import{C as e,D as t,E as n,F as r,H as i,I as a,Q as o,S as s,T as c,X as l,Y as u,_ as d,a as f,b as p,n as m,r as h,x as g,y as _}from"./app-D8B1CEvd.js";import{t as v}from"./MarketingLayout-9Lth32FP.js";var y={class:`mx-auto max-w-6xl px-6 py-16`},b={key:0,class:`mb-8 rounded-xl border border-emerald-500/30 bg-emerald-500/10 px-4 py-3 text-sm font-medium text-emerald-700 dark:text-emerald-300`},x={class:`mb-10 flex flex-wrap items-end justify-between gap-4`},S={class:`flex shrink-0 items-center gap-2`},C={key:1,class:`rounded-2xl border border-dashed border-line p-16 text-center text-ink-muted`},w={key:2,class:`grid gap-5 sm:grid-cols-2 lg:grid-cols-3`},T=[`src`,`alt`],E={key:1,class:`grid aspect-[2/1] w-full place-items-center bg-primary/10 text-4xl`},D={class:`flex flex-1 flex-col p-6`},O={class:`flex items-center gap-2`},k={class:`truncate font-bold group-hover:text-primary`},A={class:`ml-auto shrink-0 text-xs font-semibold uppercase tracking-wide text-ink-muted`},j={class:`mt-3 line-clamp-2 text-sm text-ink-2`},M={key:0,class:`mt-3`},N={class:`mt-4 flex flex-1 items-end justify-between border-t border-line pt-4`},P=t({__name:`Index`,props:{products:{}},setup(t){let P=_(()=>f().props.flash?.status),F=_(()=>!!f().props.auth?.user);function I(e){return e?.rating===`safe`?{t:`✓ Reviewed safe`,c:`bg-emerald-500/15 text-emerald-600 dark:text-emerald-400`}:e?.rating===`caution`?{t:`⚠ Review: caution`,c:`bg-amber-500/15 text-amber-600 dark:text-amber-400`}:e?.rating===`unsafe`?{t:`⛔ Review: unsafe`,c:`bg-red-500/15 text-red-600 dark:text-red-400`}:null}return(f,_)=>(r(),e(d,null,[n(u(m),{title:`Extensions & themes — Convoro`}),n(v,null,{default:i(()=>[p(`section`,y,[P.value?(r(),e(`div`,b,o(P.value),1)):s(``,!0),p(`div`,x,[_[2]||=p(`div`,{class:`max-w-2xl`},[p(`h1`,{class:`text-4xl font-black tracking-tight`},`Extensions & themes`),p(`p`,{class:`mt-3 text-lg text-ink-2`},`Browse the directory of Convoro extensions and themes. Free add-ons install in one click; premium ones are purchased on their detail page — you get a license key to install on any of your sites.`)],-1),p(`div`,S,[F.value?(r(),g(u(h),{key:0,href:`/extensions/manage`,class:`inline-flex items-center gap-2 rounded-c border border-line px-4 py-2.5 text-sm font-bold text-ink-2 hover:bg-surface-2`},{default:i(()=>[..._[0]||=[c(` Manage yours `,-1)]]),_:1})):s(``,!0),n(u(h),{href:`/extensions/submit`,class:`inline-flex items-center gap-2 rounded-c bg-primary px-5 py-2.5 text-sm font-bold text-white hover:bg-primary-600`},{default:i(()=>[..._[1]||=[p(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[p(`path`,{d:`M12 5v14M5 12h14`})],-1),c(` Submit your extension `,-1)]]),_:1})])]),t.products.length?(r(),e(`div`,w,[(r(!0),e(d,null,a(t.products,t=>(r(),g(u(h),{key:t.slug,href:`/extensions/${t.slug}`,class:`group flex flex-col overflow-hidden rounded-2xl border border-line bg-surface transition hover:-translate-y-0.5 hover:shadow-lg`},{default:i(()=>[t.image?(r(),e(`img`,{key:0,src:t.image,alt:t.name,loading:`lazy`,class:`aspect-[2/1] w-full object-cover`},null,8,T)):(r(),e(`div`,E,o(t.type===`theme`?`🎨`:`🧩`),1)),p(`div`,D,[p(`div`,O,[p(`h3`,k,o(t.name),1),p(`span`,A,o(t.type),1)]),p(`p`,j,o(t.description),1),I(t.review)?(r(),e(`div`,M,[p(`span`,{class:l([`inline-flex items-center rounded-full px-2 py-0.5 text-[11px] font-bold`,I(t.review).c])},o(I(t.review).t),3)])):s(``,!0),p(`div`,N,[p(`span`,{class:l([`font-extrabold`,t.free?`text-ink-muted`:`text-primary`])},o(t.price),3),_[3]||=p(`span`,{class:`text-sm font-semibold text-primary group-hover:underline`},`View →`,-1)])])]),_:2},1032,[`href`]))),128))])):(r(),e(`div`,C,` New premium add-ons are on the way. Check back soon. `))])]),_:1})],64))}});export{P as default};