@marimo-team/frontend 0.24.1-dev99 → 0.24.2-dev129

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 (304) hide show
  1. package/dist/assets/{CellStatus-wvvZkEPY.js → CellStatus-LoTwk7fR.js} +1 -1
  2. package/dist/assets/{ConnectedDataExplorerComponent-Dkqk66Mv.js → ConnectedDataExplorerComponent-DW6cJ-Lr.js} +1 -1
  3. package/dist/assets/{ErrorBoundary-npvnLp9x.js → ErrorBoundary-CDVGFYfr.js} +1 -1
  4. package/dist/assets/JsonOutput-CzIGPEZQ.js +50 -0
  5. package/dist/assets/{LazyAnyLanguageCodeMirror-zSwE3dvU.js → LazyAnyLanguageCodeMirror-LboTfNDv.js} +2 -2
  6. package/dist/assets/{MarimoErrorOutput-CeUo5oka.js → MarimoErrorOutput-DqpoYOvw.js} +1 -1
  7. package/dist/assets/RenderHTML-DwhMAd9l.js +1 -0
  8. package/dist/assets/{RunButton-BaV8A-z4.js → RunButton-BlpbweyH.js} +1 -1
  9. package/dist/assets/{VisuallyHidden-SChAyKIQ.js → VisuallyHidden-CBMDmozt.js} +1 -1
  10. package/dist/assets/{add-cell-with-ai-DoLkfzYn.js → add-cell-with-ai-R-3DS79K.js} +1 -1
  11. package/dist/assets/{add-connection-dialog-C1IF1nR0.js → add-connection-dialog-BGfpw5lC.js} +1 -1
  12. package/dist/assets/{agent-panel-CG154QrU.js → agent-panel-Cgt_K0tD.js} +1 -1
  13. package/dist/assets/ai-model-dropdown-DCmiuk7x.js +3 -0
  14. package/dist/assets/alert-dialog-CA-2mBs3.js +11 -0
  15. package/dist/assets/any-language-editor-DflLjPSQ.js +1 -0
  16. package/dist/assets/{app-config-button-ktBH1pEB.js → app-config-button-DUJC6b6x.js} +1 -1
  17. package/dist/assets/badge-BSgtkC2e.js +1 -0
  18. package/dist/assets/{blob-DVtvZmWH.js → blob-B2d_dHwI.js} +1 -1
  19. package/dist/assets/button-Dh8EwhsF.js +1 -0
  20. package/dist/assets/{cache-panel-C7jsiqCa.js → cache-panel-DqgtC98s.js} +1 -1
  21. package/dist/assets/{capabilities-LWzb3E3M.js → capabilities-D8kPgMKr.js} +1 -1
  22. package/dist/assets/{cell-editor-DoDqaCZp.js → cell-editor-Dw09J9yD.js} +6 -6
  23. package/dist/assets/{cell-link-Dqqt6Rgs.js → cell-link-6burT2XF.js} +1 -1
  24. package/dist/assets/{cells-D4RwofRx.js → cells-Cp-G34Rz.js} +56 -56
  25. package/dist/assets/{chat-display-COmzHgx5.js → chat-display-Bu405iyc.js} +1 -1
  26. package/dist/assets/{chat-panel-B2tyEfGW.js → chat-panel-BlUwNY5j.js} +1 -1
  27. package/dist/assets/{chat-ui-B5bsr-7V.js → chat-ui-DGiVDzNh.js} +1 -1
  28. package/dist/assets/{circle--ysFeW9z.js → circle-ByJdIf5p.js} +1 -1
  29. package/dist/assets/{column-preview-CW5DPFvy.js → column-preview-riSXbYe_.js} +1 -1
  30. package/dist/assets/{command-palette-B9dyvMvJ.js → command-palette-CCVzJcyf.js} +1 -1
  31. package/dist/assets/{common-CC3tuCpi.js → common-CHR7w7aQ.js} +1 -1
  32. package/dist/assets/{components-D02ZZZMP.js → components-C7mWrmXr.js} +1 -1
  33. package/dist/assets/{components-CBlGIIAX.js → components-DUYCXngU.js} +1 -1
  34. package/dist/assets/config-B-r81uZ6.js +1 -0
  35. package/dist/assets/{config-D4frVGQ4.js → config-BlNM0caL.js} +1 -1
  36. package/dist/assets/{copy-Cg05mM3C.js → copy-DlEomWzI.js} +1 -1
  37. package/dist/assets/{copy-icon-CRxVZTJ9.js → copy-icon-z8fuTE3w.js} +1 -1
  38. package/dist/assets/{createReducer-Bq-nQJiK.js → createReducer-B_XmHROl.js} +1 -1
  39. package/dist/assets/{datasource-Do8f2hFf.js → datasource-DrODSIs0.js} +1 -1
  40. package/dist/assets/{dates-DK5JikJo.js → dates-B58T85Jq.js} +1 -1
  41. package/dist/assets/dependency-graph-panel-AY5BEVH2.js +5 -0
  42. package/dist/assets/{dist-7qdHLg-L.js → dist-B0RXffUm.js} +1 -1
  43. package/dist/assets/dist-B0qYy1Ye.js +1 -0
  44. package/dist/assets/{dist-B97dKQGP.js → dist-B8pdsUrS.js} +1 -1
  45. package/dist/assets/{dist-BcfF-rkl.js → dist-BF7Lrekv.js} +1 -1
  46. package/dist/assets/dist-BL8RjfvI.js +1 -0
  47. package/dist/assets/dist-BVZxge7j.js +1 -0
  48. package/dist/assets/{dist-fxnYzq-R.js → dist-BaRNSaca.js} +1 -1
  49. package/dist/assets/dist-Bk2yQtw4.js +1 -0
  50. package/dist/assets/dist-BsfiiKoy.js +1 -0
  51. package/dist/assets/dist-BskmVd3B.js +1 -0
  52. package/dist/assets/{dist-DL1Thauf.js → dist-Bsu3h9O7.js} +1 -1
  53. package/dist/assets/{dist-PIe1xcZo.js → dist-BtC9ym6k.js} +7 -7
  54. package/dist/assets/{dist-DeuWxYVk.js → dist-Bv0S1RlZ.js} +1 -1
  55. package/dist/assets/{dist-CidBzUqR.js → dist-C--ZICxQ.js} +1 -1
  56. package/dist/assets/dist-C-2fD3XY.js +1 -0
  57. package/dist/assets/{dist-DzAWvPVK.js → dist-CKUpxYGQ.js} +1 -1
  58. package/dist/assets/dist-CMFMfBm1.js +1 -0
  59. package/dist/assets/dist-CZNULd6Z.js +2 -0
  60. package/dist/assets/dist-CjFduPiC.js +1 -0
  61. package/dist/assets/{dist-DoAjHgMj.js → dist-CmImLjus.js} +1 -1
  62. package/dist/assets/{dist-BKx0MLbb.js → dist-Cq8NOszX.js} +1 -1
  63. package/dist/assets/{dist-DCc0VfiO.js → dist-Cx4BE7jC.js} +3 -3
  64. package/dist/assets/dist-D45ScydS.js +1 -0
  65. package/dist/assets/dist-D6dg87r7.js +1 -0
  66. package/dist/assets/dist-DEjfQLz0.js +1 -0
  67. package/dist/assets/{dist-BcYW-EJk.js → dist-DJOWOALB.js} +1 -1
  68. package/dist/assets/{dist-CxxZaSme.js → dist-DPoYlxSC.js} +1 -1
  69. package/dist/assets/dist-DR-Y-nl3.js +1 -0
  70. package/dist/assets/dist-Dahlp9JQ.js +1 -0
  71. package/dist/assets/{dist-DIkuvChK.js → dist-Db-HC93w.js} +1 -1
  72. package/dist/assets/{dist-DTM7BAUu.js → dist-DdOlZ6mj.js} +1 -1
  73. package/dist/assets/{dist-Dz_04liz.js → dist-DiYjQAhI.js} +1 -1
  74. package/dist/assets/{dist-BO5c5n_b.js → dist-DkPPv0FB.js} +1 -1
  75. package/dist/assets/{dist-DkCO0b-0.js → dist-DmGtPaVM.js} +1 -1
  76. package/dist/assets/{dist-CXmhxecl.js → dist-DnxYYyU7.js} +1 -1
  77. package/dist/assets/{dist-CO1Hfv5H.js → dist-Dw9YRsCU.js} +1 -1
  78. package/dist/assets/dist-Dwx3KdUP.js +1 -0
  79. package/dist/assets/{dist-BgL43w5r.js → dist-DzCQtGkt.js} +1 -1
  80. package/dist/assets/dist-JweaDt6P.js +1 -0
  81. package/dist/assets/{dist-Dbu5sPgR.js → dist-gELFCfHH.js} +1 -1
  82. package/dist/assets/dist-kGDJ0AWF.js +1 -0
  83. package/dist/assets/{dist-Cqm1W-Zm.js → dist-kaLvV_d4.js} +1 -1
  84. package/dist/assets/{dist-CEeRVpMD.js → dist-qvk3g06H.js} +1 -1
  85. package/dist/assets/dist-wCw2twuB.js +1 -0
  86. package/dist/assets/dist-wF42tUcr.js +1 -0
  87. package/dist/assets/dist-wY2yia-1.js +3 -0
  88. package/dist/assets/{documentation-panel-DvHjxlli.js → documentation-panel-CaJF7e-j.js} +1 -1
  89. package/dist/assets/{download-BP8MrprC.js → download-DMxOzI7b.js} +1 -1
  90. package/dist/assets/dropdown-menu-C40jM9o4.js +1 -0
  91. package/dist/assets/{edit-page-71cK-Nhe.js → edit-page-Vqd9NedM.js} +6 -6
  92. package/dist/assets/{error-banner-BYN8YUMe.js → error-banner-Dw5YY9wq.js} +1 -1
  93. package/dist/assets/{error-entries-DOZ1u97X.js → error-entries-Cv2m1yhc.js} +1 -1
  94. package/dist/assets/{error-panel-CINcf76Z.js → error-panel-Bhlvt6_H.js} +1 -1
  95. package/dist/assets/{es-BuMFDpR4.js → es-CrFhA96G.js} +1 -1
  96. package/dist/assets/{esm-Dw0vvSg2.js → esm-BHMOvJzM.js} +1 -1
  97. package/dist/assets/{esm-BGpfQNhD.js → esm-DmqQGMel.js} +1 -1
  98. package/dist/assets/file-explorer-panel-6HvNfCrJ.js +1 -0
  99. package/dist/assets/{file-icons-DgKj9mrV.js → file-icons-DdGYuADJ.js} +1 -1
  100. package/dist/assets/file-name-input-K4MKESI_.js +3 -0
  101. package/dist/assets/{floating-outline-CRXIsrPm.js → floating-outline-DaUHnl_e.js} +1 -1
  102. package/dist/assets/{formats-DSzGCKeO.js → formats-C6s96nu2.js} +1 -1
  103. package/dist/assets/{formatting-BJlT1s_3.js → formatting-BWZH2nBg.js} +1 -1
  104. package/dist/assets/{fullscreen-0EEPR7uc.js → fullscreen-BH2jz-F4.js} +5 -5
  105. package/dist/assets/{gallery-page-TqnFYECu.js → gallery-page-C3pBpHlY.js} +1 -1
  106. package/dist/assets/{glide-data-editor-DcY3nXI8.js → glide-data-editor-sICUMEhk.js} +1 -1
  107. package/dist/assets/{glide-utils-CR1sWLZU.js → glide-utils-UGsrRHYj.js} +1 -1
  108. package/dist/assets/home-page-BLd6rnbk.js +4 -0
  109. package/dist/assets/{html-to-image-DMn_7CCA.js → html-to-image-D6GUC5q6.js} +1 -1
  110. package/dist/assets/index-BGT7have.css +2 -0
  111. package/dist/assets/index-ipFYAeCF.js +29 -0
  112. package/dist/assets/{input-Daz6sk8l.js → input-DEbY281O.js} +2 -2
  113. package/dist/assets/{kiosk-mode-CzGt3mc2.js → kiosk-mode-mxgb5lWf.js} +1 -1
  114. package/dist/assets/{layout-KJMQADEj.js → layout-DWnrxIo2.js} +5 -5
  115. package/dist/assets/links-DLvOXyO_.js +1 -0
  116. package/dist/assets/{logs-panel-DFibPeCT.js → logs-panel-BGS2v3ba.js} +1 -1
  117. package/dist/assets/lua-1tNpM92n.js +1 -0
  118. package/dist/assets/{lua-CRIS5afH.js → lua-DXBxhmso.js} +1 -1
  119. package/dist/assets/{markdown-renderer-CdZX2MvM.js → markdown-renderer-BZKlbm2Q.js} +1 -1
  120. package/dist/assets/menu-items-BSRA2YI9.js +1 -0
  121. package/dist/assets/{mermaid-CeseGGnS.js → mermaid-l6lQkCib.js} +1 -1
  122. package/dist/assets/{name-cell-input-B-d5Jwh4.js → name-cell-input-BMCdK-el.js} +1 -1
  123. package/dist/assets/{numbers-DKurV_vq.js → numbers-Bc-r3jsC.js} +1 -1
  124. package/dist/assets/{outline-panel-D2Wk10hY.js → outline-panel-Dr5u73V6.js} +1 -1
  125. package/dist/assets/{packages-panel-CQsbxIlG.js → packages-panel-BdpRg9tX.js} +1 -1
  126. package/dist/assets/{pair-with-agent-modal-CNxmIMFM.js → pair-with-agent-modal-CbUFKJHP.js} +1 -1
  127. package/dist/assets/{panel-accordion-state-D6-FMXE2.js → panel-accordion-state-DjUTN7i5.js} +1 -1
  128. package/dist/assets/{panels-BgcK_4M7.js → panels-CWn0Yh1D.js} +1 -1
  129. package/dist/assets/process-output-Ck7-P_xp.js +1 -0
  130. package/dist/assets/{readonly-code-display-BvqLeUsJ.js → readonly-code-display--S2daDa6.js} +1 -1
  131. package/dist/assets/{readonly-python-code-GSN4D4sb.js → readonly-python-code-DpIyjHqY.js} +1 -1
  132. package/dist/assets/{renderShortcut-DK_OucLT.js → renderShortcut-X-CJUSM8.js} +1 -1
  133. package/dist/assets/{reveal-component-u9ED2diI.js → reveal-component-nZIAapoD.js} +1 -1
  134. package/dist/assets/{run-page-U5iuhyz8.js → run-page-9pl8qhQR.js} +1 -1
  135. package/dist/assets/{runs-BQTlv6Ja.js → runs-euHSzlw_.js} +1 -1
  136. package/dist/assets/{scratchpad-panel--YOR0kUB.js → scratchpad-panel-BleGt2KM.js} +1 -1
  137. package/dist/assets/{scroll-to-bottom-button-xua0e9rA.js → scroll-to-bottom-button-DufiYUD7.js} +1 -1
  138. package/dist/assets/{secrets-panel-CZPbFAZH.js → secrets-panel-D3BpDIgg.js} +1 -1
  139. package/dist/assets/select-nLt2y0Sw.js +1 -0
  140. package/dist/assets/{session-CEdta5_Q.js → session-Sz5nSFku.js} +1 -1
  141. package/dist/assets/session-panel-DRGPlL5J.js +1 -0
  142. package/dist/assets/{share-C2MPy_VX.js → share-CPtBiNgr.js} +1 -1
  143. package/dist/assets/{skeleton-CsceCAjw.js → skeleton-BKeh8hf3.js} +1 -1
  144. package/dist/assets/{snippets-panel-BxwHsPmW.js → snippets-panel-D5yy7kj0.js} +1 -1
  145. package/dist/assets/{spec-CUFquO6R.js → spec-DKsAmLTi.js} +1 -1
  146. package/dist/assets/{state-BqrF--O0.js → state-B6AklCzD.js} +1 -1
  147. package/dist/assets/{state-C2c3_VuY.js → state-B8XRqyFg.js} +1 -1
  148. package/dist/assets/{state-CHplO0zn.js → state-Di9TbuV9.js} +1 -1
  149. package/dist/assets/{strings-CpYReX2Q.js → strings-CReV1AYG.js} +1 -1
  150. package/dist/assets/{swiper-component-Bot7ehYH.js → swiper-component-5Kdi1-Gn.js} +1 -1
  151. package/dist/assets/{switch-CtH5Ct94.js → switch-DjXr9Y9D.js} +1 -1
  152. package/dist/assets/{tabs-c6mpccpH.js → tabs-Cy1qXLzH.js} +1 -1
  153. package/dist/assets/{terminal-C73iz1fU.js → terminal-CQAFGBfN.js} +1 -1
  154. package/dist/assets/{tooltip-Cwltdez8.js → tooltip-BG35uS_N.js} +1 -1
  155. package/dist/assets/{tooltip-D7dq6bnc.js → tooltip-BUtPzKB4.js} +1 -1
  156. package/dist/assets/{tracing-Dhq121dR.js → tracing-DNk3gmWv.js} +1 -1
  157. package/dist/assets/{tracing-panel-IKt1933_.js → tracing-panel-Yqazr6w_.js} +2 -2
  158. package/dist/assets/{tree-actions-DIfWonCA.js → tree-actions-CG5g7aUQ.js} +1 -1
  159. package/dist/assets/{useAddCell-BYrVaYfZ.js → useAddCell-DdB_uBif.js} +1 -1
  160. package/dist/assets/{useBoolean-ZU5StAbr.js → useBoolean-BXC4CItZ.js} +1 -1
  161. package/dist/assets/{useCellActionButton-DbXDs0MA.js → useCellActionButton-B31neI3m.js} +1 -1
  162. package/dist/assets/{useDebounce-Dulm61-t.js → useDebounce-DgpSQhrP.js} +1 -1
  163. package/dist/assets/{useDeleteCell-Wgcl3CRG.js → useDeleteCell-Bz49_cFj.js} +1 -1
  164. package/dist/assets/{useDependencyPanelTab-C5AU8GKL.js → useDependencyPanelTab-C_ps0r--.js} +1 -1
  165. package/dist/assets/{useEventListener-D27Dii_l.js → useEventListener-92uWqz-P.js} +1 -1
  166. package/dist/assets/{useIframeCapabilities-DEpTCh1Q.js → useIframeCapabilities-C7Di8f2y.js} +1 -1
  167. package/dist/assets/{useInstallPackage-u7d0wo79.js → useInstallPackage-DsD08SLK.js} +1 -1
  168. package/dist/assets/{useInterval-B1_J4wdT.js → useInterval-B4v7_zd0.js} +1 -1
  169. package/dist/assets/{useNotebookActions-FuMERtHq.js → useNotebookActions-CQtbk9CB.js} +2 -2
  170. package/dist/assets/{useRunCells-DTdMRbkE.js → useRunCells-CX7oW5zy.js} +1 -1
  171. package/dist/assets/{useSplitCell-2z0zEB8X.js → useSplitCell-Dy2_DmJR.js} +1 -1
  172. package/dist/assets/{useTheme-CF-zG9YH.js → useTheme-C-ri8BtY.js} +1 -1
  173. package/dist/assets/utils-D5Ywm7-q.js +1 -0
  174. package/dist/assets/{vega-component-BSXJcTJb.js → vega-component-C7TCzyaU.js} +1 -1
  175. package/dist/assets/write-secret-modal-D6zoZgLY.js +2 -0
  176. package/dist/index.html +73 -73
  177. package/package.json +26 -26
  178. package/src/components/ai/ai-provider-icon.tsx +2 -2
  179. package/src/components/ai/ai-utils.ts +1 -1
  180. package/src/components/app-config/ai-config.tsx +33 -37
  181. package/src/components/app-config/user-config-form.tsx +1 -1
  182. package/src/components/data-table/__tests__/column-explorer.test.tsx +64 -4
  183. package/src/components/data-table/__tests__/column-visibility-dropdown.test.tsx +137 -4
  184. package/src/components/data-table/__tests__/url-detector.test.tsx +1 -1
  185. package/src/components/data-table/__tests__/useColumnVisibility.test.ts +153 -1
  186. package/src/components/data-table/column-explorer-panel/column-explorer.tsx +54 -25
  187. package/src/components/data-table/column-visibility-dropdown.tsx +62 -14
  188. package/src/components/data-table/date-popover.tsx +2 -1
  189. package/src/components/data-table/hooks/use-column-visibility.ts +76 -0
  190. package/src/components/data-table/renderers.tsx +4 -8
  191. package/src/components/data-table/show-only-column-button.tsx +58 -0
  192. package/src/components/dependency-graph/__tests__/elements.test.ts +151 -0
  193. package/src/components/dependency-graph/custom-edge.tsx +68 -0
  194. package/src/components/dependency-graph/custom-node.tsx +54 -26
  195. package/src/components/dependency-graph/dependency-graph-tree.tsx +110 -21
  196. package/src/components/dependency-graph/elements.ts +225 -31
  197. package/src/components/dependency-graph/panels.tsx +23 -2
  198. package/src/components/dependency-graph/utils/__tests__/layout.test.ts +78 -0
  199. package/src/components/dependency-graph/utils/layout.ts +108 -18
  200. package/src/components/editor/Output.tsx +40 -0
  201. package/src/components/editor/__tests__/Output.test.tsx +85 -2
  202. package/src/components/editor/connections/secret-combobox.tsx +3 -1
  203. package/src/components/editor/file-tree/__tests__/file-explorer-navigation.test.tsx +832 -0
  204. package/src/components/editor/file-tree/__tests__/file-viewer.test.tsx +27 -0
  205. package/src/components/editor/file-tree/__tests__/requesting-tree.test.ts +130 -0
  206. package/src/components/editor/file-tree/file-browser-row.tsx +82 -0
  207. package/src/components/editor/file-tree/file-explorer.tsx +377 -159
  208. package/src/components/editor/file-tree/file-operations.tsx +1 -1
  209. package/src/components/editor/file-tree/file-search-results.tsx +142 -0
  210. package/src/components/editor/file-tree/file-tree-row.tsx +40 -0
  211. package/src/components/editor/file-tree/file-viewer.tsx +2 -1
  212. package/src/components/editor/file-tree/renderers.tsx +4 -2
  213. package/src/components/editor/file-tree/requesting-tree.tsx +162 -32
  214. package/src/components/editor/file-tree/use-file-search.ts +142 -0
  215. package/src/components/editor/file-tree/use-hover-expand.ts +34 -0
  216. package/src/components/editor/navigation/__tests__/navigation.test.ts +30 -0
  217. package/src/components/editor/navigation/navigation.ts +20 -0
  218. package/src/components/forms/form.tsx +6 -4
  219. package/src/components/home/components.tsx +1 -0
  220. package/src/components/static-html/share-modal.tsx +3 -2
  221. package/src/components/ui/__tests__/badge.test.ts +63 -0
  222. package/src/components/ui/__tests__/button.test.ts +19 -0
  223. package/src/components/ui/__tests__/fullscreen.test.tsx +88 -0
  224. package/src/components/ui/__tests__/menu-items.test.ts +31 -0
  225. package/src/components/ui/badge.tsx +9 -7
  226. package/src/components/ui/button.tsx +1 -0
  227. package/src/components/ui/combobox.tsx +1 -1
  228. package/src/components/ui/date-input.tsx +1 -1
  229. package/src/components/ui/dialog.tsx +3 -1
  230. package/src/components/ui/fullscreen.tsx +43 -1
  231. package/src/components/ui/input.tsx +5 -1
  232. package/src/components/ui/links.tsx +2 -1
  233. package/src/components/ui/menu-items.tsx +9 -9
  234. package/src/components/ui/native-select.tsx +2 -2
  235. package/src/components/ui/navigation.tsx +1 -1
  236. package/src/components/ui/range-slider.tsx +5 -3
  237. package/src/components/ui/select.tsx +1 -1
  238. package/src/components/ui/sheet.tsx +1 -1
  239. package/src/components/ui/toast.tsx +8 -5
  240. package/src/components/ui/toaster.tsx +2 -2
  241. package/src/core/ai/ids/__tests__/ids.test.ts +0 -8
  242. package/src/core/ai/ids/ids.ts +1 -1
  243. package/src/core/cells/__tests__/add-missing-import.test.ts +20 -0
  244. package/src/core/codemirror/language/__tests__/utils.test.ts +1 -1
  245. package/src/core/config/config-schema.ts +1 -0
  246. package/src/core/hotkeys/hotkeys.ts +5 -0
  247. package/src/core/network/__tests__/requests-toasting.test.tsx +14 -0
  248. package/src/core/network/requests-toasting.tsx +1 -1
  249. package/src/css/globals.css +28 -0
  250. package/src/hooks/useEventListener.ts +1 -1
  251. package/src/plugins/core/RenderHTML.tsx +6 -4
  252. package/src/plugins/impl/MatrixPlugin.tsx +1 -1
  253. package/src/plugins/impl/code/any-language-editor.tsx +7 -4
  254. package/src/plugins/impl/data-frames/__tests__/schema.test.ts +34 -1
  255. package/src/plugins/impl/data-frames/forms/__tests__/__snapshots__/form.test.tsx.snap +25 -25
  256. package/src/plugins/impl/data-frames/schema.ts +5 -11
  257. package/src/plugins/impl/panel/__tests__/utils.test.ts +4 -4
  258. package/src/plugins/impl/vega/__tests__/vega.test.ts +1 -1
  259. package/src/stories/cell.stories.tsx +15 -11
  260. package/src/utils/__tests__/events.test.ts +1 -1
  261. package/dist/assets/JsonOutput-CRLQQVKf.js +0 -50
  262. package/dist/assets/RenderHTML-YkwVPe9V.js +0 -1
  263. package/dist/assets/ai-model-dropdown-CrSrb8Zz.js +0 -3
  264. package/dist/assets/alert-dialog-BVi_GyOB.js +0 -11
  265. package/dist/assets/any-language-editor-BL8H-DwB.js +0 -1
  266. package/dist/assets/badge-D_-uqy2N.js +0 -1
  267. package/dist/assets/button-Btj6GXNy.js +0 -1
  268. package/dist/assets/config-ycxJQP2b.js +0 -1
  269. package/dist/assets/dependency-graph-panel-Dg-tUB9T.js +0 -5
  270. package/dist/assets/dist-2oRmY-BC.js +0 -1
  271. package/dist/assets/dist-8lhGoJ54.js +0 -3
  272. package/dist/assets/dist-B4QaGCvF.js +0 -1
  273. package/dist/assets/dist-B_ABJVTW.js +0 -1
  274. package/dist/assets/dist-Bke0Ybxy.js +0 -1
  275. package/dist/assets/dist-Bw8CAY5i.js +0 -1
  276. package/dist/assets/dist-BwmO3SSk.js +0 -1
  277. package/dist/assets/dist-C3KxgR0m.js +0 -1
  278. package/dist/assets/dist-CLE562nZ.js +0 -1
  279. package/dist/assets/dist-CLi0j3bw.js +0 -1
  280. package/dist/assets/dist-CMIyXejt.js +0 -1
  281. package/dist/assets/dist-CbQrIaPV.js +0 -2
  282. package/dist/assets/dist-CpgfIIzU.js +0 -1
  283. package/dist/assets/dist-D7aYPqs9.js +0 -1
  284. package/dist/assets/dist-DKCF5R0T.js +0 -1
  285. package/dist/assets/dist-DbFa9cik.js +0 -1
  286. package/dist/assets/dist-DdPuhs_-.js +0 -1
  287. package/dist/assets/dist-DkfdZExz.js +0 -1
  288. package/dist/assets/dist-hOh6JBwi.js +0 -1
  289. package/dist/assets/dist-mY1j_5eA.js +0 -1
  290. package/dist/assets/dist-tg3aVnpD.js +0 -1
  291. package/dist/assets/dropdown-menu-CqNabM1f.js +0 -1
  292. package/dist/assets/file-explorer-panel-cflxW8a7.js +0 -1
  293. package/dist/assets/file-name-input-CQF4Ovwx.js +0 -3
  294. package/dist/assets/home-page-DPRHPAQM.js +0 -4
  295. package/dist/assets/index-BkIXRAbi.css +0 -2
  296. package/dist/assets/index-p49fbIlR.js +0 -29
  297. package/dist/assets/links-DPh7yoP-.js +0 -1
  298. package/dist/assets/lua-_4wuYo1j.js +0 -1
  299. package/dist/assets/menu-items-BSVrMleU.js +0 -1
  300. package/dist/assets/process-output-DvTtgoMs.js +0 -1
  301. package/dist/assets/select-czJLm6jf.js +0 -1
  302. package/dist/assets/session-panel-C_N3WGWQ.js +0 -1
  303. package/dist/assets/utils-CWSZQEjr.js +0 -1
  304. package/dist/assets/write-secret-modal-lNU_7c2x.js +0 -2
@@ -0,0 +1,11 @@
1
+ import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{t}from"./react-CBDbhulC.js";import{t as n}from"./compiler-runtime-CYIjoINj.js";import{i as r,o as i,r as a}from"./useEventListener-92uWqz-P.js";import{t as o}from"./cn-ldLVeaqm.js";import{t as s}from"./jsx-runtime-B74pBk57.js";import{C as c,S as l,T as u,b as ee,c as te,d as ne,f as re,h as ie,i as ae,l as oe,p as se,s as ce,v as d,w as f,y as p}from"./fullscreen-BH2jz-F4.js";import{n as m}from"./button-Dh8EwhsF.js";var h=e(t(),1),g=s(),_=`Dialog`,[v,le]=f(_),[ue,y]=v(_),b=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=h.useRef(null),c=h.useRef(null),[l,u]=ee({prop:r,defaultProp:i??!1,onChange:a,caller:_});return(0,g.jsx)(ue,{scope:t,triggerRef:s,contentRef:c,contentId:d(),titleId:d(),descriptionId:d(),open:l,onOpenChange:u,onOpenToggle:h.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})};b.displayName=_;var x=`DialogTrigger`,de=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,a=y(x,n),o=i(t,a.triggerRef);return(0,g.jsx)(u.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":a.open,"aria-controls":a.contentId,"data-state":I(a.open),...r,ref:o,onClick:l(e.onClick,a.onOpenToggle)})});de.displayName=x;var S=`DialogPortal`,[fe,C]=v(S,{forceMount:void 0}),w=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=y(S,t);return(0,g.jsx)(fe,{scope:t,forceMount:n,children:h.Children.map(r,e=>(0,g.jsx)(p,{present:n||a.open,children:(0,g.jsx)(re,{asChild:!0,container:i,children:e})}))})};w.displayName=S;var T=`DialogOverlay`,E=h.forwardRef((e,t)=>{let n=C(T,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=y(T,e.__scopeDialog);return a.modal?(0,g.jsx)(p,{present:r||a.open,children:(0,g.jsx)(me,{...i,ref:t})}):null});E.displayName=T;var pe=a(`DialogOverlay.RemoveScroll`),me=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=y(T,n);return(0,g.jsx)(oe,{as:pe,allowPinchZoom:!0,shards:[i.contentRef],children:(0,g.jsx)(u.div,{"data-state":I(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),D=`DialogContent`,O=h.forwardRef((e,t)=>{let n=C(D,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=y(D,e.__scopeDialog);return(0,g.jsx)(p,{present:r||a.open,children:a.modal?(0,g.jsx)(he,{...i,ref:t}):(0,g.jsx)(ge,{...i,ref:t})})});O.displayName=D;var he=h.forwardRef((e,t)=>{let n=y(D,e.__scopeDialog),r=h.useRef(null),a=i(t,n.contentRef,r);return h.useEffect(()=>{let e=r.current;if(e)return te(e)},[]),(0,g.jsx)(k,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:l(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:l(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:l(e.onFocusOutside,e=>e.preventDefault())})}),ge=h.forwardRef((e,t)=>{let n=y(D,e.__scopeDialog),r=h.useRef(!1),i=h.useRef(!1);return(0,g.jsx)(k,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),k=h.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,...s}=e,c=y(D,n),l=h.useRef(null),u=i(t,l);return ne(),(0,g.jsxs)(g.Fragment,{children:[(0,g.jsx)(se,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:o,children:(0,g.jsx)(ie,{role:`dialog`,id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":I(c.open),...s,ref:u,onDismiss:()=>c.onOpenChange(!1)})}),(0,g.jsxs)(g.Fragment,{children:[(0,g.jsx)(ve,{titleId:c.titleId}),(0,g.jsx)(be,{contentRef:l,descriptionId:c.descriptionId})]})]})}),A=`DialogTitle`,j=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=y(A,n);return(0,g.jsx)(u.h2,{id:i.titleId,...r,ref:t})});j.displayName=A;var M=`DialogDescription`,N=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=y(M,n);return(0,g.jsx)(u.p,{id:i.descriptionId,...r,ref:t})});N.displayName=M;var P=`DialogClose`,F=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=y(P,n);return(0,g.jsx)(u.button,{type:`button`,...r,ref:t,onClick:l(e.onClick,()=>i.onOpenChange(!1))})});F.displayName=P;function I(e){return e?`open`:`closed`}var L=`DialogTitleWarning`,[_e,R]=c(L,{contentName:D,titleName:A,docsSlug:`dialog`}),ve=({titleId:e})=>{let t=R(L),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
+
3
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
+
5
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return h.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},ye=`DialogDescriptionWarning`,be=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${R(ye).contentName}}.`;return h.useEffect(()=>{let r=e.current?.getAttribute(`aria-describedby`);t&&r&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},z=b,B=de,V=w,H=E,U=O,W=j,G=N,K=F,q=`AlertDialog`,[xe,Se]=f(q,[le]),J=le(),Y=e=>{let{__scopeAlertDialog:t,...n}=e,r=J(t);return(0,g.jsx)(z,{...r,...n,modal:!0})};Y.displayName=q;var Ce=`AlertDialogTrigger`,we=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,i=J(n);return(0,g.jsx)(B,{...i,...r,ref:t})});we.displayName=Ce;var Te=`AlertDialogPortal`,Ee=e=>{let{__scopeAlertDialog:t,...n}=e,r=J(t);return(0,g.jsx)(V,{...r,...n})};Ee.displayName=Te;var De=`AlertDialogOverlay`,Oe=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,i=J(n);return(0,g.jsx)(H,{...i,...r,ref:t})});Oe.displayName=De;var X=`AlertDialogContent`,[ke,Ae]=xe(X),je=r(`AlertDialogContent`),Me=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,children:r,...a}=e,o=J(n),s=h.useRef(null),c=i(t,s),u=h.useRef(null);return(0,g.jsx)(_e,{contentName:X,titleName:Ne,docsSlug:`alert-dialog`,children:(0,g.jsx)(ke,{scope:n,cancelRef:u,children:(0,g.jsxs)(U,{role:`alertdialog`,...o,...a,ref:c,onOpenAutoFocus:l(a.onOpenAutoFocus,e=>{e.preventDefault(),u.current?.focus({preventScroll:!0})}),onPointerDownOutside:e=>e.preventDefault(),onInteractOutside:e=>e.preventDefault(),children:[(0,g.jsx)(je,{children:r}),(0,g.jsx)(Ve,{contentRef:s})]})})})});Me.displayName=X;var Ne=`AlertDialogTitle`,Pe=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,i=J(n);return(0,g.jsx)(W,{...i,...r,ref:t})});Pe.displayName=Ne;var Fe=`AlertDialogDescription`,Ie=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,i=J(n);return(0,g.jsx)(G,{...i,...r,ref:t})});Ie.displayName=Fe;var Le=`AlertDialogAction`,Re=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,i=J(n);return(0,g.jsx)(K,{...i,...r,ref:t})});Re.displayName=Le;var ze=`AlertDialogCancel`,Be=h.forwardRef((e,t)=>{let{__scopeAlertDialog:n,...r}=e,{cancelRef:a}=Ae(ze,n),o=J(n),s=i(t,a);return(0,g.jsx)(K,{...o,...r,ref:s})});Be.displayName=ze;var Ve=({contentRef:e})=>{let t=`\`${X}\` requires a description for the component to be accessible for screen reader users.
6
+
7
+ You can add a description to the \`${X}\` by passing a \`${Fe}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
8
+
9
+ Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${X}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
10
+
11
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return h.useEffect(()=>{document.getElementById(e.current?.getAttribute(`aria-describedby`))||console.warn(t)},[t,e]),null},He=Y,Ue=we,We=Ee,Ge=Oe,Ke=Me,Z=Re,qe=Be,Je=Pe,Ye=Ie,Q=n();function Xe(){let e=(0,Q.c)(3),[t,n]=(0,h.useState)(null),r;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=()=>{n(document.activeElement)},e[0]=r):r=e[0];let i=r,a;return e[1]===t?a=e[2]:(a={onOpenAutoFocus:i,onCloseAutoFocus:e=>{document.activeElement===document.body&&(t instanceof HTMLElement&&t.focus(),e.preventDefault())}},e[1]=t,e[2]=a),a}var Ze=He,Qe=Ue,$e=ae(({children:e,...t})=>(0,g.jsx)(We,{...t,children:(0,g.jsx)(ce,{children:(0,g.jsx)(`div`,{className:`fixed inset-0 z-50 flex items-end justify-center sm:items-start sm:top-[15%]`,children:e})})}));$e.displayName=We.displayName;var et=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;if(n[0]!==e){let{className:t,children:a,...o}=e;r=t,i=o,n[0]=e,n[1]=r,n[2]=i}else r=n[1],i=n[2];let a;n[3]===r?a=n[4]:(a=o(`fixed inset-0 z-50 bg-background/80 backdrop-blur-xs transition-opacity animate-in fade-in`,r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(Ge,{className:a,...i,ref:t}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});et.displayName=Ge.displayName;var tt=h.forwardRef((e,t)=>{let n=(0,Q.c)(11),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a=Xe(),s;n[3]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,g.jsx)(et,{}),n[3]=s):s=n[3];let c;n[4]===r?c=n[5]:(c=o(`fixed z-50 grid w-full max-w-2xl scale-100 gap-4 border bg-background p-6 opacity-100 shadow-sm animate-in fade-in-90 slide-in-from-bottom-10 sm:rounded-lg sm:zoom-in-90 sm:slide-in-from-bottom-0 md:w-full`,r),n[4]=r,n[5]=c);let l;return n[6]!==i||n[7]!==t||n[8]!==a||n[9]!==c?(l=(0,g.jsxs)($e,{children:[s,(0,g.jsx)(Ke,{ref:t,className:c,...a,...i})]}),n[6]=i,n[7]=t,n[8]=a,n[9]=c,n[10]=l):l=n[10],l});tt.displayName=Ke.displayName;var nt=e=>{let t=(0,Q.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=o(`flex flex-col space-y-2 text-center sm:text-left`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,g.jsx)(`div`,{className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a};nt.displayName=`AlertDialogHeader`;var rt=e=>{let t=(0,Q.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=o(`flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,g.jsx)(`div`,{className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a};rt.displayName=`AlertDialogFooter`;var it=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a;n[3]===r?a=n[4]:(a=o(`text-lg font-semibold`,r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(Je,{ref:t,className:a,...i}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});it.displayName=Je.displayName;var at=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a;n[3]===r?a=n[4]:(a=o(`text-muted-foreground`,r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(Ye,{ref:t,className:a,...i}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});at.displayName=Ye.displayName;var ot=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a;n[3]===r?a=n[4]:(a=o(m(),r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(Z,{ref:t,className:a,...i}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});ot.displayName=Z.displayName;var st=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a;n[3]===r?a=n[4]:(a=o(m({variant:`destructive`}),r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(Z,{ref:t,className:a,...i}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});st.displayName=`AlertDialogDestructiveAction`;var $=h.forwardRef((e,t)=>{let n=(0,Q.c)(9),r,i;n[0]===e?(r=n[1],i=n[2]):({className:r,...i}=e,n[0]=e,n[1]=r,n[2]=i);let a;n[3]===r?a=n[4]:(a=o(m({variant:`secondary`}),`mt-2 sm:mt-0`,r),n[3]=r,n[4]=a);let s;return n[5]!==i||n[6]!==t||n[7]!==a?(s=(0,g.jsx)(qe,{ref:t,className:a,...i}),n[5]=i,n[6]=t,n[7]=a,n[8]=s):s=n[8],s});$.displayName=qe.displayName;export{z as _,at as a,nt as c,Xe as d,K as f,V as g,H as h,tt as i,it as l,G as m,ot as n,st as o,U as p,$ as r,rt as s,Ze as t,Qe as u,W as v,B as y};
@@ -0,0 +1 @@
1
+ import"./rolldown-runtime-B0Z9INg1.js";import{t as e}from"./react-CBDbhulC.js";import{t}from"./compiler-runtime-CYIjoINj.js";import{g as n}from"./useEventListener-92uWqz-P.js";import{t as r}from"./jsx-runtime-B74pBk57.js";import{t as i}from"./copy-icon-z8fuTE3w.js";import{t as a}from"./esm-BHMOvJzM.js";import{n as o}from"./error-banner-Dw5YY9wq.js";import{n as s,t as c}from"./esm-DmqQGMel.js";var l=t();e();var u=r(),d={python:`py`,python3:`py`,javascript:`js`,typescript:`ts`,shell:`sh`,bash:`sh`,unknown:`text`,undefined:`text`},f=[];function p(e){return e?e in c:!1}var m=e=>{let t=(0,l.c)(29),r,m,h,g,_,v;if(t[0]!==e){let{language:n,hideUnsupportedLanguageErrors:i,showCopyButton:a,extensions:o,...s}=e;m=i,_=a,g=s,h=n,r=o===void 0?f:o,h=d[h||``]||h,v=p(h),t[0]=e,t[1]=r,t[2]=m,t[3]=h,t[4]=g,t[5]=_,t[6]=v}else r=t[1],m=t[2],h=t[3],g=t[4],_=t[5],v=t[6];let y=v;y||n.warn(`Language ${h} not found in CodeMirror.`);let b;bb0:{if(!p(h)){b=r;break bb0}let e;t[7]===h?e=t[8]:(e=s(h),t[7]=h,t[8]=e);let n;t[9]!==r||t[10]!==e?(n=[e,...r].filter(Boolean),t[9]=r,t[10]=e,t[11]=n):n=t[11],b=n}let x=b,S;t[12]!==m||t[13]!==y||t[14]!==h?(S=!y&&!m&&(0,u.jsx)(o,{className:`mb-1 rounded-sm`,error:`Language ${h} not supported. Supported languages are: ${Object.keys(c).join(`, `)}`}),t[12]=m,t[13]=y,t[14]=h,t[15]=S):S=t[15];let C;t[16]!==y||t[17]!==g||t[18]!==_?(C=_&&y&&(0,u.jsx)(i,{tooltip:!1,buttonClassName:`absolute top-2 right-2 z-10 hover-action`,className:`h-4 w-4 text-muted-foreground`,value:g.value||``,toastTitle:`Copied to clipboard`}),t[16]=y,t[17]=g,t[18]=_,t[19]=C):C=t[19];let w;t[20]===x?w=t[21]:(w=[...x],t[20]=x,t[21]=w);let T;t[22]!==g||t[23]!==w?(T=(0,u.jsx)(a,{...g,extensions:w}),t[22]=g,t[23]=w,t[24]=T):T=t[24];let E;return t[25]!==S||t[26]!==C||t[27]!==T?(E=(0,u.jsxs)(`div`,{className:`relative w-full group hover-actions-parent`,children:[S,C,T]}),t[25]=S,t[26]=C,t[27]=T,t[28]=E):E=t[28],E};export{d as LANGUAGE_MAP,m as default};
@@ -1 +1 @@
1
- import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{c as t}from"./useEvent-xfs0Sn4r.js";import{t as n}from"./react-CBDbhulC.js";import{Kn as r,Mn as i,Pn as a,_n as o,an as s,cn as c,gn as l,mn as u,nn as d,on as f,rn as p,sn as m,tn as h}from"./cells-D4RwofRx.js";import{t as g}from"./compiler-runtime-CYIjoINj.js";import{C as _,O as v,k as y}from"./utils-CWSZQEjr.js";import{E as b,d as x,f as S,i as C,n as w,u as T}from"./ai-model-dropdown-CrSrb8Zz.js";import{N as E}from"./config-D4frVGQ4.js";import{t as D}from"./jsx-runtime-B74pBk57.js";import{o as O}from"./alert-dialog-BVi_GyOB.js";import{l as k}from"./select-czJLm6jf.js";import{t as A}from"./tooltip-D7dq6bnc.js";import{t as j}from"./button-Btj6GXNy.js";import{s as M}from"./arrays-BqUx5USx.js";import{r as N}from"./requests-C6_IaFh7.js";import{t as P}from"./createLucideIcon-B7HeEoG2.js";import{r as F}from"./useNumberFormatter-DHJ9s6Vk.js";import{M as I,T as L,b as R,j as z,p as B,w as V}from"./write-secret-modal-lNU_7c2x.js";import{r as H}from"./input-Daz6sk8l.js";import{t as U}from"./settings-C-cYas75.js";import{t as W}from"./use-toast-DpWHUGuF.js";import{t as G}from"./VisuallyHidden-SChAyKIQ.js";import{n as K}from"./useDebounce-Dulm61-t.js";import{t as q}from"./kbd-Cwh96ZBE.js";import{t as J}from"./Inputs-E85rt2lh.js";var Y=P(`power-off`,[[`path`,{d:`M18.36 6.64A9 9 0 0 1 20.77 15`,key:`dxknvb`}],[`path`,{d:`M6.16 6.16a9 9 0 1 0 12.68 12.68`,key:`1x7qb5`}],[`path`,{d:`M12 2v4`,key:`3427ic`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),X=g(),Z=D(),ee=e=>{let t=(0,X.c)(15),{description:n,disabled:r,tooltip:i}=e,a=r!==void 0&&r,o=i===void 0?`Shutdown`:i,{openConfirm:s,closeModal:c}=R(),{sendShutdown:l}=N(),u;t[0]===l?u=t[1]:(u=()=>{l(),setTimeout(te,200)},t[0]=l,t[1]=u);let d=u;if(E())return null;let f=a?`disabled`:`red`,p;t[2]!==c||t[3]!==n||t[4]!==d||t[5]!==s?(p=e=>{e.stopPropagation(),s({title:`Shutdown`,description:n,variant:`destructive`,confirmAction:(0,Z.jsx)(O,{onClick:()=>{d(),c()},"aria-label":`Confirm Shutdown`,children:`Shutdown`})})},t[2]=c,t[3]=n,t[4]=d,t[5]=s,t[6]=p):p=t[6];let m;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,Z.jsx)(F,{strokeWidth:1}),t[7]=m):m=t[7];let h;t[8]!==a||t[9]!==f||t[10]!==p?(h=(0,Z.jsx)(J,{"aria-label":`Shutdown`,"data-testid":`shutdown-button`,shape:`circle`,size:`small`,color:f,className:`h-[27px] w-[27px]`,disabled:a,onClick:p,children:m}),t[8]=a,t[9]=f,t[10]=p,t[11]=h):h=t[11];let g;return t[12]!==h||t[13]!==o?(g=(0,Z.jsx)(A,{content:o,children:h}),t[12]=h,t[13]=o,t[14]=g):g=t[14],g};function te(){window.close()}var Q=e(n(),1),ne=100,re=()=>{let e=(0,X.c)(37),[t,n]=_(),{saveAppConfig:o}=N(),l=(0,Q.useId)(),u=(0,Q.useId)(),g;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(g=i(v),e[0]=g):g=e[0];let y;e[1]===t?y=e[2]:(y={resolver:g,defaultValues:t},e[1]=t,e[2]=y);let b=a(y),C;e[3]!==o||e[4]!==n?(C=async e=>{await o({config:e}).then(()=>{n(e)}).catch(()=>{n(e)})},e[3]=o,e[4]=n,e[5]=C):C=e[5];let w=C,T;e[6]===w?T=e[7]:(T=e=>{w(e)},e[6]=w,e[7]=T);let E=K(T,ne),D;e[8]===t.width?D=e[9]:(D=[t.width],e[8]=t.width,e[9]=D),(0,Q.useEffect)(ie,D);let O;e[10]!==E||e[11]!==b?(O=b.handleSubmit(E),e[10]=E,e[11]=b,e[12]=O):O=e[12];let k;e[13]===Symbol.for(`react.memo_cache_sentinel`)?(k=(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(S,{children:`Notebook Settings`}),(0,Z.jsx)(x,{children:`Configure how your notebook or application looks and behaves.`})]}),e[13]=k):k=e[13];let A;e[14]===b.control?A=e[15]:(A=(0,Z.jsxs)($,{title:`Display`,children:[(0,Z.jsx)(s,{control:b.control,name:`width`,render:oe}),(0,Z.jsx)(s,{control:b.control,name:`app_title`,render:se})]}),e[14]=b.control,e[15]=A);let j;e[16]===b.control?j=e[17]:(j=(0,Z.jsxs)($,{title:`Custom Files`,children:[(0,Z.jsx)(s,{control:b.control,name:`css_file`,render:ce}),(0,Z.jsx)(s,{control:b.control,name:`html_head_file`,render:le})]}),e[16]=b.control,e[17]=j);let P;e[18]===b.control?P=e[19]:(P=(0,Z.jsx)($,{title:`Data`,children:(0,Z.jsx)(s,{control:b.control,name:`sql_output`,render:de})}),e[18]=b.control,e[19]=P);let F;e[20]!==l||e[21]!==u?(F=e=>{let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-col gap-2`,children:[(0,Z.jsx)(d,{children:(0,Z.jsxs)(`div`,{className:`flex gap-4`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center space-x-2`,children:[(0,Z.jsx)(r,{id:l,"data-testid":`html-checkbox`,checked:t.value.includes(`html`),onCheckedChange:()=>{t.onChange(M(t.value,`html`))}}),(0,Z.jsx)(m,{htmlFor:l,children:`HTML`})]}),(0,Z.jsxs)(`div`,{className:`flex items-center space-x-2`,children:[(0,Z.jsx)(r,{id:u,"data-testid":`ipynb-checkbox`,checked:t.value.includes(`ipynb`),onCheckedChange:()=>{t.onChange(M(t.value,`ipynb`))}}),(0,Z.jsx)(m,{htmlFor:u,children:`IPYNB`})]})]})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`When enabled, marimo will periodically save this notebook in your selected formats (HTML, IPYNB) to a folder named`,` `,(0,Z.jsx)(q,{className:`inline`,children:`__marimo__`}),` next to your notebook file.`]})]})},e[20]=l,e[21]=u,e[22]=F):F=e[22];let I;e[23]!==b.control||e[24]!==F?(I=(0,Z.jsx)($,{title:`Exporting outputs`,children:(0,Z.jsx)(s,{control:b.control,name:`auto_download`,render:F})}),e[23]=b.control,e[24]=F,e[25]=I):I=e[25];let L;e[26]!==I||e[27]!==A||e[28]!==j||e[29]!==P?(L=(0,Z.jsxs)(`div`,{className:`grid grid-cols-2 gap-x-8 gap-y-4`,children:[A,j,P,I]}),e[26]=I,e[27]=A,e[28]=j,e[29]=P,e[30]=L):L=e[30];let R;e[31]!==L||e[32]!==O?(R=(0,Z.jsxs)(`form`,{onChange:O,className:`flex flex-col gap-6`,children:[k,L]}),e[31]=L,e[32]=O,e[33]=R):R=e[33];let z;return e[34]!==b||e[35]!==R?(z=(0,Z.jsx)(h,{...b,children:R}),e[34]=b,e[35]=R,e[36]=z):z=e[36],z},$=e=>{let t=(0,X.c)(5),{title:n,children:r}=e,i;t[0]===n?i=t[1]:(i=(0,Z.jsx)(`h3`,{className:`text-base font-semibold mb-1`,children:n}),t[0]=n,t[1]=i);let a;return t[2]!==r||t[3]!==i?(a=(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-2`,children:[i,r]}),t[2]=r,t[3]=i,t[4]=a):a=t[4],a};function ie(){window.dispatchEvent(new Event(`resize`))}function ae(e){return(0,Z.jsx)(`option`,{value:e,children:e},e)}function oe(e){let{field:t}=e;return(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`Width`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(k,{"data-testid":`app-width-select`,onChange:e=>t.onChange(e.target.value),value:t.value,disabled:t.disabled,className:`inline-flex mr-2`,children:b().map(ae)})}),(0,Z.jsx)(c,{})]})}function se(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`App title`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,onChange:e=>{t.onChange(e.target.value),y.safeParse(e.target.value).success&&(document.title=e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsx)(p,{children:`The application title is put in the title tag in the HTML code and typically displayed in the title bar of the browser window.`})]})}function ce(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{className:`shrink-0`,children:`Custom CSS`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,placeholder:`custom.css`,onChange:e=>{t.onChange(e.target.value),y.safeParse(e.target.value).success&&(document.title=e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsx)(p,{children:`A filepath to a custom css file to be injected into the notebook.`})]})}function le(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{className:`shrink-0`,children:`HTML Head`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,placeholder:`head.html`,onChange:e=>{t.onChange(e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`A filepath to an HTML file to be injected into the`,` `,(0,Z.jsx)(q,{className:`inline`,children:`<head/>`}),` section of the notebook. Use this to add analytics, custom fonts, meta tags, or external scripts.`]})]})}function ue(e){return(0,Z.jsx)(`option`,{value:e.value,children:e.label},e.value)}function de(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`SQL Output Type`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(k,{"data-testid":`sql-output-select`,onChange:e=>{t.onChange(e.target.value),W({title:`Kernel Restart Required`,description:`This change requires a kernel restart to take effect.`})},value:t.value,disabled:t.disabled,className:`inline-flex mr-2`,children:T.map(ue)})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`The Python type returned by a SQL cell. For best performance with large datasets, we recommend using`,` `,(0,Z.jsx)(q,{className:`inline`,children:`native`}),`. See the`,` `,(0,Z.jsx)(B,{href:`https://docs.marimo.io/guides/working_with_data/sql`,children:`SQL guide`}),` `,`for more information.`]})]})}var fe=e=>{let n=(0,X.c)(32),{showAppConfig:r,disabled:i,tooltip:a}=e,s=r===void 0||r,c=i!==void 0&&i,d=a===void 0?`Settings`:a,[f,p]=t(w),m=c?`disabled`:`hint-green`,h;n[0]===Symbol.for(`react.memo_cache_sentinel`)?(h=(0,Z.jsx)(U,{strokeWidth:1.8}),n[0]=h):h=n[0];let g;n[1]===d?g=n[2]:(g=(0,Z.jsx)(A,{content:d,children:h}),n[1]=d,n[2]=g);let _;n[3]!==c||n[4]!==m||n[5]!==g?(_=(0,Z.jsx)(J,{"aria-label":`Config`,"data-testid":`app-config-button`,shape:`circle`,size:`small`,className:`h-[27px] w-[27px]`,disabled:c,color:m,children:g}),n[3]=c,n[4]=m,n[5]=g,n[6]=_):_=n[6];let v=_,y;n[7]===Symbol.for(`react.memo_cache_sentinel`)?(y=(0,Z.jsxs)(L,{className:`w-[90vw] h-[90vh] overflow-hidden sm:max-w-5xl top-[5vh] p-0`,children:[(0,Z.jsx)(G,{children:(0,Z.jsx)(z,{children:`User settings`})}),(0,Z.jsx)(C,{})]}),n[7]=y):y=n[7];let b=y;if(!s){let e;n[8]===v?e=n[9]:(e=(0,Z.jsx)(I,{children:v}),n[8]=v,n[9]=e);let t;return n[10]!==p||n[11]!==f||n[12]!==e?(t=(0,Z.jsxs)(V,{open:f,onOpenChange:p,children:[e,b]}),n[10]=p,n[11]=f,n[12]=e,n[13]=t):t=n[13],t}let x;n[14]===v?x=n[15]:(x=(0,Z.jsx)(o,{asChild:!0,children:v}),n[14]=v,n[15]=x);let S,T;n[16]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Z.jsx)(re,{}),T=(0,Z.jsx)(`div`,{className:`h-px bg-border my-2`}),n[16]=S,n[17]=T):(S=n[16],T=n[17]);let E;n[18]===p?E=n[19]:(E=()=>p(!0),n[18]=p,n[19]=E);let D;n[20]===Symbol.for(`react.memo_cache_sentinel`)?(D=(0,Z.jsx)(U,{strokeWidth:1.8,className:`w-4 h-4 mr-2`}),n[20]=D):D=n[20];let O;n[21]===E?O=n[22]:(O=(0,Z.jsxs)(l,{className:`w-[650px] overflow-auto max-h-[80vh] max-w-[80vw]`,align:`end`,side:`bottom`,onFocusOutside:pe,children:[S,T,(0,Z.jsxs)(j,{onClick:E,variant:`link`,className:`px-0`,children:[D,`User settings`]})]}),n[21]=E,n[22]=O);let k;n[23]!==O||n[24]!==x?(k=(0,Z.jsxs)(u,{children:[x,O]}),n[23]=O,n[24]=x,n[25]=k):k=n[25];let M;n[26]!==p||n[27]!==f?(M=(0,Z.jsx)(V,{open:f,onOpenChange:p,children:b}),n[26]=p,n[27]=f,n[28]=M):M=n[28];let N;return n[29]!==k||n[30]!==M?(N=(0,Z.jsxs)(Z.Fragment,{children:[k,M]}),n[29]=k,n[30]=M,n[31]=N):N=n[31],N};function pe(e){return e.preventDefault()}export{ee as n,Y as r,fe as t};
1
+ import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{c as t}from"./useEvent-xfs0Sn4r.js";import{t as n}from"./react-CBDbhulC.js";import{Kn as r,Mn as i,Pn as a,_n as o,an as s,cn as c,gn as l,mn as u,nn as d,on as f,rn as p,sn as m,tn as h}from"./cells-Cp-G34Rz.js";import{t as g}from"./compiler-runtime-CYIjoINj.js";import{C as _,O as v,k as y}from"./utils-D5Ywm7-q.js";import{E as b,d as x,f as S,i as C,n as w,u as T}from"./ai-model-dropdown-DCmiuk7x.js";import{N as E}from"./config-BlNM0caL.js";import{t as D}from"./jsx-runtime-B74pBk57.js";import{o as O}from"./alert-dialog-CA-2mBs3.js";import{l as k}from"./select-nLt2y0Sw.js";import{t as A}from"./tooltip-BUtPzKB4.js";import{t as j}from"./button-Dh8EwhsF.js";import{s as M}from"./arrays-BqUx5USx.js";import{r as N}from"./requests-C6_IaFh7.js";import{t as P}from"./createLucideIcon-B7HeEoG2.js";import{r as F}from"./useNumberFormatter-DHJ9s6Vk.js";import{M as I,T as L,b as R,j as z,p as B,w as V}from"./write-secret-modal-D6zoZgLY.js";import{r as H}from"./input-DEbY281O.js";import{t as U}from"./settings-C-cYas75.js";import{t as W}from"./use-toast-DpWHUGuF.js";import{t as G}from"./VisuallyHidden-CBMDmozt.js";import{r as K}from"./useDebounce-DgpSQhrP.js";import{t as q}from"./kbd-Cwh96ZBE.js";import{t as J}from"./Inputs-E85rt2lh.js";var Y=P(`power-off`,[[`path`,{d:`M18.36 6.64A9 9 0 0 1 20.77 15`,key:`dxknvb`}],[`path`,{d:`M6.16 6.16a9 9 0 1 0 12.68 12.68`,key:`1x7qb5`}],[`path`,{d:`M12 2v4`,key:`3427ic`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),X=g(),Z=D(),ee=e=>{let t=(0,X.c)(15),{description:n,disabled:r,tooltip:i}=e,a=r!==void 0&&r,o=i===void 0?`Shutdown`:i,{openConfirm:s,closeModal:c}=R(),{sendShutdown:l}=N(),u;t[0]===l?u=t[1]:(u=()=>{l(),setTimeout(te,200)},t[0]=l,t[1]=u);let d=u;if(E())return null;let f=a?`disabled`:`red`,p;t[2]!==c||t[3]!==n||t[4]!==d||t[5]!==s?(p=e=>{e.stopPropagation(),s({title:`Shutdown`,description:n,variant:`destructive`,confirmAction:(0,Z.jsx)(O,{onClick:()=>{d(),c()},"aria-label":`Confirm Shutdown`,children:`Shutdown`})})},t[2]=c,t[3]=n,t[4]=d,t[5]=s,t[6]=p):p=t[6];let m;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,Z.jsx)(F,{strokeWidth:1}),t[7]=m):m=t[7];let h;t[8]!==a||t[9]!==f||t[10]!==p?(h=(0,Z.jsx)(J,{"aria-label":`Shutdown`,"data-testid":`shutdown-button`,shape:`circle`,size:`small`,color:f,className:`h-[27px] w-[27px]`,disabled:a,onClick:p,children:m}),t[8]=a,t[9]=f,t[10]=p,t[11]=h):h=t[11];let g;return t[12]!==h||t[13]!==o?(g=(0,Z.jsx)(A,{content:o,children:h}),t[12]=h,t[13]=o,t[14]=g):g=t[14],g};function te(){window.close()}var Q=e(n(),1),ne=100,re=()=>{let e=(0,X.c)(37),[t,n]=_(),{saveAppConfig:o}=N(),l=(0,Q.useId)(),u=(0,Q.useId)(),g;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(g=i(v),e[0]=g):g=e[0];let y;e[1]===t?y=e[2]:(y={resolver:g,defaultValues:t},e[1]=t,e[2]=y);let b=a(y),C;e[3]!==o||e[4]!==n?(C=async e=>{await o({config:e}).then(()=>{n(e)}).catch(()=>{n(e)})},e[3]=o,e[4]=n,e[5]=C):C=e[5];let w=C,T;e[6]===w?T=e[7]:(T=e=>{w(e)},e[6]=w,e[7]=T);let E=K(T,ne),D;e[8]===t.width?D=e[9]:(D=[t.width],e[8]=t.width,e[9]=D),(0,Q.useEffect)(ie,D);let O;e[10]!==E||e[11]!==b?(O=b.handleSubmit(E),e[10]=E,e[11]=b,e[12]=O):O=e[12];let k;e[13]===Symbol.for(`react.memo_cache_sentinel`)?(k=(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(S,{children:`Notebook Settings`}),(0,Z.jsx)(x,{children:`Configure how your notebook or application looks and behaves.`})]}),e[13]=k):k=e[13];let A;e[14]===b.control?A=e[15]:(A=(0,Z.jsxs)($,{title:`Display`,children:[(0,Z.jsx)(s,{control:b.control,name:`width`,render:oe}),(0,Z.jsx)(s,{control:b.control,name:`app_title`,render:se})]}),e[14]=b.control,e[15]=A);let j;e[16]===b.control?j=e[17]:(j=(0,Z.jsxs)($,{title:`Custom Files`,children:[(0,Z.jsx)(s,{control:b.control,name:`css_file`,render:ce}),(0,Z.jsx)(s,{control:b.control,name:`html_head_file`,render:le})]}),e[16]=b.control,e[17]=j);let P;e[18]===b.control?P=e[19]:(P=(0,Z.jsx)($,{title:`Data`,children:(0,Z.jsx)(s,{control:b.control,name:`sql_output`,render:de})}),e[18]=b.control,e[19]=P);let F;e[20]!==l||e[21]!==u?(F=e=>{let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-col gap-2`,children:[(0,Z.jsx)(d,{children:(0,Z.jsxs)(`div`,{className:`flex gap-4`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center space-x-2`,children:[(0,Z.jsx)(r,{id:l,"data-testid":`html-checkbox`,checked:t.value.includes(`html`),onCheckedChange:()=>{t.onChange(M(t.value,`html`))}}),(0,Z.jsx)(m,{htmlFor:l,children:`HTML`})]}),(0,Z.jsxs)(`div`,{className:`flex items-center space-x-2`,children:[(0,Z.jsx)(r,{id:u,"data-testid":`ipynb-checkbox`,checked:t.value.includes(`ipynb`),onCheckedChange:()=>{t.onChange(M(t.value,`ipynb`))}}),(0,Z.jsx)(m,{htmlFor:u,children:`IPYNB`})]})]})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`When enabled, marimo will periodically save this notebook in your selected formats (HTML, IPYNB) to a folder named`,` `,(0,Z.jsx)(q,{className:`inline`,children:`__marimo__`}),` next to your notebook file.`]})]})},e[20]=l,e[21]=u,e[22]=F):F=e[22];let I;e[23]!==b.control||e[24]!==F?(I=(0,Z.jsx)($,{title:`Exporting outputs`,children:(0,Z.jsx)(s,{control:b.control,name:`auto_download`,render:F})}),e[23]=b.control,e[24]=F,e[25]=I):I=e[25];let L;e[26]!==I||e[27]!==A||e[28]!==j||e[29]!==P?(L=(0,Z.jsxs)(`div`,{className:`grid grid-cols-2 gap-x-8 gap-y-4`,children:[A,j,P,I]}),e[26]=I,e[27]=A,e[28]=j,e[29]=P,e[30]=L):L=e[30];let R;e[31]!==L||e[32]!==O?(R=(0,Z.jsxs)(`form`,{onChange:O,className:`flex flex-col gap-6`,children:[k,L]}),e[31]=L,e[32]=O,e[33]=R):R=e[33];let z;return e[34]!==b||e[35]!==R?(z=(0,Z.jsx)(h,{...b,children:R}),e[34]=b,e[35]=R,e[36]=z):z=e[36],z},$=e=>{let t=(0,X.c)(5),{title:n,children:r}=e,i;t[0]===n?i=t[1]:(i=(0,Z.jsx)(`h3`,{className:`text-base font-semibold mb-1`,children:n}),t[0]=n,t[1]=i);let a;return t[2]!==r||t[3]!==i?(a=(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-2`,children:[i,r]}),t[2]=r,t[3]=i,t[4]=a):a=t[4],a};function ie(){window.dispatchEvent(new Event(`resize`))}function ae(e){return(0,Z.jsx)(`option`,{value:e,children:e},e)}function oe(e){let{field:t}=e;return(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`Width`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(k,{"data-testid":`app-width-select`,onChange:e=>t.onChange(e.target.value),value:t.value,disabled:t.disabled,className:`inline-flex mr-2`,children:b().map(ae)})}),(0,Z.jsx)(c,{})]})}function se(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`App title`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,onChange:e=>{t.onChange(e.target.value),y.safeParse(e.target.value).success&&(document.title=e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsx)(p,{children:`The application title is put in the title tag in the HTML code and typically displayed in the title bar of the browser window.`})]})}function ce(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{className:`shrink-0`,children:`Custom CSS`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,placeholder:`custom.css`,onChange:e=>{t.onChange(e.target.value),y.safeParse(e.target.value).success&&(document.title=e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsx)(p,{children:`A filepath to a custom css file to be injected into the notebook.`})]})}function le(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{className:`shrink-0`,children:`HTML Head`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(H,{...t,value:t.value??``,placeholder:`head.html`,onChange:e=>{t.onChange(e.target.value)}})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`A filepath to an HTML file to be injected into the`,` `,(0,Z.jsx)(q,{className:`inline`,children:`<head/>`}),` section of the notebook. Use this to add analytics, custom fonts, meta tags, or external scripts.`]})]})}function ue(e){return(0,Z.jsx)(`option`,{value:e.value,children:e.label},e.value)}function de(e){let{field:t}=e;return(0,Z.jsxs)(`div`,{className:`flex flex-col gap-y-1`,children:[(0,Z.jsxs)(f,{className:`flex flex-row items-center space-x-1 space-y-0`,children:[(0,Z.jsx)(m,{children:`SQL Output Type`}),(0,Z.jsx)(d,{children:(0,Z.jsx)(k,{"data-testid":`sql-output-select`,onChange:e=>{t.onChange(e.target.value),W({title:`Kernel Restart Required`,description:`This change requires a kernel restart to take effect.`})},value:t.value,disabled:t.disabled,className:`inline-flex mr-2`,children:T.map(ue)})}),(0,Z.jsx)(c,{})]}),(0,Z.jsxs)(p,{children:[`The Python type returned by a SQL cell. For best performance with large datasets, we recommend using`,` `,(0,Z.jsx)(q,{className:`inline`,children:`native`}),`. See the`,` `,(0,Z.jsx)(B,{href:`https://docs.marimo.io/guides/working_with_data/sql`,children:`SQL guide`}),` `,`for more information.`]})]})}var fe=e=>{let n=(0,X.c)(32),{showAppConfig:r,disabled:i,tooltip:a}=e,s=r===void 0||r,c=i!==void 0&&i,d=a===void 0?`Settings`:a,[f,p]=t(w),m=c?`disabled`:`hint-green`,h;n[0]===Symbol.for(`react.memo_cache_sentinel`)?(h=(0,Z.jsx)(U,{strokeWidth:1.8}),n[0]=h):h=n[0];let g;n[1]===d?g=n[2]:(g=(0,Z.jsx)(A,{content:d,children:h}),n[1]=d,n[2]=g);let _;n[3]!==c||n[4]!==m||n[5]!==g?(_=(0,Z.jsx)(J,{"aria-label":`Config`,"data-testid":`app-config-button`,shape:`circle`,size:`small`,className:`h-[27px] w-[27px]`,disabled:c,color:m,children:g}),n[3]=c,n[4]=m,n[5]=g,n[6]=_):_=n[6];let v=_,y;n[7]===Symbol.for(`react.memo_cache_sentinel`)?(y=(0,Z.jsxs)(L,{className:`w-[90vw] h-[90vh] overflow-hidden sm:max-w-5xl top-[5vh] p-0`,children:[(0,Z.jsx)(G,{children:(0,Z.jsx)(z,{children:`User settings`})}),(0,Z.jsx)(C,{})]}),n[7]=y):y=n[7];let b=y;if(!s){let e;n[8]===v?e=n[9]:(e=(0,Z.jsx)(I,{children:v}),n[8]=v,n[9]=e);let t;return n[10]!==p||n[11]!==f||n[12]!==e?(t=(0,Z.jsxs)(V,{open:f,onOpenChange:p,children:[e,b]}),n[10]=p,n[11]=f,n[12]=e,n[13]=t):t=n[13],t}let x;n[14]===v?x=n[15]:(x=(0,Z.jsx)(o,{asChild:!0,children:v}),n[14]=v,n[15]=x);let S,T;n[16]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Z.jsx)(re,{}),T=(0,Z.jsx)(`div`,{className:`h-px bg-border my-2`}),n[16]=S,n[17]=T):(S=n[16],T=n[17]);let E;n[18]===p?E=n[19]:(E=()=>p(!0),n[18]=p,n[19]=E);let D;n[20]===Symbol.for(`react.memo_cache_sentinel`)?(D=(0,Z.jsx)(U,{strokeWidth:1.8,className:`w-4 h-4 mr-2`}),n[20]=D):D=n[20];let O;n[21]===E?O=n[22]:(O=(0,Z.jsxs)(l,{className:`w-[650px] overflow-auto max-h-[80vh] max-w-[80vw]`,align:`end`,side:`bottom`,onFocusOutside:pe,children:[S,T,(0,Z.jsxs)(j,{onClick:E,variant:`link`,className:`px-0`,children:[D,`User settings`]})]}),n[21]=E,n[22]=O);let k;n[23]!==O||n[24]!==x?(k=(0,Z.jsxs)(u,{children:[x,O]}),n[23]=O,n[24]=x,n[25]=k):k=n[25];let M;n[26]!==p||n[27]!==f?(M=(0,Z.jsx)(V,{open:f,onOpenChange:p,children:b}),n[26]=p,n[27]=f,n[28]=M):M=n[28];let N;return n[29]!==k||n[30]!==M?(N=(0,Z.jsxs)(Z.Fragment,{children:[k,M]}),n[29]=k,n[30]=M,n[31]=N):N=n[31],N};function pe(e){return e.preventDefault()}export{ee as n,Y as r,fe as t};
@@ -0,0 +1 @@
1
+ import"./rolldown-runtime-B0Z9INg1.js";import{t as e}from"./react-CBDbhulC.js";import{t}from"./compiler-runtime-CYIjoINj.js";import{n,t as r}from"./cn-ldLVeaqm.js";import{t as i}from"./jsx-runtime-B74pBk57.js";var a=t();e();var o=i(),s=n(`inline-flex items-center border rounded-full px-2 py-0.5 text-xs font-semibold transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 forced-color-adjust-none`,{variants:{variant:{default:`bg-primary hover:bg-primary/60 border-transparent text-primary-foreground forced-colors:bg-[Highlight] forced-colors:border-[Highlight] forced-colors:text-[HighlightText] forced-colors:hover:bg-[Highlight] forced-colors:hover:text-[HighlightText]`,defaultOutline:`bg-(--blue-2) border-(--blue-8) text-(--blue-11) forced-colors:bg-[Canvas] forced-colors:border-[Highlight] forced-colors:text-[CanvasText]`,secondary:`bg-secondary hover:bg-secondary/80 border-transparent text-secondary-foreground forced-colors:bg-[ButtonFace] forced-colors:border-[ButtonText] forced-colors:text-[ButtonText] forced-colors:hover:bg-[Highlight] forced-colors:hover:text-[HighlightText]`,destructive:`bg-(--red-2) border-(--red-6) text-(--red-9) hover:bg-(--red-3) forced-colors:bg-[Canvas] forced-colors:border-[ButtonText] forced-colors:text-[CanvasText] forced-colors:hover:bg-[Highlight] forced-colors:hover:text-[HighlightText]`,success:`bg-(--grass-2) border-(--grass-5) text-(--grass-9) hover:bg-(--grass-3) forced-colors:bg-[Canvas] forced-colors:border-[ButtonText] forced-colors:text-[CanvasText] forced-colors:hover:bg-[Highlight] forced-colors:hover:text-[HighlightText]`,outline:`text-foreground forced-colors:bg-[Canvas] forced-colors:border-[ButtonText] forced-colors:text-[CanvasText]`}},defaultVariants:{variant:`default`}}),c=e=>{let t=(0,a.c)(10),n,i,c;t[0]===e?(n=t[1],i=t[2],c=t[3]):({className:n,variant:c,...i}=e,t[0]=e,t[1]=n,t[2]=i,t[3]=c);let l;t[4]!==n||t[5]!==c?(l=r(s({variant:c}),n),t[4]=n,t[5]=c,t[6]=l):l=t[6];let u;return t[7]!==i||t[8]!==l?(u=(0,o.jsx)(`div`,{className:l,...i}),t[7]=i,t[8]=l,t[9]=u):u=t[9],u};export{c as t};
@@ -1 +1 @@
1
- import{a as e}from"./markdown-renderer-CdZX2MvM.js";function t(e){return new Promise((t,n)=>{let r=new FileReader;r.onload=e=>{t(e.target?.result)},r.onerror=e=>{n(Error(`Failed to read blob: ${e.type}`))},r.readAsDataURL(e)})}function n(e){let[t,n]=e.split(`,`,2),r=/^data:(.+);base64$/.exec(t)?.[1],i=atob(n),a=i.length,o=new Uint8Array(a);for(let e=0;e<a;e++)o[e]=i.charCodeAt(e);return new Blob([o],{type:r})}function r({contents:t,mimeType:r,isBase64:i}){return i?n(e(t,r)):new Blob([t],{type:r})}export{r as n,t as r,n as t};
1
+ import{a as e}from"./markdown-renderer-BZKlbm2Q.js";function t(e){return new Promise((t,n)=>{let r=new FileReader;r.onload=e=>{t(e.target?.result)},r.onerror=e=>{n(Error(`Failed to read blob: ${e.type}`))},r.readAsDataURL(e)})}function n(e){let[t,n]=e.split(`,`,2),r=/^data:(.+);base64$/.exec(t)?.[1],i=atob(n),a=i.length,o=new Uint8Array(a);for(let e=0;e<a;e++)o[e]=i.charCodeAt(e);return new Blob([o],{type:r})}function r({contents:t,mimeType:r,isBase64:i}){return i?n(e(t,r)):new Blob([t],{type:r})}export{r as n,t as r,n as t};
@@ -0,0 +1 @@
1
+ import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{t}from"./react-CBDbhulC.js";import{t as n}from"./compiler-runtime-CYIjoINj.js";import{m as r,n as i,t as a}from"./useEventListener-92uWqz-P.js";import{n as o,t as s}from"./cn-ldLVeaqm.js";import{t as c}from"./jsx-runtime-B74pBk57.js";var l=e(t(),1),u=n(),d={stopPropagation:e=>t=>{t.stopPropagation(),e&&e(t)},onEnter:e=>t=>{t.key===`Enter`&&e&&e(t)},preventFocus:e=>{e.preventDefault()},fromInput:e=>{let t=d.composedTarget(e);return t.tagName===`INPUT`||t.tagName===`TEXTAREA`||t.tagName.startsWith(`MARIMO`)||t.isContentEditable||d.fromCodeMirror(t)},fromCodeMirror:e=>e.closest(`.cm-editor`)!==null,shouldIgnoreKeyboardEvent(e){let t=d.composedTarget(e);return t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement||t instanceof HTMLElement&&(t.isContentEditable||t.tagName===`BUTTON`||t.closest(`[role='textbox']`)!==null||t.closest(`[contenteditable='true']`)!==null||d.fromCodeMirror(t))},composedTarget(e){return`composedPath`in e&&typeof e.composedPath==`function`?e.composedPath()[0]??e.target:e.target},hasModifier:e=>e.ctrlKey||e.metaKey||e.altKey||e.shiftKey,isMetaOrCtrl:e=>e.metaKey||e.ctrlKey},f=c(),p=`active:shadow-none`,m=o(s(`disabled:opacity-50 disabled:pointer-events-none`,`inline-flex items-center justify-center rounded-md text-sm font-medium focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-2 ring-offset-background`,`forced-color-adjust-none forced-colors:border-[ButtonText] forced-colors:bg-[ButtonFace] forced-colors:text-[ButtonText] forced-colors:hover:bg-[Highlight] forced-colors:hover:text-[HighlightText] forced-colors:disabled:border-[GrayText] forced-colors:disabled:text-[GrayText]`),{variants:{variant:{default:s(`bg-primary text-primary-foreground hover:bg-primary/90 shadow-xs border border-primary`,p),destructive:s(`border shadow-xs`,`bg-destructive text-destructive-foreground border-destructive-border hover:bg-destructive-hover`,p),success:s(`border shadow-xs`,`bg-success text-success-foreground border-success-border hover:bg-success-hover`,p),warn:s(`border shadow-xs`,`bg-action text-action-foreground border-action-border hover:bg-action-hover`,p),action:s(`bg-action text-action-foreground shadow-xs`,`hover:bg-action-hover border border-action-border`,p),outline:s(`border border-slate-300 shadow-xs`,`hover:bg-accent hover:text-accent-foreground`,`hover:border-primary`,`aria-selected:text-accent-foreground aria-selected:border-primary`,p),secondary:s(`bg-secondary text-secondary-foreground hover:bg-secondary/80`,`border border-input shadow-xs`,p),text:s(`opacity-80 hover:opacity-100`,`active:opacity-100`),ghost:s(`border border-transparent`,`hover:bg-accent hover:text-accent-foreground hover:shadow-xs`,p,`active:text-accent-foreground`),link:`underline-offset-4 hover:underline text-link`,linkDestructive:`underline-offset-4 hover:underline text-destructive underline-destructive`,outlineDestructive:`border border-destructive text-destructive hover:bg-destructive/10`},size:{default:`h-10 py-2 px-4`,xs:`h-7 px-2 rounded-md text-xs`,sm:`h-9 px-3 rounded-md`,lg:`h-11 px-8 rounded-md`,icon:`h-6 w-6 mb-0`},disabled:{true:`opacity-50 pointer-events-none`}},defaultVariants:{variant:`default`,size:`sm`}}),h=l.forwardRef((e,t)=>{let n=(0,u.c)(19),o,c,p,h,g,_;n[0]===e?(o=n[1],c=n[2],p=n[3],h=n[4],g=n[5],_=n[6]):({className:o,variant:_,size:h,asChild:g,keyboardShortcut:c,...p}=e,n[0]=e,n[1]=o,n[2]=c,n[3]=p,n[4]=h,n[5]=g,n[6]=_);let v=g!==void 0&&g,y=l.useRef(null),b;n[7]===Symbol.for(`react.memo_cache_sentinel`)?(b=()=>y.current,n[7]=b):b=n[7],l.useImperativeHandle(t,b);let x;n[8]===c?x=n[9]:(x=e=>{!c||e.defaultPrevented||d.shouldIgnoreKeyboardEvent(e)||r(c)(e)&&(e.preventDefault(),e.stopPropagation(),y?.current&&!y.current.disabled&&y.current.click())},n[8]=c,n[9]=x),a(document,`keydown`,x);let S=v?i:`button`,C;n[10]!==o||n[11]!==p.disabled||n[12]!==h||n[13]!==_?(C=s(m({variant:_,size:h,className:o,disabled:p.disabled}),o),n[10]=o,n[11]=p.disabled,n[12]=h,n[13]=_,n[14]=C):C=n[14];let w;return n[15]!==S||n[16]!==p||n[17]!==C?(w=(0,f.jsx)(S,{className:C,ref:y,...p}),n[15]=S,n[16]=p,n[17]=C,n[18]=w):w=n[18],w});h.displayName=`Button`;export{m as n,d as r,h as t};
@@ -1 +1 @@
1
- import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{l as t}from"./useEvent-xfs0Sn4r.js";import{t as n}from"./react-CBDbhulC.js";import{t as r}from"./compiler-runtime-CYIjoINj.js";import{t as i}from"./cn-ldLVeaqm.js";import{t as a}from"./jsx-runtime-B74pBk57.js";import{a as o,c as s,i as c,l,n as u,o as d,r as f,s as p,t as m,u as h}from"./alert-dialog-BVi_GyOB.js";import{t as g}from"./button-Btj6GXNy.js";import{r as _}from"./requests-C6_IaFh7.js";import{t as v}from"./database-zap-CloO6gbw.js";import{t as y}from"./spinner-Ck-Hgfvj.js";import{t as b}from"./refresh-cw-Bf-rx_aV.js";import{t as x}from"./trash-2-D_HX-0qx.js";import{t as S}from"./use-toast-DpWHUGuF.js";import{t as C}from"./context-Do8M9TDF.js";import{i as w}from"./numbers-DKurV_vq.js";import{n as T}from"./useAsyncData-Buhk-UgR.js";import{t as E}from"./empty-state-kWyb5dCS.js";import{t as D}from"./requests-S_7PqcSt.js";import{n as O,t as k}from"./formatting-BJlT1s_3.js";var A=r(),j=e(n(),1),M=a(),N=e=>{let t=(0,A.c)(27),{children:n,title:r,description:i,onConfirm:a,confirmText:g,cancelText:_,destructive:v}=e,y=g===void 0?`Continue`:g,b=_===void 0?`Cancel`:_,x=v!==void 0&&v,[S,C]=j.useState(!1),w;t[0]===a?w=t[1]:(w=()=>{a(),C(!1)},t[0]=a,t[1]=w);let T=w,E=x?d:u,D;t[2]===n?D=t[3]:(D=(0,M.jsx)(h,{asChild:!0,children:n}),t[2]=n,t[3]=D);let O;t[4]===r?O=t[5]:(O=(0,M.jsx)(l,{children:r}),t[4]=r,t[5]=O);let k;t[6]===i?k=t[7]:(k=(0,M.jsx)(o,{children:i}),t[6]=i,t[7]=k);let N;t[8]!==O||t[9]!==k?(N=(0,M.jsxs)(s,{children:[O,k]}),t[8]=O,t[9]=k,t[10]=N):N=t[10];let P;t[11]===b?P=t[12]:(P=(0,M.jsx)(f,{children:b}),t[11]=b,t[12]=P);let F;t[13]!==E||t[14]!==y||t[15]!==T?(F=(0,M.jsx)(E,{onClick:T,children:y}),t[13]=E,t[14]=y,t[15]=T,t[16]=F):F=t[16];let I;t[17]!==F||t[18]!==P?(I=(0,M.jsxs)(p,{children:[P,F]}),t[17]=F,t[18]=P,t[19]=I):I=t[19];let L;t[20]!==I||t[21]!==N?(L=(0,M.jsxs)(c,{children:[N,I]}),t[20]=I,t[21]=N,t[22]=L):L=t[22];let R;return t[23]!==S||t[24]!==L||t[25]!==D?(R=(0,M.jsxs)(m,{open:S,onOpenChange:C,children:[D,L]}),t[23]=S,t[24]=L,t[25]=D,t[26]=R):R=t[26],R},P=()=>{let{clearCache:e,getCacheInfo:n}=_(),r=t(D),[a,o]=(0,j.useState)(!1),{locale:s}=C(),{isPending:c,isFetching:l,refetch:u}=T(async()=>{await n(),await new Promise(e=>setTimeout(e,500))},[]),d=async()=>{try{o(!0),await e(),S({title:`Cache purged`,description:`All cached data has been cleared`}),u()}catch(e){S({title:`Error`,description:e instanceof Error?e.message:`Failed to purge cache`,variant:`danger`})}finally{o(!1)}};if(c&&!r)return(0,M.jsx)(y,{size:`medium`,centered:!0});let f=(0,M.jsxs)(g,{variant:`outline`,size:`sm`,onClick:u,disabled:l,children:[l?(0,M.jsx)(y,{size:`small`,className:`w-4 h-4 mr-2`}):(0,M.jsx)(b,{className:`w-4 h-4 mr-2`}),`Refresh`]});if(!r)return(0,M.jsx)(E,{title:`No cache data`,description:`Cache information is not available.`,icon:(0,M.jsx)(v,{}),action:f});let p=r.hits,m=r.misses,h=r.time,A=r.disk_total,P=r.disk_to_free,I=p+m,L=I>0?p/I*100:0;return I===0?(0,M.jsx)(E,{title:`No cache activity`,description:`The cache has not been used yet. Cached functions will appear here once they are executed.`,icon:(0,M.jsx)(v,{}),action:f}):(0,M.jsx)(`div`,{className:`flex flex-col h-full overflow-auto`,children:(0,M.jsxs)(`div`,{className:`flex flex-col gap-4 p-4 h-full`,children:[(0,M.jsx)(`div`,{className:`flex items-center justify-end`,children:(0,M.jsx)(g,{variant:`ghost`,size:`icon`,className:`h-6 w-6`,onClick:u,disabled:l,children:(0,M.jsx)(b,{className:i(`h-4 w-4 text-muted-foreground hover:text-foreground`,l&&`animate-[spin_0.5s]`)})})}),(0,M.jsxs)(`div`,{className:`space-y-3`,children:[(0,M.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:`Statistics`}),(0,M.jsxs)(`div`,{className:`grid grid-cols-2 gap-3`,children:[(0,M.jsx)(F,{label:`Time saved`,value:O(h,s),description:`Total execution time saved`}),(0,M.jsx)(F,{label:`Hit rate`,value:I>0?`${w(L,s)}%`:`—`,description:`${w(p,s)} hits / ${w(I,s)} total`}),(0,M.jsx)(F,{label:`Cache hits`,value:w(p,s),description:`Successful cache retrievals`}),(0,M.jsx)(F,{label:`Cache misses`,value:w(m,s),description:`Cache not found`})]})]}),A>0&&(0,M.jsxs)(`div`,{className:`space-y-3 pt-2 border-t`,children:[(0,M.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:`Storage`}),(0,M.jsx)(`div`,{className:`grid grid-cols-1 gap-3`,children:(0,M.jsx)(F,{label:`Disk usage`,value:k(A,s),description:P>0?`${k(P,s)} can be freed`:`Cache storage on disk`})})]}),(0,M.jsx)(`div`,{className:`my-auto`}),(0,M.jsx)(`div`,{className:`pt-2 border-t`,children:(0,M.jsx)(N,{title:`Purge cache?`,description:`This will permanently delete all cached data. This action cannot be undone.`,confirmText:`Purge`,destructive:!0,onConfirm:d,children:(0,M.jsxs)(g,{variant:`outlineDestructive`,size:`xs`,disabled:a,className:`w-full`,children:[a?(0,M.jsx)(y,{size:`small`,className:`w-3 h-3 mr-2`}):(0,M.jsx)(x,{className:`w-3 h-3 mr-2`}),`Purge Cache`]})})})]})})},F=e=>{let t=(0,A.c)(10),{label:n,value:r,description:i}=e,a;t[0]===n?a=t[1]:(a=(0,M.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:n}),t[0]=n,t[1]=a);let o;t[2]===r?o=t[3]:(o=(0,M.jsx)(`span`,{className:`text-lg font-semibold`,children:r}),t[2]=r,t[3]=o);let s;t[4]===i?s=t[5]:(s=i&&(0,M.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:i}),t[4]=i,t[5]=s);let c;return t[6]!==a||t[7]!==o||t[8]!==s?(c=(0,M.jsxs)(`div`,{className:`flex flex-col gap-1 p-3 rounded-lg border bg-card`,children:[a,o,s]}),t[6]=a,t[7]=o,t[8]=s,t[9]=c):c=t[9],c};export{P as default};
1
+ import{a as e}from"./rolldown-runtime-B0Z9INg1.js";import{l as t}from"./useEvent-xfs0Sn4r.js";import{t as n}from"./react-CBDbhulC.js";import{t as r}from"./compiler-runtime-CYIjoINj.js";import{t as i}from"./cn-ldLVeaqm.js";import{t as a}from"./jsx-runtime-B74pBk57.js";import{a as o,c as s,i as c,l,n as u,o as d,r as f,s as p,t as m,u as h}from"./alert-dialog-CA-2mBs3.js";import{t as g}from"./button-Dh8EwhsF.js";import{r as _}from"./requests-C6_IaFh7.js";import{t as v}from"./database-zap-CloO6gbw.js";import{t as y}from"./spinner-Ck-Hgfvj.js";import{t as b}from"./refresh-cw-Bf-rx_aV.js";import{t as x}from"./trash-2-D_HX-0qx.js";import{t as S}from"./use-toast-DpWHUGuF.js";import{t as C}from"./context-Do8M9TDF.js";import{i as w}from"./numbers-Bc-r3jsC.js";import{n as T}from"./useAsyncData-Buhk-UgR.js";import{t as E}from"./empty-state-kWyb5dCS.js";import{t as D}from"./requests-S_7PqcSt.js";import{n as O,t as k}from"./formatting-BWZH2nBg.js";var A=r(),j=e(n(),1),M=a(),N=e=>{let t=(0,A.c)(27),{children:n,title:r,description:i,onConfirm:a,confirmText:g,cancelText:_,destructive:v}=e,y=g===void 0?`Continue`:g,b=_===void 0?`Cancel`:_,x=v!==void 0&&v,[S,C]=j.useState(!1),w;t[0]===a?w=t[1]:(w=()=>{a(),C(!1)},t[0]=a,t[1]=w);let T=w,E=x?d:u,D;t[2]===n?D=t[3]:(D=(0,M.jsx)(h,{asChild:!0,children:n}),t[2]=n,t[3]=D);let O;t[4]===r?O=t[5]:(O=(0,M.jsx)(l,{children:r}),t[4]=r,t[5]=O);let k;t[6]===i?k=t[7]:(k=(0,M.jsx)(o,{children:i}),t[6]=i,t[7]=k);let N;t[8]!==O||t[9]!==k?(N=(0,M.jsxs)(s,{children:[O,k]}),t[8]=O,t[9]=k,t[10]=N):N=t[10];let P;t[11]===b?P=t[12]:(P=(0,M.jsx)(f,{children:b}),t[11]=b,t[12]=P);let F;t[13]!==E||t[14]!==y||t[15]!==T?(F=(0,M.jsx)(E,{onClick:T,children:y}),t[13]=E,t[14]=y,t[15]=T,t[16]=F):F=t[16];let I;t[17]!==F||t[18]!==P?(I=(0,M.jsxs)(p,{children:[P,F]}),t[17]=F,t[18]=P,t[19]=I):I=t[19];let L;t[20]!==I||t[21]!==N?(L=(0,M.jsxs)(c,{children:[N,I]}),t[20]=I,t[21]=N,t[22]=L):L=t[22];let R;return t[23]!==S||t[24]!==L||t[25]!==D?(R=(0,M.jsxs)(m,{open:S,onOpenChange:C,children:[D,L]}),t[23]=S,t[24]=L,t[25]=D,t[26]=R):R=t[26],R},P=()=>{let{clearCache:e,getCacheInfo:n}=_(),r=t(D),[a,o]=(0,j.useState)(!1),{locale:s}=C(),{isPending:c,isFetching:l,refetch:u}=T(async()=>{await n(),await new Promise(e=>setTimeout(e,500))},[]),d=async()=>{try{o(!0),await e(),S({title:`Cache purged`,description:`All cached data has been cleared`}),u()}catch(e){S({title:`Error`,description:e instanceof Error?e.message:`Failed to purge cache`,variant:`danger`})}finally{o(!1)}};if(c&&!r)return(0,M.jsx)(y,{size:`medium`,centered:!0});let f=(0,M.jsxs)(g,{variant:`outline`,size:`sm`,onClick:u,disabled:l,children:[l?(0,M.jsx)(y,{size:`small`,className:`w-4 h-4 mr-2`}):(0,M.jsx)(b,{className:`w-4 h-4 mr-2`}),`Refresh`]});if(!r)return(0,M.jsx)(E,{title:`No cache data`,description:`Cache information is not available.`,icon:(0,M.jsx)(v,{}),action:f});let p=r.hits,m=r.misses,h=r.time,A=r.disk_total,P=r.disk_to_free,I=p+m,L=I>0?p/I*100:0;return I===0?(0,M.jsx)(E,{title:`No cache activity`,description:`The cache has not been used yet. Cached functions will appear here once they are executed.`,icon:(0,M.jsx)(v,{}),action:f}):(0,M.jsx)(`div`,{className:`flex flex-col h-full overflow-auto`,children:(0,M.jsxs)(`div`,{className:`flex flex-col gap-4 p-4 h-full`,children:[(0,M.jsx)(`div`,{className:`flex items-center justify-end`,children:(0,M.jsx)(g,{variant:`ghost`,size:`icon`,className:`h-6 w-6`,onClick:u,disabled:l,children:(0,M.jsx)(b,{className:i(`h-4 w-4 text-muted-foreground hover:text-foreground`,l&&`animate-[spin_0.5s]`)})})}),(0,M.jsxs)(`div`,{className:`space-y-3`,children:[(0,M.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:`Statistics`}),(0,M.jsxs)(`div`,{className:`grid grid-cols-2 gap-3`,children:[(0,M.jsx)(F,{label:`Time saved`,value:O(h,s),description:`Total execution time saved`}),(0,M.jsx)(F,{label:`Hit rate`,value:I>0?`${w(L,s)}%`:`—`,description:`${w(p,s)} hits / ${w(I,s)} total`}),(0,M.jsx)(F,{label:`Cache hits`,value:w(p,s),description:`Successful cache retrievals`}),(0,M.jsx)(F,{label:`Cache misses`,value:w(m,s),description:`Cache not found`})]})]}),A>0&&(0,M.jsxs)(`div`,{className:`space-y-3 pt-2 border-t`,children:[(0,M.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:`Storage`}),(0,M.jsx)(`div`,{className:`grid grid-cols-1 gap-3`,children:(0,M.jsx)(F,{label:`Disk usage`,value:k(A,s),description:P>0?`${k(P,s)} can be freed`:`Cache storage on disk`})})]}),(0,M.jsx)(`div`,{className:`my-auto`}),(0,M.jsx)(`div`,{className:`pt-2 border-t`,children:(0,M.jsx)(N,{title:`Purge cache?`,description:`This will permanently delete all cached data. This action cannot be undone.`,confirmText:`Purge`,destructive:!0,onConfirm:d,children:(0,M.jsxs)(g,{variant:`outlineDestructive`,size:`xs`,disabled:a,className:`w-full`,children:[a?(0,M.jsx)(y,{size:`small`,className:`w-3 h-3 mr-2`}):(0,M.jsx)(x,{className:`w-3 h-3 mr-2`}),`Purge Cache`]})})})]})})},F=e=>{let t=(0,A.c)(10),{label:n,value:r,description:i}=e,a;t[0]===n?a=t[1]:(a=(0,M.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:n}),t[0]=n,t[1]=a);let o;t[2]===r?o=t[3]:(o=(0,M.jsx)(`span`,{className:`text-lg font-semibold`,children:r}),t[2]=r,t[3]=o);let s;t[4]===i?s=t[5]:(s=i&&(0,M.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:i}),t[4]=i,t[5]=s);let c;return t[6]!==a||t[7]!==o||t[8]!==s?(c=(0,M.jsxs)(`div`,{className:`flex flex-col gap-1 p-3 rounded-lg border bg-card`,children:[a,o,s]}),t[6]=a,t[7]=o,t[8]=s,t[9]=c):c=t[9],c};export{P as default};
@@ -1 +1 @@
1
- import{g as e}from"./useEventListener-D27Dii_l.js";import{n as t}from"./once-Haz_uxEL.js";function n(e){try{let t=window[e],n=`__storage_test__`,r=`test`;if(!t)return!1;t.setItem(n,r);let i=t.getItem(n);return t.removeItem(n),i===r}catch{return!1}}function r(){try{return`download`in document.createElement(`a`)}catch{return!1}}function i(){let t=window.parent!==window,i={isEmbedded:t,hasLocalStorage:n(`localStorage`),hasSessionStorage:n(`sessionStorage`),hasClipboard:navigator.clipboard!==void 0,hasDownloads:r(),hasFullscreen:document.fullscreenEnabled!==void 0&&document.fullscreenEnabled,hasMediaDevices:navigator.mediaDevices!==void 0&&typeof navigator.mediaDevices.getUserMedia==`function`};return t&&(e.log(`[iframe] Running in embedded context`),i.hasLocalStorage||e.warn(`[iframe] localStorage unavailable - using fallback storage`),i.hasClipboard||e.warn(`[iframe] Clipboard API unavailable`),i.hasDownloads||e.warn(`[iframe] Download capability may be restricted`),i.hasFullscreen||e.warn(`[iframe] Fullscreen API unavailable`),i.hasMediaDevices||e.warn(`[iframe] Media devices API unavailable`)),i}var a=t(()=>i());export{a as t};
1
+ import{g as e}from"./useEventListener-92uWqz-P.js";import{n as t}from"./once-Haz_uxEL.js";function n(e){try{let t=window[e],n=`__storage_test__`,r=`test`;if(!t)return!1;t.setItem(n,r);let i=t.getItem(n);return t.removeItem(n),i===r}catch{return!1}}function r(){try{return`download`in document.createElement(`a`)}catch{return!1}}function i(){let t=window.parent!==window,i={isEmbedded:t,hasLocalStorage:n(`localStorage`),hasSessionStorage:n(`sessionStorage`),hasClipboard:navigator.clipboard!==void 0,hasDownloads:r(),hasFullscreen:document.fullscreenEnabled!==void 0&&document.fullscreenEnabled,hasMediaDevices:navigator.mediaDevices!==void 0&&typeof navigator.mediaDevices.getUserMedia==`function`};return t&&(e.log(`[iframe] Running in embedded context`),i.hasLocalStorage||e.warn(`[iframe] localStorage unavailable - using fallback storage`),i.hasClipboard||e.warn(`[iframe] Clipboard API unavailable`),i.hasDownloads||e.warn(`[iframe] Download capability may be restricted`),i.hasFullscreen||e.warn(`[iframe] Fullscreen API unavailable`),i.hasMediaDevices||e.warn(`[iframe] Media devices API unavailable`)),i}var a=t(()=>i());export{a as t};