@oxide/design-system 1.7.7--canary.fdd8ab6.0 → 1.7.7--canary.87d60df.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/components/dist/architecture-I3QFYML2-YZWO3N3B.js +14 -0
- package/components/dist/architecture-I3QFYML2-YZWO3N3B.js.map +1 -0
- package/components/dist/architectureDiagram-UYN6MBPD-HXPGIDN7.js +8846 -0
- package/components/dist/architectureDiagram-UYN6MBPD-HXPGIDN7.js.map +1 -0
- package/components/dist/blockDiagram-ZHA2E4KO-OAYYKCLF.js +3721 -0
- package/components/dist/blockDiagram-ZHA2E4KO-OAYYKCLF.js.map +1 -0
- package/components/dist/c4Diagram-6F5ED5ID-TBHFK2XY.js +2599 -0
- package/components/dist/c4Diagram-6F5ED5ID-TBHFK2XY.js.map +1 -0
- package/components/dist/chunk-2DDKDUUO.js +439 -0
- package/components/dist/chunk-2DDKDUUO.js.map +1 -0
- package/components/dist/chunk-2NHDMTP7.js +26905 -0
- package/components/dist/chunk-2NHDMTP7.js.map +1 -0
- package/components/dist/chunk-4IJS44L3.js +22 -0
- package/components/dist/chunk-4IJS44L3.js.map +1 -0
- package/components/dist/chunk-562WOS3Z.js +1109 -0
- package/components/dist/chunk-562WOS3Z.js.map +1 -0
- package/components/dist/chunk-6UD2HOKB.js +17082 -0
- package/components/dist/chunk-6UD2HOKB.js.map +1 -0
- package/components/dist/chunk-76BOQ7BT.js +63 -0
- package/components/dist/chunk-76BOQ7BT.js.map +1 -0
- package/components/dist/chunk-7I5DT373.js +97 -0
- package/components/dist/chunk-7I5DT373.js.map +1 -0
- package/components/dist/chunk-BPREMNVP.js +1875 -0
- package/components/dist/chunk-BPREMNVP.js.map +1 -0
- package/components/dist/chunk-BVYAEHG3.js +122 -0
- package/components/dist/chunk-BVYAEHG3.js.map +1 -0
- package/components/dist/chunk-BW7DFBOS.js +152 -0
- package/components/dist/chunk-BW7DFBOS.js.map +1 -0
- package/components/dist/chunk-EZG2MNHW.js +59 -0
- package/components/dist/chunk-EZG2MNHW.js.map +1 -0
- package/components/dist/chunk-G6QWNAHJ.js +43 -0
- package/components/dist/chunk-G6QWNAHJ.js.map +1 -0
- package/components/dist/chunk-H72D3HRR.js +1244 -0
- package/components/dist/chunk-H72D3HRR.js.map +1 -0
- package/components/dist/chunk-K532NZMW.js +46 -0
- package/components/dist/chunk-K532NZMW.js.map +1 -0
- package/components/dist/chunk-LC3BX2KL.js +25 -0
- package/components/dist/chunk-LC3BX2KL.js.map +1 -0
- package/components/dist/chunk-LQ2ABR7F.js +5665 -0
- package/components/dist/chunk-LQ2ABR7F.js.map +1 -0
- package/components/dist/chunk-M6L3MM6K.js +22 -0
- package/components/dist/chunk-M6L3MM6K.js.map +1 -0
- package/components/dist/chunk-MWA4PRRW.js +122 -0
- package/components/dist/chunk-MWA4PRRW.js.map +1 -0
- package/components/dist/chunk-ND3FLKHU.js +570 -0
- package/components/dist/chunk-ND3FLKHU.js.map +1 -0
- package/components/dist/chunk-NIVHLOPB.js +2621 -0
- package/components/dist/chunk-NIVHLOPB.js.map +1 -0
- package/components/dist/chunk-R6F6FFK7.js +65 -0
- package/components/dist/chunk-R6F6FFK7.js.map +1 -0
- package/components/dist/chunk-RN5R3L7O.js +2041 -0
- package/components/dist/chunk-RN5R3L7O.js.map +1 -0
- package/components/dist/chunk-RWDBBMDN.js +10910 -0
- package/components/dist/chunk-RWDBBMDN.js.map +1 -0
- package/components/dist/chunk-T7HPDS4Z.js +573 -0
- package/components/dist/chunk-T7HPDS4Z.js.map +1 -0
- package/components/dist/chunk-TG4YEU4Q.js +23 -0
- package/components/dist/chunk-TG4YEU4Q.js.map +1 -0
- package/components/dist/chunk-U5WCXBW2.js +48 -0
- package/components/dist/chunk-U5WCXBW2.js.map +1 -0
- package/components/dist/chunk-V6PWN6OH.js +1875 -0
- package/components/dist/chunk-V6PWN6OH.js.map +1 -0
- package/components/dist/chunk-VLTHNCSD.js +48 -0
- package/components/dist/chunk-VLTHNCSD.js.map +1 -0
- package/components/dist/chunk-WDK4G4UR.js +2791 -0
- package/components/dist/chunk-WDK4G4UR.js.map +1 -0
- package/components/dist/chunk-WLVQWTC6.js +77 -0
- package/components/dist/chunk-WLVQWTC6.js.map +1 -0
- package/components/dist/chunk-YDLS5R4M.js +48 -0
- package/components/dist/chunk-YDLS5R4M.js.map +1 -0
- package/components/dist/chunk-YGFBWU2Q.js +7 -0
- package/components/dist/chunk-YGFBWU2Q.js.map +1 -0
- package/components/dist/chunk-ZBL4CWCH.js +2120 -0
- package/components/dist/chunk-ZBL4CWCH.js.map +1 -0
- package/components/dist/classDiagram-LNE6IOMH-VRQHEQWM.js +40 -0
- package/components/dist/classDiagram-LNE6IOMH-VRQHEQWM.js.map +1 -0
- package/components/dist/classDiagram-v2-MQ7JQ4JX-5GB4NXXM.js +40 -0
- package/components/dist/classDiagram-v2-MQ7JQ4JX-5GB4NXXM.js.map +1 -0
- package/components/dist/dagre-4EVJKHTY-XW45LMKR.js +734 -0
- package/components/dist/dagre-4EVJKHTY-XW45LMKR.js.map +1 -0
- package/components/dist/diagram-QW4FP2JN-J2YMUPB5.js +226 -0
- package/components/dist/diagram-QW4FP2JN-J2YMUPB5.js.map +1 -0
- package/components/dist/erDiagram-6RL3IURR-HQULDVJI.js +1381 -0
- package/components/dist/erDiagram-6RL3IURR-HQULDVJI.js.map +1 -0
- package/components/dist/flowDiagram-7ASYPVHJ-2542732I.js +2349 -0
- package/components/dist/flowDiagram-7ASYPVHJ-2542732I.js.map +1 -0
- package/components/dist/ganttDiagram-NTVNEXSI-V66YQQB3.js +2413 -0
- package/components/dist/ganttDiagram-NTVNEXSI-V66YQQB3.js.map +1 -0
- package/components/dist/gitGraph-YCYPL57B-AAXPWQN7.js +14 -0
- package/components/dist/gitGraph-YCYPL57B-AAXPWQN7.js.map +1 -0
- package/components/dist/gitGraphDiagram-NRZ2UAAF-5DU6QMYZ.js +1763 -0
- package/components/dist/gitGraphDiagram-NRZ2UAAF-5DU6QMYZ.js.map +1 -0
- package/components/dist/index.d.ts +5 -2
- package/components/dist/index.js +1729 -126
- package/components/dist/index.js.map +1 -1
- package/components/dist/info-46DW6VJ7-43TTIEYF.js +14 -0
- package/components/dist/info-46DW6VJ7-43TTIEYF.js.map +1 -0
- package/components/dist/infoDiagram-A4XQUW5V-UZERSQDI.js +54 -0
- package/components/dist/infoDiagram-A4XQUW5V-UZERSQDI.js.map +1 -0
- package/components/dist/journeyDiagram-G5WM74LC-RVKMRGRW.js +1244 -0
- package/components/dist/journeyDiagram-G5WM74LC-RVKMRGRW.js.map +1 -0
- package/components/dist/kanban-definition-QRCXZQQD-NWU5I3TK.js +1119 -0
- package/components/dist/kanban-definition-QRCXZQQD-NWU5I3TK.js.map +1 -0
- package/components/dist/katex-WNZY3CE5.js +14484 -0
- package/components/dist/katex-WNZY3CE5.js.map +1 -0
- package/components/dist/mindmap-definition-GWI6TPTV-MISEH6LG.js +6013 -0
- package/components/dist/mindmap-definition-GWI6TPTV-MISEH6LG.js.map +1 -0
- package/components/dist/packet-W2GHVCYJ-FBZCFIPR.js +14 -0
- package/components/dist/packet-W2GHVCYJ-FBZCFIPR.js.map +1 -0
- package/components/dist/pie-BEWT4RHE-UFFBBCXM.js +14 -0
- package/components/dist/pie-BEWT4RHE-UFFBBCXM.js.map +1 -0
- package/components/dist/pieDiagram-YF2LJOPJ-IXEVHPCM.js +223 -0
- package/components/dist/pieDiagram-YF2LJOPJ-IXEVHPCM.js.map +1 -0
- package/components/dist/quadrantDiagram-OS5C2QUG-MW26UCZV.js +1408 -0
- package/components/dist/quadrantDiagram-OS5C2QUG-MW26UCZV.js.map +1 -0
- package/components/dist/requirementDiagram-MIRIMTAZ-BX24AAHL.js +1175 -0
- package/components/dist/requirementDiagram-MIRIMTAZ-BX24AAHL.js.map +1 -0
- package/components/dist/sankeyDiagram-Y46BX6SQ-5RKUGG63.js +1278 -0
- package/components/dist/sankeyDiagram-Y46BX6SQ-5RKUGG63.js.map +1 -0
- package/components/dist/sequenceDiagram-G6AWOVSC-2T3JBUZ2.js +3529 -0
- package/components/dist/sequenceDiagram-G6AWOVSC-2T3JBUZ2.js.map +1 -0
- package/components/dist/stateDiagram-MAYHULR4-HZ5EGLPA.js +505 -0
- package/components/dist/stateDiagram-MAYHULR4-HZ5EGLPA.js.map +1 -0
- package/components/dist/stateDiagram-v2-4JROLMXI-DN2FEZV3.js +40 -0
- package/components/dist/stateDiagram-v2-4JROLMXI-DN2FEZV3.js.map +1 -0
- package/components/dist/timeline-definition-U7ZMHBDA-GB6AKKW4.js +1260 -0
- package/components/dist/timeline-definition-U7ZMHBDA-GB6AKKW4.js.map +1 -0
- package/components/dist/xychartDiagram-6QU3TZC5-BFFLEHUP.js +1877 -0
- package/components/dist/xychartDiagram-6QU3TZC5-BFFLEHUP.js.map +1 -0
- package/package.json +2 -1
package/components/dist/index.js
CHANGED
|
@@ -1,3 +1,70 @@
|
|
|
1
|
+
import {
|
|
2
|
+
version
|
|
3
|
+
} from "./chunk-YGFBWU2Q.js";
|
|
4
|
+
import {
|
|
5
|
+
selectSvgElement
|
|
6
|
+
} from "./chunk-TG4YEU4Q.js";
|
|
7
|
+
import {
|
|
8
|
+
JSON_SCHEMA,
|
|
9
|
+
load
|
|
10
|
+
} from "./chunk-WDK4G4UR.js";
|
|
11
|
+
import {
|
|
12
|
+
registerLayoutLoaders
|
|
13
|
+
} from "./chunk-WLVQWTC6.js";
|
|
14
|
+
import "./chunk-ND3FLKHU.js";
|
|
15
|
+
import "./chunk-LQ2ABR7F.js";
|
|
16
|
+
import "./chunk-BW7DFBOS.js";
|
|
17
|
+
import "./chunk-M6L3MM6K.js";
|
|
18
|
+
import {
|
|
19
|
+
registerIconPacks
|
|
20
|
+
} from "./chunk-H72D3HRR.js";
|
|
21
|
+
import {
|
|
22
|
+
dedent
|
|
23
|
+
} from "./chunk-NIVHLOPB.js";
|
|
24
|
+
import {
|
|
25
|
+
cleanAndMerge,
|
|
26
|
+
decodeEntities,
|
|
27
|
+
encodeEntities,
|
|
28
|
+
isDetailedError,
|
|
29
|
+
removeDirectives,
|
|
30
|
+
utils_default
|
|
31
|
+
} from "./chunk-T7HPDS4Z.js";
|
|
32
|
+
import "./chunk-7I5DT373.js";
|
|
33
|
+
import {
|
|
34
|
+
UnknownDiagramError,
|
|
35
|
+
__name,
|
|
36
|
+
addDirective,
|
|
37
|
+
assignWithDepth_default,
|
|
38
|
+
configureSvgSize,
|
|
39
|
+
defaultConfig,
|
|
40
|
+
detectType,
|
|
41
|
+
detectors,
|
|
42
|
+
evaluate,
|
|
43
|
+
frontMatterRegex,
|
|
44
|
+
getConfig,
|
|
45
|
+
getDiagram,
|
|
46
|
+
getDiagramLoader,
|
|
47
|
+
getSiteConfig,
|
|
48
|
+
log,
|
|
49
|
+
purify,
|
|
50
|
+
registerDiagram,
|
|
51
|
+
registerLazyLoadedDiagrams,
|
|
52
|
+
reset,
|
|
53
|
+
saveConfigFromInitialize,
|
|
54
|
+
select_default,
|
|
55
|
+
setConfig,
|
|
56
|
+
setLogLevel,
|
|
57
|
+
setSiteConfig,
|
|
58
|
+
styles_default,
|
|
59
|
+
themes_default,
|
|
60
|
+
updateSiteConfig
|
|
61
|
+
} from "./chunk-RWDBBMDN.js";
|
|
62
|
+
import {
|
|
63
|
+
isEmpty_default
|
|
64
|
+
} from "./chunk-BVYAEHG3.js";
|
|
65
|
+
import "./chunk-562WOS3Z.js";
|
|
66
|
+
import "./chunk-K532NZMW.js";
|
|
67
|
+
|
|
1
68
|
// components/src/asciidoc/index.tsx
|
|
2
69
|
import asciidoctor2 from "@asciidoctor/core";
|
|
3
70
|
import { Content as Content4 } from "@oxide/react-asciidoc";
|
|
@@ -47,8 +114,8 @@ var classed = {
|
|
|
47
114
|
|
|
48
115
|
// components/src/asciidoc/Admonition.tsx
|
|
49
116
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
50
|
-
var Admonition = ({ node }) => {
|
|
51
|
-
const attrs2 =
|
|
117
|
+
var Admonition = ({ node: node2 }) => {
|
|
118
|
+
const attrs2 = node2.attributes;
|
|
52
119
|
let icon;
|
|
53
120
|
if (attrs2.name === "caution") {
|
|
54
121
|
icon = /* @__PURE__ */ jsx(Error12, {});
|
|
@@ -60,12 +127,12 @@ var Admonition = ({ node }) => {
|
|
|
60
127
|
return /* @__PURE__ */ jsxs("div", { className: `admonitionblock ${attrs2.name}`, children: [
|
|
61
128
|
/* @__PURE__ */ jsx("div", { className: "admonition-icon", children: icon }),
|
|
62
129
|
/* @__PURE__ */ jsxs("div", { className: "admonition-content content", children: [
|
|
63
|
-
/* @__PURE__ */ jsx(Title, { text:
|
|
130
|
+
/* @__PURE__ */ jsx(Title, { text: node2.title }),
|
|
64
131
|
/* @__PURE__ */ jsx("div", { children: titleCase(attrs2.name.toString()) }),
|
|
65
132
|
/* @__PURE__ */ jsxs("div", { children: [
|
|
66
|
-
/* @__PURE__ */ jsx(Title, { text:
|
|
67
|
-
|
|
68
|
-
/* @__PURE__ */ jsx(Content, { blocks:
|
|
133
|
+
/* @__PURE__ */ jsx(Title, { text: node2.title }),
|
|
134
|
+
node2.content && parse(node2.content),
|
|
135
|
+
/* @__PURE__ */ jsx(Content, { blocks: node2.blocks })
|
|
69
136
|
] })
|
|
70
137
|
] })
|
|
71
138
|
] });
|
|
@@ -110,9 +177,1536 @@ var Warning12 = ({ className }) => /* @__PURE__ */ jsx(
|
|
|
110
177
|
);
|
|
111
178
|
var Admonition_default = Admonition;
|
|
112
179
|
|
|
180
|
+
// node_modules/stylis/src/Enum.js
|
|
181
|
+
var COMMENT = "comm";
|
|
182
|
+
var RULESET = "rule";
|
|
183
|
+
var DECLARATION = "decl";
|
|
184
|
+
var IMPORT = "@import";
|
|
185
|
+
var KEYFRAMES = "@keyframes";
|
|
186
|
+
var LAYER = "@layer";
|
|
187
|
+
|
|
188
|
+
// node_modules/stylis/src/Utility.js
|
|
189
|
+
var abs = Math.abs;
|
|
190
|
+
var from = String.fromCharCode;
|
|
191
|
+
function trim(value) {
|
|
192
|
+
return value.trim();
|
|
193
|
+
}
|
|
194
|
+
function replace(value, pattern, replacement) {
|
|
195
|
+
return value.replace(pattern, replacement);
|
|
196
|
+
}
|
|
197
|
+
function indexof(value, search, position2) {
|
|
198
|
+
return value.indexOf(search, position2);
|
|
199
|
+
}
|
|
200
|
+
function charat(value, index) {
|
|
201
|
+
return value.charCodeAt(index) | 0;
|
|
202
|
+
}
|
|
203
|
+
function substr(value, begin, end) {
|
|
204
|
+
return value.slice(begin, end);
|
|
205
|
+
}
|
|
206
|
+
function strlen(value) {
|
|
207
|
+
return value.length;
|
|
208
|
+
}
|
|
209
|
+
function sizeof(value) {
|
|
210
|
+
return value.length;
|
|
211
|
+
}
|
|
212
|
+
function append(value, array) {
|
|
213
|
+
return array.push(value), value;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
// node_modules/stylis/src/Tokenizer.js
|
|
217
|
+
var line = 1;
|
|
218
|
+
var column = 1;
|
|
219
|
+
var length = 0;
|
|
220
|
+
var position = 0;
|
|
221
|
+
var character = 0;
|
|
222
|
+
var characters = "";
|
|
223
|
+
function node(value, root, parent, type, props, children, length2, siblings) {
|
|
224
|
+
return { value, root, parent, type, props, children, line, column, length: length2, return: "", siblings };
|
|
225
|
+
}
|
|
226
|
+
function char() {
|
|
227
|
+
return character;
|
|
228
|
+
}
|
|
229
|
+
function prev() {
|
|
230
|
+
character = position > 0 ? charat(characters, --position) : 0;
|
|
231
|
+
if (column--, character === 10)
|
|
232
|
+
column = 1, line--;
|
|
233
|
+
return character;
|
|
234
|
+
}
|
|
235
|
+
function next() {
|
|
236
|
+
character = position < length ? charat(characters, position++) : 0;
|
|
237
|
+
if (column++, character === 10)
|
|
238
|
+
column = 1, line++;
|
|
239
|
+
return character;
|
|
240
|
+
}
|
|
241
|
+
function peek() {
|
|
242
|
+
return charat(characters, position);
|
|
243
|
+
}
|
|
244
|
+
function caret() {
|
|
245
|
+
return position;
|
|
246
|
+
}
|
|
247
|
+
function slice(begin, end) {
|
|
248
|
+
return substr(characters, begin, end);
|
|
249
|
+
}
|
|
250
|
+
function token(type) {
|
|
251
|
+
switch (type) {
|
|
252
|
+
case 0:
|
|
253
|
+
case 9:
|
|
254
|
+
case 10:
|
|
255
|
+
case 13:
|
|
256
|
+
case 32:
|
|
257
|
+
return 5;
|
|
258
|
+
case 33:
|
|
259
|
+
case 43:
|
|
260
|
+
case 44:
|
|
261
|
+
case 47:
|
|
262
|
+
case 62:
|
|
263
|
+
case 64:
|
|
264
|
+
case 126:
|
|
265
|
+
case 59:
|
|
266
|
+
case 123:
|
|
267
|
+
case 125:
|
|
268
|
+
return 4;
|
|
269
|
+
case 58:
|
|
270
|
+
return 3;
|
|
271
|
+
case 34:
|
|
272
|
+
case 39:
|
|
273
|
+
case 40:
|
|
274
|
+
case 91:
|
|
275
|
+
return 2;
|
|
276
|
+
case 41:
|
|
277
|
+
case 93:
|
|
278
|
+
return 1;
|
|
279
|
+
}
|
|
280
|
+
return 0;
|
|
281
|
+
}
|
|
282
|
+
function alloc(value) {
|
|
283
|
+
return line = column = 1, length = strlen(characters = value), position = 0, [];
|
|
284
|
+
}
|
|
285
|
+
function dealloc(value) {
|
|
286
|
+
return characters = "", value;
|
|
287
|
+
}
|
|
288
|
+
function delimit(type) {
|
|
289
|
+
return trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)));
|
|
290
|
+
}
|
|
291
|
+
function whitespace(type) {
|
|
292
|
+
while (character = peek())
|
|
293
|
+
if (character < 33)
|
|
294
|
+
next();
|
|
295
|
+
else
|
|
296
|
+
break;
|
|
297
|
+
return token(type) > 2 || token(character) > 3 ? "" : " ";
|
|
298
|
+
}
|
|
299
|
+
function escaping(index, count) {
|
|
300
|
+
while (--count && next())
|
|
301
|
+
if (character < 48 || character > 102 || character > 57 && character < 65 || character > 70 && character < 97)
|
|
302
|
+
break;
|
|
303
|
+
return slice(index, caret() + (count < 6 && peek() == 32 && next() == 32));
|
|
304
|
+
}
|
|
305
|
+
function delimiter(type) {
|
|
306
|
+
while (next())
|
|
307
|
+
switch (character) {
|
|
308
|
+
case type:
|
|
309
|
+
return position;
|
|
310
|
+
case 34:
|
|
311
|
+
case 39:
|
|
312
|
+
if (type !== 34 && type !== 39)
|
|
313
|
+
delimiter(character);
|
|
314
|
+
break;
|
|
315
|
+
case 40:
|
|
316
|
+
if (type === 41)
|
|
317
|
+
delimiter(type);
|
|
318
|
+
break;
|
|
319
|
+
case 92:
|
|
320
|
+
next();
|
|
321
|
+
break;
|
|
322
|
+
}
|
|
323
|
+
return position;
|
|
324
|
+
}
|
|
325
|
+
function commenter(type, index) {
|
|
326
|
+
while (next())
|
|
327
|
+
if (type + character === 47 + 10)
|
|
328
|
+
break;
|
|
329
|
+
else if (type + character === 42 + 42 && peek() === 47)
|
|
330
|
+
break;
|
|
331
|
+
return "/*" + slice(index, position - 1) + "*" + from(type === 47 ? type : next());
|
|
332
|
+
}
|
|
333
|
+
function identifier(index) {
|
|
334
|
+
while (!token(peek()))
|
|
335
|
+
next();
|
|
336
|
+
return slice(index, position);
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
// node_modules/stylis/src/Parser.js
|
|
340
|
+
function compile(value) {
|
|
341
|
+
return dealloc(parse2("", null, null, null, [""], value = alloc(value), 0, [0], value));
|
|
342
|
+
}
|
|
343
|
+
function parse2(value, root, parent, rule, rules, rulesets, pseudo, points, declarations) {
|
|
344
|
+
var index = 0;
|
|
345
|
+
var offset2 = 0;
|
|
346
|
+
var length2 = pseudo;
|
|
347
|
+
var atrule = 0;
|
|
348
|
+
var property = 0;
|
|
349
|
+
var previous = 0;
|
|
350
|
+
var variable = 1;
|
|
351
|
+
var scanning = 1;
|
|
352
|
+
var ampersand = 1;
|
|
353
|
+
var character2 = 0;
|
|
354
|
+
var type = "";
|
|
355
|
+
var props = rules;
|
|
356
|
+
var children = rulesets;
|
|
357
|
+
var reference = rule;
|
|
358
|
+
var characters2 = type;
|
|
359
|
+
while (scanning)
|
|
360
|
+
switch (previous = character2, character2 = next()) {
|
|
361
|
+
case 40:
|
|
362
|
+
if (previous != 108 && charat(characters2, length2 - 1) == 58) {
|
|
363
|
+
if (indexof(characters2 += replace(delimit(character2), "&", "&\f"), "&\f", abs(index ? points[index - 1] : 0)) != -1)
|
|
364
|
+
ampersand = -1;
|
|
365
|
+
break;
|
|
366
|
+
}
|
|
367
|
+
case 34:
|
|
368
|
+
case 39:
|
|
369
|
+
case 91:
|
|
370
|
+
characters2 += delimit(character2);
|
|
371
|
+
break;
|
|
372
|
+
case 9:
|
|
373
|
+
case 10:
|
|
374
|
+
case 13:
|
|
375
|
+
case 32:
|
|
376
|
+
characters2 += whitespace(previous);
|
|
377
|
+
break;
|
|
378
|
+
case 92:
|
|
379
|
+
characters2 += escaping(caret() - 1, 7);
|
|
380
|
+
continue;
|
|
381
|
+
case 47:
|
|
382
|
+
switch (peek()) {
|
|
383
|
+
case 42:
|
|
384
|
+
case 47:
|
|
385
|
+
append(comment(commenter(next(), caret()), root, parent, declarations), declarations);
|
|
386
|
+
if ((token(previous || 1) == 5 || token(peek() || 1) == 5) && strlen(characters2) && substr(characters2, -1, void 0) !== " ")
|
|
387
|
+
characters2 += " ";
|
|
388
|
+
break;
|
|
389
|
+
default:
|
|
390
|
+
characters2 += "/";
|
|
391
|
+
}
|
|
392
|
+
break;
|
|
393
|
+
case 123 * variable:
|
|
394
|
+
points[index++] = strlen(characters2) * ampersand;
|
|
395
|
+
case 125 * variable:
|
|
396
|
+
case 59:
|
|
397
|
+
case 0:
|
|
398
|
+
switch (character2) {
|
|
399
|
+
case 0:
|
|
400
|
+
case 125:
|
|
401
|
+
scanning = 0;
|
|
402
|
+
case 59 + offset2:
|
|
403
|
+
if (ampersand == -1)
|
|
404
|
+
characters2 = replace(characters2, /\f/g, "");
|
|
405
|
+
if (property > 0 && (strlen(characters2) - length2 || variable === 0 && previous === 47))
|
|
406
|
+
append(property > 32 ? declaration(characters2 + ";", rule, parent, length2 - 1, declarations) : declaration(replace(characters2, " ", "") + ";", rule, parent, length2 - 2, declarations), declarations);
|
|
407
|
+
break;
|
|
408
|
+
case 59:
|
|
409
|
+
characters2 += ";";
|
|
410
|
+
default:
|
|
411
|
+
append(reference = ruleset(characters2, root, parent, index, offset2, rules, points, type, props = [], children = [], length2, rulesets), rulesets);
|
|
412
|
+
if (character2 === 123)
|
|
413
|
+
if (offset2 === 0)
|
|
414
|
+
parse2(characters2, root, reference, reference, props, rulesets, length2, points, children);
|
|
415
|
+
else
|
|
416
|
+
switch (atrule === 99 && charat(characters2, 3) === 110 ? 100 : atrule) {
|
|
417
|
+
case 100:
|
|
418
|
+
case 108:
|
|
419
|
+
case 109:
|
|
420
|
+
case 115:
|
|
421
|
+
parse2(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length2, children), children), rules, children, length2, points, rule ? props : children);
|
|
422
|
+
break;
|
|
423
|
+
default:
|
|
424
|
+
parse2(characters2, reference, reference, reference, [""], children, 0, points, children);
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
index = offset2 = property = 0, variable = ampersand = 1, type = characters2 = "", length2 = pseudo;
|
|
428
|
+
break;
|
|
429
|
+
case 58:
|
|
430
|
+
length2 = 1 + strlen(characters2), property = previous;
|
|
431
|
+
default:
|
|
432
|
+
if (variable < 1) {
|
|
433
|
+
if (character2 == 123)
|
|
434
|
+
--variable;
|
|
435
|
+
else if (character2 == 125 && variable++ == 0 && prev() == 125)
|
|
436
|
+
continue;
|
|
437
|
+
}
|
|
438
|
+
switch (characters2 += from(character2), character2 * variable) {
|
|
439
|
+
case 38:
|
|
440
|
+
ampersand = offset2 > 0 ? 1 : (characters2 += "\f", -1);
|
|
441
|
+
break;
|
|
442
|
+
case 44:
|
|
443
|
+
points[index++] = (strlen(characters2) - 1) * ampersand, ampersand = 1;
|
|
444
|
+
break;
|
|
445
|
+
case 64:
|
|
446
|
+
if (peek() === 45)
|
|
447
|
+
characters2 += delimit(next());
|
|
448
|
+
atrule = peek(), offset2 = length2 = strlen(type = characters2 += identifier(caret())), character2++;
|
|
449
|
+
break;
|
|
450
|
+
case 45:
|
|
451
|
+
if (previous === 45 && strlen(characters2) == 2)
|
|
452
|
+
variable = 0;
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
return rulesets;
|
|
456
|
+
}
|
|
457
|
+
function ruleset(value, root, parent, index, offset2, rules, points, type, props, children, length2, siblings) {
|
|
458
|
+
var post = offset2 - 1;
|
|
459
|
+
var rule = offset2 === 0 ? rules : [""];
|
|
460
|
+
var size2 = sizeof(rule);
|
|
461
|
+
for (var i = 0, j = 0, k = 0; i < index; ++i)
|
|
462
|
+
for (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size2; ++x)
|
|
463
|
+
if (z = trim(j > 0 ? rule[x] + " " + y : replace(y, /&\f/g, rule[x])))
|
|
464
|
+
props[k++] = z;
|
|
465
|
+
return node(value, root, parent, offset2 === 0 ? RULESET : type, props, children, length2, siblings);
|
|
466
|
+
}
|
|
467
|
+
function comment(value, root, parent, siblings) {
|
|
468
|
+
return node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0, siblings);
|
|
469
|
+
}
|
|
470
|
+
function declaration(value, root, parent, length2, siblings) {
|
|
471
|
+
return node(value, root, parent, DECLARATION, substr(value, 0, length2), substr(value, length2 + 1, -1), length2, siblings);
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
// node_modules/stylis/src/Serializer.js
|
|
475
|
+
function serialize(children, callback) {
|
|
476
|
+
var output = "";
|
|
477
|
+
for (var i = 0; i < children.length; i++)
|
|
478
|
+
output += callback(children[i], i, children, callback) || "";
|
|
479
|
+
return output;
|
|
480
|
+
}
|
|
481
|
+
function stringify(element, index, children, callback) {
|
|
482
|
+
switch (element.type) {
|
|
483
|
+
case LAYER:
|
|
484
|
+
if (element.children.length)
|
|
485
|
+
break;
|
|
486
|
+
case IMPORT:
|
|
487
|
+
case DECLARATION:
|
|
488
|
+
return element.return = element.return || element.value;
|
|
489
|
+
case COMMENT:
|
|
490
|
+
return "";
|
|
491
|
+
case KEYFRAMES:
|
|
492
|
+
return element.return = element.value + "{" + serialize(element.children, callback) + "}";
|
|
493
|
+
case RULESET:
|
|
494
|
+
if (!strlen(element.value = element.props.join(",")))
|
|
495
|
+
return "";
|
|
496
|
+
}
|
|
497
|
+
return strlen(children = serialize(element.children, callback)) ? element.return = element.value + "{" + children + "}" : "";
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
// node_modules/mermaid/dist/mermaid.core.mjs
|
|
501
|
+
var id = "c4";
|
|
502
|
+
var detector = /* @__PURE__ */ __name((txt) => {
|
|
503
|
+
return /^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(txt);
|
|
504
|
+
}, "detector");
|
|
505
|
+
var loader = /* @__PURE__ */ __name(async () => {
|
|
506
|
+
const { diagram: diagram2 } = await import("./c4Diagram-6F5ED5ID-TBHFK2XY.js");
|
|
507
|
+
return { id, diagram: diagram2 };
|
|
508
|
+
}, "loader");
|
|
509
|
+
var plugin = {
|
|
510
|
+
id,
|
|
511
|
+
detector,
|
|
512
|
+
loader
|
|
513
|
+
};
|
|
514
|
+
var c4Detector_default = plugin;
|
|
515
|
+
var id2 = "flowchart";
|
|
516
|
+
var detector2 = /* @__PURE__ */ __name((txt, config) => {
|
|
517
|
+
if (config?.flowchart?.defaultRenderer === "dagre-wrapper" || config?.flowchart?.defaultRenderer === "elk") {
|
|
518
|
+
return false;
|
|
519
|
+
}
|
|
520
|
+
return /^\s*graph/.test(txt);
|
|
521
|
+
}, "detector");
|
|
522
|
+
var loader2 = /* @__PURE__ */ __name(async () => {
|
|
523
|
+
const { diagram: diagram2 } = await import("./flowDiagram-7ASYPVHJ-2542732I.js");
|
|
524
|
+
return { id: id2, diagram: diagram2 };
|
|
525
|
+
}, "loader");
|
|
526
|
+
var plugin2 = {
|
|
527
|
+
id: id2,
|
|
528
|
+
detector: detector2,
|
|
529
|
+
loader: loader2
|
|
530
|
+
};
|
|
531
|
+
var flowDetector_default = plugin2;
|
|
532
|
+
var id3 = "flowchart-v2";
|
|
533
|
+
var detector3 = /* @__PURE__ */ __name((txt, config) => {
|
|
534
|
+
if (config?.flowchart?.defaultRenderer === "dagre-d3") {
|
|
535
|
+
return false;
|
|
536
|
+
}
|
|
537
|
+
if (config?.flowchart?.defaultRenderer === "elk") {
|
|
538
|
+
config.layout = "elk";
|
|
539
|
+
}
|
|
540
|
+
if (/^\s*graph/.test(txt) && config?.flowchart?.defaultRenderer === "dagre-wrapper") {
|
|
541
|
+
return true;
|
|
542
|
+
}
|
|
543
|
+
return /^\s*flowchart/.test(txt);
|
|
544
|
+
}, "detector");
|
|
545
|
+
var loader3 = /* @__PURE__ */ __name(async () => {
|
|
546
|
+
const { diagram: diagram2 } = await import("./flowDiagram-7ASYPVHJ-2542732I.js");
|
|
547
|
+
return { id: id3, diagram: diagram2 };
|
|
548
|
+
}, "loader");
|
|
549
|
+
var plugin3 = {
|
|
550
|
+
id: id3,
|
|
551
|
+
detector: detector3,
|
|
552
|
+
loader: loader3
|
|
553
|
+
};
|
|
554
|
+
var flowDetector_v2_default = plugin3;
|
|
555
|
+
var id4 = "er";
|
|
556
|
+
var detector4 = /* @__PURE__ */ __name((txt) => {
|
|
557
|
+
return /^\s*erDiagram/.test(txt);
|
|
558
|
+
}, "detector");
|
|
559
|
+
var loader4 = /* @__PURE__ */ __name(async () => {
|
|
560
|
+
const { diagram: diagram2 } = await import("./erDiagram-6RL3IURR-HQULDVJI.js");
|
|
561
|
+
return { id: id4, diagram: diagram2 };
|
|
562
|
+
}, "loader");
|
|
563
|
+
var plugin4 = {
|
|
564
|
+
id: id4,
|
|
565
|
+
detector: detector4,
|
|
566
|
+
loader: loader4
|
|
567
|
+
};
|
|
568
|
+
var erDetector_default = plugin4;
|
|
569
|
+
var id5 = "gitGraph";
|
|
570
|
+
var detector5 = /* @__PURE__ */ __name((txt) => {
|
|
571
|
+
return /^\s*gitGraph/.test(txt);
|
|
572
|
+
}, "detector");
|
|
573
|
+
var loader5 = /* @__PURE__ */ __name(async () => {
|
|
574
|
+
const { diagram: diagram2 } = await import("./gitGraphDiagram-NRZ2UAAF-5DU6QMYZ.js");
|
|
575
|
+
return { id: id5, diagram: diagram2 };
|
|
576
|
+
}, "loader");
|
|
577
|
+
var plugin5 = {
|
|
578
|
+
id: id5,
|
|
579
|
+
detector: detector5,
|
|
580
|
+
loader: loader5
|
|
581
|
+
};
|
|
582
|
+
var gitGraphDetector_default = plugin5;
|
|
583
|
+
var id6 = "gantt";
|
|
584
|
+
var detector6 = /* @__PURE__ */ __name((txt) => {
|
|
585
|
+
return /^\s*gantt/.test(txt);
|
|
586
|
+
}, "detector");
|
|
587
|
+
var loader6 = /* @__PURE__ */ __name(async () => {
|
|
588
|
+
const { diagram: diagram2 } = await import("./ganttDiagram-NTVNEXSI-V66YQQB3.js");
|
|
589
|
+
return { id: id6, diagram: diagram2 };
|
|
590
|
+
}, "loader");
|
|
591
|
+
var plugin6 = {
|
|
592
|
+
id: id6,
|
|
593
|
+
detector: detector6,
|
|
594
|
+
loader: loader6
|
|
595
|
+
};
|
|
596
|
+
var ganttDetector_default = plugin6;
|
|
597
|
+
var id7 = "info";
|
|
598
|
+
var detector7 = /* @__PURE__ */ __name((txt) => {
|
|
599
|
+
return /^\s*info/.test(txt);
|
|
600
|
+
}, "detector");
|
|
601
|
+
var loader7 = /* @__PURE__ */ __name(async () => {
|
|
602
|
+
const { diagram: diagram2 } = await import("./infoDiagram-A4XQUW5V-UZERSQDI.js");
|
|
603
|
+
return { id: id7, diagram: diagram2 };
|
|
604
|
+
}, "loader");
|
|
605
|
+
var info = {
|
|
606
|
+
id: id7,
|
|
607
|
+
detector: detector7,
|
|
608
|
+
loader: loader7
|
|
609
|
+
};
|
|
610
|
+
var id8 = "pie";
|
|
611
|
+
var detector8 = /* @__PURE__ */ __name((txt) => {
|
|
612
|
+
return /^\s*pie/.test(txt);
|
|
613
|
+
}, "detector");
|
|
614
|
+
var loader8 = /* @__PURE__ */ __name(async () => {
|
|
615
|
+
const { diagram: diagram2 } = await import("./pieDiagram-YF2LJOPJ-IXEVHPCM.js");
|
|
616
|
+
return { id: id8, diagram: diagram2 };
|
|
617
|
+
}, "loader");
|
|
618
|
+
var pie = {
|
|
619
|
+
id: id8,
|
|
620
|
+
detector: detector8,
|
|
621
|
+
loader: loader8
|
|
622
|
+
};
|
|
623
|
+
var id9 = "quadrantChart";
|
|
624
|
+
var detector9 = /* @__PURE__ */ __name((txt) => {
|
|
625
|
+
return /^\s*quadrantChart/.test(txt);
|
|
626
|
+
}, "detector");
|
|
627
|
+
var loader9 = /* @__PURE__ */ __name(async () => {
|
|
628
|
+
const { diagram: diagram2 } = await import("./quadrantDiagram-OS5C2QUG-MW26UCZV.js");
|
|
629
|
+
return { id: id9, diagram: diagram2 };
|
|
630
|
+
}, "loader");
|
|
631
|
+
var plugin7 = {
|
|
632
|
+
id: id9,
|
|
633
|
+
detector: detector9,
|
|
634
|
+
loader: loader9
|
|
635
|
+
};
|
|
636
|
+
var quadrantDetector_default = plugin7;
|
|
637
|
+
var id10 = "xychart";
|
|
638
|
+
var detector10 = /* @__PURE__ */ __name((txt) => {
|
|
639
|
+
return /^\s*xychart-beta/.test(txt);
|
|
640
|
+
}, "detector");
|
|
641
|
+
var loader10 = /* @__PURE__ */ __name(async () => {
|
|
642
|
+
const { diagram: diagram2 } = await import("./xychartDiagram-6QU3TZC5-BFFLEHUP.js");
|
|
643
|
+
return { id: id10, diagram: diagram2 };
|
|
644
|
+
}, "loader");
|
|
645
|
+
var plugin8 = {
|
|
646
|
+
id: id10,
|
|
647
|
+
detector: detector10,
|
|
648
|
+
loader: loader10
|
|
649
|
+
};
|
|
650
|
+
var xychartDetector_default = plugin8;
|
|
651
|
+
var id11 = "requirement";
|
|
652
|
+
var detector11 = /* @__PURE__ */ __name((txt) => {
|
|
653
|
+
return /^\s*requirement(Diagram)?/.test(txt);
|
|
654
|
+
}, "detector");
|
|
655
|
+
var loader11 = /* @__PURE__ */ __name(async () => {
|
|
656
|
+
const { diagram: diagram2 } = await import("./requirementDiagram-MIRIMTAZ-BX24AAHL.js");
|
|
657
|
+
return { id: id11, diagram: diagram2 };
|
|
658
|
+
}, "loader");
|
|
659
|
+
var plugin9 = {
|
|
660
|
+
id: id11,
|
|
661
|
+
detector: detector11,
|
|
662
|
+
loader: loader11
|
|
663
|
+
};
|
|
664
|
+
var requirementDetector_default = plugin9;
|
|
665
|
+
var id12 = "sequence";
|
|
666
|
+
var detector12 = /* @__PURE__ */ __name((txt) => {
|
|
667
|
+
return /^\s*sequenceDiagram/.test(txt);
|
|
668
|
+
}, "detector");
|
|
669
|
+
var loader12 = /* @__PURE__ */ __name(async () => {
|
|
670
|
+
const { diagram: diagram2 } = await import("./sequenceDiagram-G6AWOVSC-2T3JBUZ2.js");
|
|
671
|
+
return { id: id12, diagram: diagram2 };
|
|
672
|
+
}, "loader");
|
|
673
|
+
var plugin10 = {
|
|
674
|
+
id: id12,
|
|
675
|
+
detector: detector12,
|
|
676
|
+
loader: loader12
|
|
677
|
+
};
|
|
678
|
+
var sequenceDetector_default = plugin10;
|
|
679
|
+
var id13 = "class";
|
|
680
|
+
var detector13 = /* @__PURE__ */ __name((txt, config) => {
|
|
681
|
+
if (config?.class?.defaultRenderer === "dagre-wrapper") {
|
|
682
|
+
return false;
|
|
683
|
+
}
|
|
684
|
+
return /^\s*classDiagram/.test(txt);
|
|
685
|
+
}, "detector");
|
|
686
|
+
var loader13 = /* @__PURE__ */ __name(async () => {
|
|
687
|
+
const { diagram: diagram2 } = await import("./classDiagram-LNE6IOMH-VRQHEQWM.js");
|
|
688
|
+
return { id: id13, diagram: diagram2 };
|
|
689
|
+
}, "loader");
|
|
690
|
+
var plugin11 = {
|
|
691
|
+
id: id13,
|
|
692
|
+
detector: detector13,
|
|
693
|
+
loader: loader13
|
|
694
|
+
};
|
|
695
|
+
var classDetector_default = plugin11;
|
|
696
|
+
var id14 = "classDiagram";
|
|
697
|
+
var detector14 = /* @__PURE__ */ __name((txt, config) => {
|
|
698
|
+
if (/^\s*classDiagram/.test(txt) && config?.class?.defaultRenderer === "dagre-wrapper") {
|
|
699
|
+
return true;
|
|
700
|
+
}
|
|
701
|
+
return /^\s*classDiagram-v2/.test(txt);
|
|
702
|
+
}, "detector");
|
|
703
|
+
var loader14 = /* @__PURE__ */ __name(async () => {
|
|
704
|
+
const { diagram: diagram2 } = await import("./classDiagram-v2-MQ7JQ4JX-5GB4NXXM.js");
|
|
705
|
+
return { id: id14, diagram: diagram2 };
|
|
706
|
+
}, "loader");
|
|
707
|
+
var plugin12 = {
|
|
708
|
+
id: id14,
|
|
709
|
+
detector: detector14,
|
|
710
|
+
loader: loader14
|
|
711
|
+
};
|
|
712
|
+
var classDetector_V2_default = plugin12;
|
|
713
|
+
var id15 = "state";
|
|
714
|
+
var detector15 = /* @__PURE__ */ __name((txt, config) => {
|
|
715
|
+
if (config?.state?.defaultRenderer === "dagre-wrapper") {
|
|
716
|
+
return false;
|
|
717
|
+
}
|
|
718
|
+
return /^\s*stateDiagram/.test(txt);
|
|
719
|
+
}, "detector");
|
|
720
|
+
var loader15 = /* @__PURE__ */ __name(async () => {
|
|
721
|
+
const { diagram: diagram2 } = await import("./stateDiagram-MAYHULR4-HZ5EGLPA.js");
|
|
722
|
+
return { id: id15, diagram: diagram2 };
|
|
723
|
+
}, "loader");
|
|
724
|
+
var plugin13 = {
|
|
725
|
+
id: id15,
|
|
726
|
+
detector: detector15,
|
|
727
|
+
loader: loader15
|
|
728
|
+
};
|
|
729
|
+
var stateDetector_default = plugin13;
|
|
730
|
+
var id16 = "stateDiagram";
|
|
731
|
+
var detector16 = /* @__PURE__ */ __name((txt, config) => {
|
|
732
|
+
if (/^\s*stateDiagram-v2/.test(txt)) {
|
|
733
|
+
return true;
|
|
734
|
+
}
|
|
735
|
+
if (/^\s*stateDiagram/.test(txt) && config?.state?.defaultRenderer === "dagre-wrapper") {
|
|
736
|
+
return true;
|
|
737
|
+
}
|
|
738
|
+
return false;
|
|
739
|
+
}, "detector");
|
|
740
|
+
var loader16 = /* @__PURE__ */ __name(async () => {
|
|
741
|
+
const { diagram: diagram2 } = await import("./stateDiagram-v2-4JROLMXI-DN2FEZV3.js");
|
|
742
|
+
return { id: id16, diagram: diagram2 };
|
|
743
|
+
}, "loader");
|
|
744
|
+
var plugin14 = {
|
|
745
|
+
id: id16,
|
|
746
|
+
detector: detector16,
|
|
747
|
+
loader: loader16
|
|
748
|
+
};
|
|
749
|
+
var stateDetector_V2_default = plugin14;
|
|
750
|
+
var id17 = "journey";
|
|
751
|
+
var detector17 = /* @__PURE__ */ __name((txt) => {
|
|
752
|
+
return /^\s*journey/.test(txt);
|
|
753
|
+
}, "detector");
|
|
754
|
+
var loader17 = /* @__PURE__ */ __name(async () => {
|
|
755
|
+
const { diagram: diagram2 } = await import("./journeyDiagram-G5WM74LC-RVKMRGRW.js");
|
|
756
|
+
return { id: id17, diagram: diagram2 };
|
|
757
|
+
}, "loader");
|
|
758
|
+
var plugin15 = {
|
|
759
|
+
id: id17,
|
|
760
|
+
detector: detector17,
|
|
761
|
+
loader: loader17
|
|
762
|
+
};
|
|
763
|
+
var journeyDetector_default = plugin15;
|
|
764
|
+
var draw = /* @__PURE__ */ __name((_text, id26, version2) => {
|
|
765
|
+
log.debug("rendering svg for syntax error\n");
|
|
766
|
+
const svg = selectSvgElement(id26);
|
|
767
|
+
const g = svg.append("g");
|
|
768
|
+
svg.attr("viewBox", "0 0 2412 512");
|
|
769
|
+
configureSvgSize(svg, 100, 512, true);
|
|
770
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
771
|
+
"d",
|
|
772
|
+
"m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"
|
|
773
|
+
);
|
|
774
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
775
|
+
"d",
|
|
776
|
+
"m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"
|
|
777
|
+
);
|
|
778
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
779
|
+
"d",
|
|
780
|
+
"m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"
|
|
781
|
+
);
|
|
782
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
783
|
+
"d",
|
|
784
|
+
"m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"
|
|
785
|
+
);
|
|
786
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
787
|
+
"d",
|
|
788
|
+
"m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"
|
|
789
|
+
);
|
|
790
|
+
g.append("path").attr("class", "error-icon").attr(
|
|
791
|
+
"d",
|
|
792
|
+
"m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"
|
|
793
|
+
);
|
|
794
|
+
g.append("text").attr("class", "error-text").attr("x", 1440).attr("y", 250).attr("font-size", "150px").style("text-anchor", "middle").text("Syntax error in text");
|
|
795
|
+
g.append("text").attr("class", "error-text").attr("x", 1250).attr("y", 400).attr("font-size", "100px").style("text-anchor", "middle").text(`mermaid version ${version2}`);
|
|
796
|
+
}, "draw");
|
|
797
|
+
var renderer = { draw };
|
|
798
|
+
var errorRenderer_default = renderer;
|
|
799
|
+
var diagram = {
|
|
800
|
+
db: {},
|
|
801
|
+
renderer,
|
|
802
|
+
parser: {
|
|
803
|
+
parse: /* @__PURE__ */ __name(() => {
|
|
804
|
+
return;
|
|
805
|
+
}, "parse")
|
|
806
|
+
}
|
|
807
|
+
};
|
|
808
|
+
var errorDiagram_default = diagram;
|
|
809
|
+
var id18 = "flowchart-elk";
|
|
810
|
+
var detector18 = /* @__PURE__ */ __name((txt, config = {}) => {
|
|
811
|
+
if (
|
|
812
|
+
// If diagram explicitly states flowchart-elk
|
|
813
|
+
/^\s*flowchart-elk/.test(txt) || // If a flowchart/graph diagram has their default renderer set to elk
|
|
814
|
+
/^\s*flowchart|graph/.test(txt) && config?.flowchart?.defaultRenderer === "elk"
|
|
815
|
+
) {
|
|
816
|
+
config.layout = "elk";
|
|
817
|
+
return true;
|
|
818
|
+
}
|
|
819
|
+
return false;
|
|
820
|
+
}, "detector");
|
|
821
|
+
var loader18 = /* @__PURE__ */ __name(async () => {
|
|
822
|
+
const { diagram: diagram2 } = await import("./flowDiagram-7ASYPVHJ-2542732I.js");
|
|
823
|
+
return { id: id18, diagram: diagram2 };
|
|
824
|
+
}, "loader");
|
|
825
|
+
var plugin16 = {
|
|
826
|
+
id: id18,
|
|
827
|
+
detector: detector18,
|
|
828
|
+
loader: loader18
|
|
829
|
+
};
|
|
830
|
+
var detector_default = plugin16;
|
|
831
|
+
var id19 = "timeline";
|
|
832
|
+
var detector19 = /* @__PURE__ */ __name((txt) => {
|
|
833
|
+
return /^\s*timeline/.test(txt);
|
|
834
|
+
}, "detector");
|
|
835
|
+
var loader19 = /* @__PURE__ */ __name(async () => {
|
|
836
|
+
const { diagram: diagram2 } = await import("./timeline-definition-U7ZMHBDA-GB6AKKW4.js");
|
|
837
|
+
return { id: id19, diagram: diagram2 };
|
|
838
|
+
}, "loader");
|
|
839
|
+
var plugin17 = {
|
|
840
|
+
id: id19,
|
|
841
|
+
detector: detector19,
|
|
842
|
+
loader: loader19
|
|
843
|
+
};
|
|
844
|
+
var detector_default2 = plugin17;
|
|
845
|
+
var id20 = "mindmap";
|
|
846
|
+
var detector20 = /* @__PURE__ */ __name((txt) => {
|
|
847
|
+
return /^\s*mindmap/.test(txt);
|
|
848
|
+
}, "detector");
|
|
849
|
+
var loader20 = /* @__PURE__ */ __name(async () => {
|
|
850
|
+
const { diagram: diagram2 } = await import("./mindmap-definition-GWI6TPTV-MISEH6LG.js");
|
|
851
|
+
return { id: id20, diagram: diagram2 };
|
|
852
|
+
}, "loader");
|
|
853
|
+
var plugin18 = {
|
|
854
|
+
id: id20,
|
|
855
|
+
detector: detector20,
|
|
856
|
+
loader: loader20
|
|
857
|
+
};
|
|
858
|
+
var detector_default3 = plugin18;
|
|
859
|
+
var id21 = "kanban";
|
|
860
|
+
var detector21 = /* @__PURE__ */ __name((txt) => {
|
|
861
|
+
return /^\s*kanban/.test(txt);
|
|
862
|
+
}, "detector");
|
|
863
|
+
var loader21 = /* @__PURE__ */ __name(async () => {
|
|
864
|
+
const { diagram: diagram2 } = await import("./kanban-definition-QRCXZQQD-NWU5I3TK.js");
|
|
865
|
+
return { id: id21, diagram: diagram2 };
|
|
866
|
+
}, "loader");
|
|
867
|
+
var plugin19 = {
|
|
868
|
+
id: id21,
|
|
869
|
+
detector: detector21,
|
|
870
|
+
loader: loader21
|
|
871
|
+
};
|
|
872
|
+
var detector_default4 = plugin19;
|
|
873
|
+
var id22 = "sankey";
|
|
874
|
+
var detector22 = /* @__PURE__ */ __name((txt) => {
|
|
875
|
+
return /^\s*sankey-beta/.test(txt);
|
|
876
|
+
}, "detector");
|
|
877
|
+
var loader22 = /* @__PURE__ */ __name(async () => {
|
|
878
|
+
const { diagram: diagram2 } = await import("./sankeyDiagram-Y46BX6SQ-5RKUGG63.js");
|
|
879
|
+
return { id: id22, diagram: diagram2 };
|
|
880
|
+
}, "loader");
|
|
881
|
+
var plugin20 = {
|
|
882
|
+
id: id22,
|
|
883
|
+
detector: detector22,
|
|
884
|
+
loader: loader22
|
|
885
|
+
};
|
|
886
|
+
var sankeyDetector_default = plugin20;
|
|
887
|
+
var id23 = "packet";
|
|
888
|
+
var detector23 = /* @__PURE__ */ __name((txt) => {
|
|
889
|
+
return /^\s*packet-beta/.test(txt);
|
|
890
|
+
}, "detector");
|
|
891
|
+
var loader23 = /* @__PURE__ */ __name(async () => {
|
|
892
|
+
const { diagram: diagram2 } = await import("./diagram-QW4FP2JN-J2YMUPB5.js");
|
|
893
|
+
return { id: id23, diagram: diagram2 };
|
|
894
|
+
}, "loader");
|
|
895
|
+
var packet = {
|
|
896
|
+
id: id23,
|
|
897
|
+
detector: detector23,
|
|
898
|
+
loader: loader23
|
|
899
|
+
};
|
|
900
|
+
var id24 = "block";
|
|
901
|
+
var detector24 = /* @__PURE__ */ __name((txt) => {
|
|
902
|
+
return /^\s*block-beta/.test(txt);
|
|
903
|
+
}, "detector");
|
|
904
|
+
var loader24 = /* @__PURE__ */ __name(async () => {
|
|
905
|
+
const { diagram: diagram2 } = await import("./blockDiagram-ZHA2E4KO-OAYYKCLF.js");
|
|
906
|
+
return { id: id24, diagram: diagram2 };
|
|
907
|
+
}, "loader");
|
|
908
|
+
var plugin21 = {
|
|
909
|
+
id: id24,
|
|
910
|
+
detector: detector24,
|
|
911
|
+
loader: loader24
|
|
912
|
+
};
|
|
913
|
+
var blockDetector_default = plugin21;
|
|
914
|
+
var id25 = "architecture";
|
|
915
|
+
var detector25 = /* @__PURE__ */ __name((txt) => {
|
|
916
|
+
return /^\s*architecture/.test(txt);
|
|
917
|
+
}, "detector");
|
|
918
|
+
var loader25 = /* @__PURE__ */ __name(async () => {
|
|
919
|
+
const { diagram: diagram2 } = await import("./architectureDiagram-UYN6MBPD-HXPGIDN7.js");
|
|
920
|
+
return { id: id25, diagram: diagram2 };
|
|
921
|
+
}, "loader");
|
|
922
|
+
var architecture = {
|
|
923
|
+
id: id25,
|
|
924
|
+
detector: detector25,
|
|
925
|
+
loader: loader25
|
|
926
|
+
};
|
|
927
|
+
var architectureDetector_default = architecture;
|
|
928
|
+
var hasLoadedDiagrams = false;
|
|
929
|
+
var addDiagrams = /* @__PURE__ */ __name(() => {
|
|
930
|
+
if (hasLoadedDiagrams) {
|
|
931
|
+
return;
|
|
932
|
+
}
|
|
933
|
+
hasLoadedDiagrams = true;
|
|
934
|
+
registerDiagram("error", errorDiagram_default, (text) => {
|
|
935
|
+
return text.toLowerCase().trim() === "error";
|
|
936
|
+
});
|
|
937
|
+
registerDiagram(
|
|
938
|
+
"---",
|
|
939
|
+
// --- diagram type may appear if YAML front-matter is not parsed correctly
|
|
940
|
+
{
|
|
941
|
+
db: {
|
|
942
|
+
clear: /* @__PURE__ */ __name(() => {
|
|
943
|
+
}, "clear")
|
|
944
|
+
},
|
|
945
|
+
styles: {},
|
|
946
|
+
// should never be used
|
|
947
|
+
renderer: {
|
|
948
|
+
draw: /* @__PURE__ */ __name(() => {
|
|
949
|
+
}, "draw")
|
|
950
|
+
},
|
|
951
|
+
parser: {
|
|
952
|
+
parse: /* @__PURE__ */ __name(() => {
|
|
953
|
+
throw new Error(
|
|
954
|
+
"Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks"
|
|
955
|
+
);
|
|
956
|
+
}, "parse")
|
|
957
|
+
},
|
|
958
|
+
init: /* @__PURE__ */ __name(() => null, "init")
|
|
959
|
+
// no op
|
|
960
|
+
},
|
|
961
|
+
(text) => {
|
|
962
|
+
return text.toLowerCase().trimStart().startsWith("---");
|
|
963
|
+
}
|
|
964
|
+
);
|
|
965
|
+
registerLazyLoadedDiagrams(
|
|
966
|
+
c4Detector_default,
|
|
967
|
+
detector_default4,
|
|
968
|
+
classDetector_V2_default,
|
|
969
|
+
classDetector_default,
|
|
970
|
+
erDetector_default,
|
|
971
|
+
ganttDetector_default,
|
|
972
|
+
info,
|
|
973
|
+
pie,
|
|
974
|
+
requirementDetector_default,
|
|
975
|
+
sequenceDetector_default,
|
|
976
|
+
detector_default,
|
|
977
|
+
flowDetector_v2_default,
|
|
978
|
+
flowDetector_default,
|
|
979
|
+
detector_default3,
|
|
980
|
+
detector_default2,
|
|
981
|
+
gitGraphDetector_default,
|
|
982
|
+
stateDetector_V2_default,
|
|
983
|
+
stateDetector_default,
|
|
984
|
+
journeyDetector_default,
|
|
985
|
+
quadrantDetector_default,
|
|
986
|
+
sankeyDetector_default,
|
|
987
|
+
packet,
|
|
988
|
+
xychartDetector_default,
|
|
989
|
+
blockDetector_default,
|
|
990
|
+
architectureDetector_default
|
|
991
|
+
);
|
|
992
|
+
}, "addDiagrams");
|
|
993
|
+
var loadRegisteredDiagrams = /* @__PURE__ */ __name(async () => {
|
|
994
|
+
log.debug(`Loading registered diagrams`);
|
|
995
|
+
const results = await Promise.allSettled(
|
|
996
|
+
Object.entries(detectors).map(async ([key, { detector: detector26, loader: loader26 }]) => {
|
|
997
|
+
if (loader26) {
|
|
998
|
+
try {
|
|
999
|
+
getDiagram(key);
|
|
1000
|
+
} catch {
|
|
1001
|
+
try {
|
|
1002
|
+
const { diagram: diagram2, id: id26 } = await loader26();
|
|
1003
|
+
registerDiagram(id26, diagram2, detector26);
|
|
1004
|
+
} catch (err) {
|
|
1005
|
+
log.error(`Failed to load external diagram with key ${key}. Removing from detectors.`);
|
|
1006
|
+
delete detectors[key];
|
|
1007
|
+
throw err;
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
})
|
|
1012
|
+
);
|
|
1013
|
+
const failed = results.filter((result) => result.status === "rejected");
|
|
1014
|
+
if (failed.length > 0) {
|
|
1015
|
+
log.error(`Failed to load ${failed.length} external diagrams`);
|
|
1016
|
+
for (const res of failed) {
|
|
1017
|
+
log.error(res);
|
|
1018
|
+
}
|
|
1019
|
+
throw new Error(`Failed to load ${failed.length} external diagrams`);
|
|
1020
|
+
}
|
|
1021
|
+
}, "loadRegisteredDiagrams");
|
|
1022
|
+
var SVG_ROLE = "graphics-document document";
|
|
1023
|
+
function setA11yDiagramInfo(svg, diagramType) {
|
|
1024
|
+
svg.attr("role", SVG_ROLE);
|
|
1025
|
+
if (diagramType !== "") {
|
|
1026
|
+
svg.attr("aria-roledescription", diagramType);
|
|
1027
|
+
}
|
|
1028
|
+
}
|
|
1029
|
+
__name(setA11yDiagramInfo, "setA11yDiagramInfo");
|
|
1030
|
+
function addSVGa11yTitleDescription(svg, a11yTitle, a11yDesc, baseId) {
|
|
1031
|
+
if (svg.insert === void 0) {
|
|
1032
|
+
return;
|
|
1033
|
+
}
|
|
1034
|
+
if (a11yDesc) {
|
|
1035
|
+
const descId = `chart-desc-${baseId}`;
|
|
1036
|
+
svg.attr("aria-describedby", descId);
|
|
1037
|
+
svg.insert("desc", ":first-child").attr("id", descId).text(a11yDesc);
|
|
1038
|
+
}
|
|
1039
|
+
if (a11yTitle) {
|
|
1040
|
+
const titleId = `chart-title-${baseId}`;
|
|
1041
|
+
svg.attr("aria-labelledby", titleId);
|
|
1042
|
+
svg.insert("title", ":first-child").attr("id", titleId).text(a11yTitle);
|
|
1043
|
+
}
|
|
1044
|
+
}
|
|
1045
|
+
__name(addSVGa11yTitleDescription, "addSVGa11yTitleDescription");
|
|
1046
|
+
var Diagram = class _Diagram {
|
|
1047
|
+
constructor(type, text, db, parser, renderer2) {
|
|
1048
|
+
this.type = type;
|
|
1049
|
+
this.text = text;
|
|
1050
|
+
this.db = db;
|
|
1051
|
+
this.parser = parser;
|
|
1052
|
+
this.renderer = renderer2;
|
|
1053
|
+
}
|
|
1054
|
+
static {
|
|
1055
|
+
__name(this, "Diagram");
|
|
1056
|
+
}
|
|
1057
|
+
static async fromText(text, metadata = {}) {
|
|
1058
|
+
const config = getConfig();
|
|
1059
|
+
const type = detectType(text, config);
|
|
1060
|
+
text = encodeEntities(text) + "\n";
|
|
1061
|
+
try {
|
|
1062
|
+
getDiagram(type);
|
|
1063
|
+
} catch {
|
|
1064
|
+
const loader26 = getDiagramLoader(type);
|
|
1065
|
+
if (!loader26) {
|
|
1066
|
+
throw new UnknownDiagramError(`Diagram ${type} not found.`);
|
|
1067
|
+
}
|
|
1068
|
+
const { id: id26, diagram: diagram2 } = await loader26();
|
|
1069
|
+
registerDiagram(id26, diagram2);
|
|
1070
|
+
}
|
|
1071
|
+
const { db, parser, renderer: renderer2, init: init2 } = getDiagram(type);
|
|
1072
|
+
if (parser.parser) {
|
|
1073
|
+
parser.parser.yy = db;
|
|
1074
|
+
}
|
|
1075
|
+
db.clear?.();
|
|
1076
|
+
init2?.(config);
|
|
1077
|
+
if (metadata.title) {
|
|
1078
|
+
db.setDiagramTitle?.(metadata.title);
|
|
1079
|
+
}
|
|
1080
|
+
await parser.parse(text);
|
|
1081
|
+
return new _Diagram(type, text, db, parser, renderer2);
|
|
1082
|
+
}
|
|
1083
|
+
async render(id26, version2) {
|
|
1084
|
+
await this.renderer.draw(this.text, id26, version2, this);
|
|
1085
|
+
}
|
|
1086
|
+
getParser() {
|
|
1087
|
+
return this.parser;
|
|
1088
|
+
}
|
|
1089
|
+
getType() {
|
|
1090
|
+
return this.type;
|
|
1091
|
+
}
|
|
1092
|
+
};
|
|
1093
|
+
var interactionFunctions = [];
|
|
1094
|
+
var attachFunctions = /* @__PURE__ */ __name(() => {
|
|
1095
|
+
interactionFunctions.forEach((f) => {
|
|
1096
|
+
f();
|
|
1097
|
+
});
|
|
1098
|
+
interactionFunctions = [];
|
|
1099
|
+
}, "attachFunctions");
|
|
1100
|
+
var cleanupComments = /* @__PURE__ */ __name((text) => {
|
|
1101
|
+
return text.replace(/^\s*%%(?!{)[^\n]+\n?/gm, "").trimStart();
|
|
1102
|
+
}, "cleanupComments");
|
|
1103
|
+
function extractFrontMatter(text) {
|
|
1104
|
+
const matches = text.match(frontMatterRegex);
|
|
1105
|
+
if (!matches) {
|
|
1106
|
+
return {
|
|
1107
|
+
text,
|
|
1108
|
+
metadata: {}
|
|
1109
|
+
};
|
|
1110
|
+
}
|
|
1111
|
+
let parsed = load(matches[1], {
|
|
1112
|
+
// To support config, we need JSON schema.
|
|
1113
|
+
// https://www.yaml.org/spec/1.2/spec.html#id2803231
|
|
1114
|
+
schema: JSON_SCHEMA
|
|
1115
|
+
}) ?? {};
|
|
1116
|
+
parsed = typeof parsed === "object" && !Array.isArray(parsed) ? parsed : {};
|
|
1117
|
+
const metadata = {};
|
|
1118
|
+
if (parsed.displayMode) {
|
|
1119
|
+
metadata.displayMode = parsed.displayMode.toString();
|
|
1120
|
+
}
|
|
1121
|
+
if (parsed.title) {
|
|
1122
|
+
metadata.title = parsed.title.toString();
|
|
1123
|
+
}
|
|
1124
|
+
if (parsed.config) {
|
|
1125
|
+
metadata.config = parsed.config;
|
|
1126
|
+
}
|
|
1127
|
+
return {
|
|
1128
|
+
text: text.slice(matches[0].length),
|
|
1129
|
+
metadata
|
|
1130
|
+
};
|
|
1131
|
+
}
|
|
1132
|
+
__name(extractFrontMatter, "extractFrontMatter");
|
|
1133
|
+
var cleanupText = /* @__PURE__ */ __name((code) => {
|
|
1134
|
+
return code.replace(/\r\n?/g, "\n").replace(
|
|
1135
|
+
/<(\w+)([^>]*)>/g,
|
|
1136
|
+
(match, tag, attributes) => "<" + tag + attributes.replace(/="([^"]*)"/g, "='$1'") + ">"
|
|
1137
|
+
);
|
|
1138
|
+
}, "cleanupText");
|
|
1139
|
+
var processFrontmatter = /* @__PURE__ */ __name((code) => {
|
|
1140
|
+
const { text, metadata } = extractFrontMatter(code);
|
|
1141
|
+
const { displayMode, title, config = {} } = metadata;
|
|
1142
|
+
if (displayMode) {
|
|
1143
|
+
if (!config.gantt) {
|
|
1144
|
+
config.gantt = {};
|
|
1145
|
+
}
|
|
1146
|
+
config.gantt.displayMode = displayMode;
|
|
1147
|
+
}
|
|
1148
|
+
return { title, config, text };
|
|
1149
|
+
}, "processFrontmatter");
|
|
1150
|
+
var processDirectives = /* @__PURE__ */ __name((code) => {
|
|
1151
|
+
const initDirective = utils_default.detectInit(code) ?? {};
|
|
1152
|
+
const wrapDirectives = utils_default.detectDirective(code, "wrap");
|
|
1153
|
+
if (Array.isArray(wrapDirectives)) {
|
|
1154
|
+
initDirective.wrap = wrapDirectives.some(({ type }) => type === "wrap");
|
|
1155
|
+
} else if (wrapDirectives?.type === "wrap") {
|
|
1156
|
+
initDirective.wrap = true;
|
|
1157
|
+
}
|
|
1158
|
+
return {
|
|
1159
|
+
text: removeDirectives(code),
|
|
1160
|
+
directive: initDirective
|
|
1161
|
+
};
|
|
1162
|
+
}, "processDirectives");
|
|
1163
|
+
function preprocessDiagram(code) {
|
|
1164
|
+
const cleanedCode = cleanupText(code);
|
|
1165
|
+
const frontMatterResult = processFrontmatter(cleanedCode);
|
|
1166
|
+
const directiveResult = processDirectives(frontMatterResult.text);
|
|
1167
|
+
const config = cleanAndMerge(frontMatterResult.config, directiveResult.directive);
|
|
1168
|
+
code = cleanupComments(directiveResult.text);
|
|
1169
|
+
return {
|
|
1170
|
+
code,
|
|
1171
|
+
title: frontMatterResult.title,
|
|
1172
|
+
config
|
|
1173
|
+
};
|
|
1174
|
+
}
|
|
1175
|
+
__name(preprocessDiagram, "preprocessDiagram");
|
|
1176
|
+
function toBase64(str) {
|
|
1177
|
+
const utf8Bytes = new TextEncoder().encode(str);
|
|
1178
|
+
const utf8Str = Array.from(utf8Bytes, (byte) => String.fromCodePoint(byte)).join("");
|
|
1179
|
+
return btoa(utf8Str);
|
|
1180
|
+
}
|
|
1181
|
+
__name(toBase64, "toBase64");
|
|
1182
|
+
var MAX_TEXTLENGTH = 5e4;
|
|
1183
|
+
var MAX_TEXTLENGTH_EXCEEDED_MSG = "graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa";
|
|
1184
|
+
var SECURITY_LVL_SANDBOX = "sandbox";
|
|
1185
|
+
var SECURITY_LVL_LOOSE = "loose";
|
|
1186
|
+
var XMLNS_SVG_STD = "http://www.w3.org/2000/svg";
|
|
1187
|
+
var XMLNS_XLINK_STD = "http://www.w3.org/1999/xlink";
|
|
1188
|
+
var XMLNS_XHTML_STD = "http://www.w3.org/1999/xhtml";
|
|
1189
|
+
var IFRAME_WIDTH = "100%";
|
|
1190
|
+
var IFRAME_HEIGHT = "100%";
|
|
1191
|
+
var IFRAME_STYLES = "border:0;margin:0;";
|
|
1192
|
+
var IFRAME_BODY_STYLE = "margin:0";
|
|
1193
|
+
var IFRAME_SANDBOX_OPTS = "allow-top-navigation-by-user-activation allow-popups";
|
|
1194
|
+
var IFRAME_NOT_SUPPORTED_MSG = 'The "iframe" tag is not supported by your browser.';
|
|
1195
|
+
var DOMPURIFY_TAGS = ["foreignobject"];
|
|
1196
|
+
var DOMPURIFY_ATTR = ["dominant-baseline"];
|
|
1197
|
+
function processAndSetConfigs(text) {
|
|
1198
|
+
const processed = preprocessDiagram(text);
|
|
1199
|
+
reset();
|
|
1200
|
+
addDirective(processed.config ?? {});
|
|
1201
|
+
return processed;
|
|
1202
|
+
}
|
|
1203
|
+
__name(processAndSetConfigs, "processAndSetConfigs");
|
|
1204
|
+
async function parse3(text, parseOptions) {
|
|
1205
|
+
addDiagrams();
|
|
1206
|
+
try {
|
|
1207
|
+
const { code, config } = processAndSetConfigs(text);
|
|
1208
|
+
const diagram2 = await getDiagramFromText(code);
|
|
1209
|
+
return { diagramType: diagram2.type, config };
|
|
1210
|
+
} catch (error) {
|
|
1211
|
+
if (parseOptions?.suppressErrors) {
|
|
1212
|
+
return false;
|
|
1213
|
+
}
|
|
1214
|
+
throw error;
|
|
1215
|
+
}
|
|
1216
|
+
}
|
|
1217
|
+
__name(parse3, "parse");
|
|
1218
|
+
var cssImportantStyles = /* @__PURE__ */ __name((cssClass, element, cssClasses = []) => {
|
|
1219
|
+
return `
|
|
1220
|
+
.${cssClass} ${element} { ${cssClasses.join(" !important; ")} !important; }`;
|
|
1221
|
+
}, "cssImportantStyles");
|
|
1222
|
+
var createCssStyles = /* @__PURE__ */ __name((config, classDefs = /* @__PURE__ */ new Map()) => {
|
|
1223
|
+
let cssStyles = "";
|
|
1224
|
+
if (config.themeCSS !== void 0) {
|
|
1225
|
+
cssStyles += `
|
|
1226
|
+
${config.themeCSS}`;
|
|
1227
|
+
}
|
|
1228
|
+
if (config.fontFamily !== void 0) {
|
|
1229
|
+
cssStyles += `
|
|
1230
|
+
:root { --mermaid-font-family: ${config.fontFamily}}`;
|
|
1231
|
+
}
|
|
1232
|
+
if (config.altFontFamily !== void 0) {
|
|
1233
|
+
cssStyles += `
|
|
1234
|
+
:root { --mermaid-alt-font-family: ${config.altFontFamily}}`;
|
|
1235
|
+
}
|
|
1236
|
+
if (classDefs instanceof Map) {
|
|
1237
|
+
const htmlLabels = config.htmlLabels ?? config.flowchart?.htmlLabels;
|
|
1238
|
+
const cssHtmlElements = ["> *", "span"];
|
|
1239
|
+
const cssShapeElements = ["rect", "polygon", "ellipse", "circle", "path"];
|
|
1240
|
+
const cssElements = htmlLabels ? cssHtmlElements : cssShapeElements;
|
|
1241
|
+
classDefs.forEach((styleClassDef) => {
|
|
1242
|
+
if (!isEmpty_default(styleClassDef.styles)) {
|
|
1243
|
+
cssElements.forEach((cssElement) => {
|
|
1244
|
+
cssStyles += cssImportantStyles(styleClassDef.id, cssElement, styleClassDef.styles);
|
|
1245
|
+
});
|
|
1246
|
+
}
|
|
1247
|
+
if (!isEmpty_default(styleClassDef.textStyles)) {
|
|
1248
|
+
cssStyles += cssImportantStyles(
|
|
1249
|
+
styleClassDef.id,
|
|
1250
|
+
"tspan",
|
|
1251
|
+
(styleClassDef?.textStyles || []).map((s) => s.replace("color", "fill"))
|
|
1252
|
+
);
|
|
1253
|
+
}
|
|
1254
|
+
});
|
|
1255
|
+
}
|
|
1256
|
+
return cssStyles;
|
|
1257
|
+
}, "createCssStyles");
|
|
1258
|
+
var createUserStyles = /* @__PURE__ */ __name((config, graphType, classDefs, svgId) => {
|
|
1259
|
+
const userCSSstyles = createCssStyles(config, classDefs);
|
|
1260
|
+
const allStyles = styles_default(graphType, userCSSstyles, config.themeVariables);
|
|
1261
|
+
return serialize(compile(`${svgId}{${allStyles}}`), stringify);
|
|
1262
|
+
}, "createUserStyles");
|
|
1263
|
+
var cleanUpSvgCode = /* @__PURE__ */ __name((svgCode = "", inSandboxMode, useArrowMarkerUrls) => {
|
|
1264
|
+
let cleanedUpSvg = svgCode;
|
|
1265
|
+
if (!useArrowMarkerUrls && !inSandboxMode) {
|
|
1266
|
+
cleanedUpSvg = cleanedUpSvg.replace(
|
|
1267
|
+
/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,
|
|
1268
|
+
'marker-end="url(#'
|
|
1269
|
+
);
|
|
1270
|
+
}
|
|
1271
|
+
cleanedUpSvg = decodeEntities(cleanedUpSvg);
|
|
1272
|
+
cleanedUpSvg = cleanedUpSvg.replace(/<br>/g, "<br/>");
|
|
1273
|
+
return cleanedUpSvg;
|
|
1274
|
+
}, "cleanUpSvgCode");
|
|
1275
|
+
var putIntoIFrame = /* @__PURE__ */ __name((svgCode = "", svgElement) => {
|
|
1276
|
+
const height = svgElement?.viewBox?.baseVal?.height ? svgElement.viewBox.baseVal.height + "px" : IFRAME_HEIGHT;
|
|
1277
|
+
const base64encodedSrc = toBase64(`<body style="${IFRAME_BODY_STYLE}">${svgCode}</body>`);
|
|
1278
|
+
return `<iframe style="width:${IFRAME_WIDTH};height:${height};${IFRAME_STYLES}" src="data:text/html;charset=UTF-8;base64,${base64encodedSrc}" sandbox="${IFRAME_SANDBOX_OPTS}">
|
|
1279
|
+
${IFRAME_NOT_SUPPORTED_MSG}
|
|
1280
|
+
</iframe>`;
|
|
1281
|
+
}, "putIntoIFrame");
|
|
1282
|
+
var appendDivSvgG = /* @__PURE__ */ __name((parentRoot, id26, enclosingDivId, divStyle, svgXlink) => {
|
|
1283
|
+
const enclosingDiv = parentRoot.append("div");
|
|
1284
|
+
enclosingDiv.attr("id", enclosingDivId);
|
|
1285
|
+
if (divStyle) {
|
|
1286
|
+
enclosingDiv.attr("style", divStyle);
|
|
1287
|
+
}
|
|
1288
|
+
const svgNode = enclosingDiv.append("svg").attr("id", id26).attr("width", "100%").attr("xmlns", XMLNS_SVG_STD);
|
|
1289
|
+
if (svgXlink) {
|
|
1290
|
+
svgNode.attr("xmlns:xlink", svgXlink);
|
|
1291
|
+
}
|
|
1292
|
+
svgNode.append("g");
|
|
1293
|
+
return parentRoot;
|
|
1294
|
+
}, "appendDivSvgG");
|
|
1295
|
+
function sandboxedIframe(parentNode, iFrameId) {
|
|
1296
|
+
return parentNode.append("iframe").attr("id", iFrameId).attr("style", "width: 100%; height: 100%;").attr("sandbox", "");
|
|
1297
|
+
}
|
|
1298
|
+
__name(sandboxedIframe, "sandboxedIframe");
|
|
1299
|
+
var removeExistingElements = /* @__PURE__ */ __name((doc, id26, divId, iFrameId) => {
|
|
1300
|
+
doc.getElementById(id26)?.remove();
|
|
1301
|
+
doc.getElementById(divId)?.remove();
|
|
1302
|
+
doc.getElementById(iFrameId)?.remove();
|
|
1303
|
+
}, "removeExistingElements");
|
|
1304
|
+
var render = /* @__PURE__ */ __name(async function(id26, text, svgContainingElement) {
|
|
1305
|
+
addDiagrams();
|
|
1306
|
+
const processed = processAndSetConfigs(text);
|
|
1307
|
+
text = processed.code;
|
|
1308
|
+
const config = getConfig();
|
|
1309
|
+
log.debug(config);
|
|
1310
|
+
if (text.length > (config?.maxTextSize ?? MAX_TEXTLENGTH)) {
|
|
1311
|
+
text = MAX_TEXTLENGTH_EXCEEDED_MSG;
|
|
1312
|
+
}
|
|
1313
|
+
const idSelector = "#" + id26;
|
|
1314
|
+
const iFrameID = "i" + id26;
|
|
1315
|
+
const iFrameID_selector = "#" + iFrameID;
|
|
1316
|
+
const enclosingDivID = "d" + id26;
|
|
1317
|
+
const enclosingDivID_selector = "#" + enclosingDivID;
|
|
1318
|
+
const removeTempElements = /* @__PURE__ */ __name(() => {
|
|
1319
|
+
const tmpElementSelector = isSandboxed ? iFrameID_selector : enclosingDivID_selector;
|
|
1320
|
+
const node2 = select_default(tmpElementSelector).node();
|
|
1321
|
+
if (node2 && "remove" in node2) {
|
|
1322
|
+
node2.remove();
|
|
1323
|
+
}
|
|
1324
|
+
}, "removeTempElements");
|
|
1325
|
+
let root = select_default("body");
|
|
1326
|
+
const isSandboxed = config.securityLevel === SECURITY_LVL_SANDBOX;
|
|
1327
|
+
const isLooseSecurityLevel = config.securityLevel === SECURITY_LVL_LOOSE;
|
|
1328
|
+
const fontFamily = config.fontFamily;
|
|
1329
|
+
if (svgContainingElement !== void 0) {
|
|
1330
|
+
if (svgContainingElement) {
|
|
1331
|
+
svgContainingElement.innerHTML = "";
|
|
1332
|
+
}
|
|
1333
|
+
if (isSandboxed) {
|
|
1334
|
+
const iframe = sandboxedIframe(select_default(svgContainingElement), iFrameID);
|
|
1335
|
+
root = select_default(iframe.nodes()[0].contentDocument.body);
|
|
1336
|
+
root.node().style.margin = 0;
|
|
1337
|
+
} else {
|
|
1338
|
+
root = select_default(svgContainingElement);
|
|
1339
|
+
}
|
|
1340
|
+
appendDivSvgG(root, id26, enclosingDivID, `font-family: ${fontFamily}`, XMLNS_XLINK_STD);
|
|
1341
|
+
} else {
|
|
1342
|
+
removeExistingElements(document, id26, enclosingDivID, iFrameID);
|
|
1343
|
+
if (isSandboxed) {
|
|
1344
|
+
const iframe = sandboxedIframe(select_default("body"), iFrameID);
|
|
1345
|
+
root = select_default(iframe.nodes()[0].contentDocument.body);
|
|
1346
|
+
root.node().style.margin = 0;
|
|
1347
|
+
} else {
|
|
1348
|
+
root = select_default("body");
|
|
1349
|
+
}
|
|
1350
|
+
appendDivSvgG(root, id26, enclosingDivID);
|
|
1351
|
+
}
|
|
1352
|
+
let diag;
|
|
1353
|
+
let parseEncounteredException;
|
|
1354
|
+
try {
|
|
1355
|
+
diag = await Diagram.fromText(text, { title: processed.title });
|
|
1356
|
+
} catch (error) {
|
|
1357
|
+
if (config.suppressErrorRendering) {
|
|
1358
|
+
removeTempElements();
|
|
1359
|
+
throw error;
|
|
1360
|
+
}
|
|
1361
|
+
diag = await Diagram.fromText("error");
|
|
1362
|
+
parseEncounteredException = error;
|
|
1363
|
+
}
|
|
1364
|
+
const element = root.select(enclosingDivID_selector).node();
|
|
1365
|
+
const diagramType = diag.type;
|
|
1366
|
+
const svg = element.firstChild;
|
|
1367
|
+
const firstChild = svg.firstChild;
|
|
1368
|
+
const diagramClassDefs = diag.renderer.getClasses?.(text, diag);
|
|
1369
|
+
const rules = createUserStyles(config, diagramType, diagramClassDefs, idSelector);
|
|
1370
|
+
const style1 = document.createElement("style");
|
|
1371
|
+
style1.innerHTML = rules;
|
|
1372
|
+
svg.insertBefore(style1, firstChild);
|
|
1373
|
+
try {
|
|
1374
|
+
await diag.renderer.draw(text, id26, version, diag);
|
|
1375
|
+
} catch (e) {
|
|
1376
|
+
if (config.suppressErrorRendering) {
|
|
1377
|
+
removeTempElements();
|
|
1378
|
+
} else {
|
|
1379
|
+
errorRenderer_default.draw(text, id26, version);
|
|
1380
|
+
}
|
|
1381
|
+
throw e;
|
|
1382
|
+
}
|
|
1383
|
+
const svgNode = root.select(`${enclosingDivID_selector} svg`);
|
|
1384
|
+
const a11yTitle = diag.db.getAccTitle?.();
|
|
1385
|
+
const a11yDescr = diag.db.getAccDescription?.();
|
|
1386
|
+
addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr);
|
|
1387
|
+
root.select(`[id="${id26}"]`).selectAll("foreignobject > *").attr("xmlns", XMLNS_XHTML_STD);
|
|
1388
|
+
let svgCode = root.select(enclosingDivID_selector).node().innerHTML;
|
|
1389
|
+
log.debug("config.arrowMarkerAbsolute", config.arrowMarkerAbsolute);
|
|
1390
|
+
svgCode = cleanUpSvgCode(svgCode, isSandboxed, evaluate(config.arrowMarkerAbsolute));
|
|
1391
|
+
if (isSandboxed) {
|
|
1392
|
+
const svgEl = root.select(enclosingDivID_selector + " svg").node();
|
|
1393
|
+
svgCode = putIntoIFrame(svgCode, svgEl);
|
|
1394
|
+
} else if (!isLooseSecurityLevel) {
|
|
1395
|
+
svgCode = purify.sanitize(svgCode, {
|
|
1396
|
+
ADD_TAGS: DOMPURIFY_TAGS,
|
|
1397
|
+
ADD_ATTR: DOMPURIFY_ATTR,
|
|
1398
|
+
HTML_INTEGRATION_POINTS: { foreignobject: true }
|
|
1399
|
+
});
|
|
1400
|
+
}
|
|
1401
|
+
attachFunctions();
|
|
1402
|
+
if (parseEncounteredException) {
|
|
1403
|
+
throw parseEncounteredException;
|
|
1404
|
+
}
|
|
1405
|
+
removeTempElements();
|
|
1406
|
+
return {
|
|
1407
|
+
diagramType,
|
|
1408
|
+
svg: svgCode,
|
|
1409
|
+
bindFunctions: diag.db.bindFunctions
|
|
1410
|
+
};
|
|
1411
|
+
}, "render");
|
|
1412
|
+
function initialize(userOptions = {}) {
|
|
1413
|
+
const options = assignWithDepth_default({}, userOptions);
|
|
1414
|
+
if (options?.fontFamily && !options.themeVariables?.fontFamily) {
|
|
1415
|
+
if (!options.themeVariables) {
|
|
1416
|
+
options.themeVariables = {};
|
|
1417
|
+
}
|
|
1418
|
+
options.themeVariables.fontFamily = options.fontFamily;
|
|
1419
|
+
}
|
|
1420
|
+
saveConfigFromInitialize(options);
|
|
1421
|
+
if (options?.theme && options.theme in themes_default) {
|
|
1422
|
+
options.themeVariables = themes_default[options.theme].getThemeVariables(
|
|
1423
|
+
options.themeVariables
|
|
1424
|
+
);
|
|
1425
|
+
} else if (options) {
|
|
1426
|
+
options.themeVariables = themes_default.default.getThemeVariables(options.themeVariables);
|
|
1427
|
+
}
|
|
1428
|
+
const config = typeof options === "object" ? setSiteConfig(options) : getSiteConfig();
|
|
1429
|
+
setLogLevel(config.logLevel);
|
|
1430
|
+
addDiagrams();
|
|
1431
|
+
}
|
|
1432
|
+
__name(initialize, "initialize");
|
|
1433
|
+
var getDiagramFromText = /* @__PURE__ */ __name((text, metadata = {}) => {
|
|
1434
|
+
const { code } = preprocessDiagram(text);
|
|
1435
|
+
return Diagram.fromText(code, metadata);
|
|
1436
|
+
}, "getDiagramFromText");
|
|
1437
|
+
function addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr) {
|
|
1438
|
+
setA11yDiagramInfo(svgNode, diagramType);
|
|
1439
|
+
addSVGa11yTitleDescription(svgNode, a11yTitle, a11yDescr, svgNode.attr("id"));
|
|
1440
|
+
}
|
|
1441
|
+
__name(addA11yInfo, "addA11yInfo");
|
|
1442
|
+
var mermaidAPI = Object.freeze({
|
|
1443
|
+
render,
|
|
1444
|
+
parse: parse3,
|
|
1445
|
+
getDiagramFromText,
|
|
1446
|
+
initialize,
|
|
1447
|
+
getConfig,
|
|
1448
|
+
setConfig,
|
|
1449
|
+
getSiteConfig,
|
|
1450
|
+
updateSiteConfig,
|
|
1451
|
+
reset: /* @__PURE__ */ __name(() => {
|
|
1452
|
+
reset();
|
|
1453
|
+
}, "reset"),
|
|
1454
|
+
globalReset: /* @__PURE__ */ __name(() => {
|
|
1455
|
+
reset(defaultConfig);
|
|
1456
|
+
}, "globalReset"),
|
|
1457
|
+
defaultConfig
|
|
1458
|
+
});
|
|
1459
|
+
setLogLevel(getConfig().logLevel);
|
|
1460
|
+
reset(getConfig());
|
|
1461
|
+
var handleError = /* @__PURE__ */ __name((error, errors, parseError) => {
|
|
1462
|
+
log.warn(error);
|
|
1463
|
+
if (isDetailedError(error)) {
|
|
1464
|
+
if (parseError) {
|
|
1465
|
+
parseError(error.str, error.hash);
|
|
1466
|
+
}
|
|
1467
|
+
errors.push({ ...error, message: error.str, error });
|
|
1468
|
+
} else {
|
|
1469
|
+
if (parseError) {
|
|
1470
|
+
parseError(error);
|
|
1471
|
+
}
|
|
1472
|
+
if (error instanceof Error) {
|
|
1473
|
+
errors.push({
|
|
1474
|
+
str: error.message,
|
|
1475
|
+
message: error.message,
|
|
1476
|
+
hash: error.name,
|
|
1477
|
+
error
|
|
1478
|
+
});
|
|
1479
|
+
}
|
|
1480
|
+
}
|
|
1481
|
+
}, "handleError");
|
|
1482
|
+
var run = /* @__PURE__ */ __name(async function(options = {
|
|
1483
|
+
querySelector: ".mermaid"
|
|
1484
|
+
}) {
|
|
1485
|
+
try {
|
|
1486
|
+
await runThrowsErrors(options);
|
|
1487
|
+
} catch (e) {
|
|
1488
|
+
if (isDetailedError(e)) {
|
|
1489
|
+
log.error(e.str);
|
|
1490
|
+
}
|
|
1491
|
+
if (mermaid.parseError) {
|
|
1492
|
+
mermaid.parseError(e);
|
|
1493
|
+
}
|
|
1494
|
+
if (!options.suppressErrors) {
|
|
1495
|
+
log.error("Use the suppressErrors option to suppress these errors");
|
|
1496
|
+
throw e;
|
|
1497
|
+
}
|
|
1498
|
+
}
|
|
1499
|
+
}, "run");
|
|
1500
|
+
var runThrowsErrors = /* @__PURE__ */ __name(async function({ postRenderCallback, querySelector, nodes } = {
|
|
1501
|
+
querySelector: ".mermaid"
|
|
1502
|
+
}) {
|
|
1503
|
+
const conf = mermaidAPI.getConfig();
|
|
1504
|
+
log.debug(`${!postRenderCallback ? "No " : ""}Callback function found`);
|
|
1505
|
+
let nodesToProcess;
|
|
1506
|
+
if (nodes) {
|
|
1507
|
+
nodesToProcess = nodes;
|
|
1508
|
+
} else if (querySelector) {
|
|
1509
|
+
nodesToProcess = document.querySelectorAll(querySelector);
|
|
1510
|
+
} else {
|
|
1511
|
+
throw new Error("Nodes and querySelector are both undefined");
|
|
1512
|
+
}
|
|
1513
|
+
log.debug(`Found ${nodesToProcess.length} diagrams`);
|
|
1514
|
+
if (conf?.startOnLoad !== void 0) {
|
|
1515
|
+
log.debug("Start On Load: " + conf?.startOnLoad);
|
|
1516
|
+
mermaidAPI.updateSiteConfig({ startOnLoad: conf?.startOnLoad });
|
|
1517
|
+
}
|
|
1518
|
+
const idGenerator = new utils_default.InitIDGenerator(conf.deterministicIds, conf.deterministicIDSeed);
|
|
1519
|
+
let txt;
|
|
1520
|
+
const errors = [];
|
|
1521
|
+
for (const element of Array.from(nodesToProcess)) {
|
|
1522
|
+
log.info("Rendering diagram: " + element.id);
|
|
1523
|
+
if (element.getAttribute("data-processed")) {
|
|
1524
|
+
continue;
|
|
1525
|
+
}
|
|
1526
|
+
element.setAttribute("data-processed", "true");
|
|
1527
|
+
const id26 = `mermaid-${idGenerator.next()}`;
|
|
1528
|
+
txt = element.innerHTML;
|
|
1529
|
+
txt = dedent(utils_default.entityDecode(txt)).trim().replace(/<br\s*\/?>/gi, "<br/>");
|
|
1530
|
+
const init2 = utils_default.detectInit(txt);
|
|
1531
|
+
if (init2) {
|
|
1532
|
+
log.debug("Detected early reinit: ", init2);
|
|
1533
|
+
}
|
|
1534
|
+
try {
|
|
1535
|
+
const { svg, bindFunctions } = await render2(id26, txt, element);
|
|
1536
|
+
element.innerHTML = svg;
|
|
1537
|
+
if (postRenderCallback) {
|
|
1538
|
+
await postRenderCallback(id26);
|
|
1539
|
+
}
|
|
1540
|
+
if (bindFunctions) {
|
|
1541
|
+
bindFunctions(element);
|
|
1542
|
+
}
|
|
1543
|
+
} catch (error) {
|
|
1544
|
+
handleError(error, errors, mermaid.parseError);
|
|
1545
|
+
}
|
|
1546
|
+
}
|
|
1547
|
+
if (errors.length > 0) {
|
|
1548
|
+
throw errors[0];
|
|
1549
|
+
}
|
|
1550
|
+
}, "runThrowsErrors");
|
|
1551
|
+
var initialize2 = /* @__PURE__ */ __name(function(config) {
|
|
1552
|
+
mermaidAPI.initialize(config);
|
|
1553
|
+
}, "initialize");
|
|
1554
|
+
var init = /* @__PURE__ */ __name(async function(config, nodes, callback) {
|
|
1555
|
+
log.warn("mermaid.init is deprecated. Please use run instead.");
|
|
1556
|
+
if (config) {
|
|
1557
|
+
initialize2(config);
|
|
1558
|
+
}
|
|
1559
|
+
const runOptions = { postRenderCallback: callback, querySelector: ".mermaid" };
|
|
1560
|
+
if (typeof nodes === "string") {
|
|
1561
|
+
runOptions.querySelector = nodes;
|
|
1562
|
+
} else if (nodes) {
|
|
1563
|
+
if (nodes instanceof HTMLElement) {
|
|
1564
|
+
runOptions.nodes = [nodes];
|
|
1565
|
+
} else {
|
|
1566
|
+
runOptions.nodes = nodes;
|
|
1567
|
+
}
|
|
1568
|
+
}
|
|
1569
|
+
await run(runOptions);
|
|
1570
|
+
}, "init");
|
|
1571
|
+
var registerExternalDiagrams = /* @__PURE__ */ __name(async (diagrams, {
|
|
1572
|
+
lazyLoad = true
|
|
1573
|
+
} = {}) => {
|
|
1574
|
+
addDiagrams();
|
|
1575
|
+
registerLazyLoadedDiagrams(...diagrams);
|
|
1576
|
+
if (lazyLoad === false) {
|
|
1577
|
+
await loadRegisteredDiagrams();
|
|
1578
|
+
}
|
|
1579
|
+
}, "registerExternalDiagrams");
|
|
1580
|
+
var contentLoaded = /* @__PURE__ */ __name(function() {
|
|
1581
|
+
if (mermaid.startOnLoad) {
|
|
1582
|
+
const { startOnLoad } = mermaidAPI.getConfig();
|
|
1583
|
+
if (startOnLoad) {
|
|
1584
|
+
mermaid.run().catch((err) => log.error("Mermaid failed to initialize", err));
|
|
1585
|
+
}
|
|
1586
|
+
}
|
|
1587
|
+
}, "contentLoaded");
|
|
1588
|
+
if (typeof document !== "undefined") {
|
|
1589
|
+
window.addEventListener("load", contentLoaded, false);
|
|
1590
|
+
}
|
|
1591
|
+
var setParseErrorHandler = /* @__PURE__ */ __name(function(parseErrorHandler) {
|
|
1592
|
+
mermaid.parseError = parseErrorHandler;
|
|
1593
|
+
}, "setParseErrorHandler");
|
|
1594
|
+
var executionQueue = [];
|
|
1595
|
+
var executionQueueRunning = false;
|
|
1596
|
+
var executeQueue = /* @__PURE__ */ __name(async () => {
|
|
1597
|
+
if (executionQueueRunning) {
|
|
1598
|
+
return;
|
|
1599
|
+
}
|
|
1600
|
+
executionQueueRunning = true;
|
|
1601
|
+
while (executionQueue.length > 0) {
|
|
1602
|
+
const f = executionQueue.shift();
|
|
1603
|
+
if (f) {
|
|
1604
|
+
try {
|
|
1605
|
+
await f();
|
|
1606
|
+
} catch (e) {
|
|
1607
|
+
log.error("Error executing queue", e);
|
|
1608
|
+
}
|
|
1609
|
+
}
|
|
1610
|
+
}
|
|
1611
|
+
executionQueueRunning = false;
|
|
1612
|
+
}, "executeQueue");
|
|
1613
|
+
var parse22 = /* @__PURE__ */ __name(async (text, parseOptions) => {
|
|
1614
|
+
return new Promise((resolve, reject) => {
|
|
1615
|
+
const performCall = /* @__PURE__ */ __name(() => new Promise((res, rej) => {
|
|
1616
|
+
mermaidAPI.parse(text, parseOptions).then(
|
|
1617
|
+
(r) => {
|
|
1618
|
+
res(r);
|
|
1619
|
+
resolve(r);
|
|
1620
|
+
},
|
|
1621
|
+
(e) => {
|
|
1622
|
+
log.error("Error parsing", e);
|
|
1623
|
+
mermaid.parseError?.(e);
|
|
1624
|
+
rej(e);
|
|
1625
|
+
reject(e);
|
|
1626
|
+
}
|
|
1627
|
+
);
|
|
1628
|
+
}), "performCall");
|
|
1629
|
+
executionQueue.push(performCall);
|
|
1630
|
+
executeQueue().catch(reject);
|
|
1631
|
+
});
|
|
1632
|
+
}, "parse");
|
|
1633
|
+
var render2 = /* @__PURE__ */ __name((id26, text, container) => {
|
|
1634
|
+
return new Promise((resolve, reject) => {
|
|
1635
|
+
const performCall = /* @__PURE__ */ __name(() => new Promise((res, rej) => {
|
|
1636
|
+
mermaidAPI.render(id26, text, container).then(
|
|
1637
|
+
(r) => {
|
|
1638
|
+
res(r);
|
|
1639
|
+
resolve(r);
|
|
1640
|
+
},
|
|
1641
|
+
(e) => {
|
|
1642
|
+
log.error("Error parsing", e);
|
|
1643
|
+
mermaid.parseError?.(e);
|
|
1644
|
+
rej(e);
|
|
1645
|
+
reject(e);
|
|
1646
|
+
}
|
|
1647
|
+
);
|
|
1648
|
+
}), "performCall");
|
|
1649
|
+
executionQueue.push(performCall);
|
|
1650
|
+
executeQueue().catch(reject);
|
|
1651
|
+
});
|
|
1652
|
+
}, "render");
|
|
1653
|
+
var mermaid = {
|
|
1654
|
+
startOnLoad: true,
|
|
1655
|
+
mermaidAPI,
|
|
1656
|
+
parse: parse22,
|
|
1657
|
+
render: render2,
|
|
1658
|
+
init,
|
|
1659
|
+
run,
|
|
1660
|
+
registerExternalDiagrams,
|
|
1661
|
+
registerLayoutLoaders,
|
|
1662
|
+
initialize: initialize2,
|
|
1663
|
+
parseError: void 0,
|
|
1664
|
+
contentLoaded,
|
|
1665
|
+
setParseErrorHandler,
|
|
1666
|
+
detectType,
|
|
1667
|
+
registerIconPacks
|
|
1668
|
+
};
|
|
1669
|
+
var mermaid_default = mermaid;
|
|
1670
|
+
|
|
1671
|
+
// components/src/asciidoc/Mermaid.tsx
|
|
1672
|
+
import { memo, useId, useState } from "react";
|
|
1673
|
+
import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
1674
|
+
mermaid_default.initialize({
|
|
1675
|
+
startOnLoad: false,
|
|
1676
|
+
theme: "dark"
|
|
1677
|
+
});
|
|
1678
|
+
var Mermaid = memo(function Mermaid2({ content }) {
|
|
1679
|
+
const [showSource, setShowSource] = useState(false);
|
|
1680
|
+
const id26 = `mermaid-diagram-${useId().replace(/:/g, "_")}`;
|
|
1681
|
+
const mermaidRef = async (node2) => {
|
|
1682
|
+
if (node2) {
|
|
1683
|
+
const { svg } = await mermaid_default.render(id26, content);
|
|
1684
|
+
node2.innerHTML = svg;
|
|
1685
|
+
}
|
|
1686
|
+
};
|
|
1687
|
+
return /* @__PURE__ */ jsxs2(Fragment, { children: [
|
|
1688
|
+
/* @__PURE__ */ jsxs2(
|
|
1689
|
+
"button",
|
|
1690
|
+
{
|
|
1691
|
+
className: "absolute right-2 top-2 text-mono-xs text-tertiary",
|
|
1692
|
+
onClick: () => setShowSource(!showSource),
|
|
1693
|
+
children: [
|
|
1694
|
+
showSource ? "Hide" : "Show",
|
|
1695
|
+
" Source ",
|
|
1696
|
+
/* @__PURE__ */ jsx2("span", { className: "text-quinary", children: "|" }),
|
|
1697
|
+
" ",
|
|
1698
|
+
"Mermaid"
|
|
1699
|
+
]
|
|
1700
|
+
}
|
|
1701
|
+
),
|
|
1702
|
+
!showSource ? /* @__PURE__ */ jsx2("code", { ref: mermaidRef, className: "w-full" }) : /* @__PURE__ */ jsx2("code", { children: content })
|
|
1703
|
+
] });
|
|
1704
|
+
});
|
|
1705
|
+
var Mermaid_default = Mermaid;
|
|
1706
|
+
|
|
113
1707
|
// icons/react/Link16Icon.tsx
|
|
114
|
-
import { jsx as
|
|
115
|
-
var Link16Icon = ({ title, titleId, ...props }) => /* @__PURE__ */
|
|
1708
|
+
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
1709
|
+
var Link16Icon = ({ title, titleId, ...props }) => /* @__PURE__ */ jsxs3(
|
|
116
1710
|
"svg",
|
|
117
1711
|
{
|
|
118
1712
|
width: 16,
|
|
@@ -123,10 +1717,10 @@ var Link16Icon = ({ title, titleId, ...props }) => /* @__PURE__ */ jsxs2(
|
|
|
123
1717
|
"aria-labelledby": titleId,
|
|
124
1718
|
...props,
|
|
125
1719
|
children: [
|
|
126
|
-
title ? /* @__PURE__ */
|
|
127
|
-
/* @__PURE__ */
|
|
128
|
-
/* @__PURE__ */
|
|
129
|
-
/* @__PURE__ */
|
|
1720
|
+
title ? /* @__PURE__ */ jsx3("title", { id: titleId, children: title }) : null,
|
|
1721
|
+
/* @__PURE__ */ jsxs3("g", { fill: "currentColor", children: [
|
|
1722
|
+
/* @__PURE__ */ jsx3("path", { d: "m6.586 12.243 1.59-1.591a.75.75 0 0 1 1.061 0l.354.353a.75.75 0 0 1 0 1.06L8 13.658A4 4 0 0 1 2.343 8l1.591-1.591a.75.75 0 0 1 1.06 0l.354.354a.75.75 0 0 1 0 1.06l-1.59 1.591a2 2 0 1 0 2.828 2.829ZM12.066 9.591a.75.75 0 0 1-1.06 0l-.354-.354a.75.75 0 0 1 0-1.06l1.59-1.591a2 2 0 1 0-2.828-2.829l-1.59 1.591a.75.75 0 0 1-1.061 0l-.354-.353a.75.75 0 0 1 0-1.06L8 2.342A4 4 0 0 1 13.657 8l-1.591 1.591Z" }),
|
|
1723
|
+
/* @__PURE__ */ jsx3("path", { d: "M9.945 5.702a.75.75 0 0 0-1.061 0L5.702 8.884a.75.75 0 0 0 0 1.06l.353.354a.75.75 0 0 0 1.061 0l3.182-3.182a.75.75 0 0 0 0-1.06l-.353-.354Z" })
|
|
130
1724
|
] })
|
|
131
1725
|
]
|
|
132
1726
|
}
|
|
@@ -134,12 +1728,12 @@ var Link16Icon = ({ title, titleId, ...props }) => /* @__PURE__ */ jsxs2(
|
|
|
134
1728
|
var Link16Icon_default = Link16Icon;
|
|
135
1729
|
|
|
136
1730
|
// icons/react/Checkmark12Icon.tsx
|
|
137
|
-
import { jsx as
|
|
1731
|
+
import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
138
1732
|
var Checkmark12Icon = ({
|
|
139
1733
|
title,
|
|
140
1734
|
titleId,
|
|
141
1735
|
...props
|
|
142
|
-
}) => /* @__PURE__ */
|
|
1736
|
+
}) => /* @__PURE__ */ jsxs4(
|
|
143
1737
|
"svg",
|
|
144
1738
|
{
|
|
145
1739
|
width: 12,
|
|
@@ -150,8 +1744,8 @@ var Checkmark12Icon = ({
|
|
|
150
1744
|
"aria-labelledby": titleId,
|
|
151
1745
|
...props,
|
|
152
1746
|
children: [
|
|
153
|
-
title ? /* @__PURE__ */
|
|
154
|
-
/* @__PURE__ */
|
|
1747
|
+
title ? /* @__PURE__ */ jsx4("title", { id: titleId, children: title }) : null,
|
|
1748
|
+
/* @__PURE__ */ jsx4(
|
|
155
1749
|
"path",
|
|
156
1750
|
{
|
|
157
1751
|
fillRule: "evenodd",
|
|
@@ -166,12 +1760,12 @@ var Checkmark12Icon = ({
|
|
|
166
1760
|
var Checkmark12Icon_default = Checkmark12Icon;
|
|
167
1761
|
|
|
168
1762
|
// icons/react/DirectionRightIcon.tsx
|
|
169
|
-
import { jsx as
|
|
1763
|
+
import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
170
1764
|
var DirectionRightIcon = ({
|
|
171
1765
|
title,
|
|
172
1766
|
titleId,
|
|
173
1767
|
...props
|
|
174
|
-
}) => /* @__PURE__ */
|
|
1768
|
+
}) => /* @__PURE__ */ jsxs5(
|
|
175
1769
|
"svg",
|
|
176
1770
|
{
|
|
177
1771
|
width: 12,
|
|
@@ -182,8 +1776,8 @@ var DirectionRightIcon = ({
|
|
|
182
1776
|
"aria-labelledby": titleId,
|
|
183
1777
|
...props,
|
|
184
1778
|
children: [
|
|
185
|
-
title ? /* @__PURE__ */
|
|
186
|
-
/* @__PURE__ */
|
|
1779
|
+
title ? /* @__PURE__ */ jsx5("title", { id: titleId, children: title }) : null,
|
|
1780
|
+
/* @__PURE__ */ jsx5(
|
|
187
1781
|
"path",
|
|
188
1782
|
{
|
|
189
1783
|
d: "M8.807 6.597a.667.667 0 0 0 0-1.194l-5.842-2.92A.667.667 0 0 0 2 3.079v5.842c0 .496.522.818.965.596l5.842-2.92Z",
|
|
@@ -196,12 +1790,12 @@ var DirectionRightIcon = ({
|
|
|
196
1790
|
var DirectionRightIcon_default = DirectionRightIcon;
|
|
197
1791
|
|
|
198
1792
|
// icons/react/SelectArrows6Icon.tsx
|
|
199
|
-
import { jsx as
|
|
1793
|
+
import { jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
200
1794
|
var SelectArrows6Icon = ({
|
|
201
1795
|
title,
|
|
202
1796
|
titleId,
|
|
203
1797
|
...props
|
|
204
|
-
}) => /* @__PURE__ */
|
|
1798
|
+
}) => /* @__PURE__ */ jsxs6(
|
|
205
1799
|
"svg",
|
|
206
1800
|
{
|
|
207
1801
|
width: 6,
|
|
@@ -212,8 +1806,8 @@ var SelectArrows6Icon = ({
|
|
|
212
1806
|
"aria-labelledby": titleId,
|
|
213
1807
|
...props,
|
|
214
1808
|
children: [
|
|
215
|
-
title ? /* @__PURE__ */
|
|
216
|
-
/* @__PURE__ */
|
|
1809
|
+
title ? /* @__PURE__ */ jsx6("title", { id: titleId, children: title }) : null,
|
|
1810
|
+
/* @__PURE__ */ jsx6(
|
|
217
1811
|
"path",
|
|
218
1812
|
{
|
|
219
1813
|
fillRule: "evenodd",
|
|
@@ -228,32 +1822,32 @@ var SelectArrows6Icon = ({
|
|
|
228
1822
|
var SelectArrows6Icon_default = SelectArrows6Icon;
|
|
229
1823
|
|
|
230
1824
|
// components/src/asciidoc/Section.tsx
|
|
231
|
-
import { Content as Content2, parse as
|
|
1825
|
+
import { Content as Content2, parse as parse4 } from "@oxide/react-asciidoc";
|
|
232
1826
|
import cn2 from "classnames";
|
|
233
1827
|
import { createElement as createElement2 } from "react";
|
|
234
|
-
import { Fragment, jsx as
|
|
1828
|
+
import { Fragment as Fragment2, jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
235
1829
|
var stripAnchors = (str) => str.replace(/<a[^>]*>(.*?)<\/a>/gi, "$1");
|
|
236
|
-
var Section = ({ node }) => {
|
|
237
|
-
const level =
|
|
1830
|
+
var Section = ({ node: node2 }) => {
|
|
1831
|
+
const level = node2.level;
|
|
238
1832
|
let title = "";
|
|
239
|
-
let sectNum =
|
|
1833
|
+
let sectNum = node2.num;
|
|
240
1834
|
sectNum = sectNum === "." ? "" : sectNum;
|
|
241
|
-
title = /* @__PURE__ */
|
|
242
|
-
/* @__PURE__ */
|
|
243
|
-
/* @__PURE__ */
|
|
244
|
-
|
|
245
|
-
/* @__PURE__ */
|
|
1835
|
+
title = /* @__PURE__ */ jsxs7(Fragment2, { children: [
|
|
1836
|
+
/* @__PURE__ */ jsx7("span", { className: "anchor", id: node2.id || "", "aria-hidden": "true" }),
|
|
1837
|
+
/* @__PURE__ */ jsxs7("a", { className: "link group", href: `#${node2.id}`, children: [
|
|
1838
|
+
parse4(stripAnchors(node2.title)),
|
|
1839
|
+
/* @__PURE__ */ jsx7(Link16Icon_default, { className: "ml-2 hidden text-accent-secondary group-hover:inline-block" })
|
|
246
1840
|
] })
|
|
247
1841
|
] });
|
|
248
1842
|
if (level === 0) {
|
|
249
|
-
return /* @__PURE__ */
|
|
250
|
-
/* @__PURE__ */
|
|
251
|
-
/* @__PURE__ */
|
|
1843
|
+
return /* @__PURE__ */ jsxs7(Fragment2, { children: [
|
|
1844
|
+
/* @__PURE__ */ jsx7("h1", { className: cn2("sect0", node2.role), "data-sectnum": sectNum, children: title }),
|
|
1845
|
+
/* @__PURE__ */ jsx7(Content2, { blocks: node2.blocks })
|
|
252
1846
|
] });
|
|
253
1847
|
} else {
|
|
254
|
-
return /* @__PURE__ */
|
|
1848
|
+
return /* @__PURE__ */ jsxs7("div", { className: cn2(`sect${level}`, node2.role), children: [
|
|
255
1849
|
createElement2(`h${level + 1}`, { "data-sectnum": sectNum }, title),
|
|
256
|
-
/* @__PURE__ */
|
|
1850
|
+
/* @__PURE__ */ jsx7("div", { className: "sectionbody", children: /* @__PURE__ */ jsx7(Content2, { blocks: node2.blocks }) })
|
|
257
1851
|
] });
|
|
258
1852
|
}
|
|
259
1853
|
};
|
|
@@ -261,18 +1855,18 @@ var Section_default = Section;
|
|
|
261
1855
|
|
|
262
1856
|
// components/src/asciidoc/Table.tsx
|
|
263
1857
|
import { Table as InnerTable } from "@oxide/react-asciidoc";
|
|
264
|
-
import { jsx as
|
|
265
|
-
var Table = ({ node }) => /* @__PURE__ */
|
|
1858
|
+
import { jsx as jsx8 } from "react/jsx-runtime";
|
|
1859
|
+
var Table = ({ node: node2 }) => /* @__PURE__ */ jsx8("div", { className: "table-wrapper", children: /* @__PURE__ */ jsx8(InnerTable, { node: node2 }) });
|
|
266
1860
|
var Table_default = Table;
|
|
267
1861
|
|
|
268
1862
|
// components/src/asciidoc/TableOfContents.tsx
|
|
269
1863
|
import * as Accordion from "@radix-ui/react-accordion";
|
|
270
1864
|
import { Link } from "@remix-run/react";
|
|
271
1865
|
import cn3 from "classnames";
|
|
272
|
-
import { Fragment as
|
|
273
|
-
import { jsx as
|
|
1866
|
+
import { Fragment as Fragment3, useCallback, useEffect, useMemo, useRef, useState as useState2 } from "react";
|
|
1867
|
+
import { jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
274
1868
|
function useIntersectionObserver(elements, callback, options) {
|
|
275
|
-
const [observer, setObserver] =
|
|
1869
|
+
const [observer, setObserver] = useState2(null);
|
|
276
1870
|
useEffect(() => {
|
|
277
1871
|
const observer2 = new IntersectionObserver(callback, options);
|
|
278
1872
|
setObserver(observer2);
|
|
@@ -304,9 +1898,9 @@ function findParentSection(element) {
|
|
|
304
1898
|
const sect2Wrapper = element.closest(".sect2");
|
|
305
1899
|
return sect2Wrapper ? sect2Wrapper : element.closest(".sect1");
|
|
306
1900
|
}
|
|
307
|
-
function newSection(
|
|
1901
|
+
function newSection(node2, element, wrapper, parent) {
|
|
308
1902
|
return {
|
|
309
|
-
node,
|
|
1903
|
+
node: node2,
|
|
310
1904
|
element,
|
|
311
1905
|
wrapper,
|
|
312
1906
|
parent,
|
|
@@ -346,7 +1940,7 @@ function maxIndex(nums) {
|
|
|
346
1940
|
}, void 0);
|
|
347
1941
|
}
|
|
348
1942
|
function useActiveSectionTracking(initialSections, onSectionChange, debug = false) {
|
|
349
|
-
const [sectionWrappers, setSectionWrappers] =
|
|
1943
|
+
const [sectionWrappers, setSectionWrappers] = useState2(
|
|
350
1944
|
buildSectionTree(initialSections)
|
|
351
1945
|
);
|
|
352
1946
|
const sectionMeasurements = useRef([]);
|
|
@@ -360,7 +1954,7 @@ function useActiveSectionTracking(initialSections, onSectionChange, debug = fals
|
|
|
360
1954
|
const wrapperActivator = useCallback(
|
|
361
1955
|
(entries) => {
|
|
362
1956
|
for (const entry of entries) {
|
|
363
|
-
const index = sectionWrappers.findIndex((
|
|
1957
|
+
const index = sectionWrappers.findIndex((node2) => node2.wrapper === entry.target);
|
|
364
1958
|
const covered = entry.intersectionRect.height / (entry.rootBounds?.height || 1);
|
|
365
1959
|
sectionMeasurements.current[index] = covered;
|
|
366
1960
|
}
|
|
@@ -399,7 +1993,7 @@ function useActiveSectionTracking(initialSections, onSectionChange, debug = fals
|
|
|
399
1993
|
return "0px";
|
|
400
1994
|
}
|
|
401
1995
|
});
|
|
402
|
-
debugNode = /* @__PURE__ */
|
|
1996
|
+
debugNode = /* @__PURE__ */ jsx9(
|
|
403
1997
|
"div",
|
|
404
1998
|
{
|
|
405
1999
|
style: {
|
|
@@ -426,13 +2020,13 @@ var DesktopOutline = ({
|
|
|
426
2020
|
activeItem
|
|
427
2021
|
}) => {
|
|
428
2022
|
const renderToc = (sections) => {
|
|
429
|
-
return sections.map((item) => /* @__PURE__ */
|
|
430
|
-
/* @__PURE__ */
|
|
2023
|
+
return sections.map((item) => /* @__PURE__ */ jsxs8(Fragment3, { children: [
|
|
2024
|
+
/* @__PURE__ */ jsx9(
|
|
431
2025
|
"li",
|
|
432
2026
|
{
|
|
433
2027
|
"data-level": item.level,
|
|
434
2028
|
className: cn3("mb-0 list-none text-sans-sm", item.level > 2 && "hidden"),
|
|
435
|
-
children: /* @__PURE__ */
|
|
2029
|
+
children: /* @__PURE__ */ jsx9(
|
|
436
2030
|
Link,
|
|
437
2031
|
{
|
|
438
2032
|
to: `#${item.id}`,
|
|
@@ -443,7 +2037,7 @@ var DesktopOutline = ({
|
|
|
443
2037
|
style: {
|
|
444
2038
|
paddingLeft: `${0.5 + item.level * 0.5}rem`
|
|
445
2039
|
},
|
|
446
|
-
children: /* @__PURE__ */
|
|
2040
|
+
children: /* @__PURE__ */ jsx9("span", { dangerouslySetInnerHTML: { __html: item.title } })
|
|
447
2041
|
}
|
|
448
2042
|
)
|
|
449
2043
|
}
|
|
@@ -452,7 +2046,7 @@ var DesktopOutline = ({
|
|
|
452
2046
|
] }, item.id));
|
|
453
2047
|
};
|
|
454
2048
|
if (toc && toc.length > 0) {
|
|
455
|
-
return /* @__PURE__ */
|
|
2049
|
+
return /* @__PURE__ */ jsx9("ul", { className: "toc", children: renderToc(toc) });
|
|
456
2050
|
}
|
|
457
2051
|
return null;
|
|
458
2052
|
};
|
|
@@ -462,8 +2056,8 @@ var SmallScreenOutline = ({
|
|
|
462
2056
|
title
|
|
463
2057
|
}) => {
|
|
464
2058
|
const renderToc = (sections) => {
|
|
465
|
-
return sections.map((item) => /* @__PURE__ */
|
|
466
|
-
/* @__PURE__ */
|
|
2059
|
+
return sections.map((item) => /* @__PURE__ */ jsxs8(Fragment3, { children: [
|
|
2060
|
+
/* @__PURE__ */ jsx9(
|
|
467
2061
|
"li",
|
|
468
2062
|
{
|
|
469
2063
|
"data-level": item.level,
|
|
@@ -471,7 +2065,7 @@ var SmallScreenOutline = ({
|
|
|
471
2065
|
"AccordionContent hydrated list-none text-sans-sm",
|
|
472
2066
|
item.level > 2 && "hidden"
|
|
473
2067
|
),
|
|
474
|
-
children: /* @__PURE__ */
|
|
2068
|
+
children: /* @__PURE__ */ jsx9(
|
|
475
2069
|
Link,
|
|
476
2070
|
{
|
|
477
2071
|
to: `#${item.id}`,
|
|
@@ -482,7 +2076,7 @@ var SmallScreenOutline = ({
|
|
|
482
2076
|
style: {
|
|
483
2077
|
paddingLeft: `${0.5 + item.level * 0.5}rem`
|
|
484
2078
|
},
|
|
485
|
-
children: /* @__PURE__ */
|
|
2079
|
+
children: /* @__PURE__ */ jsx9("span", { dangerouslySetInnerHTML: { __html: item.title } })
|
|
486
2080
|
}
|
|
487
2081
|
)
|
|
488
2082
|
}
|
|
@@ -491,19 +2085,19 @@ var SmallScreenOutline = ({
|
|
|
491
2085
|
] }, item.id));
|
|
492
2086
|
};
|
|
493
2087
|
if (toc && toc.length > 0) {
|
|
494
|
-
return /* @__PURE__ */
|
|
2088
|
+
return /* @__PURE__ */ jsx9(
|
|
495
2089
|
Accordion.Root,
|
|
496
2090
|
{
|
|
497
2091
|
type: "single",
|
|
498
2092
|
className: "sticky top-[calc(var(--header-height)-1px)] z-10 -mt-px mb-10 block max-h-[calc(100vh-var(--header-height)+1px)] w-full overflow-y-scroll border-b border-t bg-default border-secondary 1200:hidden print:hidden",
|
|
499
2093
|
collapsible: true,
|
|
500
|
-
children: /* @__PURE__ */
|
|
501
|
-
/* @__PURE__ */
|
|
2094
|
+
children: /* @__PURE__ */ jsxs8(Accordion.Item, { value: `small-toc-${title}`, children: [
|
|
2095
|
+
/* @__PURE__ */ jsx9(Accordion.Header, { children: /* @__PURE__ */ jsxs8(Accordion.Trigger, { className: "flex h-[--toc-header-height] w-full items-center justify-between px-4 text-sans-md text-default hover:bg-hover 400:px-6 600:px-8 [&>svg]:data-[state=open]:rotate-90", children: [
|
|
502
2096
|
"Table of Contents",
|
|
503
2097
|
" ",
|
|
504
|
-
/* @__PURE__ */
|
|
2098
|
+
/* @__PURE__ */ jsx9(DirectionRightIcon_default, { className: "transition-all text-tertiary" })
|
|
505
2099
|
] }) }),
|
|
506
|
-
/* @__PURE__ */
|
|
2100
|
+
/* @__PURE__ */ jsx9(Accordion.Content, { className: "AccordionContent hydrated w-full border-t px-4 border-secondary 400:px-6 600:px-8", children: /* @__PURE__ */ jsx9("div", { className: "py-4", children: renderToc(toc) }) })
|
|
507
2101
|
] })
|
|
508
2102
|
}
|
|
509
2103
|
);
|
|
@@ -2039,35 +3633,36 @@ var loadAsciidoctor = ({
|
|
|
2039
3633
|
constructor() {
|
|
2040
3634
|
this.baseConverter = new ad2.Html5Converter();
|
|
2041
3635
|
}
|
|
2042
|
-
convert(
|
|
2043
|
-
switch (
|
|
3636
|
+
convert(node2, transform) {
|
|
3637
|
+
switch (node2.getNodeName()) {
|
|
2044
3638
|
case "inline_callout":
|
|
2045
|
-
return convertInlineCallout(
|
|
3639
|
+
return convertInlineCallout(node2);
|
|
2046
3640
|
default:
|
|
2047
3641
|
break;
|
|
2048
3642
|
}
|
|
2049
|
-
return this.baseConverter.convert(
|
|
3643
|
+
return this.baseConverter.convert(node2, transform);
|
|
2050
3644
|
}
|
|
2051
3645
|
}
|
|
2052
3646
|
extensions.forEach((extension) => ad2.Extensions.register(extension));
|
|
2053
3647
|
ad2.ConverterFactory.register(new InlineConverter2(), ["html5"]);
|
|
2054
3648
|
return ad2;
|
|
2055
3649
|
};
|
|
2056
|
-
function convertInlineCallout(
|
|
2057
|
-
return `<i class="conum" data-value="${
|
|
3650
|
+
function convertInlineCallout(node2) {
|
|
3651
|
+
return `<i class="conum" data-value="${node2.getText()}"></i>`;
|
|
2058
3652
|
}
|
|
2059
|
-
var handleDocument = async (
|
|
2060
|
-
const doc = prepareDocument(
|
|
3653
|
+
var handleDocument = async (document2) => {
|
|
3654
|
+
const doc = prepareDocument(document2);
|
|
2061
3655
|
return await processDocument(doc, highlight);
|
|
2062
3656
|
};
|
|
2063
3657
|
|
|
2064
3658
|
// components/src/asciidoc/index.tsx
|
|
2065
|
-
import { jsx as
|
|
2066
|
-
var MinimalDocument = ({ document }) => /* @__PURE__ */
|
|
3659
|
+
import { jsx as jsx10 } from "react/jsx-runtime";
|
|
3660
|
+
var MinimalDocument = ({ document: document2 }) => /* @__PURE__ */ jsx10("div", { id: "content", className: "asciidoc-body w-full", children: /* @__PURE__ */ jsx10(Content4, { blocks: document2.blocks }) });
|
|
2067
3661
|
var AsciiDocBlocks = {
|
|
2068
3662
|
Admonition: Admonition_default,
|
|
2069
3663
|
Table: Table_default,
|
|
2070
3664
|
Section: Section_default,
|
|
3665
|
+
Mermaid: Mermaid_default,
|
|
2071
3666
|
MinimalDocument
|
|
2072
3667
|
};
|
|
2073
3668
|
var renderWithBreaks = (text) => {
|
|
@@ -2092,20 +3687,20 @@ var QUOTE_TAGS = {
|
|
|
2092
3687
|
"latexmath": ["\\(", "\\)"]
|
|
2093
3688
|
};
|
|
2094
3689
|
var chop = (str) => str.substring(0, str.length - 1);
|
|
2095
|
-
var convertInlineQuoted = (
|
|
2096
|
-
const type =
|
|
3690
|
+
var convertInlineQuoted = (node2) => {
|
|
3691
|
+
const type = node2.getType();
|
|
2097
3692
|
const quoteTag = QUOTE_TAGS[type];
|
|
2098
3693
|
const [open, close, tag] = quoteTag || ["", ""];
|
|
2099
|
-
let text =
|
|
3694
|
+
let text = node2.getText();
|
|
2100
3695
|
if (type === "monospaced") {
|
|
2101
3696
|
text = renderWithBreaks(text);
|
|
2102
3697
|
}
|
|
2103
|
-
const
|
|
2104
|
-
const role =
|
|
2105
|
-
const idAttr =
|
|
3698
|
+
const id26 = node2.getId();
|
|
3699
|
+
const role = node2.getRole();
|
|
3700
|
+
const idAttr = id26 ? `id="${id26}"` : "";
|
|
2106
3701
|
const classAttr = role ? `class="${role}"` : "";
|
|
2107
3702
|
const attrs2 = `${idAttr} ${classAttr}`;
|
|
2108
|
-
if (
|
|
3703
|
+
if (id26 || role) {
|
|
2109
3704
|
if (tag) {
|
|
2110
3705
|
return `${chop(open)} ${attrs2}>${text}${close}`;
|
|
2111
3706
|
} else {
|
|
@@ -2115,8 +3710,8 @@ var convertInlineQuoted = (node) => {
|
|
|
2115
3710
|
return `${open}${text}${close}`;
|
|
2116
3711
|
}
|
|
2117
3712
|
};
|
|
2118
|
-
function convertInlineCallout2(
|
|
2119
|
-
return `<i class="conum" data-value="${
|
|
3713
|
+
function convertInlineCallout2(node2) {
|
|
3714
|
+
return `<i class="conum" data-value="${node2.getText()}"></i>`;
|
|
2120
3715
|
}
|
|
2121
3716
|
var ad = asciidoctor2();
|
|
2122
3717
|
var InlineConverter = class {
|
|
@@ -2124,22 +3719,22 @@ var InlineConverter = class {
|
|
|
2124
3719
|
constructor() {
|
|
2125
3720
|
this.baseConverter = new ad.Html5Converter();
|
|
2126
3721
|
}
|
|
2127
|
-
convert(
|
|
2128
|
-
switch (
|
|
3722
|
+
convert(node2, transform) {
|
|
3723
|
+
switch (node2.getNodeName()) {
|
|
2129
3724
|
case "inline_quoted":
|
|
2130
|
-
return convertInlineQuoted(
|
|
3725
|
+
return convertInlineQuoted(node2);
|
|
2131
3726
|
case "inline_callout":
|
|
2132
|
-
return convertInlineCallout2(
|
|
3727
|
+
return convertInlineCallout2(node2);
|
|
2133
3728
|
default:
|
|
2134
3729
|
break;
|
|
2135
3730
|
}
|
|
2136
|
-
return this.baseConverter.convert(
|
|
3731
|
+
return this.baseConverter.convert(node2, transform);
|
|
2137
3732
|
}
|
|
2138
3733
|
};
|
|
2139
3734
|
|
|
2140
3735
|
// components/src/ui/badge/Badge.tsx
|
|
2141
3736
|
import cn4 from "classnames";
|
|
2142
|
-
import { jsx as
|
|
3737
|
+
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
2143
3738
|
var badgeColors = {
|
|
2144
3739
|
default: {
|
|
2145
3740
|
default: `ring-1 ring-inset bg-accent-secondary text-accent ring-[rgba(var(--base-green-800-rgb),0.15)]`,
|
|
@@ -2164,7 +3759,7 @@ var Badge = ({
|
|
|
2164
3759
|
color = "default",
|
|
2165
3760
|
variant = "default"
|
|
2166
3761
|
}) => {
|
|
2167
|
-
return /* @__PURE__ */
|
|
3762
|
+
return /* @__PURE__ */ jsx11(
|
|
2168
3763
|
"span",
|
|
2169
3764
|
{
|
|
2170
3765
|
className: cn4(
|
|
@@ -2174,7 +3769,7 @@ var Badge = ({
|
|
|
2174
3769
|
badgeColors[variant][color],
|
|
2175
3770
|
className
|
|
2176
3771
|
),
|
|
2177
|
-
children: /* @__PURE__ */
|
|
3772
|
+
children: /* @__PURE__ */ jsx11("span", { children })
|
|
2178
3773
|
}
|
|
2179
3774
|
);
|
|
2180
3775
|
};
|
|
@@ -2182,7 +3777,7 @@ var Badge = ({
|
|
|
2182
3777
|
// components/src/ui/button/Button.tsx
|
|
2183
3778
|
import cn5 from "classnames";
|
|
2184
3779
|
import { forwardRef } from "react";
|
|
2185
|
-
import { jsx as
|
|
3780
|
+
import { jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
2186
3781
|
var buttonSizes = ["sm", "icon", "base"];
|
|
2187
3782
|
var variants = ["primary", "secondary", "ghost", "danger"];
|
|
2188
3783
|
var sizeStyle = {
|
|
@@ -2222,7 +3817,7 @@ var Button = forwardRef(
|
|
|
2222
3817
|
...rest
|
|
2223
3818
|
}, ref) => {
|
|
2224
3819
|
const isDisabled = disabled || loading;
|
|
2225
|
-
return /* @__PURE__ */
|
|
3820
|
+
return /* @__PURE__ */ jsxs9(
|
|
2226
3821
|
"button",
|
|
2227
3822
|
{
|
|
2228
3823
|
className: cn5(buttonStyle({ size: size2, variant }), className, {
|
|
@@ -2235,8 +3830,8 @@ var Button = forwardRef(
|
|
|
2235
3830
|
"aria-disabled": isDisabled,
|
|
2236
3831
|
...rest,
|
|
2237
3832
|
children: [
|
|
2238
|
-
loading && /* @__PURE__ */
|
|
2239
|
-
/* @__PURE__ */
|
|
3833
|
+
loading && /* @__PURE__ */ jsx12(Spinner, { className: "absolute", variant }),
|
|
3834
|
+
/* @__PURE__ */ jsx12("span", { className: cn5("flex items-center", innerClassName, { invisible: loading }), children })
|
|
2240
3835
|
]
|
|
2241
3836
|
}
|
|
2242
3837
|
);
|
|
@@ -2245,8 +3840,8 @@ var Button = forwardRef(
|
|
|
2245
3840
|
|
|
2246
3841
|
// components/src/ui/spinner/Spinner.tsx
|
|
2247
3842
|
import cn6 from "classnames";
|
|
2248
|
-
import { useEffect as useEffect2, useRef as useRef2, useState as
|
|
2249
|
-
import { Fragment as
|
|
3843
|
+
import { useEffect as useEffect2, useRef as useRef2, useState as useState3 } from "react";
|
|
3844
|
+
import { Fragment as Fragment4, jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
2250
3845
|
var spinnerSizes = ["base", "lg"];
|
|
2251
3846
|
var spinnerVariants = ["primary", "secondary", "ghost", "danger"];
|
|
2252
3847
|
var Spinner = ({
|
|
@@ -2258,7 +3853,7 @@ var Spinner = ({
|
|
|
2258
3853
|
const center = size2 === "lg" ? 18 : 6;
|
|
2259
3854
|
const radius = size2 === "lg" ? 16 : 5;
|
|
2260
3855
|
const strokeWidth = size2 === "lg" ? 3 : 2;
|
|
2261
|
-
return /* @__PURE__ */
|
|
3856
|
+
return /* @__PURE__ */ jsxs10(
|
|
2262
3857
|
"svg",
|
|
2263
3858
|
{
|
|
2264
3859
|
width: frameSize,
|
|
@@ -2269,7 +3864,7 @@ var Spinner = ({
|
|
|
2269
3864
|
"aria-labelledby": "Spinner",
|
|
2270
3865
|
className: cn6("spinner", `spinner-${variant}`, `spinner-${size2}`, className),
|
|
2271
3866
|
children: [
|
|
2272
|
-
/* @__PURE__ */
|
|
3867
|
+
/* @__PURE__ */ jsx13(
|
|
2273
3868
|
"circle",
|
|
2274
3869
|
{
|
|
2275
3870
|
fill: "none",
|
|
@@ -2282,7 +3877,7 @@ var Spinner = ({
|
|
|
2282
3877
|
strokeOpacity: 0.2
|
|
2283
3878
|
}
|
|
2284
3879
|
),
|
|
2285
|
-
/* @__PURE__ */
|
|
3880
|
+
/* @__PURE__ */ jsx13(
|
|
2286
3881
|
"circle",
|
|
2287
3882
|
{
|
|
2288
3883
|
className: "path",
|
|
@@ -2300,7 +3895,7 @@ var Spinner = ({
|
|
|
2300
3895
|
);
|
|
2301
3896
|
};
|
|
2302
3897
|
var SpinnerLoader = ({ isLoading, children = null, minTime = 500 }) => {
|
|
2303
|
-
const [isVisible, setIsVisible] =
|
|
3898
|
+
const [isVisible, setIsVisible] = useState3(isLoading);
|
|
2304
3899
|
const hideTimeout = useRef2(null);
|
|
2305
3900
|
const loadingStartTime = useRef2(0);
|
|
2306
3901
|
useEffect2(() => {
|
|
@@ -2323,24 +3918,24 @@ var SpinnerLoader = ({ isLoading, children = null, minTime = 500 }) => {
|
|
|
2323
3918
|
clearTimeout(hideTimeout.current);
|
|
2324
3919
|
};
|
|
2325
3920
|
}, [isLoading, minTime]);
|
|
2326
|
-
return isVisible ? /* @__PURE__ */
|
|
3921
|
+
return isVisible ? /* @__PURE__ */ jsx13(Spinner, {}) : /* @__PURE__ */ jsx13(Fragment4, { children });
|
|
2327
3922
|
};
|
|
2328
3923
|
|
|
2329
3924
|
// components/src/ui/tabs/Tabs.tsx
|
|
2330
3925
|
import { Content as Content5, List, Root as Root2, Trigger as Trigger2 } from "@radix-ui/react-tabs";
|
|
2331
3926
|
import cn7 from "classnames";
|
|
2332
|
-
import { jsx as
|
|
3927
|
+
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
2333
3928
|
var Tabs = {
|
|
2334
|
-
Root: ({ className, ...props }) => /* @__PURE__ */
|
|
2335
|
-
Trigger: ({ children, className, ...props }) => /* @__PURE__ */
|
|
2336
|
-
List: ({ className, ...props }) => /* @__PURE__ */
|
|
2337
|
-
Content: ({ className, ...props }) => /* @__PURE__ */
|
|
3929
|
+
Root: ({ className, ...props }) => /* @__PURE__ */ jsx14(Root2, { ...props, className: cn7("ox-tabs", className) }),
|
|
3930
|
+
Trigger: ({ children, className, ...props }) => /* @__PURE__ */ jsx14(Trigger2, { ...props, className: cn7("ox-tab", className), children: /* @__PURE__ */ jsx14("div", { children }) }),
|
|
3931
|
+
List: ({ className, ...props }) => /* @__PURE__ */ jsx14(List, { ...props, className: cn7("ox-tabs-list", className) }),
|
|
3932
|
+
Content: ({ className, ...props }) => /* @__PURE__ */ jsx14(Content5, { ...props, className: cn7("ox-tabs-panel", className) })
|
|
2338
3933
|
};
|
|
2339
3934
|
|
|
2340
3935
|
// components/src/ui/checkbox/Checkbox.tsx
|
|
2341
3936
|
import cn8 from "classnames";
|
|
2342
|
-
import { jsx as
|
|
2343
|
-
var Check = () => /* @__PURE__ */
|
|
3937
|
+
import { jsx as jsx15, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
3938
|
+
var Check = () => /* @__PURE__ */ jsx15(Checkmark12Icon_default, { className: "pointer-events-none absolute left-0.5 top-0.5 h-3 w-3 fill-current text-accent" });
|
|
2344
3939
|
var Indeterminate = classed.div`absolute w-2 h-0.5 left-1 top-[7px] bg-accent pointer-events-none`;
|
|
2345
3940
|
var inputStyle = `
|
|
2346
3941
|
appearance-none border border-default bg-default h-4 w-4 rounded-sm absolute left-0 outline-none
|
|
@@ -2354,9 +3949,9 @@ var Checkbox = ({
|
|
|
2354
3949
|
children,
|
|
2355
3950
|
className,
|
|
2356
3951
|
...inputProps
|
|
2357
|
-
}) => /* @__PURE__ */
|
|
2358
|
-
/* @__PURE__ */
|
|
2359
|
-
/* @__PURE__ */
|
|
3952
|
+
}) => /* @__PURE__ */ jsxs11("label", { className: "inline-flex items-center", children: [
|
|
3953
|
+
/* @__PURE__ */ jsxs11("span", { className: "relative h-4 w-4", children: [
|
|
3954
|
+
/* @__PURE__ */ jsx15(
|
|
2360
3955
|
"input",
|
|
2361
3956
|
{
|
|
2362
3957
|
className: cn8(inputStyle, className),
|
|
@@ -2365,17 +3960,17 @@ var Checkbox = ({
|
|
|
2365
3960
|
...inputProps
|
|
2366
3961
|
}
|
|
2367
3962
|
),
|
|
2368
|
-
inputProps.checked && !indeterminate && /* @__PURE__ */
|
|
2369
|
-
indeterminate && /* @__PURE__ */
|
|
3963
|
+
inputProps.checked && !indeterminate && /* @__PURE__ */ jsx15(Check, {}),
|
|
3964
|
+
indeterminate && /* @__PURE__ */ jsx15(Indeterminate, {})
|
|
2370
3965
|
] }),
|
|
2371
|
-
children && /* @__PURE__ */
|
|
3966
|
+
children && /* @__PURE__ */ jsx15("span", { className: "ml-2.5 text-sans-md text-secondary", children })
|
|
2372
3967
|
] });
|
|
2373
3968
|
|
|
2374
3969
|
// components/src/ui/listbox/Listbox.tsx
|
|
2375
3970
|
import { FloatingPortal, flip, offset, size, useFloating } from "@floating-ui/react";
|
|
2376
3971
|
import { Listbox as Select } from "@headlessui/react";
|
|
2377
3972
|
import cn9 from "classnames";
|
|
2378
|
-
import { Fragment as
|
|
3973
|
+
import { Fragment as Fragment5, jsx as jsx16, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
2379
3974
|
var Listbox = ({
|
|
2380
3975
|
name,
|
|
2381
3976
|
selected,
|
|
@@ -2404,14 +3999,14 @@ var Listbox = ({
|
|
|
2404
3999
|
const selectedItem = selected && items.find((i) => i.value === selected);
|
|
2405
4000
|
const noItems = !isLoading && items.length === 0;
|
|
2406
4001
|
const isDisabled = disabled || noItems;
|
|
2407
|
-
return /* @__PURE__ */
|
|
4002
|
+
return /* @__PURE__ */ jsx16("div", { className: cn9("relative", className), children: /* @__PURE__ */ jsx16(
|
|
2408
4003
|
Select,
|
|
2409
4004
|
{
|
|
2410
4005
|
value: selected,
|
|
2411
4006
|
onChange: (val) => val !== null && onChange(val),
|
|
2412
4007
|
disabled: isDisabled || isLoading,
|
|
2413
|
-
children: ({ open }) => /* @__PURE__ */
|
|
2414
|
-
/* @__PURE__ */
|
|
4008
|
+
children: ({ open }) => /* @__PURE__ */ jsxs12(Fragment5, { children: [
|
|
4009
|
+
/* @__PURE__ */ jsxs12(
|
|
2415
4010
|
Select.Button,
|
|
2416
4011
|
{
|
|
2417
4012
|
name,
|
|
@@ -2427,34 +4022,34 @@ var Listbox = ({
|
|
|
2427
4022
|
),
|
|
2428
4023
|
...props,
|
|
2429
4024
|
children: [
|
|
2430
|
-
/* @__PURE__ */
|
|
4025
|
+
/* @__PURE__ */ jsx16("div", { className: "w-full px-3 text-left", children: selectedItem ? (
|
|
2431
4026
|
// labelString is one line, which is what we need when label is a ReactNode
|
|
2432
4027
|
selectedItem.labelString || selectedItem.label
|
|
2433
|
-
) : /* @__PURE__ */
|
|
2434
|
-
!isDisabled && /* @__PURE__ */
|
|
2435
|
-
/* @__PURE__ */
|
|
4028
|
+
) : /* @__PURE__ */ jsx16("span", { className: "text-quaternary", children: noItems ? "No items" : placeholder }) }),
|
|
4029
|
+
!isDisabled && /* @__PURE__ */ jsx16(SpinnerLoader, { isLoading }),
|
|
4030
|
+
/* @__PURE__ */ jsx16(
|
|
2436
4031
|
"div",
|
|
2437
4032
|
{
|
|
2438
4033
|
className: "ml-3 flex h-[calc(100%-12px)] items-center border-l px-3 border-secondary",
|
|
2439
4034
|
"aria-hidden": true,
|
|
2440
|
-
children: /* @__PURE__ */
|
|
4035
|
+
children: /* @__PURE__ */ jsx16(SelectArrows6Icon_default, { className: "h-[14px] w-2 text-tertiary" })
|
|
2441
4036
|
}
|
|
2442
4037
|
)
|
|
2443
4038
|
]
|
|
2444
4039
|
}
|
|
2445
4040
|
),
|
|
2446
|
-
/* @__PURE__ */
|
|
4041
|
+
/* @__PURE__ */ jsx16(FloatingPortal, { children: /* @__PURE__ */ jsx16(
|
|
2447
4042
|
Select.Options,
|
|
2448
4043
|
{
|
|
2449
4044
|
ref: refs.setFloating,
|
|
2450
4045
|
style: floatingStyles,
|
|
2451
4046
|
className: "ox-menu pointer-events-auto z-50 overflow-y-auto !outline-none",
|
|
2452
|
-
children: items.map((item) => /* @__PURE__ */
|
|
4047
|
+
children: items.map((item) => /* @__PURE__ */ jsx16(
|
|
2453
4048
|
Select.Option,
|
|
2454
4049
|
{
|
|
2455
4050
|
value: item.value,
|
|
2456
4051
|
className: "relative border-b border-secondary last:border-0",
|
|
2457
|
-
children: ({ active, selected: selected2 }) => /* @__PURE__ */
|
|
4052
|
+
children: ({ active, selected: selected2 }) => /* @__PURE__ */ jsx16(
|
|
2458
4053
|
"div",
|
|
2459
4054
|
{
|
|
2460
4055
|
className: cn9(
|
|
@@ -2500,4 +4095,12 @@ export {
|
|
|
2500
4095
|
useIntersectionObserver,
|
|
2501
4096
|
variants
|
|
2502
4097
|
};
|
|
4098
|
+
/*! Bundled license information:
|
|
4099
|
+
|
|
4100
|
+
mermaid/dist/mermaid.core.mjs:
|
|
4101
|
+
(*! Check if previously processed *)
|
|
4102
|
+
(*!
|
|
4103
|
+
* Wait for document loaded before starting the execution
|
|
4104
|
+
*)
|
|
4105
|
+
*/
|
|
2503
4106
|
//# sourceMappingURL=index.js.map
|