import{c as o,r as i,p as e,L as c}from"./index-D3Q1knR6.js";import{T as x,S as d,B as m}from"./TopBar-C8rjlOhI.js";import"./createLucideIcon-BLVTLNRa.js";import"./flame-BaVgRNL-.js";import"./message-circle-CjeS-3Ff.js";function j(){const{models:a}=o.useLoaderData(),[t,n]=i.useState(""),l=t?a.filter(s=>(s.name+s.handle+s.tags.join(" ")).toLowerCase().includes(t.toLowerCase())):a;return e.jsxs("div",{className:"min-h-screen bg-white text-[#333]",children:[e.jsx(x,{}),e.jsxs("main",{className:"mx-auto max-w-3xl px-3 pb-24 pt-4",children:[e.jsxs("div",{className:"mb-5 flex items-center gap-2 rounded-2xl bg-[#f8f8f8] px-3 py-2.5 ring-1 ring-[#e0e0e0]",children:[e.jsx(d,{className:"h-4 w-4 text-[#999]"}),e.jsx("input",{value:t,onChange:s=>n(s.target.value),placeholder:"Buscar modelos, @handle, #tag",className:"w-full bg-transparent text-sm outline-none placeholder:text-[#999]"})]}),e.jsx("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-3",children:l.map(s=>{const r=e.jsxs(e.Fragment,{children:[s.cover?e.jsx("img",{src:s.cover,alt:s.name,className:"h-full w-full object-cover transition group-hover:scale-105"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-[#f8f8f8]",children:e.jsx("span",{className:"text-[10px] uppercase tracking-wider text-[#999]",children:"em breve"})}),e.jsxs("div",{className:"absolute inset-x-0 bottom-0 bg-gradient-to-t from-black/85 to-transparent p-2 text-white",children:[e.jsx("p",{className:"truncate text-xs font-semibold",children:s.name}),e.jsx("p",{className:"truncate text-[10px] text-white/75",children:s.comingSoon?"em breve":`@${s.handle}`})]})]});return s.comingSoon?e.jsx("div",{className:"relative aspect-[3/4] overflow-hidden rounded-xl bg-[#f8f8f8] ring-1 ring-[#e0e0e0] opacity-80",children:r},s.slug):e.jsx(c,{to:"/modelo/$slug",params:{slug:s.slug},className:"group relative aspect-[3/4] overflow-hidden rounded-xl bg-[#f8f8f8] ring-1 ring-[#e0e0e0]",children:r},s.slug)})})]}),e.jsx(m,{})]})}export{j as component};
