@marimo-team/frontend 0.23.16-dev42 → 0.23.16-dev43

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 (32) hide show
  1. package/dist/assets/{JsonOutput-CyzvjIjx.js → JsonOutput-C08yZPMz.js} +1 -1
  2. package/dist/assets/{add-connection-dialog-C97ylgk0.js → add-connection-dialog-ChQis5IF.js} +1 -1
  3. package/dist/assets/{agent-panel-Dxo9WUKV.js → agent-panel-Bh4wHqF0.js} +1 -1
  4. package/dist/assets/{cell-editor-BKrHbyX_.js → cell-editor-_0p7q-Z_.js} +1 -1
  5. package/dist/assets/{column-preview-Cb8R9kfl.js → column-preview-UAW6odg3.js} +1 -1
  6. package/dist/assets/{command-palette-B1S9PjZi.js → command-palette-YAVCtQ6D.js} +1 -1
  7. package/dist/assets/{dependency-graph-panel-DY5lvPDx.js → dependency-graph-panel-BmvJHSNy.js} +1 -1
  8. package/dist/assets/{download-DpS57jyt.js → download-BIGA4WFm.js} +3 -3
  9. package/dist/assets/{edit-page-DA765yQV.js → edit-page-ejL0j3OD.js} +4 -4
  10. package/dist/assets/{file-explorer-panel-BKUo-MDh.js → file-explorer-panel-BxfypeX1.js} +1 -1
  11. package/dist/assets/{form-nHzLTU1m.js → form-D8N71OB1.js} +1 -1
  12. package/dist/assets/{index-C7_REKh1.js → index-BLnlUAQy.js} +2 -2
  13. package/dist/assets/{layout-B29hqiiK.js → layout-B8cCh91r.js} +3 -3
  14. package/dist/assets/{panels-Bb4fIHgH.js → panels-DG_QWeJn.js} +1 -1
  15. package/dist/assets/{reveal-component-5jf0W625.js → reveal-component-c5jsRi2_.js} +1 -1
  16. package/dist/assets/{run-page-BMKx9ld_.js → run-page-BUPqI6K7.js} +1 -1
  17. package/dist/assets/{scratchpad-panel-C8z8vzBX.js → scratchpad-panel-BR7YpUiV.js} +1 -1
  18. package/dist/assets/{session-panel-BVVk-02h.js → session-panel-DW3mL5Qf.js} +1 -1
  19. package/dist/assets/{skeleton-Bubr9pIj.js → skeleton-CeWH7IQO.js} +1 -1
  20. package/dist/assets/{useCellActionButton-DypR3yDt.js → useCellActionButton-D-uro4Di.js} +1 -1
  21. package/dist/assets/{useDependencyPanelTab-CwdwKf7A.js → useDependencyPanelTab-BGGAtEWD.js} +1 -1
  22. package/dist/assets/useNotebookActions-Cm5GAHUD.js +12 -0
  23. package/dist/index.html +5 -5
  24. package/package.json +1 -1
  25. package/src/components/editor/actions/__tests__/pdf-export.test.ts +32 -9
  26. package/src/components/editor/actions/pdf-export.ts +11 -11
  27. package/src/components/editor/actions/useNotebookActions.tsx +11 -5
  28. package/src/core/export/__tests__/hooks.test.ts +2 -4
  29. package/src/core/export/hooks.ts +4 -3
  30. package/src/utils/__tests__/download.test.tsx +20 -3
  31. package/src/utils/download.ts +3 -9
  32. package/dist/assets/useNotebookActions-jWIcmpv0.js +0 -12
@@ -205,9 +205,26 @@ describe("downloadAsPDF", () => {
205
205
  webpdf: false,
206
206
  preset: "slides",
207
207
  includeInputs: true,
208
- rasterizeOutputs: true,
209
- rasterScale: 4,
210
- rasterServer: "static",
208
+ includeOutputs: true,
209
+ });
210
+ });
211
+
212
+ it("should send input and output selections", async () => {
213
+ mockExportAsPDF.mockRejectedValue(new Error("network"));
214
+
215
+ await expect(
216
+ downloadAsPDF({
217
+ webpdf: true,
218
+ includeInputs: false,
219
+ includeOutputs: false,
220
+ }),
221
+ ).rejects.toThrow("network");
222
+
223
+ expect(mockExportAsPDF).toHaveBeenCalledWith({
224
+ webpdf: true,
225
+ preset: "document",
226
+ includeInputs: false,
227
+ includeOutputs: false,
211
228
  });
212
229
  });
213
230
  });
@@ -211,18 +211,14 @@ export async function downloadAsPDF(opts: {
211
211
  webpdf: boolean;
212
212
  preset?: PDFExportPreset;
213
213
  includeInputs?: boolean;
214
- rasterizeOutputs?: boolean;
215
- rasterScale?: number;
216
- rasterServer?: "static" | "live";
214
+ includeOutputs?: boolean;
217
215
  }) {
218
216
  const client = getRequestClient();
219
217
  const {
220
218
  webpdf,
221
219
  preset = "document",
222
220
  includeInputs = true,
223
- rasterizeOutputs = true,
224
- rasterScale = 4,
225
- rasterServer = "static",
221
+ includeOutputs = true,
226
222
  } = opts;
227
223
 
228
224
  try {
@@ -230,9 +226,7 @@ export async function downloadAsPDF(opts: {
230
226
  webpdf,
231
227
  preset,
232
228
  includeInputs,
233
- rasterizeOutputs,
234
- rasterScale,
235
- rasterServer,
229
+ includeOutputs,
236
230
  });
237
231
 
238
232
  downloadExportedFile(exportedFile);
@@ -1,12 +0,0 @@
1
- import{s as Se}from"./chunk-LvLJmgfZ.js";import{d as R,i as Wt,l as St,p as At,u as N}from"./useEvent-D91BmmQi.js";import{t as _t}from"./react-Bj1aDYRI.js";import{An as Dt,Bi as Et,Cr as It,E as Ae,Fi as Pt,Fn as Tt,Kn as Lt,Ln as Ot,Nn as Ht,Nr as Rt,Nt as _e,Or as Ft,Pn as $t,Qi as ke,T as qt,Tr as Bt,g as Ut,m as De,qt as Yt,si as Kt,t as Vt,wr as Ee,y as Gt}from"./cells-DzyDERZy.js";import{t as z}from"./compiler-runtime-B3qBwwSJ.js";import{n as Jt,r as Qt,x as Xt}from"./ai-model-dropdown-Bvqy98cI.js";import{g as F,n as Zt}from"./useEventListener-C0195JsF.js";import{t as Ie}from"./objects-BlG0ZrO0.js";import{C as ea,r as ta}from"./utils-BWBBpCkT.js";import{n as v,t as Pe}from"./constants-CDyU_g2F.js";import{M as ee,O as aa,T as Te,j as Le,k as na,v as Oe}from"./config-B-Q7J_6d.js";import{c as oa}from"./readonly-python-code-DHxOnQGj.js";import{t as sa}from"./cn-DYvqRARy.js";import{t as ra}from"./jsx-runtime-Blw4afVn.js";import{o as la}from"./alert-dialog-Bb8Lz8ko.js";import{a as ia,c as da,i as ca,n as ha,r as ma,s as ua,t as pa}from"./select-BP75_5jJ.js";import{Ft as fa}from"./JsonOutput-CyzvjIjx.js";import{f as xa,l as He,n as ba,o as Re,r as ya,s as ka,t as wa}from"./download-DpS57jyt.js";import{t as ga}from"./tooltip-4bZlU7jl.js";import{r as ja,t as P}from"./button-DDGiD1NW.js";import{i as va,t as we}from"./strings--BknHX9C.js";import{r as T}from"./requests-9-v2bhoi.js";import{t as k}from"./createLucideIcon-w-Qo9n0R.js";import{F as Ca,I as Na,L as za,R as Fe,a as $e,d as Ma,i as qe,u as Be}from"./layout-B29hqiiK.js";import{t as Ue}from"./check-rzLRd0j9.js";import{r as Wa}from"./useCellActionButton-DypR3yDt.js";import{t as Sa}from"./code-B2aKtXoe.js";import{t as Aa}from"./copy-3iHFdt22.js";import{t as Ye}from"./eye-off-BOZA7gbn.js";import{t as Ke}from"./external-link-BOlXZUla.js";import{t as te}from"./file-CJH9JNGH.js";import{u as _a}from"./form-nHzLTU1m.js";import{n as Da,r as Ea,t as Ia}from"./youtube-OwaksuQt.js";import{i as Pa,n as Ve}from"./add-connection-dialog-C97ylgk0.js";import{t as Ta}from"./house-DS0r7dNZ.js";import{t as La}from"./image-5XI2VU-q.js";import{t as Oa}from"./link-CHdiBDr5.js";import{r as Ha}from"./input-JxFwu-3G.js";import{t as Ra}from"./settings-D_PiwXwo.js";import{t as Fa}from"./sparkles-DUCpRFlS.js";import{y as $a}from"./textarea-Bmzmbbpo.js";import{t as qa}from"./square-DFICx2Qv.js";import{t as Ge}from"./triangle-alert-BL4YVsPy.js";import{t as W}from"./use-toast-BwJoaaDM.js";import{n as Je,t as Ba}from"./paths-BKO-pHK6.js";import{o as Ua}from"./session-BmukRjSi.js";import{n as ae}from"./copy-Bxb1_Gtw.js";import{t as Qe}from"./copy-icon-neDQUo4Q.js";import{r as Ya}from"./useRunCells-C2dvU2jA.js";import{a as Xe,c as Ze,i as Ka,n as et,r as tt}from"./dialog-BCVepWLJ.js";import{n as ne}from"./ImperativeModal-fY-ZfT0b.js";import{r as Va,t as at}from"./share-852X_cqy.js";import{a as Ga}from"./cell-link-w5IbCQV4.js";import{n as nt}from"./useAsyncData-Bg5iAViP.js";import{a as Ja}from"./renderShortcut-Bl8_FVn8.js";import{t as Qa}from"./icons-CIPE8AIY.js";import{i as Xa,n as ot}from"./error-entries-CTYMwfsh.js";import{t as Za}from"./pair-with-agent-modal-BCRSACei.js";import{t as en}from"./github-_JH-0hIO.js";import{n as st}from"./marimo-icons-C_nFooxr.js";import{t as tn}from"./links-CZr5bjvo.js";import{i as an,n as rt,t as ge}from"./skeleton-Bubr9pIj.js";import{t as lt}from"./types-Da7lA5YC.js";var nn=k("circle-chevron-down",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 10-4 4-4-4",key:"894hmk"}]]),on=k("circle-chevron-right",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m10 8 4 4-4 4",key:"1wy4r4"}]]),it=k("clipboard-copy",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M8 4H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2",key:"4jdomd"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v4",key:"3hqy98"}],["path",{d:"M21 14H11",key:"1bme5i"}],["path",{d:"m15 10-4 4 4 4",key:"5dvupr"}]]),dt=k("command",[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]]),ct=k("diamond-plus",[["path",{d:"M12 8v8",key:"napkw2"}],["path",{d:"M2.7 10.3a2.41 2.41 0 0 0 0 3.41l7.59 7.59a2.41 2.41 0 0 0 3.41 0l7.59-7.59a2.41 2.41 0 0 0 0-3.41L13.7 2.71a2.41 2.41 0 0 0-3.41 0z",key:"1ey20j"}],["path",{d:"M8 12h8",key:"1wcyev"}]]),sn=k("fast-forward",[["path",{d:"M12 6a2 2 0 0 1 3.414-1.414l6 6a2 2 0 0 1 0 2.828l-6 6A2 2 0 0 1 12 18z",key:"b19h5q"}],["path",{d:"M2 6a2 2 0 0 1 3.414-1.414l6 6a2 2 0 0 1 0 2.828l-6 6A2 2 0 0 1 2 18z",key:"h7h5ge"}]]),rn=k("files",[["path",{d:"M15 2h-4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V8",key:"14sh0y"}],["path",{d:"M16.706 2.706A2.4 2.4 0 0 0 15 2v5a1 1 0 0 0 1 1h5a2.4 2.4 0 0 0-.706-1.706z",key:"1970lx"}],["path",{d:"M5 7a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 1.732-1",key:"l4dndm"}]]),ln=k("list",[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]]),ht=k("message-circle-question-mark",[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),dn=k("notebook",[["path",{d:"M2 6h4",key:"aawbzj"}],["path",{d:"M2 10h4",key:"l0bgd4"}],["path",{d:"M2 14h4",key:"1gsvsf"}],["path",{d:"M2 18h4",key:"1bu2t1"}],["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",key:"1nb95v"}],["path",{d:"M16 2v20",key:"rotuqe"}]]),cn=k("panel-left",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]]),mt=k("presentation",[["path",{d:"M2 3h20",key:"91anmk"}],["path",{d:"M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3",key:"2k9sn8"}],["path",{d:"m7 21 5-5 5 5",key:"bip4we"}]]),hn=k("share-2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]),mn=k("square-power",[["path",{d:"M12 7v4",key:"xawao1"}],["path",{d:"M7.998 9.003a5 5 0 1 0 8-.005",key:"1pek45"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}]]),ut=k("undo-2",[["path",{d:"M9 14 4 9l5-5",key:"102s5s"}],["path",{d:"M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11",key:"f3b9sd"}]]),un=z(),L=Se(_t(),1);function je(e,t){let n=(0,un.c)(11),o;n[0]===t?o=n[1]:(o=new Pt(t),n[0]=t,n[1]=o);let s=o,l;n[2]!==e||n[3]!==s?(l=()=>s.get(e),n[2]=e,n[3]=s,n[4]=l):l=n[4];let[r,d]=(0,L.useState)(l),i;n[5]!==e||n[6]!==s?(i=x=>{d(x),s.set(e,x)},n[5]=e,n[6]=s,n[7]=i):i=n[7];let c=i,h;return n[8]!==c||n[9]!==r?(h=[r,c],n[8]=c,n[9]=r,n[10]=h):h=n[10],h}function pn(e,t){return{...e,Binaries:{...e.Binaries,Browser:t}}}function fn(e,t,n,o){return{marimo:e,Locale:n||void 0,Binaries:{Browser:t},"Environment Collection Error":o}}function ve(e,t){let n=Math.max(2,...Array.from(t.matchAll(/`+/g),s=>s[0].length)),o="`".repeat(n+1);return`${o}${e}
2
- ${t}
3
- ${o}`}function xn(e,t){let n=e.includes("?")?"&":"?",o=[],s=e,l=0;for(let[r,d]of Object.entries(t)){if(d.length===0)continue;let i=`${r}=${encodeURIComponent(d)}`,c=`${s}${l===0?n:"&"}${i}`;if(c.length>6e3){o.push(r);continue}s=c,l+=1}return{url:s,omitted:o}}function Ce(e,t){return["<details>",`<summary>${we.htmlEscape(e)??""}</summary>`,"",t,"","</details>"].join(`
4
- `)}function bn(e){return Ce("Environment",ve("json",JSON.stringify(e,null,2)))}function pt(e){return Ce("Errors",ve("text",e.map(ot).join(`
5
-
6
- ---
7
-
8
- `)))}function yn(e){return Ce("Code",ve("python",e))}var ft=z(),a=Se(ra(),1),kn=Zt,xt=e=>{let t=(0,ft.c)(16),{content:n}=e,[o,s]=(0,L.useState)(!1),l=!o&&"max-h-24 overflow-hidden",r;t[0]===l?r=t[1]:(r=sa("text-xs bg-muted rounded p-2 overflow-x-auto whitespace-pre-wrap",l),t[0]=l,t[1]=r);let d;t[2]!==n||t[3]!==r?(d=(0,a.jsx)("pre",{className:r,children:n}),t[2]=n,t[3]=r,t[4]=d):d=t[4];let i;t[5]===o?i=t[6]:(i=!o&&(0,a.jsx)("div",{className:"pointer-events-none absolute inset-x-0 bottom-0 h-10 rounded-b bg-gradient-to-b from-transparent to-muted"}),t[5]=o,t[6]=i);let c;t[7]!==d||t[8]!==i?(c=(0,a.jsxs)("div",{className:"relative",children:[d,i]}),t[7]=d,t[8]=i,t[9]=c):c=t[9];let h;t[10]===Symbol.for("react.memo_cache_sentinel")?(h=()=>s(gn),t[10]=h):h=t[10];let x=o?"Show less":"Show more",m;t[11]===x?m=t[12]:(m=(0,a.jsx)(P,{type:"button",variant:"link",size:"xs",className:"self-start",onClick:h,children:x}),t[11]=x,t[12]=m);let b;return t[13]!==c||t[14]!==m?(b=(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[c,m]}),t[13]=c,t[14]=m,t[15]=b):b=t[15],b};const wn=e=>{let t=(0,ft.c)(6),{children:n}=e,{openModal:o,closeModal:s}=ne(),l;t[0]!==s||t[1]!==o?(l=()=>o((0,a.jsx)(bt,{onClose:s})),t[0]=s,t[1]=o,t[2]=l):l=t[2];let r;return t[3]!==n||t[4]!==l?(r=(0,a.jsx)(kn,{onClick:l,children:n}),t[3]=n,t[4]=l,t[5]=r):r=t[5],r},bt=()=>{let{getEnvironmentInfo:e,readCode:t}=T(),n=nt(async()=>e(),[e]),o=N(Gt),s=(0,L.useMemo)(()=>Xa(Wt),[o]),l=Ma(o.cellIds.inOrderIds.map(u=>o.cellData[u])),r=N(Et),d=N(Oe),i=r!==null&&l&&d.state===Te.OPEN,c=i?void 0:r===null?"Save the notebook first.":l?"Connect the notebook to include its source.":"Notebook source is hidden in this view.",[h,x]=je("marimo:issue-report:include-errors",!1),[m,b]=je("marimo:issue-report:include-code",!1),f=n.data?pn(n.data,navigator.userAgent):n.status==="error"?fn(oa(),navigator.userAgent,navigator.language,"Server environment information unavailable"):void 0,y=nt(async()=>{if(!m||!i)return;let{contents:u}=await t();return u},[m,i,t]),{url:w,omitted:g}=(0,L.useMemo)(()=>{if(!f)return{url:v.bugReportUrl,omitted:[]};let u={env:bn(f)};return h&&s.length>0&&(u["bug-description"]=pt(s)),m&&y.data&&(u["reproduction-code"]=yn(y.data)),xn(v.bugReportUrl,u)},[f,s,h,m,y.data]),j=g.map(u=>u==="bug-description"?"errors":u==="reproduction-code"?"code":u).join(", ");return(0,a.jsxs)(et,{className:"w-[540px] max-w-[90vw]",children:[(0,a.jsxs)(Xe,{children:[(0,a.jsx)(Ze,{children:"Report an issue"}),(0,a.jsx)(tt,{children:"Open a GitHub bug report prefilled with your environment, and optionally your current errors and notebook code. Nothing is uploaded automatically; review the details before posting."})]}),(0,a.jsxs)("div",{className:"flex flex-col gap-4 max-h-[60vh] overflow-y-auto",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(P,{type:"button",variant:"default",size:"xs",asChild:!0,className:"self-start",children:(0,a.jsxs)("a",{href:w,target:"_blank",rel:"noreferrer",children:[(0,a.jsx)(Ke,{className:"w-4 h-4 mr-2"}),"Open GitHub issue"]})}),(0,a.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2 text-sm",children:[(0,a.jsx)(_e,{id:"issue-include-errors",checked:h,disabled:s.length===0,onCheckedChange:u=>x(u===!0),"aria-label":"Include errors"}),(0,a.jsx)("label",{htmlFor:"issue-include-errors",children:"Include errors"})]}),(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2 text-sm",children:[(0,a.jsx)(_e,{id:"issue-include-code",checked:m,disabled:!i,onCheckedChange:u=>b(u===!0),"aria-label":"Include notebook code"}),(0,a.jsx)("label",{htmlFor:"issue-include-code",children:"Include notebook code"})]}),c&&(0,a.jsx)("span",{className:"text-xs text-muted-foreground ml-6",children:c}),m&&y.status==="error"&&(0,a.jsx)("span",{className:"text-xs text-(--red-11) ml-6",children:"Notebook source could not be loaded."})]})]}),j?(0,a.jsxs)("div",{className:"flex items-start gap-2 text-xs text-(--yellow-11)",children:[(0,a.jsx)(Ge,{className:"w-3.5 h-3.5 shrink-0 mt-0.5"}),(0,a.jsxs)("span",{children:["Too large to prefill and left out of the link: ",j,". Paste them into the issue manually."]})]}):(0,a.jsx)("p",{className:"text-xs text-muted-foreground",children:"Your environment is always included."})]}),n.status==="pending"&&(0,a.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:"Loading environment details\u2026"}),(0,a.jsx)(ge,{className:"h-4 w-full"}),(0,a.jsx)(ge,{className:"h-4 w-3/4"}),(0,a.jsx)(ge,{className:"h-4 w-1/2"})]}),n.status==="error"&&(0,a.jsxs)("div",{className:"flex items-center gap-2 text-sm",children:[(0,a.jsx)(Ge,{className:"w-4 h-4 text-(--yellow-11) shrink-0"}),(0,a.jsx)("span",{children:"Server environment information unavailable"}),(0,a.jsx)(P,{type:"button",variant:"link",size:"xs",onClick:()=>n.refetch(),children:"Retry"})]}),f&&(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm font-medium",children:"Environment details"}),(0,a.jsx)(Qe,{className:"w-3.5 h-3.5",value:JSON.stringify(f,null,2),ariaLabel:"Copy environment JSON",toastTitle:"Environment details copied"})]}),(0,a.jsx)(xt,{content:JSON.stringify(f,null,2)})]}),f&&s.length>0&&(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-sm font-medium",children:"Errors"}),(0,a.jsx)(Qe,{className:"w-3.5 h-3.5",value:pt(s),ariaLabel:"Copy errors",toastTitle:"Errors copied"})]}),(0,a.jsx)(xt,{content:s.map(ot).join(`
9
-
10
- ---
11
-
12
- `)})]}),f&&s.length===0&&(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:"No errors detected."}),(0,a.jsx)("div",{className:"border-t pt-3",children:(0,a.jsxs)("p",{className:"text-sm text-muted-foreground",children:["Other feedback? Take our"," ",(0,a.jsx)("a",{href:v.feedbackForm,target:"_blank",rel:"noreferrer",className:"underline",children:"two-minute survey"})," ","or chat with us on"," ",(0,a.jsx)("a",{href:v.discordLink,target:"_blank",rel:"noreferrer",className:"underline",children:"Discord"}),"."]})})]})]})};function gn(e){return!e}var yt=z(),oe="https://static.marimo.app";const jn=e=>{let t=(0,yt.c)(25),{onClose:n}=e,[o,s]=(0,L.useState)(""),{exportAsHTML:l}=T(),r=`${o}-${Math.random().toString(36).slice(2,6)}`,d=`${oe}/static/${r}`,i;t[0]!==l||t[1]!==n||t[2]!==r?(i=async u=>{u.preventDefault(),n();let{contents:H}=await l({download:!1,includeCode:!0,files:Ca.INSTANCE.filenames()}),S=W({title:"Uploading static notebook...",description:"Please wait."});await fetch(`${oe}/api/static`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({html:H,path:r})}).catch(()=>{S.dismiss(),W({title:"Error uploading static page",description:(0,a.jsxs)("div",{children:["Please try again later. If the problem persists, please file a bug report on"," ",(0,a.jsx)("a",{href:v.issuesPage,target:"_blank",className:"underline",children:"GitHub"}),"."]})})}),S.dismiss(),W({title:"Static page uploaded!",description:(0,a.jsxs)("div",{children:["The URL has been copied to your clipboard.",(0,a.jsx)("br",{}),"You can share it with anyone."]})})},t[0]=l,t[1]=n,t[2]=r,t[3]=i):i=t[3];let c;t[4]===Symbol.for("react.memo_cache_sentinel")?(c=(0,a.jsx)(Ze,{children:"Share static notebook"}),t[4]=c):c=t[4];let h;t[5]===Symbol.for("react.memo_cache_sentinel")?(h=(0,a.jsxs)(Xe,{children:[c,(0,a.jsxs)(tt,{children:["You can publish a static, non-interactive version of this notebook to the public web. We will create a link for you that lives on"," ",(0,a.jsx)("a",{href:oe,target:"_blank",children:oe}),"."]})]}),t[5]=h):h=t[5];let x;t[6]===Symbol.for("react.memo_cache_sentinel")?(x=u=>{s(u.target.value.toLowerCase().replaceAll(/\s/g,"-").replaceAll(/[^\da-z-]/g,""))},t[6]=x):x=t[6];let m;t[7]===o?m=t[8]:(m=(0,a.jsx)(Ha,{"data-testid":"slug-input",id:"slug",autoFocus:!0,value:o,placeholder:"Notebook slug",onChange:x,required:!0,autoComplete:"off"}),t[7]=o,t[8]=m);let b;t[9]===d?b=t[10]:(b=(0,a.jsxs)("div",{className:"font-semibold text-sm text-muted-foreground gap-2 flex flex-col",children:["Anyone will be able to access your notebook at this URL:",(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(vn,{text:d}),(0,a.jsx)("span",{className:"text-primary",children:d})]})]}),t[9]=d,t[10]=b);let f;t[11]!==m||t[12]!==b?(f=(0,a.jsxs)("div",{className:"flex flex-col gap-6 py-4",children:[m,b]}),t[11]=m,t[12]=b,t[13]=f):f=t[13];let y;t[14]===n?y=t[15]:(y=(0,a.jsx)(P,{"data-testid":"cancel-share-static-notebook-button",variant:"secondary",onClick:n,children:"Cancel"}),t[14]=n,t[15]=y);let w;t[16]===d?w=t[17]:(w=(0,a.jsx)(P,{"data-testid":"share-static-notebook-button","aria-label":"Save",variant:"default",type:"submit",onClick:async()=>{await ae(d)},children:"Create"}),t[16]=d,t[17]=w);let g;t[18]!==y||t[19]!==w?(g=(0,a.jsxs)(Ka,{children:[y,w]}),t[18]=y,t[19]=w,t[20]=g):g=t[20];let j;return t[21]!==i||t[22]!==g||t[23]!==f?(j=(0,a.jsx)(et,{className:"w-fit",children:(0,a.jsxs)("form",{onSubmit:i,children:[h,f,g]})}),t[21]=i,t[22]=g,t[23]=f,t[24]=j):j=t[24],j};var vn=e=>{let t=(0,yt.c)(8),[n,o]=L.useState(!1),s;t[0]===e.text?s=t[1]:(s=ja.stopPropagation(async c=>{c.preventDefault(),await ae(e.text),o(!0),setTimeout(()=>o(!1),2e3)}),t[0]=e.text,t[1]=s);let l=s,r;t[2]===Symbol.for("react.memo_cache_sentinel")?(r=(0,a.jsx)(Aa,{size:14,strokeWidth:1.5}),t[2]=r):r=t[2];let d;t[3]===l?d=t[4]:(d=(0,a.jsx)(P,{"data-testid":"copy-static-notebook-url-button",onClick:l,size:"xs",variant:"secondary",children:r}),t[3]=l,t[4]=d);let i;return t[5]!==n||t[6]!==d?(i=(0,a.jsx)(ga,{content:"Copied!",open:n,children:d}),t[5]=n,t[6]=d,t[7]=i):i=t[7],i},Cn=z();function Nn(){let e=document.getElementsByClassName(Pe.outputArea);for(let t of e){let n=t.getBoundingClientRect();if(n.bottom>0&&n.top<window.innerHeight){let o=ke.findElement(t);if(!o){F.warn("Could not find HTMLCellId for visible output area",t);continue}return{cellId:ke.parse(o.id)}}}return F.warn("No visible output area found for scroll anchor"),null}function zn(e){if(!e){F.warn("No scroll anchor provided to restore scroll position");return}let t=document.getElementById(ke.create(e.cellId));if(!t){F.warn("Could not find cell element to restore scroll position",e.cellId);return}if(!t.querySelector(`.${Pe.outputArea}`)){F.warn("Could not find output area to restore scroll position",e.cellId);return}t.scrollIntoView({block:"start",behavior:"auto"})}function kt(){let e=(0,Cn.c)(2),t=R(Le),n;return e[0]===t?n=e[1]:(n=()=>{let o=Nn();t(s=>({mode:na(s.mode),cellAnchor:(o==null?void 0:o.cellId)??null})),requestAnimationFrame(()=>{requestAnimationFrame(()=>{zn(o)})})},e[0]=t,e[1]=n),n}const wt=At(!1);var Mn=z();const Wn=()=>{let e=(0,Mn.c)(7),{selectedLayout:t}=$e(),{setLayoutView:n}=qe();if(ee()&&!Lt("wasm_layouts"))return null;let o;e[0]===n?o=e[1]:(o=d=>n(d),e[0]=n,e[1]=o);let s;e[2]===Symbol.for("react.memo_cache_sentinel")?(s=(0,a.jsx)(ua,{className:"min-w-[110px] border-border bg-background","data-testid":"layout-select",children:(0,a.jsx)(da,{placeholder:"Select a view"})}),e[2]=s):s=e[2];let l;e[3]===Symbol.for("react.memo_cache_sentinel")?(l=(0,a.jsx)(ha,{children:(0,a.jsxs)(ma,{children:[(0,a.jsx)(ia,{children:"View as"}),lt.map(An)]})}),e[3]=l):l=e[3];let r;return e[4]!==t||e[5]!==o?(r=(0,a.jsxs)(pa,{"data-testid":"layout-select",value:t,onValueChange:o,children:[s,l]}),e[4]=t,e[5]=o,e[6]=r):r=e[6],r};function Sn(e){return(0,a.jsx)(gt(e),{className:"h-4 w-4"})}function gt(e){switch(e){case"vertical":return ln;case"grid":return Ea;case"slides":return mt;default:return va(e),qa}}function jt(e){return we.startCase(e)}function An(e){return(0,a.jsx)(ca,{value:e,children:(0,a.jsxs)("div",{className:"flex items-center gap-1.5 leading-5",children:[Sn(e),(0,a.jsx)("span",{children:jt(e)})]})},e)}async function _n(e){let{preset:t,downloadPDF:n}=e;await n({webpdf:!1,preset:t,includeInputs:!0,rasterServer:"static"})}var Dn=z();function En(e){let t=(0,Dn.c)(5),{openPrompt:n,closeModal:o}=ne(),{sendCopy:s}=T(),l;return t[0]!==o||t[1]!==n||t[2]!==s||t[3]!==e?(l=()=>{if(!e)return null;let r=Ba.guessDeliminator(e);n({title:"Copy notebook",description:"Enter a new filename for the notebook copy.",defaultValue:`_${Je.basename(e)}`,confirmText:"Copy notebook",spellCheck:!1,onConfirm:d=>{let i=r.join(Je.dirname(e),d);s({source:e,destination:i}).then(()=>{o(),W({title:"Notebook copied",description:"A copy of the notebook has been created."}),tn(i)})}})},t[0]=o,t[1]=n,t[2]=s,t[3]=e,t[4]=l):l=t[4],l}var In=z();function vt(){let e=(0,In.c)(4),{openConfirm:t}=ne(),n=R(Oe),{sendRestart:o}=T(),s;return e[0]!==t||e[1]!==o||e[2]!==n?(s=()=>{t({title:"Restart Kernel",description:"This will restart the Python kernel. You'll lose all data that's in memory. You will also lose any unsaved changes, so make sure to save your work before restarting.",variant:"destructive",confirmAction:(0,a.jsx)(la,{onClick:async()=>{n({state:Te.CLOSING}),await o(),Va()},"aria-label":"Confirm Restart",children:"Restart"})})},e[0]=t,e[1]=o,e[2]=n,e[3]=s):s=e[3],s}var Pn=z(),Tn=new Yt,Ln=e=>Tn.isSupported(e)?"markdown":"code";const Ct=()=>{let e=(0,Pn.c)(3),{updateCellConfig:t}=Ae(),{saveCellConfig:n}=T(),o;return e[0]!==n||e[1]!==t?(o=async(s,l)=>{let r=De(),d={};for(let c of r.cellIds.inOrderIds){let h=r.cellData[c];h===void 0||h.config.hide_code===s||Ln(h.code)===l&&(d[c]={hide_code:s})}let i=Ie.entries(d);if(i.length!==0){await n({configs:d});for(let[c,h]of i)t({cellId:c,config:h})}},e[0]=n,e[1]=t,e[2]=o):o=e[2],o};var On=z(),O=e=>{e==null||e.preventDefault(),e==null||e.stopPropagation()};function Hn(){var ze,Me,We;let e=(0,On.c)(56),t=Ga(),{openModal:n,closeModal:o}=ne(),{toggleApplication:s}=Ht(),{selectedPanel:l}=$t(),[r]=St(Le),d=N(aa),i=Ct(),[c]=ea(),h=N(Dt),x=N(ta),{updateCellConfig:m,undoDeleteCell:b,clearAllCellOutputs:f,addSetupCellIfDoesntExist:y,collapseAllCells:w,expandAllCells:g}=Ae(),j=vt(),u=Ya(),H=En(t),S=R(wt),re=R(Jt),{handleClick:le}=Qt(),ie=R(Xt),{exportAsIPYNB:de,exportAsMarkdown:ce,readCode:A,saveCellConfig:he,updateCellOutputs:_}=T(),D=an(),me=N(Ut),ue=N(Vt),pe=N(qt),{selectedLayout:$}=$e(),{setLayoutView:fe}=qe(),q=kt(),B=((ze=c.sharing)==null?void 0:ze.html)??!0,U=((Me=c.sharing)==null?void 0:Me.wasm)??!0,Y=((We=c.sharing)==null?void 0:We.molab)??!0,Ne=!ee(),xe=$==="slides",Nt=no,zt=ao,K;e[0]!==t||e[1]!==D||e[2]!==_?(K=async p=>{let{preset:C,title:M}=p;if(!t){se();return}await He(M,async ye=>{await rt({takeScreenshots:()=>D({progress:ye}),updateCellOutputs:_}),await _n({preset:C,downloadPDF:ba})})},e[0]=t,e[1]=D,e[2]=_,e[3]=K):K=e[3];let E=K,V;e[4]===E?V=e[5]:(V=async()=>{if(Ne){await E({preset:"document",title:"Downloading Document PDF..."});return}let p=new Event("export-beforeprint"),C=new Event("export-afterprint");window.dispatchEvent(p),setTimeout(to,0),setTimeout(()=>window.dispatchEvent(C),0)},e[4]=E,e[5]=V);let G=V,J;e[6]!==de||e[7]!==t||e[8]!==D||e[9]!==_?(J=async()=>{if(!t){se();return}await He("Downloading IPYNB...",async p=>{await rt({takeScreenshots:()=>D({progress:p}),updateCellOutputs:_}),Re(await de({download:!1}))})},e[6]=de,e[7]=t,e[8]=D,e[9]=_,e[10]=J):J=e[10];let be=J,Q;e[11]===Symbol.for("react.memo_cache_sentinel")?(Q=(0,a.jsx)(fa,{size:14,strokeWidth:1.5}),e[11]=Q):Q=e[11];let X;e[12]===Symbol.for("react.memo_cache_sentinel")?(X=(0,a.jsx)(Fe,{size:14,strokeWidth:1.5}),e[12]=X):X=e[12];let I;e[13]===t?I=e[14]:(I=async()=>{if(!t){se();return}await Be({includeCode:!0})},e[13]=t,e[14]=I);let Z;return e[15]!==y||e[16]!==x||e[17]!==ue||e[18]!==h||e[19]!==f||e[20]!==o||e[21]!==w||e[22]!==H||e[23]!==E||e[24]!==g||e[25]!==ce||e[26]!==t||e[27]!==G||e[28]!==be||e[29]!==me||e[30]!==xe||e[31]!==d||e[32]!==n||e[33]!==le||e[34]!==A||e[35]!==j||e[36]!==u||e[37]!==he||e[38]!==$||e[39]!==l||e[40]!==i||e[41]!==S||e[42]!==ie||e[43]!==fe||e[44]!==re||e[45]!==B||e[46]!==Y||e[47]!==U||e[48]!==I||e[49]!==s||e[50]!==q||e[51]!==b||e[52]!==pe||e[53]!==m||e[54]!==r.mode?(Z=[{icon:Q,label:"Download",handle:O,dropdown:[{icon:X,label:"Download as HTML",handle:I},{icon:(0,a.jsx)(Fe,{size:14,strokeWidth:1.5}),label:"Download as HTML (exclude code)",handle:async()=>{if(!t){se();return}await Be({includeCode:!1})}},{icon:(0,a.jsx)(Qa,{strokeWidth:1.5,style:{width:14,height:14}}),label:"Download as Markdown",handle:async()=>{Re(await ce({download:!1}))}},{icon:(0,a.jsx)(dn,{size:14,strokeWidth:1.5}),label:"Download as ipynb",handle:be},{icon:(0,a.jsx)(Sa,{size:14,strokeWidth:1.5}),label:"Download Python code",handle:async()=>{let p=await A();ya(new Blob([p.contents],{type:"text/plain"}),xa.toPY(document.title))}},{divider:!0,icon:(0,a.jsx)(La,{size:14,strokeWidth:1.5}),label:"Download as PNG",disabled:r.mode!=="present",tooltip:r.mode==="present"?void 0:(0,a.jsxs)("span",{children:["Only available in app view. ",(0,a.jsx)("br",{}),"Toggle with: ",Ja("global.hideCode",!1)]}),handle:eo},xe?{divider:!0,icon:(0,a.jsx)(te,{size:14,strokeWidth:1.5}),label:"Download as PDF",handle:O,dropdown:[{icon:(0,a.jsx)(te,{size:14,strokeWidth:1.5}),label:"Document Layout",handle:G},{icon:(0,a.jsx)(te,{size:14,strokeWidth:1.5}),label:"Slides Layout",rightElement:zt(!0),hidden:!Ne,handle:async()=>{await E({preset:"slides",title:"Downloading Slides PDF..."})}}]}:{divider:!0,icon:(0,a.jsx)(te,{size:14,strokeWidth:1.5}),label:"Download as PDF",handle:G}]},{icon:(0,a.jsx)(Fa,{size:14,strokeWidth:1.5}),label:"Pair with an agent",hidden:ee(),handle:async()=>{n((0,a.jsx)(Za,{onClose:o}))}},{icon:(0,a.jsx)(hn,{size:14,strokeWidth:1.5}),label:"Share",handle:O,hidden:!B&&!U&&!Y,dropdown:[{icon:(0,a.jsx)(_a,{size:14,strokeWidth:1.5}),label:"Publish HTML to web",hidden:!B,handle:async()=>{n((0,a.jsx)(jn,{onClose:o}))}},{icon:(0,a.jsx)(Oa,{size:14,strokeWidth:1.5}),label:"Create WebAssembly link",hidden:!U,handle:async()=>{await ae(at({code:(await A()).contents})),W({title:"Copied",description:"Link copied to clipboard."})}},{icon:(0,a.jsx)(st,{size:14,strokeWidth:1.5}),label:"Create molab notebook",hidden:!Y,handle:async()=>{let p=at({code:(await A()).contents,baseUrl:`${v.molab}/new`});window.open(p,"_blank")}}]},{icon:(0,a.jsx)(cn,{size:14,strokeWidth:1.5}),label:"Helper panel",redundant:!0,handle:O,dropdown:Tt.flatMap(p=>{let C=p.type==="ai"&&!x;if(Ot({panel:p,capabilities:h,aiEnabled:x})&&!C)return[];let{type:M,Icon:ye,additionalKeywords:Mt}=p;return{label:we.startCase(M),rightElement:Nt(l===M),icon:(0,a.jsx)(ye,{size:14,strokeWidth:1.5}),handle:()=>{if(C){le("ai","ai-features");return}s(M)},additionalKeywords:Mt}})},{icon:(0,a.jsx)(mt,{size:14,strokeWidth:1.5}),label:"Present as",handle:O,dropdown:[{icon:r.mode==="present"?(0,a.jsx)($a,{size:14,strokeWidth:1.5}):(0,a.jsx)(Na,{size:14,strokeWidth:1.5}),label:"Toggle app view",hotkey:"global.hideCode",handle:()=>{q()}},...lt.map((p,C)=>{let M=gt(p);return{divider:C===0,label:jt(p),icon:(0,a.jsx)(M,{size:14,strokeWidth:1.5}),rightElement:(0,a.jsx)("div",{className:"w-8 flex justify-end",children:$===p&&(0,a.jsx)(Ue,{size:14})}),handle:()=>{fe(p),r.mode==="edit"&&q()}}})]},{icon:(0,a.jsx)(rn,{size:14,strokeWidth:1.5}),label:"Duplicate notebook",hidden:!t||ee(),handle:H},{icon:(0,a.jsx)(it,{size:14,strokeWidth:1.5}),label:"Copy code to clipboard",hidden:!t,handle:async()=>{await ae((await A()).contents),W({title:"Copied",description:"Code copied to clipboard."})}},{icon:(0,a.jsx)(Wa,{size:14,strokeWidth:1.5}),label:"Enable all cells",hidden:!me||d,handle:async()=>{let p=Kt(De());await he({configs:Ie.fromEntries(p.map(Zn))});for(let C of p)m({cellId:C,config:{disabled:!1}})}},{divider:!0,icon:(0,a.jsx)(ct,{size:14,strokeWidth:1.5}),label:"Add setup cell",handle:()=>{y({})}},{icon:(0,a.jsx)(Bt,{size:14,strokeWidth:1.5}),label:"Add database connection",handle:()=>{n((0,a.jsx)(Ve,{onClose:o}))}},{icon:(0,a.jsx)(Pa,{size:14,strokeWidth:1.5}),label:"Add remote storage",handle:()=>{n((0,a.jsx)(Ve,{defaultTab:"storage",onClose:o}))}},{icon:(0,a.jsx)(ut,{size:14,strokeWidth:1.5}),label:pe,hidden:!ue||d,handle:()=>{b()}},{icon:(0,a.jsx)(mn,{size:14,strokeWidth:1.5}),label:"Restart kernel",variant:"danger",handle:j,additionalKeywords:["reset","reload","restart"]},{icon:(0,a.jsx)(sn,{size:14,strokeWidth:1.5}),label:"Re-run all cells",redundant:!0,hotkey:"global.runAll",handle:async()=>{u()}},{icon:(0,a.jsx)(Ft,{size:14,strokeWidth:1.5}),label:"Clear all outputs",redundant:!0,handle:()=>{f()}},{icon:(0,a.jsx)(Ee,{size:14,strokeWidth:1.5}),label:"Show all code",hotkey:"global.showAllCode",handle:()=>i(!1,"code"),redundant:!0},{icon:(0,a.jsx)(Ye,{size:14,strokeWidth:1.5}),label:"Hide all code",hotkey:"global.hideAllCode",handle:()=>i(!0,"code"),redundant:!0},{icon:(0,a.jsx)(Ee,{size:14,strokeWidth:1.5}),label:"Show all markdown code",hotkey:"global.showAllMarkdownCode",handle:()=>i(!1,"markdown"),redundant:!0},{icon:(0,a.jsx)(Ye,{size:14,strokeWidth:1.5}),label:"Hide all markdown code",hotkey:"global.hideAllMarkdownCode",handle:()=>i(!0,"markdown"),redundant:!0},{icon:(0,a.jsx)(on,{size:14,strokeWidth:1.5}),label:"Collapse all sections",hotkey:"global.collapseAllSections",handle:w,redundant:!0},{icon:(0,a.jsx)(nn,{size:14,strokeWidth:1.5}),label:"Expand all sections",hotkey:"global.expandAllSections",handle:g,redundant:!0},{divider:!0,icon:(0,a.jsx)(dt,{size:14,strokeWidth:1.5}),label:"Command palette",hotkey:"global.commandPalette",handle:()=>S(Xn)},{icon:(0,a.jsx)(za,{size:14,strokeWidth:1.5}),label:"Keyboard shortcuts",hotkey:"global.showHelp",handle:()=>ie(Qn)},{icon:(0,a.jsx)(Ra,{size:14,strokeWidth:1.5}),label:"User settings",handle:()=>re(Jn),redundant:!0,additionalKeywords:["preferences","options","configuration"]},{icon:(0,a.jsx)(ht,{size:14,strokeWidth:1.5}),label:"Report an issue",additionalKeywords:["feedback","bug","issue","report","diagnostics"],handle:()=>n((0,a.jsx)(bt,{onClose:o}))},{icon:(0,a.jsx)(Ke,{size:14,strokeWidth:1.5}),label:"Resources",handle:O,dropdown:[{icon:(0,a.jsx)(Rt,{size:14,strokeWidth:1.5}),label:"Documentation",handle:Gn},{icon:(0,a.jsx)(en,{className:"h-3.5 w-3.5"}),label:"GitHub",handle:Vn},{icon:(0,a.jsx)(Da,{size:14,strokeWidth:1.5}),label:"Discord Community",handle:Kn},{icon:(0,a.jsx)(Ia,{className:"h-3.5 w-3.5"}),label:"YouTube",handle:Yn},{icon:(0,a.jsx)(It,{size:14,strokeWidth:1.5}),label:"Changelog",handle:Un}]},{divider:!0,icon:(0,a.jsx)(Ta,{size:14,strokeWidth:1.5}),label:"Open home",hidden:!location.search.includes("file"),handle:Bn},{icon:(0,a.jsx)(st,{size:14,strokeWidth:1.5}),label:"New notebook",hidden:!location.search.includes("file"),handle:qn}].filter($n).map(Rn),e[15]=y,e[16]=x,e[17]=ue,e[18]=h,e[19]=f,e[20]=o,e[21]=w,e[22]=H,e[23]=E,e[24]=g,e[25]=ce,e[26]=t,e[27]=G,e[28]=be,e[29]=me,e[30]=xe,e[31]=d,e[32]=n,e[33]=le,e[34]=A,e[35]=j,e[36]=u,e[37]=he,e[38]=$,e[39]=l,e[40]=i,e[41]=S,e[42]=ie,e[43]=fe,e[44]=re,e[45]=B,e[46]=Y,e[47]=U,e[48]=I,e[49]=s,e[50]=q,e[51]=b,e[52]=pe,e[53]=m,e[54]=r.mode,e[55]=Z):Z=e[55],Z}function Rn(e){return e.dropdown?{...e,dropdown:e.dropdown.filter(Fn)}:e}function Fn(e){return!e.hidden}function $n(e){return!e.hidden}function qn(){let e=Ua();window.open(e,"_blank")}function Bn(){let e=document.baseURI.split("?")[0];window.open(e,"_blank","noopener")}function Un(){window.open(v.releasesPage,"_blank")}function Yn(){window.open(v.youtube,"_blank")}function Kn(){window.open(v.discordLink,"_blank")}function Vn(){window.open(v.githubPage,"_blank")}function Gn(){window.open(v.docsPage,"_blank")}function Jn(e){return!e}function Qn(e){return!e}function Xn(e){return!e}function Zn(e){return[e,{disabled:!1}]}async function eo(){let e=document.getElementById("App");e&&await ka({element:e,filename:document.title,prepare:wa})}function to(){return window.print()}function ao(e){return e?(0,a.jsx)("span",{className:"ml-3 shrink-0 rounded-full border border-emerald-200 bg-emerald-50 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wide text-emerald-700",children:"Recommended"}):null}function no(e){return(0,a.jsx)("div",{className:"w-8 flex justify-end",children:e&&(0,a.jsx)(Ue,{size:14})})}function se(){W({title:"Error",description:"Notebooks must be named to be exported.",variant:"danger"})}export{wt as a,je as c,ct as d,dt as f,Wn as i,ut as l,Ct as n,kt as o,it as p,vt as r,wn as s,Hn as t,ht as u};