@aiquants/markdown 8.1.1 → 9.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +102 -4
- package/dist/{abnfDiagram-VRR7QNED-714qd8by.cjs → abnfDiagram-VRR7QNED-BlcBSkWc.cjs} +1 -1
- package/dist/{abnfDiagram-VRR7QNED-ClsV3o7-.js → abnfDiagram-VRR7QNED-DPvv0JN7.js} +3 -3
- package/dist/{arc-Bs2N0CEE.cjs → arc-DnEVH7-N.cjs} +1 -1
- package/dist/arc-b3PXY3wd.js +83 -0
- package/dist/{architectureDiagram-ZJ3FMSHR-l2Kn8D2e.js → architectureDiagram-ZJ3FMSHR-BPDNqRgJ.js} +2 -2
- package/dist/{architectureDiagram-ZJ3FMSHR-SPtbaJq1.cjs → architectureDiagram-ZJ3FMSHR-BPesVaHB.cjs} +1 -1
- package/dist/{blockDiagram-677ZJIJ3-CbCSQo90.js → blockDiagram-677ZJIJ3-Bif7ObTM.js} +3 -3
- package/dist/{blockDiagram-677ZJIJ3-C01MGcBZ.cjs → blockDiagram-677ZJIJ3-D1wkf-um.cjs} +1 -1
- package/dist/{c4Diagram-LMCZKHZV-CdXSplj6.js → c4Diagram-LMCZKHZV-BTR45GVa.js} +2 -2
- package/dist/{c4Diagram-LMCZKHZV-TuT3uTkj.cjs → c4Diagram-LMCZKHZV-ByUwS5Pa.cjs} +1 -1
- package/dist/{channel-inzdTBsL.js → channel-BjDEP12v.js} +1 -1
- package/dist/{channel-DZlQOicJ.cjs → channel-s9lqY49F.cjs} +1 -1
- package/dist/{chunk-2Q5K7J3B-BlcbsuzR.js → chunk-2Q5K7J3B-3Yxool5g.js} +1 -1
- package/dist/{chunk-2Q5K7J3B-D2t88W5_.cjs → chunk-2Q5K7J3B-GdBcW8di.cjs} +1 -1
- package/dist/{chunk-32BRIVSS-DPtab14v.cjs → chunk-32BRIVSS-B08XoiLi.cjs} +1 -1
- package/dist/{chunk-32BRIVSS-8XP7uEWL.js → chunk-32BRIVSS-CVTMS7GT.js} +1 -1
- package/dist/{chunk-5VM5RSS4-BjciIcJB.cjs → chunk-5VM5RSS4-BQoi-IrE.cjs} +1 -1
- package/dist/{chunk-5VM5RSS4-D03FahtZ.js → chunk-5VM5RSS4-D9iWNvvu.js} +1 -1
- package/dist/{chunk-EX3LRPZG-CwaWU3NG.cjs → chunk-EX3LRPZG-BXIZ7mJ_.cjs} +1 -1
- package/dist/{chunk-EX3LRPZG-Cz4_aUcx.js → chunk-EX3LRPZG-CRf3FYTC.js} +21 -21
- package/dist/{chunk-JWPE2WC7-BhnZoEDO.cjs → chunk-JWPE2WC7-BziKhEzJ.cjs} +1 -1
- package/dist/{chunk-JWPE2WC7-CZnRHc3B.js → chunk-JWPE2WC7-D2PL9wSE.js} +1 -1
- package/dist/{chunk-MOJQB5TN-Bln4G16L.cjs → chunk-MOJQB5TN-BZPg0rA4.cjs} +1 -1
- package/dist/{chunk-MOJQB5TN-CAgrBpGK.js → chunk-MOJQB5TN-DcKI-L1a.js} +7 -7
- package/dist/{chunk-PUDLZKDR-Chc4If4v.js → chunk-PUDLZKDR-DDUAtfaX.js} +6 -6
- package/dist/{chunk-PUDLZKDR-ZSUOxhwQ.cjs → chunk-PUDLZKDR-DtwY_vfa.cjs} +1 -1
- package/dist/{chunk-RYQCIY6F-CmqX9MNK.cjs → chunk-RYQCIY6F-BczXRQc_.cjs} +1 -1
- package/dist/{chunk-RYQCIY6F-BWJMA-CG.js → chunk-RYQCIY6F-CrSm-DUq.js} +5 -5
- package/dist/{chunk-V7JOEXUC-B13vGPTt.cjs → chunk-V7JOEXUC-DHDaKlaz.cjs} +1 -1
- package/dist/{chunk-V7JOEXUC-DxTIfD2Z.js → chunk-V7JOEXUC-fKZqn2BY.js} +15 -15
- package/dist/{chunk-VR4S4FIN-CbzSMdlG.js → chunk-VR4S4FIN-CB1TUCm-.js} +3 -3
- package/dist/{chunk-VR4S4FIN-C67CWetO.cjs → chunk-VR4S4FIN-CbOikBFH.cjs} +1 -1
- package/dist/{chunk-XXDRQBXY-D00l-azL.cjs → chunk-XXDRQBXY-BNQCeyB9.cjs} +1 -1
- package/dist/{chunk-XXDRQBXY-DF5XNYDF.js → chunk-XXDRQBXY-K8anqUB1.js} +1 -1
- package/dist/{classDiagram-v2-EOCWNBFH-BVXrsjAy.js → classDiagram-OUVF2IWQ-0DLLfHtC.js} +2 -2
- package/dist/{classDiagram-OUVF2IWQ-kTYC0DeX.cjs → classDiagram-OUVF2IWQ-D1vfgcCB.cjs} +1 -1
- package/dist/{classDiagram-OUVF2IWQ-BVXrsjAy.js → classDiagram-v2-EOCWNBFH-0DLLfHtC.js} +2 -2
- package/dist/{classDiagram-v2-EOCWNBFH-kTYC0DeX.cjs → classDiagram-v2-EOCWNBFH-D1vfgcCB.cjs} +1 -1
- package/dist/code-blocks.cjs +1 -0
- package/dist/code-blocks.d.ts +12 -0
- package/dist/code-blocks.js +36 -0
- package/dist/components/MarkdownRenderer.d.ts +6 -1
- package/dist/components/MarkdownViewer.d.ts +5 -1
- package/dist/components/SpreadsheetBlock.d.ts +24 -0
- package/dist/components/SpreadsheetToolbar.d.ts +21 -0
- package/dist/components/controlStyles.d.ts +3 -0
- package/dist/components/mdastNodes/CodeNode.d.ts +1 -0
- package/dist/components/spreadsheetClipboard.d.ts +16 -0
- package/dist/components/spreadsheetLabels.d.ts +33 -0
- package/dist/components/spreadsheetModel.d.ts +31 -0
- package/dist/components/viewerLabels.d.ts +6 -1
- package/dist/converter.wasm +0 -0
- package/dist/{cose-bilkent-JH36ORCC-lZuyWql7.js → cose-bilkent-JH36ORCC-DSrvI7Rp.js} +5 -5
- package/dist/{cose-bilkent-JH36ORCC-CbeyXphF.cjs → cose-bilkent-JH36ORCC-Flvn8Q3R.cjs} +1 -1
- package/dist/{cynefinDiagram-TSTJHNR4-DKAvatlk.js → cynefinDiagram-TSTJHNR4-BGtSNTPQ.js} +56 -56
- package/dist/{cynefinDiagram-TSTJHNR4-Cuqne60m.cjs → cynefinDiagram-TSTJHNR4-BxqOgmm9.cjs} +1 -1
- package/dist/{dagre-VKFMJZFB-DOl32ZLj.js → dagre-VKFMJZFB-Bq5NKuKi.js} +26 -26
- package/dist/{dagre-VKFMJZFB-D9B4A3vP.cjs → dagre-VKFMJZFB-CIQyEWnl.cjs} +1 -1
- package/dist/{diagram-FQU43EPY-DW9s8x-t.js → diagram-FQU43EPY-B4shMan7.js} +31 -31
- package/dist/{diagram-FQU43EPY-CyKNQRDz.cjs → diagram-FQU43EPY-C-3vCuEY.cjs} +1 -1
- package/dist/{diagram-G47NLZAW-JWyg9BAf.js → diagram-G47NLZAW-BnJ5uYMd.js} +49 -49
- package/dist/{diagram-G47NLZAW-Bd402kCS.cjs → diagram-G47NLZAW-BnVPH5jd.cjs} +1 -1
- package/dist/{diagram-NH7WQ7WH-O9D369xQ.cjs → diagram-NH7WQ7WH-4RGgOu7p.cjs} +1 -1
- package/dist/{diagram-NH7WQ7WH-CBVjs5Qb.js → diagram-NH7WQ7WH-9s11j-Nx.js} +15 -15
- package/dist/{diagram-OA4YK3LP-CGFLIsXt.cjs → diagram-OA4YK3LP-BBtbKikh.cjs} +1 -1
- package/dist/{diagram-OA4YK3LP-DwedHmnV.js → diagram-OA4YK3LP-CgqOV0tg.js} +25 -25
- package/dist/{diagram-WEI45ONY-BgJvkrqe.js → diagram-WEI45ONY-CvzP7VJ3.js} +67 -67
- package/dist/{diagram-WEI45ONY-CEsljMQV.cjs → diagram-WEI45ONY-DZKSviH2.cjs} +1 -1
- package/dist/{ebnfDiagram-CCIWWBDH-C7QZ4wXM.js → ebnfDiagram-CCIWWBDH-CJSyu4o9.js} +3 -3
- package/dist/{ebnfDiagram-CCIWWBDH-e9oWuIhA.cjs → ebnfDiagram-CCIWWBDH-DpiouxMS.cjs} +1 -1
- package/dist/{erDiagram-Q63AITRT-BdP8JBuN.cjs → erDiagram-Q63AITRT-BT1bGFxN.cjs} +1 -1
- package/dist/{erDiagram-Q63AITRT-OUarWTK1.js → erDiagram-Q63AITRT-BxRdYBzJ.js} +19 -19
- package/dist/extractHeadings-B-v1O82x.cjs +314 -0
- package/dist/{extractHeadings-CUTXOBTa.js → extractHeadings-SqtThWou.js} +6472 -5968
- package/dist/flowDiagram-23GEKE2U-C-drHfAk.js +7 -0
- package/dist/flowDiagram-23GEKE2U-Cr8_S21X.cjs +1 -0
- package/dist/{ganttDiagram-NO4QXBWP-DjqYneGy.cjs → ganttDiagram-NO4QXBWP-BXUukgtA.cjs} +1 -1
- package/dist/{ganttDiagram-NO4QXBWP-7q1R_3-p.js → ganttDiagram-NO4QXBWP-BbNFbubH.js} +2 -2
- package/dist/{gitGraphDiagram-IHSO6WYX-B5gb3Rqu.js → gitGraphDiagram-IHSO6WYX-BY7URUuV.js} +10 -10
- package/dist/{gitGraphDiagram-IHSO6WYX-BjogZ4FH.cjs → gitGraphDiagram-IHSO6WYX-CtRl8SF8.cjs} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.client.cjs +1 -1
- package/dist/index.client.d.ts +3 -1
- package/dist/index.client.js +38 -36
- package/dist/index.js +38 -36
- package/dist/{infoDiagram-FWYZ7A6U-BaKyN9IA.js → infoDiagram-FWYZ7A6U-BwM_aV37.js} +3 -3
- package/dist/{infoDiagram-FWYZ7A6U-BkG_Sltp.cjs → infoDiagram-FWYZ7A6U-DjbpQufv.cjs} +1 -1
- package/dist/{ishikawaDiagram-FXEZZL3T-CSv6cDIC.js → ishikawaDiagram-FXEZZL3T-CWHT2wjh.js} +35 -35
- package/dist/{ishikawaDiagram-FXEZZL3T-CiyiRY0n.cjs → ishikawaDiagram-FXEZZL3T-D0k3NpJW.cjs} +1 -1
- package/dist/{journeyDiagram-5HDEW3XC-CidOpS4e.cjs → journeyDiagram-5HDEW3XC-BAzrW3sk.cjs} +1 -1
- package/dist/{journeyDiagram-5HDEW3XC-BSe4iQ8y.js → journeyDiagram-5HDEW3XC-CTBamWVg.js} +30 -30
- package/dist/{kanban-definition-HUTT4EX6-NcWyJMi_.js → kanban-definition-HUTT4EX6-DX8ATmyc.js} +47 -47
- package/dist/{kanban-definition-HUTT4EX6-E7S0-2B0.cjs → kanban-definition-HUTT4EX6-vEBxhqy3.cjs} +1 -1
- package/dist/{linear-DBHjPQ2a.js → linear-CUPbFHK0.js} +5 -5
- package/dist/{linear-DVrRITf5.cjs → linear-DO7t2MIy.cjs} +1 -1
- package/dist/{mindmap-definition-LN4V7U3C-CPgaG7JV.cjs → mindmap-definition-LN4V7U3C-CPgbGhe0.cjs} +1 -1
- package/dist/{mindmap-definition-LN4V7U3C-ddxMumCY.js → mindmap-definition-LN4V7U3C-CZiyButG.js} +11 -11
- package/dist/{pegDiagram-2B236MQR-CLzXETR3.js → pegDiagram-2B236MQR-BTTxMeDC.js} +3 -3
- package/dist/{pegDiagram-2B236MQR-CA_DeqqA.cjs → pegDiagram-2B236MQR-DFSWh2UC.cjs} +1 -1
- package/dist/{pieDiagram-ENE6RG2P-WVn8XJGb.js → pieDiagram-ENE6RG2P-5OqZWuO-.js} +49 -49
- package/dist/{pieDiagram-ENE6RG2P-Dg04F48S.cjs → pieDiagram-ENE6RG2P-DWsTb8I9.cjs} +1 -1
- package/dist/{quadrantDiagram-ABIIQ3AL-BsckSYJt.cjs → quadrantDiagram-ABIIQ3AL-BnIKvRMS.cjs} +1 -1
- package/dist/{quadrantDiagram-ABIIQ3AL-DyWlNOhT.js → quadrantDiagram-ABIIQ3AL-DimV94Rb.js} +45 -45
- package/dist/{railroadDiagram-RFXS5EU6-D3VxK11o.js → railroadDiagram-RFXS5EU6-CO_q8JT9.js} +3 -3
- package/dist/{railroadDiagram-RFXS5EU6-DCnQVXco.cjs → railroadDiagram-RFXS5EU6-D7cUshy0.cjs} +1 -1
- package/dist/{requirementDiagram-TGXJPOKE-BMaGXiNU.js → requirementDiagram-TGXJPOKE-Ceitr12-.js} +3 -3
- package/dist/{requirementDiagram-TGXJPOKE-DXCyNSis.cjs → requirementDiagram-TGXJPOKE-CjPsjAsx.cjs} +1 -1
- package/dist/{sankeyDiagram-HTMAVEWB-BX6vKeUm.js → sankeyDiagram-HTMAVEWB-CAfuQjzU.js} +47 -47
- package/dist/{sankeyDiagram-HTMAVEWB-D1m7iBLQ.cjs → sankeyDiagram-HTMAVEWB-CQhx84em.cjs} +1 -1
- package/dist/{sequenceDiagram-DBY2YBRQ-0mMExPO7.js → sequenceDiagram-DBY2YBRQ-BZ2yIdO6.js} +3 -3
- package/dist/{sequenceDiagram-DBY2YBRQ-BOZ4f_Hs.cjs → sequenceDiagram-DBY2YBRQ-Cr1VcoK2.cjs} +1 -1
- package/dist/{sizeCapture-X5ZJPWSS-0Q0rI-PZ.cjs → sizeCapture-X5ZJPWSS-B5X1945u.cjs} +1 -1
- package/dist/{sizeCapture-X5ZJPWSS-CFgV5LdI.js → sizeCapture-X5ZJPWSS-CA-VZP1J.js} +1 -1
- package/dist/{stateDiagram-2N3HPSRC-Co2cQg3S.cjs → stateDiagram-2N3HPSRC-BeP4b2HS.cjs} +1 -1
- package/dist/{stateDiagram-2N3HPSRC-BbQVKPdF.js → stateDiagram-2N3HPSRC-CbAk-IE5.js} +13 -13
- package/dist/{stateDiagram-v2-6OUMAXLB-QePyEJnH.js → stateDiagram-v2-6OUMAXLB-C5uUx1aU.js} +2 -2
- package/dist/{stateDiagram-v2-6OUMAXLB-Boy-ppxx.cjs → stateDiagram-v2-6OUMAXLB-L_ypLgkx.cjs} +1 -1
- package/dist/styles/markdown.css +1 -1
- package/dist/styles/markdown.standalone.css +1 -1
- package/dist/{swimlanes-5IMT3BWC-D4n1siHn.js → swimlanes-5IMT3BWC-BOKZHjmn.js} +313 -313
- package/dist/{swimlanes-5IMT3BWC-Cqs5VVSm.cjs → swimlanes-5IMT3BWC-DGpEXqaM.cjs} +1 -1
- package/dist/{swimlanesDiagram-G3AALYLV-Da8ZZAJn.js → swimlanesDiagram-G3AALYLV-BG07hh3H.js} +2 -2
- package/dist/{swimlanesDiagram-G3AALYLV-DVHw2s5w.cjs → swimlanesDiagram-G3AALYLV-DqChJVS9.cjs} +1 -1
- package/dist/{timeline-definition-FHXFAJF6-BGK-KyNC.js → timeline-definition-FHXFAJF6-Ct3xWe_j.js} +40 -40
- package/dist/{timeline-definition-FHXFAJF6-D25i6kkS.cjs → timeline-definition-FHXFAJF6-O0HVNX0c.cjs} +1 -1
- package/dist/{vennDiagram-L72KCM5P-8XQ-KXbG.cjs → vennDiagram-L72KCM5P-BqOqbGRA.cjs} +1 -1
- package/dist/{vennDiagram-L72KCM5P-CLkAwtsq.js → vennDiagram-L72KCM5P-DCY6NWkD.js} +124 -124
- package/dist/{wardleyDiagram-EHGQE667-DPCJNwRB.cjs → wardleyDiagram-EHGQE667-B2Civob5.cjs} +1 -1
- package/dist/{wardleyDiagram-EHGQE667-C0S3P_7H.js → wardleyDiagram-EHGQE667-CYStGsZi.js} +25 -25
- package/dist/{xychartDiagram-FW5EYKEG-DAacRCtv.js → xychartDiagram-FW5EYKEG-BifGB5it.js} +40 -40
- package/dist/{xychartDiagram-FW5EYKEG-BTE5ffMN.cjs → xychartDiagram-FW5EYKEG-C4GuhADi.cjs} +1 -1
- package/package.json +16 -7
- package/dist/arc-Eb0BfUPO.js +0 -83
- package/dist/extractHeadings-agc-00bD.cjs +0 -311
- package/dist/flowDiagram-23GEKE2U-BZYdQMwk.js +0 -7
- package/dist/flowDiagram-23GEKE2U-DDjpVH-X.cjs +0 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { p as B } from "./chunk-JWPE2WC7-
|
|
2
|
-
import { _ as b,
|
|
1
|
+
import { p as B } from "./chunk-JWPE2WC7-D2PL9wSE.js";
|
|
2
|
+
import { _ as b, ak as m, an as C, V as S, U as w, O as D, K as T, a8 as P, a9 as z, J as E, G as F, ai as A, al as W, ae as _ } from "./extractHeadings-SqtThWou.js";
|
|
3
3
|
import { p as N } from "./cynefin-VYW2F7L2-Bkk-F_Js.js";
|
|
4
4
|
var L = W.packet, u, v = (u = class {
|
|
5
5
|
constructor() {
|
|
6
|
-
this.packet = [], this.setAccTitle = D, this.getAccTitle = T, this.setDiagramTitle =
|
|
6
|
+
this.packet = [], this.setAccTitle = D, this.getAccTitle = T, this.setDiagramTitle = P, this.getDiagramTitle = z, this.getAccDescription = E, this.setAccDescription = F;
|
|
7
7
|
}
|
|
8
8
|
getConfig() {
|
|
9
9
|
const t = m({
|
|
10
10
|
...L,
|
|
11
|
-
...
|
|
11
|
+
...A().packet
|
|
12
12
|
});
|
|
13
13
|
return t.showBits && (t.paddingY += 10), t;
|
|
14
14
|
}
|
|
@@ -21,7 +21,7 @@ var L = W.packet, u, v = (u = class {
|
|
|
21
21
|
clear() {
|
|
22
22
|
_(), this.packet = [];
|
|
23
23
|
}
|
|
24
|
-
}, b(u, "PacketDB"), u), M = 1e4,
|
|
24
|
+
}, b(u, "PacketDB"), u), M = 1e4, O = /* @__PURE__ */ b((e, t) => {
|
|
25
25
|
B(e, t);
|
|
26
26
|
let r = -1, s = [], n = 1;
|
|
27
27
|
const { bitsPerRow: l } = t.getConfig();
|
|
@@ -35,14 +35,14 @@ var L = W.packet, u, v = (u = class {
|
|
|
35
35
|
if (d === 0)
|
|
36
36
|
throw new Error(`Packet block ${a} is invalid. Cannot have a zero bit field.`);
|
|
37
37
|
for (i ??= a + (d ?? 1) - 1, d ??= i - a + 1, r = i, w.debug(`Packet block ${a} - ${r} with label ${c}`); s.length <= l + 1 && t.getPacket().length < M; ) {
|
|
38
|
-
const [p, o] =
|
|
38
|
+
const [p, o] = Y({ start: a, end: i, bits: d, label: c }, n, l);
|
|
39
39
|
if (s.push(p), p.end + 1 === n * l && (t.pushWord(s), s = [], n++), !o)
|
|
40
40
|
break;
|
|
41
41
|
({ start: a, end: i, bits: d, label: c } = o);
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
t.pushWord(s);
|
|
45
|
-
}, "populate"),
|
|
45
|
+
}, "populate"), Y = /* @__PURE__ */ b((e, t, r) => {
|
|
46
46
|
if (e.start === void 0)
|
|
47
47
|
throw new Error("start should have been set during first phase");
|
|
48
48
|
if (e.end === void 0)
|
|
@@ -75,7 +75,7 @@ var L = W.packet, u, v = (u = class {
|
|
|
75
75
|
throw new Error(
|
|
76
76
|
"parser.parser?.yy was not a PacketDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues."
|
|
77
77
|
);
|
|
78
|
-
w.debug(t),
|
|
78
|
+
w.debug(t), O(t, r);
|
|
79
79
|
}, "parse")
|
|
80
80
|
}, G = /* @__PURE__ */ b((e, t, r, s) => {
|
|
81
81
|
const n = s.db, l = n.getConfig(), { rowHeight: a, paddingY: i, bitWidth: d, bitsPerRow: c } = l, p = n.getPacket(), o = n.getDiagramTitle(), h = a + i, g = h * (p.length + 1) - (o ? 0 : a), k = d * c + 2, f = C(t);
|
|
@@ -92,7 +92,7 @@ var L = W.packet, u, v = (u = class {
|
|
|
92
92
|
const k = o.end === o.start, f = p - 2;
|
|
93
93
|
c.append("text").attr("x", h + (k ? g / 2 : 0)).attr("y", f).attr("class", "packetByte start").attr("dominant-baseline", "auto").attr("text-anchor", k ? "middle" : "start").text(o.start), k || c.append("text").attr("x", h + g).attr("y", f).attr("class", "packetByte end").attr("dominant-baseline", "auto").attr("text-anchor", "end").text(o.end);
|
|
94
94
|
}
|
|
95
|
-
}, "drawWord"),
|
|
95
|
+
}, "drawWord"), K = { draw: G }, U = {
|
|
96
96
|
byteFontSize: "10px",
|
|
97
97
|
startByteColor: "black",
|
|
98
98
|
endByteColor: "black",
|
|
@@ -103,8 +103,8 @@ var L = W.packet, u, v = (u = class {
|
|
|
103
103
|
blockStrokeColor: "black",
|
|
104
104
|
blockStrokeWidth: "1",
|
|
105
105
|
blockFillColor: "#efefef"
|
|
106
|
-
},
|
|
107
|
-
const t = m(
|
|
106
|
+
}, j = /* @__PURE__ */ b(({ packet: e } = {}) => {
|
|
107
|
+
const t = m(U, e);
|
|
108
108
|
return `
|
|
109
109
|
.packetByte {
|
|
110
110
|
font-size: ${t.byteFontSize};
|
|
@@ -129,14 +129,14 @@ var L = W.packet, u, v = (u = class {
|
|
|
129
129
|
fill: ${t.blockFillColor};
|
|
130
130
|
}
|
|
131
131
|
`;
|
|
132
|
-
}, "styles"),
|
|
132
|
+
}, "styles"), V = {
|
|
133
133
|
parser: x,
|
|
134
134
|
get db() {
|
|
135
135
|
return new v();
|
|
136
136
|
},
|
|
137
|
-
renderer:
|
|
138
|
-
styles:
|
|
137
|
+
renderer: K,
|
|
138
|
+
styles: j
|
|
139
139
|
};
|
|
140
140
|
export {
|
|
141
|
-
|
|
141
|
+
V as diagram
|
|
142
142
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("./chunk-2Q5K7J3B-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("./chunk-2Q5K7J3B-GdBcW8di.cjs"),H=require("./chunk-JWPE2WC7-BziKhEzJ.cjs"),r=require("./extractHeadings-B-v1O82x.cjs"),z=require("./cynefin-VYW2F7L2-MpAliYy9.cjs");var V=/[─━│┃└┗├┣]/,$=/[└┗├┣]/,O=/[─━]/,T=/^[\s│┃]+$/,B=/^\s*(title[\t ]|accTitle[\t ]*:|accDescr[\t ]*[:{])/,k=/^\s*%%/,X=" ";function D(n){return n.some(e=>V.test(e))}r.__name(D,"isBoxDrawingFormat");function S(n){for(const e of n){const t=$.exec(e);if(t?.index&&t.index>0)return t.index}return 4}r.__name(S,"inferSegmentWidth");function E(n,e){return n.replace(/\bline\s+(\d+)\b/gi,(t,i)=>{const o=parseInt(i,10),c=e.get(o);return c?`line ${c}`:t})}r.__name(E,"remapErrorLines");function N(n){const e=n.split(`
|
|
2
2
|
`),t=new Map;let i=-1;for(const[a,s]of e.entries())if(s.trim()==="treeView-beta"){i=a;break}if(i===-1)return{text:n,lineMap:t};const o=[];for(let a=i+1;a<e.length;a++){const s=e[a];s.trim()===""||k.test(s)||B.test(s)||T.test(s)||o.push(s.replace(/\t/g," "))}if(!D(o))return{text:n,lineMap:t};const c=S(o),l=[];let d=0;for(let a=0;a<=i;a++)l.push(e[a]),d++,t.set(d,a+1);for(let a=i+1;a<e.length;a++){const s=e[a],g=s.trim(),p=a+1;if(g===""){l.push(s),d++,t.set(d,p);continue}if(k.test(s)){l.push(s),d++,t.set(d,p);continue}if(B.test(s)){l.push(s),d++,t.set(d,p);continue}if(T.test(s))continue;const h=s.replace(/\t/g," "),m=$.exec(h);if(m?.index!==void 0){const f=m.index,w=Math.round(f/c)+1;let u=f+1;for(;u<h.length&&O.test(h[u]);)u++;for(;u<h.length&&h[u]===" ";)u++;const _=h.slice(u).trimEnd();if(!_)throw new Error(`Line ${p}: Empty node — expected a filename or directory name after the box-drawing prefix`);const R=X.repeat(w);l.push(R+_),d++,t.set(d,p)}else{if(/^[\s─━│┃└┗├┣]+$/.test(h))continue;if(V.test(h))l.push(s),d++,t.set(d,p);else{if(/^\s+/.test(h))throw new Error(`Line ${p}: Unexpected indentation without box-drawing characters. In box-drawing format, use ├── or └── prefixes for indented nodes.`);l.push(s),d++,t.set(d,p)}}}return{text:l.join(`
|
|
3
3
|
`),lineMap:t}}r.__name(N,"preprocessBoxDrawing");var x=new W.ImperativeState(()=>({cnt:1,stack:[{id:0,level:-1,name:"/",nodeType:"directory",children:[]}]})),G=r.__name(()=>{x.reset(),r.clear()},"clear"),P=r.__name(()=>x.records.stack[0],"getRoot"),Y=r.__name(()=>x.records.cnt,"getCount"),q=r.defaultConfig_default.treeView,F=r.__name(()=>r.cleanAndMerge(q,r.getConfig().treeView),"getConfig"),j=r.__name((n,e,t,i,o,c)=>{for(;n<=x.records.stack[x.records.stack.length-1].level;)x.records.stack.pop();const l={id:x.records.cnt++,level:n,name:e,nodeType:t,icon:o,cssClass:i,description:c,children:[]};x.records.stack[x.records.stack.length-1].children.push(l),x.records.stack.push(l)},"addNode"),Z={clear:G,addNode:j,getRoot:P,getCount:Y,getConfig:F,getAccTitle:r.getAccTitle,getAccDescription:r.getAccDescription,getDiagramTitle:r.getDiagramTitle,setAccDescription:r.setAccDescription,setAccTitle:r.setAccTitle,setDiagramTitle:r.setDiagramTitle},b=Z,J=r.__name(n=>{H.populateCommonDb(n,b);for(const e of n.nodes){const t=typeof e.indent=="number"?e.indent:0;let i=e.name;const o=i.endsWith("/");o&&(i=i.slice(0,-1));const c=o?"directory":"file",l=e.classAnnotation||void 0,d=e.iconAnnotation,a=d!==void 0?d||"none":void 0,s=e.descAnnotation||void 0,g=s?r.sanitizeText(s,r.getConfig()):void 0;b.addNode(t,i,c,l,a,g)}},"populate"),U={parse:r.__name(async n=>{const{text:e,lineMap:t}=N(n);try{const i=await z.parse("treeView",e);r.log.debug(i),J(i)}catch(i){throw t.size>0&&i instanceof Error&&(i.message=E(i.message,t)),i}},"parse")},v={prefix:"mermaid-treeview",height:24,width:24,icons:{folder:{body:'<path fill="currentColor" d="M10.59 4.59A2 2 0 0 0 9.17 4H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.17z"/>'},file:{body:'<path fill="currentColor" fill-rule="evenodd" d="M6 2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8.83a2 2 0 0 0-.59-1.42l-4.82-4.82A2 2 0 0 0 13.17 2H6Zm7.5 1.9l4.6 4.6h-3.6a1 1 0 0 1-1-1V3.9Z" clip-rule="evenodd"/>'}}};function L(n,e){const t=e?.filenameIcons?.[n];if(t)return t;const i=n.lastIndexOf(".");if(i>0){const o=n.substring(i).toLowerCase(),c=e?.extensionIcons;return c?.[o]??c?.[o.slice(1)]}}r.__name(L,"detectIcon");function C(n,e){return n.includes(":")?n:n in v.icons||!e?`${v.prefix}:${n}`:`${e}:${n}`}r.__name(C,"qualifyIcon");function I(n,e){if(n.icon!=="none"){if(n.icon)return C(n.icon,e.defaultIconPack);if(e.showIcons){if(n.nodeType==="file"){const t=L(n.name,e);if(t==="none")return;if(t)return C(t,e.defaultIconPack)}return`${v.prefix}:${n.nodeType==="directory"?"folder":"file"}`}}}r.__name(I,"getNodeIcon");r.registerIconPacks([{name:v.prefix,icons:v}]);var y=14,K=4,Q=16,M=r.__name((n,e)=>`tv-icon-${n}-${e.replace(/[^\w-]/g,"-")}`,"iconSymbolId"),ee=r.__name(async(n,e,t,i)=>{const o=new Set,c=r.__name(a=>{const s=I(a,t);s&&o.add(s),a.children.forEach(c)},"collect");if(c(e),o.size===0)return;const l=await Promise.all([...o].map(async a=>({icon:a,svg:await r.getIconSVG(a,{height:y,width:y})}))),d=n.append("defs");for(const{icon:a,svg:s}of l)d.append("g").attr("id",M(i,a)).html(s)},"injectIconDefs"),te=r.__name((n,e,t,i,o,c)=>{const l=i.append("g");let d="treeView-node-label";t.nodeType==="directory"&&(d+=" treeView-node-dir"),t.cssClass&&(d+=` ${t.cssClass}`);const a=y+K,s=I(t,o),g=s!==void 0;s&&l.append("use").attr("xlink:href",`#${M(c,s)}`).attr("x",n+o.paddingX).attr("y",e+o.paddingY).attr("class","treeView-node-icon");const p=l.append("text").text(t.name).attr("dominant-baseline","middle").attr("class",d),{height:h,width:m}=p.node().getBBox(),f=h+o.paddingY*2,w=n+o.paddingX+(g?a:0);p.attr("x",w),p.attr("y",e+f/2);const u=w+m,_=m+o.paddingX*2+(g?a:0);return t.BBox={x:n,y:e,width:_,height:f},t.cssClass?.split(/\s+/).includes("highlight")&&l.insert("rect",":first-child").attr("x",n).attr("y",e+1).attr("width",0).attr("height",f-2).attr("rx",3).attr("class","treeView-highlight-bg"),{node:t,nodeGroup:l,labelRightEdge:u,centerY:e+f/2}},"positionLabel"),A=r.__name((n,e,t,i,o,c)=>n.append("line").attr("x1",e).attr("y1",t).attr("x2",i).attr("y2",o).attr("stroke-width",c).attr("class","treeView-node-line"),"positionLine"),ne=r.__name((n,e,t,i)=>{let o=0,c=0;const l=[],d=r.__name((g,p,h,m)=>{const f=m*(h.rowIndent+h.paddingX),w=te(f,o,p,g,h,i);l.push(w);const{height:u,width:_}=p.BBox;A(g,f-h.rowIndent,o+u/2,f,o+u/2,h.lineThickness),c=Math.max(c,f+_),o+=u},"drawNode"),a=r.__name((g,p=0)=>{d(n,g,t,p),g.children.forEach(w=>{a(w,p+1)});const{x:h,y:m,height:f}=g.BBox;if(g.children.length){const{y:w,height:u}=g.children[g.children.length-1].BBox;A(n,h+t.paddingX,m+f,h+t.paddingX,w+u/2+t.lineThickness/2,t.lineThickness)}},"processNode");a(e);const s=l.filter(g=>g.node.description);if(s.length>0){const p=Math.max(...l.map(h=>h.labelRightEdge))+Q;for(const h of s){const f=h.nodeGroup.append("text").text(h.node.description).attr("dominant-baseline","middle").attr("class","treeView-node-description").attr("x",p).attr("y",h.centerY).node().getBBox();c=Math.max(c,p+f.width+t.paddingX)}}for(const g of l)if(g.node.cssClass?.split(/\s+/).includes("highlight")){const p=g.nodeGroup.select(".treeView-highlight-bg");if(!p.empty()){const h=c-g.node.BBox.x+8;p.attr("width",h),c=Math.max(c,g.node.BBox.x+h+2)}}return{totalHeight:o,totalWidth:c}},"drawTree"),re=r.__name(async(n,e,t,i)=>{r.log.debug(`Rendering treeView diagram
|
|
4
4
|
`+n);const o=i.db,c=o.getRoot(),l=o.getConfig(),d=r.selectSvgElement(e);await ee(d,c,l,e);const a=d.append("g");a.attr("class","tree-view");const{totalHeight:s,totalWidth:g}=ne(a,c,l,e);d.attr("viewBox",`-${l.lineThickness/2} 0 ${g} ${s}`),r.configureSvgSize(d,s,g,l.useMaxWidth)},"draw"),ie={draw:re},oe=ie,se={labelFontSize:"16px",labelColor:"black",lineColor:"black",iconColor:"#546e7a",descriptionColor:"#6a9955",highlightBg:"rgba(255, 193, 7, 0.15)",highlightStroke:"#ffc107"},ae=r.__name(({treeView:n})=>{const{labelFontSize:e,labelColor:t,lineColor:i,iconColor:o,descriptionColor:c,highlightBg:l,highlightStroke:d}=r.cleanAndMerge(se,n);return`
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { I as
|
|
2
|
-
import { p as
|
|
3
|
-
import {
|
|
1
|
+
import { I as W } from "./chunk-2Q5K7J3B-3Yxool5g.js";
|
|
2
|
+
import { p as X } from "./chunk-JWPE2WC7-D2PL9wSE.js";
|
|
3
|
+
import { a8 as G, O as Y, G as P, a9 as F, J as Z, K as j, _ as f, ak as A, U as N, an as U, V as q, ai as D, ae as J, Y as K, aZ as Q, al as ee, a_ as te } from "./extractHeadings-SqtThWou.js";
|
|
4
4
|
import { p as ne } from "./cynefin-VYW2F7L2-Bkk-F_Js.js";
|
|
5
|
-
var E = /[─━│┃└┗├┣]/, S = /[└┗├┣]/, re = /[─━]/, V = /^[\s│┃]+$/,
|
|
5
|
+
var E = /[─━│┃└┗├┣]/, S = /[└┗├┣]/, re = /[─━]/, V = /^[\s│┃]+$/, k = /^\s*(title[\t ]|accTitle[\t ]*:|accDescr[\t ]*[:{])/, $ = /^\s*%%/, ie = " ";
|
|
6
6
|
function L(n) {
|
|
7
7
|
return n.some((e) => E.test(e));
|
|
8
8
|
}
|
|
@@ -37,7 +37,7 @@ function R(n) {
|
|
|
37
37
|
const i = [];
|
|
38
38
|
for (let s = r + 1; s < e.length; s++) {
|
|
39
39
|
const o = e[s];
|
|
40
|
-
o.trim() === "" ||
|
|
40
|
+
o.trim() === "" || $.test(o) || k.test(o) || V.test(o) || i.push(o.replace(/\t/g, " "));
|
|
41
41
|
}
|
|
42
42
|
if (!L(i))
|
|
43
43
|
return { text: n, lineMap: t };
|
|
@@ -51,11 +51,11 @@ function R(n) {
|
|
|
51
51
|
c.push(o), l++, t.set(l, p);
|
|
52
52
|
continue;
|
|
53
53
|
}
|
|
54
|
-
if (
|
|
54
|
+
if ($.test(o)) {
|
|
55
55
|
c.push(o), l++, t.set(l, p);
|
|
56
56
|
continue;
|
|
57
57
|
}
|
|
58
|
-
if (
|
|
58
|
+
if (k.test(o)) {
|
|
59
59
|
c.push(o), l++, t.set(l, p);
|
|
60
60
|
continue;
|
|
61
61
|
}
|
|
@@ -74,8 +74,8 @@ function R(n) {
|
|
|
74
74
|
throw new Error(
|
|
75
75
|
`Line ${p}: Empty node — expected a filename or directory name after the box-drawing prefix`
|
|
76
76
|
);
|
|
77
|
-
const
|
|
78
|
-
c.push(
|
|
77
|
+
const O = ie.repeat(m);
|
|
78
|
+
c.push(O + v), l++, t.set(l, p);
|
|
79
79
|
} else {
|
|
80
80
|
if (/^[\s─━│┃└┗├┣]+$/.test(d))
|
|
81
81
|
continue;
|
|
@@ -94,7 +94,7 @@ function R(n) {
|
|
|
94
94
|
`), lineMap: t };
|
|
95
95
|
}
|
|
96
96
|
f(R, "preprocessBoxDrawing");
|
|
97
|
-
var x = new
|
|
97
|
+
var x = new W(() => ({
|
|
98
98
|
cnt: 1,
|
|
99
99
|
stack: [
|
|
100
100
|
{
|
|
@@ -127,20 +127,20 @@ var x = new X(() => ({
|
|
|
127
127
|
getRoot: se,
|
|
128
128
|
getCount: ae,
|
|
129
129
|
getConfig: le,
|
|
130
|
-
getAccTitle:
|
|
131
|
-
getAccDescription:
|
|
132
|
-
getDiagramTitle:
|
|
130
|
+
getAccTitle: j,
|
|
131
|
+
getAccDescription: Z,
|
|
132
|
+
getDiagramTitle: F,
|
|
133
133
|
setAccDescription: P,
|
|
134
134
|
setAccTitle: Y,
|
|
135
|
-
setDiagramTitle:
|
|
135
|
+
setDiagramTitle: G
|
|
136
136
|
}, I = he, pe = /* @__PURE__ */ f((n) => {
|
|
137
|
-
|
|
137
|
+
X(n, I);
|
|
138
138
|
for (const e of n.nodes) {
|
|
139
139
|
const t = typeof e.indent == "number" ? e.indent : 0;
|
|
140
140
|
let r = e.name;
|
|
141
141
|
const i = r.endsWith("/");
|
|
142
142
|
i && (r = r.slice(0, -1));
|
|
143
|
-
const a = i ? "directory" : "file", c = e.classAnnotation || void 0, l = e.iconAnnotation, s = l !== void 0 ? l || "none" : void 0, o = e.descAnnotation || void 0, h = o ?
|
|
143
|
+
const a = i ? "directory" : "file", c = e.classAnnotation || void 0, l = e.iconAnnotation, s = l !== void 0 ? l || "none" : void 0, o = e.descAnnotation || void 0, h = o ? K(o, D()) : void 0;
|
|
144
144
|
I.addNode(t, r, a, c, s, h);
|
|
145
145
|
}
|
|
146
146
|
}, "populate"), fe = {
|
|
@@ -166,7 +166,7 @@ var x = new X(() => ({
|
|
|
166
166
|
}
|
|
167
167
|
}
|
|
168
168
|
};
|
|
169
|
-
function
|
|
169
|
+
function H(n, e) {
|
|
170
170
|
const t = e?.filenameIcons?.[n];
|
|
171
171
|
if (t)
|
|
172
172
|
return t;
|
|
@@ -176,7 +176,7 @@ function z(n, e) {
|
|
|
176
176
|
return a?.[i] ?? a?.[i.slice(1)];
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
|
-
f(
|
|
179
|
+
f(H, "detectIcon");
|
|
180
180
|
function C(n, e) {
|
|
181
181
|
return n.includes(":") ? n : n in b.icons || !e ? `${b.prefix}:${n}` : `${e}:${n}`;
|
|
182
182
|
}
|
|
@@ -187,7 +187,7 @@ function B(n, e) {
|
|
|
187
187
|
return C(n.icon, e.defaultIconPack);
|
|
188
188
|
if (e.showIcons) {
|
|
189
189
|
if (n.nodeType === "file") {
|
|
190
|
-
const t =
|
|
190
|
+
const t = H(n.name, e);
|
|
191
191
|
if (t === "none")
|
|
192
192
|
return;
|
|
193
193
|
if (t)
|
|
@@ -204,7 +204,7 @@ te([
|
|
|
204
204
|
icons: b
|
|
205
205
|
}
|
|
206
206
|
]);
|
|
207
|
-
var y = 14, ge = 4, ue = 16,
|
|
207
|
+
var y = 14, ge = 4, ue = 16, z = /* @__PURE__ */ f((n, e) => `tv-icon-${n}-${e.replace(/[^\w-]/g, "-")}`, "iconSymbolId"), we = /* @__PURE__ */ f(async (n, e, t, r) => {
|
|
208
208
|
const i = /* @__PURE__ */ new Set(), a = /* @__PURE__ */ f((s) => {
|
|
209
209
|
const o = B(s, t);
|
|
210
210
|
o && i.add(o), s.children.forEach(a);
|
|
@@ -214,20 +214,20 @@ var y = 14, ge = 4, ue = 16, H = /* @__PURE__ */ f((n, e) => `tv-icon-${n}-${e.r
|
|
|
214
214
|
const c = await Promise.all(
|
|
215
215
|
[...i].map(async (s) => ({
|
|
216
216
|
icon: s,
|
|
217
|
-
svg: await
|
|
217
|
+
svg: await Q(s, {
|
|
218
218
|
height: y,
|
|
219
219
|
width: y
|
|
220
220
|
})
|
|
221
221
|
}))
|
|
222
222
|
), l = n.append("defs");
|
|
223
223
|
for (const { icon: s, svg: o } of c)
|
|
224
|
-
l.append("g").attr("id",
|
|
224
|
+
l.append("g").attr("id", z(r, s)).html(o);
|
|
225
225
|
}, "injectIconDefs"), me = /* @__PURE__ */ f((n, e, t, r, i, a) => {
|
|
226
226
|
const c = r.append("g");
|
|
227
227
|
let l = "treeView-node-label";
|
|
228
228
|
t.nodeType === "directory" && (l += " treeView-node-dir"), t.cssClass && (l += ` ${t.cssClass}`);
|
|
229
229
|
const s = y + ge, o = B(t, i), h = o !== void 0;
|
|
230
|
-
o && c.append("use").attr("xlink:href", `#${
|
|
230
|
+
o && c.append("use").attr("xlink:href", `#${z(a, o)}`).attr("x", n + i.paddingX).attr("y", e + i.paddingY).attr("class", "treeView-node-icon");
|
|
231
231
|
const p = c.append("text").text(t.name).attr("dominant-baseline", "middle").attr("class", l), { height: d, width: w } = p.node().getBBox(), g = d + i.paddingY * 2, m = n + i.paddingX + (h ? s : 0);
|
|
232
232
|
p.attr("x", m), p.attr("y", e + g / 2);
|
|
233
233
|
const u = m + w, v = w + i.paddingX * 2 + (h ? s : 0);
|
|
@@ -284,12 +284,12 @@ var y = 14, ge = 4, ue = 16, H = /* @__PURE__ */ f((n, e) => `tv-icon-${n}-${e.r
|
|
|
284
284
|
}, "drawTree"), ve = /* @__PURE__ */ f(async (n, e, t, r) => {
|
|
285
285
|
N.debug(`Rendering treeView diagram
|
|
286
286
|
` + n);
|
|
287
|
-
const i = r.db, a = i.getRoot(), c = i.getConfig(), l =
|
|
287
|
+
const i = r.db, a = i.getRoot(), c = i.getConfig(), l = U(e);
|
|
288
288
|
await we(l, a, c, e);
|
|
289
289
|
const s = l.append("g");
|
|
290
290
|
s.attr("class", "tree-view");
|
|
291
291
|
const { totalHeight: o, totalWidth: h } = xe(s, a, c, e);
|
|
292
|
-
l.attr("viewBox", `-${c.lineThickness / 2} 0 ${h} ${o}`),
|
|
292
|
+
l.attr("viewBox", `-${c.lineThickness / 2} 0 ${h} ${o}`), q(l, o, h, c.useMaxWidth);
|
|
293
293
|
}, "draw"), be = {
|
|
294
294
|
draw: ve
|
|
295
295
|
}, Ie = be, Ce = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { p as
|
|
2
|
-
import {
|
|
3
|
-
import { p as
|
|
4
|
-
var
|
|
1
|
+
import { p as k } from "./chunk-JWPE2WC7-D2PL9wSE.js";
|
|
2
|
+
import { G as R, J as I, a9 as _, a8 as E, K as F, O as D, _ as c, an as G, ae as P, ak as y, ai as C, al as z, U as B, ao as V, V as W } from "./extractHeadings-SqtThWou.js";
|
|
3
|
+
import { p as H } from "./cynefin-VYW2F7L2-Bkk-F_Js.js";
|
|
4
|
+
var h = {
|
|
5
5
|
showLegend: !0,
|
|
6
6
|
ticks: 5,
|
|
7
7
|
max: null,
|
|
@@ -10,11 +10,11 @@ var m = {
|
|
|
10
10
|
}, w = {
|
|
11
11
|
axes: [],
|
|
12
12
|
curves: [],
|
|
13
|
-
options:
|
|
14
|
-
}, x = structuredClone(w),
|
|
15
|
-
...
|
|
13
|
+
options: h
|
|
14
|
+
}, x = structuredClone(w), j = z.radar, U = /* @__PURE__ */ c(() => y({
|
|
15
|
+
...j,
|
|
16
16
|
...C().radar
|
|
17
|
-
}), "getConfig"), b = /* @__PURE__ */ c(() => x.axes, "getAxes"),
|
|
17
|
+
}), "getConfig"), b = /* @__PURE__ */ c(() => x.axes, "getAxes"), J = /* @__PURE__ */ c(() => x.curves, "getCurves"), K = /* @__PURE__ */ c(() => x.options, "getOptions"), N = /* @__PURE__ */ c((a) => {
|
|
18
18
|
x.axes = a.map((t) => ({
|
|
19
19
|
name: t.name,
|
|
20
20
|
label: t.label ?? t.name
|
|
@@ -32,7 +32,7 @@ var m = {
|
|
|
32
32
|
if (t.length === 0)
|
|
33
33
|
throw new Error("Axes must be populated before curves for reference entries");
|
|
34
34
|
return t.map((e) => {
|
|
35
|
-
const r = a.find((
|
|
35
|
+
const r = a.find((n) => n.axis?.$refText === e.name);
|
|
36
36
|
if (r === void 0)
|
|
37
37
|
throw new Error("Missing entry for axis " + e.label);
|
|
38
38
|
return r.value;
|
|
@@ -43,102 +43,102 @@ var m = {
|
|
|
43
43
|
{}
|
|
44
44
|
);
|
|
45
45
|
x.options = {
|
|
46
|
-
showLegend: t.showLegend?.value ??
|
|
47
|
-
ticks: t.ticks?.value ??
|
|
48
|
-
max: t.max?.value ??
|
|
49
|
-
min: t.min?.value ??
|
|
50
|
-
graticule: t.graticule?.value ??
|
|
46
|
+
showLegend: t.showLegend?.value ?? h.showLegend,
|
|
47
|
+
ticks: t.ticks?.value ?? h.ticks,
|
|
48
|
+
max: t.max?.value ?? h.max,
|
|
49
|
+
min: t.min?.value ?? h.min,
|
|
50
|
+
graticule: t.graticule?.value ?? h.graticule
|
|
51
51
|
};
|
|
52
52
|
}, "setOptions"), q = /* @__PURE__ */ c(() => {
|
|
53
|
-
|
|
53
|
+
P(), x = structuredClone(w);
|
|
54
54
|
}, "clear"), $ = {
|
|
55
55
|
getAxes: b,
|
|
56
|
-
getCurves:
|
|
57
|
-
getOptions:
|
|
58
|
-
setAxes:
|
|
56
|
+
getCurves: J,
|
|
57
|
+
getOptions: K,
|
|
58
|
+
setAxes: N,
|
|
59
59
|
setCurves: X,
|
|
60
60
|
setOptions: Z,
|
|
61
|
-
getConfig:
|
|
61
|
+
getConfig: U,
|
|
62
62
|
clear: q,
|
|
63
63
|
setAccTitle: D,
|
|
64
64
|
getAccTitle: F,
|
|
65
65
|
setDiagramTitle: E,
|
|
66
66
|
getDiagramTitle: _,
|
|
67
67
|
getAccDescription: I,
|
|
68
|
-
setAccDescription:
|
|
69
|
-
},
|
|
70
|
-
|
|
68
|
+
setAccDescription: R
|
|
69
|
+
}, Q = /* @__PURE__ */ c((a) => {
|
|
70
|
+
k(a, $);
|
|
71
71
|
const { axes: t, curves: e, options: r } = a;
|
|
72
72
|
$.setAxes(t), $.setCurves(e), $.setOptions(r);
|
|
73
73
|
}, "populate"), tt = {
|
|
74
74
|
parse: /* @__PURE__ */ c(async (a) => {
|
|
75
|
-
const t = await
|
|
76
|
-
B.debug(t),
|
|
75
|
+
const t = await H("radar", a);
|
|
76
|
+
B.debug(t), Q(t);
|
|
77
77
|
}, "parse")
|
|
78
78
|
}, et = /* @__PURE__ */ c((a, t, e, r) => {
|
|
79
|
-
const
|
|
80
|
-
rt(u, i, v,
|
|
79
|
+
const n = r.db, i = n.getAxes(), l = n.getCurves(), s = n.getOptions(), o = n.getConfig(), d = n.getDiagramTitle(), p = G(t), u = at(p, o), g = s.max ?? Math.max(...l.map((f) => Math.max(...f.entries))), m = s.min, v = Math.min(o.width, o.height) / 2;
|
|
80
|
+
rt(u, i, v, s.ticks, s.graticule), nt(u, i, v, o), A(u, i, l, m, g, s.graticule, o), T(u, l, s.showLegend, o), u.append("text").attr("class", "radarTitle").text(d).attr("x", 0).attr("y", -o.height / 2 - o.marginTop);
|
|
81
81
|
}, "draw"), at = /* @__PURE__ */ c((a, t) => {
|
|
82
|
-
const e = t.width + t.marginLeft + t.marginRight, r = t.height + t.marginTop + t.marginBottom,
|
|
82
|
+
const e = t.width + t.marginLeft + t.marginRight, r = t.height + t.marginTop + t.marginBottom, n = {
|
|
83
83
|
x: t.marginLeft + t.width / 2,
|
|
84
84
|
y: t.marginTop + t.height / 2
|
|
85
85
|
};
|
|
86
|
-
return
|
|
87
|
-
}, "drawFrame"), rt = /* @__PURE__ */ c((a, t, e, r,
|
|
88
|
-
if (
|
|
86
|
+
return W(a, r, e, t.useMaxWidth ?? !0), a.attr("viewBox", `0 0 ${e} ${r}`).attr("overflow", "visible"), a.append("g").attr("transform", `translate(${n.x}, ${n.y})`);
|
|
87
|
+
}, "drawFrame"), rt = /* @__PURE__ */ c((a, t, e, r, n) => {
|
|
88
|
+
if (n === "circle")
|
|
89
89
|
for (let i = 0; i < r; i++) {
|
|
90
90
|
const l = e * (i + 1) / r;
|
|
91
91
|
a.append("circle").attr("r", l).attr("class", "radarGraticule");
|
|
92
92
|
}
|
|
93
|
-
else if (
|
|
93
|
+
else if (n === "polygon") {
|
|
94
94
|
const i = t.length;
|
|
95
95
|
for (let l = 0; l < r; l++) {
|
|
96
|
-
const
|
|
97
|
-
const u = 2 * p * Math.PI / i - Math.PI / 2, g =
|
|
98
|
-
return `${g},${
|
|
96
|
+
const s = e * (l + 1) / r, o = t.map((d, p) => {
|
|
97
|
+
const u = 2 * p * Math.PI / i - Math.PI / 2, g = s * Math.cos(u), m = s * Math.sin(u);
|
|
98
|
+
return `${g},${m}`;
|
|
99
99
|
}).join(" ");
|
|
100
100
|
a.append("polygon").attr("points", o).attr("class", "radarGraticule");
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
|
-
}, "drawGraticule"),
|
|
104
|
-
const
|
|
105
|
-
for (let i = 0; i <
|
|
106
|
-
const l = t[i].label,
|
|
103
|
+
}, "drawGraticule"), nt = /* @__PURE__ */ c((a, t, e, r) => {
|
|
104
|
+
const n = t.length;
|
|
105
|
+
for (let i = 0; i < n; i++) {
|
|
106
|
+
const l = t[i].label, s = 2 * i * Math.PI / n - Math.PI / 2, o = Math.cos(s), d = Math.sin(s);
|
|
107
107
|
a.append("line").attr("x1", 0).attr("y1", 0).attr("x2", e * r.axisScaleFactor * o).attr("y2", e * r.axisScaleFactor * d).attr("class", "radarAxisLine");
|
|
108
108
|
const p = o > 0.01 ? "start" : o < -0.01 ? "end" : "middle", u = d > 0.01 ? "hanging" : d < -0.01 ? "auto" : "central", g = 4;
|
|
109
109
|
a.append("text").text(l).attr("x", e * r.axisLabelFactor * o + g * o).attr("y", e * r.axisLabelFactor * d + g * d).attr("text-anchor", p).attr("dominant-baseline", u).attr("class", "radarAxisLabel");
|
|
110
110
|
}
|
|
111
111
|
}, "drawAxes");
|
|
112
|
-
function A(a, t, e, r,
|
|
113
|
-
const
|
|
112
|
+
function A(a, t, e, r, n, i, l) {
|
|
113
|
+
const s = t.length, o = Math.min(l.width, l.height) / 2;
|
|
114
114
|
e.forEach((d, p) => {
|
|
115
|
-
if (d.entries.length !==
|
|
115
|
+
if (d.entries.length !== s)
|
|
116
116
|
return;
|
|
117
|
-
const u = d.entries.map((g,
|
|
118
|
-
const v = 2 * Math.PI *
|
|
119
|
-
return { x:
|
|
117
|
+
const u = d.entries.map((g, m) => {
|
|
118
|
+
const v = 2 * Math.PI * m / s - Math.PI / 2, f = M(g, r, n, o), O = f * Math.cos(v), S = f * Math.sin(v);
|
|
119
|
+
return { x: O, y: S };
|
|
120
120
|
});
|
|
121
121
|
i === "circle" ? a.append("path").attr("d", L(u, l.curveTension)).attr("class", `radarCurve-${p}`) : i === "polygon" && a.append("polygon").attr("points", u.map((g) => `${g.x},${g.y}`).join(" ")).attr("class", `radarCurve-${p}`);
|
|
122
122
|
});
|
|
123
123
|
}
|
|
124
124
|
c(A, "drawCurves");
|
|
125
125
|
function M(a, t, e, r) {
|
|
126
|
-
const
|
|
127
|
-
return r * (
|
|
126
|
+
const n = Math.min(Math.max(a, t), e);
|
|
127
|
+
return r * (n - t) / (e - t);
|
|
128
128
|
}
|
|
129
129
|
c(M, "relativeRadius");
|
|
130
130
|
function L(a, t) {
|
|
131
131
|
const e = a.length;
|
|
132
132
|
let r = `M${a[0].x},${a[0].y}`;
|
|
133
|
-
for (let
|
|
134
|
-
const i = a[(
|
|
135
|
-
x: l.x + (
|
|
136
|
-
y: l.y + (
|
|
133
|
+
for (let n = 0; n < e; n++) {
|
|
134
|
+
const i = a[(n - 1 + e) % e], l = a[n], s = a[(n + 1) % e], o = a[(n + 2) % e], d = {
|
|
135
|
+
x: l.x + (s.x - i.x) * t,
|
|
136
|
+
y: l.y + (s.y - i.y) * t
|
|
137
137
|
}, p = {
|
|
138
|
-
x:
|
|
139
|
-
y:
|
|
138
|
+
x: s.x - (o.x - l.x) * t,
|
|
139
|
+
y: s.y - (o.y - l.y) * t
|
|
140
140
|
};
|
|
141
|
-
r += ` C${d.x},${d.y} ${p.x},${p.y} ${
|
|
141
|
+
r += ` C${d.x},${d.y} ${p.x},${p.y} ${s.x},${s.y}`;
|
|
142
142
|
}
|
|
143
143
|
return `${r} Z`;
|
|
144
144
|
}
|
|
@@ -146,36 +146,36 @@ c(L, "closedRoundCurve");
|
|
|
146
146
|
function T(a, t, e, r) {
|
|
147
147
|
if (!e)
|
|
148
148
|
return;
|
|
149
|
-
const
|
|
150
|
-
t.forEach((
|
|
151
|
-
const d = a.append("g").attr("transform", `translate(${
|
|
152
|
-
d.append("rect").attr("width", 12).attr("height", 12).attr("class", `radarLegendBox-${o}`), d.append("text").attr("x", 16).attr("y", 0).attr("class", "radarLegendText").text(
|
|
149
|
+
const n = (r.width / 2 + r.marginRight) * 3 / 4, i = -(r.height / 2 + r.marginTop) * 3 / 4, l = 20;
|
|
150
|
+
t.forEach((s, o) => {
|
|
151
|
+
const d = a.append("g").attr("transform", `translate(${n}, ${i + o * l})`);
|
|
152
|
+
d.append("rect").attr("width", 12).attr("height", 12).attr("class", `radarLegendBox-${o}`), d.append("text").attr("x", 16).attr("y", 0).attr("class", "radarLegendText").text(s.label);
|
|
153
153
|
});
|
|
154
154
|
}
|
|
155
155
|
c(T, "drawLegend");
|
|
156
|
-
var
|
|
156
|
+
var st = { draw: et }, ot = /* @__PURE__ */ c((a, t) => {
|
|
157
157
|
let e = "";
|
|
158
158
|
for (let r = 0; r < a.THEME_COLOR_LIMIT; r++) {
|
|
159
|
-
const
|
|
159
|
+
const n = a[`cScale${r}`];
|
|
160
160
|
e += `
|
|
161
161
|
.radarCurve-${r} {
|
|
162
|
-
color: ${
|
|
163
|
-
fill: ${
|
|
162
|
+
color: ${n};
|
|
163
|
+
fill: ${n};
|
|
164
164
|
fill-opacity: ${t.curveOpacity};
|
|
165
|
-
stroke: ${
|
|
165
|
+
stroke: ${n};
|
|
166
166
|
stroke-width: ${t.curveStrokeWidth};
|
|
167
167
|
}
|
|
168
168
|
.radarLegendBox-${r} {
|
|
169
|
-
fill: ${
|
|
169
|
+
fill: ${n};
|
|
170
170
|
fill-opacity: ${t.curveOpacity};
|
|
171
|
-
stroke: ${
|
|
171
|
+
stroke: ${n};
|
|
172
172
|
}
|
|
173
173
|
`;
|
|
174
174
|
}
|
|
175
175
|
return e;
|
|
176
176
|
}, "genIndexStyles"), it = /* @__PURE__ */ c((a) => {
|
|
177
|
-
const t =
|
|
178
|
-
return { themeVariables: r, radarOptions:
|
|
177
|
+
const t = V(), e = C(), r = y(t, e.themeVariables), n = y(r.radar, a);
|
|
178
|
+
return { themeVariables: r, radarOptions: n };
|
|
179
179
|
}, "buildRadarStyleOptions"), lt = /* @__PURE__ */ c(({ radar: a } = {}) => {
|
|
180
180
|
const { themeVariables: t, radarOptions: e } = it(a);
|
|
181
181
|
return `
|
|
@@ -209,7 +209,7 @@ var nt = { draw: et }, ot = /* @__PURE__ */ c((a, t) => {
|
|
|
209
209
|
}, "styles"), pt = {
|
|
210
210
|
parser: tt,
|
|
211
211
|
db: $,
|
|
212
|
-
renderer:
|
|
212
|
+
renderer: st,
|
|
213
213
|
styles: lt
|
|
214
214
|
};
|
|
215
215
|
export {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const L=require("./chunk-JWPE2WC7-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const L=require("./chunk-JWPE2WC7-BziKhEzJ.cjs"),n=require("./extractHeadings-B-v1O82x.cjs"),S=require("./cynefin-VYW2F7L2-MpAliYy9.cjs");var x={showLegend:!0,ticks:5,max:null,min:0,graticule:"circle"},y={axes:[],curves:[],options:x},p=structuredClone(y),O=n.defaultConfig_default.radar,k=n.__name(()=>n.cleanAndMerge({...O,...n.getConfig().radar}),"getConfig"),f=n.__name(()=>p.axes,"getAxes"),D=n.__name(()=>p.curves,"getCurves"),R=n.__name(()=>p.options,"getOptions"),E=n.__name(a=>{p.axes=a.map(e=>({name:e.name,label:e.label??e.name}))},"setAxes"),F=n.__name(a=>{p.curves=a.map(e=>({name:e.name,label:e.label??e.name,entries:I(e.entries)}))},"setCurves"),I=n.__name(a=>{if(a[0].axis==null)return a.map(t=>t.value);const e=f();if(e.length===0)throw new Error("Axes must be populated before curves for reference entries");return e.map(t=>{const r=a.find(s=>s.axis?.$refText===t.name);if(r===void 0)throw new Error("Missing entry for axis "+t.label);return r.value})},"computeCurveEntries"),P=n.__name(a=>{const e=a.reduce((t,r)=>(t[r.name]=r,t),{});p.options={showLegend:e.showLegend?.value??x.showLegend,ticks:e.ticks?.value??x.ticks,max:e.max?.value??x.max,min:e.min?.value??x.min,graticule:e.graticule?.value??x.graticule}},"setOptions"),W=n.__name(()=>{n.clear(),p=structuredClone(y)},"clear"),_={getAxes:f,getCurves:D,getOptions:R,setAxes:E,setCurves:F,setOptions:P,getConfig:k,clear:W,setAccTitle:n.setAccTitle,getAccTitle:n.getAccTitle,setDiagramTitle:n.setDiagramTitle,getDiagramTitle:n.getDiagramTitle,getAccDescription:n.getAccDescription,setAccDescription:n.setAccDescription},z=n.__name(a=>{L.populateCommonDb(a,_);const{axes:e,curves:t,options:r}=a;_.setAxes(e),_.setCurves(t),_.setOptions(r)},"populate"),G={parse:n.__name(async a=>{const e=await S.parse("radar",a);n.log.debug(e),z(e)},"parse")},B=n.__name((a,e,t,r)=>{const s=r.db,l=s.getAxes(),c=s.getCurves(),o=s.getOptions(),i=s.getConfig(),d=s.getDiagramTitle(),g=n.selectSvgElement(e),u=V(g,i),m=o.max??Math.max(...c.map($=>Math.max(...$.entries))),h=o.min,v=Math.min(i.width,i.height)/2;H(u,l,v,o.ticks,o.graticule),j(u,l,v,i),C(u,l,c,h,m,o.graticule,i),A(u,c,o.showLegend,i),u.append("text").attr("class","radarTitle").text(d).attr("x",0).attr("y",-i.height/2-i.marginTop)},"draw"),V=n.__name((a,e)=>{const t=e.width+e.marginLeft+e.marginRight,r=e.height+e.marginTop+e.marginBottom,s={x:e.marginLeft+e.width/2,y:e.marginTop+e.height/2};return n.configureSvgSize(a,r,t,e.useMaxWidth??!0),a.attr("viewBox",`0 0 ${t} ${r}`).attr("overflow","visible"),a.append("g").attr("transform",`translate(${s.x}, ${s.y})`)},"drawFrame"),H=n.__name((a,e,t,r,s)=>{if(s==="circle")for(let l=0;l<r;l++){const c=t*(l+1)/r;a.append("circle").attr("r",c).attr("class","radarGraticule")}else if(s==="polygon"){const l=e.length;for(let c=0;c<r;c++){const o=t*(c+1)/r,i=e.map((d,g)=>{const u=2*g*Math.PI/l-Math.PI/2,m=o*Math.cos(u),h=o*Math.sin(u);return`${m},${h}`}).join(" ");a.append("polygon").attr("points",i).attr("class","radarGraticule")}}},"drawGraticule"),j=n.__name((a,e,t,r)=>{const s=e.length;for(let l=0;l<s;l++){const c=e[l].label,o=2*l*Math.PI/s-Math.PI/2,i=Math.cos(o),d=Math.sin(o);a.append("line").attr("x1",0).attr("y1",0).attr("x2",t*r.axisScaleFactor*i).attr("y2",t*r.axisScaleFactor*d).attr("class","radarAxisLine");const g=i>.01?"start":i<-.01?"end":"middle",u=d>.01?"hanging":d<-.01?"auto":"central",m=4;a.append("text").text(c).attr("x",t*r.axisLabelFactor*i+m*i).attr("y",t*r.axisLabelFactor*d+m*d).attr("text-anchor",g).attr("dominant-baseline",u).attr("class","radarAxisLabel")}},"drawAxes");function C(a,e,t,r,s,l,c){const o=e.length,i=Math.min(c.width,c.height)/2;t.forEach((d,g)=>{if(d.entries.length!==o)return;const u=d.entries.map((m,h)=>{const v=2*Math.PI*h/o-Math.PI/2,$=b(m,r,s,i),M=$*Math.cos(v),T=$*Math.sin(v);return{x:M,y:T}});l==="circle"?a.append("path").attr("d",w(u,c.curveTension)).attr("class",`radarCurve-${g}`):l==="polygon"&&a.append("polygon").attr("points",u.map(m=>`${m.x},${m.y}`).join(" ")).attr("class",`radarCurve-${g}`)})}n.__name(C,"drawCurves");function b(a,e,t,r){const s=Math.min(Math.max(a,e),t);return r*(s-e)/(t-e)}n.__name(b,"relativeRadius");function w(a,e){const t=a.length;let r=`M${a[0].x},${a[0].y}`;for(let s=0;s<t;s++){const l=a[(s-1+t)%t],c=a[s],o=a[(s+1)%t],i=a[(s+2)%t],d={x:c.x+(o.x-l.x)*e,y:c.y+(o.y-l.y)*e},g={x:o.x-(i.x-c.x)*e,y:o.y-(i.y-c.y)*e};r+=` C${d.x},${d.y} ${g.x},${g.y} ${o.x},${o.y}`}return`${r} Z`}n.__name(w,"closedRoundCurve");function A(a,e,t,r){if(!t)return;const s=(r.width/2+r.marginRight)*3/4,l=-(r.height/2+r.marginTop)*3/4,c=20;e.forEach((o,i)=>{const d=a.append("g").attr("transform",`translate(${s}, ${l+i*c})`);d.append("rect").attr("width",12).attr("height",12).attr("class",`radarLegendBox-${i}`),d.append("text").attr("x",16).attr("y",0).attr("class","radarLegendText").text(o.label)})}n.__name(A,"drawLegend");var q={draw:B},Y=n.__name((a,e)=>{let t="";for(let r=0;r<a.THEME_COLOR_LIMIT;r++){const s=a[`cScale${r}`];t+=`
|
|
2
2
|
.radarCurve-${r} {
|
|
3
3
|
color: ${s};
|
|
4
4
|
fill: ${s};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { g as l, r as m, d as n } from "./chunk-MOJQB5TN-
|
|
2
|
-
import { p } from "./chunk-JWPE2WC7-
|
|
3
|
-
import { _ as t,
|
|
1
|
+
import { g as l, r as m, d as n } from "./chunk-MOJQB5TN-DcKI-L1a.js";
|
|
2
|
+
import { p } from "./chunk-JWPE2WC7-D2PL9wSE.js";
|
|
3
|
+
import { _ as t, U as o } from "./extractHeadings-SqtThWou.js";
|
|
4
4
|
import { M as u, a as f } from "./cynefin-VYW2F7L2-Bkk-F_Js.js";
|
|
5
5
|
var c = f().RailroadEbnf.parser.LangiumParser, s = /* @__PURE__ */ t((e) => {
|
|
6
6
|
const r = e.alternatives.map(E);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./chunk-MOJQB5TN-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./chunk-MOJQB5TN-BZPg0rA4.cjs"),l=require("./chunk-JWPE2WC7-BziKhEzJ.cjs"),t=require("./extractHeadings-B-v1O82x.cjs"),o=require("./cynefin-VYW2F7L2-MpAliYy9.cjs");var m=o.createRailroadEbnfServices().RailroadEbnf.parser.LangiumParser,s=t.__name(e=>{const r=e.alternatives.map(u);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformChoice"),u=t.__name(e=>{const r=e.elements.map(c);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformSequence"),i=t.__name(e=>{switch(e.$type){case"EbnfTerminal":return{type:"terminal",value:e.value};case"EbnfNonTerminal":return{type:"nonterminal",name:e.name};case"EbnfSpecial":return{type:"special",text:e.text};case"EbnfGroup":return s(e.element);case"EbnfOptional":return{type:"optional",element:s(e.element)};case"EbnfRepetition":return{type:"repetition",element:s(e.element),min:0,max:1/0};default:throw new Error(`Unsupported EBNF primary node: ${e.$type}`)}},"transformPrimary"),p=t.__name((e,r)=>{switch(r.$type){case"EbnfOptionalPostfix":return{type:"optional",element:e};case"EbnfZeroOrMorePostfix":return{type:"repetition",element:e,min:0,max:1/0};case"EbnfOneOrMorePostfix":return{type:"repetition",element:e,min:1,max:1/0};case"EbnfExceptionPostfix":return{type:"sequence",elements:[e,{type:"terminal",value:"-"},i(r.except)]};default:throw new Error(`Unsupported EBNF postfix node: ${r.$type}`)}},"transformPostfix"),c=t.__name(e=>e.postfixes.reduce((r,a)=>p(r,a),i(e.base)),"transformTerm"),f=t.__name(e=>({name:e.name,definition:s(e.definition)}),"transformRule"),d=t.__name(e=>{l.populateCommonDb(e,n.db),e.title&&n.db.setTitle(e.title),e.rules.map(r=>n.db.addRule(f(r)))},"populateDb"),b={parse:t.__name(e=>{n.db.clear(),t.log.debug("[EBNF Parser] Starting Langium parse");const r=m.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new o.MermaidParseError(r);const a=r.value;t.log.debug("[EBNF Parser] Parsed rules:",a.rules.length),d(a),t.log.debug("[EBNF Parser] Parse complete")},"parse"),parser:{yy:n.db}},E={parser:b,db:n.db,renderer:n.renderer,styles:n.getStyles};exports.diagram=E;
|