@blueking/ai-blueking 2.1.4-beta.7 → 2.1.4-beta.8
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.
- package/dist/standalone/_baseFor-DZ1vnh4H.js +393 -0
- package/dist/standalone/arc-WNacHY26.js +80 -0
- package/dist/standalone/architecture-YZFGNWBL-pIa_tKdA.js +3 -0
- package/dist/standalone/architectureDiagram-Q4EWVU46-Bfam8Fg3.js +4057 -0
- package/dist/standalone/array-CWNufkl9.js +6 -0
- package/dist/standalone/blockDiagram-DXYQGD6D-vAb9uyF5.js +3033 -0
- package/dist/standalone/c4Diagram-AHTNJAMY-BWACU0ER.js +2961 -0
- package/dist/standalone/channel-Br5ChI8U.js +5 -0
- package/dist/standalone/chunk-2KRD3SAO-Deh6AASy.js +23 -0
- package/dist/standalone/chunk-336JU56O-CFKWNcxR.js +49 -0
- package/dist/standalone/chunk-426QAEUC-D_wKNd3w.js +9 -0
- package/dist/standalone/chunk-4BX2VUAB-DKC_OBWg.js +8 -0
- package/dist/standalone/chunk-4TB4RGXK-HiVG7T1A.js +3254 -0
- package/dist/standalone/chunk-55IACEB6-DBivnNb2.js +8 -0
- package/dist/standalone/chunk-5FUZZQ4R-tiEjqlP4.js +3638 -0
- package/dist/standalone/chunk-5PVQY5BW-BCjrVrWB.js +1299 -0
- package/dist/standalone/chunk-67CJDMHE-BX09W6oy.js +23 -0
- package/dist/standalone/chunk-7N4EOEYR-G144j5Vc.js +35 -0
- package/dist/standalone/chunk-AA7GKIK3-Dx9YCoJ-.js +30 -0
- package/dist/standalone/chunk-BSJP7CBP-DE8WR0MI.js +82 -0
- package/dist/standalone/chunk-CIAEETIT-Bv86XVLB.js +23 -0
- package/dist/standalone/chunk-EDXVE4YY-DE9KzYM-.js +25 -0
- package/dist/standalone/chunk-ENJZ2VHE-DlxIC-A3.js +560 -0
- package/dist/standalone/chunk-FMBD7UC4-DCkBrKFO.js +5 -0
- package/dist/standalone/chunk-FOC6F5B3-C7hwrEZJ.js +23 -0
- package/dist/standalone/chunk-ICPOFSXX-B9JXAgJU.js +2772 -0
- package/dist/standalone/chunk-K5T4RW27-T6hJxJM0.js +16070 -0
- package/dist/standalone/chunk-KGLVRYIC-C0JPhrjn.js +23 -0
- package/dist/standalone/chunk-LIHQZDEY-CiavnvWh.js +64 -0
- package/dist/standalone/chunk-ORNJ4GCN-BtJ79bik.js +31 -0
- package/dist/standalone/chunk-OYMX7WX6-D2UHnmfD.js +2014 -0
- package/dist/standalone/chunk-QZHKN3VN-DhzThSvb.js +15 -0
- package/dist/standalone/chunk-U2HBQHQK-75Isf1R4.js +1896 -0
- package/dist/standalone/chunk-WQLz0Won.js +20 -0
- package/dist/standalone/chunk-X2U36JSP-DSzducJI.js +67 -0
- package/dist/standalone/chunk-XPW4576I-BFhmu0d4.js +1146 -0
- package/dist/standalone/chunk-YZCP3GAM-90EaSO-2.js +60 -0
- package/dist/standalone/chunk-ZZ45TVLE-DUagTZ9d.js +32 -0
- package/dist/standalone/classDiagram-6PBFFD2Q-Bwt78q4N.js +29 -0
- package/dist/standalone/classDiagram-v2-HSJHXN6E-B2qI9-xf.js +29 -0
- package/dist/standalone/clone-CBw-BHXl.js +8 -0
- package/dist/standalone/cose-bilkent-S5V4N54A-DFJ1nlog.js +2250 -0
- package/dist/standalone/cytoscape.esm-DdhenceR.js +18103 -0
- package/dist/standalone/dagre-KV5264BT-CXTBtAae.js +293 -0
- package/dist/standalone/dagre-kfvGmNUa.js +1606 -0
- package/dist/standalone/defaultLocale-bckJcYh1.js +201 -0
- package/dist/standalone/diagram-5BDNPKRD--gLHDKg-.js +101 -0
- package/dist/standalone/diagram-G4DWMVQ6-BwLE9Hsf.js +524 -0
- package/dist/standalone/diagram-MMDJMWI5-CoilYxa0.js +213 -0
- package/dist/standalone/diagram-TYMM5635-BupwRdr6.js +133 -0
- package/dist/standalone/dist-Dlj1jr8W.js +59 -0
- package/dist/standalone/erDiagram-SMLLAGMA-tIdn6ZCM.js +1700 -0
- package/dist/standalone/flatten-CXxC4cn2.js +40 -0
- package/dist/standalone/flowDiagram-DWJPFMVM-C86bLTAY.js +4146 -0
- package/dist/standalone/ganttDiagram-T4ZO3ILL-BT23lv_X.js +3077 -0
- package/dist/standalone/gitGraph-7Q5UKJZL-C-7nG8PF.js +3 -0
- package/dist/standalone/gitGraphDiagram-UUTBAWPF-DT1BGQsP.js +728 -0
- package/dist/standalone/graphlib-DrXiQBFg.js +373 -0
- package/dist/standalone/index.es.min.js +59705 -0
- package/dist/standalone/index.iife.min.js +3502 -0
- package/dist/standalone/index.umd.min.js +3502 -0
- package/dist/standalone/info-OMHHGYJF-BOS7mrON.js +3 -0
- package/dist/standalone/infoDiagram-42DDH7IO-Dx7LFK0B.js +19 -0
- package/dist/standalone/init-B75p2clj.js +15 -0
- package/dist/standalone/isEmpty-CVG4Bj-P.js +35 -0
- package/dist/standalone/ishikawaDiagram-UXIWVN3A-CX4cX3qb.js +718 -0
- package/dist/standalone/journeyDiagram-VCZTEJTY-BCvxmmFn.js +883 -0
- package/dist/standalone/kanban-definition-6JOO6SKY-SVINWaiM.js +973 -0
- package/dist/standalone/katex-CKrw0rbA.js +22016 -0
- package/dist/standalone/line-BF1XS-Ng.js +34 -0
- package/dist/standalone/linear-DGQDIL28.js +289 -0
- package/dist/standalone/mermaid-parser.core-Blz-Qy2h.js +69 -0
- package/dist/standalone/mermaid.core-CHTh1JGx.js +944 -0
- package/dist/standalone/mindmap-definition-QFDTVHPH-1Trzro3y.js +1009 -0
- package/dist/standalone/ordinal-F3U6aXtP.js +65 -0
- package/dist/standalone/packet-4T2RLAQJ-ai5Omp1h.js +3 -0
- package/dist/standalone/path-Dm3C8WEs.js +85 -0
- package/dist/standalone/pie-ZZUOXDRM-Df1rG6QC.js +3 -0
- package/dist/standalone/pieDiagram-DEJITSTG-D5Omb898.js +165 -0
- package/dist/standalone/purify.es-CZ_RvYUu.js +549 -0
- package/dist/standalone/quadrantDiagram-34T5L4WZ-Ct4g9T4o.js +1974 -0
- package/dist/standalone/radar-PYXPWWZC-B2t6k6Fg.js +3 -0
- package/dist/standalone/reduce-DbMsJ4nx.js +532 -0
- package/dist/standalone/requirementDiagram-MS252O5E-CP0BUgnz.js +2221 -0
- package/dist/standalone/rough.esm-UCEI3PYn.js +1352 -0
- package/dist/standalone/sankeyDiagram-XADWPNL6-D6C7yZ3k.js +920 -0
- package/dist/standalone/sequenceDiagram-FGHM5R23-KeodespT.js +4157 -0
- package/dist/standalone/src-CFVe5TPD.js +2146 -0
- package/dist/standalone/stateDiagram-FHFEXIEX-DAupoS9U.js +217 -0
- package/dist/standalone/stateDiagram-v2-QKLJ7IA2-C1Lw_i_z.js +27 -0
- package/dist/standalone/style.css +1 -0
- package/dist/standalone/timeline-definition-GMOUNBTQ-Cwhj84lX.js +1068 -0
- package/dist/standalone/treeView-SZITEDCU-BnoMeJSb.js +3 -0
- package/dist/standalone/treemap-W4RFUUIX-B38XFBZF.js +3 -0
- package/dist/standalone/vennDiagram-DHZGUBPP-_1PHloeO.js +1858 -0
- package/dist/standalone/wardley-RL74JXVD-bB8BBy_Y.js +3 -0
- package/dist/standalone/wardleyDiagram-NUSXRM2D-DRLCx-qh.js +578 -0
- package/dist/standalone/xychartDiagram-5P7HB3ND-Bz2-4Ufi.js +2044 -0
- package/dist/standalone-mount-core.d.ts +34 -0
- package/dist/standalone-mount-core.d.ts.map +1 -0
- package/dist/standalone-mount.d.ts +14 -0
- package/dist/standalone-mount.d.ts.map +1 -0
- package/dist/standalone.d.ts +8 -0
- package/dist/standalone.d.ts.map +1 -0
- package/package.json +12 -3
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatDecimal.js
|
|
2
|
+
function e(e) {
|
|
3
|
+
return Math.abs(e = Math.round(e)) >= 1e21 ? e.toLocaleString("en").replace(/,/g, "") : e.toString(10);
|
|
4
|
+
}
|
|
5
|
+
function t(e, t) {
|
|
6
|
+
if (!isFinite(e) || e === 0) return null;
|
|
7
|
+
var n = (e = t ? e.toExponential(t - 1) : e.toExponential()).indexOf("e"), r = e.slice(0, n);
|
|
8
|
+
return [r.length > 1 ? r[0] + r.slice(2) : r, +e.slice(n + 1)];
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/exponent.js
|
|
12
|
+
function n(e) {
|
|
13
|
+
return e = t(Math.abs(e)), e ? e[1] : NaN;
|
|
14
|
+
}
|
|
15
|
+
//#endregion
|
|
16
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatGroup.js
|
|
17
|
+
function r(e, t) {
|
|
18
|
+
return function(n, r) {
|
|
19
|
+
for (var i = n.length, a = [], o = 0, s = e[0], c = 0; i > 0 && s > 0 && (c + s + 1 > r && (s = Math.max(1, r - c)), a.push(n.substring(i -= s, i + s)), !((c += s + 1) > r));) s = e[o = (o + 1) % e.length];
|
|
20
|
+
return a.reverse().join(t);
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
//#endregion
|
|
24
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatNumerals.js
|
|
25
|
+
function i(e) {
|
|
26
|
+
return function(t) {
|
|
27
|
+
return t.replace(/[0-9]/g, function(t) {
|
|
28
|
+
return e[+t];
|
|
29
|
+
});
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
//#endregion
|
|
33
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatSpecifier.js
|
|
34
|
+
var a = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;
|
|
35
|
+
function o(e) {
|
|
36
|
+
if (!(t = a.exec(e))) throw Error("invalid format: " + e);
|
|
37
|
+
var t;
|
|
38
|
+
return new s({
|
|
39
|
+
fill: t[1],
|
|
40
|
+
align: t[2],
|
|
41
|
+
sign: t[3],
|
|
42
|
+
symbol: t[4],
|
|
43
|
+
zero: t[5],
|
|
44
|
+
width: t[6],
|
|
45
|
+
comma: t[7],
|
|
46
|
+
precision: t[8] && t[8].slice(1),
|
|
47
|
+
trim: t[9],
|
|
48
|
+
type: t[10]
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
o.prototype = s.prototype;
|
|
52
|
+
function s(e) {
|
|
53
|
+
this.fill = e.fill === void 0 ? " " : e.fill + "", this.align = e.align === void 0 ? ">" : e.align + "", this.sign = e.sign === void 0 ? "-" : e.sign + "", this.symbol = e.symbol === void 0 ? "" : e.symbol + "", this.zero = !!e.zero, this.width = e.width === void 0 ? void 0 : +e.width, this.comma = !!e.comma, this.precision = e.precision === void 0 ? void 0 : +e.precision, this.trim = !!e.trim, this.type = e.type === void 0 ? "" : e.type + "";
|
|
54
|
+
}
|
|
55
|
+
s.prototype.toString = function() {
|
|
56
|
+
return this.fill + this.align + this.sign + this.symbol + (this.zero ? "0" : "") + (this.width === void 0 ? "" : Math.max(1, this.width | 0)) + (this.comma ? "," : "") + (this.precision === void 0 ? "" : "." + Math.max(0, this.precision | 0)) + (this.trim ? "~" : "") + this.type;
|
|
57
|
+
};
|
|
58
|
+
//#endregion
|
|
59
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatTrim.js
|
|
60
|
+
function c(e) {
|
|
61
|
+
out: for (var t = e.length, n = 1, r = -1, i; n < t; ++n) switch (e[n]) {
|
|
62
|
+
case ".":
|
|
63
|
+
r = i = n;
|
|
64
|
+
break;
|
|
65
|
+
case "0":
|
|
66
|
+
r === 0 && (r = n), i = n;
|
|
67
|
+
break;
|
|
68
|
+
default:
|
|
69
|
+
if (!+e[n]) break out;
|
|
70
|
+
r > 0 && (r = 0);
|
|
71
|
+
break;
|
|
72
|
+
}
|
|
73
|
+
return r > 0 ? e.slice(0, r) + e.slice(i + 1) : e;
|
|
74
|
+
}
|
|
75
|
+
//#endregion
|
|
76
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatPrefixAuto.js
|
|
77
|
+
var l;
|
|
78
|
+
function u(e, n) {
|
|
79
|
+
var r = t(e, n);
|
|
80
|
+
if (!r) return l = void 0, e.toPrecision(n);
|
|
81
|
+
var i = r[0], a = r[1], o = a - (l = Math.max(-8, Math.min(8, Math.floor(a / 3))) * 3) + 1, s = i.length;
|
|
82
|
+
return o === s ? i : o > s ? i + Array(o - s + 1).join("0") : o > 0 ? i.slice(0, o) + "." + i.slice(o) : "0." + Array(1 - o).join("0") + t(e, Math.max(0, n + o - 1))[0];
|
|
83
|
+
}
|
|
84
|
+
//#endregion
|
|
85
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatRounded.js
|
|
86
|
+
function d(e, n) {
|
|
87
|
+
var r = t(e, n);
|
|
88
|
+
if (!r) return e + "";
|
|
89
|
+
var i = r[0], a = r[1];
|
|
90
|
+
return a < 0 ? "0." + Array(-a).join("0") + i : i.length > a + 1 ? i.slice(0, a + 1) + "." + i.slice(a + 1) : i + Array(a - i.length + 2).join("0");
|
|
91
|
+
}
|
|
92
|
+
//#endregion
|
|
93
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/formatTypes.js
|
|
94
|
+
var f = {
|
|
95
|
+
"%": (e, t) => (e * 100).toFixed(t),
|
|
96
|
+
b: (e) => Math.round(e).toString(2),
|
|
97
|
+
c: (e) => e + "",
|
|
98
|
+
d: e,
|
|
99
|
+
e: (e, t) => e.toExponential(t),
|
|
100
|
+
f: (e, t) => e.toFixed(t),
|
|
101
|
+
g: (e, t) => e.toPrecision(t),
|
|
102
|
+
o: (e) => Math.round(e).toString(8),
|
|
103
|
+
p: (e, t) => d(e * 100, t),
|
|
104
|
+
r: d,
|
|
105
|
+
s: u,
|
|
106
|
+
X: (e) => Math.round(e).toString(16).toUpperCase(),
|
|
107
|
+
x: (e) => Math.round(e).toString(16)
|
|
108
|
+
};
|
|
109
|
+
//#endregion
|
|
110
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/identity.js
|
|
111
|
+
function p(e) {
|
|
112
|
+
return e;
|
|
113
|
+
}
|
|
114
|
+
//#endregion
|
|
115
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/locale.js
|
|
116
|
+
var m = Array.prototype.map, h = [
|
|
117
|
+
"y",
|
|
118
|
+
"z",
|
|
119
|
+
"a",
|
|
120
|
+
"f",
|
|
121
|
+
"p",
|
|
122
|
+
"n",
|
|
123
|
+
"µ",
|
|
124
|
+
"m",
|
|
125
|
+
"",
|
|
126
|
+
"k",
|
|
127
|
+
"M",
|
|
128
|
+
"G",
|
|
129
|
+
"T",
|
|
130
|
+
"P",
|
|
131
|
+
"E",
|
|
132
|
+
"Z",
|
|
133
|
+
"Y"
|
|
134
|
+
];
|
|
135
|
+
function g(e) {
|
|
136
|
+
var t = e.grouping === void 0 || e.thousands === void 0 ? p : r(m.call(e.grouping, Number), e.thousands + ""), a = e.currency === void 0 ? "" : e.currency[0] + "", s = e.currency === void 0 ? "" : e.currency[1] + "", u = e.decimal === void 0 ? "." : e.decimal + "", d = e.numerals === void 0 ? p : i(m.call(e.numerals, String)), g = e.percent === void 0 ? "%" : e.percent + "", _ = e.minus === void 0 ? "−" : e.minus + "", v = e.nan === void 0 ? "NaN" : e.nan + "";
|
|
137
|
+
function y(e, n) {
|
|
138
|
+
e = o(e);
|
|
139
|
+
var r = e.fill, i = e.align, p = e.sign, m = e.symbol, y = e.zero, b = e.width, x = e.comma, S = e.precision, C = e.trim, w = e.type;
|
|
140
|
+
w === "n" ? (x = !0, w = "g") : f[w] || (S === void 0 && (S = 12), C = !0, w = "g"), (y || r === "0" && i === "=") && (y = !0, r = "0", i = "=");
|
|
141
|
+
var T = (n && n.prefix !== void 0 ? n.prefix : "") + (m === "$" ? a : m === "#" && /[boxX]/.test(w) ? "0" + w.toLowerCase() : ""), E = (m === "$" ? s : /[%p]/.test(w) ? g : "") + (n && n.suffix !== void 0 ? n.suffix : ""), D = f[w], O = /[defgprs%]/.test(w);
|
|
142
|
+
S = S === void 0 ? 6 : /[gprs]/.test(w) ? Math.max(1, Math.min(21, S)) : Math.max(0, Math.min(20, S));
|
|
143
|
+
function k(e) {
|
|
144
|
+
var n = T, a = E, o, s, f;
|
|
145
|
+
if (w === "c") a = D(e) + a, e = "";
|
|
146
|
+
else {
|
|
147
|
+
e = +e;
|
|
148
|
+
var m = e < 0 || 1 / e < 0;
|
|
149
|
+
if (e = isNaN(e) ? v : D(Math.abs(e), S), C && (e = c(e)), m && +e == 0 && p !== "+" && (m = !1), n = (m ? p === "(" ? p : _ : p === "-" || p === "(" ? "" : p) + n, a = (w === "s" && !isNaN(e) && l !== void 0 ? h[8 + l / 3] : "") + a + (m && p === "(" ? ")" : ""), O) {
|
|
150
|
+
for (o = -1, s = e.length; ++o < s;) if (f = e.charCodeAt(o), 48 > f || f > 57) {
|
|
151
|
+
a = (f === 46 ? u + e.slice(o + 1) : e.slice(o)) + a, e = e.slice(0, o);
|
|
152
|
+
break;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
x && !y && (e = t(e, Infinity));
|
|
157
|
+
var g = n.length + e.length + a.length, k = g < b ? Array(b - g + 1).join(r) : "";
|
|
158
|
+
switch (x && y && (e = t(k + e, k.length ? b - a.length : Infinity), k = ""), i) {
|
|
159
|
+
case "<":
|
|
160
|
+
e = n + e + a + k;
|
|
161
|
+
break;
|
|
162
|
+
case "=":
|
|
163
|
+
e = n + k + e + a;
|
|
164
|
+
break;
|
|
165
|
+
case "^":
|
|
166
|
+
e = k.slice(0, g = k.length >> 1) + n + e + a + k.slice(g);
|
|
167
|
+
break;
|
|
168
|
+
default:
|
|
169
|
+
e = k + n + e + a;
|
|
170
|
+
break;
|
|
171
|
+
}
|
|
172
|
+
return d(e);
|
|
173
|
+
}
|
|
174
|
+
return k.toString = function() {
|
|
175
|
+
return e + "";
|
|
176
|
+
}, k;
|
|
177
|
+
}
|
|
178
|
+
function b(e, t) {
|
|
179
|
+
var r = Math.max(-8, Math.min(8, Math.floor(n(t) / 3))) * 3, i = 10 ** -r, a = y((e = o(e), e.type = "f", e), { suffix: h[8 + r / 3] });
|
|
180
|
+
return function(e) {
|
|
181
|
+
return a(i * e);
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
return {
|
|
185
|
+
format: y,
|
|
186
|
+
formatPrefix: b
|
|
187
|
+
};
|
|
188
|
+
}
|
|
189
|
+
//#endregion
|
|
190
|
+
//#region ../../node_modules/.pnpm/d3-format@3.1.2/node_modules/d3-format/src/defaultLocale.js
|
|
191
|
+
var _, v, y;
|
|
192
|
+
b({
|
|
193
|
+
thousands: ",",
|
|
194
|
+
grouping: [3],
|
|
195
|
+
currency: ["$", ""]
|
|
196
|
+
});
|
|
197
|
+
function b(e) {
|
|
198
|
+
return _ = g(e), v = _.format, y = _.formatPrefix, _;
|
|
199
|
+
}
|
|
200
|
+
//#endregion
|
|
201
|
+
export { n as i, y as n, o as r, v as t };
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import { g as e, h as t } from "./src-CFVe5TPD.js";
|
|
2
|
+
import { B as n, C as r, V as i, W as a, _ as o, a as s, c, d as l, v as u, y as d } from "./chunk-ICPOFSXX-B9JXAgJU.js";
|
|
3
|
+
import { r as f } from "./chunk-5PVQY5BW-BCjrVrWB.js";
|
|
4
|
+
import { t as p } from "./chunk-426QAEUC-D_wKNd3w.js";
|
|
5
|
+
import { t as m } from "./chunk-4BX2VUAB-DKC_OBWg.js";
|
|
6
|
+
import { t as h } from "./mermaid-parser.core-Blz-Qy2h.js";
|
|
7
|
+
import { t as g } from "./chunk-QZHKN3VN-DhzThSvb.js";
|
|
8
|
+
//#region ../../node_modules/.pnpm/mermaid@11.14.0/node_modules/mermaid/dist/chunks/mermaid.core/diagram-5BDNPKRD.mjs
|
|
9
|
+
var _ = new g(() => ({
|
|
10
|
+
cnt: 1,
|
|
11
|
+
stack: [{
|
|
12
|
+
id: 0,
|
|
13
|
+
level: -1,
|
|
14
|
+
name: "/",
|
|
15
|
+
children: []
|
|
16
|
+
}]
|
|
17
|
+
})), v = /* @__PURE__ */ t(() => {
|
|
18
|
+
_.reset(), s();
|
|
19
|
+
}, "clear"), y = /* @__PURE__ */ t(() => _.records.stack[0], "getRoot"), b = /* @__PURE__ */ t(() => _.records.cnt, "getCount"), x = l.treeView, S = {
|
|
20
|
+
clear: v,
|
|
21
|
+
addNode: /* @__PURE__ */ t((e, t) => {
|
|
22
|
+
for (; e <= _.records.stack[_.records.stack.length - 1].level;) _.records.stack.pop();
|
|
23
|
+
let n = {
|
|
24
|
+
id: _.records.cnt++,
|
|
25
|
+
level: e,
|
|
26
|
+
name: t,
|
|
27
|
+
children: []
|
|
28
|
+
};
|
|
29
|
+
_.records.stack[_.records.stack.length - 1].children.push(n), _.records.stack.push(n);
|
|
30
|
+
}, "addNode"),
|
|
31
|
+
getRoot: y,
|
|
32
|
+
getCount: b,
|
|
33
|
+
getConfig: /* @__PURE__ */ t(() => f(x, d().treeView), "getConfig"),
|
|
34
|
+
getAccTitle: u,
|
|
35
|
+
getAccDescription: o,
|
|
36
|
+
getDiagramTitle: r,
|
|
37
|
+
setAccDescription: n,
|
|
38
|
+
setAccTitle: i,
|
|
39
|
+
setDiagramTitle: a
|
|
40
|
+
}, C = /* @__PURE__ */ t((e) => {
|
|
41
|
+
m(e, S), e.nodes.map((e) => S.addNode(e.indent ? parseInt(e.indent) : 0, e.name));
|
|
42
|
+
}, "populate"), w = { parse: /* @__PURE__ */ t(async (t) => {
|
|
43
|
+
let n = await h("treeView", t);
|
|
44
|
+
e.debug(n), C(n);
|
|
45
|
+
}, "parse") }, T = /* @__PURE__ */ t((e, t, n, r, i) => {
|
|
46
|
+
let a = r.append("text").text(n.name).attr("dominant-baseline", "middle").attr("class", "treeView-node-label"), { height: o, width: s } = a.node().getBBox(), c = o + i.paddingY * 2, l = s + i.paddingX * 2;
|
|
47
|
+
a.attr("x", e + i.paddingX), a.attr("y", t + c / 2), n.BBox = {
|
|
48
|
+
x: e,
|
|
49
|
+
y: t,
|
|
50
|
+
width: l,
|
|
51
|
+
height: c
|
|
52
|
+
};
|
|
53
|
+
}, "positionLabel"), E = /* @__PURE__ */ t((e, t, n, r, i, a) => e.append("line").attr("x1", t).attr("y1", n).attr("x2", r).attr("y2", i).attr("stroke-width", a).attr("class", "treeView-node-line"), "positionLine"), D = /* @__PURE__ */ t((e, n, r) => {
|
|
54
|
+
let i = 0, a = 0, o = /* @__PURE__ */ t((e, t, n, r) => {
|
|
55
|
+
let o = r * (n.rowIndent + n.paddingX);
|
|
56
|
+
T(o, i, t, e, n);
|
|
57
|
+
let { height: s, width: c } = t.BBox;
|
|
58
|
+
E(e, o - n.rowIndent, i + s / 2, o, i + s / 2, n.lineThickness), a = Math.max(a, o + c), i += s;
|
|
59
|
+
}, "drawNode"), s = /* @__PURE__ */ t((t, n = 0) => {
|
|
60
|
+
o(e, t, r, n), t.children.forEach((e) => {
|
|
61
|
+
s(e, n + 1);
|
|
62
|
+
});
|
|
63
|
+
let { x: i, y: a, height: c } = t.BBox;
|
|
64
|
+
if (t.children.length) {
|
|
65
|
+
let { y: n, height: o } = t.children[t.children.length - 1].BBox;
|
|
66
|
+
E(e, i + r.paddingX, a + c, i + r.paddingX, n + o / 2 + r.lineThickness / 2, r.lineThickness);
|
|
67
|
+
}
|
|
68
|
+
}, "processNode");
|
|
69
|
+
return s(n), {
|
|
70
|
+
totalHeight: i,
|
|
71
|
+
totalWidth: a
|
|
72
|
+
};
|
|
73
|
+
}, "drawTree"), O = { draw: /* @__PURE__ */ t((t, n, r, i) => {
|
|
74
|
+
e.debug("Rendering treeView diagram\n" + t);
|
|
75
|
+
let a = i.db, o = a.getRoot(), s = a.getConfig(), l = p(n), u = l.append("g");
|
|
76
|
+
u.attr("class", "tree-view");
|
|
77
|
+
let { totalHeight: d, totalWidth: f } = D(u, o, s);
|
|
78
|
+
l.attr("viewBox", `-${s.lineThickness / 2} 0 ${f} ${d}`), c(l, d, f, s.useMaxWidth);
|
|
79
|
+
}, "draw") }, k = {
|
|
80
|
+
labelFontSize: "16px",
|
|
81
|
+
labelColor: "black",
|
|
82
|
+
lineColor: "black"
|
|
83
|
+
}, A = {
|
|
84
|
+
db: S,
|
|
85
|
+
renderer: O,
|
|
86
|
+
parser: w,
|
|
87
|
+
styles: /* @__PURE__ */ t(({ treeView: e }) => {
|
|
88
|
+
let { labelFontSize: t, labelColor: n, lineColor: r } = f(k, e);
|
|
89
|
+
return `
|
|
90
|
+
.treeView-node-label {
|
|
91
|
+
font-size: ${t};
|
|
92
|
+
fill: ${n};
|
|
93
|
+
}
|
|
94
|
+
.treeView-node-line {
|
|
95
|
+
stroke: ${r};
|
|
96
|
+
}
|
|
97
|
+
`;
|
|
98
|
+
}, "styles")
|
|
99
|
+
};
|
|
100
|
+
//#endregion
|
|
101
|
+
export { A as diagram };
|