bg-editor 0.0.1 → 0.0.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 (74) hide show
  1. package/dist/_baseUniq-DtZISqda.js +473 -0
  2. package/dist/{arc-wItjmL5I.js → arc-BpOtYBpP.js} +1 -7
  3. package/dist/architecture-U656AL7Q-BN22wDFh.js +6 -0
  4. package/dist/{architectureDiagram-VXUJARFQ-iG5MkBjx.js → architectureDiagram-VXUJARFQ-D90AF2uK.js} +4 -10
  5. package/dist/{blockDiagram-VD42YOAC-i2GlXmWy.js → blockDiagram-VD42YOAC-DXQNldkG.js} +5 -11
  6. package/dist/{c4Diagram-YG6GDRKO-IufO7T1R.js → c4Diagram-YG6GDRKO-Bl1xCfsC.js} +2 -8
  7. package/dist/channel-BiQYlsVc.js +6 -0
  8. package/dist/{chunk-4BX2VUAB-5_v9rnje.js → chunk-4BX2VUAB-JnvgOgeI.js} +1 -7
  9. package/dist/{chunk-55IACEB6-BDNtSypP.js → chunk-55IACEB6-DvzYdqd0.js} +1 -7
  10. package/dist/{chunk-B4BG7PRW-DzaYPsfW.js → chunk-B4BG7PRW-D2zs0pMT.js} +4 -10
  11. package/dist/{chunk-DI55MBZ5-Buwrprkw.js → chunk-DI55MBZ5-IhCs2q12.js} +3 -9
  12. package/dist/{chunk-FMBD7UC4-BaEPEIWb.js → chunk-FMBD7UC4-CI7_2stl.js} +1 -7
  13. package/dist/{chunk-QN33PNHL-DhbA7i5G.js → chunk-QN33PNHL-D3gdmDbi.js} +1 -7
  14. package/dist/{chunk-QZHKN3VN-BAb_D1oz.js → chunk-QZHKN3VN-BaqG_46X.js} +1 -7
  15. package/dist/{chunk-TZMSLE5B-OU1MJ2do.js → chunk-TZMSLE5B-fUTKpgTY.js} +1 -7
  16. package/dist/{classDiagram-v2-WZHVMYZB-KStC8v09.js → classDiagram-2ON5EDUG-BbUC7jyd.js} +2 -8
  17. package/dist/{classDiagram-2ON5EDUG-KStC8v09.js → classDiagram-v2-WZHVMYZB-BbUC7jyd.js} +2 -8
  18. package/dist/clone-CDwfUPH_.js +9 -0
  19. package/dist/{cose-bilkent-S5V4N54A-eRXCoix2.js → cose-bilkent-S5V4N54A-BfRx9IMy.js} +8 -14
  20. package/dist/{cytoscape.esm-BG3R4uVs.js → cytoscape.esm-DoU_GB5M.js} +0 -6
  21. package/dist/{dagre-6UL2VRFP-Bi83jPQf.js → dagre-6UL2VRFP-pX_n00Op.js} +116 -123
  22. package/dist/{defaultLocale-DgmhL6Re.js → defaultLocale-DEnRyJdC.js} +3 -9
  23. package/dist/diagram-PSM6KHXK-CwWsOtmB.js +396 -0
  24. package/dist/{diagram-QEK2KX5R-BR--iNM5.js → diagram-QEK2KX5R-Dxmoi6nm.js} +3 -9
  25. package/dist/{diagram-S2PKOQOG-NTnEy5_O.js → diagram-S2PKOQOG-HSYMJfV1.js} +3 -9
  26. package/dist/{erDiagram-Q2GNP2WA-C8oZ5c-S.js → erDiagram-Q2GNP2WA-DQP8lHpe.js} +4 -10
  27. package/dist/{flowDiagram-NV44I4VS-DiKad3Bb.js → flowDiagram-NV44I4VS-Cl_9jtIL.js} +5 -11
  28. package/dist/{ganttDiagram-LVOFAZNH-CthzjjJq.js → ganttDiagram-LVOFAZNH-CPmFv-yQ.js} +3 -9
  29. package/dist/gitGraph-F6HP7TQM-80sPVnm_.js +6 -0
  30. package/dist/{gitGraphDiagram-NY62KEGX-d4KszKqi.js → gitGraphDiagram-NY62KEGX-B-81Admd.js} +4 -10
  31. package/dist/graph-rMBrFJ2v.js +382 -0
  32. package/dist/index-D5tpgmxE.js +164793 -0
  33. package/dist/info-NVLQJR56-DBCgZtPg.js +6 -0
  34. package/dist/{infoDiagram-ER5ION4S-DedidjTu.js → infoDiagram-ER5ION4S-CqZmP7Ed.js} +2 -8
  35. package/dist/{init-d639unba.js → init-Dbt-6wo9.js} +0 -6
  36. package/dist/{journeyDiagram-XKPGCS4Q-BylvmUWL.js → journeyDiagram-XKPGCS4Q-Stv9y4h1.js} +4 -10
  37. package/dist/{kanban-definition-3W4ZIXB7-DGV_aVgU.js → kanban-definition-3W4ZIXB7-C5R0pumf.js} +2 -8
  38. package/dist/layout-DHK3CzAK.js +1416 -0
  39. package/dist/{linear-CO_vz87n.js → linear-CD94DoB6.js} +7 -13
  40. package/dist/{mermaid-parser.core-CYtF6phW.js → mermaid-parser.core-D1WCqkLE.js} +6707 -5492
  41. package/dist/min-CDOTJW1A.js +39 -0
  42. package/dist/{mindmap-definition-VGOIOE7T-BU05Y6Vz.js → mindmap-definition-VGOIOE7T-BONuOB6H.js} +11 -17
  43. package/dist/{ordinal-CofNqUw2.js → ordinal-mgyNSFm_.js} +1 -7
  44. package/dist/packet-BFZMPI3H-ByqiBqYS.js +6 -0
  45. package/dist/pie-7BOR55EZ-Bzv7npkH.js +6 -0
  46. package/dist/{pieDiagram-ADFJNKIX-reGTUsiW.js → pieDiagram-ADFJNKIX-CQ6y-x9k.js} +10 -16
  47. package/dist/{quadrantDiagram-AYHSOK5B-NeHOJ0lX.js → quadrantDiagram-AYHSOK5B-C4hTUyLY.js} +2 -8
  48. package/dist/radar-NHE76QYJ-OVSgPUhl.js +6 -0
  49. package/dist/{requirementDiagram-UZGBJVZJ-BE76XNaT.js → requirementDiagram-UZGBJVZJ-CM3F7AET.js} +3 -9
  50. package/dist/{sankeyDiagram-TZEHDZUN-UHfMLEKl.js → sankeyDiagram-TZEHDZUN-F2yxFEnc.js} +2 -8
  51. package/dist/{sequenceDiagram-WL72ISMW-62KWnVbh.js → sequenceDiagram-WL72ISMW-CZgiwPgi.js} +3 -9
  52. package/dist/{stateDiagram-FKZM4ZOC--_CkWvu6.js → stateDiagram-FKZM4ZOC-Bxzbhi-m.js} +4 -10
  53. package/dist/{stateDiagram-v2-4FDKWEC3-Dj7ZjAmI.js → stateDiagram-v2-4FDKWEC3-DfVPJhMD.js} +2 -8
  54. package/dist/style.css +1 -1
  55. package/dist/{timeline-definition-IT6M3QCI-C3Wb0xMN.js → timeline-definition-IT6M3QCI-_z700I-W.js} +2 -8
  56. package/dist/treemap-KMMF4GRG-D5Tr-XRi.js +6 -0
  57. package/dist/umo-editor.js +1 -7
  58. package/dist/{xychartDiagram-PRI3JC2R-D2J307cO.js → xychartDiagram-PRI3JC2R-yKhqmxR_.js} +4 -10
  59. package/package.json +6 -1
  60. package/dist/_basePickBy-4kmg42pS.js +0 -158
  61. package/dist/_baseUniq-WOvvCHTI.js +0 -621
  62. package/dist/architecture-U656AL7Q-FYDwFSxk.js +0 -12
  63. package/dist/channel-Dah4F59k.js +0 -12
  64. package/dist/clone-C74UiRbr.js +0 -15
  65. package/dist/diagram-PSM6KHXK-aW98k2-4.js +0 -539
  66. package/dist/gitGraph-F6HP7TQM-CuXAC0XT.js +0 -12
  67. package/dist/graph-CnOTx4E0.js +0 -254
  68. package/dist/index-D6-Wf75-.js +0 -122127
  69. package/dist/info-NVLQJR56-Dhmtdc7O.js +0 -12
  70. package/dist/layout-OXk4OSoz.js +0 -1342
  71. package/dist/packet-BFZMPI3H-D7H_8Q-U.js +0 -12
  72. package/dist/pie-7BOR55EZ-BNWNcO5Z.js +0 -12
  73. package/dist/radar-NHE76QYJ-DrVEcvh1.js +0 -12
  74. package/dist/treemap-KMMF4GRG-Bc8F2dFd.js +0 -12
@@ -0,0 +1,396 @@
1
+ import "./style.css";
2
+ import { _ as w, D as Q, E as ee, H as ce, e as de, l as J, aM as pe, aN as E, d as j, b as ue, a as he, p as fe, q as me, g as ge, s as ye, F as Se, aO as xe, y as ve } from "./index-D5tpgmxE.js";
3
+ import { s as be } from "./chunk-QN33PNHL-D3gdmDbi.js";
4
+ import { p as we } from "./chunk-4BX2VUAB-JnvgOgeI.js";
5
+ import { p as Ce } from "./mermaid-parser.core-D1WCqkLE.js";
6
+ import { f as O } from "./defaultLocale-DEnRyJdC.js";
7
+ import { o as Z } from "./ordinal-mgyNSFm_.js";
8
+ function Te(r) {
9
+ if (typeof r != "function") throw new Error();
10
+ return r;
11
+ }
12
+ function q() {
13
+ return 0;
14
+ }
15
+ function G(r) {
16
+ return function() {
17
+ return r;
18
+ };
19
+ }
20
+ function Le(r) {
21
+ r.x0 = Math.round(r.x0), r.y0 = Math.round(r.y0), r.x1 = Math.round(r.x1), r.y1 = Math.round(r.y1);
22
+ }
23
+ function $e(r, l, o, i, p) {
24
+ for (var s = r.children, c, h = -1, v = s.length, n = r.value && (i - l) / r.value; ++h < v; )
25
+ c = s[h], c.y0 = o, c.y1 = p, c.x0 = l, c.x1 = l += c.value * n;
26
+ }
27
+ function Fe(r, l, o, i, p) {
28
+ for (var s = r.children, c, h = -1, v = s.length, n = r.value && (p - o) / r.value; ++h < v; )
29
+ c = s[h], c.x0 = l, c.x1 = i, c.y0 = o, c.y1 = o += c.value * n;
30
+ }
31
+ var Me = (1 + Math.sqrt(5)) / 2;
32
+ function Ne(r, l, o, i, p, s) {
33
+ for (var c = [], h = l.children, v, n, d = 0, b = 0, t = h.length, x, y, S = l.value, u, m, k, N, D, B, z; d < t; ) {
34
+ x = p - o, y = s - i;
35
+ do
36
+ u = h[b++].value;
37
+ while (!u && b < t);
38
+ for (m = k = u, B = Math.max(y / x, x / y) / (S * r), z = u * u * B, D = Math.max(k / z, z / m); b < t; ++b) {
39
+ if (u += n = h[b].value, n < m && (m = n), n > k && (k = n), z = u * u * B, N = Math.max(k / z, z / m), N > D) {
40
+ u -= n;
41
+ break;
42
+ }
43
+ D = N;
44
+ }
45
+ c.push(v = { value: u, dice: x < y, children: h.slice(d, b) }), v.dice ? $e(v, o, i, p, S ? i += y * u / S : s) : Fe(v, o, i, S ? o += x * u / S : p, s), S -= u, d = b;
46
+ }
47
+ return c;
48
+ }
49
+ const ke = function r(l) {
50
+ function o(i, p, s, c, h) {
51
+ Ne(l, i, p, s, c, h);
52
+ }
53
+ return o.ratio = function(i) {
54
+ return r((i = +i) > 1 ? i : 1);
55
+ }, o;
56
+ }(Me);
57
+ function ze() {
58
+ var r = ke, l = !1, o = 1, i = 1, p = [0], s = q, c = q, h = q, v = q, n = q;
59
+ function d(t) {
60
+ return t.x0 = t.y0 = 0, t.x1 = o, t.y1 = i, t.eachBefore(b), p = [0], l && t.eachBefore(Le), t;
61
+ }
62
+ function b(t) {
63
+ var x = p[t.depth], y = t.x0 + x, S = t.y0 + x, u = t.x1 - x, m = t.y1 - x;
64
+ u < y && (y = u = (y + u) / 2), m < S && (S = m = (S + m) / 2), t.x0 = y, t.y0 = S, t.x1 = u, t.y1 = m, t.children && (x = p[t.depth + 1] = s(t) / 2, y += n(t) - x, S += c(t) - x, u -= h(t) - x, m -= v(t) - x, u < y && (y = u = (y + u) / 2), m < S && (S = m = (S + m) / 2), r(t, y, S, u, m));
65
+ }
66
+ return d.round = function(t) {
67
+ return arguments.length ? (l = !!t, d) : l;
68
+ }, d.size = function(t) {
69
+ return arguments.length ? (o = +t[0], i = +t[1], d) : [o, i];
70
+ }, d.tile = function(t) {
71
+ return arguments.length ? (r = Te(t), d) : r;
72
+ }, d.padding = function(t) {
73
+ return arguments.length ? d.paddingInner(t).paddingOuter(t) : d.paddingInner();
74
+ }, d.paddingInner = function(t) {
75
+ return arguments.length ? (s = typeof t == "function" ? t : G(+t), d) : s;
76
+ }, d.paddingOuter = function(t) {
77
+ return arguments.length ? d.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t) : d.paddingTop();
78
+ }, d.paddingTop = function(t) {
79
+ return arguments.length ? (c = typeof t == "function" ? t : G(+t), d) : c;
80
+ }, d.paddingRight = function(t) {
81
+ return arguments.length ? (h = typeof t == "function" ? t : G(+t), d) : h;
82
+ }, d.paddingBottom = function(t) {
83
+ return arguments.length ? (v = typeof t == "function" ? t : G(+t), d) : v;
84
+ }, d.paddingLeft = function(t) {
85
+ return arguments.length ? (n = typeof t == "function" ? t : G(+t), d) : n;
86
+ }, d;
87
+ }
88
+ var W, te = (W = class {
89
+ constructor() {
90
+ this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.setAccTitle = ue, this.getAccTitle = he, this.setDiagramTitle = fe, this.getDiagramTitle = me, this.getAccDescription = ge, this.setAccDescription = ye;
91
+ }
92
+ getNodes() {
93
+ return this.nodes;
94
+ }
95
+ getConfig() {
96
+ const l = Se, o = ee();
97
+ return Q({
98
+ ...l.treemap,
99
+ ...o.treemap ?? {}
100
+ });
101
+ }
102
+ addNode(l, o) {
103
+ this.nodes.push(l), this.levels.set(l, o), o === 0 && (this.outerNodes.push(l), this.root ?? (this.root = l));
104
+ }
105
+ getRoot() {
106
+ return { name: "", children: this.outerNodes };
107
+ }
108
+ addClass(l, o) {
109
+ const i = this.classes.get(l) ?? { id: l, styles: [], textStyles: [] }, p = o.replace(/\\,/g, "§§§").replace(/,/g, ";").replace(/§§§/g, ",").split(";");
110
+ p && p.forEach((s) => {
111
+ xe(s) && (i?.textStyles ? i.textStyles.push(s) : i.textStyles = [s]), i?.styles ? i.styles.push(s) : i.styles = [s];
112
+ }), this.classes.set(l, i);
113
+ }
114
+ getClasses() {
115
+ return this.classes;
116
+ }
117
+ getStylesForClass(l) {
118
+ return this.classes.get(l)?.styles ?? [];
119
+ }
120
+ clear() {
121
+ ve(), this.nodes = [], this.levels = /* @__PURE__ */ new Map(), this.outerNodes = [], this.classes = /* @__PURE__ */ new Map(), this.root = void 0;
122
+ }
123
+ }, w(W, "TreeMapDB"), W);
124
+ function ae(r) {
125
+ if (!r.length)
126
+ return [];
127
+ const l = [], o = [];
128
+ return r.forEach((i) => {
129
+ const p = {
130
+ name: i.name,
131
+ children: i.type === "Leaf" ? void 0 : []
132
+ };
133
+ for (p.classSelector = i?.classSelector, 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; )
134
+ o.pop();
135
+ if (o.length === 0)
136
+ l.push(p);
137
+ else {
138
+ const s = o[o.length - 1].node;
139
+ s.children ? s.children.push(p) : s.children = [p];
140
+ }
141
+ i.type !== "Leaf" && o.push({ node: p, level: i.level });
142
+ }), l;
143
+ }
144
+ w(ae, "buildHierarchy");
145
+ var Ae = /* @__PURE__ */ w((r, l) => {
146
+ we(r, l);
147
+ const o = [];
148
+ for (const s of r.TreemapRows ?? [])
149
+ s.$type === "ClassDefStatement" && l.addClass(s.className ?? "", s.styleText ?? "");
150
+ for (const s of r.TreemapRows ?? []) {
151
+ const c = s.item;
152
+ if (!c)
153
+ continue;
154
+ const h = s.indent ? parseInt(s.indent) : 0, v = Ve(c), n = c.classSelector ? l.getStylesForClass(c.classSelector) : [], d = n.length > 0 ? n.join(";") : void 0, b = {
155
+ level: h,
156
+ name: v,
157
+ type: c.$type,
158
+ value: c.value,
159
+ classSelector: c.classSelector,
160
+ cssCompiledStyles: d
161
+ };
162
+ o.push(b);
163
+ }
164
+ const i = ae(o), p = /* @__PURE__ */ w((s, c) => {
165
+ for (const h of s)
166
+ l.addNode(h, c), h.children && h.children.length > 0 && p(h.children, c + 1);
167
+ }, "addNodesRecursively");
168
+ p(i, 0);
169
+ }, "populate"), Ve = /* @__PURE__ */ w((r) => r.name ? String(r.name) : "", "getItemName"), le = {
170
+ // @ts-expect-error - TreeMapDB is not assignable to DiagramDB
171
+ parser: { yy: void 0 },
172
+ parse: /* @__PURE__ */ w(async (r) => {
173
+ try {
174
+ const o = await Ce("treemap", r);
175
+ J.debug("Treemap AST:", o);
176
+ const i = le.parser?.yy;
177
+ if (!(i instanceof te))
178
+ throw new Error(
179
+ "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."
180
+ );
181
+ Ae(o, i);
182
+ } catch (l) {
183
+ throw J.error("Error parsing treemap:", l), l;
184
+ }
185
+ }, "parse")
186
+ }, De = 10, R = 10, X = 25, Pe = /* @__PURE__ */ w((r, l, o, i) => {
187
+ const p = i.db, s = p.getConfig(), c = s.padding ?? De, h = p.getDiagramTitle(), v = p.getRoot(), { themeVariables: n } = ee();
188
+ if (!v)
189
+ return;
190
+ const d = h ? 30 : 0, b = ce(l), t = s.nodeWidth ? s.nodeWidth * R : 960, x = s.nodeHeight ? s.nodeHeight * R : 500, y = t, S = x + d;
191
+ b.attr("viewBox", `0 0 ${y} ${S}`), de(b, S, y, s.useMaxWidth);
192
+ let u;
193
+ try {
194
+ const e = s.valueFormat || ",";
195
+ if (e === "$0,0")
196
+ u = /* @__PURE__ */ w((a) => "$" + O(",")(a), "valueFormat");
197
+ else if (e.startsWith("$") && e.includes(",")) {
198
+ const a = /\.\d+/.exec(e), f = a ? a[0] : "";
199
+ u = /* @__PURE__ */ w((C) => "$" + O("," + f)(C), "valueFormat");
200
+ } else if (e.startsWith("$")) {
201
+ const a = e.substring(1);
202
+ u = /* @__PURE__ */ w((f) => "$" + O(a || "")(f), "valueFormat");
203
+ } else
204
+ u = O(e);
205
+ } catch (e) {
206
+ J.error("Error creating format function:", e), u = O(",");
207
+ }
208
+ const m = Z().range([
209
+ "transparent",
210
+ n.cScale0,
211
+ n.cScale1,
212
+ n.cScale2,
213
+ n.cScale3,
214
+ n.cScale4,
215
+ n.cScale5,
216
+ n.cScale6,
217
+ n.cScale7,
218
+ n.cScale8,
219
+ n.cScale9,
220
+ n.cScale10,
221
+ n.cScale11
222
+ ]), k = Z().range([
223
+ "transparent",
224
+ n.cScalePeer0,
225
+ n.cScalePeer1,
226
+ n.cScalePeer2,
227
+ n.cScalePeer3,
228
+ n.cScalePeer4,
229
+ n.cScalePeer5,
230
+ n.cScalePeer6,
231
+ n.cScalePeer7,
232
+ n.cScalePeer8,
233
+ n.cScalePeer9,
234
+ n.cScalePeer10,
235
+ n.cScalePeer11
236
+ ]), N = Z().range([
237
+ n.cScaleLabel0,
238
+ n.cScaleLabel1,
239
+ n.cScaleLabel2,
240
+ n.cScaleLabel3,
241
+ n.cScaleLabel4,
242
+ n.cScaleLabel5,
243
+ n.cScaleLabel6,
244
+ n.cScaleLabel7,
245
+ n.cScaleLabel8,
246
+ n.cScaleLabel9,
247
+ n.cScaleLabel10,
248
+ n.cScaleLabel11
249
+ ]);
250
+ h && b.append("text").attr("x", y / 2).attr("y", d / 2).attr("class", "treemapTitle").attr("text-anchor", "middle").attr("dominant-baseline", "middle").text(h);
251
+ const D = b.append("g").attr("transform", `translate(0, ${d})`).attr("class", "treemapContainer"), B = pe(v).sum((e) => e.value ?? 0).sort((e, a) => (a.value ?? 0) - (e.value ?? 0)), K = ze().size([t, x]).paddingTop(
252
+ (e) => e.children && e.children.length > 0 ? X + R : 0
253
+ ).paddingInner(c).paddingLeft((e) => e.children && e.children.length > 0 ? R : 0).paddingRight((e) => e.children && e.children.length > 0 ? R : 0).paddingBottom((e) => e.children && e.children.length > 0 ? R : 0).round(!0)(B), ne = K.descendants().filter((e) => e.children && e.children.length > 0), _ = D.selectAll(".treemapSection").data(ne).enter().append("g").attr("class", "treemapSection").attr("transform", (e) => `translate(${e.x0},${e.y0})`);
254
+ _.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", X).attr("class", "treemapSectionHeader").attr("fill", "none").attr("fill-opacity", 0.6).attr("stroke-width", 0.6).attr("style", (e) => e.depth === 0 ? "display: none;" : ""), _.append("clipPath").attr("id", (e, a) => `clip-section-${l}-${a}`).append("rect").attr("width", (e) => Math.max(0, e.x1 - e.x0 - 12)).attr("height", X), _.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", (e) => e.y1 - e.y0).attr("class", (e, a) => `treemapSection section${a}`).attr("fill", (e) => m(e.data.name)).attr("fill-opacity", 0.6).attr("stroke", (e) => k(e.data.name)).attr("stroke-width", 2).attr("stroke-opacity", 0.4).attr("style", (e) => {
255
+ if (e.depth === 0)
256
+ return "display: none;";
257
+ const a = E({ cssCompiledStyles: e.data.cssCompiledStyles });
258
+ return a.nodeStyles + ";" + a.borderStyles.join(";");
259
+ }), _.append("text").attr("class", "treemapSectionLabel").attr("x", 6).attr("y", X / 2).attr("dominant-baseline", "middle").text((e) => e.depth === 0 ? "" : e.data.name).attr("font-weight", "bold").attr("style", (e) => {
260
+ if (e.depth === 0)
261
+ return "display: none;";
262
+ const a = "dominant-baseline: middle; font-size: 12px; fill:" + N(e.data.name) + "; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;", f = E({ cssCompiledStyles: e.data.cssCompiledStyles });
263
+ return a + f.labelStyles.replace("color:", "fill:");
264
+ }).each(function(e) {
265
+ if (e.depth === 0)
266
+ return;
267
+ const a = j(this), f = e.data.name;
268
+ a.text(f);
269
+ const C = e.x1 - e.x0, $ = 6;
270
+ let F;
271
+ s.showValues !== !1 && e.value ? F = C - 10 - 30 - 10 - $ : F = C - $ - 6;
272
+ const M = Math.max(15, F), g = a.node();
273
+ if (g.getComputedTextLength() > M) {
274
+ const T = "...";
275
+ let L = f;
276
+ for (; L.length > 0; ) {
277
+ if (L = f.substring(0, L.length - 1), L.length === 0) {
278
+ a.text(T), g.getComputedTextLength() > M && a.text("");
279
+ break;
280
+ }
281
+ if (a.text(L + T), g.getComputedTextLength() <= M)
282
+ break;
283
+ }
284
+ }
285
+ }), s.showValues !== !1 && _.append("text").attr("class", "treemapSectionValue").attr("x", (e) => e.x1 - e.x0 - 10).attr("y", X / 2).attr("text-anchor", "end").attr("dominant-baseline", "middle").text((e) => e.value ? u(e.value) : "").attr("font-style", "italic").attr("style", (e) => {
286
+ if (e.depth === 0)
287
+ return "display: none;";
288
+ const a = "text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:" + N(e.data.name) + "; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;", f = E({ cssCompiledStyles: e.data.cssCompiledStyles });
289
+ return a + f.labelStyles.replace("color:", "fill:");
290
+ });
291
+ const se = K.leaves(), Y = D.selectAll(".treemapLeafGroup").data(se).enter().append("g").attr("class", (e, a) => `treemapNode treemapLeafGroup leaf${a}${e.data.classSelector ? ` ${e.data.classSelector}` : ""}x`).attr("transform", (e) => `translate(${e.x0},${e.y0})`);
292
+ Y.append("rect").attr("width", (e) => e.x1 - e.x0).attr("height", (e) => e.y1 - e.y0).attr("class", "treemapLeaf").attr("fill", (e) => e.parent ? m(e.parent.data.name) : m(e.data.name)).attr("style", (e) => E({ cssCompiledStyles: e.data.cssCompiledStyles }).nodeStyles).attr("fill-opacity", 0.3).attr("stroke", (e) => e.parent ? m(e.parent.data.name) : m(e.data.name)).attr("stroke-width", 3), Y.append("clipPath").attr("id", (e, a) => `clip-${l}-${a}`).append("rect").attr("width", (e) => Math.max(0, e.x1 - e.x0 - 4)).attr("height", (e) => Math.max(0, e.y1 - e.y0 - 4)), Y.append("text").attr("class", "treemapLabel").attr("x", (e) => (e.x1 - e.x0) / 2).attr("y", (e) => (e.y1 - e.y0) / 2).attr("style", (e) => {
293
+ const a = "text-anchor: middle; dominant-baseline: middle; font-size: 38px;fill:" + N(e.data.name) + ";", f = E({ cssCompiledStyles: e.data.cssCompiledStyles });
294
+ return a + f.labelStyles.replace("color:", "fill:");
295
+ }).attr("clip-path", (e, a) => `url(#clip-${l}-${a})`).text((e) => e.data.name).each(function(e) {
296
+ const a = j(this), f = e.x1 - e.x0, C = e.y1 - e.y0, $ = a.node(), F = 4, P = f - 2 * F, M = C - 2 * F;
297
+ if (P < 10 || M < 10) {
298
+ a.style("display", "none");
299
+ return;
300
+ }
301
+ let g = parseInt(a.style("font-size"), 10);
302
+ const A = 8, T = 28, L = 0.6, V = 6, H = 2;
303
+ for (; $.getComputedTextLength() > P && g > A; )
304
+ g--, a.style("font-size", `${g}px`);
305
+ let I = Math.max(
306
+ V,
307
+ Math.min(T, Math.round(g * L))
308
+ ), U = g + H + I;
309
+ for (; U > M && g > A && (g--, I = Math.max(
310
+ V,
311
+ Math.min(T, Math.round(g * L))
312
+ ), !(I < V && g === A)); )
313
+ a.style("font-size", `${g}px`), U = g + H + I;
314
+ a.style("font-size", `${g}px`), ($.getComputedTextLength() > P || g < A || M < g) && a.style("display", "none");
315
+ }), s.showValues !== !1 && Y.append("text").attr("class", "treemapValue").attr("x", (a) => (a.x1 - a.x0) / 2).attr("y", function(a) {
316
+ return (a.y1 - a.y0) / 2;
317
+ }).attr("style", (a) => {
318
+ const f = "text-anchor: middle; dominant-baseline: hanging; font-size: 28px;fill:" + N(a.data.name) + ";", C = E({ cssCompiledStyles: a.data.cssCompiledStyles });
319
+ return f + C.labelStyles.replace("color:", "fill:");
320
+ }).attr("clip-path", (a, f) => `url(#clip-${l}-${f})`).text((a) => a.value ? u(a.value) : "").each(function(a) {
321
+ const f = j(this), C = this.parentNode;
322
+ if (!C) {
323
+ f.style("display", "none");
324
+ return;
325
+ }
326
+ const $ = j(C).select(".treemapLabel");
327
+ if ($.empty() || $.style("display") === "none") {
328
+ f.style("display", "none");
329
+ return;
330
+ }
331
+ const F = parseFloat($.style("font-size")), P = 28, M = 0.6, g = 6, A = 2, T = Math.max(
332
+ g,
333
+ Math.min(P, Math.round(F * M))
334
+ );
335
+ f.style("font-size", `${T}px`);
336
+ const V = (a.y1 - a.y0) / 2 + F / 2 + A;
337
+ f.attr("y", V);
338
+ const H = a.x1 - a.x0, ie = a.y1 - a.y0 - 4, oe = H - 2 * 4;
339
+ f.node().getComputedTextLength() > oe || V + T > ie || T < g ? f.style("display", "none") : f.style("display", null);
340
+ });
341
+ const re = s.diagramPadding ?? 8;
342
+ be(b, re, "flowchart", s?.useMaxWidth || !1);
343
+ }, "draw"), Ee = /* @__PURE__ */ w(function(r, l) {
344
+ return l.db.getClasses();
345
+ }, "getClasses"), Re = { draw: Pe, getClasses: Ee }, We = {
346
+ sectionStrokeColor: "black",
347
+ sectionStrokeWidth: "1",
348
+ sectionFillColor: "#efefef",
349
+ leafStrokeColor: "black",
350
+ leafStrokeWidth: "1",
351
+ leafFillColor: "#efefef",
352
+ labelColor: "black",
353
+ labelFontSize: "12px",
354
+ valueFontSize: "10px",
355
+ valueColor: "black",
356
+ titleColor: "black",
357
+ titleFontSize: "14px"
358
+ }, Be = /* @__PURE__ */ w(({
359
+ treemap: r
360
+ } = {}) => {
361
+ const l = Q(We, r);
362
+ return `
363
+ .treemapNode.section {
364
+ stroke: ${l.sectionStrokeColor};
365
+ stroke-width: ${l.sectionStrokeWidth};
366
+ fill: ${l.sectionFillColor};
367
+ }
368
+ .treemapNode.leaf {
369
+ stroke: ${l.leafStrokeColor};
370
+ stroke-width: ${l.leafStrokeWidth};
371
+ fill: ${l.leafFillColor};
372
+ }
373
+ .treemapLabel {
374
+ fill: ${l.labelColor};
375
+ font-size: ${l.labelFontSize};
376
+ }
377
+ .treemapValue {
378
+ fill: ${l.valueColor};
379
+ font-size: ${l.valueFontSize};
380
+ }
381
+ .treemapTitle {
382
+ fill: ${l.titleColor};
383
+ font-size: ${l.titleFontSize};
384
+ }
385
+ `;
386
+ }, "getStyles"), _e = Be, Ue = {
387
+ parser: le,
388
+ get db() {
389
+ return new te();
390
+ },
391
+ renderer: Re,
392
+ styles: _e
393
+ };
394
+ export {
395
+ Ue as diagram
396
+ };
@@ -1,13 +1,7 @@
1
1
  import "./style.css";
2
- import { _ as l, s as k, g as R, q as E, p as F, a as I, b as _, H as D, y as G, D as f, E as C, F as P, l as z, K as H } from "./index-D6-Wf75-.js";
3
- import { p as V } from "./chunk-4BX2VUAB-5_v9rnje.js";
4
- import { p as W } from "./mermaid-parser.core-CYtF6phW.js";
5
- /**
6
- * @umoteam/editor 9.0.1
7
- * @license MIT
8
- * @author umodoc https://www.umodoc.com
9
- * @see https://www.umodoc.com
10
- **/
2
+ import { _ as l, s as k, g as R, q as E, p as F, a as I, b as _, H as D, y as G, D as f, E as C, F as P, l as z, K as H } from "./index-D5tpgmxE.js";
3
+ import { p as V } from "./chunk-4BX2VUAB-JnvgOgeI.js";
4
+ import { p as W } from "./mermaid-parser.core-D1WCqkLE.js";
11
5
  var m = {
12
6
  showLegend: !0,
13
7
  ticks: 5,
@@ -1,13 +1,7 @@
1
1
  import "./style.css";
2
- import { _ as b, D as m, H as B, e as C, l as w, b as S, a as D, p as T, q as E, g as F, s as P, E as z, F as A, y as W } from "./index-D6-Wf75-.js";
3
- import { p as _ } from "./chunk-4BX2VUAB-5_v9rnje.js";
4
- import { p as N } from "./mermaid-parser.core-CYtF6phW.js";
5
- /**
6
- * @umoteam/editor 9.0.1
7
- * @license MIT
8
- * @author umodoc https://www.umodoc.com
9
- * @see https://www.umodoc.com
10
- **/
2
+ import { _ as b, D as m, H as B, e as C, l as w, b as S, a as D, p as T, q as E, g as F, s as P, E as z, F as A, y as W } from "./index-D5tpgmxE.js";
3
+ import { p as _ } from "./chunk-4BX2VUAB-JnvgOgeI.js";
4
+ import { p as N } from "./mermaid-parser.core-D1WCqkLE.js";
11
5
  var L = A.packet, u, v = (u = class {
12
6
  constructor() {
13
7
  this.packet = [], this.setAccTitle = S, this.getAccTitle = D, this.setDiagramTitle = T, this.getDiagramTitle = E, this.getAccDescription = F, this.setAccDescription = P;
@@ -1,14 +1,8 @@
1
1
  import "./style.css";
2
- import { g as Dt } from "./chunk-55IACEB6-BDNtSypP.js";
3
- import { s as wt } from "./chunk-QN33PNHL-DhbA7i5G.js";
4
- import { _ as u, b as Vt, a as Lt, s as Mt, g as Bt, p as Ft, q as Yt, c as tt, l as D, y as Pt, x as zt, A as Gt, B as Kt, o as Zt, r as Ut, d as jt, u as Wt } from "./index-D6-Wf75-.js";
5
- import { c as Qt } from "./channel-Dah4F59k.js";
6
- /**
7
- * @umoteam/editor 9.0.1
8
- * @license MIT
9
- * @author umodoc https://www.umodoc.com
10
- * @see https://www.umodoc.com
11
- **/
2
+ import { g as Dt } from "./chunk-55IACEB6-DvzYdqd0.js";
3
+ import { s as wt } from "./chunk-QN33PNHL-D3gdmDbi.js";
4
+ import { _ as u, b as Vt, a as Lt, s as Mt, g as Bt, p as Ft, q as Yt, c as tt, l as D, y as Pt, x as zt, A as Gt, B as Kt, o as Zt, r as Ut, d as jt, u as Wt } from "./index-D5tpgmxE.js";
5
+ import { c as Qt } from "./channel-BiQYlsVc.js";
12
6
  var dt = function() {
13
7
  var s = /* @__PURE__ */ u(function(R, n, a, c) {
14
8
  for (a = a || {}, c = R.length; c--; a[R[c]] = n) ;
@@ -1,15 +1,9 @@
1
1
  import "./style.css";
2
- import { g as qt } from "./chunk-FMBD7UC4-BaEPEIWb.js";
3
- import { _ as m, n as Ot, l as $, c as b1, d as E1, o as Ht, r as Xt, u as it, b as Qt, s as Jt, p as Zt, a as $t, g as te, q as ee, k as se, t as ie, J as re, v as ae, x as st, y as ne, z as ue, A as oe } from "./index-D6-Wf75-.js";
4
- import { g as le } from "./chunk-55IACEB6-BDNtSypP.js";
5
- import { s as ce } from "./chunk-QN33PNHL-DhbA7i5G.js";
6
- import { c as he } from "./channel-Dah4F59k.js";
7
- /**
8
- * @umoteam/editor 9.0.1
9
- * @license MIT
10
- * @author umodoc https://www.umodoc.com
11
- * @see https://www.umodoc.com
12
- **/
2
+ import { g as qt } from "./chunk-FMBD7UC4-CI7_2stl.js";
3
+ import { _ as m, n as Ot, l as $, c as b1, d as E1, o as Ht, r as Xt, u as it, b as Qt, s as Jt, p as Zt, a as $t, g as te, q as ee, k as se, t as ie, J as re, v as ae, x as st, y as ne, z as ue, A as oe } from "./index-D5tpgmxE.js";
4
+ import { g as le } from "./chunk-55IACEB6-DvzYdqd0.js";
5
+ import { s as ce } from "./chunk-QN33PNHL-D3gdmDbi.js";
6
+ import { c as he } from "./channel-BiQYlsVc.js";
13
7
  var de = "flowchart-", G1, pe = (G1 = class {
14
8
  // cspell:ignore funs
15
9
  constructor() {
@@ -1,13 +1,7 @@
1
1
  import "./style.css";
2
- import { b1 as $e, b2 as Un, b3 as Je, b4 as Ke, b5 as tn, b6 as re, b7 as En, aI as Te, aJ as be, _ as h, g as Ln, s as An, q as In, p as Wn, a as On, b as Hn, c as _t, d as Zt, e as Nn, b8 as it, l as Qt, k as Vn, j as zn, y as Pn, u as Rn } from "./index-D6-Wf75-.js";
3
- import { b as Bn, t as Ie, c as Zn, a as qn, l as Xn } from "./linear-CO_vz87n.js";
4
- import { i as Gn } from "./init-d639unba.js";
5
- /**
6
- * @umoteam/editor 9.0.1
7
- * @license MIT
8
- * @author umodoc https://www.umodoc.com
9
- * @see https://www.umodoc.com
10
- **/
2
+ import { be as $e, bf as Un, bg as Je, bh as Ke, bi as tn, bj as re, bk as En, aH as Te, aI as be, _ as h, g as Ln, s as An, q as In, p as Wn, a as On, b as Hn, c as _t, d as Zt, e as Nn, bl as it, l as Qt, k as Vn, j as zn, y as Pn, u as Rn } from "./index-D5tpgmxE.js";
3
+ import { b as Bn, t as Ie, c as Zn, a as qn, l as Xn } from "./linear-CD94DoB6.js";
4
+ import { i as Gn } from "./init-Dbt-6wo9.js";
11
5
  function jn(t, e) {
12
6
  let n;
13
7
  if (e === void 0)
@@ -0,0 +1,6 @@
1
+ import "./style.css";
2
+ import { G as t, f as G } from "./mermaid-parser.core-D1WCqkLE.js";
3
+ export {
4
+ t as GitGraphModule,
5
+ G as createGitGraphServices
6
+ };
@@ -1,14 +1,8 @@
1
1
  import "./style.css";
2
- import { p as Y } from "./chunk-4BX2VUAB-5_v9rnje.js";
3
- import { I as K } from "./chunk-QZHKN3VN-BAb_D1oz.js";
4
- import { _ as l, q as U, p as V, s as X, g as J, a as Q, b as Z, l as m, c as rr, d as er, u as tr, C as ar, y as sr, k as C, D as nr, E as or, F as cr, G as ir } from "./index-D6-Wf75-.js";
5
- import { p as dr } from "./mermaid-parser.core-CYtF6phW.js";
6
- /**
7
- * @umoteam/editor 9.0.1
8
- * @license MIT
9
- * @author umodoc https://www.umodoc.com
10
- * @see https://www.umodoc.com
11
- **/
2
+ import { p as Y } from "./chunk-4BX2VUAB-JnvgOgeI.js";
3
+ import { I as K } from "./chunk-QZHKN3VN-BaqG_46X.js";
4
+ import { _ as l, q as U, p as V, s as X, g as J, a as Q, b as Z, l as m, c as rr, d as er, u as tr, C as ar, y as sr, k as C, D as nr, E as or, F as cr, G as ir } from "./index-D5tpgmxE.js";
5
+ import { p as dr } from "./mermaid-parser.core-D1WCqkLE.js";
12
6
  var x = {
13
7
  NORMAL: 0,
14
8
  REVERSE: 1,