const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./ValueControlPopover-DXSyOe6g.js","./vendor-primevue-D1-E3-0M.js","./rolldown-runtime-ConPGZeh.js","./dialogService-DIdX_hbW.js","./_plugin-vue_export-helper-DrrwuIjt.js","./vendor-other-CT05lTmi.js","./vendor-three-Bev8c8v4.js","./vendor-tiptap-BcmbE3kh.js","./vendor-vue-W0uRz0qB.js","./vendor-other-CaaUC6Qe.css","./vendor-xterm-yFOVTnkn.js","./vendor-xterm-kHJ-D0s7.css","./PanelTemplate-CURL0L1Z.js","./api-DvJuMrZn.js","./widget-BQ1DBAAx.js","./colorUtil-B_d8JZoL.js","./tailwindUtil-ByInBvan.js","./Button-DXEyozJJ.js","./vendor-reka-ui-B91t29PA.js","./Slider-CFj4XNt_.js","./useErrorHandling-DNVxJ2sn.js","./remoteConfig-BiMFcSmW.js","./userStore-B8bYM80v.js","./markdownRendererUtil-CsfE-fUn.js","./dialogService-BBccNyOm.css"])))=>i.map(i=>d[i]);
import{i as e,n as t}from"./rolldown-runtime-ConPGZeh.js";import{$n as n,Gn as r,Lr as i,Nn as a,Or as o,Pr as s,Qn as c,Sr as l,Tr as u,Xn as d,Yr as f,Zn as p,ar as m,bn as h,er as g,ii as _,ir as v,jr as y,li as b,mr as x,oi as S,or as C,pr as w,rr as T,wr as E,yn as D}from"./vendor-primevue-D1-E3-0M.js";import{c as O,l as k,o as A,s as j,t as M,u as N}from"./vendor-reka-ui-B91t29PA.js";import{n as P,t as F}from"./tailwindUtil-ByInBvan.js";import{n as I,t as L}from"./Button-DXEyozJJ.js";var R,z,B,V=t((()=>{a(),M(),I(),F(),R={class:`flex flex-col p-1`},z=[`onClick`],B=C({inheritAttrs:!1,__name:`Popover`,props:{entries:{},icon:{},to:{}},setup(e){return(e,t)=>(l(),c(_(N),null,{default:i(({close:t})=>[v(_(A),{"as-child":``},{default:i(()=>[u(e.$slots,`button`,{},()=>[v(L,{size:`icon`},{default:i(()=>[p(`i`,{class:S(e.icon??`icon-[lucide--ellipsis]`)},null,2)]),_:1})])]),_:3}),v(_(j),{to:e.to},{default:i(()=>[v(_(O),x({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:i(()=>[u(e.$slots,`default`,{},()=>[p(`div`,R,[(l(!0),g(r,null,E(e.entries??[],(e,i)=>(l(),g(`section`,{key:i,class:`flex flex-col border-b-2 last:border-none border-border-subtle`},[(l(!0),g(r,null,E(e,({label:e,action:r,icon:i})=>(l(),g(`div`,{key:e,class:S(_(P)(`flex flex-row gap-4 p-2 rounded-sm my-1`,r&&`cursor-pointer hover:bg-secondary-background-hover`)),onClick:()=>{r&&(r(),t())}},[i?(l(),g(`i`,{key:0,class:S(i)},null,2)):n(``,!0),T(` `+b(e),1)],10,z))),128))]))),128))])]),v(_(k),{class:`fill-base-background stroke-border-subtle`})]),_:2},1040)]),_:2},1032,[`to`])]),_:3}))}})})),H,U=t((()=>{V(),V(),H=B})),W,G,K=t((()=>{a(),U(),I(),h(),W={class:`relative grid grid-cols-subgrid`},G=C({__name:`WidgetWithControl`,props:w({widget:{},component:{}},{modelValue:{},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=m(()=>D(()=>import(`./ValueControlPopover-DXSyOe6g.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]),import.meta.url)),n=e,r=y(e,`modelValue`),a=f(n.widget.controlWidget.value),u=d(()=>{switch(a.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 s(a,n.widget.controlWidget.update),(e,n)=>(l(),g(`div`,W,[(l(),c(o(e.component),x(e.$attrs,{modelValue:r.value,"onUpdate:modelValue":n[1]||=e=>r.value=e,widget:e.widget}),{default:i(()=>[v(H,null,{button:i(()=>[v(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:i(()=>[p(`i`,{class:S(`${u.value} text-primary-background text-xs w-full`)},null,2)]),_:1})]),default:i(()=>[v(_(t),{modelValue:a.value,"onUpdate:modelValue":n[0]||=e=>a.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-TutXdNW8.js.map