@aidapt/caity-chat 3.0.0
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/README.md +73 -0
- package/dist/lib/_baseUniq-BVCT-t6P.js +477 -0
- package/dist/lib/arc-Kj6ZmwPS.js +83 -0
- package/dist/lib/architectureDiagram-Q4EWVU46-DA4kYaz_.js +4690 -0
- package/dist/lib/blockDiagram-DXYQGD6D-BWT5yya1.js +2295 -0
- package/dist/lib/c4Diagram-AHTNJAMY-BjY6DW3U.js +1577 -0
- package/dist/lib/caity-chat.tgz +0 -0
- package/dist/lib/channel-BjraetTo.js +5 -0
- package/dist/lib/chunk-4BX2VUAB-iSPZGgxQ.js +8 -0
- package/dist/lib/chunk-4TB4RGXK-DvnUcLoe.js +1465 -0
- package/dist/lib/chunk-55IACEB6-Mw25YX9j.js +8 -0
- package/dist/lib/chunk-EDXVE4YY-Dtbxz7df.js +19 -0
- package/dist/lib/chunk-FMBD7UC4-OCIy3top.js +19 -0
- package/dist/lib/chunk-OYMX7WX6-DFW9El2C.js +1383 -0
- package/dist/lib/chunk-QZHKN3VN-BYFTfk7k.js +15 -0
- package/dist/lib/chunk-YZCP3GAM-Cs-HTcyJ.js +68 -0
- package/dist/lib/classDiagram-6PBFFD2Q-CrDUlIYr.js +16 -0
- package/dist/lib/classDiagram-v2-HSJHXN6E-CrDUlIYr.js +16 -0
- package/dist/lib/clone-C0qEGPCz.js +8 -0
- package/dist/lib/cose-bilkent-S5V4N54A-H1-YbKvI.js +2609 -0
- package/dist/lib/cytoscape.esm-D_3MZVO6.js +18707 -0
- package/dist/lib/dagre-KV5264BT-DhEnTJ4D.js +443 -0
- package/dist/lib/defaultLocale-BgPVtth8.js +171 -0
- package/dist/lib/diagram-5BDNPKRD-CK6wgKxI.js +123 -0
- package/dist/lib/diagram-G4DWMVQ6-IhA_MJ0t.js +528 -0
- package/dist/lib/diagram-MMDJMWI5-DDuA1rYY.js +217 -0
- package/dist/lib/diagram-TYMM5635-_VI1en0S.js +142 -0
- package/dist/lib/erDiagram-SMLLAGMA-B1REwW7y.js +899 -0
- package/dist/lib/flowDiagram-DWJPFMVM-rWzOGDlg.js +1628 -0
- package/dist/lib/ganttDiagram-T4ZO3ILL-UhSvbAmM.js +2701 -0
- package/dist/lib/gitGraphDiagram-UUTBAWPF-DrsSMMoJ.js +815 -0
- package/dist/lib/graph-DMr8NrNW.js +738 -0
- package/dist/lib/index.d.ts +665 -0
- package/dist/lib/index.js +52 -0
- package/dist/lib/infoDiagram-42DDH7IO-CPF3XCNj.js +24 -0
- package/dist/lib/init-DjUOC4st.js +16 -0
- package/dist/lib/ishikawaDiagram-UXIWVN3A-B4Nt1TdW.js +621 -0
- package/dist/lib/journeyDiagram-VCZTEJTY-DW5yRsOM.js +834 -0
- package/dist/lib/kanban-definition-6JOO6SKY-5DmJRubo.js +724 -0
- package/dist/lib/layout-B00IQLgh.js +1441 -0
- package/dist/lib/linear-LLab47WO.js +259 -0
- package/dist/lib/main-C9dvh9CT.js +88771 -0
- package/dist/lib/mermaid.core-BrBkhL9h.js +15967 -0
- package/dist/lib/min-CJFyJhXg.js +38 -0
- package/dist/lib/mindmap-definition-QFDTVHPH-doqZCFNi.js +833 -0
- package/dist/lib/ordinal-B6-f3MAq.js +61 -0
- package/dist/lib/pieDiagram-DEJITSTG-DKi5GKup.js +163 -0
- package/dist/lib/quadrantDiagram-34T5L4WZ-COYWmEhy.js +1022 -0
- package/dist/lib/requirementDiagram-MS252O5E-D3odK6YH.js +882 -0
- package/dist/lib/sankeyDiagram-XADWPNL6-D36eaMCx.js +810 -0
- package/dist/lib/sequenceDiagram-FGHM5R23-NpESTwMk.js +2883 -0
- package/dist/lib/standalone.js +4 -0
- package/dist/lib/stateDiagram-FHFEXIEX-kXZ_Bn-a.js +263 -0
- package/dist/lib/stateDiagram-v2-QKLJ7IA2-B5xMdEuE.js +16 -0
- package/dist/lib/timeline-definition-GMOUNBTQ-DZDdcJwy.js +1055 -0
- package/dist/lib/vennDiagram-DHZGUBPP-Clhb6EGF.js +1557 -0
- package/dist/lib/wardley-RL74JXVD-CwSnyVu7.js +18396 -0
- package/dist/lib/wardleyDiagram-NUSXRM2D-DnXL4F04.js +594 -0
- package/dist/lib/xychartDiagram-5P7HB3ND-CweIkrg3.js +1342 -0
- package/package.json +95 -0
- package/src/types/caity-chat.d.ts +213 -0
- package/src/types/template-slots.d.ts +167 -0
|
@@ -0,0 +1,1055 @@
|
|
|
1
|
+
import { _ as o, D as pt, V as Ct, W as Rt, X as Wt, c as gt, l as E, I as Pt, N as Bt, Y as ft, d as U, C as Vt, $ as Ft, z as zt } from "./mermaid.core-BrBkhL9h.js";
|
|
2
|
+
import { d as ot } from "./arc-Kj6ZmwPS.js";
|
|
3
|
+
var tt = (function() {
|
|
4
|
+
var e = /* @__PURE__ */ o(function(k, s, d, l) {
|
|
5
|
+
for (d = d || {}, l = k.length; l--; d[k[l]] = s) ;
|
|
6
|
+
return d;
|
|
7
|
+
}, "o"), t = [6, 11, 13, 14, 15, 17, 19, 20, 23, 24], n = [1, 12], i = [1, 13], r = [1, 14], h = [1, 15], c = [1, 16], a = [1, 19], f = [1, 20], g = {
|
|
8
|
+
trace: /* @__PURE__ */ o(function() {
|
|
9
|
+
}, "trace"),
|
|
10
|
+
yy: {},
|
|
11
|
+
symbols_: { error: 2, start: 3, timeline_header: 4, document: 5, EOF: 6, timeline: 7, timeline_lr: 8, timeline_td: 9, line: 10, SPACE: 11, statement: 12, NEWLINE: 13, title: 14, acc_title: 15, acc_title_value: 16, acc_descr: 17, acc_descr_value: 18, acc_descr_multiline_value: 19, section: 20, period_statement: 21, event_statement: 22, period: 23, event: 24, $accept: 0, $end: 1 },
|
|
12
|
+
terminals_: { 2: "error", 6: "EOF", 7: "timeline", 8: "timeline_lr", 9: "timeline_td", 11: "SPACE", 13: "NEWLINE", 14: "title", 15: "acc_title", 16: "acc_title_value", 17: "acc_descr", 18: "acc_descr_value", 19: "acc_descr_multiline_value", 20: "section", 23: "period", 24: "event" },
|
|
13
|
+
productions_: [0, [3, 3], [4, 1], [4, 1], [4, 1], [5, 0], [5, 2], [10, 2], [10, 1], [10, 1], [10, 1], [12, 1], [12, 2], [12, 2], [12, 1], [12, 1], [12, 1], [12, 1], [21, 1], [22, 1]],
|
|
14
|
+
performAction: /* @__PURE__ */ o(function(s, d, l, p, x, u, S) {
|
|
15
|
+
var v = u.length - 1;
|
|
16
|
+
switch (x) {
|
|
17
|
+
case 1:
|
|
18
|
+
return u[v - 1];
|
|
19
|
+
case 3:
|
|
20
|
+
p.setDirection("LR");
|
|
21
|
+
break;
|
|
22
|
+
case 4:
|
|
23
|
+
p.setDirection("TD");
|
|
24
|
+
break;
|
|
25
|
+
case 5:
|
|
26
|
+
this.$ = [];
|
|
27
|
+
break;
|
|
28
|
+
case 6:
|
|
29
|
+
u[v - 1].push(u[v]), this.$ = u[v - 1];
|
|
30
|
+
break;
|
|
31
|
+
case 7:
|
|
32
|
+
case 8:
|
|
33
|
+
this.$ = u[v];
|
|
34
|
+
break;
|
|
35
|
+
case 9:
|
|
36
|
+
case 10:
|
|
37
|
+
this.$ = [];
|
|
38
|
+
break;
|
|
39
|
+
case 11:
|
|
40
|
+
p.getCommonDb().setDiagramTitle(u[v].substr(6)), this.$ = u[v].substr(6);
|
|
41
|
+
break;
|
|
42
|
+
case 12:
|
|
43
|
+
this.$ = u[v].trim(), p.getCommonDb().setAccTitle(this.$);
|
|
44
|
+
break;
|
|
45
|
+
case 13:
|
|
46
|
+
case 14:
|
|
47
|
+
this.$ = u[v].trim(), p.getCommonDb().setAccDescription(this.$);
|
|
48
|
+
break;
|
|
49
|
+
case 15:
|
|
50
|
+
p.addSection(u[v].substr(8)), this.$ = u[v].substr(8);
|
|
51
|
+
break;
|
|
52
|
+
case 18:
|
|
53
|
+
p.addTask(u[v], 0, ""), this.$ = u[v];
|
|
54
|
+
break;
|
|
55
|
+
case 19:
|
|
56
|
+
p.addEvent(u[v].substr(2)), this.$ = u[v];
|
|
57
|
+
break;
|
|
58
|
+
}
|
|
59
|
+
}, "anonymous"),
|
|
60
|
+
table: [{ 3: 1, 4: 2, 7: [1, 3], 8: [1, 4], 9: [1, 5] }, { 1: [3] }, e(t, [2, 5], { 5: 6 }), e(t, [2, 2]), e(t, [2, 3]), e(t, [2, 4]), { 6: [1, 7], 10: 8, 11: [1, 9], 12: 10, 13: [1, 11], 14: n, 15: i, 17: r, 19: h, 20: c, 21: 17, 22: 18, 23: a, 24: f }, e(t, [2, 10], { 1: [2, 1] }), e(t, [2, 6]), { 12: 21, 14: n, 15: i, 17: r, 19: h, 20: c, 21: 17, 22: 18, 23: a, 24: f }, e(t, [2, 8]), e(t, [2, 9]), e(t, [2, 11]), { 16: [1, 22] }, { 18: [1, 23] }, e(t, [2, 14]), e(t, [2, 15]), e(t, [2, 16]), e(t, [2, 17]), e(t, [2, 18]), e(t, [2, 19]), e(t, [2, 7]), e(t, [2, 12]), e(t, [2, 13])],
|
|
61
|
+
defaultActions: {},
|
|
62
|
+
parseError: /* @__PURE__ */ o(function(s, d) {
|
|
63
|
+
if (d.recoverable)
|
|
64
|
+
this.trace(s);
|
|
65
|
+
else {
|
|
66
|
+
var l = new Error(s);
|
|
67
|
+
throw l.hash = d, l;
|
|
68
|
+
}
|
|
69
|
+
}, "parseError"),
|
|
70
|
+
parse: /* @__PURE__ */ o(function(s) {
|
|
71
|
+
var d = this, l = [0], p = [], x = [null], u = [], S = this.table, v = "", I = 0, C = 0, W = 2, O = 1, L = u.slice.call(arguments, 1), w = Object.create(this.lexer), H = { yy: {} };
|
|
72
|
+
for (var V in this.yy)
|
|
73
|
+
Object.prototype.hasOwnProperty.call(this.yy, V) && (H.yy[V] = this.yy[V]);
|
|
74
|
+
w.setInput(s, H.yy), H.yy.lexer = w, H.yy.parser = this, typeof w.yylloc > "u" && (w.yylloc = {});
|
|
75
|
+
var F = w.yylloc;
|
|
76
|
+
u.push(F);
|
|
77
|
+
var K = w.options && w.options.ranges;
|
|
78
|
+
typeof H.yy.parseError == "function" ? this.parseError = H.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
|
|
79
|
+
function N(A) {
|
|
80
|
+
l.length = l.length - 2 * A, x.length = x.length - A, u.length = u.length - A;
|
|
81
|
+
}
|
|
82
|
+
o(N, "popStack");
|
|
83
|
+
function b() {
|
|
84
|
+
var A;
|
|
85
|
+
return A = p.pop() || w.lex() || O, typeof A != "number" && (A instanceof Array && (p = A, A = p.pop()), A = d.symbols_[A] || A), A;
|
|
86
|
+
}
|
|
87
|
+
o(b, "lex");
|
|
88
|
+
for (var _, $, T, P, R = {}, G, B, Z, j; ; ) {
|
|
89
|
+
if ($ = l[l.length - 1], this.defaultActions[$] ? T = this.defaultActions[$] : ((_ === null || typeof _ > "u") && (_ = b()), T = S[$] && S[$][_]), typeof T > "u" || !T.length || !T[0]) {
|
|
90
|
+
var Y = "";
|
|
91
|
+
j = [];
|
|
92
|
+
for (G in S[$])
|
|
93
|
+
this.terminals_[G] && G > W && j.push("'" + this.terminals_[G] + "'");
|
|
94
|
+
w.showPosition ? Y = "Parse error on line " + (I + 1) + `:
|
|
95
|
+
` + w.showPosition() + `
|
|
96
|
+
Expecting ` + j.join(", ") + ", got '" + (this.terminals_[_] || _) + "'" : Y = "Parse error on line " + (I + 1) + ": Unexpected " + (_ == O ? "end of input" : "'" + (this.terminals_[_] || _) + "'"), this.parseError(Y, {
|
|
97
|
+
text: w.match,
|
|
98
|
+
token: this.terminals_[_] || _,
|
|
99
|
+
line: w.yylineno,
|
|
100
|
+
loc: F,
|
|
101
|
+
expected: j
|
|
102
|
+
});
|
|
103
|
+
}
|
|
104
|
+
if (T[0] instanceof Array && T.length > 1)
|
|
105
|
+
throw new Error("Parse Error: multiple actions possible at state: " + $ + ", token: " + _);
|
|
106
|
+
switch (T[0]) {
|
|
107
|
+
case 1:
|
|
108
|
+
l.push(_), x.push(w.yytext), u.push(w.yylloc), l.push(T[1]), _ = null, C = w.yyleng, v = w.yytext, I = w.yylineno, F = w.yylloc;
|
|
109
|
+
break;
|
|
110
|
+
case 2:
|
|
111
|
+
if (B = this.productions_[T[1]][1], R.$ = x[x.length - B], R._$ = {
|
|
112
|
+
first_line: u[u.length - (B || 1)].first_line,
|
|
113
|
+
last_line: u[u.length - 1].last_line,
|
|
114
|
+
first_column: u[u.length - (B || 1)].first_column,
|
|
115
|
+
last_column: u[u.length - 1].last_column
|
|
116
|
+
}, K && (R._$.range = [
|
|
117
|
+
u[u.length - (B || 1)].range[0],
|
|
118
|
+
u[u.length - 1].range[1]
|
|
119
|
+
]), P = this.performAction.apply(R, [
|
|
120
|
+
v,
|
|
121
|
+
C,
|
|
122
|
+
I,
|
|
123
|
+
H.yy,
|
|
124
|
+
T[1],
|
|
125
|
+
x,
|
|
126
|
+
u
|
|
127
|
+
].concat(L)), typeof P < "u")
|
|
128
|
+
return P;
|
|
129
|
+
B && (l = l.slice(0, -1 * B * 2), x = x.slice(0, -1 * B), u = u.slice(0, -1 * B)), l.push(this.productions_[T[1]][0]), x.push(R.$), u.push(R._$), Z = S[l[l.length - 2]][l[l.length - 1]], l.push(Z);
|
|
130
|
+
break;
|
|
131
|
+
case 3:
|
|
132
|
+
return !0;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
return !0;
|
|
136
|
+
}, "parse")
|
|
137
|
+
}, m = /* @__PURE__ */ (function() {
|
|
138
|
+
var k = {
|
|
139
|
+
EOF: 1,
|
|
140
|
+
parseError: /* @__PURE__ */ o(function(d, l) {
|
|
141
|
+
if (this.yy.parser)
|
|
142
|
+
this.yy.parser.parseError(d, l);
|
|
143
|
+
else
|
|
144
|
+
throw new Error(d);
|
|
145
|
+
}, "parseError"),
|
|
146
|
+
// resets the lexer, sets new input
|
|
147
|
+
setInput: /* @__PURE__ */ o(function(s, d) {
|
|
148
|
+
return this.yy = d || this.yy || {}, this._input = s, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
|
|
149
|
+
first_line: 1,
|
|
150
|
+
first_column: 0,
|
|
151
|
+
last_line: 1,
|
|
152
|
+
last_column: 0
|
|
153
|
+
}, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
|
|
154
|
+
}, "setInput"),
|
|
155
|
+
// consumes and returns one char from the input
|
|
156
|
+
input: /* @__PURE__ */ o(function() {
|
|
157
|
+
var s = this._input[0];
|
|
158
|
+
this.yytext += s, this.yyleng++, this.offset++, this.match += s, this.matched += s;
|
|
159
|
+
var d = s.match(/(?:\r\n?|\n).*/g);
|
|
160
|
+
return d ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), s;
|
|
161
|
+
}, "input"),
|
|
162
|
+
// unshifts one char (or a string) into the input
|
|
163
|
+
unput: /* @__PURE__ */ o(function(s) {
|
|
164
|
+
var d = s.length, l = s.split(/(?:\r\n?|\n)/g);
|
|
165
|
+
this._input = s + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - d), this.offset -= d;
|
|
166
|
+
var p = this.match.split(/(?:\r\n?|\n)/g);
|
|
167
|
+
this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), l.length - 1 && (this.yylineno -= l.length - 1);
|
|
168
|
+
var x = this.yylloc.range;
|
|
169
|
+
return this.yylloc = {
|
|
170
|
+
first_line: this.yylloc.first_line,
|
|
171
|
+
last_line: this.yylineno + 1,
|
|
172
|
+
first_column: this.yylloc.first_column,
|
|
173
|
+
last_column: l ? (l.length === p.length ? this.yylloc.first_column : 0) + p[p.length - l.length].length - l[0].length : this.yylloc.first_column - d
|
|
174
|
+
}, this.options.ranges && (this.yylloc.range = [x[0], x[0] + this.yyleng - d]), this.yyleng = this.yytext.length, this;
|
|
175
|
+
}, "unput"),
|
|
176
|
+
// When called from action, caches matched text and appends it on next action
|
|
177
|
+
more: /* @__PURE__ */ o(function() {
|
|
178
|
+
return this._more = !0, this;
|
|
179
|
+
}, "more"),
|
|
180
|
+
// When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
|
|
181
|
+
reject: /* @__PURE__ */ o(function() {
|
|
182
|
+
if (this.options.backtrack_lexer)
|
|
183
|
+
this._backtrack = !0;
|
|
184
|
+
else
|
|
185
|
+
return this.parseError("Lexical error on line " + (this.yylineno + 1) + `. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
186
|
+
` + this.showPosition(), {
|
|
187
|
+
text: "",
|
|
188
|
+
token: null,
|
|
189
|
+
line: this.yylineno
|
|
190
|
+
});
|
|
191
|
+
return this;
|
|
192
|
+
}, "reject"),
|
|
193
|
+
// retain first n characters of the match
|
|
194
|
+
less: /* @__PURE__ */ o(function(s) {
|
|
195
|
+
this.unput(this.match.slice(s));
|
|
196
|
+
}, "less"),
|
|
197
|
+
// displays already matched input, i.e. for error messages
|
|
198
|
+
pastInput: /* @__PURE__ */ o(function() {
|
|
199
|
+
var s = this.matched.substr(0, this.matched.length - this.match.length);
|
|
200
|
+
return (s.length > 20 ? "..." : "") + s.substr(-20).replace(/\n/g, "");
|
|
201
|
+
}, "pastInput"),
|
|
202
|
+
// displays upcoming input, i.e. for error messages
|
|
203
|
+
upcomingInput: /* @__PURE__ */ o(function() {
|
|
204
|
+
var s = this.match;
|
|
205
|
+
return s.length < 20 && (s += this._input.substr(0, 20 - s.length)), (s.substr(0, 20) + (s.length > 20 ? "..." : "")).replace(/\n/g, "");
|
|
206
|
+
}, "upcomingInput"),
|
|
207
|
+
// displays the character position where the lexing error occurred, i.e. for error messages
|
|
208
|
+
showPosition: /* @__PURE__ */ o(function() {
|
|
209
|
+
var s = this.pastInput(), d = new Array(s.length + 1).join("-");
|
|
210
|
+
return s + this.upcomingInput() + `
|
|
211
|
+
` + d + "^";
|
|
212
|
+
}, "showPosition"),
|
|
213
|
+
// test the lexed token: return FALSE when not a match, otherwise return token
|
|
214
|
+
test_match: /* @__PURE__ */ o(function(s, d) {
|
|
215
|
+
var l, p, x;
|
|
216
|
+
if (this.options.backtrack_lexer && (x = {
|
|
217
|
+
yylineno: this.yylineno,
|
|
218
|
+
yylloc: {
|
|
219
|
+
first_line: this.yylloc.first_line,
|
|
220
|
+
last_line: this.last_line,
|
|
221
|
+
first_column: this.yylloc.first_column,
|
|
222
|
+
last_column: this.yylloc.last_column
|
|
223
|
+
},
|
|
224
|
+
yytext: this.yytext,
|
|
225
|
+
match: this.match,
|
|
226
|
+
matches: this.matches,
|
|
227
|
+
matched: this.matched,
|
|
228
|
+
yyleng: this.yyleng,
|
|
229
|
+
offset: this.offset,
|
|
230
|
+
_more: this._more,
|
|
231
|
+
_input: this._input,
|
|
232
|
+
yy: this.yy,
|
|
233
|
+
conditionStack: this.conditionStack.slice(0),
|
|
234
|
+
done: this.done
|
|
235
|
+
}, this.options.ranges && (x.yylloc.range = this.yylloc.range.slice(0))), p = s[0].match(/(?:\r\n?|\n).*/g), p && (this.yylineno += p.length), this.yylloc = {
|
|
236
|
+
first_line: this.yylloc.last_line,
|
|
237
|
+
last_line: this.yylineno + 1,
|
|
238
|
+
first_column: this.yylloc.last_column,
|
|
239
|
+
last_column: p ? p[p.length - 1].length - p[p.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + s[0].length
|
|
240
|
+
}, this.yytext += s[0], this.match += s[0], this.matches = s, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(s[0].length), this.matched += s[0], l = this.performAction.call(this, this.yy, this, d, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), l)
|
|
241
|
+
return l;
|
|
242
|
+
if (this._backtrack) {
|
|
243
|
+
for (var u in x)
|
|
244
|
+
this[u] = x[u];
|
|
245
|
+
return !1;
|
|
246
|
+
}
|
|
247
|
+
return !1;
|
|
248
|
+
}, "test_match"),
|
|
249
|
+
// return next match in input
|
|
250
|
+
next: /* @__PURE__ */ o(function() {
|
|
251
|
+
if (this.done)
|
|
252
|
+
return this.EOF;
|
|
253
|
+
this._input || (this.done = !0);
|
|
254
|
+
var s, d, l, p;
|
|
255
|
+
this._more || (this.yytext = "", this.match = "");
|
|
256
|
+
for (var x = this._currentRules(), u = 0; u < x.length; u++)
|
|
257
|
+
if (l = this._input.match(this.rules[x[u]]), l && (!d || l[0].length > d[0].length)) {
|
|
258
|
+
if (d = l, p = u, this.options.backtrack_lexer) {
|
|
259
|
+
if (s = this.test_match(l, x[u]), s !== !1)
|
|
260
|
+
return s;
|
|
261
|
+
if (this._backtrack) {
|
|
262
|
+
d = !1;
|
|
263
|
+
continue;
|
|
264
|
+
} else
|
|
265
|
+
return !1;
|
|
266
|
+
} else if (!this.options.flex)
|
|
267
|
+
break;
|
|
268
|
+
}
|
|
269
|
+
return d ? (s = this.test_match(d, x[p]), s !== !1 ? s : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
|
|
270
|
+
` + this.showPosition(), {
|
|
271
|
+
text: "",
|
|
272
|
+
token: null,
|
|
273
|
+
line: this.yylineno
|
|
274
|
+
});
|
|
275
|
+
}, "next"),
|
|
276
|
+
// return next match that has a token
|
|
277
|
+
lex: /* @__PURE__ */ o(function() {
|
|
278
|
+
var d = this.next();
|
|
279
|
+
return d || this.lex();
|
|
280
|
+
}, "lex"),
|
|
281
|
+
// activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
|
|
282
|
+
begin: /* @__PURE__ */ o(function(d) {
|
|
283
|
+
this.conditionStack.push(d);
|
|
284
|
+
}, "begin"),
|
|
285
|
+
// pop the previously active lexer condition state off the condition stack
|
|
286
|
+
popState: /* @__PURE__ */ o(function() {
|
|
287
|
+
var d = this.conditionStack.length - 1;
|
|
288
|
+
return d > 0 ? this.conditionStack.pop() : this.conditionStack[0];
|
|
289
|
+
}, "popState"),
|
|
290
|
+
// produce the lexer rule set which is active for the currently active lexer condition state
|
|
291
|
+
_currentRules: /* @__PURE__ */ o(function() {
|
|
292
|
+
return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
|
|
293
|
+
}, "_currentRules"),
|
|
294
|
+
// return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
|
|
295
|
+
topState: /* @__PURE__ */ o(function(d) {
|
|
296
|
+
return d = this.conditionStack.length - 1 - Math.abs(d || 0), d >= 0 ? this.conditionStack[d] : "INITIAL";
|
|
297
|
+
}, "topState"),
|
|
298
|
+
// alias for begin(condition)
|
|
299
|
+
pushState: /* @__PURE__ */ o(function(d) {
|
|
300
|
+
this.begin(d);
|
|
301
|
+
}, "pushState"),
|
|
302
|
+
// return the number of states currently on the stack
|
|
303
|
+
stateStackSize: /* @__PURE__ */ o(function() {
|
|
304
|
+
return this.conditionStack.length;
|
|
305
|
+
}, "stateStackSize"),
|
|
306
|
+
options: { "case-insensitive": !0 },
|
|
307
|
+
performAction: /* @__PURE__ */ o(function(d, l, p, x) {
|
|
308
|
+
switch (p) {
|
|
309
|
+
case 0:
|
|
310
|
+
break;
|
|
311
|
+
case 1:
|
|
312
|
+
break;
|
|
313
|
+
case 2:
|
|
314
|
+
return 13;
|
|
315
|
+
case 3:
|
|
316
|
+
break;
|
|
317
|
+
case 4:
|
|
318
|
+
break;
|
|
319
|
+
case 5:
|
|
320
|
+
return 8;
|
|
321
|
+
case 6:
|
|
322
|
+
return 9;
|
|
323
|
+
case 7:
|
|
324
|
+
return 7;
|
|
325
|
+
case 8:
|
|
326
|
+
return 14;
|
|
327
|
+
case 9:
|
|
328
|
+
return this.begin("acc_title"), 15;
|
|
329
|
+
case 10:
|
|
330
|
+
return this.popState(), "acc_title_value";
|
|
331
|
+
case 11:
|
|
332
|
+
return this.begin("acc_descr"), 17;
|
|
333
|
+
case 12:
|
|
334
|
+
return this.popState(), "acc_descr_value";
|
|
335
|
+
case 13:
|
|
336
|
+
this.begin("acc_descr_multiline");
|
|
337
|
+
break;
|
|
338
|
+
case 14:
|
|
339
|
+
this.popState();
|
|
340
|
+
break;
|
|
341
|
+
case 15:
|
|
342
|
+
return "acc_descr_multiline_value";
|
|
343
|
+
case 16:
|
|
344
|
+
return 20;
|
|
345
|
+
case 17:
|
|
346
|
+
return 24;
|
|
347
|
+
case 18:
|
|
348
|
+
return 23;
|
|
349
|
+
case 19:
|
|
350
|
+
return 6;
|
|
351
|
+
case 20:
|
|
352
|
+
return "INVALID";
|
|
353
|
+
}
|
|
354
|
+
}, "anonymous"),
|
|
355
|
+
rules: [/^(?:%(?!\{)[^\n]*)/i, /^(?:[^\}]%%[^\n]*)/i, /^(?:[\n]+)/i, /^(?:\s+)/i, /^(?:#[^\n]*)/i, /^(?:timeline[ \t]+LR\b)/i, /^(?:timeline[ \t]+TD\b)/i, /^(?:timeline\b)/i, /^(?:title\s[^\n]+)/i, /^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:[\}])/i, /^(?:[^\}]*)/i, /^(?:section\s[^:\n]+)/i, /^(?::\s(?:[^:\n]|:(?!\s))+)/i, /^(?:[^#:\n]+)/i, /^(?:$)/i, /^(?:.)/i],
|
|
356
|
+
conditions: { acc_descr_multiline: { rules: [14, 15], inclusive: !1 }, acc_descr: { rules: [12], inclusive: !1 }, acc_title: { rules: [10], inclusive: !1 }, INITIAL: { rules: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 16, 17, 18, 19, 20], inclusive: !0 } }
|
|
357
|
+
};
|
|
358
|
+
return k;
|
|
359
|
+
})();
|
|
360
|
+
g.lexer = m;
|
|
361
|
+
function y() {
|
|
362
|
+
this.yy = {};
|
|
363
|
+
}
|
|
364
|
+
return o(y, "Parser"), y.prototype = g, g.Parser = y, new y();
|
|
365
|
+
})();
|
|
366
|
+
tt.parser = tt;
|
|
367
|
+
var Ot = tt, yt = {};
|
|
368
|
+
Vt(yt, {
|
|
369
|
+
addEvent: () => Tt,
|
|
370
|
+
addSection: () => _t,
|
|
371
|
+
addTask: () => Et,
|
|
372
|
+
addTaskOrg: () => $t,
|
|
373
|
+
clear: () => kt,
|
|
374
|
+
default: () => Gt,
|
|
375
|
+
getCommonDb: () => xt,
|
|
376
|
+
getDirection: () => bt,
|
|
377
|
+
getSections: () => wt,
|
|
378
|
+
getTasks: () => St,
|
|
379
|
+
setDirection: () => vt
|
|
380
|
+
});
|
|
381
|
+
var D = "", mt = 0, nt = "LR", rt = [], q = [], X = [], xt = /* @__PURE__ */ o(() => Ft, "getCommonDb"), kt = /* @__PURE__ */ o(function() {
|
|
382
|
+
rt.length = 0, q.length = 0, D = "", X.length = 0, nt = "LR", zt();
|
|
383
|
+
}, "clear"), vt = /* @__PURE__ */ o(function(e) {
|
|
384
|
+
nt = e;
|
|
385
|
+
}, "setDirection"), bt = /* @__PURE__ */ o(function() {
|
|
386
|
+
return nt;
|
|
387
|
+
}, "getDirection"), _t = /* @__PURE__ */ o(function(e) {
|
|
388
|
+
D = e, rt.push(e);
|
|
389
|
+
}, "addSection"), wt = /* @__PURE__ */ o(function() {
|
|
390
|
+
return rt;
|
|
391
|
+
}, "getSections"), St = /* @__PURE__ */ o(function() {
|
|
392
|
+
let e = ct();
|
|
393
|
+
const t = 100;
|
|
394
|
+
let n = 0;
|
|
395
|
+
for (; !e && n < t; )
|
|
396
|
+
e = ct(), n++;
|
|
397
|
+
return q.push(...X), q;
|
|
398
|
+
}, "getTasks"), Et = /* @__PURE__ */ o(function(e, t, n) {
|
|
399
|
+
const i = {
|
|
400
|
+
id: mt++,
|
|
401
|
+
section: D,
|
|
402
|
+
type: D,
|
|
403
|
+
task: e,
|
|
404
|
+
score: t || 0,
|
|
405
|
+
//if event is defined, then add it the events array
|
|
406
|
+
events: n ? [n] : []
|
|
407
|
+
};
|
|
408
|
+
X.push(i);
|
|
409
|
+
}, "addTask"), Tt = /* @__PURE__ */ o(function(e) {
|
|
410
|
+
X.find((n) => n.id === mt - 1).events.push(e);
|
|
411
|
+
}, "addEvent"), $t = /* @__PURE__ */ o(function(e) {
|
|
412
|
+
const t = {
|
|
413
|
+
section: D,
|
|
414
|
+
type: D,
|
|
415
|
+
description: e,
|
|
416
|
+
task: e,
|
|
417
|
+
classes: []
|
|
418
|
+
};
|
|
419
|
+
q.push(t);
|
|
420
|
+
}, "addTaskOrg"), ct = /* @__PURE__ */ o(function() {
|
|
421
|
+
const e = /* @__PURE__ */ o(function(n) {
|
|
422
|
+
return X[n].processed;
|
|
423
|
+
}, "compileTask");
|
|
424
|
+
let t = !0;
|
|
425
|
+
for (const [n, i] of X.entries())
|
|
426
|
+
e(n), t = t && i.processed;
|
|
427
|
+
return t;
|
|
428
|
+
}, "compileTasks"), Gt = {
|
|
429
|
+
clear: kt,
|
|
430
|
+
getCommonDb: xt,
|
|
431
|
+
getDirection: bt,
|
|
432
|
+
setDirection: vt,
|
|
433
|
+
addSection: _t,
|
|
434
|
+
getSections: wt,
|
|
435
|
+
getTasks: St,
|
|
436
|
+
addTask: Et,
|
|
437
|
+
addTaskOrg: $t,
|
|
438
|
+
addEvent: Tt
|
|
439
|
+
}, Nt = 0, J = /* @__PURE__ */ o(function(e, t) {
|
|
440
|
+
const n = e.append("rect");
|
|
441
|
+
return n.attr("x", t.x), n.attr("y", t.y), n.attr("fill", t.fill), n.attr("stroke", t.stroke), n.attr("width", t.width), n.attr("height", t.height), n.attr("rx", t.rx), n.attr("ry", t.ry), t.class !== void 0 && n.attr("class", t.class), n;
|
|
442
|
+
}, "drawRect"), Dt = /* @__PURE__ */ o(function(e, t) {
|
|
443
|
+
const i = e.append("circle").attr("cx", t.cx).attr("cy", t.cy).attr("class", "face").attr("r", 15).attr("stroke-width", 2).attr("overflow", "visible"), r = e.append("g");
|
|
444
|
+
r.append("circle").attr("cx", t.cx - 15 / 3).attr("cy", t.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666"), r.append("circle").attr("cx", t.cx + 15 / 3).attr("cy", t.cy - 15 / 3).attr("r", 1.5).attr("stroke-width", 2).attr("fill", "#666").attr("stroke", "#666");
|
|
445
|
+
function h(f) {
|
|
446
|
+
const g = ot().startAngle(Math.PI / 2).endAngle(3 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
|
|
447
|
+
f.append("path").attr("class", "mouth").attr("d", g).attr("transform", "translate(" + t.cx + "," + (t.cy + 2) + ")");
|
|
448
|
+
}
|
|
449
|
+
o(h, "smile");
|
|
450
|
+
function c(f) {
|
|
451
|
+
const g = ot().startAngle(3 * Math.PI / 2).endAngle(5 * (Math.PI / 2)).innerRadius(7.5).outerRadius(6.8181818181818175);
|
|
452
|
+
f.append("path").attr("class", "mouth").attr("d", g).attr("transform", "translate(" + t.cx + "," + (t.cy + 7) + ")");
|
|
453
|
+
}
|
|
454
|
+
o(c, "sad");
|
|
455
|
+
function a(f) {
|
|
456
|
+
f.append("line").attr("class", "mouth").attr("stroke", 2).attr("x1", t.cx - 5).attr("y1", t.cy + 7).attr("x2", t.cx + 5).attr("y2", t.cy + 7).attr("class", "mouth").attr("stroke-width", "1px").attr("stroke", "#666");
|
|
457
|
+
}
|
|
458
|
+
return o(a, "ambivalent"), t.score > 3 ? h(r) : t.score < 3 ? c(r) : a(r), i;
|
|
459
|
+
}, "drawFace"), Xt = /* @__PURE__ */ o(function(e, t) {
|
|
460
|
+
const n = e.append("circle");
|
|
461
|
+
return n.attr("cx", t.cx), n.attr("cy", t.cy), n.attr("class", "actor-" + t.pos), n.attr("fill", t.fill), n.attr("stroke", t.stroke), n.attr("r", t.r), n.class !== void 0 && n.attr("class", n.class), t.title !== void 0 && n.append("title").text(t.title), n;
|
|
462
|
+
}, "drawCircle"), It = /* @__PURE__ */ o(function(e, t) {
|
|
463
|
+
const n = t.text.replace(/<br\s*\/?>/gi, " "), i = e.append("text");
|
|
464
|
+
i.attr("x", t.x), i.attr("y", t.y), i.attr("class", "legend"), i.style("text-anchor", t.anchor), t.class !== void 0 && i.attr("class", t.class);
|
|
465
|
+
const r = i.append("tspan");
|
|
466
|
+
return r.attr("x", t.x + t.textMargin * 2), r.text(n), i;
|
|
467
|
+
}, "drawText"), Kt = /* @__PURE__ */ o(function(e, t) {
|
|
468
|
+
function n(r, h, c, a, f) {
|
|
469
|
+
return r + "," + h + " " + (r + c) + "," + h + " " + (r + c) + "," + (h + a - f) + " " + (r + c - f * 1.2) + "," + (h + a) + " " + r + "," + (h + a);
|
|
470
|
+
}
|
|
471
|
+
o(n, "genPoints");
|
|
472
|
+
const i = e.append("polygon");
|
|
473
|
+
i.attr("points", n(t.x, t.y, 50, 20, 7)), i.attr("class", "labelBox"), t.y = t.y + t.labelMargin, t.x = t.x + 0.5 * t.labelMargin, It(e, t);
|
|
474
|
+
}, "drawLabel"), Ut = /* @__PURE__ */ o(function(e, t, n) {
|
|
475
|
+
const i = e.append("g"), r = st();
|
|
476
|
+
r.x = t.x, r.y = t.y, r.fill = t.fill, r.width = n.width, r.height = n.height, r.class = "journey-section section-type-" + t.num, r.rx = 3, r.ry = 3, J(i, r), Ht(n)(
|
|
477
|
+
t.text,
|
|
478
|
+
i,
|
|
479
|
+
r.x,
|
|
480
|
+
r.y,
|
|
481
|
+
r.width,
|
|
482
|
+
r.height,
|
|
483
|
+
{ class: "journey-section section-type-" + t.num },
|
|
484
|
+
n,
|
|
485
|
+
t.colour
|
|
486
|
+
);
|
|
487
|
+
}, "drawSection"), et = -1, Zt = /* @__PURE__ */ o(function(e, t, n, i) {
|
|
488
|
+
const r = t.x + n.width / 2, h = e.append("g");
|
|
489
|
+
et++, h.append("line").attr("id", i + "-task" + et).attr("x1", r).attr("y1", t.y).attr("x2", r).attr("y2", 450).attr("class", "task-line").attr("stroke-width", "1px").attr("stroke-dasharray", "4 2").attr("stroke", "#666"), Dt(h, {
|
|
490
|
+
cx: r,
|
|
491
|
+
cy: 300 + (5 - t.score) * 30,
|
|
492
|
+
score: t.score
|
|
493
|
+
});
|
|
494
|
+
const a = st();
|
|
495
|
+
a.x = t.x, a.y = t.y, a.fill = t.fill, a.width = n.width, a.height = n.height, a.class = "task task-type-" + t.num, a.rx = 3, a.ry = 3, J(h, a), Ht(n)(
|
|
496
|
+
t.task,
|
|
497
|
+
h,
|
|
498
|
+
a.x,
|
|
499
|
+
a.y,
|
|
500
|
+
a.width,
|
|
501
|
+
a.height,
|
|
502
|
+
{ class: "task" },
|
|
503
|
+
n,
|
|
504
|
+
t.colour
|
|
505
|
+
);
|
|
506
|
+
}, "drawTask"), jt = /* @__PURE__ */ o(function(e, t) {
|
|
507
|
+
J(e, {
|
|
508
|
+
x: t.startx,
|
|
509
|
+
y: t.starty,
|
|
510
|
+
width: t.stopx - t.startx,
|
|
511
|
+
height: t.stopy - t.starty,
|
|
512
|
+
fill: t.fill,
|
|
513
|
+
class: "rect"
|
|
514
|
+
}).lower();
|
|
515
|
+
}, "drawBackgroundRect"), qt = /* @__PURE__ */ o(function() {
|
|
516
|
+
return {
|
|
517
|
+
x: 0,
|
|
518
|
+
y: 0,
|
|
519
|
+
fill: void 0,
|
|
520
|
+
"text-anchor": "start",
|
|
521
|
+
width: 100,
|
|
522
|
+
height: 100,
|
|
523
|
+
textMargin: 0,
|
|
524
|
+
rx: 0,
|
|
525
|
+
ry: 0
|
|
526
|
+
};
|
|
527
|
+
}, "getTextObj"), st = /* @__PURE__ */ o(function() {
|
|
528
|
+
return {
|
|
529
|
+
x: 0,
|
|
530
|
+
y: 0,
|
|
531
|
+
width: 100,
|
|
532
|
+
anchor: "start",
|
|
533
|
+
height: 100,
|
|
534
|
+
rx: 0,
|
|
535
|
+
ry: 0
|
|
536
|
+
};
|
|
537
|
+
}, "getNoteRect"), Ht = /* @__PURE__ */ (function() {
|
|
538
|
+
function e(r, h, c, a, f, g, m, y) {
|
|
539
|
+
const k = h.append("text").attr("x", c + f / 2).attr("y", a + g / 2 + 5).style("font-color", y).style("text-anchor", "middle").text(r);
|
|
540
|
+
i(k, m);
|
|
541
|
+
}
|
|
542
|
+
o(e, "byText");
|
|
543
|
+
function t(r, h, c, a, f, g, m, y, k) {
|
|
544
|
+
const { taskFontSize: s, taskFontFamily: d } = y, l = r.split(/<br\s*\/?>/gi);
|
|
545
|
+
for (let p = 0; p < l.length; p++) {
|
|
546
|
+
const x = p * s - s * (l.length - 1) / 2, u = h.append("text").attr("x", c + f / 2).attr("y", a).attr("fill", k).style("text-anchor", "middle").style("font-size", s).style("font-family", d);
|
|
547
|
+
u.append("tspan").attr("x", c + f / 2).attr("dy", x).text(l[p]), u.attr("y", a + g / 2).attr("dominant-baseline", "central").attr("alignment-baseline", "central"), i(u, m);
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
o(t, "byTspan");
|
|
551
|
+
function n(r, h, c, a, f, g, m, y) {
|
|
552
|
+
const k = h.append("switch"), d = k.append("foreignObject").attr("x", c).attr("y", a).attr("width", f).attr("height", g).attr("position", "fixed").append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
|
|
553
|
+
d.append("div").attr("class", "label").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(r), t(r, k, c, a, f, g, m, y), i(d, m);
|
|
554
|
+
}
|
|
555
|
+
o(n, "byFo");
|
|
556
|
+
function i(r, h) {
|
|
557
|
+
for (const c in h)
|
|
558
|
+
c in h && r.attr(c, h[c]);
|
|
559
|
+
}
|
|
560
|
+
return o(i, "_setTextAttrs"), function(r) {
|
|
561
|
+
return r.textPlacement === "fo" ? n : r.textPlacement === "old" ? e : t;
|
|
562
|
+
};
|
|
563
|
+
})(), Jt = /* @__PURE__ */ o(function(e, t) {
|
|
564
|
+
Nt = 0, et = -1, e.append("defs").append("marker").attr("id", t + "-arrowhead").attr("refX", 5).attr("refY", 2).attr("markerWidth", 6).attr("markerHeight", 4).attr("orient", "auto").append("path").attr("d", "M 0,0 V 4 L6,2 Z");
|
|
565
|
+
}, "initGraphics");
|
|
566
|
+
function it(e, t) {
|
|
567
|
+
e.each(function() {
|
|
568
|
+
var n = U(this), i = n.text().split(/(\s+|<br>)/).reverse(), r, h = [], c = 1.1, a = n.attr("y"), f = parseFloat(n.attr("dy")), g = n.text(null).append("tspan").attr("x", 0).attr("y", a).attr("dy", f + "em");
|
|
569
|
+
for (let m = 0; m < i.length; m++)
|
|
570
|
+
r = i[i.length - 1 - m], h.push(r), g.text(h.join(" ").trim()), (g.node().getComputedTextLength() > t || r === "<br>") && (h.pop(), g.text(h.join(" ").trim()), r === "<br>" ? h = [""] : h = [r], g = n.append("tspan").attr("x", 0).attr("y", a).attr("dy", c + "em").text(r));
|
|
571
|
+
});
|
|
572
|
+
}
|
|
573
|
+
o(it, "wrap");
|
|
574
|
+
var Qt = /* @__PURE__ */ o(function(e, t, n, i, r, h = !1) {
|
|
575
|
+
const { theme: c, look: a } = i, f = c?.includes("redux"), g = i?.themeVariables?.THEME_COLOR_LIMIT ?? 12, m = n % g - 1, y = e.append("g");
|
|
576
|
+
t.section = m, y.attr(
|
|
577
|
+
"class",
|
|
578
|
+
(t.class ? t.class + " " : "") + "timeline-node " + ("section-" + m)
|
|
579
|
+
);
|
|
580
|
+
const k = y.append("g"), s = y.append("g"), l = s.append("text").text(t.descr).attr("dy", "1em").attr("alignment-baseline", "middle").attr("dominant-baseline", "middle").attr("text-anchor", "middle").call(it, t.width).node().getBBox(), p = i.fontSize?.replace ? i.fontSize.replace("px", "") : i.fontSize;
|
|
581
|
+
if (t.height = l.height + p * 1.1 * 0.5 + t.padding, t.height = Math.max(t.height, t.maxHeight), t.width = t.width + 2 * t.padding, s.attr("transform", "translate(" + t.width / 2 + ", " + t.padding / 2 + ")"), f && s.attr(
|
|
582
|
+
"transform",
|
|
583
|
+
`translate(${t.width / 2}, ${h ? t.padding / 2 + 3 : t.padding})`
|
|
584
|
+
), te(k, t, m, r, i), a === "neo" && (y.attr("data-look", "neo"), f)) {
|
|
585
|
+
const x = c.includes("dark"), u = e.node()?.ownerSVGElement ?? e.node(), S = U(u), v = S.attr("id") ?? "", I = v ? `${v}-drop-shadow` : "drop-shadow";
|
|
586
|
+
if (S.select(`#${I}`).empty()) {
|
|
587
|
+
const C = S.select("defs");
|
|
588
|
+
(C.empty() ? S.append("defs") : C).append("filter").attr("id", I).attr("height", "130%").attr("width", "130%").append("feDropShadow").attr("dx", "4").attr("dy", "4").attr("stdDeviation", 0).attr("flood-opacity", x ? "0.2" : "0.06").attr("flood-color", x ? "#FFFFFF" : "#000000");
|
|
589
|
+
}
|
|
590
|
+
}
|
|
591
|
+
return t;
|
|
592
|
+
}, "drawNode"), Yt = /* @__PURE__ */ o(function(e, t, n) {
|
|
593
|
+
const i = e.append("g"), h = i.append("text").text(t.descr).attr("dy", "1em").attr("alignment-baseline", "middle").attr("dominant-baseline", "middle").attr("text-anchor", "middle").call(it, t.width).node().getBBox(), c = n.fontSize?.replace ? n.fontSize.replace("px", "") : n.fontSize;
|
|
594
|
+
return i.remove(), h.height + c * 1.1 * 0.5 + t.padding;
|
|
595
|
+
}, "getVirtualNodeHeight"), te = /* @__PURE__ */ o(function(e, t, n, i, r) {
|
|
596
|
+
const { theme: h } = r, c = h?.includes("redux") ? 0 : 5, a = 5, f = c > 0 ? `M0 ${t.height - a} v${-t.height + 2 * a} q0,-${c},${c},-${c} h${t.width - 2 * a} q${c},0,${c},${c} v${t.height - a} H0 Z` : `M0 ${t.height - a} v${-(t.height - a)} h${t.width} v${t.height} H0 Z`;
|
|
597
|
+
e.append("path").attr("id", i + "-node-" + Nt++).attr("class", "node-bkg node-" + t.type).attr("d", f), h?.includes("redux") || e.append("line").attr("class", "node-line-" + n).attr("x1", 0).attr("y1", t.height).attr("x2", t.width).attr("y2", t.height);
|
|
598
|
+
}, "defaultBkg"), M = {
|
|
599
|
+
drawRect: J,
|
|
600
|
+
drawCircle: Xt,
|
|
601
|
+
drawSection: Ut,
|
|
602
|
+
drawText: It,
|
|
603
|
+
drawLabel: Kt,
|
|
604
|
+
drawTask: Zt,
|
|
605
|
+
drawBackgroundRect: jt,
|
|
606
|
+
getTextObj: qt,
|
|
607
|
+
getNoteRect: st,
|
|
608
|
+
initGraphics: Jt,
|
|
609
|
+
drawNode: Qt,
|
|
610
|
+
getVirtualNodeHeight: Yt
|
|
611
|
+
}, ee = /* @__PURE__ */ o(function(e, t, n, i) {
|
|
612
|
+
const r = gt(), { look: h, theme: c, themeVariables: a } = r, { useGradient: f, gradientStart: g, gradientStop: m } = a, y = r.timeline?.leftMargin ?? 50;
|
|
613
|
+
E.debug("timeline", i.db);
|
|
614
|
+
const k = r.securityLevel;
|
|
615
|
+
let s;
|
|
616
|
+
k === "sandbox" && (s = U("#i" + t));
|
|
617
|
+
const l = (k === "sandbox" ? U(s.nodes()[0].contentDocument.body) : U("body")).select("#" + t);
|
|
618
|
+
l.append("g");
|
|
619
|
+
const p = i.db.getTasks(), x = i.db.getCommonDb().getDiagramTitle();
|
|
620
|
+
E.debug("task", p), M.initGraphics(l, t);
|
|
621
|
+
const u = i.db.getSections();
|
|
622
|
+
E.debug("sections", u);
|
|
623
|
+
let S = 0, v = 0, I = 0, C = 0, W = 50 + y, O = 50;
|
|
624
|
+
C = 50;
|
|
625
|
+
let L = 0, w = !0;
|
|
626
|
+
u.forEach(function(N) {
|
|
627
|
+
const b = {
|
|
628
|
+
number: L,
|
|
629
|
+
descr: N,
|
|
630
|
+
section: L,
|
|
631
|
+
width: 150,
|
|
632
|
+
padding: 20,
|
|
633
|
+
maxHeight: S
|
|
634
|
+
}, _ = M.getVirtualNodeHeight(l, b, r);
|
|
635
|
+
E.debug("sectionHeight before draw", _), S = Math.max(S, _ + 20);
|
|
636
|
+
});
|
|
637
|
+
let H = 0, V = 0;
|
|
638
|
+
E.debug("tasks.length", p.length);
|
|
639
|
+
for (const [N, b] of p.entries()) {
|
|
640
|
+
const _ = {
|
|
641
|
+
number: N,
|
|
642
|
+
descr: b,
|
|
643
|
+
section: b.section,
|
|
644
|
+
width: 150,
|
|
645
|
+
padding: 20,
|
|
646
|
+
maxHeight: v
|
|
647
|
+
}, $ = M.getVirtualNodeHeight(l, _, r);
|
|
648
|
+
E.debug("taskHeight before draw", $), v = Math.max(v, $ + 20), H = Math.max(H, b.events.length);
|
|
649
|
+
let T = 0;
|
|
650
|
+
for (const P of b.events) {
|
|
651
|
+
const R = {
|
|
652
|
+
descr: P,
|
|
653
|
+
section: b.section,
|
|
654
|
+
number: b.section,
|
|
655
|
+
width: 150,
|
|
656
|
+
padding: 20,
|
|
657
|
+
maxHeight: 50
|
|
658
|
+
};
|
|
659
|
+
T += M.getVirtualNodeHeight(l, R, r);
|
|
660
|
+
}
|
|
661
|
+
b.events.length > 0 && (T += (b.events.length - 1) * 10), V = Math.max(V, T);
|
|
662
|
+
}
|
|
663
|
+
E.debug("maxSectionHeight before draw", S), E.debug("maxTaskHeight before draw", v), u && u.length > 0 ? u.forEach((N) => {
|
|
664
|
+
const b = p.filter((P) => P.section === N), _ = {
|
|
665
|
+
number: L,
|
|
666
|
+
descr: N,
|
|
667
|
+
section: L,
|
|
668
|
+
width: 200 * Math.max(b.length, 1) - 50,
|
|
669
|
+
padding: 20,
|
|
670
|
+
maxHeight: S
|
|
671
|
+
};
|
|
672
|
+
E.debug("sectionNode", _);
|
|
673
|
+
const $ = l.append("g"), T = M.drawNode($, _, L, r, t);
|
|
674
|
+
E.debug("sectionNode output", T), $.attr("transform", `translate(${W}, ${C})`), O += S + 50, b.length > 0 && lt(
|
|
675
|
+
l,
|
|
676
|
+
b,
|
|
677
|
+
L,
|
|
678
|
+
W,
|
|
679
|
+
O,
|
|
680
|
+
v,
|
|
681
|
+
r,
|
|
682
|
+
H,
|
|
683
|
+
V,
|
|
684
|
+
S,
|
|
685
|
+
!1,
|
|
686
|
+
t
|
|
687
|
+
), W += 200 * Math.max(b.length, 1), O = C, L++;
|
|
688
|
+
}) : (w = !1, lt(
|
|
689
|
+
l,
|
|
690
|
+
p,
|
|
691
|
+
L,
|
|
692
|
+
W,
|
|
693
|
+
O,
|
|
694
|
+
v,
|
|
695
|
+
r,
|
|
696
|
+
H,
|
|
697
|
+
V,
|
|
698
|
+
S,
|
|
699
|
+
!0,
|
|
700
|
+
t
|
|
701
|
+
));
|
|
702
|
+
const F = l.node().getBBox();
|
|
703
|
+
if (E.debug("bounds", F), x && l.append("text").text(x).attr("x", h === "neo" ? F.x * 2 + y : F.width / 2 - y).attr("font-size", "4ex").attr("font-weight", "bold").attr("y", 20), I = w ? S + v + 150 : v + 100, l.append("g").attr("class", "lineWrapper").append("line").attr("x1", y).attr("y1", I).attr("x2", F.width + 3 * y).attr("y2", I).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", `url(#${t}-arrowhead)`), h === "neo" && f && c !== "neutral") {
|
|
704
|
+
const N = l.select("defs"), _ = (N.empty() ? l.append("defs") : N).append("linearGradient").attr("id", l.attr("id") + "-gradient").attr("gradientUnits", "objectBoundingBox").attr("x1", "0%").attr("y1", "0%").attr("x2", "100%").attr("y2", "0%");
|
|
705
|
+
_.append("stop").attr("offset", "0%").attr("stop-color", g).attr("stop-opacity", 1), _.append("stop").attr("offset", "100%").attr("stop-color", m).attr("stop-opacity", 1);
|
|
706
|
+
}
|
|
707
|
+
ft(
|
|
708
|
+
void 0,
|
|
709
|
+
l,
|
|
710
|
+
r.timeline?.padding ?? 50,
|
|
711
|
+
r.timeline?.useMaxWidth ?? !1
|
|
712
|
+
);
|
|
713
|
+
}, "draw"), lt = /* @__PURE__ */ o(function(e, t, n, i, r, h, c, a, f, g, m, y) {
|
|
714
|
+
for (const k of t) {
|
|
715
|
+
const s = {
|
|
716
|
+
descr: k.task,
|
|
717
|
+
section: n,
|
|
718
|
+
number: n,
|
|
719
|
+
width: 150,
|
|
720
|
+
padding: 20,
|
|
721
|
+
maxHeight: h
|
|
722
|
+
};
|
|
723
|
+
E.debug("taskNode", s);
|
|
724
|
+
const d = e.append("g").attr("class", "taskWrapper"), p = M.drawNode(d, s, n, c, y).height;
|
|
725
|
+
if (E.debug("taskHeight after draw", p), d.attr("transform", `translate(${i}, ${r})`), h = Math.max(h, p), k.events) {
|
|
726
|
+
const x = e.append("g").attr("class", "lineWrapper");
|
|
727
|
+
let u = h;
|
|
728
|
+
r += 100, u = u + ne(e, k.events, n, i, r, c, y), r -= 100, x.append("line").attr("x1", i + 190 / 2).attr("y1", r + h).attr("x2", i + 190 / 2).attr("y2", r + h + 100 + f + 100).attr("stroke-width", 2).attr("stroke", "black").attr("marker-end", `url(#${y}-arrowhead)`).attr("stroke-dasharray", "5,5");
|
|
729
|
+
}
|
|
730
|
+
i = i + 200, m && !c.timeline?.disableMulticolor && n++;
|
|
731
|
+
}
|
|
732
|
+
r = r - 10;
|
|
733
|
+
}, "drawTasks"), ne = /* @__PURE__ */ o(function(e, t, n, i, r, h, c) {
|
|
734
|
+
let a = 0;
|
|
735
|
+
const f = r;
|
|
736
|
+
r = r + 100;
|
|
737
|
+
for (const g of t) {
|
|
738
|
+
const m = {
|
|
739
|
+
descr: g,
|
|
740
|
+
section: n,
|
|
741
|
+
number: n,
|
|
742
|
+
width: 150,
|
|
743
|
+
padding: 20,
|
|
744
|
+
maxHeight: 50
|
|
745
|
+
};
|
|
746
|
+
E.debug("eventNode", m);
|
|
747
|
+
const y = e.append("g").attr("class", "eventWrapper"), s = M.drawNode(y, m, n, h, c, !0).height;
|
|
748
|
+
a = a + s, y.attr("transform", `translate(${i}, ${r})`), r = r + 10 + s;
|
|
749
|
+
}
|
|
750
|
+
return r = f, a;
|
|
751
|
+
}, "drawEvents"), re = {
|
|
752
|
+
setConf: /* @__PURE__ */ o(() => {
|
|
753
|
+
}, "setConf"),
|
|
754
|
+
draw: ee
|
|
755
|
+
}, Q = 200, z = 5, se = Q + z * 2, at = Q + 100, ie = at + z * 2, Lt = 10, ae = 0, ht = 20, Mt = 20, dt = 30, At = 50, oe = /* @__PURE__ */ o(function(e, t, n, i) {
|
|
756
|
+
const r = gt(), h = r.timeline?.leftMargin ?? 50;
|
|
757
|
+
E.debug("timeline", i.db);
|
|
758
|
+
const c = Pt(t);
|
|
759
|
+
c.append("g");
|
|
760
|
+
const a = i.db.getTasks(), f = i.db.getCommonDb().getDiagramTitle();
|
|
761
|
+
E.debug("task", a), M.initGraphics(c);
|
|
762
|
+
const g = i.db.getSections();
|
|
763
|
+
E.debug("sections", g);
|
|
764
|
+
let m = 0, y = 0;
|
|
765
|
+
const k = 50 + h;
|
|
766
|
+
let s = 50;
|
|
767
|
+
const d = s, l = k, p = se + Mt, x = ie + At, u = l + p;
|
|
768
|
+
let S = 0;
|
|
769
|
+
const v = g && g.length > 0, I = v ? u : k + p, C = Math.max(50, p + x - z * 2);
|
|
770
|
+
g.forEach(function(N) {
|
|
771
|
+
const b = {
|
|
772
|
+
number: S,
|
|
773
|
+
descr: N,
|
|
774
|
+
section: S,
|
|
775
|
+
width: C,
|
|
776
|
+
padding: z,
|
|
777
|
+
maxHeight: m
|
|
778
|
+
}, _ = M.getVirtualNodeHeight(c, b, r);
|
|
779
|
+
E.debug("sectionHeight before draw", _), m = Math.max(m, _);
|
|
780
|
+
});
|
|
781
|
+
let W = 0;
|
|
782
|
+
E.debug("tasks.length", a.length);
|
|
783
|
+
for (const [N, b] of a.entries()) {
|
|
784
|
+
const _ = {
|
|
785
|
+
number: N,
|
|
786
|
+
descr: b,
|
|
787
|
+
section: b.section,
|
|
788
|
+
width: Q,
|
|
789
|
+
padding: z,
|
|
790
|
+
maxHeight: y
|
|
791
|
+
}, $ = M.getVirtualNodeHeight(c, _, r);
|
|
792
|
+
E.debug("taskHeight before draw", $), y = Math.max(y, $);
|
|
793
|
+
let T = 0;
|
|
794
|
+
for (const P of b.events) {
|
|
795
|
+
const R = {
|
|
796
|
+
descr: P,
|
|
797
|
+
section: b.section,
|
|
798
|
+
number: b.section,
|
|
799
|
+
width: at,
|
|
800
|
+
padding: z,
|
|
801
|
+
maxHeight: 50
|
|
802
|
+
};
|
|
803
|
+
T += M.getVirtualNodeHeight(c, R, r);
|
|
804
|
+
}
|
|
805
|
+
b.events.length > 0 && (T += (b.events.length - 1) * Lt), W = Math.max(W, T) + ae;
|
|
806
|
+
}
|
|
807
|
+
E.debug("maxSectionHeight before draw", m), E.debug("maxTaskHeight before draw", y);
|
|
808
|
+
const L = Math.max(y, W) + dt;
|
|
809
|
+
v ? g.forEach((N) => {
|
|
810
|
+
const b = a.filter((Z) => Z.section === N), _ = {
|
|
811
|
+
number: S,
|
|
812
|
+
descr: N,
|
|
813
|
+
section: S,
|
|
814
|
+
width: C,
|
|
815
|
+
padding: z,
|
|
816
|
+
maxHeight: m
|
|
817
|
+
};
|
|
818
|
+
E.debug("sectionNode", _);
|
|
819
|
+
const $ = c.append("g"), T = M.drawNode($, _, S, r);
|
|
820
|
+
E.debug("sectionNode output", T);
|
|
821
|
+
const P = I - p;
|
|
822
|
+
$.attr("transform", `translate(${P}, ${s})`);
|
|
823
|
+
const R = s + T.height + ht;
|
|
824
|
+
b.length > 0 && ut(
|
|
825
|
+
c,
|
|
826
|
+
b,
|
|
827
|
+
S,
|
|
828
|
+
I,
|
|
829
|
+
R,
|
|
830
|
+
y,
|
|
831
|
+
r,
|
|
832
|
+
L,
|
|
833
|
+
!1
|
|
834
|
+
);
|
|
835
|
+
const G = b.length, B = T.height + ht + L * Math.max(G, 1) - (G > 0 ? dt * 2 : 0);
|
|
836
|
+
s += B, S++;
|
|
837
|
+
}) : ut(
|
|
838
|
+
c,
|
|
839
|
+
a,
|
|
840
|
+
S,
|
|
841
|
+
I,
|
|
842
|
+
s,
|
|
843
|
+
y,
|
|
844
|
+
r,
|
|
845
|
+
L,
|
|
846
|
+
!0
|
|
847
|
+
);
|
|
848
|
+
let w = c.node()?.getBBox();
|
|
849
|
+
if (!w)
|
|
850
|
+
throw new Error("bbox not found");
|
|
851
|
+
if (E.debug("bounds", w), f) {
|
|
852
|
+
if (c.append("text").text(f).attr("x", w.width / 2 - h).attr("font-size", "4ex").attr("font-weight", "bold").attr("y", 20), w = c.node()?.getBBox(), !w)
|
|
853
|
+
throw new Error("bbox not found");
|
|
854
|
+
E.debug("bounds after title", w);
|
|
855
|
+
}
|
|
856
|
+
const [H] = Bt(r.fontSize), V = (H ?? 16) * 2, F = (H ?? 16) * 0.5 + 20, K = c.append("g").attr("class", "lineWrapper");
|
|
857
|
+
K.append("line").attr("x1", I).attr("y1", d - V).attr("x2", I).attr("y2", w.y + w.height + F).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", "url(#arrowhead)"), K.lower(), ft(
|
|
858
|
+
void 0,
|
|
859
|
+
c,
|
|
860
|
+
r.timeline?.padding ?? 50,
|
|
861
|
+
r.timeline?.useMaxWidth ?? !1
|
|
862
|
+
);
|
|
863
|
+
}, "draw"), ut = /* @__PURE__ */ o(function(e, t, n, i, r, h, c, a, f) {
|
|
864
|
+
for (const g of t) {
|
|
865
|
+
const m = {
|
|
866
|
+
descr: g.task,
|
|
867
|
+
section: n,
|
|
868
|
+
number: n,
|
|
869
|
+
width: Q,
|
|
870
|
+
padding: z,
|
|
871
|
+
maxHeight: h
|
|
872
|
+
};
|
|
873
|
+
E.debug("taskNode", m);
|
|
874
|
+
const y = e.append("g").attr("class", "taskWrapper"), k = M.drawNode(y, m, n, c), s = k.height;
|
|
875
|
+
E.debug("taskHeight after draw", s);
|
|
876
|
+
const d = i - Mt - k.width;
|
|
877
|
+
if (y.attr("transform", `translate(${d}, ${r})`), h = Math.max(h, s), g.events && g.events.length > 0) {
|
|
878
|
+
const l = r, p = i + At;
|
|
879
|
+
ce(e, g.events, n, i, p, l, c);
|
|
880
|
+
}
|
|
881
|
+
r = r + a, f && !c.timeline?.disableMulticolor && n++;
|
|
882
|
+
}
|
|
883
|
+
}, "drawTasks"), ce = /* @__PURE__ */ o(function(e, t, n, i, r, h, c) {
|
|
884
|
+
let a = h;
|
|
885
|
+
for (const f of t) {
|
|
886
|
+
const g = {
|
|
887
|
+
descr: f,
|
|
888
|
+
section: n,
|
|
889
|
+
number: n,
|
|
890
|
+
width: at,
|
|
891
|
+
padding: z,
|
|
892
|
+
maxHeight: 0
|
|
893
|
+
};
|
|
894
|
+
E.debug("eventNode", g);
|
|
895
|
+
const m = e.append("g").attr("class", "eventWrapper"), k = M.drawNode(m, g, n, c).height;
|
|
896
|
+
m.attr("transform", `translate(${r}, ${a})`);
|
|
897
|
+
const s = e.append("g").attr("class", "lineWrapper"), d = a + k / 2;
|
|
898
|
+
s.append("line").attr("x1", i).attr("y1", d).attr("x2", r).attr("y2", d).attr("stroke-width", 2).attr("stroke", "black").attr("marker-end", "url(#arrowhead)").attr("stroke-dasharray", "5,5"), a = a + k + Lt;
|
|
899
|
+
}
|
|
900
|
+
return a - h;
|
|
901
|
+
}, "drawEvents"), le = {
|
|
902
|
+
setConf: /* @__PURE__ */ o(() => {
|
|
903
|
+
}, "setConf"),
|
|
904
|
+
draw: oe
|
|
905
|
+
}, he = /* @__PURE__ */ o((e) => {
|
|
906
|
+
const { theme: t } = pt(), n = t?.includes("dark"), i = t?.includes("color"), r = e.svgId?.replace(/^#/, "") ?? "", h = r ? `url(#${r}-drop-shadow)` : e.dropShadow ?? "none";
|
|
907
|
+
let c = "";
|
|
908
|
+
for (let a = 0; a < e.THEME_COLOR_LIMIT; a++) {
|
|
909
|
+
const f = `${17 - 3 * a}`, g = i ? e.borderColorArray[a] : e.mainBkg, m = i ? e.borderColorArray[a] : e.nodeBorder;
|
|
910
|
+
c += `
|
|
911
|
+
.section-${a - 1} rect,
|
|
912
|
+
.section-${a - 1} path,
|
|
913
|
+
.section-${a - 1} circle {
|
|
914
|
+
fill: ${n && i ? e.mainBkg : g};
|
|
915
|
+
stroke: ${m};
|
|
916
|
+
stroke-width: ${e.strokeWidth};
|
|
917
|
+
filter: ${h};
|
|
918
|
+
}
|
|
919
|
+
|
|
920
|
+
.section-${a - 1} text {
|
|
921
|
+
fill: ${e.nodeBorder};
|
|
922
|
+
font-weight: ${e.fontWeight}
|
|
923
|
+
}
|
|
924
|
+
|
|
925
|
+
.node-icon-${a - 1} {
|
|
926
|
+
font-size: 40px;
|
|
927
|
+
color: ${e["cScaleLabel" + a]};
|
|
928
|
+
}
|
|
929
|
+
|
|
930
|
+
.section-edge-${a - 1} {
|
|
931
|
+
stroke: ${e["cScale" + a]};
|
|
932
|
+
}
|
|
933
|
+
|
|
934
|
+
.edge-depth-${a - 1} {
|
|
935
|
+
stroke-width: ${f};
|
|
936
|
+
}
|
|
937
|
+
|
|
938
|
+
.section-${a - 1} line {
|
|
939
|
+
stroke: ${e["cScaleInv" + a]};
|
|
940
|
+
stroke-width: 3;
|
|
941
|
+
}
|
|
942
|
+
|
|
943
|
+
.lineWrapper line {
|
|
944
|
+
stroke: ${e.nodeBorder};
|
|
945
|
+
stroke-width:${e.strokeWidth}
|
|
946
|
+
}
|
|
947
|
+
|
|
948
|
+
.disabled,
|
|
949
|
+
.disabled circle,
|
|
950
|
+
.disabled text {
|
|
951
|
+
fill: ${e.tertiaryColor ?? "lightgray"};
|
|
952
|
+
}
|
|
953
|
+
|
|
954
|
+
.disabled text {
|
|
955
|
+
fill: ${e.clusterBorder ?? "#efefef"};
|
|
956
|
+
}
|
|
957
|
+
`;
|
|
958
|
+
}
|
|
959
|
+
return c;
|
|
960
|
+
}, "genReduxSections"), de = /* @__PURE__ */ o((e) => {
|
|
961
|
+
let t = "";
|
|
962
|
+
for (let n = 0; n < e.THEME_COLOR_LIMIT; n++)
|
|
963
|
+
e["lineColor" + n] = e["lineColor" + n] || e["cScaleInv" + n], Ct(e["lineColor" + n]) ? e["lineColor" + n] = Rt(e["lineColor" + n], 20) : e["lineColor" + n] = Wt(e["lineColor" + n], 20);
|
|
964
|
+
for (let n = 0; n < e.THEME_COLOR_LIMIT; n++) {
|
|
965
|
+
const i = "" + (17 - 3 * n);
|
|
966
|
+
t += `
|
|
967
|
+
.section-${n - 1} rect, .section-${n - 1} path, .section-${n - 1} circle, .section-${n - 1} path {
|
|
968
|
+
fill: ${e["cScale" + n]};
|
|
969
|
+
}
|
|
970
|
+
.section-${n - 1} text {
|
|
971
|
+
fill: ${e["cScaleLabel" + n]};
|
|
972
|
+
}
|
|
973
|
+
.node-icon-${n - 1} {
|
|
974
|
+
font-size: 40px;
|
|
975
|
+
color: ${e["cScaleLabel" + n]};
|
|
976
|
+
}
|
|
977
|
+
.section-edge-${n - 1}{
|
|
978
|
+
stroke: ${e["cScale" + n]};
|
|
979
|
+
}
|
|
980
|
+
.edge-depth-${n - 1}{
|
|
981
|
+
stroke-width: ${i};
|
|
982
|
+
}
|
|
983
|
+
.section-${n - 1} line {
|
|
984
|
+
stroke: ${e["cScaleInv" + n]} ;
|
|
985
|
+
stroke-width: 3;
|
|
986
|
+
}
|
|
987
|
+
|
|
988
|
+
.lineWrapper line{
|
|
989
|
+
stroke: ${e["cScaleLabel" + n]} ;
|
|
990
|
+
}
|
|
991
|
+
|
|
992
|
+
.disabled, .disabled circle, .disabled text {
|
|
993
|
+
fill: ${e.tertiaryColor ?? "lightgray"};
|
|
994
|
+
}
|
|
995
|
+
.disabled text {
|
|
996
|
+
fill: ${e.clusterBorder ?? "#efefef"};
|
|
997
|
+
}
|
|
998
|
+
`;
|
|
999
|
+
}
|
|
1000
|
+
return t;
|
|
1001
|
+
}, "genSections"), ue = /* @__PURE__ */ o((e) => {
|
|
1002
|
+
const { theme: t } = pt(), n = t?.includes("redux"), i = t === "neutral", r = e.svgId?.replace(/^#/, "") ?? "";
|
|
1003
|
+
let h = "";
|
|
1004
|
+
if (e.useGradient && r && e.THEME_COLOR_LIMIT && !i)
|
|
1005
|
+
for (let c = 0; c < e.THEME_COLOR_LIMIT; c++)
|
|
1006
|
+
h += `
|
|
1007
|
+
.section-${c - 1}[data-look="neo"] rect,
|
|
1008
|
+
.section-${c - 1}[data-look="neo"] path,
|
|
1009
|
+
.section-${c - 1}[data-look="neo"] circle {
|
|
1010
|
+
fill: ${e.mainBkg};
|
|
1011
|
+
stroke: url(#${r}-gradient);
|
|
1012
|
+
stroke-width: 2;
|
|
1013
|
+
}
|
|
1014
|
+
.section-${c - 1}[data-look="neo"] line {
|
|
1015
|
+
stroke: url(#${r}-gradient);
|
|
1016
|
+
stroke-width: 2;
|
|
1017
|
+
}`;
|
|
1018
|
+
return `
|
|
1019
|
+
.edge {
|
|
1020
|
+
stroke-width: 3;
|
|
1021
|
+
}
|
|
1022
|
+
${n ? he(e) : de(e)}
|
|
1023
|
+
${h}
|
|
1024
|
+
.section-root rect, .section-root path, .section-root circle {
|
|
1025
|
+
fill: ${e.git0};
|
|
1026
|
+
}
|
|
1027
|
+
.section-root text {
|
|
1028
|
+
fill: ${e.gitBranchLabel0};
|
|
1029
|
+
}
|
|
1030
|
+
.icon-container {
|
|
1031
|
+
height:100%;
|
|
1032
|
+
display: flex;
|
|
1033
|
+
justify-content: center;
|
|
1034
|
+
align-items: center;
|
|
1035
|
+
}
|
|
1036
|
+
.edge {
|
|
1037
|
+
fill: none;
|
|
1038
|
+
}
|
|
1039
|
+
.eventWrapper {
|
|
1040
|
+
filter: brightness(120%);
|
|
1041
|
+
}
|
|
1042
|
+
`;
|
|
1043
|
+
}, "getStyles"), pe = ue, ge = {
|
|
1044
|
+
setConf: /* @__PURE__ */ o(() => {
|
|
1045
|
+
}, "setConf"),
|
|
1046
|
+
draw: /* @__PURE__ */ o((e, t, n, i) => (i?.db?.getDirection?.() ?? "LR") === "TD" ? le.draw(e, t, n, i) : re.draw(e, t, n, i), "draw")
|
|
1047
|
+
}, me = {
|
|
1048
|
+
db: yt,
|
|
1049
|
+
renderer: ge,
|
|
1050
|
+
parser: Ot,
|
|
1051
|
+
styles: pe
|
|
1052
|
+
};
|
|
1053
|
+
export {
|
|
1054
|
+
me as diagram
|
|
1055
|
+
};
|