import{r as d,j as e,L as n}from"./vendor-tanstack-BdLtprmr.js";import{L as a}from"./lazy-markdown-D_y73qoD.js";import{aP as l,C as x,m as i,o as m,aZ as o}from"./index-CPpeVt8m.js";const f=({artifact:s,compact:t=!1})=>{const r=d.useMemo(()=>l(new Date(s.created??""),"dateTime"),[s.created]);return e.jsx(n,{to:"/artifacts/key/$key",params:{key:s.key??""},children:e.jsxs(x,{className:"hover:shadow-lg hover:border-blue-700",children:[e.jsx(i,{children:e.jsx("p",{className:"text-sm font-bold text-muted-foreground",children:s.type?.toUpperCase()})}),e.jsxs(m,{children:[e.jsxs("div",{className:o("flex",t?"flex-row justify-between":"flex-col"),children:[t?e.jsx("h4",{className:"text-xl font-semibold tracking-tight font-bold",children:s.key}):e.jsx("h3",{className:"text-2xl font-semibold tracking-tight font-bold",children:s.key}),e.jsxs("div",{className:o("flex mt-2",t?"flex-col-reverse items-end":"justify-between"),children:[t?e.jsx("p",{className:"text-sm font-mono",children:r}):e.jsx("p",{className:"text-xs font-mono",children:r}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Created"})]})]}),e.jsx("hr",{className:"my-2"}),s.description?e.jsx("div",{className:"text-muted-foreground overflow-hidden truncate",children:e.jsx(a,{children:s.description??""})}):e.jsx("p",{className:"text-sm text-muted-foreground italic",children:"No description"})]})]})})};export{f as A};
//# sourceMappingURL=artifact-card-BnPKAfkY.js.map
