@marimo-team/frontend 0.23.11-dev22 → 0.23.11-dev23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (22) hide show
  1. package/dist/assets/{JsonOutput-BP1BF3ok.js → JsonOutput-BgU0YoWq.js} +12 -12
  2. package/dist/assets/{add-connection-dialog-B60ibI0N.js → add-connection-dialog-CYdyYsKy.js} +1 -1
  3. package/dist/assets/{agent-panel-HJKRcCdY.js → agent-panel-C3fnscrX.js} +1 -1
  4. package/dist/assets/{cell-editor-Bx7gOPwL.js → cell-editor-KKuNgpaD.js} +1 -1
  5. package/dist/assets/{column-preview-BatLzSJO.js → column-preview-DSb2IIj-.js} +1 -1
  6. package/dist/assets/{command-palette-IMHTYfai.js → command-palette-CN7OBmHG.js} +1 -1
  7. package/dist/assets/{edit-page-BBtiKJhO.js → edit-page-_lMTxldP.js} +4 -4
  8. package/dist/assets/{file-explorer-panel-cxPI6o3h.js → file-explorer-panel-BhxWVmmA.js} +1 -1
  9. package/dist/assets/{form-b6jUTUMx.js → form-DMjMUXw1.js} +1 -1
  10. package/dist/assets/{hooks-CY4KeAYS.js → hooks-CvOsTpNH.js} +1 -1
  11. package/dist/assets/{index-CjSc3ZEy.js → index-DW5V-tbG.js} +2 -2
  12. package/dist/assets/{layout-B093uDWH.js → layout-CrjtGZlj.js} +3 -3
  13. package/dist/assets/{panels-CtE4FsFt.js → panels-DL9ZPvBQ.js} +1 -1
  14. package/dist/assets/{reveal-component-CYeSojfe.js → reveal-component-DuIVIgwS.js} +1 -1
  15. package/dist/assets/{run-page-Hxusxawi.js → run-page-IO7tlMDF.js} +1 -1
  16. package/dist/assets/{scratchpad-panel-Cs-2Mtyy.js → scratchpad-panel-DhudwLmZ.js} +1 -1
  17. package/dist/assets/{session-panel-DRwd_pTY.js → session-panel-B4I5vfLW.js} +1 -1
  18. package/dist/assets/{useNotebookActions-3Vk8OfKI.js → useNotebookActions-Bkh6zqQr.js} +1 -1
  19. package/dist/index.html +4 -4
  20. package/package.json +1 -1
  21. package/src/components/datasources/__tests__/install-package-button.test.tsx +11 -0
  22. package/src/components/datasources/install-package-button.tsx +3 -1
@@ -1,5 +1,5 @@
1
1
  const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./loro_wasm_bg-Bg3nlaci.js","./loro_wasm_bg-C5TJxMR5.js","./chunk-LvLJmgfZ.js"])))=>i.map(i=>d[i]);
2
- var Fd=Object.defineProperty;var Va=Z=>{throw TypeError(Z)};var Ld=(Z,H,ye)=>H in Z?Fd(Z,H,{enumerable:!0,configurable:!0,writable:!0,value:ye}):Z[H]=ye;var p=(Z,H,ye)=>Ld(Z,typeof H!="symbol"?H+"":H,ye),Od=(Z,H,ye)=>H.has(Z)||Va("Cannot "+ye);var $a=(Z,H,ye)=>(Od(Z,H,"read from private field"),ye?ye.call(Z):H.get(Z)),Ha=(Z,H,ye)=>H.has(Z)?Va("Cannot add the same private member more than once"):H instanceof WeakSet?H.add(Z):H.set(Z,ye);import{s as qa}from"./chunk-LvLJmgfZ.js";import{d as za,f as kr,i as Y,l as xn,n as ae,p as Bt,s as In,u as ie}from"./useEvent-D91BmmQi.js";import{t as _d}from"./react-Bj1aDYRI.js";import{$n as Dd,$t as Cr,At as Pt,Bn as Ud,Cn as Bd,D as An,Dt as Tn,En as Sr,G as Ka,Gn as Pd,H as Fn,Ht as Xa,I as jd,Jn as Md,Kn as Rd,Nn as Gd,Nt as Jd,Ot as Wd,Pi as Vd,Qr as $d,Sn as Hd,Tt as xr,U as qd,Ui as Ln,Un as Ya,V as Qa,Vn as zd,Vt as Kd,W as Za,Wn as Xd,Xt as Ir,Yn as Yd,Yt as Qd,a as ei,an as Zd,b as ot,br as ef,ci as tf,cn as On,ct as nf,d as ti,dn as rf,en as ni,gn as of,gt as af,h as jt,ht as Ar,in as sf,ji as ri,kt as lf,li as cf,mi as oi,oi as Tr,ot as uf,pi as df,q as ai,rn as ff,tn as ii,u as si,wt as mf,xn as pf,yn as gf,zn as hf,__tla as bf}from"./cells-a44D37GV.js";import{B as yf,N as wf,P as Fr,R as li,S as vf,T as ci,k as Ef,w as Nf}from"./zod-H_cgTO0M.js";import{t as ve}from"./compiler-runtime-B3qBwwSJ.js";import{C as kf,f as Cf,m as Sf,p as xf,t as If,v as Af,w as Tf}from"./ai-model-dropdown-BUVX-tXn.js";import{_ as $e,c as ui,h as Lr,t as Ff,v as Lf}from"./useEventListener-BfYriKqt.js";import{t as Mt}from"./invariant-C2E8KCbD.js";import{_ as di,c as Of,g as fi,h as mi,l as pi,w as Or}from"./utils-BGFUZat2.js";import{S as gi,T as _f,m as Df,o as Uf,r as hi,v as wt,w as Rt}from"./config-Fh_0wwfW.js";import{n as Bf,t as Pf}from"./switch-qhCyy6_O.js";import{n as jf}from"./globals-ehK_eQQa.js";import{t as Mf}from"./ErrorBoundary-clTdAaK7.js";import{t as Ze}from"./cn-X2M2usMq.js";import{t as Rf}from"./jsx-runtime-PbYoItBR.js";import{l as Gf,r as Jf,t as Wf}from"./popover-D1IutFqN.js";import{X as Vf,Y as $f,__tla as Hf}from"./JsonOutput-BP1BF3ok.js";import{t as _r}from"./label-BbRibkug.js";import{r as qf}from"./download-YFYBUFlh.js";import{t as _n}from"./tooltip-CWSr2PfE.js";import{r as Dr,t as ut}from"./button-Db07tdz7.js";import{$t as Gt,E as zf,Et as Kf,H as bi,Ht as vt,I as Xf,Jt as Yf,Kt as dt,Lt as Ur,P as Qf,Pt as Zf,St as em,Tt as yi,Ut as Br,V as wi,Vt as tm,Wt as Jt,X as l,Xt as he,Zt as Xe,_ as nm,a as rm,at as $,bt as om,dt as Dn,ht as am,kt as im,lt as sm,m as lm,mt as cm,nn as Un,ot as um,st as M,ut as et,w as dm,wt as He,xt as fm,zt as Bn}from"./dist-Dez1I5M9.js";import{E as mm,P as pm,S as gm,a as hm,b as bm,c as ym,n as Pr,r as wm,w as vm,x as Em}from"./dist-CwfKvuyQ.js";import{o as vi}from"./arrays-DWxvyYxP.js";import{n as Nm}from"./once-CXj_gH7S.js";import{t as jr}from"./createReducer-3M-fmFeM.js";import{a as km,c as Cm,f as Pn,h as Sm,i as xm,l as Wt,n as Ei,o as Im,t as Am}from"./dist-B0WqBUnf.js";import{t as Tm}from"./main-DmhaVp6Y.js";import{r as jn,t as Fm}from"./requests-KshNNAOp.js";import{t as Lm}from"./createLucideIcon-BTp1tQDO.js";import{r as Ni,t as Om,__tla as _m}from"./layout-B093uDWH.js";import{t as Dm}from"./x-9vLEgLY6.js";import{t as Um}from"./circle-check-Q2N68uwG.js";import{D as ki,E as Bm,I as Pm,L as jm,N as Mm,S as Rm,a as Ci,d as Gm,j as Jm,k as Wm,n as Vm,o as $m,r as Si,s as Hm}from"./add-cell-with-ai-D1HMdh52.js";import{r as qm,t as zm}from"./file-icons-BEjw_TZq.js";import{n as Km}from"./spinner-BlJOg2gb.js";import{n as Mr,t as xi}from"./useDeleteCell-CTDjqdn7.js";import{t as Ii}from"./save-BtZpvX_3.js";import{Y as Xm,Z as Ai}from"./input-DiAad2nt.js";import{t as Ym}from"./sparkles-DctOjjEz.js";import{t as Qm}from"./preload-helper-y72bE5iF.js";import{t as Et}from"./use-toast-BH8bU9Xf.js";import{n as tt}from"./paths-kNeJ8nbe.js";import{t as Zm}from"./session-DF0gSADo.js";import{r as ep}from"./useTheme-BcDiZbxe.js";import{n as Ti}from"./copy-DlC1PYY-.js";import{k as tp}from"./usePress-mjvipKvz.js";import{a as np}from"./useRunCells-BRYGWDtj.js";import{c as Fi,i as Li,n as Oi,r as rp}from"./dialog-CNmqslzW.js";import{t as _i}from"./useHotkey-Dg_dwRCE.js";import{n as Di}from"./ImperativeModal-CEtvKaPt.js";import{i as op}from"./errors-48KFPvCp.js";import{t as K}from"./extends-2LbFKIQQ.js";import{t as Vt}from"./objectWithoutPropertiesLoose-Msf1n32r.js";import{t as ap}from"./kbd-BCXa3Ocm.js";import{a as Rr}from"./useInstallPackage-BaCdyZWe.js";import{i as ip,n as Ui}from"./state-BahT9g5s.js";import{a as sp,o as lp}from"./cell-link-Bia8_3oN.js";import{r as Bi}from"./html-to-image-B6hPo7Eh.js";import{a as cp}from"./focus-Ptvt4Jk-.js";import{n as up}from"./useAsyncData-CT1LpOBD.js";import{a as dp,o as Pi,r as fp,s as ji,t as mp}from"./command-Dzjey1r-.js";import{a as Mi}from"./renderShortcut-BV7Qf4L2.js";import{n as pp,t as gp}from"./icons-D3YFXNmD.js";import{n as Nt}from"./esm-DSv-aO_T.js";import{t as Ri}from"./dist-BM-OLiKa.js";import{t as hp}from"./useSplitCell-iFrd3L8H.js";import{co as bp,do as Gr,fo as yp,ft as wp,go as kt,ho as Gi,lo as Jr,mo as Ji,oo as vp,po as Ep,so as Wi,uo as Vi,__tla as Np}from"./loro_wasm_bg-C5TJxMR5.js";import{t as kp}from"./ws-Cb8IUKlU.js";import{t as $i}from"./Inputs-DJ_uXwfo.js";import{n as Cp}from"./hooks-CY4KeAYS.js";let Wr,$t,Mn,Rn,Gn,Vr,Ee,Hi,qi,zi,Ki,$r,Hr,ft,Xi,Yi,Qi,Ht,Jn,Zi,Sp=Promise.all([(()=>{try{return bf}catch{}})(),(()=>{try{return Hf}catch{}})(),(()=>{try{return _m}catch{}})(),(()=>{try{return Np}catch{}})()]).then(async()=>{var Cn,Ga,ke,Ce,Se,xe,Ie,Ae,Te,Fe,Le,Oe,_e,De,Ue,Be,Pe,je,Me,Re,Ge;var Z=Lm("file-pen",[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]]);const H={showInput:"Mod-l",acceptEdit:"Mod-y",rejectEdit:"Mod-u"};var ye=300;const St=Jt.define({combine:e=>Un(e,{onError:console.error,inputDebounceTime:ye,keymaps:H},{onError:(t,n)=>t&&n,inputDebounceTime:(t,n)=>t&&n,keymaps:(t,n)=>t&&n})}),at=he.define(),it=Xe.define({create(){return{show:!1,lineFrom:0,lineTo:0}},update(e,t){for(let n of t.effects)if(n.is(at))return n.value;return e}}),xt=he.define(),It=he.define(),zr=Xe.define({create(){return{shouldFocus:!1,inputValue:""}},update(e,t){let n=e;for(let r of t.effects)r.is(xt)&&(n={...n,inputValue:r.value}),r.is(It)&&(n={...n,shouldFocus:r.value});return n}}),qt=he.define(),At=Xe.define({create(){return null},update(e,t){for(let n of t.effects)if(n.is(qt))return n.value;return e}}),mt=he.define(),Kr=Xe.define({create(){return!1},update(e,t){for(let n of t.effects)if(n.is(mt))return n.value;return e}});var es=1;const Xr=e=>{let{state:t}=e,n=t.selection.main;if(n.empty)return!1;let r=t.doc,o=r.lineAt(n.from),a=r.lineAt(n.to);if(t.sliceDoc(o.from,a.to).trim().length<es)return!1;let i=Math.max(1,Math.min(o.number,r.lines)),s=Math.max(1,Math.min(a.number,r.lines));return e.dispatch({effects:[at.of({show:!0,lineFrom:i,lineTo:s}),It.of(!0),xt.of("")],selection:vt.cursor(o.from)}),!0},Yr=e=>e.state.field(At)?(e.dispatch({effects:[qt.of(null),at.of({show:!1,lineFrom:0,lineTo:0}),It.of(!1),xt.of(""),mt.of(!1)]}),!0):!1,Qr=e=>{let t=e.state.field(At);return t?(e.dispatch({changes:{from:t.from,to:t.to,insert:t.oldCode},effects:[qt.of(null),at.of({show:!1,lineFrom:0,lineTo:0}),It.of(!1),xt.of(""),mt.of(!1)]}),!0):!1};var Wn={mac:"\u2318",windows:"\u229E Win",default:"Ctrl"};function ts(){return navigator.platform.startsWith("Mac")?Wn.mac:navigator.platform.startsWith("Win")?Wn.windows:Wn.default}function Vn(e){return e.replace("Mod",ts()).replace("-"," ").toUpperCase()}function me(e,t){let n=document.createElement(e);return n.className=t,n}function ns(e,t,n=void 0){let r=()=>{};return(...o)=>(r(),new Promise((a,i)=>{let s=setTimeout(()=>a(e(...o)),t);r=()=>{clearTimeout(s),n!==void 0&&i(n)}}))}var zt=Xe.define({create(){return{suggestion:null}},update(e,t){let n=t.effects.find(r=>r.is(Kt));return!t.docChanged&&!n&&!t.selection?e:n&&t.state.doc===n.value.doc?{suggestion:n.value.text}:{suggestion:null}}}),Kt=he.define();function rs(e,t){let n=e.state.selection.main.head,r=[],o=$.widget({widget:new os(t),side:1});return r.push(o.range(n)),$.set(r)}var os=class extends Dn{constructor(t){super();p(this,"suggestion");this.suggestion=t}toDOM(){let t=document.createElement("span");return t.style.opacity="0.4",t.className="cm-inline-suggestion",t.textContent=this.suggestion,t.setAttribute("role","suggestion"),t.setAttribute("aria-label",`Suggestion: ${this.suggestion}`),t}get lineBreaks(){return this.suggestion.split(`
2
+ var Fd=Object.defineProperty;var Va=Z=>{throw TypeError(Z)};var Ld=(Z,H,ye)=>H in Z?Fd(Z,H,{enumerable:!0,configurable:!0,writable:!0,value:ye}):Z[H]=ye;var p=(Z,H,ye)=>Ld(Z,typeof H!="symbol"?H+"":H,ye),Od=(Z,H,ye)=>H.has(Z)||Va("Cannot "+ye);var $a=(Z,H,ye)=>(Od(Z,H,"read from private field"),ye?ye.call(Z):H.get(Z)),Ha=(Z,H,ye)=>H.has(Z)?Va("Cannot add the same private member more than once"):H instanceof WeakSet?H.add(Z):H.set(Z,ye);import{s as qa}from"./chunk-LvLJmgfZ.js";import{d as za,f as kr,i as Y,l as xn,n as ae,p as Bt,s as In,u as ie}from"./useEvent-D91BmmQi.js";import{t as _d}from"./react-Bj1aDYRI.js";import{$n as Dd,$t as Cr,At as Pt,Bn as Ud,Cn as Bd,D as An,Dt as Tn,En as Sr,G as Ka,Gn as Pd,H as Fn,Ht as Xa,I as jd,Jn as Md,Kn as Rd,Nn as Gd,Nt as Jd,Ot as Wd,Pi as Vd,Qr as $d,Sn as Hd,Tt as xr,U as qd,Ui as Ln,Un as Ya,V as Qa,Vn as zd,Vt as Kd,W as Za,Wn as Xd,Xt as Ir,Yn as Yd,Yt as Qd,a as ei,an as Zd,b as ot,br as ef,ci as tf,cn as On,ct as nf,d as ti,dn as rf,en as ni,gn as of,gt as af,h as jt,ht as Ar,in as sf,ji as ri,kt as lf,li as cf,mi as oi,oi as Tr,ot as uf,pi as df,q as ai,rn as ff,tn as ii,u as si,wt as mf,xn as pf,yn as gf,zn as hf,__tla as bf}from"./cells-a44D37GV.js";import{B as yf,N as wf,P as Fr,R as li,S as vf,T as ci,k as Ef,w as Nf}from"./zod-H_cgTO0M.js";import{t as ve}from"./compiler-runtime-B3qBwwSJ.js";import{C as kf,f as Cf,m as Sf,p as xf,t as If,v as Af,w as Tf}from"./ai-model-dropdown-BUVX-tXn.js";import{_ as $e,c as ui,h as Lr,t as Ff,v as Lf}from"./useEventListener-BfYriKqt.js";import{t as Mt}from"./invariant-C2E8KCbD.js";import{_ as di,c as Of,g as fi,h as mi,l as pi,w as Or}from"./utils-BGFUZat2.js";import{S as gi,T as _f,m as Df,o as Uf,r as hi,v as wt,w as Rt}from"./config-Fh_0wwfW.js";import{n as Bf,t as Pf}from"./switch-qhCyy6_O.js";import{n as jf}from"./globals-ehK_eQQa.js";import{t as Mf}from"./ErrorBoundary-clTdAaK7.js";import{t as Ze}from"./cn-X2M2usMq.js";import{t as Rf}from"./jsx-runtime-PbYoItBR.js";import{l as Gf,r as Jf,t as Wf}from"./popover-D1IutFqN.js";import{X as Vf,Y as $f,__tla as Hf}from"./JsonOutput-BgU0YoWq.js";import{t as _r}from"./label-BbRibkug.js";import{r as qf}from"./download-YFYBUFlh.js";import{t as _n}from"./tooltip-CWSr2PfE.js";import{r as Dr,t as ut}from"./button-Db07tdz7.js";import{$t as Gt,E as zf,Et as Kf,H as bi,Ht as vt,I as Xf,Jt as Yf,Kt as dt,Lt as Ur,P as Qf,Pt as Zf,St as em,Tt as yi,Ut as Br,V as wi,Vt as tm,Wt as Jt,X as l,Xt as he,Zt as Xe,_ as nm,a as rm,at as $,bt as om,dt as Dn,ht as am,kt as im,lt as sm,m as lm,mt as cm,nn as Un,ot as um,st as M,ut as et,w as dm,wt as He,xt as fm,zt as Bn}from"./dist-Dez1I5M9.js";import{E as mm,P as pm,S as gm,a as hm,b as bm,c as ym,n as Pr,r as wm,w as vm,x as Em}from"./dist-CwfKvuyQ.js";import{o as vi}from"./arrays-DWxvyYxP.js";import{n as Nm}from"./once-CXj_gH7S.js";import{t as jr}from"./createReducer-3M-fmFeM.js";import{a as km,c as Cm,f as Pn,h as Sm,i as xm,l as Wt,n as Ei,o as Im,t as Am}from"./dist-B0WqBUnf.js";import{t as Tm}from"./main-DmhaVp6Y.js";import{r as jn,t as Fm}from"./requests-KshNNAOp.js";import{t as Lm}from"./createLucideIcon-BTp1tQDO.js";import{r as Ni,t as Om,__tla as _m}from"./layout-CrjtGZlj.js";import{t as Dm}from"./x-9vLEgLY6.js";import{t as Um}from"./circle-check-Q2N68uwG.js";import{D as ki,E as Bm,I as Pm,L as jm,N as Mm,S as Rm,a as Ci,d as Gm,j as Jm,k as Wm,n as Vm,o as $m,r as Si,s as Hm}from"./add-cell-with-ai-D1HMdh52.js";import{r as qm,t as zm}from"./file-icons-BEjw_TZq.js";import{n as Km}from"./spinner-BlJOg2gb.js";import{n as Mr,t as xi}from"./useDeleteCell-CTDjqdn7.js";import{t as Ii}from"./save-BtZpvX_3.js";import{Y as Xm,Z as Ai}from"./input-DiAad2nt.js";import{t as Ym}from"./sparkles-DctOjjEz.js";import{t as Qm}from"./preload-helper-y72bE5iF.js";import{t as Et}from"./use-toast-BH8bU9Xf.js";import{n as tt}from"./paths-kNeJ8nbe.js";import{t as Zm}from"./session-DF0gSADo.js";import{r as ep}from"./useTheme-BcDiZbxe.js";import{n as Ti}from"./copy-DlC1PYY-.js";import{k as tp}from"./usePress-mjvipKvz.js";import{a as np}from"./useRunCells-BRYGWDtj.js";import{c as Fi,i as Li,n as Oi,r as rp}from"./dialog-CNmqslzW.js";import{t as _i}from"./useHotkey-Dg_dwRCE.js";import{n as Di}from"./ImperativeModal-CEtvKaPt.js";import{i as op}from"./errors-48KFPvCp.js";import{t as K}from"./extends-2LbFKIQQ.js";import{t as Vt}from"./objectWithoutPropertiesLoose-Msf1n32r.js";import{t as ap}from"./kbd-BCXa3Ocm.js";import{a as Rr}from"./useInstallPackage-BaCdyZWe.js";import{i as ip,n as Ui}from"./state-BahT9g5s.js";import{a as sp,o as lp}from"./cell-link-Bia8_3oN.js";import{r as Bi}from"./html-to-image-B6hPo7Eh.js";import{a as cp}from"./focus-Ptvt4Jk-.js";import{n as up}from"./useAsyncData-CT1LpOBD.js";import{a as dp,o as Pi,r as fp,s as ji,t as mp}from"./command-Dzjey1r-.js";import{a as Mi}from"./renderShortcut-BV7Qf4L2.js";import{n as pp,t as gp}from"./icons-D3YFXNmD.js";import{n as Nt}from"./esm-DSv-aO_T.js";import{t as Ri}from"./dist-BM-OLiKa.js";import{t as hp}from"./useSplitCell-iFrd3L8H.js";import{co as bp,do as Gr,fo as yp,ft as wp,go as kt,ho as Gi,lo as Jr,mo as Ji,oo as vp,po as Ep,so as Wi,uo as Vi,__tla as Np}from"./loro_wasm_bg-C5TJxMR5.js";import{t as kp}from"./ws-Cb8IUKlU.js";import{t as $i}from"./Inputs-DJ_uXwfo.js";import{n as Cp}from"./hooks-CvOsTpNH.js";let Wr,$t,Mn,Rn,Gn,Vr,Ee,Hi,qi,zi,Ki,$r,Hr,ft,Xi,Yi,Qi,Ht,Jn,Zi,Sp=Promise.all([(()=>{try{return bf}catch{}})(),(()=>{try{return Hf}catch{}})(),(()=>{try{return _m}catch{}})(),(()=>{try{return Np}catch{}})()]).then(async()=>{var Cn,Ga,ke,Ce,Se,xe,Ie,Ae,Te,Fe,Le,Oe,_e,De,Ue,Be,Pe,je,Me,Re,Ge;var Z=Lm("file-pen",[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]]);const H={showInput:"Mod-l",acceptEdit:"Mod-y",rejectEdit:"Mod-u"};var ye=300;const St=Jt.define({combine:e=>Un(e,{onError:console.error,inputDebounceTime:ye,keymaps:H},{onError:(t,n)=>t&&n,inputDebounceTime:(t,n)=>t&&n,keymaps:(t,n)=>t&&n})}),at=he.define(),it=Xe.define({create(){return{show:!1,lineFrom:0,lineTo:0}},update(e,t){for(let n of t.effects)if(n.is(at))return n.value;return e}}),xt=he.define(),It=he.define(),zr=Xe.define({create(){return{shouldFocus:!1,inputValue:""}},update(e,t){let n=e;for(let r of t.effects)r.is(xt)&&(n={...n,inputValue:r.value}),r.is(It)&&(n={...n,shouldFocus:r.value});return n}}),qt=he.define(),At=Xe.define({create(){return null},update(e,t){for(let n of t.effects)if(n.is(qt))return n.value;return e}}),mt=he.define(),Kr=Xe.define({create(){return!1},update(e,t){for(let n of t.effects)if(n.is(mt))return n.value;return e}});var es=1;const Xr=e=>{let{state:t}=e,n=t.selection.main;if(n.empty)return!1;let r=t.doc,o=r.lineAt(n.from),a=r.lineAt(n.to);if(t.sliceDoc(o.from,a.to).trim().length<es)return!1;let i=Math.max(1,Math.min(o.number,r.lines)),s=Math.max(1,Math.min(a.number,r.lines));return e.dispatch({effects:[at.of({show:!0,lineFrom:i,lineTo:s}),It.of(!0),xt.of("")],selection:vt.cursor(o.from)}),!0},Yr=e=>e.state.field(At)?(e.dispatch({effects:[qt.of(null),at.of({show:!1,lineFrom:0,lineTo:0}),It.of(!1),xt.of(""),mt.of(!1)]}),!0):!1,Qr=e=>{let t=e.state.field(At);return t?(e.dispatch({changes:{from:t.from,to:t.to,insert:t.oldCode},effects:[qt.of(null),at.of({show:!1,lineFrom:0,lineTo:0}),It.of(!1),xt.of(""),mt.of(!1)]}),!0):!1};var Wn={mac:"\u2318",windows:"\u229E Win",default:"Ctrl"};function ts(){return navigator.platform.startsWith("Mac")?Wn.mac:navigator.platform.startsWith("Win")?Wn.windows:Wn.default}function Vn(e){return e.replace("Mod",ts()).replace("-"," ").toUpperCase()}function me(e,t){let n=document.createElement(e);return n.className=t,n}function ns(e,t,n=void 0){let r=()=>{};return(...o)=>(r(),new Promise((a,i)=>{let s=setTimeout(()=>a(e(...o)),t);r=()=>{clearTimeout(s),n!==void 0&&i(n)}}))}var zt=Xe.define({create(){return{suggestion:null}},update(e,t){let n=t.effects.find(r=>r.is(Kt));return!t.docChanged&&!n&&!t.selection?e:n&&t.state.doc===n.value.doc?{suggestion:n.value.text}:{suggestion:null}}}),Kt=he.define();function rs(e,t){let n=e.state.selection.main.head,r=[],o=$.widget({widget:new os(t),side:1});return r.push(o.range(n)),$.set(r)}var os=class extends Dn{constructor(t){super();p(this,"suggestion");this.suggestion=t}toDOM(){let t=document.createElement("span");return t.style.opacity="0.4",t.className="cm-inline-suggestion",t.textContent=this.suggestion,t.setAttribute("role","suggestion"),t.setAttribute("aria-label",`Suggestion: ${this.suggestion}`),t}get lineBreaks(){return this.suggestion.split(`
3
3
  `).length-1}},as=class{constructor(e){p(this,"cache",new Map);p(this,"timeout");this.timeout=e}get(e){let t=this.cache.get(e);return t?Date.now()-t.timestamp>this.timeout?(this.cache.delete(e),null):t.result:null}set(e,t){this.cache.set(e,{result:t,timestamp:Date.now()})}},is=(e,t)=>et.fromClass(class{constructor(){p(this,"abortController",null);p(this,"cache");this.cache=new as(t.cacheTimeout??1e3)}async update(n){var i,s,c,u,d;if(!n.docChanged||((s=(i=t.events)==null?void 0:i.beforeSuggestionFetch)==null?void 0:s.call(i,n.view))===!1)return;(c=this.abortController)==null||c.abort(),this.abortController=new AbortController;let r=n.state.doc,o=r.toString(),a=this.cache.get(o);if(a){n.view.dispatch({effects:Kt.of({text:a,doc:r})});return}try{let f=await e(n.state,this.abortController.signal,n.view);if(this.abortController.signal.aborted||((d=(u=t.events)==null?void 0:u.shouldShowSuggestion)==null?void 0:d.call(u,n.view,f))===!1)return;this.cache.set(o,f),n.view.dispatch({effects:Kt.of({text:f,doc:r})})}catch(f){f instanceof Error&&f.name!=="AbortError"&&console.error("Suggestion fetch error:",f)}}destroy(){var n;(n=this.abortController)==null||n.abort()}}),ss=et.fromClass(class{constructor(){p(this,"decorations");this.decorations=$.none}update(e){var n;let t=(n=e.state.field(zt))==null?void 0:n.suggestion;if(!t){this.decorations=$.none;return}this.decorations=rs(e.view,t)}},{decorations:e=>e.decorations});function ls(e,t,n,r){return{...e.changeByRange(o=>{if(o===e.selection.main)return{changes:{from:n,to:r,insert:t},range:vt.cursor(n+t.length)};let a=r-n;return!o.empty||a&&e.sliceDoc(o.from-a,o.from)!==e.sliceDoc(n,r)?{range:o}:{changes:{from:o.from-a,to:o.from,insert:t},range:vt.cursor(o.from-a+t.length)}}),userEvent:"input.complete"}}var cs=e=>{var r,o,a;let t=(r=e.state.field(zt))==null?void 0:r.suggestion;if(!t)return!1;let n=e.state.facet($n);return e.dispatch({...ls(e.state,t,e.state.selection.main.head,e.state.selection.main.head)}),(a=(o=n.events)==null?void 0:o.onSuggestionAccepted)==null||a.call(o,e,t),!0},Zr=e=>{var r,o,a;let t=(r=e.state.field(zt))==null?void 0:r.suggestion;if(!t)return!1;let n=e.state.facet($n);return e.dispatch({effects:Kt.of({text:null,doc:e.state.doc})}),(a=(o=n.events)==null?void 0:o.onSuggestionRejected)==null||a.call(o,e,t),!0},us=He.of([{key:"Tab",run:cs},{key:"Escape",run:Zr}]),$n=Jt.define({combine:e=>e.at(-1)});function eo(e){let{delay:t=500,includeKeymap:n=!0}=e,r=ns(e.fetchFn,t);return[zt,$n.of(e),is(r,e),ss,n?us:[]]}const ds=M.baseTheme({".cm-ai-input-container":{display:"flex",flexDirection:"column",gap:"4px",width:"min(calc(100% + 7px), 500px)",padding:"5px 5px",margin:"0 -6px",backgroundColor:"light-dark(rgb(241, 243, 245), rgb(40, 40, 40))"},".cm-ai-input":{display:"block",width:"100%",padding:"3px 8px",border:"2px solid rgb(51, 154, 240)",borderRadius:"5px",fontSize:"12px"},".cm-ai-help-info-button":{fontSize:"10px",paddingLeft:"10px",height:"18px",color:"light-dark(rgb(109, 117, 125), rgb(170, 170, 170))",display:"block",marginRight:"auto"},".cm-ai-help-info-button:hover":{color:"light-dark(rgb(89, 97, 105), rgb(190, 190, 190))"},".cm-ai-generate-button":{background:"#0E639C",border:"none",padding:"2px 6px",color:"#ffffff",cursor:"pointer",font:"inherit",borderRadius:"4px","&:hover":{backgroundColor:"#1177bb"}},".cm-line.cm-ai-selection, .cm-line.cm-ai-selection.cm-active-line":{backgroundColor:"light-dark(color-mix(in srgb, rgb(223, 227, 232) 50%, transparent), color-mix(in srgb, rgb(50, 50, 50) 50%, transparent)) !important"},".cm-line:has(.cm-new-code-line)":{backgroundColor:"light-dark(color-mix(in srgb, rgb(183, 235, 143) 50%, transparent), color-mix(in srgb, rgb(40, 100, 40) 50%, transparent)) !important"},".cm-old-code-container":{backgroundColor:"light-dark(rgb(255, 205, 205), rgb(100, 40, 40))",position:"relative",display:"flex",paddingTop:"0",width:"100%",alignItems:"center"},".cm-code-button":{position:"absolute",right:"5px",top:"50%",transform:"translateY(-50%)",background:"none",border:"none",cursor:"pointer",fontSize:"16px"},".cm-floating-buttons":{fontFamily:"sans-serif",position:"absolute",top:"-20px",left:"5px",display:"flex"},".cm-floating-button":{fontFamily:"sans-serif",padding:"2px 5px",fontSize:"10px",cursor:"pointer",fontWeight:"700"},".cm-floating-accept":{backgroundColor:"light-dark(rgb(55, 125, 34), rgb(40, 80, 25))",borderTopLeftRadius:"5px",borderBottomLeftRadius:"5px",color:"white",filter:"brightness(90%)","&:hover":{filter:"brightness(100%)"}},".cm-floating-reject":{backgroundColor:"light-dark(rgb(220, 53, 69), rgb(180, 40, 50))",color:"white",borderTopRightRadius:"5px",borderBottomRightRadius:"5px",filter:"brightness(90%)","&:hover":{filter:"brightness(100%)"}},".hotkey":{display:"inline-block",padding:"0 4px",borderRadius:"3px",backgroundColor:"rgba(255, 255, 255, 0.1)",fontSize:"90%"},".cm-ai-loading-indicator":{fontStyle:"italic",fontSize:"10px",paddingLeft:"12px",color:"light-dark(rgb(109, 117, 125), rgb(170, 170, 170))",opacity:"0",transition:"opacity 0.3s ease-in-out","&::after":{content:'""',display:"inline-block",animation:"ellipsis-pulse 1.5s steps(4, end) infinite"},"&:not(:empty)":{opacity:"1"}},".cm-ai-input:disabled":{opacity:"0.5"},"@keyframes ellipsis-pulse":{"0%":{content:"'.'"},"25%":{content:"'..'"},"50%":{content:"'...'"},"75%":{content:"''"}},".cm-ai-loading-container":{display:"flex",alignItems:"center",padding:"0 8px"},".cm-ai-cancel-button":{padding:"2px 8px",fontSize:"10px",borderRadius:"4px",color:"light-dark(rgb(109, 117, 125), rgb(170, 170, 170))",cursor:"pointer","&:hover":{background:"light-dark(rgb(223, 227, 232), rgb(50, 50, 50))"}},".hidden":{display:"none"}});function fs(e){var s,c;let t=e.state.facet(St),n={...H,...t.keymaps},r=e.state.facet(Xt),o=me("div","cm-ai-tooltip").appendChild(me("div","cm-ai-tooltip-button")),a=o.appendChild(document.createElement("span"));a.textContent=`${r.label} `;let i=a.appendChild(document.createElement("span"));return i.className="hotkey",i.textContent=Vn(n.showInput),(s=o.querySelector("span"))==null||s.addEventListener("mousedown",u=>{u.stopPropagation(),u.button===0&&u.preventDefault()}),(c=o.querySelector("span"))==null||c.addEventListener("click",u=>{u.preventDefault(),Xr(e)}),o}const Xt=Jt.define({combine(e){return Un(e,{render:fs,hideOnBlur:!1,label:"Edit with AI"})}}),ms=et.fromClass((Ga=class{constructor(e){p(this,"view");p(this,"suppress");p(this,"dom");p(this,"mousedown",()=>{this.suppress=!0});p(this,"mouseup",()=>{this.suppress=!1,this.display(this.view)});p(this,"scroll",()=>{this.display(this.view)});p(this,"windowScroll",()=>{this.display(this.view)});Ha(this,Cn,e=>{var n;let t=e.state.selection.ranges.find(r=>!r.empty);if(t&&!this.suppress){let r=e.coordsAtPos(t.from),o=e.coordsAtPos(t.to);if(!r||!o)return;let a=e.dom.getBoundingClientRect(),i=(n=e.dom.parentElement)==null?void 0:n.getBoundingClientRect(),s=v=>v.top>=a.top&&v.top<=a.bottom&&v.left>=a.left&&v.left<=a.right,c=v=>!i||v.top>=i.top&&v.top<=i.bottom&&v.left>=i.left&&v.left<=i.right,u=s(r)||s(o),d=c(r)||c(o);if(!u||!d){this.dom.style.display="none",this.dom.setAttribute("aria-hidden","true");return}this.dom.style.display="flex",this.dom.setAttribute("aria-hidden","false");let f=this.dom.getBoundingClientRect(),g=s(r)?r:o,m=a.right-f.width,h=Math.min(g.left,m),w=g.top-f.height,y=i?i.y:-1/0;w<y&&(w=o.bottom),this.dom.style.left=`${h}px`,this.dom.style.top=`${w}px`,requestAnimationFrame(()=>{this.dom&&this.dom.setAttribute("aria-hidden","false")})}else this.dom.style.display="none",this.dom.setAttribute("aria-hidden","true")});this.view=e;let t=e.state.facet(Xt);this.suppress=!1,document.addEventListener("mousedown",this.mousedown),document.addEventListener("mouseup",this.mouseup),e.scrollDOM.addEventListener("scroll",this.scroll),window.addEventListener("scroll",this.windowScroll,!0);let n=t.render(e);e.dom.appendChild(n),this.dom=n}update(e){this.display(e.view)}docViewUpdate(e){this.display(e)}display(e){if(e.state.field(it).show){this.dom.style.display="none";return}if(e.state.facet(Xt).hideOnBlur&&!e.hasFocus){this.dom.style.display="none",this.dom.setAttribute("aria-hidden","true");return}e.requestMeasure({read:$a(this,Cn)})}destroy(){document.removeEventListener("mousedown",this.mousedown),document.removeEventListener("mouseup",this.mouseup),this.view.scrollDOM.removeEventListener("scroll",this.scroll),window.removeEventListener("scroll",this.windowScroll,!0),this.dom.remove()}},Cn=new WeakMap,Ga));var ps=M.baseTheme({".cm-ai-tooltip-button":{userSelect:"none",fontFamily:"system-ui, -apple-system, sans-serif",position:"fixed",display:"flex",boxSizing:"border-box",padding:"2px 6px",borderRadius:"4px",fontSize:"12px",backgroundColor:"#0E639C",color:"#ffffff",border:"1px solid transparent",boxShadow:"0 2px 4px rgba(0,0,0,0.1)",zIndex:"999",transition:"opacity 0.5s","&[aria-hidden='true']":{opacity:"0"},"&[aria-hidden='false']":{opacity:"1"},"& > span":{pointerEvents:"auto",cursor:"pointer",display:"inline-block",padding:"2px"},"&:hover":{backgroundColor:"#1177bb"}}});function gs(){return[ms,ps]}var hs=class extends Dn{constructor(t){super();p(this,"oldCode");this.oldCode=t}toDOM(t){let n=me("div","cm-old-code-container");n.setAttribute("role","region"),n.setAttribute("aria-label","Previous code version");let r=me("div","cm-old-code cm-line");r.textContent=this.oldCode;let o=me("div","cm-floating-buttons"),a=t.state.facet(St),i={...H,...a.keymaps},s=me("button","cm-floating-button cm-floating-accept");s.innerHTML=`<span class="hotkey">${Vn(i.acceptEdit)}</span> Accept`,s.setAttribute("aria-label","Accept changes"),s.addEventListener("click",u=>{u.preventDefault(),u.stopPropagation(),t.focus(),Yr(t)});let c=me("button","cm-floating-button cm-floating-reject");return c.innerHTML=`<span class="hotkey">${Vn(i.rejectEdit)}</span> Reject`,c.setAttribute("aria-label","Reject changes"),c.addEventListener("click",u=>{u.preventDefault(),u.stopPropagation(),t.focus(),Qr(t)}),o.append(s,c),n.append(r,o),n}updateDOM(t,n){return!0}},bs=class extends Dn{constructor(t){super();p(this,"complete");p(this,"abortController",null);p(this,"dom",null);p(this,"input",null);p(this,"loadingContainer",null);p(this,"helpInfo",null);p(this,"inputContainer",null);p(this,"form",null);p(this,"view",null);p(this,"onKeyDown",async t=>{t.key==="Enter"&&!t.shiftKey?(t.preventDefault(),await this.handleSubmit()):t.key==="Escape"&&this.onCancel()});p(this,"onCancel",()=>{this.cleanup();let t=this.view;t&&(t.dispatch({effects:[at.of({show:!1,lineFrom:0,lineTo:0}),mt.of(!1)]}),t.focus())});p(this,"handleSubmit",async t=>{var h;let n=this.view;if(!n)return;let r=n.state.facet(St);t==null||t.stopPropagation();let o=n.state.field(it),{input:a}=this;if(!a)return;let i=a.value.trim();if(!o.show||!i)return;let s=n.state.doc.line(o.lineFrom),c=n.state.doc.line(o.lineTo),u=s.from,d=c.to,f=n.state.sliceDoc(u,d),g=n.state.sliceDoc(0,u),m=n.state.sliceDoc(d);this.abortController=new AbortController,n.dispatch({effects:mt.of(!0)}),this.toggleLoading(!0);try{let w=await this.complete({prompt:i,selection:f,codeBefore:g,codeAfter:m,editorView:n,signal:this.abortController.signal});if(!n.state.field(it).show)return;if(!w||typeof w!="string")throw Error("Invalid completion result");n.dispatch({changes:{from:u,to:d,insert:w},effects:[at.of({show:!1,lineFrom:0,lineTo:0}),qt.of({from:u,to:u+w.length,oldCode:f,newCode:w}),mt.of(!1)]})}catch(w){if(w instanceof DOMException&&w.name==="AbortError")return;(h=r.onError)==null||h.call(r,w)}finally{this.cleanup(),this.toggleLoading(!1),n.focus()}});this.complete=t}toDOM(t){if(this.dom)return this.dom;this.view=t;let n=t.state.field(zr),r=t.state.field(Kr),o=me("div","cm-ai-input-container");this.inputContainer=o,this.dom=o;let a=me("form","cm-ai-input-form");this.form=a,a.setAttribute("role","search"),a.setAttribute("aria-label","AI editing instructions"),a.addEventListener("submit",y=>y.preventDefault());let i=me("input","cm-ai-input");this.input=i,a.append(i),i.placeholder="Editing instructions...",i.setAttribute("aria-label","AI editing instructions"),i.setAttribute("autocomplete","off"),i.setAttribute("spellcheck","true"),i.value=n.inputValue;let s=me("div","cm-ai-loading-container");this.loadingContainer=s;let c=me("div","cm-ai-loading-indicator");c.setAttribute("role","status"),c.setAttribute("aria-live","polite"),c.textContent="Generating";let u=me("button","cm-ai-cancel-button");u.textContent="Cancel",u.setAttribute("aria-label","Cancel code generation"),u.addEventListener("click",this.onCancel),s.append(u,c);let d=me("div","cm-ai-help-info");this.helpInfo=d;let f=d.appendChild(document.createElement("button"));f.className="cm-ai-help-info-button",f.textContent="Esc to close",f.addEventListener("click",this.onCancel);let g=me("button","cm-ai-generate-button");g.textContent="\u23CE Generate",g.setAttribute("aria-label","Generate code"),g.addEventListener("click",this.handleSubmit),this.toggleLoading(r),n.shouldFocus&&requestAnimationFrame(()=>{i.value=n.inputValue,i.focus(),t.dispatch({effects:It.of(!1)})}),m(i.value),i.addEventListener("input",w),i.addEventListener("keydown",this.onKeyDown);function m(y){d.replaceChildren(y?g:f)}let h="";function w(){t.dispatch({effects:xt.of(i.value)});let y=i.value.trim();y!==h&&(h=y,m(y))}return o}toggleLoading(t){var n;this.inputContainer&&this.form&&this.loadingContainer&&this.helpInfo&&((n=this.inputContainer)==null||n.replaceChildren(this.form,t?this.loadingContainer:this.helpInfo))}updateDOM(t,n){return this.dom=t,this.input=t.querySelector(".cm-ai-input"),!0}cleanup(){var t,n,r;(t=this.abortController)==null||t.abort(),this.abortController=null,(n=this.dom)==null||n.remove(),(r=this.input)==null||r.remove(),this.dom=null,this.input=null}destroy(){this.cleanup()}};function ys(e){if(!e.prompt)throw Error("prompt function is required");let t={...H,...e.keymaps};return[St.of(e),it,zr,At,Kr,gs(),ds,He.of([{key:t.showInput,run:Xr}]),dt.highest([He.of([{key:t.acceptEdit,run:Yr},{key:t.rejectEdit,run:Qr}])]),ws,vs,Es,Ns]}const ws=M.updateListener.of(e=>{let t=e.state.field(it);if(!t.show||!e.docChanged)return;let{lineFrom:n,lineTo:r}=t,o=!1;e.changes.iterChanges((a,i,s,c)=>{let u=e.state.doc.lineAt(a).number;if(u<n){let d=e.state.doc.lineAt(c).number-e.state.doc.lineAt(s).number;n+=d,r+=d,o=!0}else if(u<=r){let d=e.state.doc.lineAt(c).number-e.state.doc.lineAt(s).number;r+=d,o=!0}}),o&&e.view.dispatch({effects:[at.of({show:!0,lineFrom:n,lineTo:r})]})}),vs=M.decorations.of(e=>{let t=e.state.field(At);return t?$.set([$.mark({class:"cm-new-code-line"}).range(t.from,t.to)]):$.none}),Es=M.decorations.compute([it],e=>{let t=e.field(it),n=e.facet(St),r=[];if(t.show){let o=t.lineFrom,a=t.lineTo;for(let i=o;i<=a;i++){let s=e.doc.line(i).from;r.push($.line({class:"cm-ai-selection"}).range(s)),i===o&&r.push($.widget({widget:new bs(n.prompt),side:-1}).range(s))}}return $.set(r)}),Ns=Xe.define({create(e){return $.none},update(e,t){let n=t.state.field(At);return n?$.set([$.widget({widget:new hs(n.oldCode),block:!0}).range(n.from)]):$.none},provide:e=>M.decorations.from(e)});var ks=ve(),A=qa(_d(),1),Hn=()=>({entries:new Map}),{valueAtom:to,useActions:no}=jr(Hn,{submit:(e,t)=>{let{cellIds:n,deleteCell:r,deleteManyCells:o,store:a}=t,i=a.get(ot),s=a.get(hf),c=new Set(i.cellIds.inOrderIds.filter(f=>i.cellData[f].code.trim()==="")),u=new Map;for(let f of n){if(c.has(f)){u.set(f,{cellId:f,type:"simple"});continue}let g=i.cellRuntime[f],m=new Map;for(let w of Object.values(s)){let y=w.declaredBy.includes(f),v=w.usedBy.some(C=>!c.has(C));y&&v&&m.set(w.name,w.usedBy)}let h;g!=null&&g.runElapsedTimeMs&&g.runElapsedTimeMs>2e3&&(h=g.runElapsedTimeMs),m.size===0&&h===void 0?u.set(f,{cellId:f,type:"simple"}):u.set(f,{cellId:f,type:"expensive",executionDurationMs:h,defs:m})}let d=[...u.values()].every(f=>f.type==="simple");return u.size>0&&d?(u.size===1?r({cellId:[...u.values()][0].cellId}):o({cellIds:[...u.values()].map(f=>f.cellId)}),Hn()):{...e,entries:u}},clear:()=>Hn()});Mn=function(){let e=kr(),{submit:t,clear:n}=no(),{entries:r}=ie(to),o=xi(),a=Mr();return(0,A.useMemo)(()=>({submit:i=>{t({cellIds:i,deleteCell:o,deleteManyCells:a,store:e})},clear:n,get idle(){return r.size===0},get shouldConfirmDelete(){return r.size>1}}),[e,t,n,r,o,a])},Zi=function(e){let t=(0,ks.c)(16),n=ie(to),r=no(),o=Mr(),a;t[0]!==e||t[1]!==n.entries?(a=n.entries.get(e),t[0]=e,t[1]=n.entries,t[2]=a):a=t[2];let i=a;if(!i){let d;return t[3]===Symbol.for("react.memo_cache_sentinel")?(d={isPending:!1},t[3]=d):d=t[3],d}if(n.entries.size!==1){let d;return t[4]===i?d=t[5]:(d={isPending:!0,shouldConfirmDelete:!1,...i},t[4]=i,t[5]=d),d}let s;t[6]!==r||t[7]!==o||t[8]!==n.entries?(s=()=>{o({cellIds:[...n.entries.values()].map(Cs)}),r.clear()},t[6]=r,t[7]=o,t[8]=n.entries,t[9]=s):s=t[9];let c;t[10]===r?c=t[11]:(c=()=>r.clear(),t[10]=r,t[11]=c);let u;return t[12]!==i||t[13]!==s||t[14]!==c?(u={isPending:!0,...i,shouldConfirmDelete:!0,confirm:s,cancel:c},t[12]=i,t[13]=s,t[14]=c,t[15]=u):u=t[15],u};function Cs(e){return e.cellId}var ro=["python","sql","markdown"];function qn(e,t={}){var u;let{streaming:n=!1}=t,r=((u=e.match(/^\s*/))==null?void 0:u[0])??"",o=e.slice(r.length),a=null,i=!1;for(let d of ro)if(o.startsWith(`\`\`\`${d}`)){i=!0,a=o.slice(3+d.length),a.startsWith(`
4
4
  `)&&(a=a.slice(1));break}if(!i&&o.startsWith("```")){let d=o.slice(3);if(n&&Ss(d))return e;i=!0,a=d,a.startsWith(`
5
5
  `)&&(a=a.slice(1))}if(!i||a===null)return e;if(n)return a;let s=a.trimEnd(),c=a.slice(s.length);return s.endsWith("\n```")?s.slice(0,-4)+c:s.endsWith("```")?s.slice(0,-3)+c:a}function Ss(e){return e.includes(`
@@ -1 +1 @@
1
- import{s as D}from"./chunk-LvLJmgfZ.js";import{u as F}from"./useEvent-D91BmmQi.js";import{t as R}from"./react-Bj1aDYRI.js";import{D as U,Jr as G,Ur as H,qr as I}from"./cells-a44D37GV.js";import{t as K}from"./compiler-runtime-B3qBwwSJ.js";import{c as V}from"./utils-BGFUZat2.js";import{t as W}from"./jsx-runtime-PbYoItBR.js";import{c as X,d as Y,gt as Z}from"./JsonOutput-BP1BF3ok.js";import{t as L}from"./tooltip-CWSr2PfE.js";import{r as A,t as q}from"./button-Db07tdz7.js";import{r as $}from"./requests-KshNNAOp.js";import{t as ee}from"./createLucideIcon-BTp1tQDO.js";import{t as te}from"./useLifecycle-Baf35rp4.js";import{t as ae}from"./spinner-BlJOg2gb.js";import{r as re}from"./useTheme-BcDiZbxe.js";import{t as se}from"./copy-icon-C8Cq0-V0.js";import{t as oe}from"./context-DE_5rdOV.js";import{i as ne}from"./numbers-BVh5side.js";import{n as ce}from"./html-to-image-B6hPo7Eh.js";import{o as le}from"./focus-Ptvt4Jk-.js";var P=ee("square-plus",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]),M=K(),ie=D(R(),1),s=D(W(),1);const me=i=>{let e=(0,M.c)(53),{table:t,column:a,preview:r,onAddColumnChart:c,sqlTableContext:n}=i,{theme:u}=re(),{previewDatasetColumn:l}=$(),{locale:d}=oe(),m;e[0]!==a.name||e[1]!==l||e[2]!==n||e[3]!==t.name||e[4]!==t.source||e[5]!==t.source_type?(m=()=>{l({source:t.source,tableName:t.name,columnName:a.name,sourceType:t.source_type,fullyQualifiedTableName:G(n,t.name)})},e[0]=a.name,e[1]=l,e[2]=n,e[3]=t.name,e[4]=t.source,e[5]=t.source_type,e[6]=m):m=e[6];let p=m,h;if(e[7]!==r||e[8]!==p||e[9]!==t.source_type?(h=()=>{r||t.source_type==="connection"||t.source_type==="catalog"||p()},e[7]=r,e[8]=p,e[9]=t.source_type,e[10]=h):h=e[10],te(h),t.source_type==="connection"){let o=a.name,E=a.external_type,x;e[11]!==a.name||e[12]!==c||e[13]!==n||e[14]!==t?(x=A.stopPropagation(()=>{c(I({table:t,columnName:a.name,sqlTableContext:n}))}),e[11]=a.name,e[12]=c,e[13]=n,e[14]=t,e[15]=x):x=e[15];let C;e[16]===Symbol.for("react.memo_cache_sentinel")?(C=(0,s.jsx)(P,{className:"h-3 w-3 mr-1"}),e[16]=C):C=e[16];let f;e[17]===x?f=e[18]:(f=(0,s.jsxs)(q,{variant:"outline",size:"xs",onClick:x,children:[C," Add SQL cell"]}),e[17]=x,e[18]=f);let S;return e[19]!==a.external_type||e[20]!==a.name||e[21]!==f?(S=(0,s.jsxs)("span",{className:"text-xs text-muted-foreground gap-2 flex items-center justify-between pl-7",children:[o," (",E,")",f]}),e[19]=a.external_type,e[20]=a.name,e[21]=f,e[22]=S):S=e[22],S}if(t.source_type==="catalog"){let o;return e[23]!==a.external_type||e[24]!==a.name?(o=(0,s.jsxs)("span",{className:"text-xs text-muted-foreground gap-2 flex items-center justify-between pl-7",children:[a.name," (",a.external_type,")"]}),e[23]=a.external_type,e[24]=a.name,e[25]=o):o=e[25],o}if(!r){let o;return e[26]===Symbol.for("react.memo_cache_sentinel")?(o=(0,s.jsx)("span",{className:"text-xs text-muted-foreground",children:"Loading..."}),e[26]=o):o=e[26],o}let g;e[27]!==r.error||e[28]!==r.missing_packages||e[29]!==p?(g=r.error&&O({error:r.error,missingPackages:r.missing_packages,refetchPreview:p}),e[27]=r.error,e[28]=r.missing_packages,e[29]=p,e[30]=g):g=e[30];let y=g,_;e[31]!==a.type||e[32]!==d||e[33]!==r.stats?(_=r.stats&&Q({stats:r.stats,dataType:a.type,locale:d}),e[31]=a.type,e[32]=d,e[33]=r.stats,e[34]=_):_=e[34];let b=_,j;e[35]!==r.chart_spec||e[36]!==u?(j=r.chart_spec&&J(r.chart_spec,u),e[35]=r.chart_spec,e[36]=u,e[37]=j):j=e[37];let N=j,k;e[38]!==r.chart_code||e[39]!==t.source_type?(k=r.chart_code&&t.source_type==="local"&&(0,s.jsx)(B,{chartCode:r.chart_code}),e[38]=r.chart_code,e[39]=t.source_type,e[40]=k):k=e[40];let T=k,w;e[41]!==a.name||e[42]!==c||e[43]!==n||e[44]!==t?(w=t.source_type==="duckdb"&&(0,s.jsx)(L,{content:"Add SQL cell",delayDuration:400,children:(0,s.jsx)(q,{variant:"outline",size:"icon",className:"z-10 bg-background absolute right-1 -top-1",onClick:A.stopPropagation(()=>{c(I({table:t,columnName:a.name,sqlTableContext:n}))}),children:(0,s.jsx)(P,{className:"h-3 w-3"})})}),e[41]=a.name,e[42]=c,e[43]=n,e[44]=t,e[45]=w):w=e[45];let z=w;if(!y&&!b&&!N){let o;return e[46]===Symbol.for("react.memo_cache_sentinel")?(o=(0,s.jsx)("span",{className:"text-xs text-muted-foreground",children:"No data"}),e[46]=o):o=e[46],o}let v;return e[47]!==T||e[48]!==z||e[49]!==N||e[50]!==y||e[51]!==b?(v=(0,s.jsxs)(Y,{children:[y,T,z,N,b]}),e[47]=T,e[48]=z,e[49]=N,e[50]=y,e[51]=b,e[52]=v):v=e[52],v};function O({error:i,missingPackages:e,refetchPreview:t}){return(0,s.jsxs)("div",{className:"text-xs text-muted-foreground p-2 border border-border rounded flex items-center justify-between",children:[(0,s.jsx)("span",{children:i}),e&&(0,s.jsx)(X,{packages:e,showMaxPackages:1,className:"w-32",onInstall:t})]})}function Q({stats:i,dataType:e,locale:t}){return(0,s.jsx)("div",{className:"gap-x-16 gap-y-1 grid grid-cols-2-fit border rounded p-2 empty:hidden",children:Object.entries(i).map(([a,r])=>r==null?null:(0,s.jsxs)("div",{className:"flex items-center gap-1 group",children:[(0,s.jsx)("span",{className:"text-xs min-w-[60px] capitalize",children:H(a,e)}),(0,s.jsx)("span",{className:"text-xs font-bold text-muted-foreground tracking-wide",children:ne(r,t)}),(0,s.jsx)(se,{className:"h-3 w-3 invisible group-hover:visible",value:String(r)})]},a))})}var pe=(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsx)(ae,{className:"size-4"})});function J(i,e){let t=a=>({...a,background:"transparent",config:{...a.config,background:"transparent"}});return(0,s.jsx)(ie.Suspense,{fallback:pe,children:(0,s.jsx)(Z,{"data-container-width":"container",spec:t(JSON.parse(i)),options:{theme:e==="dark"?"dark":"vox",height:100,width:"container",actions:!1,renderer:"canvas"}})})}const B=i=>{let e=(0,M.c)(10),{chartCode:t}=i,a=F(V),r=le(),{createNewCell:c}=U(),n;e[0]!==a||e[1]!==c||e[2]!==r?(n=p=>{p.includes("alt")&&ce({autoInstantiate:a,createNewCell:c,fromCellId:r}),c({code:p,before:!1,cellId:r??"__end__"})},e[0]=a,e[1]=c,e[2]=r,e[3]=n):n=e[3];let u=n,l;e[4]!==t||e[5]!==u?(l=A.stopPropagation(()=>u(t)),e[4]=t,e[5]=u,e[6]=l):l=e[6];let d;e[7]===Symbol.for("react.memo_cache_sentinel")?(d=(0,s.jsx)(P,{className:"h-3 w-3"}),e[7]=d):d=e[7];let m;return e[8]===l?m=e[9]:(m=(0,s.jsx)(L,{content:"Add chart to notebook",delayDuration:400,children:(0,s.jsx)(q,{variant:"outline",size:"icon",className:"z-10 bg-background absolute right-1 -top-0.5",onClick:l,children:d})}),e[8]=l,e[9]=m),m};export{Q as a,O as i,me as n,P as o,J as r,B as t};
1
+ import{s as D}from"./chunk-LvLJmgfZ.js";import{u as F}from"./useEvent-D91BmmQi.js";import{t as R}from"./react-Bj1aDYRI.js";import{D as U,Jr as G,Ur as H,qr as I}from"./cells-a44D37GV.js";import{t as K}from"./compiler-runtime-B3qBwwSJ.js";import{c as V}from"./utils-BGFUZat2.js";import{t as W}from"./jsx-runtime-PbYoItBR.js";import{c as X,d as Y,gt as Z}from"./JsonOutput-BgU0YoWq.js";import{t as L}from"./tooltip-CWSr2PfE.js";import{r as A,t as q}from"./button-Db07tdz7.js";import{r as $}from"./requests-KshNNAOp.js";import{t as ee}from"./createLucideIcon-BTp1tQDO.js";import{t as te}from"./useLifecycle-Baf35rp4.js";import{t as ae}from"./spinner-BlJOg2gb.js";import{r as re}from"./useTheme-BcDiZbxe.js";import{t as se}from"./copy-icon-C8Cq0-V0.js";import{t as oe}from"./context-DE_5rdOV.js";import{i as ne}from"./numbers-BVh5side.js";import{n as ce}from"./html-to-image-B6hPo7Eh.js";import{o as le}from"./focus-Ptvt4Jk-.js";var P=ee("square-plus",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]),M=K(),ie=D(R(),1),s=D(W(),1);const me=i=>{let e=(0,M.c)(53),{table:t,column:a,preview:r,onAddColumnChart:c,sqlTableContext:n}=i,{theme:u}=re(),{previewDatasetColumn:l}=$(),{locale:d}=oe(),m;e[0]!==a.name||e[1]!==l||e[2]!==n||e[3]!==t.name||e[4]!==t.source||e[5]!==t.source_type?(m=()=>{l({source:t.source,tableName:t.name,columnName:a.name,sourceType:t.source_type,fullyQualifiedTableName:G(n,t.name)})},e[0]=a.name,e[1]=l,e[2]=n,e[3]=t.name,e[4]=t.source,e[5]=t.source_type,e[6]=m):m=e[6];let p=m,h;if(e[7]!==r||e[8]!==p||e[9]!==t.source_type?(h=()=>{r||t.source_type==="connection"||t.source_type==="catalog"||p()},e[7]=r,e[8]=p,e[9]=t.source_type,e[10]=h):h=e[10],te(h),t.source_type==="connection"){let o=a.name,E=a.external_type,x;e[11]!==a.name||e[12]!==c||e[13]!==n||e[14]!==t?(x=A.stopPropagation(()=>{c(I({table:t,columnName:a.name,sqlTableContext:n}))}),e[11]=a.name,e[12]=c,e[13]=n,e[14]=t,e[15]=x):x=e[15];let C;e[16]===Symbol.for("react.memo_cache_sentinel")?(C=(0,s.jsx)(P,{className:"h-3 w-3 mr-1"}),e[16]=C):C=e[16];let f;e[17]===x?f=e[18]:(f=(0,s.jsxs)(q,{variant:"outline",size:"xs",onClick:x,children:[C," Add SQL cell"]}),e[17]=x,e[18]=f);let S;return e[19]!==a.external_type||e[20]!==a.name||e[21]!==f?(S=(0,s.jsxs)("span",{className:"text-xs text-muted-foreground gap-2 flex items-center justify-between pl-7",children:[o," (",E,")",f]}),e[19]=a.external_type,e[20]=a.name,e[21]=f,e[22]=S):S=e[22],S}if(t.source_type==="catalog"){let o;return e[23]!==a.external_type||e[24]!==a.name?(o=(0,s.jsxs)("span",{className:"text-xs text-muted-foreground gap-2 flex items-center justify-between pl-7",children:[a.name," (",a.external_type,")"]}),e[23]=a.external_type,e[24]=a.name,e[25]=o):o=e[25],o}if(!r){let o;return e[26]===Symbol.for("react.memo_cache_sentinel")?(o=(0,s.jsx)("span",{className:"text-xs text-muted-foreground",children:"Loading..."}),e[26]=o):o=e[26],o}let g;e[27]!==r.error||e[28]!==r.missing_packages||e[29]!==p?(g=r.error&&O({error:r.error,missingPackages:r.missing_packages,refetchPreview:p}),e[27]=r.error,e[28]=r.missing_packages,e[29]=p,e[30]=g):g=e[30];let y=g,_;e[31]!==a.type||e[32]!==d||e[33]!==r.stats?(_=r.stats&&Q({stats:r.stats,dataType:a.type,locale:d}),e[31]=a.type,e[32]=d,e[33]=r.stats,e[34]=_):_=e[34];let b=_,j;e[35]!==r.chart_spec||e[36]!==u?(j=r.chart_spec&&J(r.chart_spec,u),e[35]=r.chart_spec,e[36]=u,e[37]=j):j=e[37];let N=j,k;e[38]!==r.chart_code||e[39]!==t.source_type?(k=r.chart_code&&t.source_type==="local"&&(0,s.jsx)(B,{chartCode:r.chart_code}),e[38]=r.chart_code,e[39]=t.source_type,e[40]=k):k=e[40];let T=k,w;e[41]!==a.name||e[42]!==c||e[43]!==n||e[44]!==t?(w=t.source_type==="duckdb"&&(0,s.jsx)(L,{content:"Add SQL cell",delayDuration:400,children:(0,s.jsx)(q,{variant:"outline",size:"icon",className:"z-10 bg-background absolute right-1 -top-1",onClick:A.stopPropagation(()=>{c(I({table:t,columnName:a.name,sqlTableContext:n}))}),children:(0,s.jsx)(P,{className:"h-3 w-3"})})}),e[41]=a.name,e[42]=c,e[43]=n,e[44]=t,e[45]=w):w=e[45];let z=w;if(!y&&!b&&!N){let o;return e[46]===Symbol.for("react.memo_cache_sentinel")?(o=(0,s.jsx)("span",{className:"text-xs text-muted-foreground",children:"No data"}),e[46]=o):o=e[46],o}let v;return e[47]!==T||e[48]!==z||e[49]!==N||e[50]!==y||e[51]!==b?(v=(0,s.jsxs)(Y,{children:[y,T,z,N,b]}),e[47]=T,e[48]=z,e[49]=N,e[50]=y,e[51]=b,e[52]=v):v=e[52],v};function O({error:i,missingPackages:e,refetchPreview:t}){return(0,s.jsxs)("div",{className:"text-xs text-muted-foreground p-2 border border-border rounded flex items-center justify-between",children:[(0,s.jsx)("span",{children:i}),e&&(0,s.jsx)(X,{packages:e,showMaxPackages:1,className:"w-32",onInstall:t})]})}function Q({stats:i,dataType:e,locale:t}){return(0,s.jsx)("div",{className:"gap-x-16 gap-y-1 grid grid-cols-2-fit border rounded p-2 empty:hidden",children:Object.entries(i).map(([a,r])=>r==null?null:(0,s.jsxs)("div",{className:"flex items-center gap-1 group",children:[(0,s.jsx)("span",{className:"text-xs min-w-[60px] capitalize",children:H(a,e)}),(0,s.jsx)("span",{className:"text-xs font-bold text-muted-foreground tracking-wide",children:ne(r,t)}),(0,s.jsx)(se,{className:"h-3 w-3 invisible group-hover:visible",value:String(r)})]},a))})}var pe=(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsx)(ae,{className:"size-4"})});function J(i,e){let t=a=>({...a,background:"transparent",config:{...a.config,background:"transparent"}});return(0,s.jsx)(ie.Suspense,{fallback:pe,children:(0,s.jsx)(Z,{"data-container-width":"container",spec:t(JSON.parse(i)),options:{theme:e==="dark"?"dark":"vox",height:100,width:"container",actions:!1,renderer:"canvas"}})})}const B=i=>{let e=(0,M.c)(10),{chartCode:t}=i,a=F(V),r=le(),{createNewCell:c}=U(),n;e[0]!==a||e[1]!==c||e[2]!==r?(n=p=>{p.includes("alt")&&ce({autoInstantiate:a,createNewCell:c,fromCellId:r}),c({code:p,before:!1,cellId:r??"__end__"})},e[0]=a,e[1]=c,e[2]=r,e[3]=n):n=e[3];let u=n,l;e[4]!==t||e[5]!==u?(l=A.stopPropagation(()=>u(t)),e[4]=t,e[5]=u,e[6]=l):l=e[6];let d;e[7]===Symbol.for("react.memo_cache_sentinel")?(d=(0,s.jsx)(P,{className:"h-3 w-3"}),e[7]=d):d=e[7];let m;return e[8]===l?m=e[9]:(m=(0,s.jsx)(L,{content:"Add chart to notebook",delayDuration:400,children:(0,s.jsx)(q,{variant:"outline",size:"icon",className:"z-10 bg-background absolute right-1 -top-0.5",onClick:l,children:d})}),e[8]=l,e[9]=m),m};export{Q as a,O as i,me as n,P as o,J as r,B as t};
@@ -1 +1 @@
1
- import{s as U}from"./chunk-LvLJmgfZ.js";import{l as X,u as V}from"./useEvent-D91BmmQi.js";import{t as Y}from"./react-Bj1aDYRI.js";import{Ei as Z}from"./cells-a44D37GV.js";import"./react-dom-CSu739Rf.js";import{t as O}from"./compiler-runtime-B3qBwwSJ.js";import{S as ee}from"./ai-model-dropdown-BUVX-tXn.js";import{d as le,h as te,t as ie,u as ae}from"./useEventListener-BfYriKqt.js";import{b as oe,h as ne,x as re}from"./utils-BGFUZat2.js";import{t as de}from"./jsx-runtime-PbYoItBR.js";import"./fullscreen-6ovMHcQN.js";import"./popover-D1IutFqN.js";import"./JsonOutput-BP1BF3ok.js";import"./download-YFYBUFlh.js";import"./dist-Dez1I5M9.js";import"./cjs-DXo9vDEJ.js";import"./main-DmhaVp6Y.js";import"./useNonce-0SWz6w4W.js";import{r as se}from"./requests-KshNNAOp.js";import"./layout-B093uDWH.js";import{t as pe}from"./useCellActionButton-B8YCBRJi.js";import"./markdown-renderer-DhkuKp0Y.js";import{i as me,t as he}from"./useNotebookActions-3Vk8OfKI.js";import"./dist-DHMtQYxT.js";import"./dist-Bj9Iedc0.js";import"./dist-D-o1OXc9.js";import"./dist-BZhJ1bTM.js";import"./dist-DnIl7RU-.js";import"./session-DF0gSADo.js";import"./purify.es-DdxMtdqK.js";import"./dates-Digd3pPR.js";import{n as ce}from"./useHotkey-Dg_dwRCE.js";import"./share-CDUcBp99.js";import"./utils-TBIUapDT.js";import"./vega-loader.browser-BJ9oKrvH.js";import"./defaultLocale-CuYNS33t.js";import"./defaultLocale-CGfP-Ye3.js";import"./chunk-5FQGJX7Z-D-AUn5sP.js";import"./html-to-image-B6hPo7Eh.js";import{r as ye}from"./focus-Ptvt4Jk-.js";import"./react-resizable-panels.browser.esm-CgWOEYeG.js";import{a as ue,c as fe,i as L,l as z,n as be,o as J,r as ge,s as ke}from"./command-Dzjey1r-.js";import{t as Q}from"./renderShortcut-BV7Qf4L2.js";import"./esm-DSv-aO_T.js";import"./name-cell-input-mLsE_Em-.js";import"./multi-icon-CvhGPe8t.js";import"./dist-BrSPXZRF.js";import"./dist-6Nc6OWsm.js";import"./dist-zuEISlEm.js";import"./dist-BUZOkWVK.js";import"./dist-D4sM9Hux.js";import"./dist-BMVtDS2X.js";import"./dist-teiEd76o.js";import"./dist-fRNNW4KX.js";import"./dist-CdqhtJoV.js";import"./esm-j1_GHh6X.js";var we=O(),Ce=U(Y(),1);function xe(e,l){let t=(0,we.c)(11),r;t[0]===l?r=t[1]:(r=new Z(l),t[0]=l,t[1]=r);let d=r,n;t[2]!==e||t[3]!==d?(n=()=>d.get(e),t[2]=e,t[3]=d,t[4]=n):n=t[4];let[m,k]=(0,Ce.useState)(n),i;t[5]!==e||t[6]!==d?(i=w=>{k(w),d.set(e,w)},t[5]=e,t[6]=d,t[7]=i):i=t[7];let u=i,h;return t[8]!==u||t[9]!==m?(h=[m,u],t[8]=u,t[9]=m,t[10]=h):h=t[10],h}var je=O(),Se=3;function ve(){let e=(0,je.c)(7),l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=[],e[0]=l):l=e[0];let[t,r]=xe("marimo:commands",l),d;e[1]!==t||e[2]!==r?(d=m=>{r(_e([m,...t]).slice(0,Se))},e[1]=t,e[2]=r,e[3]=d):d=e[3];let n;return e[4]!==t||e[5]!==d?(n={recentCommands:t,addRecentCommand:d},e[4]=t,e[5]=d,e[6]=n):n=e[6],n}function _e(e){return[...new Set(e)]}function W(e){return e.dropdown!==void 0}function T(e,l=""){return e.flatMap(t=>t.label?W(t)?T(t.dropdown,`${l+t.label} > `):{...t,label:l+t.label,additionalKeywords:t.additionalKeywords}:[])}var Ke=O();function He(){let e=(0,Ke.c)(75),[l,t]=re(),[r,d]=oe(),{saveAppConfig:n,saveUserConfig:m}=se(),k;e[0]!==m||e[1]!==t?(k=async p=>{await m({config:p}).then(()=>{t(c=>({...c,...p}))})},e[0]=m,e[1]=t,e[2]=k):k=e[2];let i=k,u;e[3]!==n||e[4]!==d?(u=async p=>{await n({config:p}).then(()=>{d(p)})},e[3]=n,e[4]=d,e[5]=u):u=e[5];let h=u,w;if(e[6]!==r||e[7]!==l.completion||e[8]!==l.display||e[9]!==l.keymap||e[10]!==h||e[11]!==i){let p;e[13]===r?p=e[14]:(p=B=>B!==r.width,e[13]=r,e[14]=p);let c;e[15]!==r||e[16]!==h?(c=B=>({label:`App config > Set width=${B}`,handle:()=>{h({...r,width:B})}}),e[15]=r,e[16]=h,e[17]=c):c=e[17];let K;e[18]!==l.display||e[19]!==i?(K={label:"Config > Set theme: dark",handle:()=>{i({display:{...l.display,theme:"dark"}})}},e[18]=l.display,e[19]=i,e[20]=K):K=e[20];let C;e[21]!==l.display||e[22]!==i?(C={label:"Config > Set theme: light",handle:()=>{i({display:{...l.display,theme:"light"}})}},e[21]=l.display,e[22]=i,e[23]=C):C=e[23];let H;e[24]!==l.display||e[25]!==i?(H={label:"Config > Set theme: system",handle:()=>{i({display:{...l.display,theme:"system"}})}},e[24]=l.display,e[25]=i,e[26]=H):H=e[26];let R=l.keymap.preset==="vim",A;e[27]!==l.keymap||e[28]!==i?(A=()=>{i({keymap:{...l.keymap,preset:"vim"}})},e[27]=l.keymap,e[28]=i,e[29]=A):A=e[29];let M;e[30]!==R||e[31]!==A?(M={label:"Config > Switch keymap to VIM",hidden:R,handle:A},e[30]=R,e[31]=A,e[32]=M):M=e[32];let N=l.keymap.preset==="default",x;e[33]!==l.keymap||e[34]!==i?(x=()=>{i({keymap:{...l.keymap,preset:"default"}})},e[33]=l.keymap,e[34]=i,e[35]=x):x=e[35];let f;e[36]!==N||e[37]!==x?(f={label:"Config > Switch keymap to default (current: VIM)",hidden:N,handle:x},e[36]=N,e[37]=x,e[38]=f):f=e[38];let j;e[39]!==l.completion||e[40]!==i?(j=()=>{i({completion:{...l.completion,copilot:!1}})},e[39]=l.completion,e[40]=i,e[41]=j):j=e[41];let S=l.completion.copilot!=="github",P;e[42]!==j||e[43]!==S?(P={label:"Config > Disable GitHub Copilot",handle:j,hidden:S},e[42]=j,e[43]=S,e[44]=P):P=e[44];let v;e[45]!==l.completion||e[46]!==i?(v=()=>{i({completion:{...l.completion,copilot:"github"}})},e[45]=l.completion,e[46]=i,e[47]=v):v=e[47];let G=l.completion.copilot==="github",$;e[48]!==v||e[49]!==G?($={label:"Config > Enable GitHub Copilot",handle:v,hidden:G},e[48]=v,e[49]=G,e[50]=$):$=e[50];let q=!l.display.reference_highlighting,_;e[51]!==l.display||e[52]!==i?(_=()=>{i({display:{...l.display,reference_highlighting:!1}})},e[51]=l.display,e[52]=i,e[53]=_):_=e[53];let b;e[54]!==q||e[55]!==_?(b={label:"Config > Disable reference highlighting",hidden:q,handle:_},e[54]=q,e[55]=_,e[56]=b):b=e[56];let y;e[57]!==l.display||e[58]!==i?(y=()=>{i({display:{...l.display,reference_highlighting:!0}})},e[57]=l.display,e[58]=i,e[59]=y):y=e[59];let D;e[60]!==l.display.reference_highlighting||e[61]!==y?(D={label:"Config > Enable reference highlighting",hidden:l.display.reference_highlighting,handle:y},e[60]=l.display.reference_highlighting,e[61]=y,e[62]=D):D=e[62];let a=l.display.cell_output==="above",o;e[63]!==l.display||e[64]!==i?(o=()=>{i({display:{...l.display,cell_output:"above"}})},e[63]=l.display,e[64]=i,e[65]=o):o=e[65];let E;e[66]!==a||e[67]!==o?(E={label:"Config > Set cell output area: above",hidden:a,handle:o},e[66]=a,e[67]=o,e[68]=E):E=e[68];let g=l.display.cell_output==="below",F;e[69]!==l.display||e[70]!==i?(F=()=>{i({display:{...l.display,cell_output:"below"}})},e[69]=l.display,e[70]=i,e[71]=F):F=e[71];let I;e[72]!==g||e[73]!==F?(I={label:"Config > Set cell output area: below",hidden:g,handle:F},e[72]=g,e[73]=F,e[74]=I):I=e[74],w=[...ee().filter(p).map(c),K,C,H,M,f,P,$,b,D,E,I].filter(Ae),e[6]=r,e[7]=l.completion,e[8]=l.display,e[9]=l.keymap,e[10]=h,e[11]=i,e[12]=w}else w=e[12];return w}function Ae(e){return!e.hidden}var Me=O(),s=U(de(),1),Ne=()=>{let e=(0,Me.c)(37),[l,t]=X(me),r=ce(),d=V(ye),n=V(ne),m;e[0]===d?m=e[1]:(m={cell:d},e[0]=d,e[1]=m);let k=pe(m).flat();k=T(k);let i=He(),u=he();u=[...T(u),...T(i)];let h=u.filter(De),w=le.keyBy(h,Ee),{recentCommands:p,addRecentCommand:c}=ve(),K;e[2]===p?K=e[3]:(K=new Set(p),e[2]=p,e[3]=K);let C=K,H;e[4]!==n||e[5]!==t?(H=a=>{te(n.getHotkey("global.commandPalette").key)(a)&&(a.preventDefault(),t(Fe))},e[4]=n,e[5]=t,e[6]=H):H=e[6],ie(document,"keydown",H);let R;e[7]!==c||e[8]!==n||e[9]!==r||e[10]!==t?(R=(a,o)=>{let E=r[a];if(!E)return null;let g=n.getHotkey(a);return(0,s.jsxs)(J,{disabled:o.disabled,keywords:g.additionalKeywords,onSelect:()=>{c(a),t(!1),requestAnimationFrame(()=>{E()})},value:g.name,children:[(0,s.jsxs)("span",{children:[g.name,o.tooltip&&(0,s.jsx)("span",{className:"ml-2",children:o.tooltip})]}),(0,s.jsx)(z,{children:(0,s.jsx)(Q,{shortcut:g.key})})]},a)},e[7]=c,e[8]=n,e[9]=r,e[10]=t,e[11]=R):R=e[11];let A=R,M;e[12]!==c||e[13]!==n||e[14]!==t?(M=a=>{let{label:o,handle:E,props:g,hotkey:F,additionalKeywords:I}=a,B=g===void 0?{}:g;return(0,s.jsxs)(J,{disabled:B.disabled,keywords:I,onSelect:()=>{c(o),t(!1),requestAnimationFrame(()=>{E()})},value:o,children:[(0,s.jsxs)("span",{children:[o,B.tooltip&&(0,s.jsxs)("span",{className:"ml-2",children:["(",B.tooltip,")"]})]}),F&&(0,s.jsx)(z,{children:(0,s.jsx)(Q,{shortcut:n.getHotkey(F).key})})]},o)},e[12]=c,e[13]=n,e[14]=t,e[15]=M):M=e[15];let N=M,x=be,f;e[16]===Symbol.for("react.memo_cache_sentinel")?(f=(0,s.jsx)(ue,{placeholder:"Type to search..."}),e[16]=f):f=e[16];let j=ke,S;e[17]===Symbol.for("react.memo_cache_sentinel")?(S=(0,s.jsx)(ge,{children:"No results found."}),e[17]=S):S=e[17];let P=p.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(L,{heading:"Recently Used",children:p.map(a=>{let o=w[a];return ae(a)?A(a,{disabled:o==null?void 0:o.disabled,tooltip:o==null?void 0:o.tooltip}):o&&!W(o)?N({label:o.label,handle:o.handleHeadless||o.handle,props:{disabled:o.disabled,tooltip:o.tooltip},additionalKeywords:o.additionalKeywords}):null})}),(0,s.jsx)(fe,{})]}),v=L,G=n.iterate().map(a=>{if(C.has(a))return null;let o=w[a];return A(a,{disabled:o==null?void 0:o.disabled,tooltip:o==null?void 0:o.tooltip})}),$=h.map(a=>C.has(a.label)?null:N({label:a.label,handle:a.handleHeadless||a.handle,props:{disabled:a.disabled,tooltip:a.tooltip},additionalKeywords:a.additionalKeywords})),q;e[18]!==C||e[19]!==N?(q=a=>C.has(a.label)?null:N({label:`Cell > ${a.label}`,handle:a.handleHeadless||a.handle,props:{disabled:a.disabled,tooltip:a.tooltip},additionalKeywords:a.additionalKeywords}),e[18]=C,e[19]=N,e[20]=q):q=e[20];let _=k.map(q),b;e[21]!==v||e[22]!==$||e[23]!==_||e[24]!==G?(b=(0,s.jsxs)(v,{heading:"Commands",children:[G,$,_]}),e[21]=v,e[22]=$,e[23]=_,e[24]=G,e[25]=b):b=e[25];let y;e[26]!==j||e[27]!==b||e[28]!==S||e[29]!==P?(y=(0,s.jsxs)(j,{children:[S,P,b]}),e[26]=j,e[27]=b,e[28]=S,e[29]=P,e[30]=y):y=e[30];let D;return e[31]!==x||e[32]!==l||e[33]!==t||e[34]!==y||e[35]!==f?(D=(0,s.jsxs)(x,{open:l,onOpenChange:t,children:[f,y]}),e[31]=x,e[32]=l,e[33]=t,e[34]=y,e[35]=f,e[36]=D):D=e[36],D};function De(e){return!e.hotkey}function Ee(e){return e.label}function Fe(e){return!e}export{Ne as default};
1
+ import{s as U}from"./chunk-LvLJmgfZ.js";import{l as X,u as V}from"./useEvent-D91BmmQi.js";import{t as Y}from"./react-Bj1aDYRI.js";import{Ei as Z}from"./cells-a44D37GV.js";import"./react-dom-CSu739Rf.js";import{t as O}from"./compiler-runtime-B3qBwwSJ.js";import{S as ee}from"./ai-model-dropdown-BUVX-tXn.js";import{d as le,h as te,t as ie,u as ae}from"./useEventListener-BfYriKqt.js";import{b as oe,h as ne,x as re}from"./utils-BGFUZat2.js";import{t as de}from"./jsx-runtime-PbYoItBR.js";import"./fullscreen-6ovMHcQN.js";import"./popover-D1IutFqN.js";import"./JsonOutput-BgU0YoWq.js";import"./download-YFYBUFlh.js";import"./dist-Dez1I5M9.js";import"./cjs-DXo9vDEJ.js";import"./main-DmhaVp6Y.js";import"./useNonce-0SWz6w4W.js";import{r as se}from"./requests-KshNNAOp.js";import"./layout-CrjtGZlj.js";import{t as pe}from"./useCellActionButton-B8YCBRJi.js";import"./markdown-renderer-DhkuKp0Y.js";import{i as me,t as he}from"./useNotebookActions-Bkh6zqQr.js";import"./dist-DHMtQYxT.js";import"./dist-Bj9Iedc0.js";import"./dist-D-o1OXc9.js";import"./dist-BZhJ1bTM.js";import"./dist-DnIl7RU-.js";import"./session-DF0gSADo.js";import"./purify.es-DdxMtdqK.js";import"./dates-Digd3pPR.js";import{n as ce}from"./useHotkey-Dg_dwRCE.js";import"./share-CDUcBp99.js";import"./utils-TBIUapDT.js";import"./vega-loader.browser-BJ9oKrvH.js";import"./defaultLocale-CuYNS33t.js";import"./defaultLocale-CGfP-Ye3.js";import"./chunk-5FQGJX7Z-D-AUn5sP.js";import"./html-to-image-B6hPo7Eh.js";import{r as ye}from"./focus-Ptvt4Jk-.js";import"./react-resizable-panels.browser.esm-CgWOEYeG.js";import{a as ue,c as fe,i as L,l as z,n as be,o as J,r as ge,s as ke}from"./command-Dzjey1r-.js";import{t as Q}from"./renderShortcut-BV7Qf4L2.js";import"./esm-DSv-aO_T.js";import"./name-cell-input-mLsE_Em-.js";import"./multi-icon-CvhGPe8t.js";import"./dist-BrSPXZRF.js";import"./dist-6Nc6OWsm.js";import"./dist-zuEISlEm.js";import"./dist-BUZOkWVK.js";import"./dist-D4sM9Hux.js";import"./dist-BMVtDS2X.js";import"./dist-teiEd76o.js";import"./dist-fRNNW4KX.js";import"./dist-CdqhtJoV.js";import"./esm-j1_GHh6X.js";var we=O(),Ce=U(Y(),1);function xe(e,l){let t=(0,we.c)(11),r;t[0]===l?r=t[1]:(r=new Z(l),t[0]=l,t[1]=r);let d=r,n;t[2]!==e||t[3]!==d?(n=()=>d.get(e),t[2]=e,t[3]=d,t[4]=n):n=t[4];let[m,k]=(0,Ce.useState)(n),i;t[5]!==e||t[6]!==d?(i=w=>{k(w),d.set(e,w)},t[5]=e,t[6]=d,t[7]=i):i=t[7];let u=i,h;return t[8]!==u||t[9]!==m?(h=[m,u],t[8]=u,t[9]=m,t[10]=h):h=t[10],h}var je=O(),Se=3;function ve(){let e=(0,je.c)(7),l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=[],e[0]=l):l=e[0];let[t,r]=xe("marimo:commands",l),d;e[1]!==t||e[2]!==r?(d=m=>{r(_e([m,...t]).slice(0,Se))},e[1]=t,e[2]=r,e[3]=d):d=e[3];let n;return e[4]!==t||e[5]!==d?(n={recentCommands:t,addRecentCommand:d},e[4]=t,e[5]=d,e[6]=n):n=e[6],n}function _e(e){return[...new Set(e)]}function W(e){return e.dropdown!==void 0}function T(e,l=""){return e.flatMap(t=>t.label?W(t)?T(t.dropdown,`${l+t.label} > `):{...t,label:l+t.label,additionalKeywords:t.additionalKeywords}:[])}var Ke=O();function He(){let e=(0,Ke.c)(75),[l,t]=re(),[r,d]=oe(),{saveAppConfig:n,saveUserConfig:m}=se(),k;e[0]!==m||e[1]!==t?(k=async p=>{await m({config:p}).then(()=>{t(c=>({...c,...p}))})},e[0]=m,e[1]=t,e[2]=k):k=e[2];let i=k,u;e[3]!==n||e[4]!==d?(u=async p=>{await n({config:p}).then(()=>{d(p)})},e[3]=n,e[4]=d,e[5]=u):u=e[5];let h=u,w;if(e[6]!==r||e[7]!==l.completion||e[8]!==l.display||e[9]!==l.keymap||e[10]!==h||e[11]!==i){let p;e[13]===r?p=e[14]:(p=B=>B!==r.width,e[13]=r,e[14]=p);let c;e[15]!==r||e[16]!==h?(c=B=>({label:`App config > Set width=${B}`,handle:()=>{h({...r,width:B})}}),e[15]=r,e[16]=h,e[17]=c):c=e[17];let K;e[18]!==l.display||e[19]!==i?(K={label:"Config > Set theme: dark",handle:()=>{i({display:{...l.display,theme:"dark"}})}},e[18]=l.display,e[19]=i,e[20]=K):K=e[20];let C;e[21]!==l.display||e[22]!==i?(C={label:"Config > Set theme: light",handle:()=>{i({display:{...l.display,theme:"light"}})}},e[21]=l.display,e[22]=i,e[23]=C):C=e[23];let H;e[24]!==l.display||e[25]!==i?(H={label:"Config > Set theme: system",handle:()=>{i({display:{...l.display,theme:"system"}})}},e[24]=l.display,e[25]=i,e[26]=H):H=e[26];let R=l.keymap.preset==="vim",A;e[27]!==l.keymap||e[28]!==i?(A=()=>{i({keymap:{...l.keymap,preset:"vim"}})},e[27]=l.keymap,e[28]=i,e[29]=A):A=e[29];let M;e[30]!==R||e[31]!==A?(M={label:"Config > Switch keymap to VIM",hidden:R,handle:A},e[30]=R,e[31]=A,e[32]=M):M=e[32];let N=l.keymap.preset==="default",x;e[33]!==l.keymap||e[34]!==i?(x=()=>{i({keymap:{...l.keymap,preset:"default"}})},e[33]=l.keymap,e[34]=i,e[35]=x):x=e[35];let f;e[36]!==N||e[37]!==x?(f={label:"Config > Switch keymap to default (current: VIM)",hidden:N,handle:x},e[36]=N,e[37]=x,e[38]=f):f=e[38];let j;e[39]!==l.completion||e[40]!==i?(j=()=>{i({completion:{...l.completion,copilot:!1}})},e[39]=l.completion,e[40]=i,e[41]=j):j=e[41];let S=l.completion.copilot!=="github",P;e[42]!==j||e[43]!==S?(P={label:"Config > Disable GitHub Copilot",handle:j,hidden:S},e[42]=j,e[43]=S,e[44]=P):P=e[44];let v;e[45]!==l.completion||e[46]!==i?(v=()=>{i({completion:{...l.completion,copilot:"github"}})},e[45]=l.completion,e[46]=i,e[47]=v):v=e[47];let G=l.completion.copilot==="github",$;e[48]!==v||e[49]!==G?($={label:"Config > Enable GitHub Copilot",handle:v,hidden:G},e[48]=v,e[49]=G,e[50]=$):$=e[50];let q=!l.display.reference_highlighting,_;e[51]!==l.display||e[52]!==i?(_=()=>{i({display:{...l.display,reference_highlighting:!1}})},e[51]=l.display,e[52]=i,e[53]=_):_=e[53];let b;e[54]!==q||e[55]!==_?(b={label:"Config > Disable reference highlighting",hidden:q,handle:_},e[54]=q,e[55]=_,e[56]=b):b=e[56];let y;e[57]!==l.display||e[58]!==i?(y=()=>{i({display:{...l.display,reference_highlighting:!0}})},e[57]=l.display,e[58]=i,e[59]=y):y=e[59];let D;e[60]!==l.display.reference_highlighting||e[61]!==y?(D={label:"Config > Enable reference highlighting",hidden:l.display.reference_highlighting,handle:y},e[60]=l.display.reference_highlighting,e[61]=y,e[62]=D):D=e[62];let a=l.display.cell_output==="above",o;e[63]!==l.display||e[64]!==i?(o=()=>{i({display:{...l.display,cell_output:"above"}})},e[63]=l.display,e[64]=i,e[65]=o):o=e[65];let E;e[66]!==a||e[67]!==o?(E={label:"Config > Set cell output area: above",hidden:a,handle:o},e[66]=a,e[67]=o,e[68]=E):E=e[68];let g=l.display.cell_output==="below",F;e[69]!==l.display||e[70]!==i?(F=()=>{i({display:{...l.display,cell_output:"below"}})},e[69]=l.display,e[70]=i,e[71]=F):F=e[71];let I;e[72]!==g||e[73]!==F?(I={label:"Config > Set cell output area: below",hidden:g,handle:F},e[72]=g,e[73]=F,e[74]=I):I=e[74],w=[...ee().filter(p).map(c),K,C,H,M,f,P,$,b,D,E,I].filter(Ae),e[6]=r,e[7]=l.completion,e[8]=l.display,e[9]=l.keymap,e[10]=h,e[11]=i,e[12]=w}else w=e[12];return w}function Ae(e){return!e.hidden}var Me=O(),s=U(de(),1),Ne=()=>{let e=(0,Me.c)(37),[l,t]=X(me),r=ce(),d=V(ye),n=V(ne),m;e[0]===d?m=e[1]:(m={cell:d},e[0]=d,e[1]=m);let k=pe(m).flat();k=T(k);let i=He(),u=he();u=[...T(u),...T(i)];let h=u.filter(De),w=le.keyBy(h,Ee),{recentCommands:p,addRecentCommand:c}=ve(),K;e[2]===p?K=e[3]:(K=new Set(p),e[2]=p,e[3]=K);let C=K,H;e[4]!==n||e[5]!==t?(H=a=>{te(n.getHotkey("global.commandPalette").key)(a)&&(a.preventDefault(),t(Fe))},e[4]=n,e[5]=t,e[6]=H):H=e[6],ie(document,"keydown",H);let R;e[7]!==c||e[8]!==n||e[9]!==r||e[10]!==t?(R=(a,o)=>{let E=r[a];if(!E)return null;let g=n.getHotkey(a);return(0,s.jsxs)(J,{disabled:o.disabled,keywords:g.additionalKeywords,onSelect:()=>{c(a),t(!1),requestAnimationFrame(()=>{E()})},value:g.name,children:[(0,s.jsxs)("span",{children:[g.name,o.tooltip&&(0,s.jsx)("span",{className:"ml-2",children:o.tooltip})]}),(0,s.jsx)(z,{children:(0,s.jsx)(Q,{shortcut:g.key})})]},a)},e[7]=c,e[8]=n,e[9]=r,e[10]=t,e[11]=R):R=e[11];let A=R,M;e[12]!==c||e[13]!==n||e[14]!==t?(M=a=>{let{label:o,handle:E,props:g,hotkey:F,additionalKeywords:I}=a,B=g===void 0?{}:g;return(0,s.jsxs)(J,{disabled:B.disabled,keywords:I,onSelect:()=>{c(o),t(!1),requestAnimationFrame(()=>{E()})},value:o,children:[(0,s.jsxs)("span",{children:[o,B.tooltip&&(0,s.jsxs)("span",{className:"ml-2",children:["(",B.tooltip,")"]})]}),F&&(0,s.jsx)(z,{children:(0,s.jsx)(Q,{shortcut:n.getHotkey(F).key})})]},o)},e[12]=c,e[13]=n,e[14]=t,e[15]=M):M=e[15];let N=M,x=be,f;e[16]===Symbol.for("react.memo_cache_sentinel")?(f=(0,s.jsx)(ue,{placeholder:"Type to search..."}),e[16]=f):f=e[16];let j=ke,S;e[17]===Symbol.for("react.memo_cache_sentinel")?(S=(0,s.jsx)(ge,{children:"No results found."}),e[17]=S):S=e[17];let P=p.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(L,{heading:"Recently Used",children:p.map(a=>{let o=w[a];return ae(a)?A(a,{disabled:o==null?void 0:o.disabled,tooltip:o==null?void 0:o.tooltip}):o&&!W(o)?N({label:o.label,handle:o.handleHeadless||o.handle,props:{disabled:o.disabled,tooltip:o.tooltip},additionalKeywords:o.additionalKeywords}):null})}),(0,s.jsx)(fe,{})]}),v=L,G=n.iterate().map(a=>{if(C.has(a))return null;let o=w[a];return A(a,{disabled:o==null?void 0:o.disabled,tooltip:o==null?void 0:o.tooltip})}),$=h.map(a=>C.has(a.label)?null:N({label:a.label,handle:a.handleHeadless||a.handle,props:{disabled:a.disabled,tooltip:a.tooltip},additionalKeywords:a.additionalKeywords})),q;e[18]!==C||e[19]!==N?(q=a=>C.has(a.label)?null:N({label:`Cell > ${a.label}`,handle:a.handleHeadless||a.handle,props:{disabled:a.disabled,tooltip:a.tooltip},additionalKeywords:a.additionalKeywords}),e[18]=C,e[19]=N,e[20]=q):q=e[20];let _=k.map(q),b;e[21]!==v||e[22]!==$||e[23]!==_||e[24]!==G?(b=(0,s.jsxs)(v,{heading:"Commands",children:[G,$,_]}),e[21]=v,e[22]=$,e[23]=_,e[24]=G,e[25]=b):b=e[25];let y;e[26]!==j||e[27]!==b||e[28]!==S||e[29]!==P?(y=(0,s.jsxs)(j,{children:[S,P,b]}),e[26]=j,e[27]=b,e[28]=S,e[29]=P,e[30]=y):y=e[30];let D;return e[31]!==x||e[32]!==l||e[33]!==t||e[34]!==y||e[35]!==f?(D=(0,s.jsxs)(x,{open:l,onOpenChange:t,children:[f,y]}),e[31]=x,e[32]=l,e[33]=t,e[34]=y,e[35]=f,e[36]=D):D=e[36],D};function De(e){return!e.hotkey}function Ee(e){return e.label}function Fe(e){return!e}export{Ne as default};