import{d as y,r as v,K as A,o as V,eO as f,b as u,c,w as o,f as t,u as e,as as h,cC as x,e as s,eH as _,bA as C}from"./outputWidgets.7dd23d3d.js";import{d as D}from"./vuedraggable.umd.9e3b6699.js";import{_ as S}from"./SaveButton.vue_vue_type_script_setup_true_lang.825ca3ed.js";import{A as I}from"./Item.e2852263.js";import{A as L}from"./index.751c58a3.js";import{A as w}from"./Title.0952eb37.js";import{A as g}from"./index.8d63ab0d.js";import{A as b}from"./index.42ade5ee.js";import{A as E,F}from"./Form.9f41d3b4.js";import{S as U}from"./SidebarPreview.759422d3.js";import{C as $}from"./ContentLayout.fb9ec5fe.js";import{L as B}from"./LoadingContainer.5aa0eb8d.js";import{a as N}from"./asyncComputed.8f047c40.js";import{W as T}from"./workspaces.299c954e.js";import"./envVars.edb75e83.js";import"./UnsavedChangesHandler.097b575b.js";import"./ExclamationCircleOutlined.140778c5.js";import"./Modal.5fb5fcda.js";import"./Base.4bf9624b.js";import"./Link.ffd51525.js";import"./hasIn.7d5dcda7.js";import"./PlayerNavbar.a89c1e87.js";import"./PhKanban.vue.b32a2861.js";import"./PhSignOut.vue.0b43dbfe.js";import"./Text.8f0caa1d.js";import"./index.63d9c692.js";import"./Paragraph.7df229fc.js";import"./index.3a6370f6.js";import"./WidgetsFrame.22445284.js";import"./runnerData.13e158ee.js";import"./url.6301f7e9.js";import"./HomeContent.867fb964.js";import"./PhArrowSquareOut.vue.12dafa2a.js";import"./index.b7995827.js";import"./Card.fee12f7e.js";import"./TabPane.d692f77b.js";import"./record.4544f931.js";import"./pubsub.692bcdfa.js";(function(){try{var r=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(r._sentryDebugIds=r._sentryDebugIds||{},r._sentryDebugIds[a]="c67cc08b-2b10-45b8-b9ed-7731145012ea",r._sentryDebugIdIdentifier="sentry-dbid-c67cc08b-2b10-45b8-b9ed-7731145012ea")}catch{}})();const j=s("span",null,"Route",-1),M=s("span",null,"Title",-1),R=s("span",null,"Visible",-1),W={style:{flex:"1 0"}},q={style:{flex:"1 0"}},z=y({__name:"SidebarEditor",props:{modelValue:{},workspace:{}},emits:["update:modelValue"],setup(r,{emit:a}){const n=r,i=v([]),p=()=>a("update:modelValue",i.value);return A(()=>n.modelValue,(d,m)=>{f.exports.isEqual(d,m)||(i.value=f.exports.cloneDeep(d))}),V(()=>{i.value=f.exports.cloneDeep(n.modelValue)}),(d,m)=>(u(),c(e(E),{help:"Change your sidebar items position and visibility by dragging them up and down"},{default:o(()=>[t(e(g),{justify:"space-between",style:{margin:"0 0 12px 0"}},{default:o(()=>[t(e(w),{level:4,style:{margin:"0"}},{default:o(()=>[h("Sidebar items")]),_:1}),t(S,{model:d.workspace},null,8,["model"])]),_:1}),t(e(L),{bordered:""},{header:o(()=>[t(e(x),{style:{width:"100%","justify-content":"space-between"}},{default:o(()=>[j,t(e(b),{type:"vertical"}),M,t(e(b),{type:"vertical"}),R]),_:1})]),default:o(()=>[t(e(D),{modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=l=>i.value=l),style:{width:"100%"},onChange:p},{item:o(({element:l})=>[t(e(I),{style:{cursor:"ns-resize"}},{default:o(()=>[s("span",W,"/"+_(l.path),1),s("span",q,_(l.name),1),t(e(C),{checked:l.visible,"onUpdate:checked":k=>l.visible=k,type:"checkbox",onChange:p},null,8,["checked","onUpdate:checked"])]),_:2},1024)]),_:1},8,["modelValue"])]),_:1})]),_:1}))}}),H={style:{width:"50%"}},K={style:{width:"50%"}},Le=y({__name:"SidebarEditor",setup(r){const{result:a,loading:n}=N(()=>T.get());return(i,p)=>(u(),c($,null,{default:o(()=>[e(n)||!e(a)?(u(),c(B,{key:0})):(u(),c(e(F),{key:1,style:{width:"100%"}},{default:o(()=>[t(e(w),null,{default:o(()=>[h("Sidebar")]),_:1}),t(e(g),{gap:"40"},{default:o(()=>[s("div",H,[t(z,{modelValue:e(a).sidebar,"onUpdate:modelValue":p[0]||(p[0]=d=>e(a).sidebar=d),workspace:e(a)},null,8,["modelValue","workspace"])]),s("div",K,[t(U,{workspace:e(a),"widgets-visible":!1},null,8,["workspace"])])]),_:1})]),_:1}))]),_:1}))}});export{Le as default};
//# sourceMappingURL=SidebarEditor.28fbe11d.js.map
