1import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{_n as t,tn as n}from"./icons-DWDawIq8.js";import{a as r,t as i}from"./router-compat-Dwk4eIMW.js";import{t as a}from"./jsx-runtime-B74pBk57.js";import{c as o}from"./site-BE111Axk.js";import{y as s}from"./useWordPress-CvV9WWJF.js";import{t as c}from"./utils-DojpP95n.js";import{c as l,f as u,m as d,p as f,u as p,x as m}from"./helpers-5yht0PEb.js";import{t as h}from"./AuthorAvatar-BYiUxoJ-.js";import{r as g}from"./categoryColors-Cr2_D2ID.js";import{t as _}from"./Thumbnail-ClqIHPIj.js";import{t as v}from"./SaveArticleButton-DaX8g1an.js";var y=e(t(),1),b=a(),x=(0,y.forwardRef)(function({post:e,showThumbnail:t=!1,showCategory:a=!1,showExcerpt:y=!1,showAuthor:x=!1,fetchPriority:S,className:C},w){let T=d(e._embedded),E=f(e),{prefetchPost:D}=s(),O=r(),k=T?void 0:u(e),A=k?o(k):void 0,j=E?g(E.slug):`default`,M=j==="default"?`text-primary`:`text-accent-${j}`,N=e._embedded?.author?.[0],P=N?.name,F=N?.slug;return(0,b.jsxs)(`article`,{ref:w,className:c(`group flex items-start gap-4 py-3 border-b border-border last:border-0`,C),"data-prefetch-slug":e.slug,children:[t&&(T||A)&&(0,b.jsx)(i,{to:`/${e.slug}/`,className:`shrink-0`,onMouseEnter:()=>D(e.slug),onPointerDown:()=>D(e.slug),children:(0,b.jsx)(_,{media:T,src:A,alt:T?.alt_text||m(e.title?.rendered||``),ratio:`1/1`,rounded:`lg`,className:`w-16`,sizes:`64px`,fetchPriority:S})}),(0,b.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[a&&E&&(0,b.jsx)(i,{to:`/category/${E.slug}/`,className:c(`text-xs font-medium uppercase tracking-wide mb-1 block`,M),children:E.name}),(0,b.jsx)(i,{to:`/${e.slug}/`,onMouseEnter:()=>D(e.slug),onPointerDown:()=>D(e.slug),children:(0,b.jsx)(`h3`,{className:`font-medium leading-snug text-foreground transition-colors group-hover:text-primary card-title-tight`,dangerouslySetInnerHTML:{__html:e.title?.rendered||``}})}),y&&(0,b.jsx)(`p`,{className:`mt-1 line-clamp-1 text-sm text-muted-foreground`,children:m(e.excerpt?.rendered||``)}),(0,b.jsxs)(`span`,{className:`mt-1 flex flex-wrap items-center gap-1.5 text-xs text-muted-foreground`,children:[x&&P&&(0,b.jsxs)(`span`,{className:c(`flex items-center gap-1.5 shrink-0 transition-colors`,F&&`cursor-pointer hover:text-primary`),role:F?`link`:void 0,onClick:F?e=>{e.stopPropagation(),e.preventDefault(),O(`/author/${F}/`)}:void 0,children:[N&&(0,b.jsx)(h,{author:N,size:24,priority:S===`high`}),(0,b.jsx)(`span`,{className:`truncate max-w-[100px]`,children:P}),(0,b.jsx)(`span`,{className:`text-muted-foreground/50`,children:`·`})]}),(0,b.jsxs)(`span`,{className:`flex items-center gap-1 shrink-0 whitespace-nowrap`,children:[(0,b.jsx)(n,{className:`h-3 w-3`}),l(p(e))]}),(0,b.jsx)(v,{post:e,variant:`meta`,className:`ml-auto`})]})]})]})});x.displayName=`PostListItem`;export{x as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.