// @bun
import{StatusChip as G}from"@contractspec/lib.design-system";import{HStack as z}from"@contractspec/lib.ui-kit-web/ui/stack";import{ArrowRight as K,Layout as M,Radio as N,Shield as O,Tag as Q,Users as V,Zap as W}from"lucide-react";import{jsx as P,jsxs as v,Fragment as Y}from"react/jsx-runtime";function X({feature:I}){let{meta:w,operations:B,events:D,presentations:E,capabilities:F}=I,J=F?.provides?.length||F?.requires?.length;return v(Y,{children:[w.description&&P("p",{className:"text-muted-foreground text-sm leading-relaxed",children:w.description}),v(z,{gap:"md",className:"py-2",children:[B?.length?v("div",{className:"flex items-center gap-1.5 text-sm",children:[P(W,{className:"h-4 w-4 text-amber-500"}),P("span",{className:"font-medium",children:B.length}),P("span",{className:"text-muted-foreground",children:"ops"})]}):null,D?.length?v("div",{className:"flex items-center gap-1.5 text-sm",children:[P(N,{className:"h-4 w-4 text-blue-500"}),P("span",{className:"font-medium",children:D.length}),P("span",{className:"text-muted-foreground",children:"events"})]}):null,E?.length?v("div",{className:"flex items-center gap-1.5 text-sm",children:[P(M,{className:"h-4 w-4 text-purple-500"}),P("span",{className:"font-medium",children:E.length}),P("span",{className:"text-muted-foreground",children:"views"})]}):null]}),J&&v("div",{className:"space-y-1.5 border-border/50 border-t pt-1",children:[F?.provides?.length?v(z,{gap:"xs",wrap:"wrap",className:"items-start",children:[P(O,{className:"mt-0.5 h-3.5 w-3.5 text-emerald-500"}),P("span",{className:"text-muted-foreground text-xs",children:"Provides:"}),F.provides.slice(0,2).map((y)=>P(G,{tone:"success",label:y.key,size:"sm"},y.key)),F.provides.length>2&&v("span",{className:"text-muted-foreground text-xs",children:["+",F.provides.length-2]})]}):null,F?.requires?.length?v(z,{gap:"xs",wrap:"wrap",className:"items-start",children:[P(K,{className:"mt-0.5 h-3.5 w-3.5 text-blue-500"}),P("span",{className:"text-muted-foreground text-xs",children:"Requires:"}),F.requires.slice(0,2).map((y)=>P(G,{tone:"info",label:y.key,size:"sm"},y.key)),F.requires.length>2&&v("span",{className:"text-muted-foreground text-xs",children:["+",F.requires.length-2]})]}):null]}),w.tags?.length?v(z,{gap:"xs",wrap:"wrap",className:"items-center border-border/50 border-t pt-1",children:[P(Q,{className:"h-3.5 w-3.5 text-muted-foreground"}),w.tags.slice(0,4).map((y)=>v("span",{className:"rounded bg-muted px-1.5 py-0.5 text-muted-foreground text-xs",children:["#",y]},y)),w.tags.length>4&&v("span",{className:"text-muted-foreground text-xs",children:["+",w.tags.length-4]})]}):null,w.owners?.length?v(z,{gap:"xs",className:"items-center text-muted-foreground text-xs",children:[P(V,{className:"h-3.5 w-3.5"}),P("span",{children:w.owners.join(", ")})]}):null]})}export{X as FeatureHoverPreview};
