@readme/markdown 9.2.2 → 9.3.1

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 (127) hide show
  1. package/components/TutorialTile.tsx +46 -0
  2. package/components/index.ts +1 -0
  3. package/dist/10.node.js +20064 -19229
  4. package/dist/10.node.js.map +1 -1
  5. package/dist/122.node.js +23 -0
  6. package/dist/122.node.js.map +1 -0
  7. package/dist/{17.node.js → 135.node.js} +109 -110
  8. package/dist/135.node.js.map +1 -0
  9. package/dist/136.node.js +23 -0
  10. package/dist/136.node.js.map +1 -0
  11. package/dist/{52.node.js → 188.node.js} +211 -196
  12. package/dist/188.node.js.map +1 -0
  13. package/dist/214.node.js +1280 -0
  14. package/dist/214.node.js.map +1 -0
  15. package/dist/23.node.js +2563 -0
  16. package/dist/23.node.js.map +1 -0
  17. package/dist/{867.node.js → 311.node.js} +95 -95
  18. package/dist/{867.node.js.map → 311.node.js.map} +1 -1
  19. package/dist/{940.node.js → 339.node.js} +3 -75
  20. package/dist/339.node.js.map +1 -0
  21. package/dist/354.node.js +23 -0
  22. package/dist/354.node.js.map +1 -0
  23. package/dist/359.node.js +2001 -0
  24. package/dist/359.node.js.map +1 -0
  25. package/dist/364.node.js +4435 -0
  26. package/dist/364.node.js.map +1 -0
  27. package/dist/{429.node.js → 371.node.js} +196 -139
  28. package/dist/371.node.js.map +1 -0
  29. package/dist/{687.node.js → 38.node.js} +761 -761
  30. package/dist/38.node.js.map +1 -0
  31. package/dist/391.node.js +522 -0
  32. package/dist/391.node.js.map +1 -0
  33. package/dist/462.node.js +23 -0
  34. package/dist/462.node.js.map +1 -0
  35. package/dist/48.node.js +57 -0
  36. package/dist/48.node.js.map +1 -0
  37. package/dist/486.node.js +16267 -14851
  38. package/dist/486.node.js.map +1 -1
  39. package/dist/537.node.js +59 -0
  40. package/dist/537.node.js.map +1 -0
  41. package/dist/550.node.js +201 -1408
  42. package/dist/550.node.js.map +1 -1
  43. package/dist/{403.node.js → 572.node.js} +118 -118
  44. package/dist/572.node.js.map +1 -0
  45. package/dist/580.node.js +1324 -0
  46. package/dist/580.node.js.map +1 -0
  47. package/dist/{952.node.js → 649.node.js} +39 -39
  48. package/dist/{952.node.js.map → 649.node.js.map} +1 -1
  49. package/dist/740.node.js +23 -0
  50. package/dist/740.node.js.map +1 -0
  51. package/dist/741.node.js +23 -0
  52. package/dist/741.node.js.map +1 -0
  53. package/dist/779.node.js +57 -0
  54. package/dist/779.node.js.map +1 -0
  55. package/dist/805.node.js +1355 -0
  56. package/dist/805.node.js.map +1 -0
  57. package/dist/{246.node.js → 855.node.js} +671 -495
  58. package/dist/855.node.js.map +1 -0
  59. package/dist/{11.node.js → 870.node.js} +70 -63
  60. package/dist/870.node.js.map +1 -0
  61. package/dist/874.node.js +57 -0
  62. package/dist/874.node.js.map +1 -0
  63. package/dist/881.node.js +1344 -720
  64. package/dist/881.node.js.map +1 -1
  65. package/dist/{906.node.js → 890.node.js} +147 -147
  66. package/dist/{906.node.js.map → 890.node.js.map} +1 -1
  67. package/dist/898.node.js +361 -0
  68. package/dist/898.node.js.map +1 -0
  69. package/dist/{551.node.js → 912.node.js} +133 -133
  70. package/dist/{551.node.js.map → 912.node.js.map} +1 -1
  71. package/dist/{745.node.js → 915.node.js} +86 -85
  72. package/dist/915.node.js.map +1 -0
  73. package/dist/982.node.js +1132 -0
  74. package/dist/982.node.js.map +1 -0
  75. package/dist/995.node.js +189 -159
  76. package/dist/995.node.js.map +1 -1
  77. package/dist/components/TutorialTile.d.ts +3 -0
  78. package/dist/components/index.d.ts +1 -0
  79. package/dist/example/RenderError.d.ts +1 -1
  80. package/dist/lib/plain.d.ts +1 -1
  81. package/dist/main.js +1921 -332
  82. package/dist/main.node.js +1912 -333
  83. package/dist/main.node.js.map +1 -1
  84. package/package.json +1 -2
  85. package/dist/11.node.js.map +0 -1
  86. package/dist/120.node.js +0 -23
  87. package/dist/120.node.js.map +0 -1
  88. package/dist/134.node.js +0 -23
  89. package/dist/134.node.js.map +0 -1
  90. package/dist/150.node.js +0 -1892
  91. package/dist/150.node.js.map +0 -1
  92. package/dist/17.node.js.map +0 -1
  93. package/dist/246.node.js.map +0 -1
  94. package/dist/351.node.js +0 -2404
  95. package/dist/351.node.js.map +0 -1
  96. package/dist/366.node.js +0 -1185
  97. package/dist/366.node.js.map +0 -1
  98. package/dist/403.node.js.map +0 -1
  99. package/dist/429.node.js.map +0 -1
  100. package/dist/485.node.js +0 -518
  101. package/dist/485.node.js.map +0 -1
  102. package/dist/488.node.js +0 -59
  103. package/dist/488.node.js.map +0 -1
  104. package/dist/510.node.js +0 -250
  105. package/dist/510.node.js.map +0 -1
  106. package/dist/52.node.js.map +0 -1
  107. package/dist/617.node.js +0 -23
  108. package/dist/617.node.js.map +0 -1
  109. package/dist/687.node.js.map +0 -1
  110. package/dist/745.node.js.map +0 -1
  111. package/dist/775.node.js +0 -1904
  112. package/dist/775.node.js.map +0 -1
  113. package/dist/788.node.js +0 -1025
  114. package/dist/788.node.js.map +0 -1
  115. package/dist/81.node.js +0 -386
  116. package/dist/81.node.js.map +0 -1
  117. package/dist/849.node.js +0 -2590
  118. package/dist/849.node.js.map +0 -1
  119. package/dist/863.node.js +0 -23
  120. package/dist/863.node.js.map +0 -1
  121. package/dist/885.node.js +0 -52
  122. package/dist/885.node.js.map +0 -1
  123. package/dist/896.node.js +0 -1617
  124. package/dist/896.node.js.map +0 -1
  125. package/dist/91.node.js +0 -23
  126. package/dist/91.node.js.map +0 -1
  127. package/dist/940.node.js.map +0 -1
@@ -0,0 +1,1132 @@
1
+ "use strict";
2
+ exports.id = 982;
3
+ exports.ids = [982];
4
+ exports.modules = {
5
+
6
+ /***/ 4982:
7
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
8
+
9
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
10
+ /* harmony export */ diagram: () => (/* binding */ diagram)
11
+ /* harmony export */ });
12
+ /* harmony import */ var _chunk_6JRP7KZX_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7366);
13
+ /* harmony import */ var _chunk_HRU6DDCH_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(778);
14
+ /* harmony import */ var _chunk_K557N5IZ_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7590);
15
+ /* harmony import */ var _chunk_H2D2JQ3I_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4059);
16
+ /* harmony import */ var _chunk_C3MQ5ANM_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6499);
17
+ /* harmony import */ var _chunk_O4NI6UNU_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8430);
18
+ /* harmony import */ var _chunk_7B677QYD_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3113);
19
+ /* harmony import */ var _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(3804);
20
+ /* harmony import */ var khroma__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(5099);
21
+ /* harmony import */ var khroma__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(7470);
22
+ /* harmony import */ var khroma__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(8750);
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+ // src/diagrams/kanban/parser/kanban.jison
33
+ var parser = function() {
34
+ var o = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function(k, v, o2, l) {
35
+ for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v) ;
36
+ return o2;
37
+ }, "o"), $V0 = [1, 4], $V1 = [1, 13], $V2 = [1, 12], $V3 = [1, 15], $V4 = [1, 16], $V5 = [1, 20], $V6 = [1, 19], $V7 = [6, 7, 8], $V8 = [1, 26], $V9 = [1, 24], $Va = [1, 25], $Vb = [6, 7, 11], $Vc = [1, 31], $Vd = [6, 7, 11, 24], $Ve = [1, 6, 13, 16, 17, 20, 23], $Vf = [1, 35], $Vg = [1, 36], $Vh = [1, 6, 7, 11, 13, 16, 17, 20, 23], $Vi = [1, 38];
38
+ var parser2 = {
39
+ trace: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function trace() {
40
+ }, "trace"),
41
+ yy: {},
42
+ symbols_: { "error": 2, "start": 3, "mindMap": 4, "spaceLines": 5, "SPACELINE": 6, "NL": 7, "KANBAN": 8, "document": 9, "stop": 10, "EOF": 11, "statement": 12, "SPACELIST": 13, "node": 14, "shapeData": 15, "ICON": 16, "CLASS": 17, "nodeWithId": 18, "nodeWithoutId": 19, "NODE_DSTART": 20, "NODE_DESCR": 21, "NODE_DEND": 22, "NODE_ID": 23, "SHAPE_DATA": 24, "$accept": 0, "$end": 1 },
43
+ terminals_: { 2: "error", 6: "SPACELINE", 7: "NL", 8: "KANBAN", 11: "EOF", 13: "SPACELIST", 16: "ICON", 17: "CLASS", 20: "NODE_DSTART", 21: "NODE_DESCR", 22: "NODE_DEND", 23: "NODE_ID", 24: "SHAPE_DATA" },
44
+ productions_: [0, [3, 1], [3, 2], [5, 1], [5, 2], [5, 2], [4, 2], [4, 3], [10, 1], [10, 1], [10, 1], [10, 2], [10, 2], [9, 3], [9, 2], [12, 3], [12, 2], [12, 2], [12, 2], [12, 1], [12, 2], [12, 1], [12, 1], [12, 1], [12, 1], [14, 1], [14, 1], [19, 3], [18, 1], [18, 4], [15, 2], [15, 1]],
45
+ performAction: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {
46
+ var $0 = $$.length - 1;
47
+ switch (yystate) {
48
+ case 6:
49
+ case 7:
50
+ return yy;
51
+ break;
52
+ case 8:
53
+ yy.getLogger().trace("Stop NL ");
54
+ break;
55
+ case 9:
56
+ yy.getLogger().trace("Stop EOF ");
57
+ break;
58
+ case 11:
59
+ yy.getLogger().trace("Stop NL2 ");
60
+ break;
61
+ case 12:
62
+ yy.getLogger().trace("Stop EOF2 ");
63
+ break;
64
+ case 15:
65
+ yy.getLogger().info("Node: ", $$[$0 - 1].id);
66
+ yy.addNode($$[$0 - 2].length, $$[$0 - 1].id, $$[$0 - 1].descr, $$[$0 - 1].type, $$[$0]);
67
+ break;
68
+ case 16:
69
+ yy.getLogger().info("Node: ", $$[$0].id);
70
+ yy.addNode($$[$0 - 1].length, $$[$0].id, $$[$0].descr, $$[$0].type);
71
+ break;
72
+ case 17:
73
+ yy.getLogger().trace("Icon: ", $$[$0]);
74
+ yy.decorateNode({ icon: $$[$0] });
75
+ break;
76
+ case 18:
77
+ case 23:
78
+ yy.decorateNode({ class: $$[$0] });
79
+ break;
80
+ case 19:
81
+ yy.getLogger().trace("SPACELIST");
82
+ break;
83
+ case 20:
84
+ yy.getLogger().trace("Node: ", $$[$0 - 1].id);
85
+ yy.addNode(0, $$[$0 - 1].id, $$[$0 - 1].descr, $$[$0 - 1].type, $$[$0]);
86
+ break;
87
+ case 21:
88
+ yy.getLogger().trace("Node: ", $$[$0].id);
89
+ yy.addNode(0, $$[$0].id, $$[$0].descr, $$[$0].type);
90
+ break;
91
+ case 22:
92
+ yy.decorateNode({ icon: $$[$0] });
93
+ break;
94
+ case 27:
95
+ yy.getLogger().trace("node found ..", $$[$0 - 2]);
96
+ this.$ = { id: $$[$0 - 1], descr: $$[$0 - 1], type: yy.getType($$[$0 - 2], $$[$0]) };
97
+ break;
98
+ case 28:
99
+ this.$ = { id: $$[$0], descr: $$[$0], type: 0 };
100
+ break;
101
+ case 29:
102
+ yy.getLogger().trace("node found ..", $$[$0 - 3]);
103
+ this.$ = { id: $$[$0 - 3], descr: $$[$0 - 1], type: yy.getType($$[$0 - 2], $$[$0]) };
104
+ break;
105
+ case 30:
106
+ this.$ = $$[$0 - 1] + $$[$0];
107
+ break;
108
+ case 31:
109
+ this.$ = $$[$0];
110
+ break;
111
+ }
112
+ }, "anonymous"),
113
+ table: [{ 3: 1, 4: 2, 5: 3, 6: [1, 5], 8: $V0 }, { 1: [3] }, { 1: [2, 1] }, { 4: 6, 6: [1, 7], 7: [1, 8], 8: $V0 }, { 6: $V1, 7: [1, 10], 9: 9, 12: 11, 13: $V2, 14: 14, 16: $V3, 17: $V4, 18: 17, 19: 18, 20: $V5, 23: $V6 }, o($V7, [2, 3]), { 1: [2, 2] }, o($V7, [2, 4]), o($V7, [2, 5]), { 1: [2, 6], 6: $V1, 12: 21, 13: $V2, 14: 14, 16: $V3, 17: $V4, 18: 17, 19: 18, 20: $V5, 23: $V6 }, { 6: $V1, 9: 22, 12: 11, 13: $V2, 14: 14, 16: $V3, 17: $V4, 18: 17, 19: 18, 20: $V5, 23: $V6 }, { 6: $V8, 7: $V9, 10: 23, 11: $Va }, o($Vb, [2, 24], { 18: 17, 19: 18, 14: 27, 16: [1, 28], 17: [1, 29], 20: $V5, 23: $V6 }), o($Vb, [2, 19]), o($Vb, [2, 21], { 15: 30, 24: $Vc }), o($Vb, [2, 22]), o($Vb, [2, 23]), o($Vd, [2, 25]), o($Vd, [2, 26]), o($Vd, [2, 28], { 20: [1, 32] }), { 21: [1, 33] }, { 6: $V8, 7: $V9, 10: 34, 11: $Va }, { 1: [2, 7], 6: $V1, 12: 21, 13: $V2, 14: 14, 16: $V3, 17: $V4, 18: 17, 19: 18, 20: $V5, 23: $V6 }, o($Ve, [2, 14], { 7: $Vf, 11: $Vg }), o($Vh, [2, 8]), o($Vh, [2, 9]), o($Vh, [2, 10]), o($Vb, [2, 16], { 15: 37, 24: $Vc }), o($Vb, [2, 17]), o($Vb, [2, 18]), o($Vb, [2, 20], { 24: $Vi }), o($Vd, [2, 31]), { 21: [1, 39] }, { 22: [1, 40] }, o($Ve, [2, 13], { 7: $Vf, 11: $Vg }), o($Vh, [2, 11]), o($Vh, [2, 12]), o($Vb, [2, 15], { 24: $Vi }), o($Vd, [2, 30]), { 22: [1, 41] }, o($Vd, [2, 27]), o($Vd, [2, 29])],
114
+ defaultActions: { 2: [2, 1], 6: [2, 2] },
115
+ parseError: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function parseError(str, hash) {
116
+ if (hash.recoverable) {
117
+ this.trace(str);
118
+ } else {
119
+ var error = new Error(str);
120
+ error.hash = hash;
121
+ throw error;
122
+ }
123
+ }, "parseError"),
124
+ parse: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function parse(input) {
125
+ var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = "", yylineno = 0, yyleng = 0, recovering = 0, TERROR = 2, EOF = 1;
126
+ var args = lstack.slice.call(arguments, 1);
127
+ var lexer2 = Object.create(this.lexer);
128
+ var sharedState = { yy: {} };
129
+ for (var k in this.yy) {
130
+ if (Object.prototype.hasOwnProperty.call(this.yy, k)) {
131
+ sharedState.yy[k] = this.yy[k];
132
+ }
133
+ }
134
+ lexer2.setInput(input, sharedState.yy);
135
+ sharedState.yy.lexer = lexer2;
136
+ sharedState.yy.parser = this;
137
+ if (typeof lexer2.yylloc == "undefined") {
138
+ lexer2.yylloc = {};
139
+ }
140
+ var yyloc = lexer2.yylloc;
141
+ lstack.push(yyloc);
142
+ var ranges = lexer2.options && lexer2.options.ranges;
143
+ if (typeof sharedState.yy.parseError === "function") {
144
+ this.parseError = sharedState.yy.parseError;
145
+ } else {
146
+ this.parseError = Object.getPrototypeOf(this).parseError;
147
+ }
148
+ function popStack(n) {
149
+ stack.length = stack.length - 2 * n;
150
+ vstack.length = vstack.length - n;
151
+ lstack.length = lstack.length - n;
152
+ }
153
+ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(popStack, "popStack");
154
+ function lex() {
155
+ var token;
156
+ token = tstack.pop() || lexer2.lex() || EOF;
157
+ if (typeof token !== "number") {
158
+ if (token instanceof Array) {
159
+ tstack = token;
160
+ token = tstack.pop();
161
+ }
162
+ token = self.symbols_[token] || token;
163
+ }
164
+ return token;
165
+ }
166
+ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(lex, "lex");
167
+ var symbol, preErrorSymbol, state, action, a, r, yyval = {}, p, len, newState, expected;
168
+ while (true) {
169
+ state = stack[stack.length - 1];
170
+ if (this.defaultActions[state]) {
171
+ action = this.defaultActions[state];
172
+ } else {
173
+ if (symbol === null || typeof symbol == "undefined") {
174
+ symbol = lex();
175
+ }
176
+ action = table[state] && table[state][symbol];
177
+ }
178
+ if (typeof action === "undefined" || !action.length || !action[0]) {
179
+ var errStr = "";
180
+ expected = [];
181
+ for (p in table[state]) {
182
+ if (this.terminals_[p] && p > TERROR) {
183
+ expected.push("'" + this.terminals_[p] + "'");
184
+ }
185
+ }
186
+ if (lexer2.showPosition) {
187
+ errStr = "Parse error on line " + (yylineno + 1) + ":\n" + lexer2.showPosition() + "\nExpecting " + expected.join(", ") + ", got '" + (this.terminals_[symbol] || symbol) + "'";
188
+ } else {
189
+ errStr = "Parse error on line " + (yylineno + 1) + ": Unexpected " + (symbol == EOF ? "end of input" : "'" + (this.terminals_[symbol] || symbol) + "'");
190
+ }
191
+ this.parseError(errStr, {
192
+ text: lexer2.match,
193
+ token: this.terminals_[symbol] || symbol,
194
+ line: lexer2.yylineno,
195
+ loc: yyloc,
196
+ expected
197
+ });
198
+ }
199
+ if (action[0] instanceof Array && action.length > 1) {
200
+ throw new Error("Parse Error: multiple actions possible at state: " + state + ", token: " + symbol);
201
+ }
202
+ switch (action[0]) {
203
+ case 1:
204
+ stack.push(symbol);
205
+ vstack.push(lexer2.yytext);
206
+ lstack.push(lexer2.yylloc);
207
+ stack.push(action[1]);
208
+ symbol = null;
209
+ if (!preErrorSymbol) {
210
+ yyleng = lexer2.yyleng;
211
+ yytext = lexer2.yytext;
212
+ yylineno = lexer2.yylineno;
213
+ yyloc = lexer2.yylloc;
214
+ if (recovering > 0) {
215
+ recovering--;
216
+ }
217
+ } else {
218
+ symbol = preErrorSymbol;
219
+ preErrorSymbol = null;
220
+ }
221
+ break;
222
+ case 2:
223
+ len = this.productions_[action[1]][1];
224
+ yyval.$ = vstack[vstack.length - len];
225
+ yyval._$ = {
226
+ first_line: lstack[lstack.length - (len || 1)].first_line,
227
+ last_line: lstack[lstack.length - 1].last_line,
228
+ first_column: lstack[lstack.length - (len || 1)].first_column,
229
+ last_column: lstack[lstack.length - 1].last_column
230
+ };
231
+ if (ranges) {
232
+ yyval._$.range = [
233
+ lstack[lstack.length - (len || 1)].range[0],
234
+ lstack[lstack.length - 1].range[1]
235
+ ];
236
+ }
237
+ r = this.performAction.apply(yyval, [
238
+ yytext,
239
+ yyleng,
240
+ yylineno,
241
+ sharedState.yy,
242
+ action[1],
243
+ vstack,
244
+ lstack
245
+ ].concat(args));
246
+ if (typeof r !== "undefined") {
247
+ return r;
248
+ }
249
+ if (len) {
250
+ stack = stack.slice(0, -1 * len * 2);
251
+ vstack = vstack.slice(0, -1 * len);
252
+ lstack = lstack.slice(0, -1 * len);
253
+ }
254
+ stack.push(this.productions_[action[1]][0]);
255
+ vstack.push(yyval.$);
256
+ lstack.push(yyval._$);
257
+ newState = table[stack[stack.length - 2]][stack[stack.length - 1]];
258
+ stack.push(newState);
259
+ break;
260
+ case 3:
261
+ return true;
262
+ }
263
+ }
264
+ return true;
265
+ }, "parse")
266
+ };
267
+ var lexer = /* @__PURE__ */ function() {
268
+ var lexer2 = {
269
+ EOF: 1,
270
+ parseError: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function parseError(str, hash) {
271
+ if (this.yy.parser) {
272
+ this.yy.parser.parseError(str, hash);
273
+ } else {
274
+ throw new Error(str);
275
+ }
276
+ }, "parseError"),
277
+ // resets the lexer, sets new input
278
+ setInput: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function(input, yy) {
279
+ this.yy = yy || this.yy || {};
280
+ this._input = input;
281
+ this._more = this._backtrack = this.done = false;
282
+ this.yylineno = this.yyleng = 0;
283
+ this.yytext = this.matched = this.match = "";
284
+ this.conditionStack = ["INITIAL"];
285
+ this.yylloc = {
286
+ first_line: 1,
287
+ first_column: 0,
288
+ last_line: 1,
289
+ last_column: 0
290
+ };
291
+ if (this.options.ranges) {
292
+ this.yylloc.range = [0, 0];
293
+ }
294
+ this.offset = 0;
295
+ return this;
296
+ }, "setInput"),
297
+ // consumes and returns one char from the input
298
+ input: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
299
+ var ch = this._input[0];
300
+ this.yytext += ch;
301
+ this.yyleng++;
302
+ this.offset++;
303
+ this.match += ch;
304
+ this.matched += ch;
305
+ var lines = ch.match(/(?:\r\n?|\n).*/g);
306
+ if (lines) {
307
+ this.yylineno++;
308
+ this.yylloc.last_line++;
309
+ } else {
310
+ this.yylloc.last_column++;
311
+ }
312
+ if (this.options.ranges) {
313
+ this.yylloc.range[1]++;
314
+ }
315
+ this._input = this._input.slice(1);
316
+ return ch;
317
+ }, "input"),
318
+ // unshifts one char (or a string) into the input
319
+ unput: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function(ch) {
320
+ var len = ch.length;
321
+ var lines = ch.split(/(?:\r\n?|\n)/g);
322
+ this._input = ch + this._input;
323
+ this.yytext = this.yytext.substr(0, this.yytext.length - len);
324
+ this.offset -= len;
325
+ var oldLines = this.match.split(/(?:\r\n?|\n)/g);
326
+ this.match = this.match.substr(0, this.match.length - 1);
327
+ this.matched = this.matched.substr(0, this.matched.length - 1);
328
+ if (lines.length - 1) {
329
+ this.yylineno -= lines.length - 1;
330
+ }
331
+ var r = this.yylloc.range;
332
+ this.yylloc = {
333
+ first_line: this.yylloc.first_line,
334
+ last_line: this.yylineno + 1,
335
+ first_column: this.yylloc.first_column,
336
+ last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len
337
+ };
338
+ if (this.options.ranges) {
339
+ this.yylloc.range = [r[0], r[0] + this.yyleng - len];
340
+ }
341
+ this.yyleng = this.yytext.length;
342
+ return this;
343
+ }, "unput"),
344
+ // When called from action, caches matched text and appends it on next action
345
+ more: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
346
+ this._more = true;
347
+ return this;
348
+ }, "more"),
349
+ // 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.
350
+ reject: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
351
+ if (this.options.backtrack_lexer) {
352
+ this._backtrack = true;
353
+ } else {
354
+ 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).\n" + this.showPosition(), {
355
+ text: "",
356
+ token: null,
357
+ line: this.yylineno
358
+ });
359
+ }
360
+ return this;
361
+ }, "reject"),
362
+ // retain first n characters of the match
363
+ less: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function(n) {
364
+ this.unput(this.match.slice(n));
365
+ }, "less"),
366
+ // displays already matched input, i.e. for error messages
367
+ pastInput: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
368
+ var past = this.matched.substr(0, this.matched.length - this.match.length);
369
+ return (past.length > 20 ? "..." : "") + past.substr(-20).replace(/\n/g, "");
370
+ }, "pastInput"),
371
+ // displays upcoming input, i.e. for error messages
372
+ upcomingInput: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
373
+ var next = this.match;
374
+ if (next.length < 20) {
375
+ next += this._input.substr(0, 20 - next.length);
376
+ }
377
+ return (next.substr(0, 20) + (next.length > 20 ? "..." : "")).replace(/\n/g, "");
378
+ }, "upcomingInput"),
379
+ // displays the character position where the lexing error occurred, i.e. for error messages
380
+ showPosition: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
381
+ var pre = this.pastInput();
382
+ var c = new Array(pre.length + 1).join("-");
383
+ return pre + this.upcomingInput() + "\n" + c + "^";
384
+ }, "showPosition"),
385
+ // test the lexed token: return FALSE when not a match, otherwise return token
386
+ test_match: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function(match, indexed_rule) {
387
+ var token, lines, backup;
388
+ if (this.options.backtrack_lexer) {
389
+ backup = {
390
+ yylineno: this.yylineno,
391
+ yylloc: {
392
+ first_line: this.yylloc.first_line,
393
+ last_line: this.last_line,
394
+ first_column: this.yylloc.first_column,
395
+ last_column: this.yylloc.last_column
396
+ },
397
+ yytext: this.yytext,
398
+ match: this.match,
399
+ matches: this.matches,
400
+ matched: this.matched,
401
+ yyleng: this.yyleng,
402
+ offset: this.offset,
403
+ _more: this._more,
404
+ _input: this._input,
405
+ yy: this.yy,
406
+ conditionStack: this.conditionStack.slice(0),
407
+ done: this.done
408
+ };
409
+ if (this.options.ranges) {
410
+ backup.yylloc.range = this.yylloc.range.slice(0);
411
+ }
412
+ }
413
+ lines = match[0].match(/(?:\r\n?|\n).*/g);
414
+ if (lines) {
415
+ this.yylineno += lines.length;
416
+ }
417
+ this.yylloc = {
418
+ first_line: this.yylloc.last_line,
419
+ last_line: this.yylineno + 1,
420
+ first_column: this.yylloc.last_column,
421
+ last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + match[0].length
422
+ };
423
+ this.yytext += match[0];
424
+ this.match += match[0];
425
+ this.matches = match;
426
+ this.yyleng = this.yytext.length;
427
+ if (this.options.ranges) {
428
+ this.yylloc.range = [this.offset, this.offset += this.yyleng];
429
+ }
430
+ this._more = false;
431
+ this._backtrack = false;
432
+ this._input = this._input.slice(match[0].length);
433
+ this.matched += match[0];
434
+ token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);
435
+ if (this.done && this._input) {
436
+ this.done = false;
437
+ }
438
+ if (token) {
439
+ return token;
440
+ } else if (this._backtrack) {
441
+ for (var k in backup) {
442
+ this[k] = backup[k];
443
+ }
444
+ return false;
445
+ }
446
+ return false;
447
+ }, "test_match"),
448
+ // return next match in input
449
+ next: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
450
+ if (this.done) {
451
+ return this.EOF;
452
+ }
453
+ if (!this._input) {
454
+ this.done = true;
455
+ }
456
+ var token, match, tempMatch, index;
457
+ if (!this._more) {
458
+ this.yytext = "";
459
+ this.match = "";
460
+ }
461
+ var rules = this._currentRules();
462
+ for (var i = 0; i < rules.length; i++) {
463
+ tempMatch = this._input.match(this.rules[rules[i]]);
464
+ if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {
465
+ match = tempMatch;
466
+ index = i;
467
+ if (this.options.backtrack_lexer) {
468
+ token = this.test_match(tempMatch, rules[i]);
469
+ if (token !== false) {
470
+ return token;
471
+ } else if (this._backtrack) {
472
+ match = false;
473
+ continue;
474
+ } else {
475
+ return false;
476
+ }
477
+ } else if (!this.options.flex) {
478
+ break;
479
+ }
480
+ }
481
+ }
482
+ if (match) {
483
+ token = this.test_match(match, rules[index]);
484
+ if (token !== false) {
485
+ return token;
486
+ }
487
+ return false;
488
+ }
489
+ if (this._input === "") {
490
+ return this.EOF;
491
+ } else {
492
+ return this.parseError("Lexical error on line " + (this.yylineno + 1) + ". Unrecognized text.\n" + this.showPosition(), {
493
+ text: "",
494
+ token: null,
495
+ line: this.yylineno
496
+ });
497
+ }
498
+ }, "next"),
499
+ // return next match that has a token
500
+ lex: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function lex() {
501
+ var r = this.next();
502
+ if (r) {
503
+ return r;
504
+ } else {
505
+ return this.lex();
506
+ }
507
+ }, "lex"),
508
+ // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
509
+ begin: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function begin(condition) {
510
+ this.conditionStack.push(condition);
511
+ }, "begin"),
512
+ // pop the previously active lexer condition state off the condition stack
513
+ popState: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function popState() {
514
+ var n = this.conditionStack.length - 1;
515
+ if (n > 0) {
516
+ return this.conditionStack.pop();
517
+ } else {
518
+ return this.conditionStack[0];
519
+ }
520
+ }, "popState"),
521
+ // produce the lexer rule set which is active for the currently active lexer condition state
522
+ _currentRules: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function _currentRules() {
523
+ if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {
524
+ return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;
525
+ } else {
526
+ return this.conditions["INITIAL"].rules;
527
+ }
528
+ }, "_currentRules"),
529
+ // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
530
+ topState: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function topState(n) {
531
+ n = this.conditionStack.length - 1 - Math.abs(n || 0);
532
+ if (n >= 0) {
533
+ return this.conditionStack[n];
534
+ } else {
535
+ return "INITIAL";
536
+ }
537
+ }, "topState"),
538
+ // alias for begin(condition)
539
+ pushState: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function pushState(condition) {
540
+ this.begin(condition);
541
+ }, "pushState"),
542
+ // return the number of states currently on the stack
543
+ stateStackSize: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function stateStackSize() {
544
+ return this.conditionStack.length;
545
+ }, "stateStackSize"),
546
+ options: { "case-insensitive": true },
547
+ performAction: /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {
548
+ var YYSTATE = YY_START;
549
+ switch ($avoiding_name_collisions) {
550
+ case 0:
551
+ this.pushState("shapeData");
552
+ yy_.yytext = "";
553
+ return 24;
554
+ break;
555
+ case 1:
556
+ this.pushState("shapeDataStr");
557
+ return 24;
558
+ break;
559
+ case 2:
560
+ this.popState();
561
+ return 24;
562
+ break;
563
+ case 3:
564
+ const re = /\n\s*/g;
565
+ yy_.yytext = yy_.yytext.replace(re, "<br/>");
566
+ return 24;
567
+ break;
568
+ case 4:
569
+ return 24;
570
+ break;
571
+ case 5:
572
+ this.popState();
573
+ break;
574
+ case 6:
575
+ yy.getLogger().trace("Found comment", yy_.yytext);
576
+ return 6;
577
+ break;
578
+ case 7:
579
+ return 8;
580
+ break;
581
+ case 8:
582
+ this.begin("CLASS");
583
+ break;
584
+ case 9:
585
+ this.popState();
586
+ return 17;
587
+ break;
588
+ case 10:
589
+ this.popState();
590
+ break;
591
+ case 11:
592
+ yy.getLogger().trace("Begin icon");
593
+ this.begin("ICON");
594
+ break;
595
+ case 12:
596
+ yy.getLogger().trace("SPACELINE");
597
+ return 6;
598
+ break;
599
+ case 13:
600
+ return 7;
601
+ break;
602
+ case 14:
603
+ return 16;
604
+ break;
605
+ case 15:
606
+ yy.getLogger().trace("end icon");
607
+ this.popState();
608
+ break;
609
+ case 16:
610
+ yy.getLogger().trace("Exploding node");
611
+ this.begin("NODE");
612
+ return 20;
613
+ break;
614
+ case 17:
615
+ yy.getLogger().trace("Cloud");
616
+ this.begin("NODE");
617
+ return 20;
618
+ break;
619
+ case 18:
620
+ yy.getLogger().trace("Explosion Bang");
621
+ this.begin("NODE");
622
+ return 20;
623
+ break;
624
+ case 19:
625
+ yy.getLogger().trace("Cloud Bang");
626
+ this.begin("NODE");
627
+ return 20;
628
+ break;
629
+ case 20:
630
+ this.begin("NODE");
631
+ return 20;
632
+ break;
633
+ case 21:
634
+ this.begin("NODE");
635
+ return 20;
636
+ break;
637
+ case 22:
638
+ this.begin("NODE");
639
+ return 20;
640
+ break;
641
+ case 23:
642
+ this.begin("NODE");
643
+ return 20;
644
+ break;
645
+ case 24:
646
+ return 13;
647
+ break;
648
+ case 25:
649
+ return 23;
650
+ break;
651
+ case 26:
652
+ return 11;
653
+ break;
654
+ case 27:
655
+ this.begin("NSTR2");
656
+ break;
657
+ case 28:
658
+ return "NODE_DESCR";
659
+ break;
660
+ case 29:
661
+ this.popState();
662
+ break;
663
+ case 30:
664
+ yy.getLogger().trace("Starting NSTR");
665
+ this.begin("NSTR");
666
+ break;
667
+ case 31:
668
+ yy.getLogger().trace("description:", yy_.yytext);
669
+ return "NODE_DESCR";
670
+ break;
671
+ case 32:
672
+ this.popState();
673
+ break;
674
+ case 33:
675
+ this.popState();
676
+ yy.getLogger().trace("node end ))");
677
+ return "NODE_DEND";
678
+ break;
679
+ case 34:
680
+ this.popState();
681
+ yy.getLogger().trace("node end )");
682
+ return "NODE_DEND";
683
+ break;
684
+ case 35:
685
+ this.popState();
686
+ yy.getLogger().trace("node end ...", yy_.yytext);
687
+ return "NODE_DEND";
688
+ break;
689
+ case 36:
690
+ this.popState();
691
+ yy.getLogger().trace("node end ((");
692
+ return "NODE_DEND";
693
+ break;
694
+ case 37:
695
+ this.popState();
696
+ yy.getLogger().trace("node end (-");
697
+ return "NODE_DEND";
698
+ break;
699
+ case 38:
700
+ this.popState();
701
+ yy.getLogger().trace("node end (-");
702
+ return "NODE_DEND";
703
+ break;
704
+ case 39:
705
+ this.popState();
706
+ yy.getLogger().trace("node end ((");
707
+ return "NODE_DEND";
708
+ break;
709
+ case 40:
710
+ this.popState();
711
+ yy.getLogger().trace("node end ((");
712
+ return "NODE_DEND";
713
+ break;
714
+ case 41:
715
+ yy.getLogger().trace("Long description:", yy_.yytext);
716
+ return 21;
717
+ break;
718
+ case 42:
719
+ yy.getLogger().trace("Long description:", yy_.yytext);
720
+ return 21;
721
+ break;
722
+ }
723
+ }, "anonymous"),
724
+ rules: [/^(?:@\{)/i, /^(?:["])/i, /^(?:["])/i, /^(?:[^\"]+)/i, /^(?:[^}^"]+)/i, /^(?:\})/i, /^(?:\s*%%.*)/i, /^(?:kanban\b)/i, /^(?::::)/i, /^(?:.+)/i, /^(?:\n)/i, /^(?:::icon\()/i, /^(?:[\s]+[\n])/i, /^(?:[\n]+)/i, /^(?:[^\)]+)/i, /^(?:\))/i, /^(?:-\))/i, /^(?:\(-)/i, /^(?:\)\))/i, /^(?:\))/i, /^(?:\(\()/i, /^(?:\{\{)/i, /^(?:\()/i, /^(?:\[)/i, /^(?:[\s]+)/i, /^(?:[^\(\[\n\)\{\}@]+)/i, /^(?:$)/i, /^(?:["][`])/i, /^(?:[^`"]+)/i, /^(?:[`]["])/i, /^(?:["])/i, /^(?:[^"]+)/i, /^(?:["])/i, /^(?:[\)]\))/i, /^(?:[\)])/i, /^(?:[\]])/i, /^(?:\}\})/i, /^(?:\(-)/i, /^(?:-\))/i, /^(?:\(\()/i, /^(?:\()/i, /^(?:[^\)\]\(\}]+)/i, /^(?:.+(?!\(\())/i],
725
+ conditions: { "shapeDataEndBracket": { "rules": [], "inclusive": false }, "shapeDataStr": { "rules": [2, 3], "inclusive": false }, "shapeData": { "rules": [1, 4, 5], "inclusive": false }, "CLASS": { "rules": [9, 10], "inclusive": false }, "ICON": { "rules": [14, 15], "inclusive": false }, "NSTR2": { "rules": [28, 29], "inclusive": false }, "NSTR": { "rules": [31, 32], "inclusive": false }, "NODE": { "rules": [27, 30, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42], "inclusive": false }, "INITIAL": { "rules": [0, 6, 7, 8, 11, 12, 13, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26], "inclusive": true } }
726
+ };
727
+ return lexer2;
728
+ }();
729
+ parser2.lexer = lexer;
730
+ function Parser() {
731
+ this.yy = {};
732
+ }
733
+ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(Parser, "Parser");
734
+ Parser.prototype = parser2;
735
+ parser2.Parser = Parser;
736
+ return new Parser();
737
+ }();
738
+ parser.parser = parser;
739
+ var kanban_default = parser;
740
+
741
+ // src/diagrams/kanban/kanbanDb.ts
742
+ var nodes = [];
743
+ var sections = [];
744
+ var cnt = 0;
745
+ var elements = {};
746
+ var clear = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(() => {
747
+ nodes = [];
748
+ sections = [];
749
+ cnt = 0;
750
+ elements = {};
751
+ }, "clear");
752
+ var getSection = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((level) => {
753
+ if (nodes.length === 0) {
754
+ return null;
755
+ }
756
+ const sectionLevel = nodes[0].level;
757
+ let lastSection = null;
758
+ for (let i = nodes.length - 1; i >= 0; i--) {
759
+ if (nodes[i].level === sectionLevel && !lastSection) {
760
+ lastSection = nodes[i];
761
+ }
762
+ if (nodes[i].level < sectionLevel) {
763
+ throw new Error('Items without section detected, found section ("' + nodes[i].label + '")');
764
+ }
765
+ }
766
+ if (level === lastSection?.level) {
767
+ return null;
768
+ }
769
+ return lastSection;
770
+ }, "getSection");
771
+ var getSections = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
772
+ return sections;
773
+ }, "getSections");
774
+ var getData = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(function() {
775
+ const edges = [];
776
+ const _nodes = [];
777
+ const sections2 = getSections();
778
+ const conf = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .getConfig2 */ .D7)();
779
+ for (const section of sections2) {
780
+ const node = {
781
+ id: section.id,
782
+ label: (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(section.label ?? "", conf),
783
+ isGroup: true,
784
+ ticket: section.ticket,
785
+ shape: "kanbanSection",
786
+ level: section.level,
787
+ look: conf.look
788
+ };
789
+ _nodes.push(node);
790
+ const children = nodes.filter((n) => n.parentId === section.id);
791
+ for (const item of children) {
792
+ const childNode = {
793
+ id: item.id,
794
+ parentId: section.id,
795
+ label: (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(item.label ?? "", conf),
796
+ isGroup: false,
797
+ ticket: item?.ticket,
798
+ priority: item?.priority,
799
+ assigned: item?.assigned,
800
+ icon: item?.icon,
801
+ shape: "kanbanItem",
802
+ level: item.level,
803
+ rx: 5,
804
+ ry: 5,
805
+ cssStyles: ["text-align: left"]
806
+ };
807
+ _nodes.push(childNode);
808
+ }
809
+ }
810
+ return { nodes: _nodes, edges, other: {}, config: (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .getConfig2 */ .D7)() };
811
+ }, "getData");
812
+ var addNode = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((level, id, descr, type, shapeData) => {
813
+ const conf = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .getConfig2 */ .D7)();
814
+ let padding = conf.mindmap?.padding ?? _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .defaultConfig_default */ .UI.mindmap.padding;
815
+ switch (type) {
816
+ case nodeType.ROUNDED_RECT:
817
+ case nodeType.RECT:
818
+ case nodeType.HEXAGON:
819
+ padding *= 2;
820
+ }
821
+ const node = {
822
+ id: (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(id, conf) || "kbn" + cnt++,
823
+ level,
824
+ label: (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(descr, conf),
825
+ width: conf.mindmap?.maxNodeWidth ?? _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .defaultConfig_default */ .UI.mindmap.maxNodeWidth,
826
+ padding,
827
+ isGroup: false
828
+ };
829
+ if (shapeData !== void 0) {
830
+ let yamlData;
831
+ if (!shapeData.includes("\n")) {
832
+ yamlData = "{\n" + shapeData + "\n}";
833
+ } else {
834
+ yamlData = shapeData + "\n";
835
+ }
836
+ const doc = (0,_chunk_6JRP7KZX_mjs__WEBPACK_IMPORTED_MODULE_0__/* .load */ .H)(yamlData, { schema: _chunk_6JRP7KZX_mjs__WEBPACK_IMPORTED_MODULE_0__/* .JSON_SCHEMA */ .r });
837
+ if (doc.shape && (doc.shape !== doc.shape.toLowerCase() || doc.shape.includes("_"))) {
838
+ throw new Error(`No such shape: ${doc.shape}. Shape names should be lowercase.`);
839
+ }
840
+ if (doc?.shape && doc.shape === "kanbanItem") {
841
+ node.shape = doc?.shape;
842
+ }
843
+ if (doc?.label) {
844
+ node.label = doc?.label;
845
+ }
846
+ if (doc?.icon) {
847
+ node.icon = doc?.icon.toString();
848
+ }
849
+ if (doc?.assigned) {
850
+ node.assigned = doc?.assigned.toString();
851
+ }
852
+ if (doc?.ticket) {
853
+ node.ticket = doc?.ticket.toString();
854
+ }
855
+ if (doc?.priority) {
856
+ node.priority = doc?.priority;
857
+ }
858
+ }
859
+ const section = getSection(level);
860
+ if (section) {
861
+ node.parentId = section.id || "kbn" + cnt++;
862
+ } else {
863
+ sections.push(node);
864
+ }
865
+ nodes.push(node);
866
+ }, "addNode");
867
+ var nodeType = {
868
+ DEFAULT: 0,
869
+ NO_BORDER: 0,
870
+ ROUNDED_RECT: 1,
871
+ RECT: 2,
872
+ CIRCLE: 3,
873
+ CLOUD: 4,
874
+ BANG: 5,
875
+ HEXAGON: 6
876
+ };
877
+ var getType = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((startStr, endStr) => {
878
+ _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .log */ .Rm.debug("In get type", startStr, endStr);
879
+ switch (startStr) {
880
+ case "[":
881
+ return nodeType.RECT;
882
+ case "(":
883
+ return endStr === ")" ? nodeType.ROUNDED_RECT : nodeType.CLOUD;
884
+ case "((":
885
+ return nodeType.CIRCLE;
886
+ case ")":
887
+ return nodeType.CLOUD;
888
+ case "))":
889
+ return nodeType.BANG;
890
+ case "{{":
891
+ return nodeType.HEXAGON;
892
+ default:
893
+ return nodeType.DEFAULT;
894
+ }
895
+ }, "getType");
896
+ var setElementForId = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((id, element) => {
897
+ elements[id] = element;
898
+ }, "setElementForId");
899
+ var decorateNode = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((decoration) => {
900
+ if (!decoration) {
901
+ return;
902
+ }
903
+ const config = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .getConfig2 */ .D7)();
904
+ const node = nodes[nodes.length - 1];
905
+ if (decoration.icon) {
906
+ node.icon = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(decoration.icon, config);
907
+ }
908
+ if (decoration.class) {
909
+ node.cssClasses = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .sanitizeText */ .jZ)(decoration.class, config);
910
+ }
911
+ }, "decorateNode");
912
+ var type2Str = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((type) => {
913
+ switch (type) {
914
+ case nodeType.DEFAULT:
915
+ return "no-border";
916
+ case nodeType.RECT:
917
+ return "rect";
918
+ case nodeType.ROUNDED_RECT:
919
+ return "rounded-rect";
920
+ case nodeType.CIRCLE:
921
+ return "circle";
922
+ case nodeType.CLOUD:
923
+ return "cloud";
924
+ case nodeType.BANG:
925
+ return "bang";
926
+ case nodeType.HEXAGON:
927
+ return "hexgon";
928
+ // cspell: disable-line
929
+ default:
930
+ return "no-border";
931
+ }
932
+ }, "type2Str");
933
+ var getLogger = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(() => _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .log */ .Rm, "getLogger");
934
+ var getElementById = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((id) => elements[id], "getElementById");
935
+ var db = {
936
+ clear,
937
+ addNode,
938
+ getSections,
939
+ getData,
940
+ nodeType,
941
+ getType,
942
+ setElementForId,
943
+ decorateNode,
944
+ type2Str,
945
+ getLogger,
946
+ getElementById
947
+ };
948
+ var kanbanDb_default = db;
949
+
950
+ // src/diagrams/kanban/kanbanRenderer.ts
951
+ var draw = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)(async (text, id, _version, diagObj) => {
952
+ _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .log */ .Rm.debug("Rendering kanban diagram\n" + text);
953
+ const db2 = diagObj.db;
954
+ const data4Layout = db2.getData();
955
+ const conf = (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .getConfig2 */ .D7)();
956
+ conf.htmlLabels = false;
957
+ const svg = (0,_chunk_7B677QYD_mjs__WEBPACK_IMPORTED_MODULE_6__/* .selectSvgElement */ .D)(id);
958
+ const sectionsElem = svg.append("g");
959
+ sectionsElem.attr("class", "sections");
960
+ const nodesElem = svg.append("g");
961
+ nodesElem.attr("class", "items");
962
+ const sections2 = data4Layout.nodes.filter(
963
+ // TODO: TypeScript 5.5 will infer this predicate automatically
964
+ (node) => node.isGroup
965
+ );
966
+ let cnt2 = 0;
967
+ const padding = 10;
968
+ const sectionObjects = [];
969
+ let maxLabelHeight = 25;
970
+ for (const section of sections2) {
971
+ const WIDTH = conf?.kanban?.sectionWidth || 200;
972
+ cnt2 = cnt2 + 1;
973
+ section.x = WIDTH * cnt2 + (cnt2 - 1) * padding / 2;
974
+ section.width = WIDTH;
975
+ section.y = 0;
976
+ section.height = WIDTH * 3;
977
+ section.rx = 5;
978
+ section.ry = 5;
979
+ section.cssClasses = section.cssClasses + " section-" + cnt2;
980
+ const sectionObj = await (0,_chunk_HRU6DDCH_mjs__WEBPACK_IMPORTED_MODULE_1__/* .insertCluster */ .U)(sectionsElem, section);
981
+ maxLabelHeight = Math.max(maxLabelHeight, sectionObj?.labelBBox?.height);
982
+ sectionObjects.push(sectionObj);
983
+ }
984
+ let i = 0;
985
+ for (const section of sections2) {
986
+ const sectionObj = sectionObjects[i];
987
+ i = i + 1;
988
+ const WIDTH = conf?.kanban?.sectionWidth || 200;
989
+ const top = -WIDTH * 3 / 2 + maxLabelHeight;
990
+ let y = top;
991
+ const sectionItems = data4Layout.nodes.filter((node) => node.parentId === section.id);
992
+ for (const item of sectionItems) {
993
+ if (item.isGroup) {
994
+ throw new Error("Groups within groups are not allowed in Kanban diagrams");
995
+ }
996
+ item.x = section.x;
997
+ item.width = WIDTH - 1.5 * padding;
998
+ const nodeEl = await (0,_chunk_HRU6DDCH_mjs__WEBPACK_IMPORTED_MODULE_1__/* .insertNode */ .on)(nodesElem, item, { config: conf });
999
+ const bbox = nodeEl.node().getBBox();
1000
+ item.y = y + bbox.height / 2;
1001
+ await (0,_chunk_HRU6DDCH_mjs__WEBPACK_IMPORTED_MODULE_1__/* .positionNode */ .U_)(item);
1002
+ y = item.y + bbox.height / 2 + padding / 2;
1003
+ }
1004
+ const rect = sectionObj.cluster.select("rect");
1005
+ const height = Math.max(y - top + 3 * padding, 50) + (maxLabelHeight - 25);
1006
+ rect.attr("height", height);
1007
+ }
1008
+ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .setupGraphViewbox */ .ot)(
1009
+ void 0,
1010
+ svg,
1011
+ conf.mindmap?.padding ?? _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .defaultConfig_default */ .UI.kanban.padding,
1012
+ conf.mindmap?.useMaxWidth ?? _chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .defaultConfig_default */ .UI.kanban.useMaxWidth
1013
+ );
1014
+ }, "draw");
1015
+ var kanbanRenderer_default = {
1016
+ draw
1017
+ };
1018
+
1019
+ // src/diagrams/kanban/styles.ts
1020
+
1021
+ var genSections = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((options) => {
1022
+ let sections2 = "";
1023
+ for (let i = 0; i < options.THEME_COLOR_LIMIT; i++) {
1024
+ options["lineColor" + i] = options["lineColor" + i] || options["cScaleInv" + i];
1025
+ if ((0,khroma__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A)(options["lineColor" + i])) {
1026
+ options["lineColor" + i] = (0,khroma__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A)(options["lineColor" + i], 20);
1027
+ } else {
1028
+ options["lineColor" + i] = (0,khroma__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .A)(options["lineColor" + i], 20);
1029
+ }
1030
+ }
1031
+ const adjuster = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((color, level) => options.darkMode ? (0,khroma__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .A)(color, level) : (0,khroma__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A)(color, level), "adjuster");
1032
+ for (let i = 0; i < options.THEME_COLOR_LIMIT; i++) {
1033
+ const sw = "" + (17 - 3 * i);
1034
+ sections2 += `
1035
+ .section-${i - 1} rect, .section-${i - 1} path, .section-${i - 1} circle, .section-${i - 1} polygon, .section-${i - 1} path {
1036
+ fill: ${adjuster(options["cScale" + i], 10)};
1037
+ stroke: ${adjuster(options["cScale" + i], 10)};
1038
+
1039
+ }
1040
+ .section-${i - 1} text {
1041
+ fill: ${options["cScaleLabel" + i]};
1042
+ }
1043
+ .node-icon-${i - 1} {
1044
+ font-size: 40px;
1045
+ color: ${options["cScaleLabel" + i]};
1046
+ }
1047
+ .section-edge-${i - 1}{
1048
+ stroke: ${options["cScale" + i]};
1049
+ }
1050
+ .edge-depth-${i - 1}{
1051
+ stroke-width: ${sw};
1052
+ }
1053
+ .section-${i - 1} line {
1054
+ stroke: ${options["cScaleInv" + i]} ;
1055
+ stroke-width: 3;
1056
+ }
1057
+
1058
+ .disabled, .disabled circle, .disabled text {
1059
+ fill: lightgray;
1060
+ }
1061
+ .disabled text {
1062
+ fill: #efefef;
1063
+ }
1064
+
1065
+ .node rect,
1066
+ .node circle,
1067
+ .node ellipse,
1068
+ .node polygon,
1069
+ .node path {
1070
+ fill: ${options.background};
1071
+ stroke: ${options.nodeBorder};
1072
+ stroke-width: 1px;
1073
+ }
1074
+
1075
+ .kanban-ticket-link {
1076
+ fill: ${options.background};
1077
+ stroke: ${options.nodeBorder};
1078
+ text-decoration: underline;
1079
+ }
1080
+ `;
1081
+ }
1082
+ return sections2;
1083
+ }, "genSections");
1084
+ var getStyles = /* @__PURE__ */ (0,_chunk_YTJNT7DU_mjs__WEBPACK_IMPORTED_MODULE_7__/* .__name */ .K2)((options) => `
1085
+ .edge {
1086
+ stroke-width: 3;
1087
+ }
1088
+ ${genSections(options)}
1089
+ .section-root rect, .section-root path, .section-root circle, .section-root polygon {
1090
+ fill: ${options.git0};
1091
+ }
1092
+ .section-root text {
1093
+ fill: ${options.gitBranchLabel0};
1094
+ }
1095
+ .icon-container {
1096
+ height:100%;
1097
+ display: flex;
1098
+ justify-content: center;
1099
+ align-items: center;
1100
+ }
1101
+ .edge {
1102
+ fill: none;
1103
+ }
1104
+ .cluster-label, .label {
1105
+ color: ${options.textColor};
1106
+ fill: ${options.textColor};
1107
+ }
1108
+ .kanban-label {
1109
+ dy: 1em;
1110
+ alignment-baseline: middle;
1111
+ text-anchor: middle;
1112
+ dominant-baseline: middle;
1113
+ text-align: center;
1114
+ }
1115
+ `, "getStyles");
1116
+ var styles_default = getStyles;
1117
+
1118
+ // src/diagrams/kanban/kanban-definition.ts
1119
+ var diagram = {
1120
+ db: kanbanDb_default,
1121
+ renderer: kanbanRenderer_default,
1122
+ parser: kanban_default,
1123
+ styles: styles_default
1124
+ };
1125
+
1126
+
1127
+
1128
+ /***/ })
1129
+
1130
+ };
1131
+ ;
1132
+ //# sourceMappingURL=982.node.js.map