import"./rolldown-runtime-DIIn1E2Q.js";import{A as e,Bt as t,F as n,I as r,K as i,O as a,R as o,Rt as s,S as c,Ut as l,_t as u,et as d,j as f,k as p,nt as m,rt as h}from"./vendor-vue-core-DO0afONr.js";import{G as g,K as _,X as v,Y as y,q as b}from"./vendor-reka-ui-B53kLmAc.js";import{t as x}from"./src-NuWuoO1R.js";import{t as S}from"./Button-Ca3rDegY.js";var C={class:`flex flex-col p-1`},w={key:0,class:`w-full border-b border-border-subtle`},T=[`onClick`],E=o({inheritAttrs:!1,__name:`Popover`,props:{entries:{},icon:{},to:{},showArrow:{type:Boolean,default:!0}},setup(o){return(o,E)=>(d(),p(s(v),null,{default:u(({close:v})=>[r(s(g),{"as-child":``},{default:u(()=>[h(o.$slots,`button`,{},()=>[r(S,{size:`icon`},{default:u(()=>[a(`i`,{class:t(o.icon??`icon-[lucide--ellipsis]`)},null,2)]),_:1})])]),_:3}),r(s(_),{to:o.to},{default:u(()=>[r(s(b),i({side:`bottom`,"side-offset":5,"collision-padding":10},o.$attrs,{class:`data-[state=open]:data-[side=top]:animate-slideDownAndFade data-[state=open]:data-[side=right]:animate-slideLeftAndFade data-[state=open]:data-[side=bottom]:animate-slideUpAndFade data-[state=open]:data-[side=left]:animate-slideRightAndFade z-1700 rounded-lg border border-border-subtle bg-base-background p-2 shadow-sm will-change-[transform,opacity]`}),{default:u(()=>[h(o.$slots,`default`,{close:v},()=>[a(`div`,C,[(d(!0),f(c,null,m(o.entries??[],r=>(d(),f(c,{key:r.label},[r.separator?(d(),f(`div`,w)):(d(),f(`div`,{key:1,class:t(s(x)(`my-1 flex flex-row gap-4 rounded-sm p-2`,r.disabled?`pointer-events-none opacity-50`:r.command&&`cursor-pointer hover:bg-secondary-background-hover`)),onClick:e=>{!r.command||r.disabled||(r.command({originalEvent:e,item:r}),v())}},[r.icon?(d(),f(`i`,{key:0,class:t(r.icon)},null,2)):e(``,!0),n(` `+l(r.label),1)],10,T))],64))),128))])]),o.showArrow?(d(),p(s(y),{key:0,class:`fill-base-background stroke-border-subtle`})):e(``,!0)]),_:2},1040)]),_:2},1032,[`to`])]),_:3}))}});export{E as t};
//# sourceMappingURL=Popover-CXKWNrM3.js.map