@marimo-team/frontend 0.19.8-dev21 → 0.19.8-dev24

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 (169) hide show
  1. package/dist/assets/{ConnectedDataExplorerComponent-B098edeX.js → ConnectedDataExplorerComponent-C1BlkUlk.js} +1 -1
  2. package/dist/assets/{JsonOutput-DsO4felE.js → JsonOutput-BPSYj_Kn.js} +3 -3
  3. package/dist/assets/{LazyAnyLanguageCodeMirror-CQP8KZWO.js → LazyAnyLanguageCodeMirror-BqosdyZU.js} +2 -2
  4. package/dist/assets/{MarimoErrorOutput-DrTj9k_Z.js → MarimoErrorOutput-DVEiP1Ym.js} +1 -1
  5. package/dist/assets/{RenderHTML-D9vJ9neG.js → RenderHTML-Bj4DW3wy.js} +1 -1
  6. package/dist/assets/{add-cell-with-ai-CPu9tI-Q.js → add-cell-with-ai-dpMkH_5a.js} +5 -5
  7. package/dist/assets/{add-database-form-CvczP0Mq.js → add-database-form-Bn_w5TEI.js} +1 -1
  8. package/dist/assets/{agent-panel-Dbh-hMbm.js → agent-panel-BSykBSj4.js} +1 -1
  9. package/dist/assets/{ai-model-dropdown-CODXtvnr.js → ai-model-dropdown-D8AFYZjU.js} +1 -1
  10. package/dist/assets/{any-language-editor-B1WBkbF4.js → any-language-editor-DyXJSyeK.js} +1 -1
  11. package/dist/assets/{app-config-button-BGuwQV5R.js → app-config-button-Ds61zRnG.js} +1 -1
  12. package/dist/assets/{architectureDiagram-VXUJARFQ-BsTgqTsh.js → architectureDiagram-VXUJARFQ-B8zMpJcM.js} +1 -1
  13. package/dist/assets/blob-Bgnx1kuY.js +1 -0
  14. package/dist/assets/{blockDiagram-VD42YOAC-CeZonq9z.js → blockDiagram-VD42YOAC-CF1a-_t0.js} +1 -1
  15. package/dist/assets/{c4Diagram-YG6GDRKO-CDPGRzUd.js → c4Diagram-YG6GDRKO-YIsEsUdQ.js} +1 -1
  16. package/dist/assets/{cache-panel-gTIhwBeU.js → cache-panel-C_9WDApV.js} +1 -1
  17. package/dist/assets/{cell-editor-BpkNlmop.js → cell-editor-90blTXig.js} +1 -1
  18. package/dist/assets/channel-CXFsg7SH.js +1 -0
  19. package/dist/assets/{chat-display-BnUDaREA.js → chat-display-letMHFni.js} +1 -1
  20. package/dist/assets/{chat-panel-BpDjUlzW.js → chat-panel-0qUKLNYu.js} +1 -1
  21. package/dist/assets/{chunk-5FQGJX7Z-CwvgJCug.js → chunk-5FQGJX7Z-T2jyw7ZD.js} +2 -2
  22. package/dist/assets/{chunk-ABZYJK2D-CtRGq-db.js → chunk-ABZYJK2D-D1A06qKo.js} +3 -3
  23. package/dist/assets/{chunk-ATLVNIR6-CXEe2jMF.js → chunk-ATLVNIR6-C5FWd1qN.js} +1 -1
  24. package/dist/assets/{chunk-B4BG7PRW-BVqt-NSK.js → chunk-B4BG7PRW-BEayfxv_.js} +1 -1
  25. package/dist/assets/{chunk-DI55MBZ5-C_mlVJmb.js → chunk-DI55MBZ5-BSrtupT8.js} +1 -1
  26. package/dist/assets/{chunk-EXTU4WIE-CN3BqsR0.js → chunk-EXTU4WIE-wi_fHsHN.js} +1 -1
  27. package/dist/assets/{chunk-JA3XYJ7Z-B5-JYmoA.js → chunk-JA3XYJ7Z-tKDxhnhw.js} +1 -1
  28. package/dist/assets/{chunk-JZLCHNYA-UFlatyc1.js → chunk-JZLCHNYA-DtvI9B9X.js} +1 -1
  29. package/dist/assets/{chunk-N4CR4FBY-BFF_Z7sG.js → chunk-N4CR4FBY-BQcJpHO7.js} +2 -2
  30. package/dist/assets/{chunk-QN33PNHL-DOgXIePg.js → chunk-QN33PNHL-BboKw3W6.js} +1 -1
  31. package/dist/assets/{chunk-QXUST7PY-CbBaWlhv.js → chunk-QXUST7PY-C4Ihfbmy.js} +1 -1
  32. package/dist/assets/{chunk-S3R3BYOJ-CM-pQ0EF.js → chunk-S3R3BYOJ-D1UiABQX.js} +1 -1
  33. package/dist/assets/{chunk-TZMSLE5B-Bs5ERkTF.js → chunk-TZMSLE5B-BjrxQwUX.js} +1 -1
  34. package/dist/assets/classDiagram-2ON5EDUG-BHD5dOKT.js +1 -0
  35. package/dist/assets/classDiagram-v2-WZHVMYZB-VYd80hrd.js +1 -0
  36. package/dist/assets/{code-block-37QAKDTI-CT7W9knZ.js → code-block-37QAKDTI-FUPT3-7o.js} +1 -1
  37. package/dist/assets/{column-preview-Bz3KIcIX.js → column-preview-BEosUUWh.js} +1 -1
  38. package/dist/assets/{command-PbcrObnK.js → command-BpjkI15h.js} +1 -1
  39. package/dist/assets/{command-palette-D8q355Sm.js → command-palette-BymLo8Sb.js} +1 -1
  40. package/dist/assets/{common-DRWuidzm.js → common-RVtJOXao.js} +1 -1
  41. package/dist/assets/{copy-icon-B9w72gBC.js → copy-icon-C9v8EtBA.js} +1 -1
  42. package/dist/assets/{dagre-6UL2VRFP-UK8bracd.js → dagre-6UL2VRFP-CX3NGWnu.js} +1 -1
  43. package/dist/assets/{data-grid-overlay-editor-2vr_zUfM.js → data-grid-overlay-editor-BTyw6887.js} +1 -1
  44. package/dist/assets/{datasource-Dkywo3Kg.js → datasource-Bl1__6xJ.js} +1 -1
  45. package/dist/assets/{dependency-graph-panel-ZnsWxFY3.js → dependency-graph-panel-C33q1RVn.js} +1 -1
  46. package/dist/assets/{diagram-PSM6KHXK-7QiPU-26.js → diagram-PSM6KHXK-C0Sfgs1J.js} +1 -1
  47. package/dist/assets/{diagram-QEK2KX5R-BbZsWUC4.js → diagram-QEK2KX5R-DYSkW6Ju.js} +1 -1
  48. package/dist/assets/{diagram-S2PKOQOG-SZ-twU4B.js → diagram-S2PKOQOG-CfHqQVo3.js} +1 -1
  49. package/dist/assets/{dist-DY1C8dgM.js → dist-h1RhtzUB.js} +1 -1
  50. package/dist/assets/{documentation-panel-CZJavCAM.js → documentation-panel-BWViNAJ6.js} +1 -1
  51. package/dist/assets/{download-CmdFQXRz.js → download-s-BdZdTz.js} +1 -1
  52. package/dist/assets/{edit-page-e6xxDbUd.js → edit-page-nMTiqKOs.js} +3 -3
  53. package/dist/assets/{erDiagram-Q2GNP2WA-BSmVh3Kt.js → erDiagram-Q2GNP2WA-BfRyUS6D.js} +1 -1
  54. package/dist/assets/{error-panel-BMcWP1VH.js → error-panel-BhPek3dt.js} +1 -1
  55. package/dist/assets/{es-CerBf9Z6.js → es-GXAIFcot.js} +1 -1
  56. package/dist/assets/{esm-C-53tlK5.js → esm-BK6tLEHQ.js} +1 -1
  57. package/dist/assets/{file-explorer-panel-th-ny103.js → file-explorer-panel-BGF99P_O.js} +1 -1
  58. package/dist/assets/{flowDiagram-NV44I4VS-2nYUYKvI.js → flowDiagram-NV44I4VS-DKkZCUwG.js} +1 -1
  59. package/dist/assets/{form-94alAnRh.js → form-CNEyFLKK.js} +1 -1
  60. package/dist/assets/{formats-CobRswjh.js → formats-DGZwRUPy.js} +1 -1
  61. package/dist/assets/gallery-page-1AmSypJ6.js +1 -0
  62. package/dist/assets/{ganttDiagram-JELNMOA3-B77PnMPw.js → ganttDiagram-JELNMOA3-J8yLTqxn.js} +1 -1
  63. package/dist/assets/{gitGraphDiagram-NY62KEGX-B-3aRelz.js → gitGraphDiagram-NY62KEGX-DXw3a-uS.js} +1 -1
  64. package/dist/assets/{glide-data-editor-B5UMCoFz.js → glide-data-editor-Cw8eE9Xn.js} +4 -4
  65. package/dist/assets/{home-page-Bgzw3IP3.js → home-page-Cs46vLcH.js} +1 -1
  66. package/dist/assets/{hooks-B_N-kbrq.js → hooks-C13qkLoi.js} +1 -1
  67. package/dist/assets/index-3CaNzO41.css +2 -0
  68. package/dist/assets/{index-U7La6ZBB.js → index-CxrD-UyN.js} +22 -22
  69. package/dist/assets/{infoDiagram-WHAUD3N6-_vys04Gc.js → infoDiagram-WHAUD3N6-32du45zK.js} +1 -1
  70. package/dist/assets/{journeyDiagram-XKPGCS4Q-CkD6eopP.js → journeyDiagram-XKPGCS4Q-Bmx7dA25.js} +1 -1
  71. package/dist/assets/{kanban-definition-3W4ZIXB7-kX5aL9Ug.js → kanban-definition-3W4ZIXB7-DJzhLwsl.js} +1 -1
  72. package/dist/assets/katex-axIMlGRc.js +1 -0
  73. package/dist/assets/{label-C9wP7Kp2.js → label-C--1sWU6.js} +1 -1
  74. package/dist/assets/{layout-D7NLGhPa.js → layout-ZtHfLqYp.js} +3 -3
  75. package/dist/assets/{linear-BxhToEEF.js → linear-DWpCiijk.js} +1 -1
  76. package/dist/assets/{logs-panel-y2i-7VQF.js → logs-panel-z3Z9lCbV.js} +1 -1
  77. package/dist/assets/{markdown-renderer-D8AmLSIR.js → markdown-renderer-Md8pHWxP.js} +1 -1
  78. package/dist/assets/mermaid-4DMBBIKO-Dn0v3H8Z.js +1 -0
  79. package/dist/assets/{mermaid-Caj4ROsO.js → mermaid-dAaJQU1M.js} +3 -3
  80. package/dist/assets/{mhchem-CJmb5HsA.js → mhchem-2XRJK9de.js} +1 -1
  81. package/dist/assets/{mindmap-definition-VGOIOE7T-BJ9zWUqW.js → mindmap-definition-VGOIOE7T-whTFv8Zv.js} +1 -1
  82. package/dist/assets/{name-cell-input-BthamWJY.js → name-cell-input-BGxKE7pD.js} +1 -1
  83. package/dist/assets/{number-overlay-editor-DIy8e1ST.js → number-overlay-editor-65UcMR52.js} +1 -1
  84. package/dist/assets/{packages-panel-DsF1uf9X.js → packages-panel-BheI3Whw.js} +1 -1
  85. package/dist/assets/{panels-aWY9-L83.js → panels-5zIgiTjO.js} +1 -1
  86. package/dist/assets/{pieDiagram-ADFJNKIX-Mf2FMnt9.js → pieDiagram-ADFJNKIX-4n07I4VV.js} +1 -1
  87. package/dist/assets/{precisionRound-CU2C3Vxx.js → precisionRound-C3fmBb6j.js} +1 -1
  88. package/dist/assets/{quadrantDiagram-AYHSOK5B-B04U71uV.js → quadrantDiagram-AYHSOK5B-CNm24EC2.js} +1 -1
  89. package/dist/assets/{react-plotly-D4UaXGJL.js → react-plotly-OyYr93y7.js} +1 -1
  90. package/dist/assets/{react-vega-CqegDZRQ.js → react-vega-BEiHA2e9.js} +1 -1
  91. package/dist/assets/react-vega-BrNLU7si.js +1 -0
  92. package/dist/assets/{readonly-python-code-C_8a4fwz.js → readonly-python-code-q8H4JtWe.js} +1 -1
  93. package/dist/assets/{renderShortcut-B1jzzLJw.js → renderShortcut-Xr6z-RjZ.js} +1 -1
  94. package/dist/assets/{requirementDiagram-UZGBJVZJ-oJlPs172.js → requirementDiagram-UZGBJVZJ-B7BwuJGh.js} +1 -1
  95. package/dist/assets/{run-page-DQU-eaKQ.js → run-page-BtgxUxdD.js} +1 -1
  96. package/dist/assets/{sankeyDiagram-TZEHDZUN-aplEbaHE.js → sankeyDiagram-TZEHDZUN-C8KpmdhC.js} +1 -1
  97. package/dist/assets/{scratchpad-panel-N4QLTtHb.js → scratchpad-panel-BZn63vOx.js} +1 -1
  98. package/dist/assets/{secrets-panel-vKKBtc8G.js → secrets-panel-CEMSgQv5.js} +1 -1
  99. package/dist/assets/{sequenceDiagram-WL72ISMW-WAUwGkkd.js → sequenceDiagram-WL72ISMW-D0_AcPzd.js} +1 -1
  100. package/dist/assets/{session-panel-Cof-5_26.js → session-panel-iRBC1bk4.js} +1 -1
  101. package/dist/assets/{slides-component-CeMnlG8H.js → slides-component-C0UAH9QZ.js} +1 -1
  102. package/dist/assets/{snippets-panel-WBcYsSsb.js → snippets-panel-paMvhw49.js} +1 -1
  103. package/dist/assets/{stateDiagram-FKZM4ZOC-DUDhr_Gg.js → stateDiagram-FKZM4ZOC-Dz_iVJd6.js} +1 -1
  104. package/dist/assets/stateDiagram-v2-4FDKWEC3-CupainMB.js +1 -0
  105. package/dist/assets/{terminal-CF-esPMT.js → terminal-BLSSaFMR.js} +1 -1
  106. package/dist/assets/{textarea-8F9GOEGf.js → textarea-B9TY02t9.js} +1 -1
  107. package/dist/assets/{time-EL4bnqqQ.js → time-CSCsAxXS.js} +1 -1
  108. package/dist/assets/{timeline-definition-IT6M3QCI-D93LYpWp.js → timeline-definition-IT6M3QCI-DPXEeoSm.js} +1 -1
  109. package/dist/assets/{tooltip-DxKBXCGp.js → tooltip-DqsDDLgU.js} +1 -1
  110. package/dist/assets/{tracing-DGYwY__a.js → tracing-DVD0lR_-.js} +1 -1
  111. package/dist/assets/{tracing-panel-BHnlOWW9.js → tracing-panel-D0p98UnG.js} +2 -2
  112. package/dist/assets/{tree-B8r7cwRm.js → tree-Hg81oJmp.js} +1 -1
  113. package/dist/assets/{useAddCell-Cx99GRHQ.js → useAddCell-C0mjPsjt.js} +1 -1
  114. package/dist/assets/{useCellActionButton-VRGP_KkG.js → useCellActionButton-DR2cYGwm.js} +1 -1
  115. package/dist/assets/{useDeleteCell-DHPNhAtW.js → useDeleteCell-DyGTLzfg.js} +1 -1
  116. package/dist/assets/{useDependencyPanelTab-UoJrnugs.js → useDependencyPanelTab-Dd7aOXV0.js} +1 -1
  117. package/dist/assets/{useInstallPackage-xrG_Tm9T.js → useInstallPackage-Co79H1lQ.js} +1 -1
  118. package/dist/assets/{useNotebookActions-BEKXbrFJ.js → useNotebookActions-DMf9_Eai.js} +1 -1
  119. package/dist/assets/{useSplitCell-h8RpNtuv.js → useSplitCell-dutfMkv3.js} +1 -1
  120. package/dist/assets/{utilities.esm-AIy-_q0N.js → utilities.esm-BREvtThv.js} +1 -1
  121. package/dist/assets/{vega-component-D4ZTpyiq.js → vega-component-7jd4fFCJ.js} +1 -1
  122. package/dist/assets/{vega-loader.browser-DXARUlxo.js → vega-loader.browser-BegSZk0G.js} +1 -1
  123. package/dist/assets/{write-secret-modal-BodBOJkR.js → write-secret-modal-DO-EOoNO.js} +1 -1
  124. package/dist/assets/{xychartDiagram-PRI3JC2R-C8jV7uCC.js → xychartDiagram-PRI3JC2R-DINfGlOV.js} +1 -1
  125. package/dist/index.html +56 -56
  126. package/package.json +1 -1
  127. package/src/components/pages/gallery-page.tsx +37 -6
  128. package/src/core/ai/context/providers/file.ts +1 -1
  129. package/src/core/static/__tests__/files.test.ts +195 -1
  130. package/src/core/static/files.ts +39 -9
  131. package/src/plugins/impl/anywidget/AnyWidgetPlugin.tsx +7 -1
  132. package/src/utils/__tests__/blob.test.ts +3 -3
  133. package/src/utils/blob.ts +14 -27
  134. package/dist/assets/blob-t6qcPM7K.js +0 -1
  135. package/dist/assets/channel-CUmF6tDU.js +0 -1
  136. package/dist/assets/classDiagram-2ON5EDUG-DLI68D-F.js +0 -1
  137. package/dist/assets/classDiagram-v2-WZHVMYZB-yfw4NTdf.js +0 -1
  138. package/dist/assets/gallery-page-Yq7Go5FK.js +0 -1
  139. package/dist/assets/index-BTVKRPtt.css +0 -2
  140. package/dist/assets/katex-DF982Ty5.js +0 -1
  141. package/dist/assets/mermaid-4DMBBIKO-DQz_QvBC.js +0 -1
  142. package/dist/assets/react-vega-CP7NqbRQ.js +0 -1
  143. package/dist/assets/stateDiagram-v2-4FDKWEC3-yH9Rugj-.js +0 -1
  144. /package/dist/assets/{alert-BOoN6gJ1.js → alert-Cx8eFRUM.js} +0 -0
  145. /package/dist/assets/{cell-link-BoOn0OpK.js → cell-link-DfoJF6Bq.js} +0 -0
  146. /package/dist/assets/{copy-DHrHayPa.js → copy-BaRrAFL-.js} +0 -0
  147. /package/dist/assets/{defaultLocale-BLne0bXb.js → defaultLocale-B6z1Qyqt.js} +0 -0
  148. /package/dist/assets/{defaultLocale-JieDVWC_.js → defaultLocale-YteS-k_t.js} +0 -0
  149. /package/dist/assets/{dist-CDXJRSCj.js → dist-BMEHQAhk.js} +0 -0
  150. /package/dist/assets/{emotion-is-prop-valid.esm-C59xfSYt.js → emotion-is-prop-valid.esm-Dangy3Bv.js} +0 -0
  151. /package/dist/assets/{error-banner-Dlrzo_Ay.js → error-banner-w4pz2qUB.js} +0 -0
  152. /package/dist/assets/{extends-BiFDv3jB.js → extends-Dqvpuc10.js} +0 -0
  153. /package/dist/assets/{focus-BEf2RhRf.js → focus-RQ0afibT.js} +0 -0
  154. /package/dist/assets/{html-to-image-DrmKVKna.js → html-to-image-BIY1TtH0.js} +0 -0
  155. /package/dist/assets/{katex-CDLTCvjQ.js → katex-CbllUrnh.js} +0 -0
  156. /package/dist/assets/{kbd-Cm6Ba9qg.js → kbd-k3Sn_RwW.js} +0 -0
  157. /package/dist/assets/{links-7AQBmdyV.js → links-fh_IXIKE.js} +0 -0
  158. /package/dist/assets/{multi-map-t2yhdp8D.js → multi-map-A4XNra08.js} +0 -0
  159. /package/dist/assets/{objectWithoutPropertiesLoose-DfWeGRFv.js → objectWithoutPropertiesLoose-DoKw85w0.js} +0 -0
  160. /package/dist/assets/{ordinal-C93T4L8H.js → ordinal-DAqJmfoU.js} +0 -0
  161. /package/dist/assets/{process-output-OTqBNunj.js → process-output-C77tRi36.js} +0 -0
  162. /package/dist/assets/{prop-types-DaaA-ptl.js → prop-types-DVDiRdwc.js} +0 -0
  163. /package/dist/assets/{purify.es-DZrAQFIu.js → purify.es-B-nzWya6.js} +0 -0
  164. /package/dist/assets/{range-1DwpgXvM.js → range-7fnH_zLA.js} +0 -0
  165. /package/dist/assets/{table-DScsXgJW.js → table-BOsFCeLh.js} +0 -0
  166. /package/dist/assets/{useAsyncData-BMGLSTg8.js → useAsyncData-CgmD3hjw.js} +0 -0
  167. /package/dist/assets/{useDeepCompareMemoize-ChxLMT9E.js → useDeepCompareMemoize-CFtQU7An.js} +0 -0
  168. /package/dist/assets/{useIframeCapabilities-B_pQb20b.js → useIframeCapabilities-CC8VH6kZ.js} +0 -0
  169. /package/dist/assets/{useRunCells-BOowME8Z.js → useRunCells-BJznEpzj.js} +0 -0
@@ -1,3 +1,3 @@
1
- var at=Object.defineProperty;var it=(t,e,n)=>e in t?at(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var a=(t,e,n)=>it(t,typeof e!="symbol"?e+"":e,n);var j;import{s as ce}from"./chunk-LvLJmgfZ.js";import{i as G,l as D,p as P,u as ot}from"./useEvent-BhXAndur.js";import{t as lt}from"./react-Bj1aDYRI.js";import{$r as z,Qr as ut,Vr as ct,b as dt,qr as ft,y as mt}from"./cells-DbD2lYze.js";import{B as pt,C as de,D as ht,I as gt,N as yt,P as O,R as fe,k as W,w as me}from"./zod-H_cgTO0M.js";import{t as pe}from"./compiler-runtime-B3qBwwSJ.js";import{t as bt}from"./get-6uJrSKbw.js";import{t as wt}from"./assertNever-CBU83Y6o.js";import{t as vt}from"./debounce-B3mjKxHe.js";import{t as xt}from"./_baseSet-5Rdwpmr3.js";import{d as E,p as y}from"./hotkeys-BHHWjLlp.js";import{t as Et}from"./invariant-CAG_dYON.js";import{S as Ct}from"./utils-YqBXNpsM.js";import{S as _t}from"./config-D2-Bw6QC.js";import{a as kt}from"./switch-BUKXfBTu.js";import{n as he}from"./globals-BXYmO-WL.js";import{t as ge}from"./ErrorBoundary-B9Ifj8Jf.js";import{t as Rt}from"./jsx-runtime-ZmTK25f3.js";import{t as Ft}from"./button-CZ3Cs4qb.js";import{t as Nt}from"./cn-BKtXLv3a.js";import{Z as St}from"./JsonOutput-DsO4felE.js";import{t as qt}from"./createReducer-B3rBsy4P.js";import{t as ye}from"./requests-B4FYHTZl.js";import{t as be}from"./createLucideIcon-BCdY6lG5.js";import{t as Pt}from"./x-ZP5cObgf.js";import{a as Mt,l as jt,r as At}from"./markdown-renderer-D8AmLSIR.js";import{t as Tt}from"./DeferredRequestRegistry-tv0PqJZ0.js";import{t as K}from"./Deferred-CrO5-0RA.js";import{t as we}from"./uuid-DercMavo.js";import{t as It}from"./use-toast-T0_cQDma.js";import{t as ve}from"./tooltip-C_WgOOcZ.js";import{t as xe}from"./mode-CjmQoGEk.js";import{n as Lt,r as Ut,t as zt}from"./share-rXkgGlhr.js";import{r as Ot,t as Wt}from"./react-resizable-panels.browser.esm-Mq45xjWt.js";import{t as Ee}from"./toggle-CriARMQK.js";function Dt(t,e,n){return t==null?t:xt(t,e,n)}var H=Dt,Ht=be("crosshair",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"22",x2:"18",y1:"12",y2:"12",key:"l9bcsi"}],["line",{x1:"6",x2:"2",y1:"12",y2:"12",key:"13hhkx"}],["line",{x1:"12",x2:"12",y1:"6",y2:"2",key:"10w3f3"}],["line",{x1:"12",x2:"12",y1:"22",y2:"18",key:"15g9kq"}]]),Bt=be("pin",[["path",{d:"M12 17v5",key:"bb1du9"}],["path",{d:"M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z",key:"1nkz8b"}]]);function Vt(t){return{all:t||(t=new Map),on:function(e,n){var r=t.get(e);r?r.push(n):t.set(e,[n])},off:function(e,n){var r=t.get(e);r&&(n?r.splice(r.indexOf(n)>>>0,1):t.set(e,[]))},emit:function(e,n){var r=t.get(e);r&&r.slice().map(function(s){s(n)}),(r=t.get("*"))&&r.slice().map(function(s){s(e,n)})}}}var u=ce(lt(),1),J=(0,u.createContext)(null),$t=t=>{let{controller:e}=(0,u.useContext)(J),n=u.useRef(Symbol("fill"));return(0,u.useEffect)(()=>(e.mount({name:t.name,ref:n.current,children:t.children}),()=>{e.unmount({name:t.name,ref:n.current})}),[]),(0,u.useEffect)(()=>{e.update({name:t.name,ref:n.current,children:t.children})}),null},Xt=Object.defineProperty,Yt=(t,e,n)=>e in t?Xt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ce=(t,e,n)=>(Yt(t,typeof e=="symbol"?e:e+"",n),n),_e=console,Qt=class{constructor(t){Ce(this,"_bus"),Ce(this,"_db"),this._bus=t,this.handleFillMount=this.handleFillMount.bind(this),this.handleFillUpdated=this.handleFillUpdated.bind(this),this.handleFillUnmount=this.handleFillUnmount.bind(this),this._db={byName:new Map,byFill:new Map}}mount(){this._bus.on("fill-mount",this.handleFillMount),this._bus.on("fill-updated",this.handleFillUpdated),this._bus.on("fill-unmount",this.handleFillUnmount)}unmount(){this._bus.off("fill-mount",this.handleFillMount),this._bus.off("fill-updated",this.handleFillUpdated),this._bus.off("fill-unmount",this.handleFillUnmount)}handleFillMount({fill:t}){let e=u.Children.toArray(t.children),n=t.name,r={fill:t,children:e,name:n},s=this._db.byName.get(n);s?(s.components.push(r),s.listeners.forEach(i=>i([...s.components]))):this._db.byName.set(n,{listeners:[],components:[r]}),this._db.byFill.set(t.ref,r)}handleFillUpdated({fill:t}){let e=this._db.byFill.get(t.ref),n=u.Children.toArray(t.children);if(e){e.children=n;let r=this._db.byName.get(e.name);if(r)r.listeners.forEach(s=>s([...r.components]));else throw Error("registration was expected to be defined")}else{_e.error("[handleFillUpdated] component was expected to be defined");return}}handleFillUnmount({fill:t}){let e=this._db.byFill.get(t.ref);if(!e){_e.error("[handleFillUnmount] component was expected to be defined");return}let n=e.name,r=this._db.byName.get(n);if(!r)throw Error("registration was expected to be defined");r.components=r.components.filter(s=>s!==e),this._db.byFill.delete(t.ref),r.listeners.length===0&&r.components.length===0?this._db.byName.delete(n):r.listeners.forEach(s=>s([...r.components]))}onComponentsChange(t,e){let n=this._db.byName.get(t);n?(n.listeners.push(e),e(n.components)):(this._db.byName.set(t,{listeners:[e],components:[]}),e([]))}getFillsByName(t){let e=this._db.byName.get(t);return e?e.components.map(n=>n.fill):[]}getChildrenByName(t){let e=this._db.byName.get(t);return e?e.components.map(n=>n.children).reduce((n,r)=>n.concat(r),[]):[]}removeOnComponentsChange(t,e){let n=this._db.byName.get(t);if(!n)throw Error("expected registration to be defined");let r=n.listeners;r.splice(r.indexOf(e),1)}},Gt=Object.defineProperty,Kt=(t,e,n)=>e in t?Gt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Jt=(t,e,n)=>(Kt(t,typeof e=="symbol"?e:e+"",n),n),ke=class{constructor(){Jt(this,"bus",Vt())}mount(t){this.bus.emit("fill-mount",{fill:t})}unmount(t){this.bus.emit("fill-unmount",{fill:t})}update(t){this.bus.emit("fill-updated",{fill:t})}};function Zt(t){let e=t||new ke;return{controller:e,manager:new Qt(e.bus)}}var en=({controller:t,children:e})=>{let[n]=u.useState(()=>{let r=Zt(t);return r.manager.mount(),r});return u.useEffect(()=>()=>{n.manager.unmount()},[]),u.createElement(J.Provider,{value:n},e)};function Z(t,e){let[n,r]=(0,u.useState)([]),{manager:s}=(0,u.useContext)(J);return(0,u.useEffect)(()=>(s.onComponentsChange(t,r),()=>{s.removeOnComponentsChange(t,r)}),[t]),n.flatMap((i,d)=>{let{children:l}=i;return l.map((p,b)=>{if(typeof p=="number"||typeof p=="string")throw Error("Only element children will work here");return u.cloneElement(p,{key:d.toString()+b.toString(),...e})})})}var Re=t=>{let e=Z(t.name,t.childProps);if(typeof t.children=="function"){let n=t.children(e);if(u.isValidElement(n)||n===null)return n;throw Error("Slot rendered with function must return a valid React Element.")}return e};const tn=P(null);var{valueAtom:nn,useActions:rn}=qt(()=>({banners:[]}),{addBanner:(t,e)=>({...t,banners:[...t.banners,{...e,id:we()}]}),removeBanner:(t,e)=>({...t,banners:t.banners.filter(n=>n.id!==e)}),clearBanners:t=>({...t,banners:[]})});const sn=()=>ot(nn);function an(){return rn()}const on=new ke,B={SIDEBAR:"sidebar",CONTEXT_AWARE_PANEL:"context-aware-panel"};var ln=class{constructor(){a(this,"subscriptions",new Map)}addSubscription(t,e){var n;this.subscriptions.has(t)||this.subscriptions.set(t,new Set),(n=this.subscriptions.get(t))==null||n.add(e)}removeSubscription(t,e){var n;(n=this.subscriptions.get(t))==null||n.delete(e)}notify(t,e){for(let n of this.subscriptions.get(t)??[])n(e)}},Fe=class ue{constructor(e){a(this,"subscriptions",new ln);this.producer=e}static withProducerCallback(e){return new ue(e)}static empty(){return new ue}startProducer(){this.producer&&this.producer(e=>{this.subscriptions.notify("message",e)})}connect(){return new Promise(e=>setTimeout(e,0)).then(()=>{this.subscriptions.notify("open",new Event("open"))})}get readyState(){return WebSocket.OPEN}reconnect(e,n){this.close(),this.connect()}close(){this.subscriptions.notify("close",new Event("close"))}send(e){return this.subscriptions.notify("message",new MessageEvent("message",{data:e})),Promise.resolve()}addEventListener(e,n){this.subscriptions.addSubscription(e,n),e==="open"&&n(new Event("open")),e==="message"&&this.startProducer()}removeEventListener(e,n){this.subscriptions.removeSubscription(e,n)}},un=1e10,cn=1e3;function V(t,e){let n=t.map(r=>`"${r}"`).join(", ");return Error(`This RPC instance cannot ${e} because the transport did not provide one or more of these methods: ${n}`)}function dn(t={}){let e={};function n(o){e=o}let r={};function s(o){var f;r.unregisterHandler&&r.unregisterHandler(),r=o,(f=r.registerHandler)==null||f.call(r,U)}let i;function d(o){if(typeof o=="function"){i=o;return}i=(f,g)=>{let c=o[f];if(c)return c(g);let h=o._;if(!h)throw Error(`The requested method has no handler: ${f}`);return h(f,g)}}let{maxRequestTime:l=cn}=t;t.transport&&s(t.transport),t.requestHandler&&d(t.requestHandler),t._debugHooks&&n(t._debugHooks);let p=0;function b(){return p<=un?++p:p=0}let x=new Map,w=new Map;function C(o,...f){let g=f[0];return new Promise((c,h)=>{var T;if(!r.send)throw V(["send"],"make requests");let S=b(),M={type:"request",id:S,method:o,params:g};x.set(S,{resolve:c,reject:h}),l!==1/0&&w.set(S,setTimeout(()=>{w.delete(S),h(Error("RPC request timed out."))},l)),(T=e.onSend)==null||T.call(e,M),r.send(M)})}let F=new Proxy(C,{get:(o,f,g)=>f in o?Reflect.get(o,f,g):c=>C(f,c)}),_=F;function k(o,...f){var h;let g=f[0];if(!r.send)throw V(["send"],"send messages");let c={type:"message",id:o,payload:g};(h=e.onSend)==null||h.call(e,c),r.send(c)}let R=new Proxy(k,{get:(o,f,g)=>f in o?Reflect.get(o,f,g):c=>k(f,c)}),v=R,N=new Map,q=new Set;function A(o,f){var g;if(!r.registerHandler)throw V(["registerHandler"],"register message listeners");if(o==="*"){q.add(f);return}N.has(o)||N.set(o,new Set),(g=N.get(o))==null||g.add(f)}function L(o,f){var g,c;if(o==="*"){q.delete(f);return}(g=N.get(o))==null||g.delete(f),((c=N.get(o))==null?void 0:c.size)===0&&N.delete(o)}async function U(o){var f,g;if((f=e.onReceive)==null||f.call(e,o),!("type"in o))throw Error("Message does not contain a type.");if(o.type==="request"){if(!r.send||!i)throw V(["send","requestHandler"],"handle requests");let{id:c,method:h,params:S}=o,M;try{M={type:"response",id:c,success:!0,payload:await i(h,S)}}catch(T){if(!(T instanceof Error))throw T;M={type:"response",id:c,success:!1,error:T.message}}(g=e.onSend)==null||g.call(e,M),r.send(M);return}if(o.type==="response"){let c=w.get(o.id);c!=null&&clearTimeout(c);let{resolve:h,reject:S}=x.get(o.id)??{};o.success?h==null||h(o.payload):S==null||S(Error(o.error));return}if(o.type==="message"){for(let h of q)h(o.id,o.payload);let c=N.get(o.id);if(!c)return;for(let h of c)h(o.payload);return}throw Error(`Unexpected RPC message type: ${o.type}`)}return{setTransport:s,setRequestHandler:d,request:F,requestProxy:_,send:R,sendProxy:v,addMessageListener:A,removeMessageListener:L,proxy:{send:v,request:_},_setDebugHooks:n}}function fn(t){return dn(t)}var Ne="[transport-id]";function mn(t,e){let{transportId:n}=e;return n==null?t:{[Ne]:n,data:t}}function pn(t,e){let{transportId:n,filter:r}=e,s=r==null?void 0:r();if(n!=null&&s!=null)throw Error("Cannot use both `transportId` and `filter` at the same time");let i=t;if(n){if(t[Ne]!==n)return[!0];i=t.data}return s===!1?[!0]:[!1,i]}function hn(t,e={}){let{transportId:n,filter:r,remotePort:s}=e,i=t,d=s??t,l;return{send(p){d.postMessage(mn(p,{transportId:n}))},registerHandler(p){l=b=>{let x=b.data,[w,C]=pn(x,{transportId:n,filter:()=>r==null?void 0:r(b)});w||p(C)},i.addEventListener("message",l)},unregisterHandler(){l&&i.removeEventListener("message",l)}}}function gn(t,e){return hn(t,e)}function Se(t){return fn({transport:gn(t,{transportId:"marimo-transport"}),maxRequestTime:2e4,_debugHooks:{onSend:e=>{E.debug("[rpc] Parent -> Worker",e)},onReceive:e=>{E.debug("[rpc] Worker -> Parent",e)}}})}const qe=P("Initializing..."),yn=P(t=>{let e=t(mt),n=Object.values(e.cellRuntime);return n.some(r=>!jt(r.output))?!0:n.every(r=>r.status==="idle")});var Pe=Lt(),Me="marimo:file",je=new ct(null);const bn={saveFile(t){je.set(Me,t)},readFile(){return je.get(Me)}};var wn={saveFile(t){z.setCodeForHash((0,Pe.compressToEncodedURIComponent)(t))},readFile(){let t=z.getCodeFromHash()||z.getCodeFromSearchParam();return t?(0,Pe.decompressFromEncodedURIComponent)(t):null}};const vn={saveFile(t){},readFile(){let t=document.querySelector("marimo-code");return t?decodeURIComponent(t.textContent||"").trim():null}};var xn={saveFile(t){},readFile(){if(window.location.hostname!=="marimo.app")return null;let t=new URL("files/wasm-intro.py",document.baseURI);return fetch(t.toString()).then(e=>e.ok?e.text():null).catch(()=>null)}},En={saveFile(t){},readFile(){return["import marimo","app = marimo.App()","","@app.cell","def __():"," return","",'if __name__ == "__main__":'," app.run()"].join(`
1
+ var at=Object.defineProperty;var it=(t,e,n)=>e in t?at(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var a=(t,e,n)=>it(t,typeof e!="symbol"?e+"":e,n);var j;import{s as ce}from"./chunk-LvLJmgfZ.js";import{i as G,l as D,p as P,u as ot}from"./useEvent-BhXAndur.js";import{t as lt}from"./react-Bj1aDYRI.js";import{$r as z,Qr as ut,Vr as ct,b as dt,qr as ft,y as mt}from"./cells-DbD2lYze.js";import{B as pt,C as de,D as ht,I as gt,N as yt,P as O,R as fe,k as W,w as me}from"./zod-H_cgTO0M.js";import{t as pe}from"./compiler-runtime-B3qBwwSJ.js";import{t as bt}from"./get-6uJrSKbw.js";import{t as wt}from"./assertNever-CBU83Y6o.js";import{t as vt}from"./debounce-B3mjKxHe.js";import{t as xt}from"./_baseSet-5Rdwpmr3.js";import{d as E,p as y}from"./hotkeys-BHHWjLlp.js";import{t as Et}from"./invariant-CAG_dYON.js";import{S as Ct}from"./utils-YqBXNpsM.js";import{S as _t}from"./config-D2-Bw6QC.js";import{a as kt}from"./switch-BUKXfBTu.js";import{n as he}from"./globals-BXYmO-WL.js";import{t as ge}from"./ErrorBoundary-B9Ifj8Jf.js";import{t as Rt}from"./jsx-runtime-ZmTK25f3.js";import{t as Ft}from"./button-CZ3Cs4qb.js";import{t as Nt}from"./cn-BKtXLv3a.js";import{Z as St}from"./JsonOutput-BPSYj_Kn.js";import{t as qt}from"./createReducer-B3rBsy4P.js";import{t as ye}from"./requests-B4FYHTZl.js";import{t as be}from"./createLucideIcon-BCdY6lG5.js";import{t as Pt}from"./x-ZP5cObgf.js";import{a as Mt,l as jt,r as At}from"./markdown-renderer-Md8pHWxP.js";import{t as Tt}from"./DeferredRequestRegistry-tv0PqJZ0.js";import{t as K}from"./Deferred-CrO5-0RA.js";import{t as we}from"./uuid-DercMavo.js";import{t as It}from"./use-toast-T0_cQDma.js";import{t as ve}from"./tooltip-C_WgOOcZ.js";import{t as xe}from"./mode-CjmQoGEk.js";import{n as Lt,r as Ut,t as zt}from"./share-rXkgGlhr.js";import{r as Ot,t as Wt}from"./react-resizable-panels.browser.esm-Mq45xjWt.js";import{t as Ee}from"./toggle-CriARMQK.js";function Dt(t,e,n){return t==null?t:xt(t,e,n)}var H=Dt,Ht=be("crosshair",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"22",x2:"18",y1:"12",y2:"12",key:"l9bcsi"}],["line",{x1:"6",x2:"2",y1:"12",y2:"12",key:"13hhkx"}],["line",{x1:"12",x2:"12",y1:"6",y2:"2",key:"10w3f3"}],["line",{x1:"12",x2:"12",y1:"22",y2:"18",key:"15g9kq"}]]),Bt=be("pin",[["path",{d:"M12 17v5",key:"bb1du9"}],["path",{d:"M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z",key:"1nkz8b"}]]);function Vt(t){return{all:t||(t=new Map),on:function(e,n){var r=t.get(e);r?r.push(n):t.set(e,[n])},off:function(e,n){var r=t.get(e);r&&(n?r.splice(r.indexOf(n)>>>0,1):t.set(e,[]))},emit:function(e,n){var r=t.get(e);r&&r.slice().map(function(s){s(n)}),(r=t.get("*"))&&r.slice().map(function(s){s(e,n)})}}}var u=ce(lt(),1),J=(0,u.createContext)(null),$t=t=>{let{controller:e}=(0,u.useContext)(J),n=u.useRef(Symbol("fill"));return(0,u.useEffect)(()=>(e.mount({name:t.name,ref:n.current,children:t.children}),()=>{e.unmount({name:t.name,ref:n.current})}),[]),(0,u.useEffect)(()=>{e.update({name:t.name,ref:n.current,children:t.children})}),null},Xt=Object.defineProperty,Yt=(t,e,n)=>e in t?Xt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ce=(t,e,n)=>(Yt(t,typeof e=="symbol"?e:e+"",n),n),_e=console,Qt=class{constructor(t){Ce(this,"_bus"),Ce(this,"_db"),this._bus=t,this.handleFillMount=this.handleFillMount.bind(this),this.handleFillUpdated=this.handleFillUpdated.bind(this),this.handleFillUnmount=this.handleFillUnmount.bind(this),this._db={byName:new Map,byFill:new Map}}mount(){this._bus.on("fill-mount",this.handleFillMount),this._bus.on("fill-updated",this.handleFillUpdated),this._bus.on("fill-unmount",this.handleFillUnmount)}unmount(){this._bus.off("fill-mount",this.handleFillMount),this._bus.off("fill-updated",this.handleFillUpdated),this._bus.off("fill-unmount",this.handleFillUnmount)}handleFillMount({fill:t}){let e=u.Children.toArray(t.children),n=t.name,r={fill:t,children:e,name:n},s=this._db.byName.get(n);s?(s.components.push(r),s.listeners.forEach(i=>i([...s.components]))):this._db.byName.set(n,{listeners:[],components:[r]}),this._db.byFill.set(t.ref,r)}handleFillUpdated({fill:t}){let e=this._db.byFill.get(t.ref),n=u.Children.toArray(t.children);if(e){e.children=n;let r=this._db.byName.get(e.name);if(r)r.listeners.forEach(s=>s([...r.components]));else throw Error("registration was expected to be defined")}else{_e.error("[handleFillUpdated] component was expected to be defined");return}}handleFillUnmount({fill:t}){let e=this._db.byFill.get(t.ref);if(!e){_e.error("[handleFillUnmount] component was expected to be defined");return}let n=e.name,r=this._db.byName.get(n);if(!r)throw Error("registration was expected to be defined");r.components=r.components.filter(s=>s!==e),this._db.byFill.delete(t.ref),r.listeners.length===0&&r.components.length===0?this._db.byName.delete(n):r.listeners.forEach(s=>s([...r.components]))}onComponentsChange(t,e){let n=this._db.byName.get(t);n?(n.listeners.push(e),e(n.components)):(this._db.byName.set(t,{listeners:[e],components:[]}),e([]))}getFillsByName(t){let e=this._db.byName.get(t);return e?e.components.map(n=>n.fill):[]}getChildrenByName(t){let e=this._db.byName.get(t);return e?e.components.map(n=>n.children).reduce((n,r)=>n.concat(r),[]):[]}removeOnComponentsChange(t,e){let n=this._db.byName.get(t);if(!n)throw Error("expected registration to be defined");let r=n.listeners;r.splice(r.indexOf(e),1)}},Gt=Object.defineProperty,Kt=(t,e,n)=>e in t?Gt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Jt=(t,e,n)=>(Kt(t,typeof e=="symbol"?e:e+"",n),n),ke=class{constructor(){Jt(this,"bus",Vt())}mount(t){this.bus.emit("fill-mount",{fill:t})}unmount(t){this.bus.emit("fill-unmount",{fill:t})}update(t){this.bus.emit("fill-updated",{fill:t})}};function Zt(t){let e=t||new ke;return{controller:e,manager:new Qt(e.bus)}}var en=({controller:t,children:e})=>{let[n]=u.useState(()=>{let r=Zt(t);return r.manager.mount(),r});return u.useEffect(()=>()=>{n.manager.unmount()},[]),u.createElement(J.Provider,{value:n},e)};function Z(t,e){let[n,r]=(0,u.useState)([]),{manager:s}=(0,u.useContext)(J);return(0,u.useEffect)(()=>(s.onComponentsChange(t,r),()=>{s.removeOnComponentsChange(t,r)}),[t]),n.flatMap((i,d)=>{let{children:l}=i;return l.map((p,b)=>{if(typeof p=="number"||typeof p=="string")throw Error("Only element children will work here");return u.cloneElement(p,{key:d.toString()+b.toString(),...e})})})}var Re=t=>{let e=Z(t.name,t.childProps);if(typeof t.children=="function"){let n=t.children(e);if(u.isValidElement(n)||n===null)return n;throw Error("Slot rendered with function must return a valid React Element.")}return e};const tn=P(null);var{valueAtom:nn,useActions:rn}=qt(()=>({banners:[]}),{addBanner:(t,e)=>({...t,banners:[...t.banners,{...e,id:we()}]}),removeBanner:(t,e)=>({...t,banners:t.banners.filter(n=>n.id!==e)}),clearBanners:t=>({...t,banners:[]})});const sn=()=>ot(nn);function an(){return rn()}const on=new ke,B={SIDEBAR:"sidebar",CONTEXT_AWARE_PANEL:"context-aware-panel"};var ln=class{constructor(){a(this,"subscriptions",new Map)}addSubscription(t,e){var n;this.subscriptions.has(t)||this.subscriptions.set(t,new Set),(n=this.subscriptions.get(t))==null||n.add(e)}removeSubscription(t,e){var n;(n=this.subscriptions.get(t))==null||n.delete(e)}notify(t,e){for(let n of this.subscriptions.get(t)??[])n(e)}},Fe=class ue{constructor(e){a(this,"subscriptions",new ln);this.producer=e}static withProducerCallback(e){return new ue(e)}static empty(){return new ue}startProducer(){this.producer&&this.producer(e=>{this.subscriptions.notify("message",e)})}connect(){return new Promise(e=>setTimeout(e,0)).then(()=>{this.subscriptions.notify("open",new Event("open"))})}get readyState(){return WebSocket.OPEN}reconnect(e,n){this.close(),this.connect()}close(){this.subscriptions.notify("close",new Event("close"))}send(e){return this.subscriptions.notify("message",new MessageEvent("message",{data:e})),Promise.resolve()}addEventListener(e,n){this.subscriptions.addSubscription(e,n),e==="open"&&n(new Event("open")),e==="message"&&this.startProducer()}removeEventListener(e,n){this.subscriptions.removeSubscription(e,n)}},un=1e10,cn=1e3;function V(t,e){let n=t.map(r=>`"${r}"`).join(", ");return Error(`This RPC instance cannot ${e} because the transport did not provide one or more of these methods: ${n}`)}function dn(t={}){let e={};function n(o){e=o}let r={};function s(o){var f;r.unregisterHandler&&r.unregisterHandler(),r=o,(f=r.registerHandler)==null||f.call(r,U)}let i;function d(o){if(typeof o=="function"){i=o;return}i=(f,g)=>{let c=o[f];if(c)return c(g);let h=o._;if(!h)throw Error(`The requested method has no handler: ${f}`);return h(f,g)}}let{maxRequestTime:l=cn}=t;t.transport&&s(t.transport),t.requestHandler&&d(t.requestHandler),t._debugHooks&&n(t._debugHooks);let p=0;function b(){return p<=un?++p:p=0}let x=new Map,w=new Map;function C(o,...f){let g=f[0];return new Promise((c,h)=>{var T;if(!r.send)throw V(["send"],"make requests");let S=b(),M={type:"request",id:S,method:o,params:g};x.set(S,{resolve:c,reject:h}),l!==1/0&&w.set(S,setTimeout(()=>{w.delete(S),h(Error("RPC request timed out."))},l)),(T=e.onSend)==null||T.call(e,M),r.send(M)})}let F=new Proxy(C,{get:(o,f,g)=>f in o?Reflect.get(o,f,g):c=>C(f,c)}),_=F;function k(o,...f){var h;let g=f[0];if(!r.send)throw V(["send"],"send messages");let c={type:"message",id:o,payload:g};(h=e.onSend)==null||h.call(e,c),r.send(c)}let R=new Proxy(k,{get:(o,f,g)=>f in o?Reflect.get(o,f,g):c=>k(f,c)}),v=R,N=new Map,q=new Set;function A(o,f){var g;if(!r.registerHandler)throw V(["registerHandler"],"register message listeners");if(o==="*"){q.add(f);return}N.has(o)||N.set(o,new Set),(g=N.get(o))==null||g.add(f)}function L(o,f){var g,c;if(o==="*"){q.delete(f);return}(g=N.get(o))==null||g.delete(f),((c=N.get(o))==null?void 0:c.size)===0&&N.delete(o)}async function U(o){var f,g;if((f=e.onReceive)==null||f.call(e,o),!("type"in o))throw Error("Message does not contain a type.");if(o.type==="request"){if(!r.send||!i)throw V(["send","requestHandler"],"handle requests");let{id:c,method:h,params:S}=o,M;try{M={type:"response",id:c,success:!0,payload:await i(h,S)}}catch(T){if(!(T instanceof Error))throw T;M={type:"response",id:c,success:!1,error:T.message}}(g=e.onSend)==null||g.call(e,M),r.send(M);return}if(o.type==="response"){let c=w.get(o.id);c!=null&&clearTimeout(c);let{resolve:h,reject:S}=x.get(o.id)??{};o.success?h==null||h(o.payload):S==null||S(Error(o.error));return}if(o.type==="message"){for(let h of q)h(o.id,o.payload);let c=N.get(o.id);if(!c)return;for(let h of c)h(o.payload);return}throw Error(`Unexpected RPC message type: ${o.type}`)}return{setTransport:s,setRequestHandler:d,request:F,requestProxy:_,send:R,sendProxy:v,addMessageListener:A,removeMessageListener:L,proxy:{send:v,request:_},_setDebugHooks:n}}function fn(t){return dn(t)}var Ne="[transport-id]";function mn(t,e){let{transportId:n}=e;return n==null?t:{[Ne]:n,data:t}}function pn(t,e){let{transportId:n,filter:r}=e,s=r==null?void 0:r();if(n!=null&&s!=null)throw Error("Cannot use both `transportId` and `filter` at the same time");let i=t;if(n){if(t[Ne]!==n)return[!0];i=t.data}return s===!1?[!0]:[!1,i]}function hn(t,e={}){let{transportId:n,filter:r,remotePort:s}=e,i=t,d=s??t,l;return{send(p){d.postMessage(mn(p,{transportId:n}))},registerHandler(p){l=b=>{let x=b.data,[w,C]=pn(x,{transportId:n,filter:()=>r==null?void 0:r(b)});w||p(C)},i.addEventListener("message",l)},unregisterHandler(){l&&i.removeEventListener("message",l)}}}function gn(t,e){return hn(t,e)}function Se(t){return fn({transport:gn(t,{transportId:"marimo-transport"}),maxRequestTime:2e4,_debugHooks:{onSend:e=>{E.debug("[rpc] Parent -> Worker",e)},onReceive:e=>{E.debug("[rpc] Worker -> Parent",e)}}})}const qe=P("Initializing..."),yn=P(t=>{let e=t(mt),n=Object.values(e.cellRuntime);return n.some(r=>!jt(r.output))?!0:n.every(r=>r.status==="idle")});var Pe=Lt(),Me="marimo:file",je=new ct(null);const bn={saveFile(t){je.set(Me,t)},readFile(){return je.get(Me)}};var wn={saveFile(t){z.setCodeForHash((0,Pe.compressToEncodedURIComponent)(t))},readFile(){let t=z.getCodeFromHash()||z.getCodeFromSearchParam();return t?(0,Pe.decompressFromEncodedURIComponent)(t):null}};const vn={saveFile(t){},readFile(){let t=document.querySelector("marimo-code");return t?decodeURIComponent(t.textContent||"").trim():null}};var xn={saveFile(t){},readFile(){if(window.location.hostname!=="marimo.app")return null;let t=new URL("files/wasm-intro.py",document.baseURI);return fetch(t.toString()).then(e=>e.ok?e.text():null).catch(()=>null)}},En={saveFile(t){},readFile(){return["import marimo","app = marimo.App()","","@app.cell","def __():"," return","",'if __name__ == "__main__":'," app.run()"].join(`
2
2
  `)}},Ae=class{constructor(t){this.stores=t}insert(t,e){this.stores.splice(t,0,e)}saveFile(t){this.stores.forEach(e=>e.saveFile(t))}readFile(){for(let t of this.stores){let e=t.readFile();if(e)return e}return null}};const $=new Ae([vn,wn]),ee=new Ae([bn,xn,En]);var Te=class rt{constructor(){a(this,"initialized",new K);a(this,"sendRename",async({filename:e})=>(e===null||(z.setFilename(e),await this.rpc.proxy.request.bridge({functionName:"rename_file",payload:e})),null));a(this,"sendSave",async e=>{if(!this.saveRpc)return E.warn("Save RPC not initialized"),null;await this.saveRpc.saveNotebook(e);let n=await this.readCode();return n.contents&&($.saveFile(n.contents),ee.saveFile(n.contents)),this.rpc.proxy.request.saveNotebook(e).catch(r=>{E.error(r)}),null});a(this,"sendCopy",async()=>{y()});a(this,"sendStdin",async e=>(await this.rpc.proxy.request.bridge({functionName:"put_input",payload:e.text}),null));a(this,"sendPdb",async()=>{y()});a(this,"sendRun",async e=>(await this.rpc.proxy.request.loadPackages(e.codes.join(`
3
3
  `)),await this.putControlRequest({type:"execute-cells",...e}),null));a(this,"sendRunScratchpad",async e=>(await this.rpc.proxy.request.loadPackages(e.code),await this.putControlRequest({type:"execute-scratchpad",...e}),null));a(this,"sendInterrupt",async()=>(this.interruptBuffer!==void 0&&(this.interruptBuffer[0]=2),null));a(this,"sendShutdown",async()=>(window.close(),null));a(this,"sendFormat",async e=>await this.rpc.proxy.request.bridge({functionName:"format",payload:e}));a(this,"sendDeleteCell",async e=>(await this.putControlRequest({type:"delete-cell",...e}),null));a(this,"sendInstallMissingPackages",async e=>(this.putControlRequest({type:"install-packages",...e}),null));a(this,"sendCodeCompletionRequest",async e=>(G.get(dt)||await this.rpc.proxy.request.bridge({functionName:"code_complete",payload:e}),null));a(this,"saveUserConfig",async e=>(await this.rpc.proxy.request.bridge({functionName:"save_user_config",payload:e}),kt.post("/kernel/save_user_config",e,{baseUrl:"/"}).catch(n=>(E.error(n),null))));a(this,"saveAppConfig",async e=>(await this.rpc.proxy.request.bridge({functionName:"save_app_config",payload:e}),null));a(this,"saveCellConfig",async e=>(await this.putControlRequest({type:"update-cell-config",...e}),null));a(this,"sendRestart",async()=>{let e=await this.readCode();return e.contents&&($.saveFile(e.contents),ee.saveFile(e.contents)),Ut(),null});a(this,"readCode",async()=>this.saveRpc?{contents:await this.saveRpc.readNotebook()}:(E.warn("Save RPC not initialized"),{contents:""}));a(this,"readSnippets",async()=>await this.rpc.proxy.request.bridge({functionName:"read_snippets",payload:void 0}));a(this,"openFile",async({path:e})=>{let n=zt({code:null,baseUrl:window.location.origin});return window.open(n,"_blank"),null});a(this,"sendListFiles",async e=>await this.rpc.proxy.request.bridge({functionName:"list_files",payload:e}));a(this,"sendSearchFiles",async e=>await this.rpc.proxy.request.bridge({functionName:"search_files",payload:e}));a(this,"sendComponentValues",async e=>(await this.putControlRequest({type:"update-ui-element",...e,token:we()}),null));a(this,"sendInstantiate",async e=>null);a(this,"sendFunctionRequest",async e=>(await this.putControlRequest({type:"invoke-function",...e}),null));a(this,"sendCreateFileOrFolder",async e=>await this.rpc.proxy.request.bridge({functionName:"create_file_or_directory",payload:e}));a(this,"sendDeleteFileOrFolder",async e=>await this.rpc.proxy.request.bridge({functionName:"delete_file_or_directory",payload:e}));a(this,"sendRenameFileOrFolder",async e=>await this.rpc.proxy.request.bridge({functionName:"move_file_or_directory",payload:e}));a(this,"sendUpdateFile",async e=>await this.rpc.proxy.request.bridge({functionName:"update_file",payload:e}));a(this,"sendFileDetails",async e=>await this.rpc.proxy.request.bridge({functionName:"file_details",payload:e}));a(this,"exportAsHTML",async e=>await this.rpc.proxy.request.bridge({functionName:"export_html",payload:e}));a(this,"exportAsMarkdown",async e=>await this.rpc.proxy.request.bridge({functionName:"export_markdown",payload:e}));a(this,"previewDatasetColumn",async e=>(await this.putControlRequest({type:"preview-dataset-column",...e}),null));a(this,"previewSQLTable",async e=>(await this.putControlRequest({type:"preview-sql-table",...e}),null));a(this,"previewSQLTableList",async e=>(await this.putControlRequest({type:"list-sql-tables",...e}),null));a(this,"previewDataSourceConnection",async e=>(await this.putControlRequest({type:"list-data-source-connection",...e}),null));a(this,"validateSQL",async e=>(await this.putControlRequest({type:"validate-sql",...e}),null));a(this,"sendModelValue",async e=>(await this.putControlRequest({type:"update-widget-model",...e}),null));a(this,"syncCellIds",()=>Promise.resolve(null));a(this,"addPackage",async e=>this.rpc.proxy.request.addPackage(e));a(this,"removePackage",async e=>this.rpc.proxy.request.removePackage(e));a(this,"getPackageList",async()=>await this.rpc.proxy.request.listPackages());a(this,"getDependencyTree",async()=>({tree:{dependencies:[],name:"",tags:[],version:null}}));a(this,"listSecretKeys",async e=>(await this.putControlRequest({type:"list-secret-keys",...e}),null));a(this,"getUsageStats",y);a(this,"openTutorial",y);a(this,"getRecentFiles",y);a(this,"getWorkspaceFiles",y);a(this,"getRunningNotebooks",y);a(this,"shutdownSession",y);a(this,"exportAsPDF",y);a(this,"autoExportAsHTML",y);a(this,"autoExportAsMarkdown",y);a(this,"autoExportAsIPYNB",y);a(this,"updateCellOutputs",y);a(this,"writeSecret",y);a(this,"invokeAiTool",y);a(this,"clearCache",y);a(this,"getCacheInfo",y);_t()&&(this.rpc=Se(new Worker(new URL(""+new URL("worker-CyCdlLVf.js",import.meta.url).href,""+import.meta.url),{type:"module",name:he()})),this.rpc.addMessageListener("ready",()=>{this.startSession()}),this.rpc.addMessageListener("initialized",()=>{this.saveRpc=this.getSaveWorker(),this.setInterruptBuffer(),this.initialized.resolve()}),this.rpc.addMessageListener("initializingMessage",({message:e})=>{G.set(qe,e)}),this.rpc.addMessageListener("initializedError",({error:e})=>{this.initialized.status==="resolved"&&(E.error(e),It({title:"Error initializing",description:e,variant:"danger"})),this.initialized.reject(Error(e))}),this.rpc.addMessageListener("kernelMessage",({message:e})=>{var n;(n=this.messageConsumer)==null||n.call(this,new MessageEvent("message",{data:e}))}))}static get INSTANCE(){let e="_marimo_private_PyodideBridge";return window[e]||(window[e]=new rt),window[e]}getSaveWorker(){return xe()==="read"?(E.debug("Skipping SaveWorker in read-mode"),{readFile:y,readNotebook:y,saveNotebook:y}):Se(new Worker(new URL(""+new URL("save-worker-CtJsIYIM.js",import.meta.url).href,""+import.meta.url),{type:"module",name:he()})).proxy.request}async startSession(){let e=await $.readFile(),n=await ee.readFile(),r=z.getFilename(),s=G.get(Ct),i={},d=new URLSearchParams(window.location.search);for(let l of d.keys()){let p=d.getAll(l);i[l]=p.length===1?p[0]:p}await this.rpc.proxy.request.startSession({queryParameters:i,code:e||n||"",filename:r,userConfig:{...s,runtime:{...s.runtime,auto_instantiate:xe()==="read"?!0:s.runtime.auto_instantiate}}})}setInterruptBuffer(){crossOriginIsolated?(this.interruptBuffer=new Uint8Array(new SharedArrayBuffer(1)),this.rpc.proxy.request.setInterruptBuffer(this.interruptBuffer)):E.warn("Not running in a secure context; interrupts are not available.")}attachMessageConsumer(e){this.messageConsumer=e,this.rpc.proxy.send.consumerReady({})}async putControlRequest(e){await this.rpc.proxy.request.bridge({functionName:"put_control_request",payload:e})}};function Cn(){return Fe.withProducerCallback(t=>{Te.INSTANCE.attachMessageConsumer(t)})}function X(t){return()=>({TYPE:t,is(e){return e.type===t},create(e){return new CustomEvent(t,e)}})}const Ie=X("marimo-value-input")(),Le=X("marimo-value-update")(),Ue=X("marimo-value-ready")(),ze=X("marimo-incoming-message")();function _n(t,e){return Ie.create({bubbles:!0,composed:!0,detail:{value:t,element:e}})}var Oe=class st{static get INSTANCE(){let e="_marimo_private_UIElementRegistry";return window[e]||(window[e]=new st),window[e]}constructor(){this.entries=new Map}has(e){return this.entries.has(e)}set(e,n){if(this.entries.has(e))throw Error(`UIElement ${e} already registered`);this.entries.set(e,{objectId:e,value:n,elements:new Set})}registerInstance(e,n){let r=this.entries.get(e);r===void 0?this.entries.set(e,{objectId:e,value:ut(n,this),elements:new Set([n])}):r.elements.add(n)}removeInstance(e,n){let r=this.entries.get(e);r!=null&&r.elements.has(n)&&r.elements.delete(n)}removeElementsByCell(e){[...this.entries.keys()].filter(n=>n.startsWith(`${e}-`)).forEach(n=>{this.entries.delete(n)})}lookupValue(e){let n=this.entries.get(e);return n===void 0?void 0:n.value}broadcastMessage(e,n,r){let s=this.entries.get(e);s===void 0?E.warn("UIElementRegistry missing entry",e):s.elements.forEach(i=>{i.dispatchEvent(ze.create({bubbles:!1,composed:!0,detail:{objectId:e,message:n,buffers:r}}))})}broadcastValueUpdate(e,n,r){let s=this.entries.get(n);s===void 0?E.warn("UIElementRegistry missing entry",n):(s.value=r,s.elements.forEach(i=>{i!==e&&i.dispatchEvent(Le.create({bubbles:!1,composed:!0,detail:{value:r,element:i}}))}),document.dispatchEvent(Ue.create({bubbles:!0,composed:!0,detail:{objectId:n}})))}};const kn=Oe.INSTANCE,Rn=new Tt("function-call-result",async(t,e)=>{await ye().sendFunctionRequest({functionCallId:t,...e})}),Fn="68px";var Nn="288px";const Sn=t=>t?/^\d+$/.test(t)?`${t}px`:t:Nn,qn=ft({isOpen:!0},(t,e)=>{if(!e)return t;switch(e.type){case"toggle":return{...t,isOpen:e.isOpen??t.isOpen};case"setWidth":return{...t,width:e.width};default:return t}});function te(t,e=[]){let n=[];if(t instanceof DataView)n.push(e);else if(Array.isArray(t))for(let[r,s]of t.entries())n.push(...te(s,[...e,r]));else if(typeof t=="object"&&t)for(let[r,s]of Object.entries(t))n.push(...te(s,[...e,r]));return n}function ne(t){let e=te(t);if(e.length===0)return{state:t,buffers:[],bufferPaths:[]};let n=structuredClone(t),r=[],s=[];for(let i of e){let d=bt(t,i);if(d instanceof DataView){let l=Mt(d);r.push(l),s.push(i),H(n,i,l)}}return{state:n,buffers:r,bufferPaths:s}}function Pn(t){return typeof t=="object"&&!!t&&"state"in t&&"bufferPaths"in t&&"buffers"in t}function Y(t){let{state:e,bufferPaths:n,buffers:r}=t;if(!n||n.length===0)return e;r&&Et(r.length===n.length,"Buffers and buffer paths not the same length");let s=structuredClone(e);for(let[i,d]of n.entries()){let l=r==null?void 0:r[i];if(l==null){E.warn("[anywidget] Could not find buffer at path",d);continue}typeof l=="string"?H(s,d,At(l)):H(s,d,l)}return s}const We=new class{constructor(t=1e4){a(this,"models",new Map);this.timeout=t}get(t){let e=this.models.get(t);return e||(e=new K,this.models.set(t,e),setTimeout(()=>{e.status==="pending"&&(e.reject(Error(`Model not found for key: ${t}`)),this.models.delete(t))},this.timeout)),e.promise}set(t,e){let n=this.models.get(t);n||(n=new K,this.models.set(t,n)),n.resolve(e)}delete(t){this.models.delete(t)}};var De=(j=class{constructor(e,n,r,s){a(this,"ANY_CHANGE_EVENT","change");a(this,"listeners",{});a(this,"widget_manager",{async get_model(e){let n=await j._modelManager.get(e);if(!n)throw Error(`Model not found with id: ${e}. This is likely because the model was not registered.`);return n}});a(this,"emitAnyChange",vt(()=>{var e;(e=this.listeners[this.ANY_CHANGE_EVENT])==null||e.forEach(n=>n())},0));this.data=e,this.onChange=n,this.sendToWidget=r,this.dirtyFields=new Map([...s].map(i=>[i,this.data[i]]))}off(e,n){var r;if(!e){this.listeners={};return}if(!n){this.listeners[e]=new Set;return}(r=this.listeners[e])==null||r.delete(n)}send(e,n,r){let{state:s,bufferPaths:i,buffers:d}=ne(e);this.sendToWidget({content:{state:s,bufferPaths:i},buffers:d}).then(n)}get(e){return this.data[e]}set(e,n){this.data={...this.data,[e]:n},this.dirtyFields.set(e,n),this.emit(`change:${e}`,n),this.emitAnyChange()}save_changes(){if(this.dirtyFields.size===0)return;let e=Object.fromEntries(this.dirtyFields.entries());this.dirtyFields.clear(),this.onChange(e)}updateAndEmitDiffs(e){e!=null&&Object.keys(e).forEach(n=>{let r=n;this.data[r]!==e[r]&&this.set(r,e[r])})}receiveCustomMessage(e,n=[]){var s;let r=He.safeParse(e);if(r.success){let i=r.data;switch(i.method){case"update":this.updateAndEmitDiffs(Y({state:i.state,bufferPaths:i.buffer_paths??[],buffers:n}));break;case"custom":(s=this.listeners["msg:custom"])==null||s.forEach(d=>d(i.content,n));break;case"open":this.updateAndEmitDiffs(Y({state:i.state,bufferPaths:i.buffer_paths??[],buffers:n}));break;case"echo_update":break;default:E.error("[anywidget] Unknown message method",i.method);break}}else E.error("Failed to parse message",r.error),E.error("Message",e)}on(e,n){this.listeners[e]||(this.listeners[e]=new Set),this.listeners[e].add(n)}emit(e,n){this.listeners[e]&&this.listeners[e].forEach(r=>r(n))}},a(j,"_modelManager",We),j),re=me(me(pt([fe(),yt()]))),se=gt(fe(),de()),He=ht("method",[O({method:W("open"),state:se,buffer_paths:re.optional()}),O({method:W("update"),state:se,buffer_paths:re.optional()}),O({method:W("custom"),content:de()}),O({method:W("echo_update"),buffer_paths:re,state:se}),O({method:W("close")})]);function Mn(t){return t==null?!1:He.safeParse(t).success}async function jn({modelId:t,msg:e,buffers:n,modelManager:r}){if(e.method==="echo_update")return;if(e.method==="custom"){(await r.get(t)).receiveCustomMessage(e,n);return}if(e.method==="close"){r.delete(t);return}let{method:s,state:i,buffer_paths:d=[]}=e,l=Y({state:i,bufferPaths:d,buffers:n});if(s==="open"){let p=new De(l,b=>{let{state:x,buffers:w,bufferPaths:C}=ne(b);ye().sendModelValue({modelId:t,message:{state:x,bufferPaths:C},buffers:w})},y,new Set);r.set(t,p);return}if(s==="update"){(await r.get(t)).updateAndEmitDiffs(l);return}wt(s)}const Be=P(null),An=P(null),Ve=P(!1),Tn=P(!1),$e=P(!1);var In=pe();const Xe=t=>{let e=(0,In.c)(8),{onResize:n,startingWidth:r,minWidth:s,maxWidth:i}=t,d=(0,u.useRef)(null),l=(0,u.useRef)(null),p=(0,u.useRef)(null),b,x;e[0]!==i||e[1]!==s||e[2]!==n?(b=()=>{let _=d.current,k=l.current,R=p.current;if(!_||!k&&!R)return;let v=Number.parseInt(window.getComputedStyle(_).width,10),N=0,q=!1,A=null,L=c=>{if(!_||!q||!A)return;let h=c.clientX-N;N=c.clientX,v=A==="left"?v-h:v+h,s&&(v=Math.max(s,v)),i&&(v=Math.min(i,v)),_.style.width=`${v}px`},U=()=>{q&&(n==null||n(v),q=!1,A=null),document.removeEventListener("mousemove",L),document.removeEventListener("mouseup",U)},o=(c,h)=>{c.preventDefault(),q=!0,A=h,N=c.clientX,document.addEventListener("mousemove",L),document.addEventListener("mouseup",U)},f=c=>o(c,"left"),g=c=>o(c,"right");return k&&k.addEventListener("mousedown",f),R&&R.addEventListener("mousedown",g),()=>{k&&k.removeEventListener("mousedown",f),R&&R.removeEventListener("mousedown",g),document.removeEventListener("mousemove",L),document.removeEventListener("mouseup",U)}},x=[s,i,n],e[0]=i,e[1]=s,e[2]=n,e[3]=b,e[4]=x):(b=e[3],x=e[4]),(0,u.useEffect)(b,x);let w;e[5]===Symbol.for("react.memo_cache_sentinel")?(w={left:l,right:p},e[5]=w):w=e[5];let C=r==="contentWidth"?"var(--content-width-medium)":`${r}px`,F;return e[6]===C?F=e[7]:(F={resizableDivRef:d,handleRefs:w,style:{width:C}},e[6]=C,e[7]=F),F};function Ye(t){t||window.dispatchEvent(new Event("resize"))}var Qe=pe(),m=ce(Rt(),1);const Ln=()=>{let t=(0,Qe.c)(16),[e,n]=D(Be),[r,s]=D(Ve),[i,d]=D(Tn),[l,p]=D($e),b;t[0]!==s||t[1]!==n?(b=()=>{n(null),s(!1)},t[0]=s,t[1]=n,t[2]=b):b=t[2];let x=b;if(Z(B.CONTEXT_AWARE_PANEL).length===0||!e||!r)return null;let w;t[3]!==l||t[4]!==i||t[5]!==p||t[6]!==d?(w=()=>(0,m.jsxs)("div",{className:"flex flex-row items-center gap-3",children:[(0,m.jsx)(ve,{content:i?"Unpin panel":"Pin panel",children:(0,m.jsx)(Ee,{size:"xs",onPressedChange:()=>d(!i),pressed:i,"aria-label":i?"Unpin panel":"Pin panel",children:i?(0,m.jsx)(Bt,{className:"w-4 h-4"}):(0,m.jsx)(St,{className:"w-4 h-4"})})}),(0,m.jsx)(ve,{content:l?(0,m.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,m.jsx)("span",{children:"Follow focused table"}),(0,m.jsx)("span",{className:"text-xs text-muted-foreground w-64",children:"The panel updates as cells that output tables are focused. Click to fix to the current cell."})]}):(0,m.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,m.jsx)("span",{children:"Focus on current table"}),(0,m.jsx)("span",{className:"text-xs text-muted-foreground w-64",children:"The panel is focused on the current table. Click to update based on which cell is focused."})]}),children:(0,m.jsx)(Ee,{size:"xs",onPressedChange:()=>p(!l),pressed:l,"aria-label":l?"Follow focused cell":"Fixed",children:(0,m.jsx)(Ht,{className:Nt("w-4 h-4",l&&"text-primary")})})})]}),t[3]=l,t[4]=i,t[5]=p,t[6]=d,t[7]=w):w=t[7];let C=w,F;t[8]!==x||t[9]!==C?(F=()=>(0,m.jsxs)("div",{className:"mt-2 pb-7 mb-4 h-full overflow-auto",children:[(0,m.jsxs)("div",{className:"flex flex-row justify-between items-center mx-2",children:[C(),(0,m.jsx)(Ft,{variant:"linkDestructive",size:"icon",onClick:x,"aria-label":"Close selection panel",children:(0,m.jsx)(Pt,{className:"w-4 h-4"})})]}),(0,m.jsx)(ge,{children:(0,m.jsx)(Re,{name:B.CONTEXT_AWARE_PANEL})})]}),t[8]=x,t[9]=C,t[10]=F):F=t[10];let _=F;if(!i){let v;return t[11]===_?v=t[12]:(v=(0,m.jsx)(zn,{children:_()}),t[11]=_,t[12]=v),v}let k;t[13]===Symbol.for("react.memo_cache_sentinel")?(k=(0,m.jsx)(Ot,{onDragging:Ye,className:"resize-handle border-border z-20 print:hidden border-l"}),t[13]=k):k=t[13];let R;return t[14]===_?R=t[15]:(R=(0,m.jsxs)(m.Fragment,{children:[k,(0,m.jsx)(Wt,{defaultSize:20,minSize:15,maxSize:80,children:_()})]}),t[14]=_,t[15]=R),R},Un=t=>{let e=(0,Qe.c)(2),{children:n}=t,r;return e[0]===n?r=e[1]:(r=(0,m.jsx)(ge,{children:(0,m.jsx)($t,{name:B.CONTEXT_AWARE_PANEL,children:n})}),e[0]=n,e[1]=r),r};var zn=({children:t})=>{let{resizableDivRef:e,handleRefs:n,style:r}=Xe({startingWidth:400,minWidth:300,maxWidth:1500});return(0,m.jsxs)("div",{className:"absolute z-40 right-0 h-full bg-background flex flex-row",children:[(0,m.jsx)("div",{ref:n.left,className:"w-1 h-full cursor-col-resize border-l"}),(0,m.jsx)("div",{ref:e,style:r,children:t})]})};function On(){var t=[...arguments];return(0,u.useMemo)(()=>e=>{t.forEach(n=>n(e))},t)}var Ge=typeof window<"u"&&window.document!==void 0&&window.document.createElement!==void 0;function Q(t){let e=Object.prototype.toString.call(t);return e==="[object Window]"||e==="[object global]"}function ae(t){return"nodeType"in t}function I(t){var e;return t?Q(t)?t:ae(t)?((e=t.ownerDocument)==null?void 0:e.defaultView)??window:window:window}function Ke(t){let{Document:e}=I(t);return t instanceof e}function Je(t){return Q(t)?!1:t instanceof I(t).HTMLElement}function Ze(t){return t instanceof I(t).SVGElement}function Wn(t){return t?Q(t)?t.document:ae(t)?Ke(t)?t:Je(t)||Ze(t)?t.ownerDocument:document:document:document}var ie=Ge?u.useLayoutEffect:u.useEffect;function et(t){let e=(0,u.useRef)(t);return ie(()=>{e.current=t}),(0,u.useCallback)(function(){var n=[...arguments];return e.current==null?void 0:e.current(...n)},[])}function Dn(){let t=(0,u.useRef)(null);return[(0,u.useCallback)((e,n)=>{t.current=setInterval(e,n)},[]),(0,u.useCallback)(()=>{t.current!==null&&(clearInterval(t.current),t.current=null)},[])]}function Hn(t,e){e===void 0&&(e=[t]);let n=(0,u.useRef)(t);return ie(()=>{n.current!==t&&(n.current=t)},e),n}function Bn(t,e){let n=(0,u.useRef)();return(0,u.useMemo)(()=>{let r=t(n.current);return n.current=r,r},[...e])}function Vn(t){let e=et(t),n=(0,u.useRef)(null);return[n,(0,u.useCallback)(r=>{r!==n.current&&(e==null||e(r,n.current)),n.current=r},[])]}function $n(t){let e=(0,u.useRef)();return(0,u.useEffect)(()=>{e.current=t},[t]),e.current}var oe={};function Xn(t,e){return(0,u.useMemo)(()=>{if(e)return e;let n=oe[t]==null?0:oe[t]+1;return oe[t]=n,t+"-"+n},[t,e])}function tt(t){return function(e){return[...arguments].slice(1).reduce((n,r)=>{let s=Object.entries(r);for(let[i,d]of s){let l=n[i];l!=null&&(n[i]=l+t*d)}return n},{...e})}}var Yn=tt(1),Qn=tt(-1);function Gn(t){return"clientX"in t&&"clientY"in t}function Kn(t){if(!t)return!1;let{KeyboardEvent:e}=I(t.target);return e&&t instanceof e}function Jn(t){if(!t)return!1;let{TouchEvent:e}=I(t.target);return e&&t instanceof e}function Zn(t){if(Jn(t)){if(t.touches&&t.touches.length){let{clientX:e,clientY:n}=t.touches[0];return{x:e,y:n}}else if(t.changedTouches&&t.changedTouches.length){let{clientX:e,clientY:n}=t.changedTouches[0];return{x:e,y:n}}}return Gn(t)?{x:t.clientX,y:t.clientY}:null}var le=Object.freeze({Translate:{toString(t){if(!t)return;let{x:e,y:n}=t;return"translate3d("+(e?Math.round(e):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(t){if(!t)return;let{scaleX:e,scaleY:n}=t;return"scaleX("+e+") scaleY("+n+")"}},Transform:{toString(t){if(t)return[le.Translate.toString(t),le.Scale.toString(t)].join(" ")}},Transition:{toString(t){let{property:e,duration:n,easing:r}=t;return e+" "+n+"ms "+r}}}),nt="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function er(t){return t.matches(nt)?t:t.querySelector(nt)}export{yn as $,An as A,Sn as B,Xn as C,Xe as D,Ye as E,Mn as F,ze as G,Rn as H,Y as I,Le as J,Ie as K,Pn as L,We as M,De as N,Ve as O,jn as P,$ as Q,ne as R,$n as S,Un as T,Oe as U,qn as V,kn as W,Te as X,_n as Y,Cn as Z,Dn as _,Zn as a,sn as at,Bn as b,Ke as c,Re as ct,ae as d,qe as et,Ze as f,et as g,On as h,er as i,tn as it,$e as j,Be as k,Je as l,Z as lt,Qn as m,Yn as n,B as nt,Wn as o,an as ot,Q as p,Ue as q,Ge as r,on as rt,I as s,en as st,le as t,Fe as tt,Kn as u,H as ut,ie as v,Ln as w,Vn as x,Hn as y,Fn as z};
@@ -1 +1 @@
1
- import{s as Z}from"./chunk-LvLJmgfZ.js";import{n as C}from"./useEvent-BhXAndur.js";import{t as R}from"./react-Bj1aDYRI.js";import"./react-dom-CSu739Rf.js";import{t as tt}from"./compiler-runtime-B3qBwwSJ.js";import{t as nt}from"./_baseUniq-BP3iN0f3.js";import{t as et}from"./debounce-B3mjKxHe.js";import{r as rt,t as at}from"./tooltip-DxKBXCGp.js";import{a as V,d as j}from"./hotkeys-BHHWjLlp.js";import{n as z}from"./config-D2-Bw6QC.js";import{t as it}from"./jsx-runtime-ZmTK25f3.js";import{r as ot}from"./button-CZ3Cs4qb.js";import{u as lt}from"./toDate-DETS9bBd.js";import"./session-fBtIbMpB.js";import{r as ct}from"./useTheme-CTORu22_.js";import"./Combination-izwufzWe.js";import{t as st}from"./tooltip-C_WgOOcZ.js";import{t as mt}from"./isValid-DpSSOU5z.js";import{n as pt}from"./vega-loader.browser-DXARUlxo.js";import{t as ut}from"./react-vega-CqegDZRQ.js";import"./defaultLocale-JieDVWC_.js";import"./defaultLocale-BLne0bXb.js";import{r as ft,t as dt}from"./alert-BOoN6gJ1.js";import{n as ht}from"./error-banner-Dlrzo_Ay.js";import{n as gt}from"./useAsyncData-BMGLSTg8.js";import{t as yt}from"./formats-CobRswjh.js";import{t as H}from"./useDeepCompareMemoize-ChxLMT9E.js";function vt(t){return t&&t.length?nt(t):[]}var N=vt,kt=tt(),x=Z(R(),1);function bt(t){return t.data&&"url"in t.data&&(t.data.url=z(t.data.url).href),t}const u={arc:"arc",area:"area",bar:"bar",image:"image",line:"line",point:"point",rect:"rect",rule:"rule",text:"text",tick:"tick",trail:"trail",circle:"circle",square:"square",geoshape:"geoshape"};var F=new Set(["boxplot","errorband","errorbar"]);const S={getMarkType(t){let n=typeof t=="string"?t:t.type;if(F.has(n))throw Error("Not supported");return n},isInteractive(t){let n=typeof t=="string"?t:t.type;return!F.has(n)},makeClickable(t){let n=typeof t=="string"?t:t.type;return n in u?typeof t=="string"?{type:t,cursor:"pointer",tooltip:!0}:{...t,type:n,cursor:"pointer",tooltip:!0}:t},getOpacity(t){return typeof t=="string"?null:"opacity"in t&&typeof t.opacity=="number"?t.opacity:null}},y={point(t){return t==null?"select_point":`select_point_${t}`},interval(t){return t==null?"select_interval":`select_interval_${t}`},legendSelection(t){return`legend_selection_${t}`},binColoring(t){return t==null?"bin_coloring":`bin_coloring_${t}`},HIGHLIGHT:"highlight",PAN_ZOOM:"pan_zoom",hasPoint(t){return t.some(n=>n.startsWith("select_point"))},hasInterval(t){return t.some(n=>n.startsWith("select_interval"))},hasLegend(t){return t.some(n=>n.startsWith("legend_selection"))},hasPanZoom(t){return t.some(n=>n.startsWith("pan_zoom"))},isBinColoring(t){return t.startsWith("bin_coloring")}},O={highlight(){return{name:y.HIGHLIGHT,select:{type:"point",on:"mouseover"}}},interval(t,n){return{name:y.interval(n),select:{type:"interval",encodings:W(t),mark:{fill:"#669EFF",fillOpacity:.07,stroke:"#669EFF",strokeOpacity:.4},on:"[mousedown[!event.metaKey], mouseup] > mousemove[!event.metaKey]",translate:"[mousedown[!event.metaKey], mouseup] > mousemove[!event.metaKey]"}}},point(t,n){return{name:y.point(n),select:{type:"point",encodings:W(t),on:"click[!event.metaKey]"}}},binColoring(t){return{name:y.binColoring(t),select:{type:"point",on:"click[!event.metaKey]"}}},legend(t){return{name:y.legendSelection(t),select:{type:"point",fields:[t]},bind:"legend"}},panZoom(){return{name:y.PAN_ZOOM,bind:"scales",select:{type:"interval",on:"[mousedown[event.metaKey], window:mouseup] > window:mousemove!",translate:"[mousedown[event.metaKey], window:mouseup] > window:mousemove!",zoom:"wheel![event.metaKey]"}}}};function W(t){switch(S.getMarkType(t.mark)){case u.image:case u.trail:return;case u.area:case u.arc:return["color"];case u.bar:{let n=wt(t);return n==="horizontal"?["y"]:n==="vertical"?["x"]:void 0}case u.circle:case u.geoshape:case u.line:case u.point:case u.rect:case u.rule:case u.square:case u.text:case u.tick:return["x","y"]}}function P(t){return"params"in t&&t.params&&t.params.length>0?N(t.params.filter(n=>n==null?!1:"select"in n&&n.select!==void 0).map(n=>n.name)):"layer"in t?N(t.layer.flatMap(P)):"vconcat"in t?N(t.vconcat.flatMap(P)):"hconcat"in t?N(t.hconcat.flatMap(P)):[]}function wt(t){var a,r;if(!t||!("mark"in t))return;let n=(a=t.encoding)==null?void 0:a.x,e=(r=t.encoding)==null?void 0:r.y;if(n&&"type"in n&&n.type==="nominal")return"vertical";if(e&&"type"in e&&e.type==="nominal"||n&&"aggregate"in n)return"horizontal";if(e&&"aggregate"in e)return"vertical"}function xt(t){if(!t.encoding)return[];let n=[];for(let e of Object.values(t.encoding))e&&typeof e=="object"&&"bin"in e&&e.bin&&"field"in e&&typeof e.field=="string"&&n.push(e.field);return n}function D(t){if(!t||!("encoding"in t))return[];let{encoding:n}=t;return n?Object.entries(n).flatMap(e=>{let[a,r]=e;return!r||!St.has(a)?[]:"field"in r&&typeof r.field=="string"?[r.field]:"condition"in r&&r.condition&&typeof r.condition=="object"&&"field"in r.condition&&r.condition.field&&typeof r.condition.field=="string"?[r.condition.field]:[]}):[]}var St=new Set(["color","fill","fillOpacity","opacity","shape","size"]);function G(t,n,e,a){let r=e.filter(o=>y.isBinColoring(o)),i={and:(r.length>0?r:e).map(o=>({param:o}))};if(t==="opacity"){let o=S.getOpacity(a)||1;return{...n,opacity:{condition:{test:i,value:o},value:o/5}}}else return n}function At(t){if(!("select"in t)||!t.select)return JSON.stringify(t);let n=t.select;if(typeof n=="string")return JSON.stringify({type:n,bind:t.bind});let e={type:n.type,encodings:"encodings"in n&&n.encodings?[...n.encodings].sort():void 0,fields:"fields"in n&&n.fields?[...n.fields].sort():void 0,bind:t.bind};return JSON.stringify(e)}function $(t){let n=E(t);if(n.length===0)return t;let e=jt(n);return e.length===0?t:{...L(K(t,new Set(e.map(a=>a.name))),e.map(a=>a.name)),params:[...t.params||[],...e]}}function E(t){let n=[];if("vconcat"in t&&Array.isArray(t.vconcat))for(let e of t.vconcat)n.push(...E(e));else if("hconcat"in t&&Array.isArray(t.hconcat))for(let e of t.hconcat)n.push(...E(e));else{if("layer"in t)return[];"mark"in t&&"params"in t&&t.params&&t.params.length>0&&n.push({params:t.params})}return n}function jt(t){if(t.length===0)return[];let n=new Map,e=t.length;for(let{params:r}of t){let i=new Set;for(let o of r){let l=At(o);i.has(l)||(i.add(l),n.has(l)||n.set(l,{count:0,param:o}),n.get(l).count++)}}let a=[];for(let[,{count:r,param:i}]of n)r===e&&a.push(i);return a}function K(t,n){if("vconcat"in t&&Array.isArray(t.vconcat))return{...t,vconcat:t.vconcat.map(e=>K(e,n))};if("hconcat"in t&&Array.isArray(t.hconcat))return{...t,hconcat:t.hconcat.map(e=>K(e,n))};if("mark"in t&&"params"in t&&t.params){let e=t.params,a=[];for(let r of e){if(!r||typeof r!="object"||!("name"in r)){a.push(r);continue}n.has(r.name)||a.push(r)}if(a.length===0){let{params:r,...i}=t;return i}return{...t,params:a}}return t}function L(t,n){return"vconcat"in t&&Array.isArray(t.vconcat)?{...t,vconcat:t.vconcat.map(e=>L(e,n))}:"hconcat"in t&&Array.isArray(t.hconcat)?{...t,hconcat:t.hconcat.map(e=>L(e,n))}:"layer"in t?t:"mark"in t&&S.isInteractive(t.mark)?{...t,mark:S.makeClickable(t.mark),encoding:G("opacity",t.encoding||{},n,t.mark)}:t}function T(t,n){var l,k;let{chartSelection:e=!0,fieldSelection:a=!0}=n;if(!e&&!a)return t;(l=t.params)!=null&&l.some(s=>s.bind==="legend")&&(a=!1);let r=(k=t.params)==null?void 0:k.some(s=>!s.bind);r&&(e=!1);let i="vconcat"in t||"hconcat"in t;if(r&&i)return t;if("vconcat"in t){let s=t.vconcat.map(m=>"mark"in m?T(m,{chartSelection:e,fieldSelection:a}):m);return $({...t,vconcat:s})}if("hconcat"in t){let s=t.hconcat.map(m=>"mark"in m?T(m,{chartSelection:e,fieldSelection:a}):m);return $({...t,hconcat:s})}if("layer"in t){let s=t.params&&t.params.length>0,m=a!==!1&&!s,v=[];if(m){let p=t.layer.flatMap(f=>"mark"in f?D(f):[]);v=[...new Set(p)],Array.isArray(a)&&(v=v.filter(f=>a.includes(f)))}let w=t.layer.map((p,f)=>{if(!("mark"in p))return p;let h=p;if(f===0&&v.length>0){let _=v.map(M=>O.legend(M));h={...h,params:[...h.params||[],..._]}}return h=q(h,e,f),h=J(h),f===0&&(h=B(h)),h});return{...t,layer:w}}if(!("mark"in t)||!S.isInteractive(t.mark))return t;let o=t;return o=Ot(o,a),o=q(o,e,void 0),o=J(o),o=B(o),o}function Ot(t,n){if(n===!1)return t;let e=D(t);Array.isArray(n)&&(e=e.filter(i=>n.includes(i)));let a=e.map(i=>O.legend(i)),r=[...t.params||[],...a];return{...t,params:r}}function q(t,n,e){if(n===!1)return t;let a;try{a=S.getMarkType(t.mark)}catch{return t}if(a==="geoshape")return t;let r=xt(t),i=n===!0?r.length>0?["point"]:_t(a):[n];if(!i||i.length===0)return t;let o=i.map(k=>k==="interval"?O.interval(t,e):O.point(t,e)),l=[...t.params||[],...o];return r.length>0&&i.includes("point")&&l.push(O.binColoring(e)),{...t,params:l}}function B(t){let n;try{n=S.getMarkType(t.mark)}catch{}if(n==="geoshape")return t;let e=t.params||[];return e.some(a=>a.bind==="scales")?t:{...t,params:[...e,O.panZoom()]}}function J(t){let n="encoding"in t?t.encoding:void 0,e=t.params||[],a=e.map(r=>r.name);return e.length===0||!S.isInteractive(t.mark)?t:{...t,mark:S.makeClickable(t.mark),encoding:G("opacity",n||{},a,t.mark)}}function _t(t){switch(t){case"arc":case"area":return["point"];case"text":case"bar":return["point","interval"];case"line":return;default:return["point","interval"]}}async function Mt(t){if(!t)return t;let n="datasets"in t?{...t.datasets}:{},e=async r=>{if(!r)return r;if("layer"in r){let l=await Promise.all(r.layer.map(e));r={...r,layer:l}}if("hconcat"in r){let l=await Promise.all(r.hconcat.map(e));r={...r,hconcat:l}}if("vconcat"in r){let l=await Promise.all(r.vconcat.map(e));r={...r,vconcat:l}}if("spec"in r&&(r={...r,spec:await e(r.spec)}),!r.data||!("url"in r.data))return r;let i;try{i=z(r.data.url)}catch{return r}let o=await rt(i.href,r.data.format);return n[i.pathname]=o,{...r,data:{name:i.pathname}}},a=await e(t);return Object.keys(n).length===0?a:{...a,datasets:n}}var d=Z(it(),1);pt("arrow",yt);var Nt=t=>{let n=(0,kt.c)(12),{value:e,setValue:a,chartSelection:r,fieldSelection:i,spec:o,embedOptions:l}=t,k,s;n[0]===o?(k=n[1],s=n[2]):(k=async()=>Mt(o),s=[o],n[0]=o,n[1]=k,n[2]=s);let{data:m,error:v}=gt(k,s);if(v){let p;return n[3]===v?p=n[4]:(p=(0,d.jsx)(ht,{error:v}),n[3]=v,n[4]=p),p}if(!m)return null;let w;return n[5]!==r||n[6]!==l||n[7]!==i||n[8]!==m||n[9]!==a||n[10]!==e?(w=(0,d.jsx)(Pt,{value:e,setValue:a,chartSelection:r,fieldSelection:i,spec:m,embedOptions:l}),n[5]=r,n[6]=l,n[7]=i,n[8]=m,n[9]=a,n[10]=e,n[11]=w):w=n[11],w},Pt=({value:t,setValue:n,chartSelection:e,fieldSelection:a,spec:r,embedOptions:i})=>{let{theme:o}=ct(),l=(0,x.useRef)(null),k=(0,x.useRef)(void 0),[s,m]=(0,x.useState)(),v=(0,x.useMemo)(()=>i&&"actions"in i?i.actions:{source:!1,compiled:!1},[i]),w=H(r),p=(0,x.useMemo)(()=>T(bt(w),{chartSelection:e,fieldSelection:a}),[w,e,a]),f=(0,x.useMemo)(()=>P(p),[p]),h=C(c=>{n({...t,...c})}),_=(0,x.useMemo)(()=>et((c,g)=>{j.debug("[Vega signal]",c,g);let b=V.mapValues(g,Ct);b=V.mapValues(b,It),h({[c]:b})},100),[h]),M=H(f),I=(0,x.useMemo)(()=>M.reduce((c,g)=>(y.PAN_ZOOM===g||y.isBinColoring(g)||c.push({signalName:g,handler:(b,Y)=>_(b,Y)}),c),[]),[M,_]),Q=C(c=>{j.error(c),j.debug(p),m(c)}),U=C(c=>{j.debug("[Vega view] created",c),k.current=c,m(void 0)}),X=()=>{let c=[];return y.hasPoint(f)&&c.push(["Point selection","click to select a point; hold shift for multi-select"]),y.hasInterval(f)&&c.push(["Interval selection","click and drag to select an interval"]),y.hasLegend(f)&&c.push(["Legend selection","click to select a legend item; hold shift for multi-select"]),y.hasPanZoom(f)&&c.push(["Pan","hold the meta key and drag"],["Zoom","hold the meta key and scroll"]),c.length===0?null:(0,d.jsx)(st,{delayDuration:300,side:"left",content:(0,d.jsx)("div",{className:"text-xs flex flex-col",children:c.map((g,b)=>(0,d.jsxs)("div",{children:[(0,d.jsxs)("span",{className:"font-bold tracking-wide",children:[g[0],":"]})," ",g[1]]},b))}),children:(0,d.jsx)(lt,{className:"absolute bottom-1 right-0 m-2 h-4 w-4 cursor-help text-muted-foreground hover:text-foreground"})})},A=ut({ref:l,spec:p,options:{theme:o==="dark"?"dark":void 0,actions:v,mode:"vega-lite",tooltip:at.call,renderer:"canvas"},onError:Q,onEmbed:U});return(0,x.useEffect)(()=>(I.forEach(({signalName:c,handler:g})=>{try{A==null||A.view.addSignalListener(c,g)}catch(b){j.error(b)}}),()=>{I.forEach(({signalName:c,handler:g})=>{try{A==null||A.view.removeSignalListener(c,g)}catch(b){j.error(b)}})}),[A,I]),(0,d.jsxs)(d.Fragment,{children:[s&&(0,d.jsxs)(dt,{variant:"destructive",children:[(0,d.jsx)(ft,{children:s.message}),(0,d.jsx)("div",{className:"text-md",children:s.stack})]}),(0,d.jsxs)("div",{className:"relative",onPointerDown:ot.stopPropagation(),children:[(0,d.jsx)("div",{ref:l}),X()]})]})};function It(t){return t instanceof Set?[...t]:t}function Ct(t){return Array.isArray(t)?t.map(n=>n instanceof Date&&mt(n)?new Date(n).getTime():n):t}var Et=Nt;export{Et as default};
1
+ import{s as Z}from"./chunk-LvLJmgfZ.js";import{n as C}from"./useEvent-BhXAndur.js";import{t as R}from"./react-Bj1aDYRI.js";import"./react-dom-CSu739Rf.js";import{t as tt}from"./compiler-runtime-B3qBwwSJ.js";import{t as nt}from"./_baseUniq-BP3iN0f3.js";import{t as et}from"./debounce-B3mjKxHe.js";import{r as rt,t as at}from"./tooltip-DqsDDLgU.js";import{a as V,d as j}from"./hotkeys-BHHWjLlp.js";import{n as z}from"./config-D2-Bw6QC.js";import{t as it}from"./jsx-runtime-ZmTK25f3.js";import{r as ot}from"./button-CZ3Cs4qb.js";import{u as lt}from"./toDate-DETS9bBd.js";import"./session-fBtIbMpB.js";import{r as ct}from"./useTheme-CTORu22_.js";import"./Combination-izwufzWe.js";import{t as st}from"./tooltip-C_WgOOcZ.js";import{t as mt}from"./isValid-DpSSOU5z.js";import{n as pt}from"./vega-loader.browser-BegSZk0G.js";import{t as ut}from"./react-vega-BEiHA2e9.js";import"./defaultLocale-YteS-k_t.js";import"./defaultLocale-B6z1Qyqt.js";import{r as ft,t as dt}from"./alert-Cx8eFRUM.js";import{n as ht}from"./error-banner-w4pz2qUB.js";import{n as gt}from"./useAsyncData-CgmD3hjw.js";import{t as yt}from"./formats-DGZwRUPy.js";import{t as H}from"./useDeepCompareMemoize-CFtQU7An.js";function vt(t){return t&&t.length?nt(t):[]}var N=vt,kt=tt(),x=Z(R(),1);function bt(t){return t.data&&"url"in t.data&&(t.data.url=z(t.data.url).href),t}const u={arc:"arc",area:"area",bar:"bar",image:"image",line:"line",point:"point",rect:"rect",rule:"rule",text:"text",tick:"tick",trail:"trail",circle:"circle",square:"square",geoshape:"geoshape"};var F=new Set(["boxplot","errorband","errorbar"]);const S={getMarkType(t){let n=typeof t=="string"?t:t.type;if(F.has(n))throw Error("Not supported");return n},isInteractive(t){let n=typeof t=="string"?t:t.type;return!F.has(n)},makeClickable(t){let n=typeof t=="string"?t:t.type;return n in u?typeof t=="string"?{type:t,cursor:"pointer",tooltip:!0}:{...t,type:n,cursor:"pointer",tooltip:!0}:t},getOpacity(t){return typeof t=="string"?null:"opacity"in t&&typeof t.opacity=="number"?t.opacity:null}},y={point(t){return t==null?"select_point":`select_point_${t}`},interval(t){return t==null?"select_interval":`select_interval_${t}`},legendSelection(t){return`legend_selection_${t}`},binColoring(t){return t==null?"bin_coloring":`bin_coloring_${t}`},HIGHLIGHT:"highlight",PAN_ZOOM:"pan_zoom",hasPoint(t){return t.some(n=>n.startsWith("select_point"))},hasInterval(t){return t.some(n=>n.startsWith("select_interval"))},hasLegend(t){return t.some(n=>n.startsWith("legend_selection"))},hasPanZoom(t){return t.some(n=>n.startsWith("pan_zoom"))},isBinColoring(t){return t.startsWith("bin_coloring")}},O={highlight(){return{name:y.HIGHLIGHT,select:{type:"point",on:"mouseover"}}},interval(t,n){return{name:y.interval(n),select:{type:"interval",encodings:W(t),mark:{fill:"#669EFF",fillOpacity:.07,stroke:"#669EFF",strokeOpacity:.4},on:"[mousedown[!event.metaKey], mouseup] > mousemove[!event.metaKey]",translate:"[mousedown[!event.metaKey], mouseup] > mousemove[!event.metaKey]"}}},point(t,n){return{name:y.point(n),select:{type:"point",encodings:W(t),on:"click[!event.metaKey]"}}},binColoring(t){return{name:y.binColoring(t),select:{type:"point",on:"click[!event.metaKey]"}}},legend(t){return{name:y.legendSelection(t),select:{type:"point",fields:[t]},bind:"legend"}},panZoom(){return{name:y.PAN_ZOOM,bind:"scales",select:{type:"interval",on:"[mousedown[event.metaKey], window:mouseup] > window:mousemove!",translate:"[mousedown[event.metaKey], window:mouseup] > window:mousemove!",zoom:"wheel![event.metaKey]"}}}};function W(t){switch(S.getMarkType(t.mark)){case u.image:case u.trail:return;case u.area:case u.arc:return["color"];case u.bar:{let n=wt(t);return n==="horizontal"?["y"]:n==="vertical"?["x"]:void 0}case u.circle:case u.geoshape:case u.line:case u.point:case u.rect:case u.rule:case u.square:case u.text:case u.tick:return["x","y"]}}function P(t){return"params"in t&&t.params&&t.params.length>0?N(t.params.filter(n=>n==null?!1:"select"in n&&n.select!==void 0).map(n=>n.name)):"layer"in t?N(t.layer.flatMap(P)):"vconcat"in t?N(t.vconcat.flatMap(P)):"hconcat"in t?N(t.hconcat.flatMap(P)):[]}function wt(t){var a,r;if(!t||!("mark"in t))return;let n=(a=t.encoding)==null?void 0:a.x,e=(r=t.encoding)==null?void 0:r.y;if(n&&"type"in n&&n.type==="nominal")return"vertical";if(e&&"type"in e&&e.type==="nominal"||n&&"aggregate"in n)return"horizontal";if(e&&"aggregate"in e)return"vertical"}function xt(t){if(!t.encoding)return[];let n=[];for(let e of Object.values(t.encoding))e&&typeof e=="object"&&"bin"in e&&e.bin&&"field"in e&&typeof e.field=="string"&&n.push(e.field);return n}function D(t){if(!t||!("encoding"in t))return[];let{encoding:n}=t;return n?Object.entries(n).flatMap(e=>{let[a,r]=e;return!r||!St.has(a)?[]:"field"in r&&typeof r.field=="string"?[r.field]:"condition"in r&&r.condition&&typeof r.condition=="object"&&"field"in r.condition&&r.condition.field&&typeof r.condition.field=="string"?[r.condition.field]:[]}):[]}var St=new Set(["color","fill","fillOpacity","opacity","shape","size"]);function G(t,n,e,a){let r=e.filter(o=>y.isBinColoring(o)),i={and:(r.length>0?r:e).map(o=>({param:o}))};if(t==="opacity"){let o=S.getOpacity(a)||1;return{...n,opacity:{condition:{test:i,value:o},value:o/5}}}else return n}function At(t){if(!("select"in t)||!t.select)return JSON.stringify(t);let n=t.select;if(typeof n=="string")return JSON.stringify({type:n,bind:t.bind});let e={type:n.type,encodings:"encodings"in n&&n.encodings?[...n.encodings].sort():void 0,fields:"fields"in n&&n.fields?[...n.fields].sort():void 0,bind:t.bind};return JSON.stringify(e)}function $(t){let n=E(t);if(n.length===0)return t;let e=jt(n);return e.length===0?t:{...L(K(t,new Set(e.map(a=>a.name))),e.map(a=>a.name)),params:[...t.params||[],...e]}}function E(t){let n=[];if("vconcat"in t&&Array.isArray(t.vconcat))for(let e of t.vconcat)n.push(...E(e));else if("hconcat"in t&&Array.isArray(t.hconcat))for(let e of t.hconcat)n.push(...E(e));else{if("layer"in t)return[];"mark"in t&&"params"in t&&t.params&&t.params.length>0&&n.push({params:t.params})}return n}function jt(t){if(t.length===0)return[];let n=new Map,e=t.length;for(let{params:r}of t){let i=new Set;for(let o of r){let l=At(o);i.has(l)||(i.add(l),n.has(l)||n.set(l,{count:0,param:o}),n.get(l).count++)}}let a=[];for(let[,{count:r,param:i}]of n)r===e&&a.push(i);return a}function K(t,n){if("vconcat"in t&&Array.isArray(t.vconcat))return{...t,vconcat:t.vconcat.map(e=>K(e,n))};if("hconcat"in t&&Array.isArray(t.hconcat))return{...t,hconcat:t.hconcat.map(e=>K(e,n))};if("mark"in t&&"params"in t&&t.params){let e=t.params,a=[];for(let r of e){if(!r||typeof r!="object"||!("name"in r)){a.push(r);continue}n.has(r.name)||a.push(r)}if(a.length===0){let{params:r,...i}=t;return i}return{...t,params:a}}return t}function L(t,n){return"vconcat"in t&&Array.isArray(t.vconcat)?{...t,vconcat:t.vconcat.map(e=>L(e,n))}:"hconcat"in t&&Array.isArray(t.hconcat)?{...t,hconcat:t.hconcat.map(e=>L(e,n))}:"layer"in t?t:"mark"in t&&S.isInteractive(t.mark)?{...t,mark:S.makeClickable(t.mark),encoding:G("opacity",t.encoding||{},n,t.mark)}:t}function T(t,n){var l,k;let{chartSelection:e=!0,fieldSelection:a=!0}=n;if(!e&&!a)return t;(l=t.params)!=null&&l.some(s=>s.bind==="legend")&&(a=!1);let r=(k=t.params)==null?void 0:k.some(s=>!s.bind);r&&(e=!1);let i="vconcat"in t||"hconcat"in t;if(r&&i)return t;if("vconcat"in t){let s=t.vconcat.map(m=>"mark"in m?T(m,{chartSelection:e,fieldSelection:a}):m);return $({...t,vconcat:s})}if("hconcat"in t){let s=t.hconcat.map(m=>"mark"in m?T(m,{chartSelection:e,fieldSelection:a}):m);return $({...t,hconcat:s})}if("layer"in t){let s=t.params&&t.params.length>0,m=a!==!1&&!s,v=[];if(m){let p=t.layer.flatMap(f=>"mark"in f?D(f):[]);v=[...new Set(p)],Array.isArray(a)&&(v=v.filter(f=>a.includes(f)))}let w=t.layer.map((p,f)=>{if(!("mark"in p))return p;let h=p;if(f===0&&v.length>0){let _=v.map(M=>O.legend(M));h={...h,params:[...h.params||[],..._]}}return h=q(h,e,f),h=J(h),f===0&&(h=B(h)),h});return{...t,layer:w}}if(!("mark"in t)||!S.isInteractive(t.mark))return t;let o=t;return o=Ot(o,a),o=q(o,e,void 0),o=J(o),o=B(o),o}function Ot(t,n){if(n===!1)return t;let e=D(t);Array.isArray(n)&&(e=e.filter(i=>n.includes(i)));let a=e.map(i=>O.legend(i)),r=[...t.params||[],...a];return{...t,params:r}}function q(t,n,e){if(n===!1)return t;let a;try{a=S.getMarkType(t.mark)}catch{return t}if(a==="geoshape")return t;let r=xt(t),i=n===!0?r.length>0?["point"]:_t(a):[n];if(!i||i.length===0)return t;let o=i.map(k=>k==="interval"?O.interval(t,e):O.point(t,e)),l=[...t.params||[],...o];return r.length>0&&i.includes("point")&&l.push(O.binColoring(e)),{...t,params:l}}function B(t){let n;try{n=S.getMarkType(t.mark)}catch{}if(n==="geoshape")return t;let e=t.params||[];return e.some(a=>a.bind==="scales")?t:{...t,params:[...e,O.panZoom()]}}function J(t){let n="encoding"in t?t.encoding:void 0,e=t.params||[],a=e.map(r=>r.name);return e.length===0||!S.isInteractive(t.mark)?t:{...t,mark:S.makeClickable(t.mark),encoding:G("opacity",n||{},a,t.mark)}}function _t(t){switch(t){case"arc":case"area":return["point"];case"text":case"bar":return["point","interval"];case"line":return;default:return["point","interval"]}}async function Mt(t){if(!t)return t;let n="datasets"in t?{...t.datasets}:{},e=async r=>{if(!r)return r;if("layer"in r){let l=await Promise.all(r.layer.map(e));r={...r,layer:l}}if("hconcat"in r){let l=await Promise.all(r.hconcat.map(e));r={...r,hconcat:l}}if("vconcat"in r){let l=await Promise.all(r.vconcat.map(e));r={...r,vconcat:l}}if("spec"in r&&(r={...r,spec:await e(r.spec)}),!r.data||!("url"in r.data))return r;let i;try{i=z(r.data.url)}catch{return r}let o=await rt(i.href,r.data.format);return n[i.pathname]=o,{...r,data:{name:i.pathname}}},a=await e(t);return Object.keys(n).length===0?a:{...a,datasets:n}}var d=Z(it(),1);pt("arrow",yt);var Nt=t=>{let n=(0,kt.c)(12),{value:e,setValue:a,chartSelection:r,fieldSelection:i,spec:o,embedOptions:l}=t,k,s;n[0]===o?(k=n[1],s=n[2]):(k=async()=>Mt(o),s=[o],n[0]=o,n[1]=k,n[2]=s);let{data:m,error:v}=gt(k,s);if(v){let p;return n[3]===v?p=n[4]:(p=(0,d.jsx)(ht,{error:v}),n[3]=v,n[4]=p),p}if(!m)return null;let w;return n[5]!==r||n[6]!==l||n[7]!==i||n[8]!==m||n[9]!==a||n[10]!==e?(w=(0,d.jsx)(Pt,{value:e,setValue:a,chartSelection:r,fieldSelection:i,spec:m,embedOptions:l}),n[5]=r,n[6]=l,n[7]=i,n[8]=m,n[9]=a,n[10]=e,n[11]=w):w=n[11],w},Pt=({value:t,setValue:n,chartSelection:e,fieldSelection:a,spec:r,embedOptions:i})=>{let{theme:o}=ct(),l=(0,x.useRef)(null),k=(0,x.useRef)(void 0),[s,m]=(0,x.useState)(),v=(0,x.useMemo)(()=>i&&"actions"in i?i.actions:{source:!1,compiled:!1},[i]),w=H(r),p=(0,x.useMemo)(()=>T(bt(w),{chartSelection:e,fieldSelection:a}),[w,e,a]),f=(0,x.useMemo)(()=>P(p),[p]),h=C(c=>{n({...t,...c})}),_=(0,x.useMemo)(()=>et((c,g)=>{j.debug("[Vega signal]",c,g);let b=V.mapValues(g,Ct);b=V.mapValues(b,It),h({[c]:b})},100),[h]),M=H(f),I=(0,x.useMemo)(()=>M.reduce((c,g)=>(y.PAN_ZOOM===g||y.isBinColoring(g)||c.push({signalName:g,handler:(b,Y)=>_(b,Y)}),c),[]),[M,_]),Q=C(c=>{j.error(c),j.debug(p),m(c)}),U=C(c=>{j.debug("[Vega view] created",c),k.current=c,m(void 0)}),X=()=>{let c=[];return y.hasPoint(f)&&c.push(["Point selection","click to select a point; hold shift for multi-select"]),y.hasInterval(f)&&c.push(["Interval selection","click and drag to select an interval"]),y.hasLegend(f)&&c.push(["Legend selection","click to select a legend item; hold shift for multi-select"]),y.hasPanZoom(f)&&c.push(["Pan","hold the meta key and drag"],["Zoom","hold the meta key and scroll"]),c.length===0?null:(0,d.jsx)(st,{delayDuration:300,side:"left",content:(0,d.jsx)("div",{className:"text-xs flex flex-col",children:c.map((g,b)=>(0,d.jsxs)("div",{children:[(0,d.jsxs)("span",{className:"font-bold tracking-wide",children:[g[0],":"]})," ",g[1]]},b))}),children:(0,d.jsx)(lt,{className:"absolute bottom-1 right-0 m-2 h-4 w-4 cursor-help text-muted-foreground hover:text-foreground"})})},A=ut({ref:l,spec:p,options:{theme:o==="dark"?"dark":void 0,actions:v,mode:"vega-lite",tooltip:at.call,renderer:"canvas"},onError:Q,onEmbed:U});return(0,x.useEffect)(()=>(I.forEach(({signalName:c,handler:g})=>{try{A==null||A.view.addSignalListener(c,g)}catch(b){j.error(b)}}),()=>{I.forEach(({signalName:c,handler:g})=>{try{A==null||A.view.removeSignalListener(c,g)}catch(b){j.error(b)}})}),[A,I]),(0,d.jsxs)(d.Fragment,{children:[s&&(0,d.jsxs)(dt,{variant:"destructive",children:[(0,d.jsx)(ft,{children:s.message}),(0,d.jsx)("div",{className:"text-md",children:s.stack})]}),(0,d.jsxs)("div",{className:"relative",onPointerDown:ot.stopPropagation(),children:[(0,d.jsx)("div",{ref:l}),X()]})]})};function It(t){return t instanceof Set?[...t]:t}function Ct(t){return Array.isArray(t)?t.map(n=>n instanceof Date&&mt(n)?new Date(n).getTime():n):t}var Et=Nt;export{Et as default};
@@ -1,4 +1,4 @@
1
- import{a as Tt,n as _n,r as Wn,s as Jn,t as qn}from"./precisionRound-CU2C3Vxx.js";import{i as _t,n as Hn,r as Gn,t as Zn}from"./defaultLocale-JieDVWC_.js";import{C as Vn,N as Wt,S as Qn,T as Jt,_ as qt,a as Kn,b as it,c as Ht,i as Xn,l as Gt,n as tr,o as nr,p as Zt,r as rr,s as er,t as ar,v as st,w as ur,x as or}from"./defaultLocale-BLne0bXb.js";function E(t,n,r){return t.fields=n||[],t.fname=r,t}function ir(t){return t==null?null:t.fname}function Vt(t){return t==null?null:t.fields}function Qt(t){return t.length===1?sr(t[0]):lr(t)}var sr=t=>function(n){return n[t]},lr=t=>{let n=t.length;return function(r){for(let e=0;e<n;++e)r=r[t[e]];return r}};function v(t){throw Error(t)}function wt(t){let n=[],r=t.length,e=null,a=0,u="",o,i,c;t+="";function l(){n.push(u+t.substring(o,i)),u="",o=i+1}for(o=i=0;i<r;++i)if(c=t[i],c==="\\")u+=t.substring(o,i++),o=i;else if(c===e)l(),e=null,a=-1;else{if(e)continue;o===a&&c==='"'||o===a&&c==="'"?(o=i+1,e=c):c==="."&&!a?i>o?l():o=i+1:c==="["?(i>o&&l(),a=o=i+1):c==="]"&&(a||v("Access path missing open bracket: "+t),a>0&&l(),a=0,o=i+1)}return a&&v("Access path missing closing bracket: "+t),e&&v("Access path missing closing quote: "+t),i>o&&(i++,l()),n}function lt(t,n,r){let e=wt(t);return t=e.length===1?e[0]:t,E((r&&r.get||Qt)(e),[t],n||t)}var cr=lt("id"),W=E(t=>t,[],"identity"),I=E(()=>0,[],"zero"),Kt=E(()=>1,[],"one"),fr=E(()=>!0,[],"true"),hr=E(()=>!1,[],"false"),gr=new Set([...Object.getOwnPropertyNames(Object.prototype).filter(t=>typeof Object.prototype[t]=="function"),"__proto__"]);function pr(t,n,r){let e=[n].concat([].slice.call(r));console[t].apply(console,e)}var mr=0,dr=1,yr=2,vr=3,br=4;function Mr(t,n,r=pr){let e=t||0;return{level(a){return arguments.length?(e=+a,this):e},error(){return e>=1&&r(n||"error","ERROR",arguments),this},warn(){return e>=2&&r(n||"warn","WARN",arguments),this},info(){return e>=3&&r(n||"log","INFO",arguments),this},debug(){return e>=4&&r(n||"log","DEBUG",arguments),this}}}var J=Array.isArray;function $(t){return t===Object(t)}var Xt=t=>t!=="__proto__";function Cr(...t){return t.reduce((n,r)=>{for(let e in r)if(e==="signals")n.signals=Tr(n.signals,r.signals);else{let a=e==="legend"?{layout:1}:e==="style"?!0:null;jt(n,e,r[e],a)}return n},{})}function jt(t,n,r,e){if(!Xt(n))return;let a,u;if($(r)&&!J(r))for(a in u=$(t[n])?t[n]:t[n]={},r)e&&(e===!0||e[a])?jt(u,a,r[a]):Xt(a)&&(u[a]=r[a]);else t[n]=r}function Tr(t,n){if(t==null)return n;let r={},e=[];function a(u){r[u.name]||(r[u.name]=1,e.push(u))}return n.forEach(a),t.forEach(a),e}function P(t){return t[t.length-1]}function q(t){return t==null||t===""?null:+t}var tn=t=>n=>t*Math.exp(n),nn=t=>n=>Math.log(t*n),rn=t=>n=>Math.sign(n)*Math.log1p(Math.abs(n/t)),en=t=>n=>Math.sign(n)*Math.expm1(Math.abs(n))*t,ct=t=>n=>n<0?-((-n)**+t):n**+t;function ft(t,n,r,e){let a=r(t[0]),u=r(P(t)),o=(u-a)*n;return[e(a-o),e(u-o)]}function wr(t,n){return ft(t,n,q,W)}function jr(t,n){var r=Math.sign(t[0]);return ft(t,n,nn(r),tn(r))}function Dr(t,n,r){return ft(t,n,ct(r),ct(1/r))}function kr(t,n,r){return ft(t,n,rn(r),en(r))}function ht(t,n,r,e,a){let u=e(t[0]),o=e(P(t)),i=n==null?(u+o)/2:e(n);return[a(i+(u-i)*r),a(i+(o-i)*r)]}function Or(t,n,r){return ht(t,n,r,q,W)}function Ur(t,n,r){let e=Math.sign(t[0]);return ht(t,n,r,nn(e),tn(e))}function xr(t,n,r,e){return ht(t,n,r,ct(e),ct(1/e))}function Nr(t,n,r,e){return ht(t,n,r,rn(e),en(e))}function Ar(t){return 1+~~(new Date(t).getMonth()/3)}function Er(t){return 1+~~(new Date(t).getUTCMonth()/3)}function R(t){return t==null?[]:J(t)?t:[t]}function Sr(t,n,r){let e=t[0],a=t[1],u;return a<e&&(u=a,a=e,e=u),u=a-e,u>=r-n?[n,r]:[e=Math.min(Math.max(e,n),r-u),e+u]}function B(t){return typeof t=="function"}var Fr="descending";function Pr(t,n,r){r||(r={}),n=R(n)||[];let e=[],a=[],u={},o=r.comparator||zr;return R(t).forEach((i,c)=>{i!=null&&(e.push(n[c]===Fr?-1:1),a.push(i=B(i)?i:lt(i,null,r)),(Vt(i)||[]).forEach(l=>u[l]=1))}),a.length===0?null:E(o(a,e),Object.keys(u))}var Dt=(t,n)=>(t<n||t==null)&&n!=null?-1:(t>n||n==null)&&t!=null?1:(n=n instanceof Date?+n:n,(t=t instanceof Date?+t:t)!==t&&n===n?-1:n!==n&&t===t?1:0),zr=(t,n)=>t.length===1?Yr(t[0],n[0]):Ir(t,n,t.length),Yr=(t,n)=>function(r,e){return Dt(t(r),t(e))*n},Ir=(t,n,r)=>(n.push(0),function(e,a){let u,o=0,i=-1;for(;o===0&&++i<r;)u=t[i],o=Dt(u(e),u(a));return o*n[i]});function an(t){return B(t)?t:()=>t}function $r(t,n){let r;return e=>{r&&clearTimeout(r),r=setTimeout(()=>(n(e),r=null),t)}}function z(t){for(let n,r,e=1,a=arguments.length;e<a;++e)for(r in n=arguments[e],n)t[r]=n[r];return t}function Rr(t,n){let r=0,e,a,u,o;if(t&&(e=t.length))if(n==null){for(a=t[r];r<e&&(a==null||a!==a);a=t[++r]);for(u=o=a;r<e;++r)a=t[r],a!=null&&(a<u&&(u=a),a>o&&(o=a))}else{for(a=n(t[r]);r<e&&(a==null||a!==a);a=n(t[++r]));for(u=o=a;r<e;++r)a=n(t[r]),a!=null&&(a<u&&(u=a),a>o&&(o=a))}return[u,o]}function Br(t,n){let r=t.length,e=-1,a,u,o,i,c;if(n==null){for(;++e<r;)if(u=t[e],u!=null&&u>=u){a=o=u;break}if(e===r)return[-1,-1];for(i=c=e;++e<r;)u=t[e],u!=null&&(a>u&&(a=u,i=e),o<u&&(o=u,c=e))}else{for(;++e<r;)if(u=n(t[e],e,t),u!=null&&u>=u){a=o=u;break}if(e===r)return[-1,-1];for(i=c=e;++e<r;)u=n(t[e],e,t),u!=null&&(a>u&&(a=u,i=e),o<u&&(o=u,c=e))}return[i,c]}function N(t,n){return Object.hasOwn(t,n)}var gt={};function Lr(t){let n={},r;function e(u){return N(n,u)&&n[u]!==gt}let a={size:0,empty:0,object:n,has:e,get(u){return e(u)?n[u]:void 0},set(u,o){return e(u)||(++a.size,n[u]===gt&&--a.empty),n[u]=o,this},delete(u){return e(u)&&(--a.size,++a.empty,n[u]=gt),this},clear(){a.size=a.empty=0,a.object=n={}},test(u){return arguments.length?(r=u,a):r},clean(){let u={},o=0;for(let i in n){let c=n[i];c!==gt&&(!r||!r(c))&&(u[i]=c,++o)}a.size=o,a.empty=0,a.object=n=u}};return t&&Object.keys(t).forEach(u=>{a.set(u,t[u])}),a}function _r(t,n,r,e,a,u){if(!r&&r!==0)return u;let o=+r,i=t[0],c=P(t),l;c<i&&(l=i,i=c,c=l),l=Math.abs(n-i);let h=Math.abs(c-n);return l<h&&l<=o?e:h<=o?a:u}function Wr(t,n,r){let e=t.prototype=Object.create(n.prototype);return Object.defineProperty(e,"constructor",{value:t,writable:!0,enumerable:!0,configurable:!0}),z(e,r)}function Jr(t,n,r,e){let a=n[0],u=n[n.length-1],o;return a>u&&(o=a,a=u,u=o),r=r===void 0||r,e=e===void 0||e,(r?a<=t:a<t)&&(e?t<=u:t<u)}function qr(t){return typeof t=="boolean"}function un(t){return Object.prototype.toString.call(t)==="[object Date]"}function on(t){return t&&B(t[Symbol.iterator])}function sn(t){return typeof t=="number"}function Hr(t){return Object.prototype.toString.call(t)==="[object RegExp]"}function pt(t){return typeof t=="string"}function Gr(t,n,r){t&&(t=n?R(t).map(i=>i.replace(/\\(.)/g,"$1")):R(t));let e=t&&t.length,a=r&&r.get||Qt,u=i=>a(n?[i]:wt(i)),o;if(!e)o=function(){return""};else if(e===1){let i=u(t[0]);o=function(c){return""+i(c)}}else{let i=t.map(u);o=function(c){let l=""+i[0](c),h=0;for(;++h<e;)l+="|"+i[h](c);return l}}return E(o,t,"key")}function Zr(t,n){let r=t[0],e=P(t),a=+n;return a?a===1?e:r+a*(e-r):r}var Vr=1e4;function Qr(t){t=+t||Vr;let n,r,e,a=()=>{n={},r={},e=0},u=(o,i)=>(++e>t&&(r=n,n={},e=1),n[o]=i);return a(),{clear:a,has:o=>N(n,o)||N(r,o),get:o=>N(n,o)?n[o]:N(r,o)?u(o,r[o]):void 0,set:(o,i)=>N(n,o)?n[o]=i:u(o,i)}}function Kr(t,n,r,e){let a=n.length,u=r.length;if(!u)return n;if(!a)return r;let o=e||new n.constructor(a+u),i=0,c=0,l=0;for(;i<a&&c<u;++l)o[l]=t(n[i],r[c])>0?r[c++]:n[i++];for(;i<a;++i,++l)o[l]=n[i];for(;c<u;++c,++l)o[l]=r[c];return o}function H(t,n){let r="";for(;--n>=0;)r+=t;return r}function Xr(t,n,r,e){let a=r||" ",u=t+"",o=n-u.length;return o<=0?u:e==="left"?H(a,o)+u:e==="center"?H(a,~~(o/2))+u+H(a,Math.ceil(o/2)):u+H(a,o)}function ln(t){return t&&P(t)-t[0]||0}function mt(t){return J(t)?`[${t.map(n=>n===null?"null":mt(n))}]`:$(t)||pt(t)?JSON.stringify(t).replaceAll("\u2028","\\u2028").replaceAll("\u2029","\\u2029"):t}function cn(t){return t==null||t===""?null:!t||t==="false"||t==="0"?!1:!!t}var te=t=>sn(t)||un(t)?t:Date.parse(t);function fn(t,n){return n||(n=te),t==null||t===""?null:n(t)}function hn(t){return t==null||t===""?null:t+""}function gn(t){let n={},r=t.length;for(let e=0;e<r;++e)n[t[e]]=!0;return n}function ne(t,n,r,e){let a=e??"\u2026",u=t+"",o=u.length,i=Math.max(0,n-a.length);return o<=n?u:r==="left"?a+u.slice(o-i):r==="center"?u.slice(0,Math.ceil(i/2))+a+u.slice(o-~~(i/2)):u.slice(0,i)+a}function re(t,n,r){if(t)if(n){let e=t.length;for(let a=0;a<e;++a){let u=n(t[a]);u&&r(u,a,t)}}else t.forEach(r)}var pn={},kt={},Ot=34,G=10,Ut=13;function mn(t){return Function("d","return {"+t.map(function(n,r){return JSON.stringify(n)+": d["+r+'] || ""'}).join(",")+"}")}function ee(t,n){var r=mn(t);return function(e,a){return n(r(e),a,t)}}function dn(t){var n=Object.create(null),r=[];return t.forEach(function(e){for(var a in e)a in n||r.push(n[a]=a)}),r}function T(t,n){var r=t+"",e=r.length;return e<n?Array(n-e+1).join(0)+r:r}function ae(t){return t<0?"-"+T(-t,6):t>9999?"+"+T(t,6):T(t,4)}function ue(t){var n=t.getUTCHours(),r=t.getUTCMinutes(),e=t.getUTCSeconds(),a=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":ae(t.getUTCFullYear(),4)+"-"+T(t.getUTCMonth()+1,2)+"-"+T(t.getUTCDate(),2)+(a?"T"+T(n,2)+":"+T(r,2)+":"+T(e,2)+"."+T(a,3)+"Z":e?"T"+T(n,2)+":"+T(r,2)+":"+T(e,2)+"Z":r||n?"T"+T(n,2)+":"+T(r,2)+"Z":"")}function oe(t){var n=RegExp('["'+t+`
1
+ import{a as Tt,n as _n,r as Wn,s as Jn,t as qn}from"./precisionRound-C3fmBb6j.js";import{i as _t,n as Hn,r as Gn,t as Zn}from"./defaultLocale-YteS-k_t.js";import{C as Vn,N as Wt,S as Qn,T as Jt,_ as qt,a as Kn,b as it,c as Ht,i as Xn,l as Gt,n as tr,o as nr,p as Zt,r as rr,s as er,t as ar,v as st,w as ur,x as or}from"./defaultLocale-B6z1Qyqt.js";function E(t,n,r){return t.fields=n||[],t.fname=r,t}function ir(t){return t==null?null:t.fname}function Vt(t){return t==null?null:t.fields}function Qt(t){return t.length===1?sr(t[0]):lr(t)}var sr=t=>function(n){return n[t]},lr=t=>{let n=t.length;return function(r){for(let e=0;e<n;++e)r=r[t[e]];return r}};function v(t){throw Error(t)}function wt(t){let n=[],r=t.length,e=null,a=0,u="",o,i,c;t+="";function l(){n.push(u+t.substring(o,i)),u="",o=i+1}for(o=i=0;i<r;++i)if(c=t[i],c==="\\")u+=t.substring(o,i++),o=i;else if(c===e)l(),e=null,a=-1;else{if(e)continue;o===a&&c==='"'||o===a&&c==="'"?(o=i+1,e=c):c==="."&&!a?i>o?l():o=i+1:c==="["?(i>o&&l(),a=o=i+1):c==="]"&&(a||v("Access path missing open bracket: "+t),a>0&&l(),a=0,o=i+1)}return a&&v("Access path missing closing bracket: "+t),e&&v("Access path missing closing quote: "+t),i>o&&(i++,l()),n}function lt(t,n,r){let e=wt(t);return t=e.length===1?e[0]:t,E((r&&r.get||Qt)(e),[t],n||t)}var cr=lt("id"),W=E(t=>t,[],"identity"),I=E(()=>0,[],"zero"),Kt=E(()=>1,[],"one"),fr=E(()=>!0,[],"true"),hr=E(()=>!1,[],"false"),gr=new Set([...Object.getOwnPropertyNames(Object.prototype).filter(t=>typeof Object.prototype[t]=="function"),"__proto__"]);function pr(t,n,r){let e=[n].concat([].slice.call(r));console[t].apply(console,e)}var mr=0,dr=1,yr=2,vr=3,br=4;function Mr(t,n,r=pr){let e=t||0;return{level(a){return arguments.length?(e=+a,this):e},error(){return e>=1&&r(n||"error","ERROR",arguments),this},warn(){return e>=2&&r(n||"warn","WARN",arguments),this},info(){return e>=3&&r(n||"log","INFO",arguments),this},debug(){return e>=4&&r(n||"log","DEBUG",arguments),this}}}var J=Array.isArray;function $(t){return t===Object(t)}var Xt=t=>t!=="__proto__";function Cr(...t){return t.reduce((n,r)=>{for(let e in r)if(e==="signals")n.signals=Tr(n.signals,r.signals);else{let a=e==="legend"?{layout:1}:e==="style"?!0:null;jt(n,e,r[e],a)}return n},{})}function jt(t,n,r,e){if(!Xt(n))return;let a,u;if($(r)&&!J(r))for(a in u=$(t[n])?t[n]:t[n]={},r)e&&(e===!0||e[a])?jt(u,a,r[a]):Xt(a)&&(u[a]=r[a]);else t[n]=r}function Tr(t,n){if(t==null)return n;let r={},e=[];function a(u){r[u.name]||(r[u.name]=1,e.push(u))}return n.forEach(a),t.forEach(a),e}function P(t){return t[t.length-1]}function q(t){return t==null||t===""?null:+t}var tn=t=>n=>t*Math.exp(n),nn=t=>n=>Math.log(t*n),rn=t=>n=>Math.sign(n)*Math.log1p(Math.abs(n/t)),en=t=>n=>Math.sign(n)*Math.expm1(Math.abs(n))*t,ct=t=>n=>n<0?-((-n)**+t):n**+t;function ft(t,n,r,e){let a=r(t[0]),u=r(P(t)),o=(u-a)*n;return[e(a-o),e(u-o)]}function wr(t,n){return ft(t,n,q,W)}function jr(t,n){var r=Math.sign(t[0]);return ft(t,n,nn(r),tn(r))}function Dr(t,n,r){return ft(t,n,ct(r),ct(1/r))}function kr(t,n,r){return ft(t,n,rn(r),en(r))}function ht(t,n,r,e,a){let u=e(t[0]),o=e(P(t)),i=n==null?(u+o)/2:e(n);return[a(i+(u-i)*r),a(i+(o-i)*r)]}function Or(t,n,r){return ht(t,n,r,q,W)}function Ur(t,n,r){let e=Math.sign(t[0]);return ht(t,n,r,nn(e),tn(e))}function xr(t,n,r,e){return ht(t,n,r,ct(e),ct(1/e))}function Nr(t,n,r,e){return ht(t,n,r,rn(e),en(e))}function Ar(t){return 1+~~(new Date(t).getMonth()/3)}function Er(t){return 1+~~(new Date(t).getUTCMonth()/3)}function R(t){return t==null?[]:J(t)?t:[t]}function Sr(t,n,r){let e=t[0],a=t[1],u;return a<e&&(u=a,a=e,e=u),u=a-e,u>=r-n?[n,r]:[e=Math.min(Math.max(e,n),r-u),e+u]}function B(t){return typeof t=="function"}var Fr="descending";function Pr(t,n,r){r||(r={}),n=R(n)||[];let e=[],a=[],u={},o=r.comparator||zr;return R(t).forEach((i,c)=>{i!=null&&(e.push(n[c]===Fr?-1:1),a.push(i=B(i)?i:lt(i,null,r)),(Vt(i)||[]).forEach(l=>u[l]=1))}),a.length===0?null:E(o(a,e),Object.keys(u))}var Dt=(t,n)=>(t<n||t==null)&&n!=null?-1:(t>n||n==null)&&t!=null?1:(n=n instanceof Date?+n:n,(t=t instanceof Date?+t:t)!==t&&n===n?-1:n!==n&&t===t?1:0),zr=(t,n)=>t.length===1?Yr(t[0],n[0]):Ir(t,n,t.length),Yr=(t,n)=>function(r,e){return Dt(t(r),t(e))*n},Ir=(t,n,r)=>(n.push(0),function(e,a){let u,o=0,i=-1;for(;o===0&&++i<r;)u=t[i],o=Dt(u(e),u(a));return o*n[i]});function an(t){return B(t)?t:()=>t}function $r(t,n){let r;return e=>{r&&clearTimeout(r),r=setTimeout(()=>(n(e),r=null),t)}}function z(t){for(let n,r,e=1,a=arguments.length;e<a;++e)for(r in n=arguments[e],n)t[r]=n[r];return t}function Rr(t,n){let r=0,e,a,u,o;if(t&&(e=t.length))if(n==null){for(a=t[r];r<e&&(a==null||a!==a);a=t[++r]);for(u=o=a;r<e;++r)a=t[r],a!=null&&(a<u&&(u=a),a>o&&(o=a))}else{for(a=n(t[r]);r<e&&(a==null||a!==a);a=n(t[++r]));for(u=o=a;r<e;++r)a=n(t[r]),a!=null&&(a<u&&(u=a),a>o&&(o=a))}return[u,o]}function Br(t,n){let r=t.length,e=-1,a,u,o,i,c;if(n==null){for(;++e<r;)if(u=t[e],u!=null&&u>=u){a=o=u;break}if(e===r)return[-1,-1];for(i=c=e;++e<r;)u=t[e],u!=null&&(a>u&&(a=u,i=e),o<u&&(o=u,c=e))}else{for(;++e<r;)if(u=n(t[e],e,t),u!=null&&u>=u){a=o=u;break}if(e===r)return[-1,-1];for(i=c=e;++e<r;)u=n(t[e],e,t),u!=null&&(a>u&&(a=u,i=e),o<u&&(o=u,c=e))}return[i,c]}function N(t,n){return Object.hasOwn(t,n)}var gt={};function Lr(t){let n={},r;function e(u){return N(n,u)&&n[u]!==gt}let a={size:0,empty:0,object:n,has:e,get(u){return e(u)?n[u]:void 0},set(u,o){return e(u)||(++a.size,n[u]===gt&&--a.empty),n[u]=o,this},delete(u){return e(u)&&(--a.size,++a.empty,n[u]=gt),this},clear(){a.size=a.empty=0,a.object=n={}},test(u){return arguments.length?(r=u,a):r},clean(){let u={},o=0;for(let i in n){let c=n[i];c!==gt&&(!r||!r(c))&&(u[i]=c,++o)}a.size=o,a.empty=0,a.object=n=u}};return t&&Object.keys(t).forEach(u=>{a.set(u,t[u])}),a}function _r(t,n,r,e,a,u){if(!r&&r!==0)return u;let o=+r,i=t[0],c=P(t),l;c<i&&(l=i,i=c,c=l),l=Math.abs(n-i);let h=Math.abs(c-n);return l<h&&l<=o?e:h<=o?a:u}function Wr(t,n,r){let e=t.prototype=Object.create(n.prototype);return Object.defineProperty(e,"constructor",{value:t,writable:!0,enumerable:!0,configurable:!0}),z(e,r)}function Jr(t,n,r,e){let a=n[0],u=n[n.length-1],o;return a>u&&(o=a,a=u,u=o),r=r===void 0||r,e=e===void 0||e,(r?a<=t:a<t)&&(e?t<=u:t<u)}function qr(t){return typeof t=="boolean"}function un(t){return Object.prototype.toString.call(t)==="[object Date]"}function on(t){return t&&B(t[Symbol.iterator])}function sn(t){return typeof t=="number"}function Hr(t){return Object.prototype.toString.call(t)==="[object RegExp]"}function pt(t){return typeof t=="string"}function Gr(t,n,r){t&&(t=n?R(t).map(i=>i.replace(/\\(.)/g,"$1")):R(t));let e=t&&t.length,a=r&&r.get||Qt,u=i=>a(n?[i]:wt(i)),o;if(!e)o=function(){return""};else if(e===1){let i=u(t[0]);o=function(c){return""+i(c)}}else{let i=t.map(u);o=function(c){let l=""+i[0](c),h=0;for(;++h<e;)l+="|"+i[h](c);return l}}return E(o,t,"key")}function Zr(t,n){let r=t[0],e=P(t),a=+n;return a?a===1?e:r+a*(e-r):r}var Vr=1e4;function Qr(t){t=+t||Vr;let n,r,e,a=()=>{n={},r={},e=0},u=(o,i)=>(++e>t&&(r=n,n={},e=1),n[o]=i);return a(),{clear:a,has:o=>N(n,o)||N(r,o),get:o=>N(n,o)?n[o]:N(r,o)?u(o,r[o]):void 0,set:(o,i)=>N(n,o)?n[o]=i:u(o,i)}}function Kr(t,n,r,e){let a=n.length,u=r.length;if(!u)return n;if(!a)return r;let o=e||new n.constructor(a+u),i=0,c=0,l=0;for(;i<a&&c<u;++l)o[l]=t(n[i],r[c])>0?r[c++]:n[i++];for(;i<a;++i,++l)o[l]=n[i];for(;c<u;++c,++l)o[l]=r[c];return o}function H(t,n){let r="";for(;--n>=0;)r+=t;return r}function Xr(t,n,r,e){let a=r||" ",u=t+"",o=n-u.length;return o<=0?u:e==="left"?H(a,o)+u:e==="center"?H(a,~~(o/2))+u+H(a,Math.ceil(o/2)):u+H(a,o)}function ln(t){return t&&P(t)-t[0]||0}function mt(t){return J(t)?`[${t.map(n=>n===null?"null":mt(n))}]`:$(t)||pt(t)?JSON.stringify(t).replaceAll("\u2028","\\u2028").replaceAll("\u2029","\\u2029"):t}function cn(t){return t==null||t===""?null:!t||t==="false"||t==="0"?!1:!!t}var te=t=>sn(t)||un(t)?t:Date.parse(t);function fn(t,n){return n||(n=te),t==null||t===""?null:n(t)}function hn(t){return t==null||t===""?null:t+""}function gn(t){let n={},r=t.length;for(let e=0;e<r;++e)n[t[e]]=!0;return n}function ne(t,n,r,e){let a=e??"\u2026",u=t+"",o=u.length,i=Math.max(0,n-a.length);return o<=n?u:r==="left"?a+u.slice(o-i):r==="center"?u.slice(0,Math.ceil(i/2))+a+u.slice(o-~~(i/2)):u.slice(0,i)+a}function re(t,n,r){if(t)if(n){let e=t.length;for(let a=0;a<e;++a){let u=n(t[a]);u&&r(u,a,t)}}else t.forEach(r)}var pn={},kt={},Ot=34,G=10,Ut=13;function mn(t){return Function("d","return {"+t.map(function(n,r){return JSON.stringify(n)+": d["+r+'] || ""'}).join(",")+"}")}function ee(t,n){var r=mn(t);return function(e,a){return n(r(e),a,t)}}function dn(t){var n=Object.create(null),r=[];return t.forEach(function(e){for(var a in e)a in n||r.push(n[a]=a)}),r}function T(t,n){var r=t+"",e=r.length;return e<n?Array(n-e+1).join(0)+r:r}function ae(t){return t<0?"-"+T(-t,6):t>9999?"+"+T(t,6):T(t,4)}function ue(t){var n=t.getUTCHours(),r=t.getUTCMinutes(),e=t.getUTCSeconds(),a=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":ae(t.getUTCFullYear(),4)+"-"+T(t.getUTCMonth()+1,2)+"-"+T(t.getUTCDate(),2)+(a?"T"+T(n,2)+":"+T(r,2)+":"+T(e,2)+"."+T(a,3)+"Z":e?"T"+T(n,2)+":"+T(r,2)+":"+T(e,2)+"Z":r||n?"T"+T(n,2)+":"+T(r,2)+"Z":"")}function oe(t){var n=RegExp('["'+t+`
2
2
  \r]`),r=t.charCodeAt(0);function e(s,f){var g,p,m=a(s,function(d,C){if(g)return g(d,C-1);p=d,g=f?ee(d,f):mn(d)});return m.columns=p||[],m}function a(s,f){var g=[],p=s.length,m=0,d=0,C,x=p<=0,j=!1;s.charCodeAt(p-1)===G&&--p,s.charCodeAt(p-1)===Ut&&--p;function y(){if(x)return kt;if(j)return j=!1,pn;var ut,ot=m,_;if(s.charCodeAt(ot)===Ot){for(;m++<p&&s.charCodeAt(m)!==Ot||s.charCodeAt(++m)===Ot;);return(ut=m)>=p?x=!0:(_=s.charCodeAt(m++))===G?j=!0:_===Ut&&(j=!0,s.charCodeAt(m)===G&&++m),s.slice(ot+1,ut-1).replace(/""/g,'"')}for(;m<p;){if((_=s.charCodeAt(ut=m++))===G)j=!0;else if(_===Ut)j=!0,s.charCodeAt(m)===G&&++m;else if(_!==r)continue;return s.slice(ot,ut)}return x=!0,s.slice(ot,p)}for(;(C=y())!==kt;){for(var at=[];C!==pn&&C!==kt;)at.push(C),C=y();f&&(at=f(at,d++))==null||g.push(at)}return g}function u(s,f){return s.map(function(g){return f.map(function(p){return h(g[p])}).join(t)})}function o(s,f){return f??(f=dn(s)),[f.map(h).join(t)].concat(u(s,f)).join(`
3
3
  `)}function i(s,f){return f??(f=dn(s)),u(s,f).join(`
4
4
  `)}function c(s){return s.map(l).join(`
@@ -1 +1 @@
1
- import{s as V}from"./chunk-LvLJmgfZ.js";import{t as B}from"./react-Bj1aDYRI.js";import{t as G}from"./compiler-runtime-B3qBwwSJ.js";import{t as H}from"./jsx-runtime-ZmTK25f3.js";import{t as W}from"./button-CZ3Cs4qb.js";import{r as I}from"./requests-B4FYHTZl.js";import{r as D}from"./input-DHHmNa19.js";import{t as E}from"./use-toast-T0_cQDma.js";import{c as J,i as O,n as Q,s as U,t as X}from"./select-B7bfltkI.js";import{a as Z,c as $,i as ee,n as te,r as re}from"./dialog-tQELcltn.js";import{t as ae}from"./links-7AQBmdyV.js";import{t as P}from"./label-C9wP7Kp2.js";import{r as L}from"./field-D9jE8HEt.js";var oe=G(),T=V(B(),1),t=V(H(),1);function le(a){return a.sort((e,r)=>e.provider==="env"?1:r.provider==="env"?-1:0)}const ne=a=>{let e=(0,oe.c)(43),{providerNames:r,onClose:A,onSuccess:F}=a,{writeSecret:Y}=I(),[o,M]=T.useState(""),[n,R]=T.useState(""),[l,z]=T.useState(r[0]),g;e[0]!==o||e[1]!==l||e[2]!==F||e[3]!==n||e[4]!==Y?(g=async i=>{if(i.preventDefault(),!l){E({title:"Error",description:"No location selected for the secret.",variant:"danger"});return}if(!o||!n||!l){E({title:"Error",description:"Please fill in all fields.",variant:"danger"});return}try{await Y({key:o,value:n,provider:"dotenv",name:l}),E({title:"Secret created",description:"The secret has been created successfully."}),F(o)}catch{E({title:"Error",description:"Failed to create secret. Please try again.",variant:"danger"})}},e[0]=o,e[1]=l,e[2]=F,e[3]=n,e[4]=Y,e[5]=g):g=e[5];let q=g,j;e[6]===Symbol.for("react.memo_cache_sentinel")?(j=(0,t.jsxs)(Z,{children:[(0,t.jsx)($,{children:"Add Secret"}),(0,t.jsx)(re,{children:"Add a new secret to your environment variables."})]}),e[6]=j):j=e[6];let y;e[7]===Symbol.for("react.memo_cache_sentinel")?(y=(0,t.jsx)(P,{htmlFor:"key",children:"Key"}),e[7]=y):y=e[7];let S;e[8]===Symbol.for("react.memo_cache_sentinel")?(S=i=>{M(ie(i.target.value))},e[8]=S):S=e[8];let s;e[9]===o?s=e[10]:(s=(0,t.jsxs)("div",{className:"grid gap-2",children:[y,(0,t.jsx)(D,{id:"key",value:o,onChange:S,placeholder:"MY_SECRET_KEY",required:!0})]}),e[9]=o,e[10]=s);let _;e[11]===Symbol.for("react.memo_cache_sentinel")?(_=(0,t.jsx)(P,{htmlFor:"value",children:"Value"}),e[11]=_):_=e[11];let b;e[12]===Symbol.for("react.memo_cache_sentinel")?(b=i=>R(i.target.value),e[12]=b):b=e[12];let c;e[13]===n?c=e[14]:(c=(0,t.jsx)(D,{id:"value",type:"password",value:n,onChange:b,required:!0,autoComplete:"off"}),e[13]=n,e[14]=c);let C;e[15]===Symbol.for("react.memo_cache_sentinel")?(C=se()&&(0,t.jsx)(L,{children:"Note: You are sending this key over http."}),e[15]=C):C=e[15];let d;e[16]===c?d=e[17]:(d=(0,t.jsxs)("div",{className:"grid gap-2",children:[_,c,C]}),e[16]=c,e[17]=d);let N;e[18]===Symbol.for("react.memo_cache_sentinel")?(N=(0,t.jsx)(P,{htmlFor:"location",children:"Location"}),e[18]=N):N=e[18];let m;e[19]===r.length?m=e[20]:(m=r.length===0&&(0,t.jsx)("p",{className:"text-sm text-muted-foreground",children:"No dotenv locations configured."}),e[19]=r.length,e[20]=m);let h;e[21]!==l||e[22]!==r?(h=r.length>0&&(0,t.jsxs)(X,{value:l,onValueChange:i=>z(i),children:[(0,t.jsx)(U,{children:(0,t.jsx)(J,{placeholder:"Select a provider"})}),(0,t.jsx)(Q,{children:r.map(ce)})]}),e[21]=l,e[22]=r,e[23]=h):h=e[23];let k;e[24]===Symbol.for("react.memo_cache_sentinel")?(k=(0,t.jsxs)(L,{children:["You can configure the location by setting the"," ",(0,t.jsx)(ae,{href:"https://links.marimo.app/dotenv",children:"dotenv configuration"}),"."]}),e[24]=k):k=e[24];let p;e[25]!==m||e[26]!==h?(p=(0,t.jsxs)("div",{className:"grid gap-2",children:[N,m,h,k]}),e[25]=m,e[26]=h,e[27]=p):p=e[27];let u;e[28]!==d||e[29]!==p||e[30]!==s?(u=(0,t.jsxs)("div",{className:"grid gap-4 py-4",children:[s,d,p]}),e[28]=d,e[29]=p,e[30]=s,e[31]=u):u=e[31];let f;e[32]===A?f=e[33]:(f=(0,t.jsx)(W,{type:"button",variant:"outline",onClick:A,children:"Cancel"}),e[32]=A,e[33]=f);let K=!o||!n||!l,v;e[34]===K?v=e[35]:(v=(0,t.jsx)(W,{type:"submit",disabled:K,children:"Add Secret"}),e[34]=K,e[35]=v);let x;e[36]!==f||e[37]!==v?(x=(0,t.jsxs)(ee,{children:[f,v]}),e[36]=f,e[37]=v,e[38]=x):x=e[38];let w;return e[39]!==q||e[40]!==u||e[41]!==x?(w=(0,t.jsx)(te,{children:(0,t.jsxs)("form",{onSubmit:q,children:[j,u,x]})}),e[39]=q,e[40]=u,e[41]=x,e[42]=w):w=e[42],w};function ie(a){return a.replaceAll(/\W/g,"_")}function se(){return window.location.href.startsWith("http://")}function ce(a){return(0,t.jsx)(O,{value:a,children:a},a)}export{le as n,ne as t};
1
+ import{s as V}from"./chunk-LvLJmgfZ.js";import{t as B}from"./react-Bj1aDYRI.js";import{t as G}from"./compiler-runtime-B3qBwwSJ.js";import{t as H}from"./jsx-runtime-ZmTK25f3.js";import{t as W}from"./button-CZ3Cs4qb.js";import{r as I}from"./requests-B4FYHTZl.js";import{r as D}from"./input-DHHmNa19.js";import{t as E}from"./use-toast-T0_cQDma.js";import{c as J,i as O,n as Q,s as U,t as X}from"./select-B7bfltkI.js";import{a as Z,c as $,i as ee,n as te,r as re}from"./dialog-tQELcltn.js";import{t as ae}from"./links-fh_IXIKE.js";import{t as P}from"./label-C--1sWU6.js";import{r as L}from"./field-D9jE8HEt.js";var oe=G(),T=V(B(),1),t=V(H(),1);function le(a){return a.sort((e,r)=>e.provider==="env"?1:r.provider==="env"?-1:0)}const ne=a=>{let e=(0,oe.c)(43),{providerNames:r,onClose:A,onSuccess:F}=a,{writeSecret:Y}=I(),[o,M]=T.useState(""),[n,R]=T.useState(""),[l,z]=T.useState(r[0]),g;e[0]!==o||e[1]!==l||e[2]!==F||e[3]!==n||e[4]!==Y?(g=async i=>{if(i.preventDefault(),!l){E({title:"Error",description:"No location selected for the secret.",variant:"danger"});return}if(!o||!n||!l){E({title:"Error",description:"Please fill in all fields.",variant:"danger"});return}try{await Y({key:o,value:n,provider:"dotenv",name:l}),E({title:"Secret created",description:"The secret has been created successfully."}),F(o)}catch{E({title:"Error",description:"Failed to create secret. Please try again.",variant:"danger"})}},e[0]=o,e[1]=l,e[2]=F,e[3]=n,e[4]=Y,e[5]=g):g=e[5];let q=g,j;e[6]===Symbol.for("react.memo_cache_sentinel")?(j=(0,t.jsxs)(Z,{children:[(0,t.jsx)($,{children:"Add Secret"}),(0,t.jsx)(re,{children:"Add a new secret to your environment variables."})]}),e[6]=j):j=e[6];let y;e[7]===Symbol.for("react.memo_cache_sentinel")?(y=(0,t.jsx)(P,{htmlFor:"key",children:"Key"}),e[7]=y):y=e[7];let S;e[8]===Symbol.for("react.memo_cache_sentinel")?(S=i=>{M(ie(i.target.value))},e[8]=S):S=e[8];let s;e[9]===o?s=e[10]:(s=(0,t.jsxs)("div",{className:"grid gap-2",children:[y,(0,t.jsx)(D,{id:"key",value:o,onChange:S,placeholder:"MY_SECRET_KEY",required:!0})]}),e[9]=o,e[10]=s);let _;e[11]===Symbol.for("react.memo_cache_sentinel")?(_=(0,t.jsx)(P,{htmlFor:"value",children:"Value"}),e[11]=_):_=e[11];let b;e[12]===Symbol.for("react.memo_cache_sentinel")?(b=i=>R(i.target.value),e[12]=b):b=e[12];let c;e[13]===n?c=e[14]:(c=(0,t.jsx)(D,{id:"value",type:"password",value:n,onChange:b,required:!0,autoComplete:"off"}),e[13]=n,e[14]=c);let C;e[15]===Symbol.for("react.memo_cache_sentinel")?(C=se()&&(0,t.jsx)(L,{children:"Note: You are sending this key over http."}),e[15]=C):C=e[15];let d;e[16]===c?d=e[17]:(d=(0,t.jsxs)("div",{className:"grid gap-2",children:[_,c,C]}),e[16]=c,e[17]=d);let N;e[18]===Symbol.for("react.memo_cache_sentinel")?(N=(0,t.jsx)(P,{htmlFor:"location",children:"Location"}),e[18]=N):N=e[18];let m;e[19]===r.length?m=e[20]:(m=r.length===0&&(0,t.jsx)("p",{className:"text-sm text-muted-foreground",children:"No dotenv locations configured."}),e[19]=r.length,e[20]=m);let h;e[21]!==l||e[22]!==r?(h=r.length>0&&(0,t.jsxs)(X,{value:l,onValueChange:i=>z(i),children:[(0,t.jsx)(U,{children:(0,t.jsx)(J,{placeholder:"Select a provider"})}),(0,t.jsx)(Q,{children:r.map(ce)})]}),e[21]=l,e[22]=r,e[23]=h):h=e[23];let k;e[24]===Symbol.for("react.memo_cache_sentinel")?(k=(0,t.jsxs)(L,{children:["You can configure the location by setting the"," ",(0,t.jsx)(ae,{href:"https://links.marimo.app/dotenv",children:"dotenv configuration"}),"."]}),e[24]=k):k=e[24];let p;e[25]!==m||e[26]!==h?(p=(0,t.jsxs)("div",{className:"grid gap-2",children:[N,m,h,k]}),e[25]=m,e[26]=h,e[27]=p):p=e[27];let u;e[28]!==d||e[29]!==p||e[30]!==s?(u=(0,t.jsxs)("div",{className:"grid gap-4 py-4",children:[s,d,p]}),e[28]=d,e[29]=p,e[30]=s,e[31]=u):u=e[31];let f;e[32]===A?f=e[33]:(f=(0,t.jsx)(W,{type:"button",variant:"outline",onClick:A,children:"Cancel"}),e[32]=A,e[33]=f);let K=!o||!n||!l,v;e[34]===K?v=e[35]:(v=(0,t.jsx)(W,{type:"submit",disabled:K,children:"Add Secret"}),e[34]=K,e[35]=v);let x;e[36]!==f||e[37]!==v?(x=(0,t.jsxs)(ee,{children:[f,v]}),e[36]=f,e[37]=v,e[38]=x):x=e[38];let w;return e[39]!==q||e[40]!==u||e[41]!==x?(w=(0,t.jsx)(te,{children:(0,t.jsxs)("form",{onSubmit:q,children:[j,u,x]})}),e[39]=q,e[40]=u,e[41]=x,e[42]=w):w=e[42],w};function ie(a){return a.replaceAll(/\W/g,"_")}function se(){return window.location.href.startsWith("http://")}function ce(a){return(0,t.jsx)(O,{value:a,children:a},a)}export{le as n,ne as t};
@@ -1,4 +1,4 @@
1
- var j,Q,K,Z,q,J,tt,it,et,st;import{t as zt}from"./linear-BxhToEEF.js";import{n as ui}from"./ordinal-C93T4L8H.js";import{t as xi}from"./range-1DwpgXvM.js";import"./defaultLocale-JieDVWC_.js";import"./purify.es-DZrAQFIu.js";import"./src-DJ8ZKoFs.js";import{t as Ot}from"./line-VKarCWVL.js";import{i as Wt}from"./chunk-S3R3BYOJ-CM-pQ0EF.js";import{n as di}from"./init-DZpk0tdu.js";import{n,r as Ft}from"./src-CmKhyEBC.js";import{B as pi,C as Xt,I as fi,T as mi,U as yi,_ as bi,a as Ai,c as Ci,d as wi,v as Si,y as mt,z as ki}from"./chunk-ABZYJK2D-CtRGq-db.js";import{t as _i}from"./chunk-EXTU4WIE-CN3BqsR0.js";import"./dist-DxxvVPQH.js";import{t as Ti}from"./chunk-JA3XYJ7Z-B5-JYmoA.js";function yt(){var e=ui().unknown(void 0),t=e.domain,i=e.range,s=0,a=1,l,g,f=!1,p=0,_=0,L=.5;delete e.unknown;function w(){var b=t().length,v=a<s,D=v?a:s,P=v?s:a;l=(P-D)/Math.max(1,b-p+_*2),f&&(l=Math.floor(l)),D+=(P-D-l*(b-p))*L,g=l*(1-p),f&&(D=Math.round(D),g=Math.round(g));var E=xi(b).map(function(m){return D+l*m});return i(v?E.reverse():E)}return e.domain=function(b){return arguments.length?(t(b),w()):t()},e.range=function(b){return arguments.length?([s,a]=b,s=+s,a=+a,w()):[s,a]},e.rangeRound=function(b){return[s,a]=b,s=+s,a=+a,f=!0,w()},e.bandwidth=function(){return g},e.step=function(){return l},e.round=function(b){return arguments.length?(f=!!b,w()):f},e.padding=function(b){return arguments.length?(p=Math.min(1,_=+b),w()):p},e.paddingInner=function(b){return arguments.length?(p=Math.min(1,b),w()):p},e.paddingOuter=function(b){return arguments.length?(_=+b,w()):_},e.align=function(b){return arguments.length?(L=Math.max(0,Math.min(1,b)),w()):L},e.copy=function(){return yt(t(),[s,a]).round(f).paddingInner(p).paddingOuter(_).align(L)},di.apply(w(),arguments)}var bt=(function(){var e=n(function(h,A,x,u){for(x||(x={}),u=h.length;u--;x[h[u]]=A);return x},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],a=[1,5],l=[1,6],g=[1,7],f=[1,5,10,12,14,16,18,19,21,23,34,35,36],p=[1,25],_=[1,26],L=[1,28],w=[1,29],b=[1,30],v=[1,31],D=[1,32],P=[1,33],E=[1,34],m=[1,35],T=[1,36],r=[1,37],z=[1,43],O=[1,42],V=[1,47],S=[1,50],c=[1,10,12,14,16,18,19,21,23,34,35,36],M=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],y=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],Y=[1,64],U={trace:n(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:n(function(h,A,x,u,k,o,at){var d=o.length-1;switch(k){case 5:u.setOrientation(o[d]);break;case 9:u.setDiagramTitle(o[d].text.trim());break;case 12:u.setLineData({text:"",type:"text"},o[d]);break;case 13:u.setLineData(o[d-1],o[d]);break;case 14:u.setBarData({text:"",type:"text"},o[d]);break;case 15:u.setBarData(o[d-1],o[d]);break;case 16:this.$=o[d].trim(),u.setAccTitle(this.$);break;case 17:case 18:this.$=o[d].trim(),u.setAccDescription(this.$);break;case 19:this.$=o[d-1];break;case 20:this.$=[Number(o[d-2]),...o[d]];break;case 21:this.$=[Number(o[d])];break;case 22:u.setXAxisTitle(o[d]);break;case 23:u.setXAxisTitle(o[d-1]);break;case 24:u.setXAxisTitle({type:"text",text:""});break;case 25:u.setXAxisBand(o[d]);break;case 26:u.setXAxisRangeData(Number(o[d-2]),Number(o[d]));break;case 27:this.$=o[d-1];break;case 28:this.$=[o[d-2],...o[d]];break;case 29:this.$=[o[d]];break;case 30:u.setYAxisTitle(o[d]);break;case 31:u.setYAxisTitle(o[d-1]);break;case 32:u.setYAxisTitle({type:"text",text:""});break;case 33:u.setYAxisRangeData(Number(o[d-2]),Number(o[d]));break;case 37:this.$={text:o[d],type:"text"};break;case 38:this.$={text:o[d],type:"text"};break;case 39:this.$={text:o[d],type:"markdown"};break;case 40:this.$=o[d];break;case 41:this.$=o[d-1]+""+o[d];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,34:a,35:l,36:g}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,34:a,35:l,36:g}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:a,35:l,36:g}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(f,[2,34]),e(f,[2,35]),e(f,[2,36]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,34:a,35:l,36:g}),{1:[2,3]},e(f,[2,5]),e(t,[2,7],{4:22,34:a,35:l,36:g}),{11:23,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:39,13:38,24:z,27:O,29:40,30:41,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:45,15:44,27:V,33:46,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:49,17:48,24:S,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:52,17:51,24:S,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{20:[1,53]},{22:[1,54]},e(c,[2,18]),{1:[2,2]},e(c,[2,8]),e(c,[2,9]),e(M,[2,37],{40:55,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r}),e(M,[2,38]),e(M,[2,39]),e(y,[2,40]),e(y,[2,42]),e(y,[2,43]),e(y,[2,44]),e(y,[2,45]),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),e(y,[2,49]),e(y,[2,50]),e(y,[2,51]),e(c,[2,10]),e(c,[2,22],{30:41,29:56,24:z,27:O}),e(c,[2,24]),e(c,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},e(c,[2,11]),e(c,[2,30],{33:60,27:V}),e(c,[2,32]),{31:[1,61]},e(c,[2,12]),{17:62,24:S},{25:63,27:Y},e(c,[2,14]),{17:65,24:S},e(c,[2,16]),e(c,[2,17]),e(y,[2,41]),e(c,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},e(c,[2,31]),{27:[1,69]},e(c,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},e(c,[2,15]),e(c,[2,26]),e(c,[2,27]),{11:59,32:72,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},e(c,[2,33]),e(c,[2,19]),{25:73,27:Y},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:n(function(h,A){if(A.recoverable)this.trace(h);else{var x=Error(h);throw x.hash=A,x}},"parseError"),parse:n(function(h){var A=this,x=[0],u=[],k=[null],o=[],at=this.table,d="",rt=0,vt=0,Et=0,ri=2,Mt=1,li=o.slice.call(arguments,1),R=Object.create(this.lexer),X={yy:{}};for(var xt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,xt)&&(X.yy[xt]=this.yy[xt]);R.setInput(h,X.yy),X.yy.lexer=R,X.yy.parser=this,R.yylloc===void 0&&(R.yylloc={});var dt=R.yylloc;o.push(dt);var ci=R.options&&R.options.ranges;typeof X.yy.parseError=="function"?this.parseError=X.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function gi(B){x.length-=2*B,k.length-=B,o.length-=B}n(gi,"popStack");function It(){var B=u.pop()||R.lex()||Mt;return typeof B!="number"&&(B instanceof Array&&(u=B,B=u.pop()),B=A.symbols_[B]||B),B}n(It,"lex");for(var I,pt,N,$,ft,H={},lt,W,$t,ct;;){if(N=x[x.length-1],this.defaultActions[N]?$=this.defaultActions[N]:(I??(I=It()),$=at[N]&&at[N][I]),$===void 0||!$.length||!$[0]){var Bt="";for(lt in ct=[],at[N])this.terminals_[lt]&&lt>ri&&ct.push("'"+this.terminals_[lt]+"'");Bt=R.showPosition?"Parse error on line "+(rt+1)+`:
1
+ var j,Q,K,Z,q,J,tt,it,et,st;import{t as zt}from"./linear-DWpCiijk.js";import{n as ui}from"./ordinal-DAqJmfoU.js";import{t as xi}from"./range-7fnH_zLA.js";import"./defaultLocale-YteS-k_t.js";import"./purify.es-B-nzWya6.js";import"./src-DJ8ZKoFs.js";import{t as Ot}from"./line-VKarCWVL.js";import{i as Wt}from"./chunk-S3R3BYOJ-D1UiABQX.js";import{n as di}from"./init-DZpk0tdu.js";import{n,r as Ft}from"./src-CmKhyEBC.js";import{B as pi,C as Xt,I as fi,T as mi,U as yi,_ as bi,a as Ai,c as Ci,d as wi,v as Si,y as mt,z as ki}from"./chunk-ABZYJK2D-D1A06qKo.js";import{t as _i}from"./chunk-EXTU4WIE-wi_fHsHN.js";import"./dist-DxxvVPQH.js";import{t as Ti}from"./chunk-JA3XYJ7Z-tKDxhnhw.js";function yt(){var e=ui().unknown(void 0),t=e.domain,i=e.range,s=0,a=1,l,g,f=!1,p=0,_=0,L=.5;delete e.unknown;function w(){var b=t().length,v=a<s,D=v?a:s,P=v?s:a;l=(P-D)/Math.max(1,b-p+_*2),f&&(l=Math.floor(l)),D+=(P-D-l*(b-p))*L,g=l*(1-p),f&&(D=Math.round(D),g=Math.round(g));var E=xi(b).map(function(m){return D+l*m});return i(v?E.reverse():E)}return e.domain=function(b){return arguments.length?(t(b),w()):t()},e.range=function(b){return arguments.length?([s,a]=b,s=+s,a=+a,w()):[s,a]},e.rangeRound=function(b){return[s,a]=b,s=+s,a=+a,f=!0,w()},e.bandwidth=function(){return g},e.step=function(){return l},e.round=function(b){return arguments.length?(f=!!b,w()):f},e.padding=function(b){return arguments.length?(p=Math.min(1,_=+b),w()):p},e.paddingInner=function(b){return arguments.length?(p=Math.min(1,b),w()):p},e.paddingOuter=function(b){return arguments.length?(_=+b,w()):_},e.align=function(b){return arguments.length?(L=Math.max(0,Math.min(1,b)),w()):L},e.copy=function(){return yt(t(),[s,a]).round(f).paddingInner(p).paddingOuter(_).align(L)},di.apply(w(),arguments)}var bt=(function(){var e=n(function(h,A,x,u){for(x||(x={}),u=h.length;u--;x[h[u]]=A);return x},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],a=[1,5],l=[1,6],g=[1,7],f=[1,5,10,12,14,16,18,19,21,23,34,35,36],p=[1,25],_=[1,26],L=[1,28],w=[1,29],b=[1,30],v=[1,31],D=[1,32],P=[1,33],E=[1,34],m=[1,35],T=[1,36],r=[1,37],z=[1,43],O=[1,42],V=[1,47],S=[1,50],c=[1,10,12,14,16,18,19,21,23,34,35,36],M=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],y=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],Y=[1,64],U={trace:n(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:n(function(h,A,x,u,k,o,at){var d=o.length-1;switch(k){case 5:u.setOrientation(o[d]);break;case 9:u.setDiagramTitle(o[d].text.trim());break;case 12:u.setLineData({text:"",type:"text"},o[d]);break;case 13:u.setLineData(o[d-1],o[d]);break;case 14:u.setBarData({text:"",type:"text"},o[d]);break;case 15:u.setBarData(o[d-1],o[d]);break;case 16:this.$=o[d].trim(),u.setAccTitle(this.$);break;case 17:case 18:this.$=o[d].trim(),u.setAccDescription(this.$);break;case 19:this.$=o[d-1];break;case 20:this.$=[Number(o[d-2]),...o[d]];break;case 21:this.$=[Number(o[d])];break;case 22:u.setXAxisTitle(o[d]);break;case 23:u.setXAxisTitle(o[d-1]);break;case 24:u.setXAxisTitle({type:"text",text:""});break;case 25:u.setXAxisBand(o[d]);break;case 26:u.setXAxisRangeData(Number(o[d-2]),Number(o[d]));break;case 27:this.$=o[d-1];break;case 28:this.$=[o[d-2],...o[d]];break;case 29:this.$=[o[d]];break;case 30:u.setYAxisTitle(o[d]);break;case 31:u.setYAxisTitle(o[d-1]);break;case 32:u.setYAxisTitle({type:"text",text:""});break;case 33:u.setYAxisRangeData(Number(o[d-2]),Number(o[d]));break;case 37:this.$={text:o[d],type:"text"};break;case 38:this.$={text:o[d],type:"text"};break;case 39:this.$={text:o[d],type:"markdown"};break;case 40:this.$=o[d];break;case 41:this.$=o[d-1]+""+o[d];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,34:a,35:l,36:g}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,34:a,35:l,36:g}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:a,35:l,36:g}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(f,[2,34]),e(f,[2,35]),e(f,[2,36]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,34:a,35:l,36:g}),{1:[2,3]},e(f,[2,5]),e(t,[2,7],{4:22,34:a,35:l,36:g}),{11:23,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:39,13:38,24:z,27:O,29:40,30:41,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:45,15:44,27:V,33:46,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:49,17:48,24:S,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{11:52,17:51,24:S,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},{20:[1,53]},{22:[1,54]},e(c,[2,18]),{1:[2,2]},e(c,[2,8]),e(c,[2,9]),e(M,[2,37],{40:55,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r}),e(M,[2,38]),e(M,[2,39]),e(y,[2,40]),e(y,[2,42]),e(y,[2,43]),e(y,[2,44]),e(y,[2,45]),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),e(y,[2,49]),e(y,[2,50]),e(y,[2,51]),e(c,[2,10]),e(c,[2,22],{30:41,29:56,24:z,27:O}),e(c,[2,24]),e(c,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},e(c,[2,11]),e(c,[2,30],{33:60,27:V}),e(c,[2,32]),{31:[1,61]},e(c,[2,12]),{17:62,24:S},{25:63,27:Y},e(c,[2,14]),{17:65,24:S},e(c,[2,16]),e(c,[2,17]),e(y,[2,41]),e(c,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},e(c,[2,31]),{27:[1,69]},e(c,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},e(c,[2,15]),e(c,[2,26]),e(c,[2,27]),{11:59,32:72,37:24,38:p,39:_,40:27,41:L,42:w,43:b,44:v,45:D,46:P,47:E,48:m,49:T,50:r},e(c,[2,33]),e(c,[2,19]),{25:73,27:Y},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:n(function(h,A){if(A.recoverable)this.trace(h);else{var x=Error(h);throw x.hash=A,x}},"parseError"),parse:n(function(h){var A=this,x=[0],u=[],k=[null],o=[],at=this.table,d="",rt=0,vt=0,Et=0,ri=2,Mt=1,li=o.slice.call(arguments,1),R=Object.create(this.lexer),X={yy:{}};for(var xt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,xt)&&(X.yy[xt]=this.yy[xt]);R.setInput(h,X.yy),X.yy.lexer=R,X.yy.parser=this,R.yylloc===void 0&&(R.yylloc={});var dt=R.yylloc;o.push(dt);var ci=R.options&&R.options.ranges;typeof X.yy.parseError=="function"?this.parseError=X.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function gi(B){x.length-=2*B,k.length-=B,o.length-=B}n(gi,"popStack");function It(){var B=u.pop()||R.lex()||Mt;return typeof B!="number"&&(B instanceof Array&&(u=B,B=u.pop()),B=A.symbols_[B]||B),B}n(It,"lex");for(var I,pt,N,$,ft,H={},lt,W,$t,ct;;){if(N=x[x.length-1],this.defaultActions[N]?$=this.defaultActions[N]:(I??(I=It()),$=at[N]&&at[N][I]),$===void 0||!$.length||!$[0]){var Bt="";for(lt in ct=[],at[N])this.terminals_[lt]&&lt>ri&&ct.push("'"+this.terminals_[lt]+"'");Bt=R.showPosition?"Parse error on line "+(rt+1)+`:
2
2
  `+R.showPosition()+`
3
3
  Expecting `+ct.join(", ")+", got '"+(this.terminals_[I]||I)+"'":"Parse error on line "+(rt+1)+": Unexpected "+(I==Mt?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(Bt,{text:R.match,token:this.terminals_[I]||I,line:R.yylineno,loc:dt,expected:ct})}if($[0]instanceof Array&&$.length>1)throw Error("Parse Error: multiple actions possible at state: "+N+", token: "+I);switch($[0]){case 1:x.push(I),k.push(R.yytext),o.push(R.yylloc),x.push($[1]),I=null,pt?(I=pt,pt=null):(vt=R.yyleng,d=R.yytext,rt=R.yylineno,dt=R.yylloc,Et>0&&Et--);break;case 2:if(W=this.productions_[$[1]][1],H.$=k[k.length-W],H._$={first_line:o[o.length-(W||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(W||1)].first_column,last_column:o[o.length-1].last_column},ci&&(H._$.range=[o[o.length-(W||1)].range[0],o[o.length-1].range[1]]),ft=this.performAction.apply(H,[d,vt,rt,X.yy,$[1],k,o].concat(li)),ft!==void 0)return ft;W&&(x=x.slice(0,-1*W*2),k=k.slice(0,-1*W),o=o.slice(0,-1*W)),x.push(this.productions_[$[1]][0]),k.push(H.$),o.push(H._$),$t=at[x[x.length-2]][x[x.length-1]],x.push($t);break;case 3:return!0}}return!0},"parse")};U.lexer=(function(){return{EOF:1,parseError:n(function(h,A){if(this.yy.parser)this.yy.parser.parseError(h,A);else throw Error(h)},"parseError"),setInput:n(function(h,A){return this.yy=A||this.yy||{},this._input=h,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:n(function(){var h=this._input[0];return this.yytext+=h,this.yyleng++,this.offset++,this.match+=h,this.matched+=h,h.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),h},"input"),unput:n(function(h){var A=h.length,x=h.split(/(?:\r\n?|\n)/g);this._input=h+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-A),this.offset-=A;var u=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),x.length-1&&(this.yylineno-=x.length-1);var k=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:x?(x.length===u.length?this.yylloc.first_column:0)+u[u.length-x.length].length-x[0].length:this.yylloc.first_column-A},this.options.ranges&&(this.yylloc.range=[k[0],k[0]+this.yyleng-A]),this.yyleng=this.yytext.length,this},"unput"),more:n(function(){return this._more=!0,this},"more"),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:n(function(h){this.unput(this.match.slice(h))},"less"),pastInput:n(function(){var h=this.matched.substr(0,this.matched.length-this.match.length);return(h.length>20?"...":"")+h.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:n(function(){var h=this.match;return h.length<20&&(h+=this._input.substr(0,20-h.length)),(h.substr(0,20)+(h.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:n(function(){var h=this.pastInput(),A=Array(h.length+1).join("-");return h+this.upcomingInput()+`
package/dist/index.html CHANGED
@@ -66,7 +66,7 @@
66
66
  <marimo-server-token data-token="{{ server_token }}" hidden></marimo-server-token>
67
67
  <!-- /TODO -->
68
68
  <title>{{ title }}</title>
69
- <script type="module" crossorigin src="./assets/index-U7La6ZBB.js"></script>
69
+ <script type="module" crossorigin src="./assets/index-CxrD-UyN.js"></script>
70
70
  <link rel="modulepreload" crossorigin href="./assets/preload-helper-DItdS47A.js">
71
71
  <link rel="modulepreload" crossorigin href="./assets/clsx-D8GwTfvk.js">
72
72
  <link rel="modulepreload" crossorigin href="./assets/cn-BKtXLv3a.js">
@@ -137,32 +137,32 @@
137
137
  <link rel="modulepreload" crossorigin href="./assets/spinner-DA8-7wQv.js">
138
138
  <link rel="modulepreload" crossorigin href="./assets/chevron-right--18M_6o9.js">
139
139
  <link rel="modulepreload" crossorigin href="./assets/dropdown-menu-BUgFWmX1.js">
140
- <link rel="modulepreload" crossorigin href="./assets/kbd-Cm6Ba9qg.js">
141
- <link rel="modulepreload" crossorigin href="./assets/renderShortcut-B1jzzLJw.js">
142
- <link rel="modulepreload" crossorigin href="./assets/multi-map-t2yhdp8D.js">
143
- <link rel="modulepreload" crossorigin href="./assets/alert-BOoN6gJ1.js">
140
+ <link rel="modulepreload" crossorigin href="./assets/kbd-k3Sn_RwW.js">
141
+ <link rel="modulepreload" crossorigin href="./assets/renderShortcut-Xr6z-RjZ.js">
142
+ <link rel="modulepreload" crossorigin href="./assets/multi-map-A4XNra08.js">
143
+ <link rel="modulepreload" crossorigin href="./assets/alert-Cx8eFRUM.js">
144
144
  <link rel="modulepreload" crossorigin href="./assets/card-DdlNjkEA.js">
145
145
  <link rel="modulepreload" crossorigin href="./assets/alert-dialog-Ctz24SMn.js">
146
146
  <link rel="modulepreload" crossorigin href="./assets/dialog-tQELcltn.js">
147
- <link rel="modulepreload" crossorigin href="./assets/dist-CDXJRSCj.js">
148
- <link rel="modulepreload" crossorigin href="./assets/label-C9wP7Kp2.js">
147
+ <link rel="modulepreload" crossorigin href="./assets/dist-BMEHQAhk.js">
148
+ <link rel="modulepreload" crossorigin href="./assets/label-C--1sWU6.js">
149
149
  <link rel="modulepreload" crossorigin href="./assets/useDebounce-B28kFfrM.js">
150
- <link rel="modulepreload" crossorigin href="./assets/textarea-8F9GOEGf.js">
150
+ <link rel="modulepreload" crossorigin href="./assets/textarea-B9TY02t9.js">
151
151
  <link rel="modulepreload" crossorigin href="./assets/numbers-UHLm3mA-.js">
152
152
  <link rel="modulepreload" crossorigin href="./assets/SSRProvider-DrpctNAg.js">
153
153
  <link rel="modulepreload" crossorigin href="./assets/context-Ga_vV5mE.js">
154
154
  <link rel="modulepreload" crossorigin href="./assets/useNumberFormatter-BX4DTYtT.js">
155
155
  <link rel="modulepreload" crossorigin href="./assets/usePress-3CRs0fQg.js">
156
156
  <link rel="modulepreload" crossorigin href="./assets/input-DHHmNa19.js">
157
- <link rel="modulepreload" crossorigin href="./assets/links-7AQBmdyV.js">
157
+ <link rel="modulepreload" crossorigin href="./assets/links-fh_IXIKE.js">
158
158
  <link rel="modulepreload" crossorigin href="./assets/popover-B-131r4d.js">
159
159
  <link rel="modulepreload" crossorigin href="./assets/switch-BUKXfBTu.js">
160
- <link rel="modulepreload" crossorigin href="./assets/table-DScsXgJW.js">
160
+ <link rel="modulepreload" crossorigin href="./assets/table-BOsFCeLh.js">
161
161
  <link rel="modulepreload" crossorigin href="./assets/mode-CjmQoGEk.js">
162
- <link rel="modulepreload" crossorigin href="./assets/useAsyncData-BMGLSTg8.js">
162
+ <link rel="modulepreload" crossorigin href="./assets/useAsyncData-CgmD3hjw.js">
163
163
  <link rel="modulepreload" crossorigin href="./assets/errors-CPlNr33a.js">
164
- <link rel="modulepreload" crossorigin href="./assets/error-banner-Dlrzo_Ay.js">
165
- <link rel="modulepreload" crossorigin href="./assets/copy-DHrHayPa.js">
164
+ <link rel="modulepreload" crossorigin href="./assets/error-banner-w4pz2qUB.js">
165
+ <link rel="modulepreload" crossorigin href="./assets/copy-BaRrAFL-.js">
166
166
  <link rel="modulepreload" crossorigin href="./assets/memoize-BCOZVFBt.js">
167
167
  <link rel="modulepreload" crossorigin href="./assets/get-6uJrSKbw.js">
168
168
  <link rel="modulepreload" crossorigin href="./assets/capitalize-CmNnkG9y.js">
@@ -171,79 +171,79 @@
171
171
  <link rel="modulepreload" crossorigin href="./assets/refresh-cw-Dx8TEWFP.js">
172
172
  <link rel="modulepreload" crossorigin href="./assets/trash-2-B8SQYdQq.js">
173
173
  <link rel="modulepreload" crossorigin href="./assets/triangle-alert-U93NZYDl.js">
174
- <link rel="modulepreload" crossorigin href="./assets/ai-model-dropdown-CODXtvnr.js">
175
- <link rel="modulepreload" crossorigin href="./assets/defaultLocale-JieDVWC_.js">
176
- <link rel="modulepreload" crossorigin href="./assets/precisionRound-CU2C3Vxx.js">
177
- <link rel="modulepreload" crossorigin href="./assets/defaultLocale-BLne0bXb.js">
178
- <link rel="modulepreload" crossorigin href="./assets/vega-loader.browser-DXARUlxo.js">
179
- <link rel="modulepreload" crossorigin href="./assets/tooltip-DxKBXCGp.js">
174
+ <link rel="modulepreload" crossorigin href="./assets/ai-model-dropdown-D8AFYZjU.js">
175
+ <link rel="modulepreload" crossorigin href="./assets/defaultLocale-YteS-k_t.js">
176
+ <link rel="modulepreload" crossorigin href="./assets/precisionRound-C3fmBb6j.js">
177
+ <link rel="modulepreload" crossorigin href="./assets/defaultLocale-B6z1Qyqt.js">
178
+ <link rel="modulepreload" crossorigin href="./assets/vega-loader.browser-BegSZk0G.js">
179
+ <link rel="modulepreload" crossorigin href="./assets/tooltip-DqsDDLgU.js">
180
180
  <link rel="modulepreload" crossorigin href="./assets/ErrorBoundary-B9Ifj8Jf.js">
181
- <link rel="modulepreload" crossorigin href="./assets/useInstallPackage-xrG_Tm9T.js">
181
+ <link rel="modulepreload" crossorigin href="./assets/useInstallPackage-Co79H1lQ.js">
182
182
  <link rel="modulepreload" crossorigin href="./assets/ImperativeModal-DZr52ffu.js">
183
- <link rel="modulepreload" crossorigin href="./assets/cell-link-BoOn0OpK.js">
184
- <link rel="modulepreload" crossorigin href="./assets/datasource-Dkywo3Kg.js">
183
+ <link rel="modulepreload" crossorigin href="./assets/cell-link-DfoJF6Bq.js">
184
+ <link rel="modulepreload" crossorigin href="./assets/datasource-Bl1__6xJ.js">
185
185
  <link rel="modulepreload" crossorigin href="./assets/state-DlF73owK.js">
186
- <link rel="modulepreload" crossorigin href="./assets/MarimoErrorOutput-DrTj9k_Z.js">
187
- <link rel="modulepreload" crossorigin href="./assets/copy-icon-B9w72gBC.js">
188
- <link rel="modulepreload" crossorigin href="./assets/html-to-image-DrmKVKna.js">
189
- <link rel="modulepreload" crossorigin href="./assets/focus-BEf2RhRf.js">
190
- <link rel="modulepreload" crossorigin href="./assets/LazyAnyLanguageCodeMirror-CQP8KZWO.js">
191
- <link rel="modulepreload" crossorigin href="./assets/chunk-5FQGJX7Z-CwvgJCug.js">
192
- <link rel="modulepreload" crossorigin href="./assets/katex-CDLTCvjQ.js">
193
- <link rel="modulepreload" crossorigin href="./assets/markdown-renderer-D8AmLSIR.js">
194
- <link rel="modulepreload" crossorigin href="./assets/command-PbcrObnK.js">
195
- <link rel="modulepreload" crossorigin href="./assets/download-CmdFQXRz.js">
196
- <link rel="modulepreload" crossorigin href="./assets/useRunCells-BOowME8Z.js">
197
- <link rel="modulepreload" crossorigin href="./assets/purify.es-DZrAQFIu.js">
198
- <link rel="modulepreload" crossorigin href="./assets/RenderHTML-D9vJ9neG.js">
199
- <link rel="modulepreload" crossorigin href="./assets/useIframeCapabilities-B_pQb20b.js">
200
- <link rel="modulepreload" crossorigin href="./assets/formats-CobRswjh.js">
186
+ <link rel="modulepreload" crossorigin href="./assets/MarimoErrorOutput-DVEiP1Ym.js">
187
+ <link rel="modulepreload" crossorigin href="./assets/copy-icon-C9v8EtBA.js">
188
+ <link rel="modulepreload" crossorigin href="./assets/html-to-image-BIY1TtH0.js">
189
+ <link rel="modulepreload" crossorigin href="./assets/focus-RQ0afibT.js">
190
+ <link rel="modulepreload" crossorigin href="./assets/LazyAnyLanguageCodeMirror-BqosdyZU.js">
191
+ <link rel="modulepreload" crossorigin href="./assets/chunk-5FQGJX7Z-T2jyw7ZD.js">
192
+ <link rel="modulepreload" crossorigin href="./assets/katex-CbllUrnh.js">
193
+ <link rel="modulepreload" crossorigin href="./assets/markdown-renderer-Md8pHWxP.js">
194
+ <link rel="modulepreload" crossorigin href="./assets/command-BpjkI15h.js">
195
+ <link rel="modulepreload" crossorigin href="./assets/download-s-BdZdTz.js">
196
+ <link rel="modulepreload" crossorigin href="./assets/useRunCells-BJznEpzj.js">
197
+ <link rel="modulepreload" crossorigin href="./assets/purify.es-B-nzWya6.js">
198
+ <link rel="modulepreload" crossorigin href="./assets/RenderHTML-Bj4DW3wy.js">
199
+ <link rel="modulepreload" crossorigin href="./assets/useIframeCapabilities-CC8VH6kZ.js">
200
+ <link rel="modulepreload" crossorigin href="./assets/formats-DGZwRUPy.js">
201
201
  <link rel="modulepreload" crossorigin href="./assets/en-US-DU2jJCpg.js">
202
202
  <link rel="modulepreload" crossorigin href="./assets/isValid-DpSSOU5z.js">
203
203
  <link rel="modulepreload" crossorigin href="./assets/dates-CT5PUuFo.js">
204
204
  <link rel="modulepreload" crossorigin href="./assets/maps-D2_Mq1pZ.js">
205
- <link rel="modulepreload" crossorigin href="./assets/extends-BiFDv3jB.js">
206
- <link rel="modulepreload" crossorigin href="./assets/emotion-is-prop-valid.esm-C59xfSYt.js">
205
+ <link rel="modulepreload" crossorigin href="./assets/extends-Dqvpuc10.js">
206
+ <link rel="modulepreload" crossorigin href="./assets/emotion-is-prop-valid.esm-Dangy3Bv.js">
207
207
  <link rel="modulepreload" crossorigin href="./assets/useDateFormatter-CieT0-H-.js">
208
208
  <link rel="modulepreload" crossorigin href="./assets/range-D2UKkEg-.js">
209
209
  <link rel="modulepreload" crossorigin href="./assets/table-CfDbAm78.js">
210
- <link rel="modulepreload" crossorigin href="./assets/JsonOutput-DsO4felE.js">
210
+ <link rel="modulepreload" crossorigin href="./assets/JsonOutput-BPSYj_Kn.js">
211
211
  <link rel="modulepreload" crossorigin href="./assets/file-Ch78NKWp.js">
212
212
  <link rel="modulepreload" crossorigin href="./assets/play-GLWQQs7F.js">
213
213
  <link rel="modulepreload" crossorigin href="./assets/chat-components-C2rqCcnp.js">
214
214
  <link rel="modulepreload" crossorigin href="./assets/isEmpty-CgX_-6Mt.js">
215
- <link rel="modulepreload" crossorigin href="./assets/chat-display-BnUDaREA.js">
216
- <link rel="modulepreload" crossorigin href="./assets/useDeleteCell-DHPNhAtW.js">
215
+ <link rel="modulepreload" crossorigin href="./assets/chat-display-letMHFni.js">
216
+ <link rel="modulepreload" crossorigin href="./assets/useDeleteCell-DyGTLzfg.js">
217
217
  <link rel="modulepreload" crossorigin href="./assets/icons-DjR3qLG_.js">
218
- <link rel="modulepreload" crossorigin href="./assets/process-output-OTqBNunj.js">
219
- <link rel="modulepreload" crossorigin href="./assets/blob-t6qcPM7K.js">
220
- <link rel="modulepreload" crossorigin href="./assets/objectWithoutPropertiesLoose-DfWeGRFv.js">
221
- <link rel="modulepreload" crossorigin href="./assets/esm-C-53tlK5.js">
222
- <link rel="modulepreload" crossorigin href="./assets/add-cell-with-ai-CPu9tI-Q.js">
218
+ <link rel="modulepreload" crossorigin href="./assets/process-output-C77tRi36.js">
219
+ <link rel="modulepreload" crossorigin href="./assets/blob-Bgnx1kuY.js">
220
+ <link rel="modulepreload" crossorigin href="./assets/objectWithoutPropertiesLoose-DoKw85w0.js">
221
+ <link rel="modulepreload" crossorigin href="./assets/esm-BK6tLEHQ.js">
222
+ <link rel="modulepreload" crossorigin href="./assets/add-cell-with-ai-dpMkH_5a.js">
223
223
  <link rel="modulepreload" crossorigin href="./assets/chart-no-axes-column-qvVRjhv1.js">
224
224
  <link rel="modulepreload" crossorigin href="./assets/square-function-B6mgCeFJ.js">
225
225
  <link rel="modulepreload" crossorigin href="./assets/spec-Ch0xnJY4.js">
226
- <link rel="modulepreload" crossorigin href="./assets/column-preview-Bz3KIcIX.js">
226
+ <link rel="modulepreload" crossorigin href="./assets/column-preview-BEosUUWh.js">
227
227
  <link rel="modulepreload" crossorigin href="./assets/toggle-CriARMQK.js">
228
228
  <link rel="modulepreload" crossorigin href="./assets/globals-BXYmO-WL.js">
229
229
  <link rel="modulepreload" crossorigin href="./assets/share-rXkgGlhr.js">
230
230
  <link rel="modulepreload" crossorigin href="./assets/_baseSet-5Rdwpmr3.js">
231
231
  <link rel="modulepreload" crossorigin href="./assets/react-resizable-panels.browser.esm-Mq45xjWt.js">
232
- <link rel="modulepreload" crossorigin href="./assets/utilities.esm-AIy-_q0N.js">
232
+ <link rel="modulepreload" crossorigin href="./assets/utilities.esm-BREvtThv.js">
233
233
  <link rel="modulepreload" crossorigin href="./assets/floating-outline-BULIQxKU.js">
234
- <link rel="modulepreload" crossorigin href="./assets/useAddCell-Cx99GRHQ.js">
234
+ <link rel="modulepreload" crossorigin href="./assets/useAddCell-C0mjPsjt.js">
235
235
  <link rel="modulepreload" crossorigin href="./assets/eye-off-AK_9uodG.js">
236
- <link rel="modulepreload" crossorigin href="./assets/readonly-python-code-C_8a4fwz.js">
236
+ <link rel="modulepreload" crossorigin href="./assets/readonly-python-code-q8H4JtWe.js">
237
237
  <link rel="modulepreload" crossorigin href="./assets/file-video-camera-C3wGzBnE.js">
238
238
  <link rel="modulepreload" crossorigin href="./assets/types-7nV0hgXj.js">
239
239
  <link rel="modulepreload" crossorigin href="./assets/refresh-ccw-DN_xCV6A.js">
240
- <link rel="modulepreload" crossorigin href="./assets/form-94alAnRh.js">
240
+ <link rel="modulepreload" crossorigin href="./assets/form-CNEyFLKK.js">
241
241
  <link rel="modulepreload" crossorigin href="./assets/field-D9jE8HEt.js">
242
242
  <link rel="modulepreload" crossorigin href="./assets/useBoolean-IZsSX_XF.js">
243
- <link rel="modulepreload" crossorigin href="./assets/useDeepCompareMemoize-ChxLMT9E.js">
243
+ <link rel="modulepreload" crossorigin href="./assets/useDeepCompareMemoize-CFtQU7An.js">
244
244
  <link rel="modulepreload" crossorigin href="./assets/types-C1UhS3qM.js">
245
- <link rel="modulepreload" crossorigin href="./assets/prop-types-DaaA-ptl.js">
246
- <link rel="modulepreload" crossorigin href="./assets/es-CerBf9Z6.js">
245
+ <link rel="modulepreload" crossorigin href="./assets/prop-types-DVDiRdwc.js">
246
+ <link rel="modulepreload" crossorigin href="./assets/es-GXAIFcot.js">
247
247
  <link rel="modulepreload" crossorigin href="./assets/hasIn-CycJImp8.js">
248
248
  <link rel="modulepreload" crossorigin href="./assets/_baseFlatten-CUZNxU8H.js">
249
249
  <link rel="modulepreload" crossorigin href="./assets/flatten-D-7VEN0q.js">
@@ -257,7 +257,7 @@
257
257
  <link rel="stylesheet" crossorigin href="./assets/cells-jmgGt1lS.css">
258
258
  <link rel="stylesheet" crossorigin href="./assets/markdown-renderer-DdDKmWlR.css">
259
259
  <link rel="stylesheet" crossorigin href="./assets/JsonOutput-B7vuddcd.css">
260
- <link rel="stylesheet" crossorigin href="./assets/index-BTVKRPtt.css">
260
+ <link rel="stylesheet" crossorigin href="./assets/index-3CaNzO41.css">
261
261
  </head>
262
262
  <body>
263
263
  <div id="root"></div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marimo-team/frontend",
3
- "version": "0.19.8-dev21",
3
+ "version": "0.19.8-dev24",
4
4
  "main": "dist/main.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "type": "module",