const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./ValueControlPopover-B2Yxc-JB.js","./vendor-primevue-D50rA9nL.js","./rolldown-runtime-BKYq3fBv.js","./dialogService-Cr3DyAja.js","./_plugin-vue_export-helper-Ckv1EJQX.js","./vendor-other-BnH5nyVX.js","./vendor-three-BDtRe4OM.js","./vendor-tiptap-Rj3K7fja.js","./vendor-vue-BAQ5VIVR.js","./vendor-other-CaaUC6Qe.css","./vendor-reka-ui-BivsvaeG.js","./vendor-xterm-ou66y9E9.js","./vendor-xterm-kHJ-D0s7.css","./PanelTemplate-BUPnglF3.js","./api-z_dXWY_S.js","./i18n-ZU7-AXHi.js","./widget-D00AxrDc.js","./colorUtil-CaSrhsxR.js","./tailwindUtil-CORTPblY.js","./Button-DzMg17Os.js","./Slider-DpLALxux.js","./useErrorHandling-Dt_X40fr.js","./remoteConfig-BXkMU0oz.js","./userStore-D0IyjTYG.js","./markdownRendererUtil-DUxQXDfQ.js","./dialogService-ev1tim4K.css"])))=>i.map(i=>d[i]);
import{i as e,n as t}from"./rolldown-runtime-BKYq3fBv.js";import{$n as n,Cr as r,Er as i,Fr as a,Gn as o,Mr as s,Nn as c,Qn as l,Rr as u,Tr as d,Xn as f,Xr as p,Zn as m,ai as h,ar as g,bn as _,er as v,hr as y,ir as b,kr as x,mr as S,or as C,si as w,sr as T,ui as E,yn as D}from"./vendor-primevue-D50rA9nL.js";import{C as O,D as k,E as A,T as j,t as M,w as N}from"./vendor-reka-ui-BivsvaeG.js";import{n as P,t as F}from"./tailwindUtil-CORTPblY.js";import{n as I,t as L}from"./Button-DzMg17Os.js";var R,z,B,V=t((()=>{c(),M(),I(),F(),R={class:`flex flex-col p-1`},z=[`onClick`],B=T({inheritAttrs:!1,__name:`Popover`,props:{entries:{},icon:{},to:{}},setup(e){return(e,t)=>(r(),l(h(k),null,{default:u(({close:t})=>[g(h(O),{"as-child":``},{default:u(()=>[i(e.$slots,`button`,{},()=>[g(L,{size:`icon`},{default:u(()=>[m(`i`,{class:w(e.icon??`icon-[lucide--ellipsis]`)},null,2)]),_:1})])]),_:3}),g(h(N),{to:e.to},{default:u(()=>[g(h(j),y({side:`bottom`,"side-offset":5,"collision-padding":10},e.$attrs,{class:`rounded-lg p-2 bg-base-background shadow-sm border border-border-subtle will-change-[transform,opacity] 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`}),{default:u(()=>[i(e.$slots,`default`,{},()=>[m(`div`,R,[(r(!0),v(o,null,d(e.entries??[],(e,i)=>(r(),v(`section`,{key:i,class:`flex flex-col border-b-2 last:border-none border-border-subtle`},[(r(!0),v(o,null,d(e,({label:e,action:i,icon:a})=>(r(),v(`div`,{key:e,class:w(h(P)(`flex flex-row gap-4 p-2 rounded-sm my-1`,i&&`cursor-pointer hover:bg-secondary-background-hover`)),onClick:()=>{i&&(i(),t())}},[a?(r(),v(`i`,{key:0,class:w(a)},null,2)):n(``,!0),b(` `+E(e),1)],10,z))),128))]))),128))])]),g(h(A),{class:`fill-base-background stroke-border-subtle`})]),_:2},1040)]),_:2},1032,[`to`])]),_:3}))}})})),H,U=t((()=>{V(),V(),H=B})),W,G,K=t((()=>{c(),U(),I(),_(),W={class:`relative grid grid-cols-subgrid`},G=T({__name:`WidgetWithControl`,props:S({widget:{},component:{}},{modelValue:{},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=C(()=>D(()=>import(`./ValueControlPopover-B2Yxc-JB.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25]),import.meta.url)),n=e,i=s(e,`modelValue`),o=p(n.widget.controlWidget.value),c=f(()=>{switch(o.value){case`increment`:return`pi pi-plus`;case`decrement`:return`pi pi-minus`;case`fixed`:return`icon-[lucide--pencil-off]`;default:return`icon-[lucide--shuffle]`}});return a(o,n.widget.controlWidget.update),(e,n)=>(r(),v(`div`,W,[(r(),l(x(e.component),y(e.$attrs,{modelValue:i.value,"onUpdate:modelValue":n[1]||=e=>i.value=e,widget:e.widget}),{default:u(()=>[g(H,null,{button:u(()=>[g(L,{variant:`textonly`,size:`sm`,class:`h-4 w-7 p-0 self-center rounded-xl bg-primary-background/30 hover:bg-primary-background-hover/30`},{default:u(()=>[m(`i`,{class:w(`${c.value} text-primary-background text-xs w-full`)},null,2)]),_:1})]),default:u(()=>[g(h(t),{modelValue:o.value,"onUpdate:modelValue":n[0]||=e=>o.value=e},null,8,[`modelValue`])]),_:1})]),_:1},16,[`modelValue`,`widget`]))]))}})})),q,J=t((()=>{K(),K(),q=G}));export{U as i,J as n,H as r,q as t};
//# sourceMappingURL=WidgetWithControl-BoLlsc0S.js.map