@antdv-next/x 1.0.2-beta.3 → 1.0.2-beta.4

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 (92) hide show
  1. package/dist/index.umd.js +1 -1
  2. package/dist/package.js +1 -1
  3. package/es/{_basePickBy-DZiMKfOQ.js → _basePickBy-DFHEGO2M.js} +2 -2
  4. package/es/{_baseUniq-DY3uHjSO.js → _baseUniq-BlS7rXTs.js} +2 -2
  5. package/es/antdv-next-x.esm.js +45472 -6767
  6. package/es/architecture-PBZL5I3N-D7tS55xM.js +3 -0
  7. package/es/{architectureDiagram-2XIMDMQ5-C8x7stcr.js → architectureDiagram-2XIMDMQ5-CmfsCwJk.js} +83 -83
  8. package/es/{blockDiagram-WCTKOSBZ-DA-s3zoq.js → blockDiagram-WCTKOSBZ-lJAan65A.js} +529 -529
  9. package/es/{c4Diagram-IC4MRINW-DD81dyS8.js → c4Diagram-IC4MRINW-B1c2x_1Q.js} +168 -168
  10. package/es/{channel-DZcPzDuw.js → channel-DFgF_2F7.js} +1 -1
  11. package/es/{chunk-4BX2VUAB-B3zzxglQ.js → chunk-4BX2VUAB-J2N81Fpp.js} +1 -1
  12. package/es/{chunk-55IACEB6-CA9CRLkM.js → chunk-55IACEB6-DGtfGRgi.js} +1 -1
  13. package/es/{chunk-7E7YKBS2-C_F-WOLQ.js → chunk-7E7YKBS2-CL2d4WAf.js} +1 -1
  14. package/es/{chunk-7R4GIKGN-CaI-1szl.js → chunk-7R4GIKGN-QT6IorJ_.js} +2 -2
  15. package/es/{chunk-C72U2L5F-l6RZhGri.js → chunk-C72U2L5F-OHTVpS-m.js} +1 -1
  16. package/es/{chunk-EGIJ26TM-Be42NeHw.js → chunk-EGIJ26TM-DyMPGYrB.js} +1 -1
  17. package/es/{chunk-FMBD7UC4-DJh0L322.js → chunk-FMBD7UC4-DCcRjunY.js} +1 -1
  18. package/es/{chunk-GEFDOKGD-BWt_f4io.js → chunk-GEFDOKGD-BWpC-zoH.js} +251 -251
  19. package/es/{chunk-GLR3WWYH-B30PgFZZ.js → chunk-GLR3WWYH-DiXcKb5Y.js} +16 -16
  20. package/es/{chunk-HHEYEP7N-DkMnkoQX.js → chunk-HHEYEP7N-Cxc7E4dX.js} +2 -2
  21. package/es/{chunk-JSJVCQXG-ddNKdfu8.js → chunk-JSJVCQXG-D8_heHOp.js} +2 -2
  22. package/es/{chunk-KX2RTZJC-BbnGQVgL.js → chunk-KX2RTZJC-D5cc4rj6.js} +2 -2
  23. package/es/{chunk-KYZI473N-B2rmiORt.js → chunk-KYZI473N-BHJ3T5Zv.js} +571 -571
  24. package/es/{chunk-L3YUKLVL-CmAZrf2E.js → chunk-L3YUKLVL-7oGaUOdc.js} +1 -1
  25. package/es/{chunk-MX3YWQON-B3_AxMM1.js → chunk-MX3YWQON-BxE-Aq9c.js} +1 -1
  26. package/es/{chunk-NQ4KR5QH-CmCG9ow3.js → chunk-NQ4KR5QH-EYQBXkqP.js} +119 -119
  27. package/es/{chunk-O4XLMI2P-CTLwv925.js → chunk-O4XLMI2P-qjOoGpnx.js} +237 -237
  28. package/es/{chunk-OZEHJAEY-CtONdvqY.js → chunk-OZEHJAEY-D82nx27s.js} +1 -1
  29. package/es/{chunk-PQ6SQG4A-Dx7no2mb.js → chunk-PQ6SQG4A-D3jtNCWN.js} +2 -2
  30. package/es/{chunk-PU5JKC2W-O9_8B7zU.js → chunk-PU5JKC2W-DdP8BS-S.js} +63 -63
  31. package/es/{chunk-QZHKN3VN-BbuqVxkO.js → chunk-QZHKN3VN-CW3cFN-h.js} +1 -1
  32. package/es/{chunk-R5LLSJPH-CpwKqyBY.js → chunk-R5LLSJPH-CreI2kO9.js} +1 -1
  33. package/es/{chunk-WL4C6EOR-BXrjoxmr.js → chunk-WL4C6EOR-BDbxJyGk.js} +119 -119
  34. package/es/{chunk-XIRO2GV7-4kMze38t.js → chunk-XIRO2GV7-S5KkbVnN.js} +1 -1
  35. package/es/{chunk-XPW4576I-DG6JendS.js → chunk-XPW4576I-B0KVSHwE.js} +1 -1
  36. package/es/{chunk-XZSTWKYB-DjOnj3KP.js → chunk-XZSTWKYB-CucN1XvM.js} +5 -5
  37. package/es/{chunk-YBOYWFTD-DVAsFYJ-.js → chunk-YBOYWFTD-CvaddD9G.js} +7 -7
  38. package/es/classDiagram-VBA2DB6C-Co3LMmg8.js +29 -0
  39. package/es/classDiagram-v2-RAHNMMFH-BZscgdF2.js +29 -0
  40. package/es/{clone-CtpnpaZq.js → clone-r3YukIBB.js} +1 -1
  41. package/es/{cose-bilkent-S5V4N54A-IRlkXPnk.js → cose-bilkent-S5V4N54A-B5OQuIhl.js} +1 -1
  42. package/es/{dagre-Dm2PNtRY.js → dagre-5aGJFKmT.js} +6 -6
  43. package/es/dagre-KLK3FWXG-BI5QQMXo.js +294 -0
  44. package/es/{diagram-E7M64L7V-Cdek_47s.js → diagram-E7M64L7V-Dz62Vz_a.js} +59 -59
  45. package/es/{diagram-IFDJBPK2-DzCaWPW3.js → diagram-IFDJBPK2-9fjvFkSc.js} +30 -30
  46. package/es/{diagram-P4PSJMXO-B7pPaer-.js → diagram-P4PSJMXO-BlX6jFjZ.js} +31 -31
  47. package/es/{erDiagram-INFDFZHY-BZHMCNB3.js → erDiagram-INFDFZHY-BcRXu8Cp.js} +127 -127
  48. package/es/{flowDiagram-PKNHOUZH-BBJx8-jP.js → flowDiagram-PKNHOUZH-UeyfgU8z.js} +155 -155
  49. package/es/{ganttDiagram-A5KZAMGK-4TJAHJUF.js → ganttDiagram-A5KZAMGK-txCzqgQ5.js} +602 -599
  50. package/es/gitGraph-HDMCJU4V-CxsS0Qr1.js +3 -0
  51. package/es/{gitGraphDiagram-K3NZZRJ6-CSATib_y.js → gitGraphDiagram-K3NZZRJ6-DghWYaFU.js} +175 -175
  52. package/es/{graphlib-WtNUGuyd.js → graphlib-dRkI1OCL.js} +3 -3
  53. package/es/info-3K5VOQVL-COqdvM99.js +3 -0
  54. package/es/{infoDiagram-LFFYTUFH-ahqynRAA.js → infoDiagram-LFFYTUFH-CA-vlAvP.js} +4 -4
  55. package/es/{isEmpty-BgdRybYg.js → isEmpty-CmA-HYrg.js} +1 -1
  56. package/es/{ishikawaDiagram-PHBUUO56-B9NWp429.js → ishikawaDiagram-PHBUUO56-DjdpS9Lb.js} +65 -65
  57. package/es/{journeyDiagram-4ABVD52K-CXmYa8OF.js → journeyDiagram-4ABVD52K-CIJfC1fp.js} +4 -4
  58. package/es/{kanban-definition-K7BYSVSG-g9tToeab.js → kanban-definition-K7BYSVSG-CC2vwGck.js} +10 -10
  59. package/es/{line-DETnb8Mr.js → line-Cu9NTacD.js} +1 -1
  60. package/es/{linear-DGQDIL28.js → linear-C0rAYYmp.js} +1 -1
  61. package/es/{mermaid-parser.core-DXn-0ev4.js → mermaid-parser.core-7Wn2L29P.js} +15 -15
  62. package/es/{mermaid.core-W4vXivv8.js → mermaid.core-Bvy_Q6Hu.js} +206 -206
  63. package/es/{mindmap-definition-YRQLILUH-x9QfilEP.js → mindmap-definition-YRQLILUH-BzTYDYmK.js} +12 -12
  64. package/es/packet-RMMSAZCW-2PTjWKLd.js +3 -0
  65. package/es/pie-UPGHQEXC-Du8-k-EA.js +3 -0
  66. package/es/{pieDiagram-SKSYHLDU-CG2GOW6Z.js → pieDiagram-SKSYHLDU-COvqE_C6.js} +24 -24
  67. package/es/{quadrantDiagram-337W2JSQ-C81pfz0c.js → quadrantDiagram-337W2JSQ-Dgv8ccjt.js} +3 -3
  68. package/es/radar-KQ55EAFF-jJOhyjxC.js +3 -0
  69. package/es/{requirementDiagram-Z7DCOOCP-J-tc0fnw.js → requirementDiagram-Z7DCOOCP-B2NyhxO-.js} +58 -58
  70. package/es/{sankeyDiagram-WA2Y5GQK-BfGyH2f1.js → sankeyDiagram-WA2Y5GQK-BfnH_gpl.js} +2 -2
  71. package/es/{sequenceDiagram-2WXFIKYE-m6aSnjku.js → sequenceDiagram-2WXFIKYE-DXssVQOF.js} +388 -388
  72. package/es/{stateDiagram-RAJIS63D-CPJuOh-s.js → stateDiagram-RAJIS63D-DvDLfupV.js} +67 -67
  73. package/es/stateDiagram-v2-FVOUBMTO-DIXyaX9W.js +27 -0
  74. package/es/{timeline-definition-YZTLITO2-C7Vz32PK.js → timeline-definition-YZTLITO2-ErcRjbZf.js} +2 -2
  75. package/es/treemap-KZPCXAKY-CvZAIYVa.js +3 -0
  76. package/es/{vennDiagram-LZ73GAT5-BWloH3fI.js → vennDiagram-LZ73GAT5-CDTZUtc8.js} +104 -104
  77. package/es/{xychartDiagram-JWTSCODW-l-SVBlqB.js → xychartDiagram-JWTSCODW-Y21jBOTg.js} +98 -98
  78. package/package.json +1 -1
  79. package/es/architecture-PBZL5I3N-BdQzc3t9.js +0 -3
  80. package/es/classDiagram-VBA2DB6C-wt_pcvEN.js +0 -29
  81. package/es/classDiagram-v2-RAHNMMFH-B8Bw4b3n.js +0 -29
  82. package/es/dagre-KLK3FWXG-DLgOeqbz.js +0 -294
  83. package/es/gitGraph-HDMCJU4V-CGPcRI5K.js +0 -3
  84. package/es/info-3K5VOQVL-D6bOjfim.js +0 -3
  85. package/es/packet-RMMSAZCW-CW6reTze.js +0 -3
  86. package/es/pie-UPGHQEXC-ByJXXnsc.js +0 -3
  87. package/es/radar-KQ55EAFF-DLq-eYVH.js +0 -3
  88. package/es/stateDiagram-v2-FVOUBMTO-uxSkj8dH.js +0 -27
  89. package/es/treemap-KZPCXAKY-BhLuAwPA.js +0 -3
  90. /package/es/{isArrayLikeObject-D4gDJaEW.js → isArrayLikeObject-jl2bjkAJ.js} +0 -0
  91. /package/es/{katex-Bvh2oRWI.js → katex-DCMiIo1z.js} +0 -0
  92. /package/es/{src-CFVe5TPD.js → src-CUQ6oOYk.js} +0 -0
@@ -0,0 +1,29 @@
1
+ import { h as e } from "./src-CUQ6oOYk.js";
2
+ import "./chunk-GEFDOKGD-BWpC-zoH.js";
3
+ import "./chunk-7R4GIKGN-QT6IorJ_.js";
4
+ import "./chunk-PU5JKC2W-DdP8BS-S.js";
5
+ import "./chunk-FMBD7UC4-DCcRjunY.js";
6
+ import "./chunk-MX3YWQON-BxE-Aq9c.js";
7
+ import "./chunk-YBOYWFTD-CvaddD9G.js";
8
+ import "./chunk-JSJVCQXG-D8_heHOp.js";
9
+ import "./chunk-55IACEB6-DGtfGRgi.js";
10
+ import "./chunk-KX2RTZJC-D5cc4rj6.js";
11
+ import "./chunk-PQ6SQG4A-D3jtNCWN.js";
12
+ import "./chunk-KYZI473N-BHJ3T5Zv.js";
13
+ import "./chunk-O4XLMI2P-qjOoGpnx.js";
14
+ import "./chunk-GLR3WWYH-DiXcKb5Y.js";
15
+ import { i as t, n, r, t as i } from "./chunk-WL4C6EOR-BDbxJyGk.js";
16
+ //#region ../../node_modules/.pnpm/mermaid@11.13.0/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-v2-RAHNMMFH.mjs
17
+ var a = {
18
+ parser: n,
19
+ get db() {
20
+ return new i();
21
+ },
22
+ renderer: r,
23
+ styles: t,
24
+ init: /* @__PURE__ */ e((e) => {
25
+ e.class ||= {}, e.class.arrowMarkerAbsolute = e.arrowMarkerAbsolute;
26
+ }, "init")
27
+ };
28
+ //#endregion
29
+ export { a as diagram };
@@ -1,4 +1,4 @@
1
- import { y as e } from "./_baseUniq-DY3uHjSO.js";
1
+ import { y as e } from "./_baseUniq-BlS7rXTs.js";
2
2
  //#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/clone.js
3
3
  var t = 4;
4
4
  function n(n) {
@@ -1,5 +1,5 @@
1
1
  import { o as e, t } from "./chunk-WQLz0Won.js";
2
- import { g as n, h as r, p as i } from "./src-CFVe5TPD.js";
2
+ import { g as n, h as r, p as i } from "./src-CUQ6oOYk.js";
3
3
  import { t as a } from "./cytoscape.esm-i2CZcWd-.js";
4
4
  //#region ../../node_modules/.pnpm/layout-base@1.0.2/node_modules/layout-base/layout-base.js
5
5
  var o = /* @__PURE__ */ t(((e, t) => {
@@ -1,9 +1,9 @@
1
- import { C as e, D as t, E as n, G as r, N as i, P as a, V as o, j as s, k as c, n as l, p as u, v as d, w as f, z as p } from "./isArrayLikeObject-D4gDJaEW.js";
2
- import { C as m, E as ee, M as h, N as te, S as ne, a as g, c as re, d as ie, f as _, i as v, m as ae, n as y, p as oe, r as b, s as x, y as se } from "./_baseUniq-DY3uHjSO.js";
3
- import { a as ce, c as le, d as ue, f as S, i as de, l as C, m as w, n as T, o as fe, r as pe, s as E, t as me, u as D } from "./_basePickBy-DZiMKfOQ.js";
4
- import { i as he, n as ge } from "./isEmpty-BgdRybYg.js";
5
- import { k as O } from "./chunk-GEFDOKGD-BWt_f4io.js";
6
- import { t as k } from "./graphlib-WtNUGuyd.js";
1
+ import { C as e, D as t, E as n, G as r, N as i, P as a, V as o, j as s, k as c, n as l, p as u, v as d, w as f, z as p } from "./isArrayLikeObject-jl2bjkAJ.js";
2
+ import { C as m, E as ee, M as h, N as te, S as ne, a as g, c as re, d as ie, f as _, i as v, m as ae, n as y, p as oe, r as b, s as x, y as se } from "./_baseUniq-BlS7rXTs.js";
3
+ import { a as ce, c as le, d as ue, f as S, i as de, l as C, m as w, n as T, o as fe, r as pe, s as E, t as me, u as D } from "./_basePickBy-DFHEGO2M.js";
4
+ import { i as he, n as ge } from "./isEmpty-CmA-HYrg.js";
5
+ import { k as O } from "./chunk-GEFDOKGD-BWpC-zoH.js";
6
+ import { t as k } from "./graphlib-dRkI1OCL.js";
7
7
  //#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_flatRest.js
8
8
  function _e(e) {
9
9
  return i(t(e, void 0, S), e + "");
@@ -0,0 +1,294 @@
1
+ import { g as e, h as t } from "./src-CUQ6oOYk.js";
2
+ import { r as n } from "./_baseUniq-BlS7rXTs.js";
3
+ import { s as r } from "./_basePickBy-DFHEGO2M.js";
4
+ import { t as i } from "./dagre-5aGJFKmT.js";
5
+ import "./chunk-GEFDOKGD-BWpC-zoH.js";
6
+ import { t as a } from "./clone-r3YukIBB.js";
7
+ import { t as o } from "./graphlib-dRkI1OCL.js";
8
+ import { b as s } from "./chunk-7R4GIKGN-QT6IorJ_.js";
9
+ import "./chunk-PU5JKC2W-DdP8BS-S.js";
10
+ import "./chunk-MX3YWQON-BxE-Aq9c.js";
11
+ import { n as c } from "./chunk-YBOYWFTD-CvaddD9G.js";
12
+ import "./chunk-PQ6SQG4A-D3jtNCWN.js";
13
+ import { a as l, c as u, i as d, l as f, n as p, t as m, u as h } from "./chunk-KYZI473N-BHJ3T5Zv.js";
14
+ import { a as g, i as _, n as v, r as y, t as b } from "./chunk-O4XLMI2P-qjOoGpnx.js";
15
+ //#region ../../node_modules/.pnpm/dagre-d3-es@7.0.14/node_modules/dagre-d3-es/src/graphlib/json.js
16
+ function x(e) {
17
+ var t = {
18
+ options: {
19
+ directed: e.isDirected(),
20
+ multigraph: e.isMultigraph(),
21
+ compound: e.isCompound()
22
+ },
23
+ nodes: S(e),
24
+ edges: C(e)
25
+ };
26
+ return n(e.graph()) || (t.value = a(e.graph())), t;
27
+ }
28
+ function S(e) {
29
+ return r(e.nodes(), function(t) {
30
+ var r = e.node(t), i = e.parent(t), a = { v: t };
31
+ return n(r) || (a.value = r), n(i) || (a.parent = i), a;
32
+ });
33
+ }
34
+ function C(e) {
35
+ return r(e.edges(), function(t) {
36
+ var r = e.edge(t), i = {
37
+ v: t.v,
38
+ w: t.w
39
+ };
40
+ return n(t.name) || (i.name = t.name), n(r) || (i.value = r), i;
41
+ });
42
+ }
43
+ //#endregion
44
+ //#region ../../node_modules/.pnpm/mermaid@11.13.0/node_modules/mermaid/dist/chunks/mermaid.core/dagre-KLK3FWXG.mjs
45
+ var w = /* @__PURE__ */ new Map(), T = /* @__PURE__ */ new Map(), E = /* @__PURE__ */ new Map(), D = /* @__PURE__ */ t(() => {
46
+ T.clear(), E.clear(), w.clear();
47
+ }, "clear"), O = /* @__PURE__ */ t((t, n) => {
48
+ let r = T.get(n) || [];
49
+ return e.trace("In isDescendant", n, " ", t, " = ", r.includes(t)), r.includes(t);
50
+ }, "isDescendant"), k = /* @__PURE__ */ t((t, n) => {
51
+ let r = T.get(n) || [];
52
+ return e.info("Descendants of ", n, " is ", r), e.info("Edge is ", t), t.v === n || t.w === n ? !1 : r ? r.includes(t.v) || O(t.v, n) || O(t.w, n) || r.includes(t.w) : (e.debug("Tilt, ", n, ",not in descendants"), !1);
53
+ }, "edgeInCluster"), A = /* @__PURE__ */ t((t, n, r, i) => {
54
+ e.warn("Copying children of ", t, "root", i, "data", n.node(t), i);
55
+ let a = n.children(t) || [];
56
+ t !== i && a.push(t), e.warn("Copying (nodes) clusterId", t, "nodes", a), a.forEach((a) => {
57
+ if (n.children(a).length > 0) A(a, n, r, i);
58
+ else {
59
+ let o = n.node(a);
60
+ e.info("cp ", a, " to ", i, " with parent ", t), r.setNode(a, o), i !== n.parent(a) && (e.warn("Setting parent", a, n.parent(a)), r.setParent(a, n.parent(a))), t !== i && a !== t ? (e.debug("Setting parent", a, t), r.setParent(a, t)) : (e.info("In copy ", t, "root", i, "data", n.node(t), i), e.debug("Not Setting parent for node=", a, "cluster!==rootId", t !== i, "node!==clusterId", a !== t));
61
+ let s = n.edges(a);
62
+ e.debug("Copying Edges", s), s.forEach((a) => {
63
+ e.info("Edge", a);
64
+ let o = n.edge(a.v, a.w, a.name);
65
+ e.info("Edge data", o, i);
66
+ try {
67
+ k(a, i) ? (e.info("Copying as ", a.v, a.w, o, a.name), r.setEdge(a.v, a.w, o, a.name), e.info("newGraph edges ", r.edges(), r.edge(r.edges()[0]))) : e.info("Skipping copy of edge ", a.v, "-->", a.w, " rootId: ", i, " clusterId:", t);
68
+ } catch (t) {
69
+ e.error(t);
70
+ }
71
+ });
72
+ }
73
+ e.debug("Removing node", a), n.removeNode(a);
74
+ });
75
+ }, "copy"), j = /* @__PURE__ */ t((e, t) => {
76
+ let n = t.children(e), r = [...n];
77
+ for (let i of n) E.set(i, e), r = [...r, ...j(i, t)];
78
+ return r;
79
+ }, "extractDescendants"), M = /* @__PURE__ */ t((e, t, n) => {
80
+ let r = e.edges().filter((e) => e.v === t || e.w === t), i = e.edges().filter((e) => e.v === n || e.w === n), a = r.map((e) => ({
81
+ v: e.v === t ? n : e.v,
82
+ w: e.w === t ? t : e.w
83
+ })), o = i.map((e) => ({
84
+ v: e.v,
85
+ w: e.w
86
+ }));
87
+ return a.filter((e) => o.some((t) => e.v === t.v && e.w === t.w));
88
+ }, "findCommonEdges"), N = /* @__PURE__ */ t((t, n, r) => {
89
+ let i = n.children(t);
90
+ if (e.trace("Searching children of id ", t, i), i.length < 1) return t;
91
+ let a;
92
+ for (let e of i) {
93
+ let t = N(e, n, r), i = M(n, r, t);
94
+ if (t) if (i.length > 0) a = t;
95
+ else return t;
96
+ }
97
+ return a;
98
+ }, "findNonClusterChild"), P = /* @__PURE__ */ t((e) => !w.has(e) || !w.get(e).externalConnections ? e : w.has(e) ? w.get(e).id : e, "getAnchorId"), F = /* @__PURE__ */ t((t, n) => {
99
+ if (!t || n > 10) {
100
+ e.debug("Opting out, no graph ");
101
+ return;
102
+ } else e.debug("Opting in, graph ");
103
+ t.nodes().forEach(function(n) {
104
+ t.children(n).length > 0 && (e.warn("Cluster identified", n, " Replacement id in edges: ", N(n, t, n)), T.set(n, j(n, t)), w.set(n, {
105
+ id: N(n, t, n),
106
+ clusterData: t.node(n)
107
+ }));
108
+ }), t.nodes().forEach(function(n) {
109
+ let r = t.children(n), i = t.edges();
110
+ r.length > 0 ? (e.debug("Cluster identified", n, T), i.forEach((t) => {
111
+ O(t.v, n) ^ O(t.w, n) && (e.warn("Edge: ", t, " leaves cluster ", n), e.warn("Descendants of XXX ", n, ": ", T.get(n)), w.get(n).externalConnections = !0);
112
+ })) : e.debug("Not a cluster ", n, T);
113
+ });
114
+ for (let e of w.keys()) {
115
+ let n = w.get(e).id, r = t.parent(n);
116
+ r !== e && w.has(r) && !w.get(r).externalConnections && (w.get(e).id = r);
117
+ }
118
+ t.edges().forEach(function(n) {
119
+ let r = t.edge(n);
120
+ e.warn("Edge " + n.v + " -> " + n.w + ": " + JSON.stringify(n)), e.warn("Edge " + n.v + " -> " + n.w + ": " + JSON.stringify(t.edge(n)));
121
+ let i = n.v, a = n.w;
122
+ if (e.warn("Fix XXX", w, "ids:", n.v, n.w, "Translating: ", w.get(n.v), " --- ", w.get(n.w)), w.get(n.v) || w.get(n.w)) {
123
+ if (e.warn("Fixing and trying - removing XXX", n.v, n.w, n.name), i = P(n.v), a = P(n.w), t.removeEdge(n.v, n.w, n.name), i !== n.v) {
124
+ let e = t.parent(i);
125
+ w.get(e).externalConnections = !0, r.fromCluster = n.v;
126
+ }
127
+ if (a !== n.w) {
128
+ let e = t.parent(a);
129
+ w.get(e).externalConnections = !0, r.toCluster = n.w;
130
+ }
131
+ e.warn("Fix Replacing with XXX", i, a, n.name), t.setEdge(i, a, r, n.name);
132
+ }
133
+ }), e.warn("Adjusted Graph", x(t)), I(t, 0), e.trace(w);
134
+ }, "adjustClustersAndEdges"), I = /* @__PURE__ */ t((t, n) => {
135
+ if (e.warn("extractor - ", n, x(t), t.children("D")), n > 10) {
136
+ e.error("Bailing out");
137
+ return;
138
+ }
139
+ let r = t.nodes(), i = !1;
140
+ for (let e of r) {
141
+ let n = t.children(e);
142
+ i ||= n.length > 0;
143
+ }
144
+ if (!i) {
145
+ e.debug("Done, no node has children", t.nodes());
146
+ return;
147
+ }
148
+ e.debug("Nodes = ", r, n);
149
+ for (let i of r) if (e.debug("Extracting node", i, w, w.has(i) && !w.get(i).externalConnections, !t.parent(i), t.node(i), t.children("D"), " Depth ", n), !w.has(i)) e.debug("Not a cluster", i, n);
150
+ else if (!w.get(i).externalConnections && t.children(i) && t.children(i).length > 0) {
151
+ e.warn("Cluster without external connections, without a parent and with children", i, n);
152
+ let r = t.graph().rankdir === "TB" ? "LR" : "TB";
153
+ w.get(i)?.clusterData?.dir && (r = w.get(i).clusterData.dir, e.warn("Fixing dir", w.get(i).clusterData.dir, r));
154
+ let a = new o({
155
+ multigraph: !0,
156
+ compound: !0
157
+ }).setGraph({
158
+ rankdir: r,
159
+ nodesep: 50,
160
+ ranksep: 50,
161
+ marginx: 8,
162
+ marginy: 8
163
+ }).setDefaultEdgeLabel(function() {
164
+ return {};
165
+ });
166
+ e.warn("Old graph before copy", x(t)), A(i, t, a, i), t.setNode(i, {
167
+ clusterNode: !0,
168
+ id: i,
169
+ clusterData: w.get(i).clusterData,
170
+ label: w.get(i).label,
171
+ graph: a
172
+ }), e.warn("New graph after copy node: (", i, ")", x(a)), e.debug("Old graph after copy", x(t));
173
+ } else e.warn("Cluster ** ", i, " **not meeting the criteria !externalConnections:", !w.get(i).externalConnections, " no parent: ", !t.parent(i), " children ", t.children(i) && t.children(i).length > 0, t.children("D"), n), e.debug(w);
174
+ r = t.nodes(), e.warn("New list of nodes", r);
175
+ for (let i of r) {
176
+ let r = t.node(i);
177
+ e.warn(" Now next level", i, r), r?.clusterNode && I(r.graph, n + 1);
178
+ }
179
+ }, "extractor"), L = /* @__PURE__ */ t((e, t) => {
180
+ if (t.length === 0) return [];
181
+ let n = Object.assign([], t);
182
+ return t.forEach((t) => {
183
+ let r = L(e, e.children(t));
184
+ n = [...n, ...r];
185
+ }), n;
186
+ }, "sorter"), R = /* @__PURE__ */ t((e) => L(e, e.children()), "sortNodesByHierarchy"), z = /* @__PURE__ */ t(async (n, r, a, o, s, p) => {
187
+ e.warn("Graph in recursive render:XAX", x(r), s);
188
+ let m = r.graph().rankdir;
189
+ e.trace("Dir in recursive render - dir:", m);
190
+ let _ = n.insert("g").attr("class", "root");
191
+ r.nodes() ? e.info("Recursive render XXX", r.nodes()) : e.info("No nodes found for", r), r.edges().length > 0 && e.info("Recursive edges", r.edge(r.edges()[0]));
192
+ let b = _.insert("g").attr("class", "clusters"), S = _.insert("g").attr("class", "edgePaths"), C = _.insert("g").attr("class", "edgeLabels"), T = _.insert("g").attr("class", "nodes");
193
+ await Promise.all(r.nodes().map(async function(t) {
194
+ let n = r.node(t);
195
+ if (s !== void 0) {
196
+ let n = JSON.parse(JSON.stringify(s.clusterData));
197
+ e.trace("Setting data for parent cluster XXX\n Node.id = ", t, "\n data=", n.height, "\nParent cluster", s.height), r.setNode(s.id, n), r.parent(t) || (e.trace("Setting parent", t, s.id), r.setParent(t, s.id, n));
198
+ }
199
+ if (e.info("(Insert) Node XXX" + t + ": " + JSON.stringify(r.node(t))), n?.clusterNode) {
200
+ e.info("Cluster identified XBX", t, n.width, r.node(t));
201
+ let { ranksep: i, nodesep: s } = r.graph();
202
+ n.graph.setGraph({
203
+ ...n.graph.graph(),
204
+ ranksep: i + 25,
205
+ nodesep: s
206
+ });
207
+ let c = await z(T, n.graph, a, o, r.node(t), p), l = c.elem;
208
+ h(n, l), n.diff = c.diff || 0, e.info("New compound node after recursive render XAX", t, "width", n.width, "height", n.height), f(l, n);
209
+ } else r.children(t).length > 0 ? (e.trace("Cluster - the non recursive path XBX", t, n.id, n, n.width, "Graph:", r), e.trace(N(n.id, r)), w.set(n.id, {
210
+ id: N(n.id, r),
211
+ node: n
212
+ })) : (e.trace("Node - the non recursive path XAX", t, T, r.node(t), m), await l(T, r.node(t), {
213
+ config: p,
214
+ dir: m
215
+ }));
216
+ })), await (/* @__PURE__ */ t(async () => {
217
+ let t = r.edges().map(async function(t) {
218
+ let n = r.edge(t.v, t.w, t.name);
219
+ e.info("Edge " + t.v + " -> " + t.w + ": " + JSON.stringify(t)), e.info("Edge " + t.v + " -> " + t.w + ": ", t, " ", JSON.stringify(r.edge(t))), e.info("Fix", w, "ids:", t.v, t.w, "Translating: ", w.get(t.v), w.get(t.w)), await y(C, n);
220
+ });
221
+ await Promise.all(t);
222
+ }, "processEdges"))(), e.info("Graph before layout:", JSON.stringify(x(r))), e.info("############################################# XXX"), e.info("### Layout ### XXX"), e.info("############################################# XXX"), i(r), e.info("Graph after layout:", JSON.stringify(x(r)));
223
+ let E = 0, { subGraphTitleTotalMargin: D } = c(p);
224
+ return await Promise.all(R(r).map(async function(t) {
225
+ let n = r.node(t);
226
+ if (e.info("Position XBX => " + t + ": (" + n.x, "," + n.y, ") width: ", n.width, " height: ", n.height), n?.clusterNode) n.y += D, e.info("A tainted cluster node XBX1", t, n.id, n.width, n.height, n.x, n.y, r.parent(t)), w.get(n.id).node = n, u(n);
227
+ else if (r.children(t).length > 0) {
228
+ e.info("A pure cluster node XBX1", t, n.id, n.x, n.y, n.width, n.height, r.parent(t)), n.height += D, r.node(n.parentId);
229
+ let i = n?.padding / 2 || 0, a = n?.labelBBox?.height || 0, o = a - i || 0;
230
+ e.debug("OffsetY", o, "labelHeight", a, "halfPadding", i), await d(b, n), w.get(n.id).node = n;
231
+ } else {
232
+ let t = r.node(n.parentId);
233
+ n.y += D / 2, e.info("A regular node XBX1 - using the padding", n.id, "parent", n.parentId, n.width, n.height, n.x, n.y, "offsetY", n.offsetY, "parent", t, t?.offsetY, n), u(n);
234
+ }
235
+ })), r.edges().forEach(function(t) {
236
+ let n = r.edge(t);
237
+ e.info("Edge " + t.v + " -> " + t.w + ": " + JSON.stringify(n), n), n.points.forEach((e) => e.y += D / 2), g(n, v(S, n, w, a, r.node(t.v), r.node(t.w), o));
238
+ }), r.nodes().forEach(function(t) {
239
+ let n = r.node(t);
240
+ e.info(t, n.type, n.diff), n.isGroup && (E = n.diff);
241
+ }), e.warn("Returning from recursive render XAX", _, E), {
242
+ elem: _,
243
+ diff: E
244
+ };
245
+ }, "recursiveRender"), B = /* @__PURE__ */ t(async (t, n) => {
246
+ let r = new o({
247
+ multigraph: !0,
248
+ compound: !0
249
+ }).setGraph({
250
+ rankdir: t.direction,
251
+ nodesep: t.config?.nodeSpacing || t.config?.flowchart?.nodeSpacing || t.nodeSpacing,
252
+ ranksep: t.config?.rankSpacing || t.config?.flowchart?.rankSpacing || t.rankSpacing,
253
+ marginx: 8,
254
+ marginy: 8
255
+ }).setDefaultEdgeLabel(function() {
256
+ return {};
257
+ }), i = n.select("g");
258
+ _(i, t.markers, t.type, t.diagramId), p(), b(), m(), D(), t.nodes.forEach((e) => {
259
+ r.setNode(e.id, { ...e }), e.parentId && r.setParent(e.id, e.parentId);
260
+ }), e.debug("Edges:", t.edges), t.edges.forEach((e) => {
261
+ if (e.start === e.end) {
262
+ let t = e.start, n = t + "---" + t + "---1", i = t + "---" + t + "---2", a = r.node(t);
263
+ r.setNode(n, {
264
+ domId: n,
265
+ id: n,
266
+ parentId: a.parentId,
267
+ labelStyle: "",
268
+ label: "",
269
+ padding: 0,
270
+ shape: "labelRect",
271
+ style: "",
272
+ width: 10,
273
+ height: 10
274
+ }), r.setParent(n, a.parentId), r.setNode(i, {
275
+ domId: i,
276
+ id: i,
277
+ parentId: a.parentId,
278
+ labelStyle: "",
279
+ padding: 0,
280
+ shape: "labelRect",
281
+ label: "",
282
+ style: "",
283
+ width: 10,
284
+ height: 10
285
+ }), r.setParent(i, a.parentId);
286
+ let o = structuredClone(e), s = structuredClone(e), c = structuredClone(e);
287
+ o.label = "", o.arrowTypeEnd = "none", o.id = t + "-cyclic-special-1", s.arrowTypeStart = "none", s.arrowTypeEnd = "none", s.id = t + "-cyclic-special-mid", c.label = "", a.isGroup && (o.fromCluster = t, c.toCluster = t), c.id = t + "-cyclic-special-2", c.arrowTypeStart = "none", r.setEdge(t, n, o, t + "-cyclic-special-0"), r.setEdge(n, i, s, t + "-cyclic-special-1"), r.setEdge(i, t, c, t + "-cyc<lic-special-2");
288
+ } else r.setEdge(e.start, e.end, { ...e }, e.id);
289
+ }), e.warn("Graph at first:", JSON.stringify(x(r))), F(r), e.warn("Graph after XAX:", JSON.stringify(x(r)));
290
+ let a = s();
291
+ await z(i, r, t.type, t.diagramId, void 0, a);
292
+ }, "render");
293
+ //#endregion
294
+ export { B as render };
@@ -1,13 +1,13 @@
1
- import { r as e } from "./chunk-GEFDOKGD-BWt_f4io.js";
2
- import { g as t, h as n, p as r } from "./src-CFVe5TPD.js";
3
- import { B as i, C as a, V as o, W as s, _ as c, a as l, c as u, d, v as f, y as p } from "./chunk-7R4GIKGN-CaI-1szl.js";
1
+ import { g as e, h as t, p as n } from "./src-CUQ6oOYk.js";
2
+ import { r } from "./chunk-GEFDOKGD-BWpC-zoH.js";
3
+ import { B as i, C as a, V as o, W as s, _ as c, a as l, c as u, d, v as f, y as p } from "./chunk-7R4GIKGN-QT6IorJ_.js";
4
4
  import { t as m } from "./ordinal-F3U6aXtP.js";
5
5
  import { t as h } from "./defaultLocale-bckJcYh1.js";
6
- import { t as g } from "./chunk-HHEYEP7N-DkMnkoQX.js";
7
- import { t as _ } from "./chunk-4BX2VUAB-B3zzxglQ.js";
8
- import { t as v } from "./mermaid-parser.core-DXn-0ev4.js";
9
- import { t as y } from "./chunk-KX2RTZJC-BbnGQVgL.js";
10
- import { i as b, n as x } from "./chunk-PQ6SQG4A-Dx7no2mb.js";
6
+ import { t as g } from "./chunk-HHEYEP7N-Cxc7E4dX.js";
7
+ import { t as _ } from "./chunk-4BX2VUAB-J2N81Fpp.js";
8
+ import { t as v } from "./mermaid-parser.core-7Wn2L29P.js";
9
+ import { t as y } from "./chunk-KX2RTZJC-D5cc4rj6.js";
10
+ import { i as b, n as x } from "./chunk-PQ6SQG4A-D3jtNCWN.js";
11
11
  //#region ../../node_modules/.pnpm/d3-hierarchy@3.1.2/node_modules/d3-hierarchy/src/hierarchy/count.js
12
12
  function S(e) {
13
13
  var t = 0, n = e.children, r = n && n.length;
@@ -258,16 +258,16 @@ var Y = class {
258
258
  this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.setAccTitle = o, this.getAccTitle = f, this.setDiagramTitle = s, this.getDiagramTitle = a, this.getAccDescription = c, this.setAccDescription = i;
259
259
  }
260
260
  static {
261
- n(this, "TreeMapDB");
261
+ t(this, "TreeMapDB");
262
262
  }
263
263
  getNodes() {
264
264
  return this.nodes;
265
265
  }
266
266
  getConfig() {
267
- let t = d, n = p();
268
- return e({
269
- ...t.treemap,
270
- ...n.treemap ?? {}
267
+ let e = d, t = p();
268
+ return r({
269
+ ...e.treemap,
270
+ ...t.treemap ?? {}
271
271
  });
272
272
  }
273
273
  addNode(e, t) {
@@ -319,15 +319,15 @@ function X(e) {
319
319
  });
320
320
  }), t;
321
321
  }
322
- n(X, "buildHierarchy");
323
- var ae = /* @__PURE__ */ n((e, t) => {
324
- _(e, t);
322
+ t(X, "buildHierarchy");
323
+ var ae = /* @__PURE__ */ t((e, n) => {
324
+ _(e, n);
325
325
  let r = [];
326
- for (let n of e.TreemapRows ?? []) n.$type === "ClassDefStatement" && t.addClass(n.className ?? "", n.styleText ?? "");
327
- for (let n of e.TreemapRows ?? []) {
328
- let e = n.item;
326
+ for (let t of e.TreemapRows ?? []) t.$type === "ClassDefStatement" && n.addClass(t.className ?? "", t.styleText ?? "");
327
+ for (let t of e.TreemapRows ?? []) {
328
+ let e = t.item;
329
329
  if (!e) continue;
330
- let i = n.indent ? parseInt(n.indent) : 0, a = oe(e), o = e.classSelector ? t.getStylesForClass(e.classSelector) : [], s = o.length > 0 ? o : void 0, c = {
330
+ let i = t.indent ? parseInt(t.indent) : 0, a = oe(e), o = e.classSelector ? n.getStylesForClass(e.classSelector) : [], s = o.length > 0 ? o : void 0, c = {
331
331
  level: i,
332
332
  name: a,
333
333
  type: e.$type,
@@ -337,25 +337,25 @@ var ae = /* @__PURE__ */ n((e, t) => {
337
337
  };
338
338
  r.push(c);
339
339
  }
340
- let i = X(r), a = /* @__PURE__ */ n((e, n) => {
341
- for (let r of e) t.addNode(r, n), r.children && r.children.length > 0 && a(r.children, n + 1);
340
+ let i = X(r), a = /* @__PURE__ */ t((e, t) => {
341
+ for (let r of e) n.addNode(r, t), r.children && r.children.length > 0 && a(r.children, t + 1);
342
342
  }, "addNodesRecursively");
343
343
  a(i, 0);
344
- }, "populate"), oe = /* @__PURE__ */ n((e) => e.name ? String(e.name) : "", "getItemName"), Z = {
344
+ }, "populate"), oe = /* @__PURE__ */ t((e) => e.name ? String(e.name) : "", "getItemName"), Z = {
345
345
  parser: { yy: void 0 },
346
- parse: /* @__PURE__ */ n(async (e) => {
346
+ parse: /* @__PURE__ */ t(async (t) => {
347
347
  try {
348
- let n = await v("treemap", e);
349
- t.debug("Treemap AST:", n);
348
+ let n = await v("treemap", t);
349
+ e.debug("Treemap AST:", n);
350
350
  let r = Z.parser?.yy;
351
351
  if (!(r instanceof Y)) throw Error("parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");
352
352
  ae(n, r);
353
- } catch (e) {
354
- throw t.error("Error parsing treemap:", e), e;
353
+ } catch (t) {
354
+ throw e.error("Error parsing treemap:", t), t;
355
355
  }
356
356
  }, "parse")
357
357
  }, se = 10, Q = 10, $ = 25, ce = {
358
- draw: /* @__PURE__ */ n((e, i, a, o) => {
358
+ draw: /* @__PURE__ */ t((r, i, a, o) => {
359
359
  let s = o.db, c = s.getConfig(), l = c.padding ?? se, d = s.getDiagramTitle(), f = s.getRoot(), { themeVariables: _ } = p();
360
360
  if (!f) return;
361
361
  let v = d ? 30 : 0, x = g(i), S = c.nodeWidth ? c.nodeWidth * Q : 960, C = c.nodeHeight ? c.nodeHeight * Q : 500, w = S, T = C + v;
@@ -363,16 +363,16 @@ var ae = /* @__PURE__ */ n((e, t) => {
363
363
  let E;
364
364
  try {
365
365
  let e = c.valueFormat || ",";
366
- if (e === "$0,0") E = /* @__PURE__ */ n((e) => "$" + h(",")(e), "valueFormat");
366
+ if (e === "$0,0") E = /* @__PURE__ */ t((e) => "$" + h(",")(e), "valueFormat");
367
367
  else if (e.startsWith("$") && e.includes(",")) {
368
- let t = /\.\d+/.exec(e), r = t ? t[0] : "";
369
- E = /* @__PURE__ */ n((e) => "$" + h("," + r)(e), "valueFormat");
368
+ let n = /\.\d+/.exec(e), r = n ? n[0] : "";
369
+ E = /* @__PURE__ */ t((e) => "$" + h("," + r)(e), "valueFormat");
370
370
  } else if (e.startsWith("$")) {
371
- let t = e.substring(1);
372
- E = /* @__PURE__ */ n((e) => "$" + h(t || "")(e), "valueFormat");
371
+ let n = e.substring(1);
372
+ E = /* @__PURE__ */ t((e) => "$" + h(n || "")(e), "valueFormat");
373
373
  } else E = h(e);
374
- } catch (e) {
375
- t.error("Error creating format function:", e), E = h(",");
374
+ } catch (t) {
375
+ e.error("Error creating format function:", t), E = h(",");
376
376
  }
377
377
  let D = m().range([
378
378
  "transparent",
@@ -424,15 +424,15 @@ var ae = /* @__PURE__ */ n((e, t) => {
424
424
  return t.nodeStyles + ";" + t.borderStyles.join(";");
425
425
  }), P.append("text").attr("class", "treemapSectionLabel").attr("x", 6).attr("y", $ / 2).attr("dominant-baseline", "middle").text((e) => e.depth === 0 ? "" : e.data.name).attr("font-weight", "bold").attr("style", (e) => e.depth === 0 ? "display: none;" : "dominant-baseline: middle; font-size: 12px; fill:" + k(e.data.name) + "; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;" + b({ cssCompiledStyles: e.data.cssCompiledStyles }).labelStyles.replace("color:", "fill:")).each(function(e) {
426
426
  if (e.depth === 0) return;
427
- let t = r(this), n = e.data.name;
428
- t.text(n);
427
+ let t = n(this), r = e.data.name;
428
+ t.text(r);
429
429
  let i = e.x1 - e.x0, a;
430
430
  a = c.showValues !== !1 && e.value ? i - 10 - 30 - 10 - 6 : i - 6 - 6;
431
431
  let o = Math.max(15, a), s = t.node();
432
432
  if (s.getComputedTextLength() > o) {
433
- let e = n;
433
+ let e = r;
434
434
  for (; e.length > 0;) {
435
- if (e = n.substring(0, e.length - 1), e.length === 0) {
435
+ if (e = r.substring(0, e.length - 1), e.length === 0) {
436
436
  t.text("..."), s.getComputedTextLength() > o && t.text("");
437
437
  break;
438
438
  }
@@ -442,7 +442,7 @@ var ae = /* @__PURE__ */ n((e, t) => {
442
442
  }), c.showValues !== !1 && P.append("text").attr("class", "treemapSectionValue").attr("x", (e) => e.x1 - e.x0 - 10).attr("y", $ / 2).attr("text-anchor", "end").attr("dominant-baseline", "middle").text((e) => e.value ? E(e.value) : "").attr("font-style", "italic").attr("style", (e) => e.depth === 0 ? "display: none;" : "text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:" + k(e.data.name) + "; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;" + b({ cssCompiledStyles: e.data.cssCompiledStyles }).labelStyles.replace("color:", "fill:"));
443
443
  let F = M.leaves(), I = A.selectAll(".treemapLeafGroup").data(F).enter().append("g").attr("class", (e, t) => `treemapNode treemapLeafGroup leaf${t}${e.data.classSelector ? ` ${e.data.classSelector}` : ""}x`).attr("transform", (e) => `translate(${e.x0},${e.y0})`);
444
444
  I.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", (e) => e.y1 - e.y0).attr("class", "treemapLeaf").attr("fill", (e) => e.parent ? D(e.parent.data.name) : D(e.data.name)).attr("style", (e) => b({ cssCompiledStyles: e.data.cssCompiledStyles }).nodeStyles).attr("fill-opacity", .3).attr("stroke", (e) => e.parent ? D(e.parent.data.name) : D(e.data.name)).attr("stroke-width", 3), I.append("clipPath").attr("id", (e, t) => `clip-${i}-${t}`).append("rect").attr("width", (e) => Math.max(0, e.x1 - e.x0 - 4)).attr("height", (e) => Math.max(0, e.y1 - e.y0 - 4)), I.append("text").attr("class", "treemapLabel").attr("x", (e) => (e.x1 - e.x0) / 2).attr("y", (e) => (e.y1 - e.y0) / 2).attr("style", (e) => "text-anchor: middle; dominant-baseline: middle; font-size: 38px;fill:" + k(e.data.name) + ";" + b({ cssCompiledStyles: e.data.cssCompiledStyles }).labelStyles.replace("color:", "fill:")).attr("clip-path", (e, t) => `url(#clip-${i}-${t})`).text((e) => e.data.name).each(function(e) {
445
- let t = r(this), n = e.x1 - e.x0, i = e.y1 - e.y0, a = t.node(), o = n - 8, s = i - 8;
445
+ let t = n(this), r = e.x1 - e.x0, i = e.y1 - e.y0, a = t.node(), o = r - 8, s = i - 8;
446
446
  if (o < 10 || s < 10) {
447
447
  t.style("display", "none");
448
448
  return;
@@ -455,12 +455,12 @@ var ae = /* @__PURE__ */ n((e, t) => {
455
455
  }), c.showValues !== !1 && I.append("text").attr("class", "treemapValue").attr("x", (e) => (e.x1 - e.x0) / 2).attr("y", function(e) {
456
456
  return (e.y1 - e.y0) / 2;
457
457
  }).attr("style", (e) => "text-anchor: middle; dominant-baseline: hanging; font-size: 28px;fill:" + k(e.data.name) + ";" + b({ cssCompiledStyles: e.data.cssCompiledStyles }).labelStyles.replace("color:", "fill:")).attr("clip-path", (e, t) => `url(#clip-${i}-${t})`).text((e) => e.value ? E(e.value) : "").each(function(e) {
458
- let t = r(this), n = this.parentNode;
459
- if (!n) {
458
+ let t = n(this), r = this.parentNode;
459
+ if (!r) {
460
460
  t.style("display", "none");
461
461
  return;
462
462
  }
463
- let i = r(n).select(".treemapLabel");
463
+ let i = n(r).select(".treemapLabel");
464
464
  if (i.empty() || i.style("display") === "none") {
465
465
  t.style("display", "none");
466
466
  return;
@@ -473,7 +473,7 @@ var ae = /* @__PURE__ */ n((e, t) => {
473
473
  t.node().getComputedTextLength() > u || s + o > l || o < 6 ? t.style("display", "none") : t.style("display", null);
474
474
  }), y(x, c.diagramPadding ?? 8, "flowchart", c?.useMaxWidth || !1);
475
475
  }, "draw"),
476
- getClasses: /* @__PURE__ */ n(function(e, t) {
476
+ getClasses: /* @__PURE__ */ t(function(e, t) {
477
477
  return t.db.getClasses();
478
478
  }, "getClasses")
479
479
  }, le = {
@@ -495,30 +495,30 @@ var ae = /* @__PURE__ */ n((e, t) => {
495
495
  return new Y();
496
496
  },
497
497
  renderer: ce,
498
- styles: /* @__PURE__ */ n(({ treemap: t } = {}) => {
499
- let n = e(le, t);
498
+ styles: /* @__PURE__ */ t(({ treemap: e } = {}) => {
499
+ let t = r(le, e);
500
500
  return `
501
501
  .treemapNode.section {
502
- stroke: ${n.sectionStrokeColor};
503
- stroke-width: ${n.sectionStrokeWidth};
504
- fill: ${n.sectionFillColor};
502
+ stroke: ${t.sectionStrokeColor};
503
+ stroke-width: ${t.sectionStrokeWidth};
504
+ fill: ${t.sectionFillColor};
505
505
  }
506
506
  .treemapNode.leaf {
507
- stroke: ${n.leafStrokeColor};
508
- stroke-width: ${n.leafStrokeWidth};
509
- fill: ${n.leafFillColor};
507
+ stroke: ${t.leafStrokeColor};
508
+ stroke-width: ${t.leafStrokeWidth};
509
+ fill: ${t.leafFillColor};
510
510
  }
511
511
  .treemapLabel {
512
- fill: ${n.labelColor};
513
- font-size: ${n.labelFontSize};
512
+ fill: ${t.labelColor};
513
+ font-size: ${t.labelFontSize};
514
514
  }
515
515
  .treemapValue {
516
- fill: ${n.valueColor};
517
- font-size: ${n.valueFontSize};
516
+ fill: ${t.valueColor};
517
+ font-size: ${t.valueFontSize};
518
518
  }
519
519
  .treemapTitle {
520
- fill: ${n.titleColor};
521
- font-size: ${n.titleFontSize};
520
+ fill: ${t.titleColor};
521
+ font-size: ${t.titleFontSize};
522
522
  }
523
523
  `;
524
524
  }, "getStyles")