@marimo-team/islands 0.15.2 → 0.15.3

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 (189) hide show
  1. package/dist/{ConnectedDataExplorerComponent-C39nQwtD.js → ConnectedDataExplorerComponent-DfvW3rBn.js} +323 -328
  2. package/dist/{ImageComparisonComponent-BhkiyswP.js → ImageComparisonComponent-XaJshw7d.js} +13 -13
  3. package/dist/{_baseUniq-DdHL34FO.js → _baseUniq-dN9WKF9m.js} +67 -67
  4. package/dist/any-language-editor-CpFniVi-.js +27 -0
  5. package/dist/{arc-BXrety1g.js → arc-BOhn-m2C.js} +1 -1
  6. package/dist/{architectureDiagram-KFL7JDKH-BMy6ywCF.js → architectureDiagram-W76B3OCA-Bpg85ZKv.js} +144 -144
  7. package/dist/assets/{worker-COGufAQn.js → worker-Y-Q4G-N2.js} +30 -26
  8. package/dist/asterisk-DS281yxp.js +271 -0
  9. package/dist/{blockDiagram-ZYB65J3Q-DYT2-nlI.js → blockDiagram-QIGZ2CNN-DS1kOHlW.js} +10 -10
  10. package/dist/{c4Diagram-AAMF2YG6-ZiQzioe6.js → c4Diagram-FPNF74CW-CyRVKssw.js} +8 -8
  11. package/dist/{channel-CeuXqUAU.js → channel-BilGXox7.js} +1 -1
  12. package/dist/{chunk-ANTBXLJU-BvYnIrdq.js → chunk-4BX2VUAB-CZR39zCO.js} +1 -1
  13. package/dist/{chunk-WVR4S24B-DXj8yaUk.js → chunk-55IACEB6-BIH-MYov.js} +1 -1
  14. package/dist/{chunk-GLLZNHP4-CyFsosAe.js → chunk-FMBD7UC4-4PZXFZE8.js} +1 -1
  15. package/dist/{chunk-JBRWN2VN-DA_EEhy2.js → chunk-K7UQS3LO-CEvWKznk.js} +117 -117
  16. package/dist/{chunk-NRVI72HA-BYx2jMlI.js → chunk-QN33PNHL-D5LO5Jq_.js} +1 -1
  17. package/dist/{chunk-FHKO5MBM-DfCztBk8.js → chunk-QZHKN3VN-6gwUonWI.js} +1 -1
  18. package/dist/{chunk-LXBSTHXV-Se7vdY6J.js → chunk-TVAH2DTR-3gm06QdU.js} +7 -7
  19. package/dist/{chunk-OMD6QJNC-CqgcPMgL.js → chunk-TZMSLE5B-Cm8Iy9bO.js} +1 -1
  20. package/dist/{classDiagram-v2-QTMF73CY-B19A3G1l.js → classDiagram-KNZD7YFC-DC529O_z.js} +2 -2
  21. package/dist/{classDiagram-3BZAVTQC-B19A3G1l.js → classDiagram-v2-RKCZMP56-DC529O_z.js} +2 -2
  22. package/dist/{clone-78au0tn1.js → clone-CLoRX3j6.js} +1 -1
  23. package/dist/cose-bilkent-S5V4N54A-qf5DlS6Y.js +2609 -0
  24. package/dist/{cytoscape.esm-BYnVVhJX.js → cytoscape.esm-DfdJODL8.js} +34 -34
  25. package/dist/{dagre-2BBEFEWP-BfEn3ZUV.js → dagre-5GWH7T2D-Ceocls0m.js} +6 -6
  26. package/dist/{data-grid-overlay-editor-CH_qLkV2.js → data-grid-overlay-editor-AqDS_UKe.js} +11 -11
  27. package/dist/{diagram-4IRLE6MV-CL8xidnG.js → diagram-N5W7TBWH-CP66oSiv.js} +59 -60
  28. package/dist/{diagram-RP2FKANI-B1BPcUew.js → diagram-QEK2KX5R-_YD4kxxi.js} +15 -15
  29. package/dist/{diagram-GUPCWM2R-CZ5cfqlq.js → diagram-S2PKOQOG-Cnj8T-OP.js} +10 -10
  30. package/dist/dockerfile-Cm8cRYCN.js +194 -0
  31. package/dist/ebnf-DUPDuY4r.js +78 -0
  32. package/dist/{erDiagram-HZWUO2LU-BEAIww50.js → erDiagram-AWTI2OKA-CGnvoHx6.js} +8 -8
  33. package/dist/fcl-CPC2WYrI.js +103 -0
  34. package/dist/{flowDiagram-THRYKUMA-Czs2UAI2.js → flowDiagram-PVAE7QVJ-DG-pr9R9.js} +9 -9
  35. package/dist/{ganttDiagram-WV7ZQ7D5-ByYIAVFO.js → ganttDiagram-OWAHRB6G-JmChtxvn.js} +34 -34
  36. package/dist/{gitGraphDiagram-OJR772UL-BcpDsiyB.js → gitGraphDiagram-NY62KEGX-D8wLfOPd.js} +4 -4
  37. package/dist/{glide-data-editor-CmN6FVyi.js → glide-data-editor-9nC3iCIZ.js} +33 -33
  38. package/dist/{graph-77W6heli.js → graph-CoRe7vAN.js} +3 -3
  39. package/dist/http-D9LttvKF.js +44 -0
  40. package/dist/{index-Bfk9dnyS.js → index-6qYeHHjQ.js} +33090 -32892
  41. package/dist/{index-BOojn38D.js → index-BpzLh4Qe.js} +7711 -7711
  42. package/dist/{index-CmozKMxx.js → index-BthgsgYX.js} +6 -6
  43. package/dist/{index-pBmAzQJl.js → index-MCx5v1x0.js} +2 -2
  44. package/dist/index-jkm77Jrz.js +98 -0
  45. package/dist/{infoDiagram-6WOFNB3A-CfzLHHVP.js → infoDiagram-STP46IZ2-BlXxvOrR.js} +2 -2
  46. package/dist/{journeyDiagram-FFXJYRFH-ndAcpkGn.js → journeyDiagram-BIP6EPQ6-CNRYs_Fc.js} +24 -26
  47. package/dist/{kanban-definition-KOZQBZVT-DcQYzNvc.js → kanban-definition-6OIFK2YF-B9HeMAuP.js} +14 -14
  48. package/dist/{layout-XySVHJgD.js → layout-m2vOUiW1.js} +81 -81
  49. package/dist/{linear-PbooOqg7.js → linear-DU6Q5CX3.js} +35 -35
  50. package/dist/{main-B5yML0bw.js → main-BD2KGFpU.js} +74594 -68034
  51. package/dist/main.js +1 -1
  52. package/dist/{mermaid-Cg5IX6Nv.js → mermaid-HVCtvbyx.js} +6160 -7493
  53. package/dist/min-DcGMA4e_.js +80 -0
  54. package/dist/mindmap-definition-Q6HEUPPD-BW8UmIDQ.js +785 -0
  55. package/dist/nginx-zDPm3Z74.js +89 -0
  56. package/dist/{number-overlay-editor-DUhfZqtP.js → number-overlay-editor-D8Hl0Syo.js} +19 -19
  57. package/dist/{pieDiagram-DBDJKBY4-DTOlNsja.js → pieDiagram-ADFJNKIX-Bg-3zg5U.js} +17 -17
  58. package/dist/{quadrantDiagram-YPSRARAO-BX2d8VS-.js → quadrantDiagram-LMRXKWRM-BO4IG6Yz.js} +6 -6
  59. package/dist/{react-plotly-Dcyw-3Sa.js → react-plotly-dkvHVuRb.js} +3577 -3577
  60. package/dist/{requirementDiagram-EGVEC5DT-D1T5u-wG.js → requirementDiagram-4UW4RH46-5sdTguSM.js} +7 -7
  61. package/dist/{sankeyDiagram-HRAUVNP4-G6xDfnp-.js → sankeyDiagram-GR3RE2ED-Buhlv9OI.js} +5 -5
  62. package/dist/sequenceDiagram-C3RYC4MD-C3qsM2UP.js +2519 -0
  63. package/dist/{slides-component-BJLlPJSr.js → slides-component-D209A0-s.js} +66 -66
  64. package/dist/solr-BNlsLglM.js +41 -0
  65. package/dist/spreadsheet-C-cy4P5N.js +49 -0
  66. package/dist/{stateDiagram-UUKSUZ4H-CYXbjaom.js → stateDiagram-KXAO66HF-CopJ7G6P.js} +5 -5
  67. package/dist/{stateDiagram-v2-EYPG3UTE-Br1HYKT6.js → stateDiagram-v2-UMBNRL4Z-CejL8AKf.js} +2 -2
  68. package/dist/style.css +1 -1
  69. package/dist/tiddlywiki-5wqsXtSk.js +155 -0
  70. package/dist/tiki-__Kn3CeS.js +181 -0
  71. package/dist/{time-B9SZnSen.js → time-BwSBitlN.js} +58 -58
  72. package/dist/{timeline-definition-3HZDQTIS-DeK_ZRD0.js → timeline-definition-XQNQX7LJ-DzMNTX-C.js} +10 -12
  73. package/dist/{timer-BYwnU4DF.js → timer-B0-z63CM.js} +16 -16
  74. package/dist/{treemap-75Q7IDZK-CKP4vV_0.js → treemap-75Q7IDZK-zeJG07dk.js} +14 -14
  75. package/dist/{vega-component-CpgdqX2d.js → vega-component-CUkiTayd.js} +30 -30
  76. package/dist/{xychartDiagram-FDP5SA34-AMEPsx_R.js → xychartDiagram-6GGTOJPD-DiENNXMS.js} +7 -7
  77. package/package.json +39 -39
  78. package/src/__mocks__/notebook.ts +3 -0
  79. package/src/__mocks__/requests.ts +3 -0
  80. package/src/__tests__/__snapshots__/CellStatus.test.tsx.snap +12 -12
  81. package/src/__tests__/chat-utils.test.ts +26 -211
  82. package/src/components/ai/ai-model-dropdown.tsx +25 -9
  83. package/src/components/app-config/ai-config.tsx +7 -0
  84. package/src/components/chat/chat-components.tsx +71 -0
  85. package/src/components/chat/chat-panel.tsx +481 -291
  86. package/src/components/chat/chat-utils.ts +50 -0
  87. package/src/components/chat/markdown-renderer.tsx +3 -7
  88. package/src/components/chat/tool-call-accordion.tsx +5 -5
  89. package/src/components/datasources/__tests__/utils.test.ts +6 -0
  90. package/src/components/datasources/column-preview.tsx +1 -3
  91. package/src/components/editor/actions/useNotebookActions.tsx +1 -1
  92. package/src/components/editor/ai/add-cell-with-ai.tsx +20 -15
  93. package/src/components/editor/ai/ai-completion-editor.tsx +22 -3
  94. package/src/components/editor/ai/completion-handlers.tsx +2 -4
  95. package/src/components/editor/ai/completion-utils.ts +85 -11
  96. package/src/components/editor/alerts/startup-logs-alert.tsx +72 -0
  97. package/src/components/editor/chrome/panels/datasources-panel.tsx +3 -1
  98. package/src/components/editor/chrome/panels/dependency-graph-panel.tsx +3 -1
  99. package/src/components/editor/chrome/panels/documentation-panel.tsx +3 -1
  100. package/src/components/editor/chrome/panels/error-panel.tsx +3 -1
  101. package/src/components/editor/chrome/panels/file-explorer-panel.tsx +3 -1
  102. package/src/components/editor/chrome/panels/logs-panel.tsx +3 -1
  103. package/src/components/editor/chrome/panels/outline-panel.tsx +3 -1
  104. package/src/components/editor/chrome/panels/packages-panel.tsx +4 -2
  105. package/src/components/editor/chrome/panels/scratchpad-panel.tsx +3 -1
  106. package/src/components/editor/chrome/panels/secrets-panel.tsx +3 -1
  107. package/src/components/editor/chrome/panels/snippets-panel.tsx +3 -1
  108. package/src/components/editor/chrome/panels/tracing-panel.tsx +3 -1
  109. package/src/components/editor/chrome/panels/variable-panel.tsx +3 -1
  110. package/src/components/editor/chrome/wrapper/app-chrome.tsx +38 -28
  111. package/src/components/editor/controls/command-palette-button.tsx +1 -1
  112. package/src/components/editor/controls/command-palette.tsx +5 -4
  113. package/src/components/editor/controls/state.ts +4 -0
  114. package/src/components/editor/package-alert.tsx +108 -58
  115. package/src/components/editor/renderers/CellArray.tsx +2 -0
  116. package/src/components/editor/renderers/vertical-layout/vertical-layout.tsx +0 -1
  117. package/src/components/pages/edit-page.tsx +7 -3
  118. package/src/core/ai/chat-utils.ts +26 -43
  119. package/src/core/ai/config.ts +1 -1
  120. package/src/core/ai/context/__tests__/registry.test.ts +277 -3
  121. package/src/core/ai/context/context.ts +11 -1
  122. package/src/core/ai/context/providers/__tests__/cell-output.test.ts +378 -0
  123. package/src/core/ai/context/providers/__tests__/error.test.ts +3 -2
  124. package/src/core/ai/context/providers/__tests__/file.test.ts +119 -0
  125. package/src/core/ai/context/providers/cell-output.ts +349 -0
  126. package/src/core/ai/context/providers/common.ts +5 -1
  127. package/src/core/ai/context/providers/file.ts +287 -0
  128. package/src/core/ai/context/registry.ts +79 -0
  129. package/src/core/ai/state.ts +22 -5
  130. package/src/core/alerts/state.ts +71 -3
  131. package/src/core/cells/cell.ts +2 -2
  132. package/src/core/cells/cells.ts +1 -1
  133. package/src/core/cells/logs.ts +1 -1
  134. package/src/core/cells/runs.ts +6 -5
  135. package/src/core/codemirror/ai/resources.ts +47 -5
  136. package/src/core/codemirror/ai/state.ts +12 -0
  137. package/src/core/codemirror/language/__tests__/sql.test.ts +45 -0
  138. package/src/core/codemirror/markdown/__tests__/commands.test.ts +1 -0
  139. package/src/core/codemirror/theme/dark.ts +1 -1
  140. package/src/core/config/capabilities.ts +1 -1
  141. package/src/core/datasets/__tests__/data-source.test.ts +24 -0
  142. package/src/core/errors/__tests__/errors.test.ts +2 -0
  143. package/src/core/islands/bridge.ts +1 -0
  144. package/src/core/islands/main.ts +1 -0
  145. package/src/core/kernel/messages.ts +12 -6
  146. package/src/core/layout/layout.ts +3 -3
  147. package/src/core/network/requests-network.ts +8 -0
  148. package/src/core/network/requests-static.ts +1 -0
  149. package/src/core/network/requests-toasting.ts +1 -0
  150. package/src/core/network/types.ts +4 -1
  151. package/src/core/wasm/bridge.ts +18 -2
  152. package/src/core/wasm/worker/bootstrap.ts +3 -1
  153. package/src/core/wasm/worker/getMarimoWheel.ts +3 -8
  154. package/src/core/wasm/worker/types.ts +3 -0
  155. package/src/core/websocket/useMarimoWebSocket.tsx +7 -1
  156. package/src/css/app/Cell.css +42 -21
  157. package/src/css/app/codemirror.css +5 -1
  158. package/src/css/globals.css +3 -0
  159. package/src/css/md.css +1 -1
  160. package/src/plugins/impl/MicrophonePlugin.tsx +2 -2
  161. package/src/plugins/impl/chat/ChatPlugin.tsx +2 -9
  162. package/src/plugins/impl/chat/chat-ui.tsx +129 -110
  163. package/src/plugins/impl/chat/types.ts +5 -8
  164. package/src/plugins/impl/code/__tests__/language.test.ts +15 -0
  165. package/src/plugins/impl/code/any-language-editor.tsx +11 -8
  166. package/src/plugins/layout/MimeRenderPlugin.tsx +3 -6
  167. package/src/stories/cell.stories.tsx +6 -0
  168. package/src/stories/layout/vertical/one-column.stories.tsx +215 -0
  169. package/src/theme/useTheme.ts +11 -6
  170. package/src/utils/__tests__/blob.test.ts +37 -0
  171. package/src/utils/arrays.ts +13 -0
  172. package/src/utils/fileToBase64.ts +21 -6
  173. package/src/utils/json/base64.ts +5 -2
  174. package/src/utils/numbers.ts +9 -7
  175. package/dist/any-language-editor-DC5170DQ.js +0 -45
  176. package/dist/asn1-jKiBa2Ya.js +0 -95
  177. package/dist/clojure-CCKyeQKf.js +0 -800
  178. package/dist/css-BkF-NPzE.js +0 -1553
  179. package/dist/index-5ZH_qS8j.js +0 -288
  180. package/dist/index-U4yn89qO.js +0 -341
  181. package/dist/javascript-C2yteZeJ.js +0 -691
  182. package/dist/min-DS5Jz-hg.js +0 -80
  183. package/dist/mindmap-definition-LNHGMQRG-0aOVaMR8.js +0 -3234
  184. package/dist/mllike-BSnXJBGA.js +0 -272
  185. package/dist/pug-CwAQJzGR.js +0 -248
  186. package/dist/python-BkR3uSy8.js +0 -313
  187. package/dist/rpm-IznJm2Xc.js +0 -57
  188. package/dist/sequenceDiagram-WFGC7UMF-DMhHzllb.js +0 -2284
  189. package/dist/ttcn-cfg-Bac_acMi.js +0 -88
@@ -652,7 +652,7 @@ var Vc = Fc(), Fa = /* @__PURE__ */ Oa(Vc), ci = rr ? rr.performance : null, lv
652
652
  return ci.now();
653
653
  } : function() {
654
654
  return Date.now();
655
- }, qc = function() {
655
+ }, qc = (function() {
656
656
  if (rr) {
657
657
  if (rr.requestAnimationFrame)
658
658
  return function(r) {
@@ -676,7 +676,7 @@ var Vc = Fc(), Fa = /* @__PURE__ */ Oa(Vc), ci = rr ? rr.performance : null, lv
676
676
  r(lv());
677
677
  }, 1e3 / 60);
678
678
  };
679
- }(), wn = function(e) {
679
+ })(), wn = function(e) {
680
680
  return qc(e);
681
681
  }, Yr = lv, Tt = 9261, vv = 65599, Ht = 5381, fv = function(e) {
682
682
  for (var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : Tt, a = t, n; n = e.next(), !n.done; )
@@ -807,7 +807,7 @@ var _o = true, Uc = console.warn != null, Kc = console.trace != null, Js = Numbe
807
807
  return a && (t = av(a, t)), e[t];
808
808
  }, Kr = function(e, t, a, n) {
809
809
  a && (t = av(a, t)), e[t] = n;
810
- }, Jc = /* @__PURE__ */ function() {
810
+ }, Jc = /* @__PURE__ */ (function() {
811
811
  function r() {
812
812
  ht(this, r), this._obj = {};
813
813
  }
@@ -837,7 +837,7 @@ var _o = true, Uc = console.warn != null, Kc = console.trace != null, Js = Numbe
837
837
  return this._obj[t];
838
838
  }
839
839
  }]);
840
- }(), Xr = typeof Map < "u" ? Map : Jc, jc = "undefined", ed = /* @__PURE__ */ function() {
840
+ })(), Xr = typeof Map < "u" ? Map : Jc, jc = "undefined", ed = /* @__PURE__ */ (function() {
841
841
  function r(e) {
842
842
  if (ht(this, r), this._obj = /* @__PURE__ */ Object.create(null), this.size = 0, e != null) {
843
843
  var t;
@@ -887,7 +887,7 @@ var _o = true, Uc = console.warn != null, Kc = console.trace != null, Js = Numbe
887
887
  return this.toArray().forEach(t, a);
888
888
  }
889
889
  }]);
890
- }(), ra = (typeof Set > "u" ? "undefined" : ar(Set)) !== jc ? Set : ed, In = function(e, t) {
890
+ })(), ra = (typeof Set > "u" ? "undefined" : ar(Set)) !== jc ? Set : ed, In = function(e, t) {
891
891
  var a = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : true;
892
892
  if (e === void 0 || t === void 0 || !Ys(e)) {
893
893
  $e("An element must have a core reference and parameters set");
@@ -1062,7 +1062,7 @@ Sa.bfs = Sa.breadthFirstSearch;
1062
1062
  Sa.dfs = Sa.depthFirstSearch;
1063
1063
  var on = { exports: {} }, rd = on.exports, Wo;
1064
1064
  function td() {
1065
- return Wo || (Wo = 1, function(r, e) {
1065
+ return Wo || (Wo = 1, (function(r, e) {
1066
1066
  (function() {
1067
1067
  var t, a, n, i, s, o, l, u, v, f, c, h, d, y, g;
1068
1068
  n = Math.floor, f = Math.min, a = function(p, m) {
@@ -1133,7 +1133,7 @@ function td() {
1133
1133
  for (b == null && (b = a), E = p.length, T = m, C = p[m], w = 2 * m + 1; w < E; )
1134
1134
  x = w + 1, x < E && !(b(p[w], p[x]) < 0) && (w = x), p[m] = p[w], m = w, w = 2 * m + 1;
1135
1135
  return p[m] = C, y(p, T, m, b);
1136
- }, t = function() {
1136
+ }, t = (function() {
1137
1137
  p.push = o, p.pop = s, p.replace = u, p.pushpop = l, p.heapify = i, p.updateItem = d, p.nlargest = c, p.nsmallest = h;
1138
1138
  function p(m) {
1139
1139
  this.cmp = m ?? a, this.nodes = [];
@@ -1166,13 +1166,13 @@ function td() {
1166
1166
  }, p.prototype.toArray = function() {
1167
1167
  return this.nodes.slice(0);
1168
1168
  }, p.prototype.insert = p.prototype.push, p.prototype.top = p.prototype.peek, p.prototype.front = p.prototype.peek, p.prototype.has = p.prototype.contains, p.prototype.copy = p.prototype.clone, p;
1169
- }(), function(p, m) {
1169
+ })(), (function(p, m) {
1170
1170
  return r.exports = m();
1171
- }(this, function() {
1171
+ })(this, function() {
1172
1172
  return t;
1173
1173
  });
1174
1174
  }).call(rd);
1175
- }(on)), on.exports;
1175
+ })(on)), on.exports;
1176
1176
  }
1177
1177
  var di, $o;
1178
1178
  function ad() {
@@ -1843,7 +1843,7 @@ var wv = function(e, t, a, n, i, s, o) {
1843
1843
  }
1844
1844
  l = -l, v = l * l * l, v = Math.acos(u / Math.sqrt(v)), d = 2 * Math.sqrt(l), i[0] = -h + d * Math.cos(v / 3), i[2] = -h + d * Math.cos((v + 2 * Math.PI) / 3), i[4] = -h + d * Math.cos((v + 4 * Math.PI) / 3);
1845
1845
  }, Od = function(e, t, a, n, i, s, o, l) {
1846
- var u = 1 * a * a - 4 * a * i + 2 * a * o + 4 * i * i - 4 * i * o + o * o + n * n - 4 * n * s + 2 * n * l + 4 * s * s - 4 * s * l + l * l, v = 1 * 9 * a * i - 3 * a * a - 3 * a * o - 6 * i * i + 3 * i * o + 9 * n * s - 3 * n * n - 3 * n * l - 6 * s * s + 3 * s * l, f = 1 * 3 * a * a - 6 * a * i + a * o - a * e + 2 * i * i + 2 * i * e - o * e + 3 * n * n - 6 * n * s + n * l - n * t + 2 * s * s + 2 * s * t - l * t, c = 1 * a * i - a * a + a * e - i * e + n * s - n * n + n * t - s * t, h = [];
1846
+ var u = 1 * a * a - 4 * a * i + 2 * a * o + 4 * i * i - 4 * i * o + o * o + n * n - 4 * n * s + 2 * n * l + 4 * s * s - 4 * s * l + l * l, v = 9 * a * i - 3 * a * a - 3 * a * o - 6 * i * i + 3 * i * o + 9 * n * s - 3 * n * n - 3 * n * l - 6 * s * s + 3 * s * l, f = 3 * a * a - 6 * a * i + a * o - a * e + 2 * i * i + 2 * i * e - o * e + 3 * n * n - 6 * n * s + n * l - n * t + 2 * s * s + 2 * s * t - l * t, c = 1 * a * i - a * a + a * e - i * e + n * s - n * n + n * t - s * t, h = [];
1847
1847
  Id(u, v, f, c, h);
1848
1848
  for (var d = 1e-7, y = [], g = 0; g < 6; g += 2)
1849
1849
  Math.abs(h[g + 1]) < d && h[g] >= 0 && h[g] <= 1 && y.push(h[g]);
@@ -3411,10 +3411,10 @@ var Ci, du;
3411
3411
  function Oh() {
3412
3412
  if (du) return Ci;
3413
3413
  du = 1;
3414
- var r = Ih(), e = function() {
3414
+ var r = Ih(), e = (function() {
3415
3415
  var a = /[^.]+$/.exec(r && r.keys && r.keys.IE_PROTO || "");
3416
3416
  return a ? "Symbol(src)_1." + a : "";
3417
- }();
3417
+ })();
3418
3418
  function t(a) {
3419
3419
  return !!e && e in a;
3420
3420
  }
@@ -3875,13 +3875,13 @@ var vg = lg(), fg = /* @__PURE__ */ Oa(vg), us, Ju;
3875
3875
  function cg() {
3876
3876
  if (Ju) return us;
3877
3877
  Ju = 1;
3878
- var r = so(), e = function() {
3878
+ var r = so(), e = (function() {
3879
3879
  try {
3880
3880
  var t = r(Object, "defineProperty");
3881
3881
  return t({}, "", {}), t;
3882
3882
  } catch {
3883
3883
  }
3884
- }();
3884
+ })();
3885
3885
  return us = e, us;
3886
3886
  }
3887
3887
  var ls, ju;
@@ -4383,11 +4383,11 @@ var qe = function() {
4383
4383
  }
4384
4384
  }].sort(function(r, e) {
4385
4385
  return Tc(r.selector, e.selector);
4386
- }), Dg = function() {
4386
+ }), Dg = (function() {
4387
4387
  for (var r = {}, e, t = 0; t < Os.length; t++)
4388
4388
  e = Os[t], r[e.selector] = e.matches;
4389
4389
  return r;
4390
- }(), Bg = function(e, t) {
4390
+ })(), Bg = function(e, t) {
4391
4391
  return Dg[e](t);
4392
4392
  }, Pg = "(" + Os.map(function(r) {
4393
4393
  return r.selector;
@@ -7628,7 +7628,7 @@ function yp(r, e, t, a) {
7628
7628
  }, T;
7629
7629
  }
7630
7630
  /*! Runge-Kutta spring physics function generator. Adapted from Framer.js, copyright Koen Bok. MIT License: http://en.wikipedia.org/wiki/MIT_License */
7631
- var mp = /* @__PURE__ */ function() {
7631
+ var mp = /* @__PURE__ */ (function() {
7632
7632
  function r(a) {
7633
7633
  return -a.tension * a.x - a.friction * a.v;
7634
7634
  }
@@ -7664,7 +7664,7 @@ var mp = /* @__PURE__ */ function() {
7664
7664
  return l[y * (l.length - 1) | 0];
7665
7665
  } : u;
7666
7666
  };
7667
- }(), Ge = function(e, t, a, n) {
7667
+ })(), Ge = function(e, t, a, n) {
7668
7668
  var i = yp(e, t, a, n);
7669
7669
  return function(s, o, l) {
7670
7670
  return s + (o - s) * i(l);
@@ -10592,7 +10592,7 @@ var kp = {
10592
10592
  },
10593
10593
  size: function() {
10594
10594
  var e = this._private, t = e.container, a = this;
10595
- return e.sizeCache = e.sizeCache || (t ? function() {
10595
+ return e.sizeCache = e.sizeCache || (t ? (function() {
10596
10596
  var n = a.window().getComputedStyle(t), i = function(o) {
10597
10597
  return parseFloat(n.getPropertyValue(o));
10598
10598
  };
@@ -10600,7 +10600,7 @@ var kp = {
10600
10600
  width: t.clientWidth - i("padding-left") - i("padding-right"),
10601
10601
  height: t.clientHeight - i("padding-top") - i("padding-bottom")
10602
10602
  };
10603
- }() : {
10603
+ })() : {
10604
10604
  // fallback if no container (not 0 b/c can be used for dividing etc)
10605
10605
  width: 1,
10606
10606
  height: 1
@@ -11111,12 +11111,12 @@ af.prototype.run = function() {
11111
11111
  x: l.x1 + l.w / 2,
11112
11112
  y: l.y1 + l.h / 2
11113
11113
  }, Y = a.reduce(function(ye, ie) {
11114
- return function(de) {
11114
+ return (function(de) {
11115
11115
  return {
11116
11116
  w: ye.w === -1 ? de.w : (ye.w + de.w) / 2,
11117
11117
  h: ye.h === -1 ? de.h : (ye.h + de.h) / 2
11118
11118
  };
11119
- }(ie.boundingBox({
11119
+ })(ie.boundingBox({
11120
11120
  includeLabels: r.nodeDimensionsIncludeLabels
11121
11121
  }));
11122
11122
  }, {
@@ -14837,7 +14837,7 @@ var ws = 1e3 / 60, Tf = {
14837
14837
  }
14838
14838
  };
14839
14839
  }
14840
- }, ny = /* @__PURE__ */ function() {
14840
+ }, ny = /* @__PURE__ */ (function() {
14841
14841
  function r(e) {
14842
14842
  var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : xn;
14843
14843
  ht(this, r), this.idsByKey = new Xr(), this.keyForId = new Xr(), this.cachesByLvl = new Xr(), this.lvls = [], this.getKey = e, this.doesEleInvalidateKey = t;
@@ -14961,7 +14961,7 @@ var ws = 1e3 / 60, Tf = {
14961
14961
  return i && this.invalidateKey(n), i || this.getNumberOfIdsForKey(n) === 0;
14962
14962
  }
14963
14963
  }]);
14964
- }(), Nl = 25, nn = 50, pn = -4, Hs = 3, Sf = 7.99, iy = 8, sy = 1024, oy = 1024, uy = 1024, ly = 0.2, vy = 0.8, fy = 10, cy = 0.15, dy = 0.1, hy = 0.9, gy = 0.9, py = 100, yy = 1, Ut = {
14964
+ })(), Nl = 25, nn = 50, pn = -4, Hs = 3, Sf = 7.99, iy = 8, sy = 1024, oy = 1024, uy = 1024, ly = 0.2, vy = 0.8, fy = 10, cy = 0.15, dy = 0.1, hy = 0.9, gy = 0.9, py = 100, yy = 1, Ut = {
14965
14965
  dequeue: "dequeue",
14966
14966
  downscale: "downscale",
14967
14967
  highQuality: "highQuality"
@@ -16501,7 +16501,7 @@ function Jy(r, e, t) {
16501
16501
  r.bindBuffer(r.ARRAY_BUFFER, l), r.bufferData(r.ARRAY_BUFFER, n.byteLength, r.DYNAMIC_DRAW);
16502
16502
  for (var u = 0; u < 3; u++) {
16503
16503
  var v = t + u;
16504
- r.enableVertexAttribArray(v), r.vertexAttribPointer(v, 3, r.FLOAT, false, 3 * 12, u * 12), r.vertexAttribDivisor(v, 1);
16504
+ r.enableVertexAttribArray(v), r.vertexAttribPointer(v, 3, r.FLOAT, false, 36, u * 12), r.vertexAttribDivisor(v, 1);
16505
16505
  }
16506
16506
  return r.bindBuffer(r.ARRAY_BUFFER, null), l.getMatrixView = function(f) {
16507
16507
  return i[f];
@@ -16551,7 +16551,7 @@ function Ws(r, e, t) {
16551
16551
  function rm(r, e, t) {
16552
16552
  return r[0] = 2 / e, r[1] = 0, r[2] = 0, r[3] = 0, r[4] = -2 / t, r[5] = 0, r[6] = -1, r[7] = 1, r[8] = 1, r;
16553
16553
  }
16554
- var tm = /* @__PURE__ */ function() {
16554
+ var tm = /* @__PURE__ */ (function() {
16555
16555
  function r(e, t, a, n) {
16556
16556
  ht(this, r), this.debugID = Math.floor(Math.random() * 1e4), this.r = e, this.texSize = t, this.texRows = a, this.texHeight = Math.floor(t / a), this.enableWrapping = true, this.locked = false, this.texture = null, this.needsBuffer = true, this.freePointer = {
16557
16557
  x: 0,
@@ -16668,7 +16668,7 @@ var tm = /* @__PURE__ */ function() {
16668
16668
  this.texture && (this.texture.deleteTexture(), this.texture = null), this.canvas = null, this.scratch = null, this.locked = true;
16669
16669
  }
16670
16670
  }]);
16671
- }(), am = /* @__PURE__ */ function() {
16671
+ })(), am = /* @__PURE__ */ (function() {
16672
16672
  function r(e, t, a, n) {
16673
16673
  ht(this, r), this.r = e, this.texSize = t, this.texRows = a, this.createTextureCanvas = n, this.atlases = [], this.styleKeyToAtlas = /* @__PURE__ */ new Map(), this.markedKeys = /* @__PURE__ */ new Set();
16674
16674
  }
@@ -16798,13 +16798,13 @@ var tm = /* @__PURE__ */ function() {
16798
16798
  };
16799
16799
  }
16800
16800
  }]);
16801
- }();
16801
+ })();
16802
16802
  function nm(r, e) {
16803
16803
  return r.intersection ? r.intersection(e) : new Set(mn(r).filter(function(t) {
16804
16804
  return e.has(t);
16805
16805
  }));
16806
16806
  }
16807
- var im = /* @__PURE__ */ function() {
16807
+ var im = /* @__PURE__ */ (function() {
16808
16808
  function r(e, t) {
16809
16809
  ht(this, r), this.r = e, this.globalOptions = t, this.atlasSize = t.webglTexSize, this.maxAtlasesPerBatch = t.webglTexPerBatch, this.renderTypes = /* @__PURE__ */ new Map(), this.collections = /* @__PURE__ */ new Map(), this.typeAndIdToKey = /* @__PURE__ */ new Map();
16810
16810
  }
@@ -16964,7 +16964,7 @@ var im = /* @__PURE__ */ function() {
16964
16964
  return t;
16965
16965
  }
16966
16966
  }]);
16967
- }(), sm = /* @__PURE__ */ function() {
16967
+ })(), sm = /* @__PURE__ */ (function() {
16968
16968
  function r(e) {
16969
16969
  ht(this, r), this.globalOptions = e, this.atlasSize = e.webglTexSize, this.maxAtlasesPerBatch = e.webglTexPerBatch, this.batchAtlases = [];
16970
16970
  }
@@ -17019,7 +17019,7 @@ var im = /* @__PURE__ */ function() {
17019
17019
  return a;
17020
17020
  }
17021
17021
  }]);
17022
- }(), om = `
17022
+ })(), om = `
17023
17023
  float circleSD(vec2 p, float r) {
17024
17024
  return distance(vec2(0), p) - r; // signed distance
17025
17025
  }
@@ -17070,7 +17070,7 @@ var im = /* @__PURE__ */ function() {
17070
17070
  // don't render the texture at all
17071
17071
  USE_BB: 2
17072
17072
  // render the bounding box as an opaque rectangle
17073
- }, Cs = 0, Kl = 1, Xl = 2, Ts = 3, _t = 4, sn = 5, ga = 6, pa = 7, fm = /* @__PURE__ */ function() {
17073
+ }, Cs = 0, Kl = 1, Xl = 2, Ts = 3, _t = 4, sn = 5, ga = 6, pa = 7, fm = /* @__PURE__ */ (function() {
17074
17074
  function r(e, t, a) {
17075
17075
  ht(this, r), this.r = e, this.gl = t, this.maxInstances = a.webglBatchSize, this.atlasSize = a.webglTexSize, this.bgColor = a.bgColor, this.debug = a.webglDebug, this.batchDebugInfo = [], a.enableWrapping = true, a.createTextureCanvas = Hy, this.atlasManager = new im(e, a), this.batchManager = new sm(a), this.simpleShapeOptions = /* @__PURE__ */ new Map(), this.program = this._createShaderProgram(Ea.SCREEN), this.pickingProgram = this._createShaderProgram(Ea.PICKING), this.vao = this._createVAO();
17076
17076
  }
@@ -17830,7 +17830,7 @@ var im = /* @__PURE__ */ function() {
17830
17830
  };
17831
17831
  }
17832
17832
  }]);
17833
- }(), Mf = {};
17833
+ })(), Mf = {};
17834
17834
  Mf.initWebgl = function(r, e) {
17835
17835
  var t = this, a = t.data.contexts[t.WEBGL];
17836
17836
  r.bgColor = cm(t), r.webglTexSize = Math.min(r.webglTexSize, a.getParameter(a.MAX_TEXTURE_SIZE)), r.webglTexRows = Math.min(r.webglTexRows, 54), r.webglTexRowsNodes = Math.min(r.webglTexRowsNodes, 54), r.webglBatchSize = Math.min(r.webglBatchSize, 16384), r.webglTexPerBatch = Math.min(r.webglTexPerBatch, a.getParameter(a.MAX_TEXTURE_IMAGE_UNITS)), t.webglDebug = r.webglDebug, t.webglDebugShowAtlases = r.webglDebugShowAtlases, t.pickingFrameBuffer = jy(a), t.pickingFrameBuffer.needsDraw = true, t.drawing = new fm(t, a, r);
@@ -1,9 +1,9 @@
1
- import { _ as w, ae as F, af as Y, ag as _, ah as H, l as i, c as V, ai as U, aj as $, a1 as q, a6 as z, a2 as P, a0 as K, ak as Q, al as W, am as Z } from "./mermaid-Cg5IX6Nv.js";
2
- import { G as B } from "./graph-77W6heli.js";
3
- import { l as I } from "./layout-XySVHJgD.js";
4
- import { i as b } from "./_baseUniq-DdHL34FO.js";
5
- import { c as L } from "./clone-78au0tn1.js";
6
- import { m as A } from "./min-DS5Jz-hg.js";
1
+ import { _ as w, ae as F, af as Y, ag as _, ah as H, l as i, c as V, ai as U, aj as $, a1 as q, a6 as z, a2 as P, a0 as K, ak as Q, al as W, am as Z } from "./mermaid-HVCtvbyx.js";
2
+ import { G as B } from "./graph-CoRe7vAN.js";
3
+ import { l as I } from "./layout-m2vOUiW1.js";
4
+ import { i as b } from "./_baseUniq-dN9WKF9m.js";
5
+ import { c as L } from "./clone-CLoRX3j6.js";
6
+ import { m as A } from "./min-DcGMA4e_.js";
7
7
  function h(e) {
8
8
  var t = {
9
9
  options: {
@@ -1,5 +1,5 @@
1
- import { G as r, H as $ } from "./main-B5yML0bw.js";
2
- import { s as z, i as D, a as J, b as Q, T as U, C as Z, m as ee } from "./glide-data-editor-CmN6FVyi.js";
1
+ import { r, v as $ } from "./main-BD2KGFpU.js";
2
+ import { s as z, i as D, a as J, b as Q, T as U, C as Z, m as ee } from "./glide-data-editor-9nC3iCIZ.js";
3
3
  const te = () => (t) => t.targetX, re = () => (t) => t.targetY, ne = () => (t) => t.targetWidth, ie = () => (t) => t.targetHeight, se = () => (t) => t.targetY + 10, ae = () => (t) => Math.max(0, (t.targetHeight - 28) / 2), oe = /* @__PURE__ */ z("div")({
4
4
  name: "DataGridOverlayEditorStyle",
5
5
  class: "gdg-d19meir1",
@@ -18,12 +18,12 @@ function le() {
18
18
  return [t ?? void 0, s];
19
19
  }
20
20
  function de() {
21
- const [t, s] = le(), [i, h] = r.useState(0), [f, C] = r.useState(true);
21
+ const [t, s] = le(), [i, h] = r.useState(0), [f, v] = r.useState(true);
22
22
  r.useLayoutEffect(() => {
23
23
  if (t === void 0 || !("IntersectionObserver" in window))
24
24
  return;
25
25
  const a = new IntersectionObserver((o) => {
26
- o.length !== 0 && C(o[0].isIntersecting);
26
+ o.length !== 0 && v(o[0].isIntersecting);
27
27
  }, { threshold: 1 });
28
28
  return a.observe(t), () => a.disconnect();
29
29
  }, [t]), r.useEffect(() => {
@@ -38,14 +38,14 @@ function de() {
38
38
  a !== void 0 && cancelAnimationFrame(a);
39
39
  };
40
40
  }, [t, f]);
41
- const v = r.useMemo(() => ({ transform: `translateX(${i}px)` }), [i]);
41
+ const C = r.useMemo(() => ({ transform: `translateX(${i}px)` }), [i]);
42
42
  return {
43
43
  ref: s,
44
- style: v
44
+ style: C
45
45
  };
46
46
  }
47
47
  const fe = (t) => {
48
- const { target: s, content: i, onFinishEditing: h, forceEditMode: f, initialValue: C, imageEditorOverride: v, markdownDivCreateNode: a, highlight: o, className: x, theme: g, id: N, cell: m, bloom: I, validateCell: p, getCellRenderer: w, provideEditor: F, isOutsideClick: V, customEventTarget: W } = t, [l, X] = r.useState(f ? i : void 0), O = r.useRef(l ?? i);
48
+ const { target: s, content: i, onFinishEditing: h, forceEditMode: f, initialValue: v, imageEditorOverride: C, markdownDivCreateNode: a, highlight: o, className: x, theme: g, id: G, cell: m, bloom: I, validateCell: p, getCellRenderer: w, provideEditor: F, isOutsideClick: H, customEventTarget: W } = t, [l, X] = r.useState(f ? i : void 0), O = r.useRef(l ?? i);
49
49
  O.current = l ?? i;
50
50
  const [y, S] = r.useState(() => p === void 0 ? true : !(D(i) && (p == null ? void 0 : p(m, i, O.current)) === false)), u = r.useCallback((e, n) => {
51
51
  h(y ? e : void 0, n);
@@ -77,7 +77,7 @@ const fe = (t) => {
77
77
  const e = Q(d);
78
78
  e && (b = d.styleOverride);
79
79
  const n = e ? d.editor : d;
80
- T = r.createElement(n, { isHighlighted: o, onChange: A, value: k, initialValue: C, onFinishedEditing: Y, validatedSelection: D(k) ? k.selectionRange : void 0, forceEditMode: f, target: s, imageEditorOverride: v, markdownDivCreateNode: a, isValid: y, theme: g });
80
+ T = r.createElement(n, { isHighlighted: o, onChange: A, value: k, initialValue: v, onFinishedEditing: Y, validatedSelection: D(k) ? k.selectionRange : void 0, forceEditMode: f, target: s, imageEditorOverride: C, markdownDivCreateNode: a, isValid: y, theme: g });
81
81
  }
82
82
  b = { ...b, ...B };
83
83
  const _ = document.getElementById("portal");
@@ -85,16 +85,16 @@ const fe = (t) => {
85
85
  return console.error('Cannot open Data Grid overlay editor, because portal not found. Please add `<div id="portal" />` as the last child of your `<body>`.'), null;
86
86
  let R = M ? "gdg-style" : "gdg-unstyle";
87
87
  y || (R += " gdg-invalid"), P && (R += " gdg-pad");
88
- const G = (I == null ? void 0 : I[0]) ?? 1, H = (I == null ? void 0 : I[1]) ?? 1;
88
+ const N = (I == null ? void 0 : I[0]) ?? 1, V = (I == null ? void 0 : I[1]) ?? 1;
89
89
  return $.createPortal(r.createElement(
90
90
  U.Provider,
91
91
  { value: g },
92
92
  r.createElement(
93
93
  Z,
94
- { style: ee(g), className: x, onClickOutside: K, isOutsideClick: V, customEventTarget: W },
94
+ { style: ee(g), className: x, onClickOutside: K, isOutsideClick: H, customEventTarget: W },
95
95
  r.createElement(
96
96
  oe,
97
- { ref: q, id: N, className: R, style: b, as: L === true ? "label" : void 0, targetX: s.x - G, targetY: s.y - H, targetWidth: s.width + G * 2, targetHeight: s.height + H * 2 },
97
+ { ref: q, id: G, className: R, style: b, as: L === true ? "label" : void 0, targetX: s.x - N, targetY: s.y - V, targetWidth: s.width + N * 2, targetHeight: s.height + V * 2 },
98
98
  r.createElement("div", { className: "gdg-clip-region", onKeyDown: j }, T)
99
99
  )
100
100
  )
@@ -1,20 +1,20 @@
1
1
  var _a;
2
- import { s as ne } from "./chunk-NRVI72HA-BYx2jMlI.js";
3
- import { _ as h, F as j, G as q, K as re, e as oe, l as B, aa as L, d as E, b as ie, a as ce, q as de, t as pe, g as he, s as me, H as ue, ab as fe, z as ye } from "./mermaid-Cg5IX6Nv.js";
4
- import { p as ge } from "./chunk-ANTBXLJU-BvYnIrdq.js";
5
- import { p as Se } from "./treemap-75Q7IDZK-CKP4vV_0.js";
6
- import { f as P } from "./main-B5yML0bw.js";
2
+ import { _ as h, F as j, G as q, K as ne, e as re, l as B, aa as L, d as E, b as oe, a as ie, q as ce, t as pe, g as de, s as he, H as me, ab as ue, z as fe } from "./mermaid-HVCtvbyx.js";
3
+ import { s as ye } from "./chunk-QN33PNHL-D5LO5Jq_.js";
4
+ import { p as ge } from "./chunk-4BX2VUAB-CZR39zCO.js";
5
+ import { p as Se } from "./treemap-75Q7IDZK-zeJG07dk.js";
6
+ import { i as P } from "./main-BD2KGFpU.js";
7
7
  import { o as R } from "./ordinal-CYN5qNoq.js";
8
- import { h as xe, t as be } from "./index-pBmAzQJl.js";
8
+ import { h as xe, t as be } from "./index-MCx5v1x0.js";
9
9
  var K = (_a = class {
10
10
  constructor() {
11
- this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.setAccTitle = ie, this.getAccTitle = ce, this.setDiagramTitle = de, this.getDiagramTitle = pe, this.getAccDescription = he, this.setAccDescription = me;
11
+ this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.setAccTitle = oe, this.getAccTitle = ie, this.setDiagramTitle = ce, this.getDiagramTitle = pe, this.getAccDescription = de, this.setAccDescription = he;
12
12
  }
13
13
  getNodes() {
14
14
  return this.nodes;
15
15
  }
16
16
  getConfig() {
17
- const s = ue, a = q();
17
+ const s = me, a = q();
18
18
  return j({
19
19
  ...s.treemap,
20
20
  ...a.treemap ?? {}
@@ -28,8 +28,8 @@ var K = (_a = class {
28
28
  }
29
29
  addClass(s, a) {
30
30
  const o = this.classes.get(s) ?? { id: s, styles: [], textStyles: [] }, i = a.replace(/\\,/g, "\xA7\xA7\xA7").replace(/,/g, ";").replace(/§§§/g, ",").split(";");
31
- i && i.forEach((d) => {
32
- fe(d) && ((o == null ? void 0 : o.textStyles) ? o.textStyles.push(d) : o.textStyles = [d]), (o == null ? void 0 : o.styles) ? o.styles.push(d) : o.styles = [d];
31
+ i && i.forEach((p) => {
32
+ ue(p) && ((o == null ? void 0 : o.textStyles) ? o.textStyles.push(p) : o.textStyles = [p]), (o == null ? void 0 : o.styles) ? o.styles.push(p) : o.styles = [p];
33
33
  }), this.classes.set(s, o);
34
34
  }
35
35
  getClasses() {
@@ -40,7 +40,7 @@ var K = (_a = class {
40
40
  return ((_a2 = this.classes.get(s)) == null ? void 0 : _a2.styles) ?? [];
41
41
  }
42
42
  clear() {
43
- ye(), this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.root = void 0;
43
+ fe(), this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.root = void 0;
44
44
  }
45
45
  }, h(_a, "TreeMapDB"), _a);
46
46
  function U(s) {
@@ -48,19 +48,19 @@ function U(s) {
48
48
  return [];
49
49
  const a = [], o = [];
50
50
  return s.forEach((i) => {
51
- const d = {
51
+ const p = {
52
52
  name: i.name,
53
53
  children: i.type === "Leaf" ? void 0 : []
54
54
  };
55
- for (d.classSelector = i == null ? void 0 : i.classSelector, (i == null ? void 0 : i.cssCompiledStyles) && (d.cssCompiledStyles = [i.cssCompiledStyles]), i.type === "Leaf" && i.value !== void 0 && (d.value = i.value); o.length > 0 && o[o.length - 1].level >= i.level; )
55
+ for (p.classSelector = i == null ? void 0 : i.classSelector, (i == null ? void 0 : i.cssCompiledStyles) && (p.cssCompiledStyles = [i.cssCompiledStyles]), i.type === "Leaf" && i.value !== void 0 && (p.value = i.value); o.length > 0 && o[o.length - 1].level >= i.level; )
56
56
  o.pop();
57
57
  if (o.length === 0)
58
- a.push(d);
58
+ a.push(p);
59
59
  else {
60
60
  const r = o[o.length - 1].node;
61
- r.children ? r.children.push(d) : r.children = [d];
61
+ r.children ? r.children.push(p) : r.children = [p];
62
62
  }
63
- i.type !== "Leaf" && o.push({ node: d, level: i.level });
63
+ i.type !== "Leaf" && o.push({ node: p, level: i.level });
64
64
  }), a;
65
65
  }
66
66
  h(U, "buildHierarchy");
@@ -70,24 +70,24 @@ var ve = /* @__PURE__ */ h((s, a) => {
70
70
  for (const r of s.TreemapRows ?? [])
71
71
  r.$type === "ClassDefStatement" && a.addClass(r.className ?? "", r.styleText ?? "");
72
72
  for (const r of s.TreemapRows ?? []) {
73
- const p = r.item;
74
- if (!p)
73
+ const d = r.item;
74
+ if (!d)
75
75
  continue;
76
- const f = r.indent ? parseInt(r.indent) : 0, M = Ce(p), l = p.classSelector ? a.getStylesForClass(p.classSelector) : [], F = l.length > 0 ? l.join(";") : void 0, b = {
77
- level: f,
76
+ const u = r.indent ? parseInt(r.indent) : 0, M = Ce(d), l = d.classSelector ? a.getStylesForClass(d.classSelector) : [], F = l.length > 0 ? l.join(";") : void 0, b = {
77
+ level: u,
78
78
  name: M,
79
- type: p.$type,
80
- value: p.value,
81
- classSelector: p.classSelector,
79
+ type: d.$type,
80
+ value: d.value,
81
+ classSelector: d.classSelector,
82
82
  cssCompiledStyles: F
83
83
  };
84
84
  o.push(b);
85
85
  }
86
- const i = U(o), d = /* @__PURE__ */ h((r, p) => {
87
- for (const f of r)
88
- a.addNode(f, p), f.children && f.children.length > 0 && d(f.children, p + 1);
86
+ const i = U(o), p = /* @__PURE__ */ h((r, d) => {
87
+ for (const u of r)
88
+ a.addNode(u, d), u.children && u.children.length > 0 && p(u.children, d + 1);
89
89
  }, "addNodesRecursively");
90
- d(i, 0);
90
+ p(i, 0);
91
91
  }, "populate"), Ce = /* @__PURE__ */ h((s) => s.name ? String(s.name) : "", "getItemName"), J = {
92
92
  // @ts-expect-error - TreeMapDB is not assignable to DiagramDB
93
93
  parser: { yy: void 0 },
@@ -107,11 +107,11 @@ var ve = /* @__PURE__ */ h((s, a) => {
107
107
  }
108
108
  }, "parse")
109
109
  }, we = 10, $ = 10, D = 25, Te = /* @__PURE__ */ h((s, a, o, i) => {
110
- const d = i.db, r = d.getConfig(), p = r.padding ?? we, f = d.getDiagramTitle(), M = d.getRoot(), { themeVariables: l } = q();
110
+ const p = i.db, r = p.getConfig(), d = r.padding ?? we, u = p.getDiagramTitle(), M = p.getRoot(), { themeVariables: l } = q();
111
111
  if (!M)
112
112
  return;
113
- const F = f ? 30 : 0, b = re(a), I = r.nodeWidth ? r.nodeWidth * $ : 960, G = r.nodeHeight ? r.nodeHeight * $ : 500, _ = I, O = G + F;
114
- b.attr("viewBox", `0 0 ${_} ${O}`), oe(b, O, _, r.useMaxWidth);
113
+ const F = u ? 30 : 0, b = ne(a), I = r.nodeWidth ? r.nodeWidth * $ : 960, G = r.nodeHeight ? r.nodeHeight * $ : 500, _ = I, O = G + F;
114
+ b.attr("viewBox", `0 0 ${_} ${O}`), re(b, O, _, r.useMaxWidth);
115
115
  let v;
116
116
  try {
117
117
  const e = r.valueFormat || ",";
@@ -170,10 +170,10 @@ var ve = /* @__PURE__ */ h((s, a) => {
170
170
  l.cScaleLabel10,
171
171
  l.cScaleLabel11
172
172
  ]);
173
- f && b.append("text").attr("x", _ / 2).attr("y", F / 2).attr("class", "treemapTitle").attr("text-anchor", "middle").attr("dominant-baseline", "middle").text(f);
173
+ u && b.append("text").attr("x", _ / 2).attr("y", F / 2).attr("class", "treemapTitle").attr("text-anchor", "middle").attr("dominant-baseline", "middle").text(u);
174
174
  const X = b.append("g").attr("transform", `translate(0, ${F})`).attr("class", "treemapContainer"), Z = xe(M).sum((e) => e.value ?? 0).sort((e, t) => (t.value ?? 0) - (e.value ?? 0)), Y = be().size([I, G]).paddingTop(
175
175
  (e) => e.children && e.children.length > 0 ? D + $ : 0
176
- ).paddingInner(p).paddingLeft((e) => e.children && e.children.length > 0 ? $ : 0).paddingRight((e) => e.children && e.children.length > 0 ? $ : 0).paddingBottom((e) => e.children && e.children.length > 0 ? $ : 0).round(true)(Z), ee = Y.descendants().filter((e) => e.children && e.children.length > 0), N = X.selectAll(".treemapSection").data(ee).enter().append("g").attr("class", "treemapSection").attr("transform", (e) => `translate(${e.x0},${e.y0})`);
176
+ ).paddingInner(d).paddingLeft((e) => e.children && e.children.length > 0 ? $ : 0).paddingRight((e) => e.children && e.children.length > 0 ? $ : 0).paddingBottom((e) => e.children && e.children.length > 0 ? $ : 0).round(true)(Z), ee = Y.descendants().filter((e) => e.children && e.children.length > 0), N = X.selectAll(".treemapSection").data(ee).enter().append("g").attr("class", "treemapSection").attr("transform", (e) => `translate(${e.x0},${e.y0})`);
177
177
  N.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", D).attr("class", "treemapSectionHeader").attr("fill", "none").attr("fill-opacity", 0.6).attr("stroke-width", 0.6).attr("style", (e) => e.depth === 0 ? "display: none;" : ""), N.append("clipPath").attr("id", (e, t) => `clip-section-${a}-${t}`).append("rect").attr("width", (e) => Math.max(0, e.x1 - e.x0 - 12)).attr("height", D), N.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", (e) => e.y1 - e.y0).attr("class", (e, t) => `treemapSection section${t}`).attr("fill", (e) => z(e.data.name)).attr("fill-opacity", 0.6).attr("stroke", (e) => Q(e.data.name)).attr("stroke-width", 2).attr("stroke-opacity", 0.4).attr("style", (e) => {
178
178
  if (e.depth === 0)
179
179
  return "display: none;";
@@ -189,19 +189,18 @@ var ve = /* @__PURE__ */ h((s, a) => {
189
189
  return;
190
190
  const t = E(this), n = e.data.name;
191
191
  t.text(n);
192
- const m = e.x1 - e.x0, g = 6;
193
- let S;
194
- r.showValues !== false && e.value ? S = m - 10 - 30 - 10 - g : S = m - g - 6;
195
- const x = Math.max(15, S), c = t.node();
196
- if (c.getComputedTextLength() > x) {
197
- const u = "...";
198
- let y = n;
199
- for (; y.length > 0; ) {
200
- if (y = n.substring(0, y.length - 1), y.length === 0) {
201
- t.text(u), c.getComputedTextLength() > x && t.text("");
192
+ const m = e.x1 - e.x0, y = 6;
193
+ let g;
194
+ r.showValues !== false && e.value ? g = m - 10 - 30 - 10 - y : g = m - y - 6;
195
+ const S = Math.max(15, g), c = t.node();
196
+ if (c.getComputedTextLength() > S) {
197
+ let f = n;
198
+ for (; f.length > 0; ) {
199
+ if (f = n.substring(0, f.length - 1), f.length === 0) {
200
+ t.text("..."), c.getComputedTextLength() > S && t.text("");
202
201
  break;
203
202
  }
204
- if (t.text(y + u), c.getComputedTextLength() <= x)
203
+ if (t.text(f + "..."), c.getComputedTextLength() <= S)
205
204
  break;
206
205
  }
207
206
  }
@@ -216,25 +215,25 @@ var ve = /* @__PURE__ */ h((s, a) => {
216
215
  const t = "text-anchor: middle; dominant-baseline: middle; font-size: 38px;fill:" + V(e.data.name) + ";", n = L({ cssCompiledStyles: e.data.cssCompiledStyles });
217
216
  return t + n.labelStyles.replace("color:", "fill:");
218
217
  }).attr("clip-path", (e, t) => `url(#clip-${a}-${t})`).text((e) => e.data.name).each(function(e) {
219
- const t = E(this), n = e.x1 - e.x0, m = e.y1 - e.y0, g = t.node(), S = 4, T = n - 2 * S, x = m - 2 * S;
220
- if (T < 10 || x < 10) {
218
+ const t = E(this), n = e.x1 - e.x0, m = e.y1 - e.y0, y = t.node(), g = 4, T = n - 2 * g, S = m - 2 * g;
219
+ if (T < 10 || S < 10) {
221
220
  t.style("display", "none");
222
221
  return;
223
222
  }
224
223
  let c = parseInt(t.style("font-size"), 10);
225
- const C = 8, u = 28, y = 0.6, w = 6, A = 2;
226
- for (; g.getComputedTextLength() > T && c > C; )
224
+ const C = 8, x = 28, f = 0.6, w = 6, A = 2;
225
+ for (; y.getComputedTextLength() > T && c > C; )
227
226
  c--, t.style("font-size", `${c}px`);
228
227
  let k = Math.max(
229
228
  w,
230
- Math.min(u, Math.round(c * y))
229
+ Math.min(x, Math.round(c * f))
231
230
  ), H = c + A + k;
232
- for (; H > x && c > C && (c--, k = Math.max(
231
+ for (; H > S && c > C && (c--, k = Math.max(
233
232
  w,
234
- Math.min(u, Math.round(c * y))
233
+ Math.min(x, Math.round(c * f))
235
234
  ), !(k < w && c === C)); )
236
235
  t.style("font-size", `${c}px`), H = c + A + k;
237
- t.style("font-size", `${c}px`), (g.getComputedTextLength() > T || c < C || x < c) && t.style("display", "none");
236
+ t.style("font-size", `${c}px`), (y.getComputedTextLength() > T || c < C || S < c) && t.style("display", "none");
238
237
  }), r.showValues !== false && W.append("text").attr("class", "treemapValue").attr("x", (t) => (t.x1 - t.x0) / 2).attr("y", function(t) {
239
238
  return (t.y1 - t.y0) / 2;
240
239
  }).attr("style", (t) => {
@@ -246,23 +245,23 @@ var ve = /* @__PURE__ */ h((s, a) => {
246
245
  n.style("display", "none");
247
246
  return;
248
247
  }
249
- const g = E(m).select(".treemapLabel");
250
- if (g.empty() || g.style("display") === "none") {
248
+ const y = E(m).select(".treemapLabel");
249
+ if (y.empty() || y.style("display") === "none") {
251
250
  n.style("display", "none");
252
251
  return;
253
252
  }
254
- const S = parseFloat(g.style("font-size")), T = 28, x = 0.6, c = 6, C = 2, u = Math.max(
253
+ const g = parseFloat(y.style("font-size")), T = 28, S = 0.6, c = 6, C = 2, x = Math.max(
255
254
  c,
256
- Math.min(T, Math.round(S * x))
255
+ Math.min(T, Math.round(g * S))
257
256
  );
258
- n.style("font-size", `${u}px`);
259
- const w = (t.y1 - t.y0) / 2 + S / 2 + C;
257
+ n.style("font-size", `${x}px`);
258
+ const w = (t.y1 - t.y0) / 2 + g / 2 + C;
260
259
  n.attr("y", w);
261
- const A = t.x1 - t.x0, le = t.y1 - t.y0 - 4, se = A - 2 * 4;
262
- n.node().getComputedTextLength() > se || w + u > le || u < c ? n.style("display", "none") : n.style("display", null);
260
+ const A = t.x1 - t.x0, le = t.y1 - t.y0 - 4, se = A - 8;
261
+ n.node().getComputedTextLength() > se || w + x > le || x < c ? n.style("display", "none") : n.style("display", null);
263
262
  });
264
263
  const ae = r.diagramPadding ?? 8;
265
- ne(b, ae, "flowchart", (r == null ? void 0 : r.useMaxWidth) || false);
264
+ ye(b, ae, "flowchart", (r == null ? void 0 : r.useMaxWidth) || false);
266
265
  }, "draw"), Le = /* @__PURE__ */ h(function(s, a) {
267
266
  return a.db.getClasses();
268
267
  }, "getClasses"), $e = { draw: Te, getClasses: Le }, Fe = {