@zjlab-frontier/markdown 1.2.6 → 1.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/dist/_basePickBy-CWu8v0ko.mjs +151 -0
  2. package/dist/_baseUniq-BYBDg8So.mjs +614 -0
  3. package/dist/arc-2_S8ohSf.mjs +83 -0
  4. package/dist/architecture-U656AL7Q-DGKLYZ_K.mjs +5 -0
  5. package/dist/architectureDiagram-VXUJARFQ-CiE3U1mu.mjs +4661 -0
  6. package/dist/blockDiagram-VD42YOAC-CsZjZOPb.mjs +2261 -0
  7. package/dist/{c4Diagram-c83219d4-DPiPzMng.mjs → c4Diagram-YG6GDRKO-1xvcuQft.mjs} +795 -794
  8. package/dist/{channel-DLtPd-ti.mjs → channel-DcbfLn-q.mjs} +1 -1
  9. package/dist/chunk-4BX2VUAB-BDp4Xs60.mjs +8 -0
  10. package/dist/chunk-55IACEB6-CTW8J150.mjs +8 -0
  11. package/dist/chunk-B4BG7PRW-B_heTEEq.mjs +1375 -0
  12. package/dist/chunk-DI55MBZ5-DhjTVH-t.mjs +1370 -0
  13. package/dist/chunk-FMBD7UC4-ClbSERVz.mjs +19 -0
  14. package/dist/chunk-QN33PNHL-BKK9fOrS.mjs +19 -0
  15. package/dist/chunk-QZHKN3VN-BJGNV1ga.mjs +15 -0
  16. package/dist/chunk-TZMSLE5B-CGED95dA.mjs +64 -0
  17. package/dist/classDiagram-2ON5EDUG-B940_szE.mjs +16 -0
  18. package/dist/classDiagram-v2-WZHVMYZB-B940_szE.mjs +16 -0
  19. package/dist/{clone-Bekeo3TW.mjs → clone-DCtolUVn.mjs} +1 -1
  20. package/dist/cose-bilkent-S5V4N54A-BYen7Ep1.mjs +2608 -0
  21. package/dist/cytoscape.esm-MSgpKP8s.mjs +18721 -0
  22. package/dist/dagre-6UL2VRFP-iIFq-NoW.mjs +444 -0
  23. package/dist/defaultLocale-D7EN2tov.mjs +171 -0
  24. package/dist/diagram-PSM6KHXK-Dy7h44b4.mjs +531 -0
  25. package/dist/diagram-QEK2KX5R-C94F1gFy.mjs +217 -0
  26. package/dist/diagram-S2PKOQOG-yhlmdZS2.mjs +142 -0
  27. package/dist/erDiagram-Q2GNP2WA-BpLUZP7_.mjs +841 -0
  28. package/dist/flowDiagram-NV44I4VS-SLzktk7G.mjs +1620 -0
  29. package/dist/ganttDiagram-JELNMOA3-DeGgQKGo.mjs +2670 -0
  30. package/dist/gitGraph-F6HP7TQM-BMUVRqib.mjs +5 -0
  31. package/dist/gitGraphDiagram-NY62KEGX-CAg0nU-l.mjs +699 -0
  32. package/dist/graph-D3huRaLs.mjs +247 -0
  33. package/dist/{index-C3zgkbpi.mjs → index-BrxkOr3k.mjs} +35916 -28708
  34. package/dist/index.es.js +4 -4
  35. package/dist/index.umd.js +1884 -1442
  36. package/dist/info-NVLQJR56-B7-uUvSf.mjs +5 -0
  37. package/dist/infoDiagram-WHAUD3N6-CvBpxqLi.mjs +24 -0
  38. package/dist/journeyDiagram-XKPGCS4Q-DuCbTsAr.mjs +834 -0
  39. package/dist/kanban-definition-3W4ZIXB7-DvIE5yxA.mjs +719 -0
  40. package/dist/layout-DxYqTZ5R.mjs +1335 -0
  41. package/dist/linear-Ft07C63i.mjs +259 -0
  42. package/dist/mermaid-parser.core-D4YfUPNI.mjs +12966 -0
  43. package/dist/mindmap-definition-VGOIOE7T-urZ0HI-X.mjs +784 -0
  44. package/dist/packet-BFZMPI3H-ByWPr9-O.mjs +5 -0
  45. package/dist/pie-7BOR55EZ-B4RcaSOO.mjs +5 -0
  46. package/dist/pieDiagram-ADFJNKIX-ieTD_ZLt.mjs +161 -0
  47. package/dist/quadrantDiagram-AYHSOK5B-CA5Lp1fr.mjs +1022 -0
  48. package/dist/radar-NHE76QYJ-xjkuc7ne.mjs +5 -0
  49. package/dist/requirementDiagram-UZGBJVZJ-dsQFkWyE.mjs +850 -0
  50. package/dist/sankeyDiagram-TZEHDZUN-BbxCMN2Y.mjs +810 -0
  51. package/dist/sequenceDiagram-WL72ISMW-DXuguRyg.mjs +2511 -0
  52. package/dist/stateDiagram-FKZM4ZOC-Df7YOK3T.mjs +263 -0
  53. package/dist/stateDiagram-v2-4FDKWEC3-D8vtVcSe.mjs +16 -0
  54. package/dist/timeline-definition-IT6M3QCI-BECtudMW.mjs +795 -0
  55. package/dist/treemap-KMMF4GRG-Whla94QX.mjs +5 -0
  56. package/dist/{xychartDiagram-f5964ef8-fDv4mp1P.mjs → xychartDiagram-PRI3JC2R-Vnmd1h04.mjs} +503 -445
  57. package/package.json +3 -3
  58. package/dist/Tableau10-D7jGxypv.mjs +0 -8
  59. package/dist/arc-DqrMsJeG.mjs +0 -84
  60. package/dist/array-CqVTtuYm.mjs +0 -6
  61. package/dist/blockDiagram-c4efeb88-B7Mcu3H_.mjs +0 -1221
  62. package/dist/classDiagram-beda092f-CRNvkLYf.mjs +0 -218
  63. package/dist/classDiagram-v2-2358418a-CUFy5DGQ.mjs +0 -200
  64. package/dist/createText-1719965b-BEXd6yNU.mjs +0 -2955
  65. package/dist/edges-96097737-CTds2HS2.mjs +0 -1088
  66. package/dist/erDiagram-0228fc6a-DdOqXYmJ.mjs +0 -929
  67. package/dist/flowDb-c6c81e3f-LkwBoeG_.mjs +0 -1126
  68. package/dist/flowDiagram-50d868cf-BlsvSXSO.mjs +0 -788
  69. package/dist/flowDiagram-v2-4f6560a1-KScjGHBx.mjs +0 -17
  70. package/dist/flowchart-elk-definition-6af322e1-mTna7kqR.mjs +0 -48146
  71. package/dist/ganttDiagram-a2739b55-B2o_UW9_.mjs +0 -2477
  72. package/dist/gitGraphDiagram-82fe8481-B6-VRPS0.mjs +0 -1264
  73. package/dist/graph-CSVeLFCJ.mjs +0 -847
  74. package/dist/index-5325376f-DsGv8AO4.mjs +0 -373
  75. package/dist/infoDiagram-8eee0895-Cx7V52QV.mjs +0 -319
  76. package/dist/journeyDiagram-c64418c1-C03IeVHa.mjs +0 -801
  77. package/dist/layout-DfnPfvJm.mjs +0 -1472
  78. package/dist/line-BwAWhs05.mjs +0 -33
  79. package/dist/linear-Ck_Qt8nI.mjs +0 -423
  80. package/dist/mindmap-definition-8da855dc-DdMLbjBy.mjs +0 -21922
  81. package/dist/path-DLwuMfdd.mjs +0 -84
  82. package/dist/pieDiagram-a8764435-BymSofHf.mjs +0 -500
  83. package/dist/quadrantDiagram-1e28029f-BXtW3eHp.mjs +0 -903
  84. package/dist/requirementDiagram-08caed73-DGBKyhE-.mjs +0 -767
  85. package/dist/sankeyDiagram-a04cb91d-BfUYRgG3.mjs +0 -802
  86. package/dist/sequenceDiagram-c5b8d532-Jj_1ttvV.mjs +0 -2234
  87. package/dist/stateDiagram-1ecb1508-CbSM9l6I.mjs +0 -266
  88. package/dist/stateDiagram-v2-c2b004d7-dS2KbqNc.mjs +0 -184
  89. package/dist/styles-b4e223ce-D01XEgS6.mjs +0 -1089
  90. package/dist/styles-ca3715f6-amZyw1GB.mjs +0 -960
  91. package/dist/styles-d45a18b0-GN33fYGn.mjs +0 -436
  92. package/dist/svgDrawCommon-b86b1483-BQvqkIEE.mjs +0 -64
  93. package/dist/timeline-definition-faaaa080-BjbyYT4p.mjs +0 -792
@@ -1,269 +1,271 @@
1
- import { s as zt, a as Ft, C as wt, D as Nt, b as Xt, c as Yt, l as St, T as Ht, e as $t, E as Ut, Z as ot, V as Ct, X as qt, Y as jt, i as Gt } from "./index-C3zgkbpi.mjs";
2
- import { c as Qt } from "./createText-1719965b-BEXd6yNU.mjs";
3
- import { i as Kt } from "./init-DjUOC4st.mjs";
4
- import { o as Zt } from "./ordinal-C0oynhte.mjs";
5
- import { l as ft } from "./linear-Ck_Qt8nI.mjs";
6
- import { l as pt } from "./line-BwAWhs05.mjs";
7
- function Jt(e, t, i) {
1
+ import { _ as a, s as gi, g as xi, q as Xt, p as di, a as fi, b as pi, l as Nt, H as mi, e as yi, y as bi, E as St, D as Yt, F as Ai, K as wi, i as Ci, aF as Si, R as Wt } from "./index-BrxkOr3k.mjs";
2
+ import { i as _i } from "./init-DjUOC4st.mjs";
3
+ import { o as ki } from "./ordinal-C0oynhte.mjs";
4
+ import { l as zt } from "./linear-Ft07C63i.mjs";
5
+ function Ri(e, t, i) {
8
6
  e = +e, t = +t, i = (n = arguments.length) < 2 ? (t = e, e = 0, 1) : n < 3 ? 1 : +i;
9
7
  for (var s = -1, n = Math.max(0, Math.ceil((t - e) / i)) | 0, o = new Array(n); ++s < n; )
10
8
  o[s] = e + s * i;
11
9
  return o;
12
10
  }
13
- function st() {
14
- var e = Zt().unknown(void 0), t = e.domain, i = e.range, s = 0, n = 1, o, c, f = !1, d = 0, R = 0, _ = 0.5;
11
+ function yt() {
12
+ var e = ki().unknown(void 0), t = e.domain, i = e.range, s = 0, n = 1, o, g, m = !1, p = 0, k = 0, v = 0.5;
15
13
  delete e.unknown;
16
- function A() {
17
- var m = t().length, T = n < s, S = T ? n : s, P = T ? s : n;
18
- o = (P - S) / Math.max(1, m - d + R * 2), f && (o = Math.floor(o)), S += (P - S - o * (m - d)) * _, c = o * (1 - d), f && (S = Math.round(S), c = Math.round(c));
19
- var p = Jt(m).map(function(C) {
20
- return S + o * C;
14
+ function C() {
15
+ var b = t().length, E = n < s, D = E ? n : s, P = E ? s : n;
16
+ o = (P - D) / Math.max(1, b - p + k * 2), m && (o = Math.floor(o)), D += (P - D - o * (b - p)) * v, g = o * (1 - p), m && (D = Math.round(D), g = Math.round(g));
17
+ var I = Ri(b).map(function(y) {
18
+ return D + o * y;
21
19
  });
22
- return i(T ? p.reverse() : p);
20
+ return i(E ? I.reverse() : I);
23
21
  }
24
- return e.domain = function(m) {
25
- return arguments.length ? (t(m), A()) : t();
26
- }, e.range = function(m) {
27
- return arguments.length ? ([s, n] = m, s = +s, n = +n, A()) : [s, n];
28
- }, e.rangeRound = function(m) {
29
- return [s, n] = m, s = +s, n = +n, f = !0, A();
22
+ return e.domain = function(b) {
23
+ return arguments.length ? (t(b), C()) : t();
24
+ }, e.range = function(b) {
25
+ return arguments.length ? ([s, n] = b, s = +s, n = +n, C()) : [s, n];
26
+ }, e.rangeRound = function(b) {
27
+ return [s, n] = b, s = +s, n = +n, m = !0, C();
30
28
  }, e.bandwidth = function() {
31
- return c;
29
+ return g;
32
30
  }, e.step = function() {
33
31
  return o;
34
- }, e.round = function(m) {
35
- return arguments.length ? (f = !!m, A()) : f;
36
- }, e.padding = function(m) {
37
- return arguments.length ? (d = Math.min(1, R = +m), A()) : d;
38
- }, e.paddingInner = function(m) {
39
- return arguments.length ? (d = Math.min(1, m), A()) : d;
40
- }, e.paddingOuter = function(m) {
41
- return arguments.length ? (R = +m, A()) : R;
42
- }, e.align = function(m) {
43
- return arguments.length ? (_ = Math.max(0, Math.min(1, m)), A()) : _;
32
+ }, e.round = function(b) {
33
+ return arguments.length ? (m = !!b, C()) : m;
34
+ }, e.padding = function(b) {
35
+ return arguments.length ? (p = Math.min(1, k = +b), C()) : p;
36
+ }, e.paddingInner = function(b) {
37
+ return arguments.length ? (p = Math.min(1, b), C()) : p;
38
+ }, e.paddingOuter = function(b) {
39
+ return arguments.length ? (k = +b, C()) : k;
40
+ }, e.align = function(b) {
41
+ return arguments.length ? (v = Math.max(0, Math.min(1, b)), C()) : v;
44
42
  }, e.copy = function() {
45
- return st(t(), [s, n]).round(f).paddingInner(d).paddingOuter(R).align(_);
46
- }, Kt.apply(A(), arguments);
43
+ return yt(t(), [s, n]).round(m).paddingInner(p).paddingOuter(k).align(v);
44
+ }, _i.apply(C(), arguments);
47
45
  }
48
- var nt = (function() {
49
- var e = function(V, r, l, u) {
50
- for (l = l || {}, u = V.length; u--; l[V[u]] = r)
51
- ;
52
- return l;
53
- }, t = [1, 10, 12, 14, 16, 18, 19, 21, 23], i = [2, 6], s = [1, 3], n = [1, 5], o = [1, 6], c = [1, 7], f = [1, 5, 10, 12, 14, 16, 18, 19, 21, 23, 34, 35, 36], d = [1, 25], R = [1, 26], _ = [1, 28], A = [1, 29], m = [1, 30], T = [1, 31], S = [1, 32], P = [1, 33], p = [1, 34], C = [1, 35], h = [1, 36], L = [1, 37], z = [1, 43], lt = [1, 42], ct = [1, 47], $ = [1, 50], w = [1, 10, 12, 14, 16, 18, 19, 21, 23, 34, 35, 36], Q = [1, 10, 12, 14, 16, 18, 19, 21, 23, 24, 26, 27, 28, 34, 35, 36], E = [1, 10, 12, 14, 16, 18, 19, 21, 23, 24, 26, 27, 28, 34, 35, 36, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50], ut = [1, 64], K = {
54
- trace: function() {
55
- },
46
+ var bt = (function() {
47
+ var e = /* @__PURE__ */ a(function(F, h, u, x) {
48
+ for (u = u || {}, x = F.length; x--; u[F[x]] = h) ;
49
+ return u;
50
+ }, "o"), t = [1, 10, 12, 14, 16, 18, 19, 21, 23], i = [2, 6], s = [1, 3], n = [1, 5], o = [1, 6], g = [1, 7], m = [1, 5, 10, 12, 14, 16, 18, 19, 21, 23, 34, 35, 36], p = [1, 25], k = [1, 26], v = [1, 28], C = [1, 29], b = [1, 30], E = [1, 31], D = [1, 32], P = [1, 33], I = [1, 34], y = [1, 35], _ = [1, 36], c = [1, 37], W = [1, 43], z = [1, 42], U = [1, 47], X = [1, 50], l = [1, 10, 12, 14, 16, 18, 19, 21, 23, 34, 35, 36], L = [1, 10, 12, 14, 16, 18, 19, 21, 23, 24, 26, 27, 28, 34, 35, 36], S = [1, 10, 12, 14, 16, 18, 19, 21, 23, 24, 26, 27, 28, 34, 35, 36, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50], R = [1, 64], $ = {
51
+ trace: /* @__PURE__ */ a(function() {
52
+ }, "trace"),
56
53
  yy: {},
57
54
  symbols_: { error: 2, start: 3, eol: 4, XYCHART: 5, chartConfig: 6, document: 7, CHART_ORIENTATION: 8, statement: 9, title: 10, text: 11, X_AXIS: 12, parseXAxis: 13, Y_AXIS: 14, parseYAxis: 15, LINE: 16, plotData: 17, BAR: 18, acc_title: 19, acc_title_value: 20, acc_descr: 21, acc_descr_value: 22, acc_descr_multiline_value: 23, SQUARE_BRACES_START: 24, commaSeparatedNumbers: 25, SQUARE_BRACES_END: 26, NUMBER_WITH_DECIMAL: 27, COMMA: 28, xAxisData: 29, bandData: 30, ARROW_DELIMITER: 31, commaSeparatedTexts: 32, yAxisData: 33, NEWLINE: 34, SEMI: 35, EOF: 36, alphaNum: 37, STR: 38, MD_STR: 39, alphaNumToken: 40, AMP: 41, NUM: 42, ALPHA: 43, PLUS: 44, EQUALS: 45, MULT: 46, DOT: 47, BRKT: 48, MINUS: 49, UNDERSCORE: 50, $accept: 0, $end: 1 },
58
55
  terminals_: { 2: "error", 5: "XYCHART", 8: "CHART_ORIENTATION", 10: "title", 12: "X_AXIS", 14: "Y_AXIS", 16: "LINE", 18: "BAR", 19: "acc_title", 20: "acc_title_value", 21: "acc_descr", 22: "acc_descr_value", 23: "acc_descr_multiline_value", 24: "SQUARE_BRACES_START", 26: "SQUARE_BRACES_END", 27: "NUMBER_WITH_DECIMAL", 28: "COMMA", 31: "ARROW_DELIMITER", 34: "NEWLINE", 35: "SEMI", 36: "EOF", 38: "STR", 39: "MD_STR", 41: "AMP", 42: "NUM", 43: "ALPHA", 44: "PLUS", 45: "EQUALS", 46: "MULT", 47: "DOT", 48: "BRKT", 49: "MINUS", 50: "UNDERSCORE" },
59
56
  productions_: [0, [3, 2], [3, 3], [3, 2], [3, 1], [6, 1], [7, 0], [7, 2], [9, 2], [9, 2], [9, 2], [9, 2], [9, 2], [9, 3], [9, 2], [9, 3], [9, 2], [9, 2], [9, 1], [17, 3], [25, 3], [25, 1], [13, 1], [13, 2], [13, 1], [29, 1], [29, 3], [30, 3], [32, 3], [32, 1], [15, 1], [15, 2], [15, 1], [33, 3], [4, 1], [4, 1], [4, 1], [11, 1], [11, 1], [11, 1], [37, 1], [37, 2], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1], [40, 1]],
60
- performAction: function(r, l, u, g, b, a, F) {
61
- var x = a.length - 1;
62
- switch (b) {
57
+ performAction: /* @__PURE__ */ a(function(h, u, x, d, w, r, at) {
58
+ var f = r.length - 1;
59
+ switch (w) {
63
60
  case 5:
64
- g.setOrientation(a[x]);
61
+ d.setOrientation(r[f]);
65
62
  break;
66
63
  case 9:
67
- g.setDiagramTitle(a[x].text.trim());
64
+ d.setDiagramTitle(r[f].text.trim());
68
65
  break;
69
66
  case 12:
70
- g.setLineData({ text: "", type: "text" }, a[x]);
67
+ d.setLineData({ text: "", type: "text" }, r[f]);
71
68
  break;
72
69
  case 13:
73
- g.setLineData(a[x - 1], a[x]);
70
+ d.setLineData(r[f - 1], r[f]);
74
71
  break;
75
72
  case 14:
76
- g.setBarData({ text: "", type: "text" }, a[x]);
73
+ d.setBarData({ text: "", type: "text" }, r[f]);
77
74
  break;
78
75
  case 15:
79
- g.setBarData(a[x - 1], a[x]);
76
+ d.setBarData(r[f - 1], r[f]);
80
77
  break;
81
78
  case 16:
82
- this.$ = a[x].trim(), g.setAccTitle(this.$);
79
+ this.$ = r[f].trim(), d.setAccTitle(this.$);
83
80
  break;
84
81
  case 17:
85
82
  case 18:
86
- this.$ = a[x].trim(), g.setAccDescription(this.$);
83
+ this.$ = r[f].trim(), d.setAccDescription(this.$);
87
84
  break;
88
85
  case 19:
89
- this.$ = a[x - 1];
86
+ this.$ = r[f - 1];
90
87
  break;
91
88
  case 20:
92
- this.$ = [Number(a[x - 2]), ...a[x]];
89
+ this.$ = [Number(r[f - 2]), ...r[f]];
93
90
  break;
94
91
  case 21:
95
- this.$ = [Number(a[x])];
92
+ this.$ = [Number(r[f])];
96
93
  break;
97
94
  case 22:
98
- g.setXAxisTitle(a[x]);
95
+ d.setXAxisTitle(r[f]);
99
96
  break;
100
97
  case 23:
101
- g.setXAxisTitle(a[x - 1]);
98
+ d.setXAxisTitle(r[f - 1]);
102
99
  break;
103
100
  case 24:
104
- g.setXAxisTitle({ type: "text", text: "" });
101
+ d.setXAxisTitle({ type: "text", text: "" });
105
102
  break;
106
103
  case 25:
107
- g.setXAxisBand(a[x]);
104
+ d.setXAxisBand(r[f]);
108
105
  break;
109
106
  case 26:
110
- g.setXAxisRangeData(Number(a[x - 2]), Number(a[x]));
107
+ d.setXAxisRangeData(Number(r[f - 2]), Number(r[f]));
111
108
  break;
112
109
  case 27:
113
- this.$ = a[x - 1];
110
+ this.$ = r[f - 1];
114
111
  break;
115
112
  case 28:
116
- this.$ = [a[x - 2], ...a[x]];
113
+ this.$ = [r[f - 2], ...r[f]];
117
114
  break;
118
115
  case 29:
119
- this.$ = [a[x]];
116
+ this.$ = [r[f]];
120
117
  break;
121
118
  case 30:
122
- g.setYAxisTitle(a[x]);
119
+ d.setYAxisTitle(r[f]);
123
120
  break;
124
121
  case 31:
125
- g.setYAxisTitle(a[x - 1]);
122
+ d.setYAxisTitle(r[f - 1]);
126
123
  break;
127
124
  case 32:
128
- g.setYAxisTitle({ type: "text", text: "" });
125
+ d.setYAxisTitle({ type: "text", text: "" });
129
126
  break;
130
127
  case 33:
131
- g.setYAxisRangeData(Number(a[x - 2]), Number(a[x]));
128
+ d.setYAxisRangeData(Number(r[f - 2]), Number(r[f]));
132
129
  break;
133
130
  case 37:
134
- this.$ = { text: a[x], type: "text" };
131
+ this.$ = { text: r[f], type: "text" };
135
132
  break;
136
133
  case 38:
137
- this.$ = { text: a[x], type: "text" };
134
+ this.$ = { text: r[f], type: "text" };
138
135
  break;
139
136
  case 39:
140
- this.$ = { text: a[x], type: "markdown" };
137
+ this.$ = { text: r[f], type: "markdown" };
141
138
  break;
142
139
  case 40:
143
- this.$ = a[x];
140
+ this.$ = r[f];
144
141
  break;
145
142
  case 41:
146
- this.$ = a[x - 1] + "" + a[x];
143
+ this.$ = r[f - 1] + "" + r[f];
147
144
  break;
148
145
  }
149
- },
150
- table: [e(t, i, { 3: 1, 4: 2, 7: 4, 5: s, 34: n, 35: o, 36: c }), { 1: [3] }, e(t, i, { 4: 2, 7: 4, 3: 8, 5: s, 34: n, 35: o, 36: c }), e(t, i, { 4: 2, 7: 4, 6: 9, 3: 10, 5: s, 8: [1, 11], 34: n, 35: o, 36: c }), { 1: [2, 4], 9: 12, 10: [1, 13], 12: [1, 14], 14: [1, 15], 16: [1, 16], 18: [1, 17], 19: [1, 18], 21: [1, 19], 23: [1, 20] }, e(f, [2, 34]), e(f, [2, 35]), e(f, [2, 36]), { 1: [2, 1] }, e(t, i, { 4: 2, 7: 4, 3: 21, 5: s, 34: n, 35: o, 36: c }), { 1: [2, 3] }, e(f, [2, 5]), e(t, [2, 7], { 4: 22, 34: n, 35: o, 36: c }), { 11: 23, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, { 11: 39, 13: 38, 24: z, 27: lt, 29: 40, 30: 41, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, { 11: 45, 15: 44, 27: ct, 33: 46, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, { 11: 49, 17: 48, 24: $, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, { 11: 52, 17: 51, 24: $, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, { 20: [1, 53] }, { 22: [1, 54] }, e(w, [2, 18]), { 1: [2, 2] }, e(w, [2, 8]), e(w, [2, 9]), e(Q, [2, 37], { 40: 55, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }), e(Q, [2, 38]), e(Q, [2, 39]), e(E, [2, 40]), e(E, [2, 42]), e(E, [2, 43]), e(E, [2, 44]), e(E, [2, 45]), e(E, [2, 46]), e(E, [2, 47]), e(E, [2, 48]), e(E, [2, 49]), e(E, [2, 50]), e(E, [2, 51]), e(w, [2, 10]), e(w, [2, 22], { 30: 41, 29: 56, 24: z, 27: lt }), e(w, [2, 24]), e(w, [2, 25]), { 31: [1, 57] }, { 11: 59, 32: 58, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, e(w, [2, 11]), e(w, [2, 30], { 33: 60, 27: ct }), e(w, [2, 32]), { 31: [1, 61] }, e(w, [2, 12]), { 17: 62, 24: $ }, { 25: 63, 27: ut }, e(w, [2, 14]), { 17: 65, 24: $ }, e(w, [2, 16]), e(w, [2, 17]), e(E, [2, 41]), e(w, [2, 23]), { 27: [1, 66] }, { 26: [1, 67] }, { 26: [2, 29], 28: [1, 68] }, e(w, [2, 31]), { 27: [1, 69] }, e(w, [2, 13]), { 26: [1, 70] }, { 26: [2, 21], 28: [1, 71] }, e(w, [2, 15]), e(w, [2, 26]), e(w, [2, 27]), { 11: 59, 32: 72, 37: 24, 38: d, 39: R, 40: 27, 41: _, 42: A, 43: m, 44: T, 45: S, 46: P, 47: p, 48: C, 49: h, 50: L }, e(w, [2, 33]), e(w, [2, 19]), { 25: 73, 27: ut }, { 26: [2, 28] }, { 26: [2, 20] }],
146
+ }, "anonymous"),
147
+ table: [e(t, i, { 3: 1, 4: 2, 7: 4, 5: s, 34: n, 35: o, 36: g }), { 1: [3] }, e(t, i, { 4: 2, 7: 4, 3: 8, 5: s, 34: n, 35: o, 36: g }), e(t, i, { 4: 2, 7: 4, 6: 9, 3: 10, 5: s, 8: [1, 11], 34: n, 35: o, 36: g }), { 1: [2, 4], 9: 12, 10: [1, 13], 12: [1, 14], 14: [1, 15], 16: [1, 16], 18: [1, 17], 19: [1, 18], 21: [1, 19], 23: [1, 20] }, e(m, [2, 34]), e(m, [2, 35]), e(m, [2, 36]), { 1: [2, 1] }, e(t, i, { 4: 2, 7: 4, 3: 21, 5: s, 34: n, 35: o, 36: g }), { 1: [2, 3] }, e(m, [2, 5]), e(t, [2, 7], { 4: 22, 34: n, 35: o, 36: g }), { 11: 23, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, { 11: 39, 13: 38, 24: W, 27: z, 29: 40, 30: 41, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, { 11: 45, 15: 44, 27: U, 33: 46, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, { 11: 49, 17: 48, 24: X, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, { 11: 52, 17: 51, 24: X, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, { 20: [1, 53] }, { 22: [1, 54] }, e(l, [2, 18]), { 1: [2, 2] }, e(l, [2, 8]), e(l, [2, 9]), e(L, [2, 37], { 40: 55, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }), e(L, [2, 38]), e(L, [2, 39]), e(S, [2, 40]), e(S, [2, 42]), e(S, [2, 43]), e(S, [2, 44]), e(S, [2, 45]), e(S, [2, 46]), e(S, [2, 47]), e(S, [2, 48]), e(S, [2, 49]), e(S, [2, 50]), e(S, [2, 51]), e(l, [2, 10]), e(l, [2, 22], { 30: 41, 29: 56, 24: W, 27: z }), e(l, [2, 24]), e(l, [2, 25]), { 31: [1, 57] }, { 11: 59, 32: 58, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, e(l, [2, 11]), e(l, [2, 30], { 33: 60, 27: U }), e(l, [2, 32]), { 31: [1, 61] }, e(l, [2, 12]), { 17: 62, 24: X }, { 25: 63, 27: R }, e(l, [2, 14]), { 17: 65, 24: X }, e(l, [2, 16]), e(l, [2, 17]), e(S, [2, 41]), e(l, [2, 23]), { 27: [1, 66] }, { 26: [1, 67] }, { 26: [2, 29], 28: [1, 68] }, e(l, [2, 31]), { 27: [1, 69] }, e(l, [2, 13]), { 26: [1, 70] }, { 26: [2, 21], 28: [1, 71] }, e(l, [2, 15]), e(l, [2, 26]), e(l, [2, 27]), { 11: 59, 32: 72, 37: 24, 38: p, 39: k, 40: 27, 41: v, 42: C, 43: b, 44: E, 45: D, 46: P, 47: I, 48: y, 49: _, 50: c }, e(l, [2, 33]), e(l, [2, 19]), { 25: 73, 27: R }, { 26: [2, 28] }, { 26: [2, 20] }],
151
148
  defaultActions: { 8: [2, 1], 10: [2, 3], 21: [2, 2], 72: [2, 28], 73: [2, 20] },
152
- parseError: function(r, l) {
153
- if (l.recoverable)
154
- this.trace(r);
149
+ parseError: /* @__PURE__ */ a(function(h, u) {
150
+ if (u.recoverable)
151
+ this.trace(h);
155
152
  else {
156
- var u = new Error(r);
157
- throw u.hash = l, u;
153
+ var x = new Error(h);
154
+ throw x.hash = u, x;
158
155
  }
159
- },
160
- parse: function(r) {
161
- var l = this, u = [0], g = [], b = [null], a = [], F = this.table, x = "", U = 0, gt = 0, Vt = 2, xt = 1, Bt = a.slice.call(arguments, 1), k = Object.create(this.lexer), B = { yy: {} };
162
- for (var J in this.yy)
163
- Object.prototype.hasOwnProperty.call(this.yy, J) && (B.yy[J] = this.yy[J]);
164
- k.setInput(r, B.yy), B.yy.lexer = k, B.yy.parser = this, typeof k.yylloc > "u" && (k.yylloc = {});
165
- var tt = k.yylloc;
166
- a.push(tt);
167
- var Wt = k.options && k.options.ranges;
168
- typeof B.yy.parseError == "function" ? this.parseError = B.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
169
- function Ot() {
170
- var I;
171
- return I = g.pop() || k.lex() || xt, typeof I != "number" && (I instanceof Array && (g = I, I = g.pop()), I = l.symbols_[I] || I), I;
156
+ }, "parseError"),
157
+ parse: /* @__PURE__ */ a(function(h) {
158
+ var u = this, x = [0], d = [], w = [null], r = [], at = this.table, f = "", lt = 0, It = 0, hi = 2, Mt = 1, li = r.slice.call(arguments, 1), T = Object.create(this.lexer), Y = { yy: {} };
159
+ for (var dt in this.yy)
160
+ Object.prototype.hasOwnProperty.call(this.yy, dt) && (Y.yy[dt] = this.yy[dt]);
161
+ T.setInput(h, Y.yy), Y.yy.lexer = T, Y.yy.parser = this, typeof T.yylloc > "u" && (T.yylloc = {});
162
+ var ft = T.yylloc;
163
+ r.push(ft);
164
+ var ci = T.options && T.options.ranges;
165
+ typeof Y.yy.parseError == "function" ? this.parseError = Y.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
166
+ function ui(V) {
167
+ x.length = x.length - 2 * V, w.length = w.length - V, r.length = r.length - V;
172
168
  }
173
- for (var D, W, v, it, O = {}, q, M, dt, j; ; ) {
174
- if (W = u[u.length - 1], this.defaultActions[W] ? v = this.defaultActions[W] : ((D === null || typeof D > "u") && (D = Ot()), v = F[W] && F[W][D]), typeof v > "u" || !v.length || !v[0]) {
175
- var et = "";
176
- j = [];
177
- for (q in F[W])
178
- this.terminals_[q] && q > Vt && j.push("'" + this.terminals_[q] + "'");
179
- k.showPosition ? et = "Parse error on line " + (U + 1) + `:
180
- ` + k.showPosition() + `
181
- Expecting ` + j.join(", ") + ", got '" + (this.terminals_[D] || D) + "'" : et = "Parse error on line " + (U + 1) + ": Unexpected " + (D == xt ? "end of input" : "'" + (this.terminals_[D] || D) + "'"), this.parseError(et, {
182
- text: k.match,
183
- token: this.terminals_[D] || D,
184
- line: k.yylineno,
185
- loc: tt,
186
- expected: j
169
+ a(ui, "popStack");
170
+ function Vt() {
171
+ var V;
172
+ return V = d.pop() || T.lex() || Mt, typeof V != "number" && (V instanceof Array && (d = V, V = d.pop()), V = u.symbols_[V] || V), V;
173
+ }
174
+ a(Vt, "lex");
175
+ for (var M, H, B, pt, q = {}, ct, O, Bt, ut; ; ) {
176
+ if (H = x[x.length - 1], this.defaultActions[H] ? B = this.defaultActions[H] : ((M === null || typeof M > "u") && (M = Vt()), B = at[H] && at[H][M]), typeof B > "u" || !B.length || !B[0]) {
177
+ var mt = "";
178
+ ut = [];
179
+ for (ct in at[H])
180
+ this.terminals_[ct] && ct > hi && ut.push("'" + this.terminals_[ct] + "'");
181
+ T.showPosition ? mt = "Parse error on line " + (lt + 1) + `:
182
+ ` + T.showPosition() + `
183
+ Expecting ` + ut.join(", ") + ", got '" + (this.terminals_[M] || M) + "'" : mt = "Parse error on line " + (lt + 1) + ": Unexpected " + (M == Mt ? "end of input" : "'" + (this.terminals_[M] || M) + "'"), this.parseError(mt, {
184
+ text: T.match,
185
+ token: this.terminals_[M] || M,
186
+ line: T.yylineno,
187
+ loc: ft,
188
+ expected: ut
187
189
  });
188
190
  }
189
- if (v[0] instanceof Array && v.length > 1)
190
- throw new Error("Parse Error: multiple actions possible at state: " + W + ", token: " + D);
191
- switch (v[0]) {
191
+ if (B[0] instanceof Array && B.length > 1)
192
+ throw new Error("Parse Error: multiple actions possible at state: " + H + ", token: " + M);
193
+ switch (B[0]) {
192
194
  case 1:
193
- u.push(D), b.push(k.yytext), a.push(k.yylloc), u.push(v[1]), D = null, gt = k.yyleng, x = k.yytext, U = k.yylineno, tt = k.yylloc;
195
+ x.push(M), w.push(T.yytext), r.push(T.yylloc), x.push(B[1]), M = null, It = T.yyleng, f = T.yytext, lt = T.yylineno, ft = T.yylloc;
194
196
  break;
195
197
  case 2:
196
- if (M = this.productions_[v[1]][1], O.$ = b[b.length - M], O._$ = {
197
- first_line: a[a.length - (M || 1)].first_line,
198
- last_line: a[a.length - 1].last_line,
199
- first_column: a[a.length - (M || 1)].first_column,
200
- last_column: a[a.length - 1].last_column
201
- }, Wt && (O._$.range = [
202
- a[a.length - (M || 1)].range[0],
203
- a[a.length - 1].range[1]
204
- ]), it = this.performAction.apply(O, [
205
- x,
206
- gt,
207
- U,
208
- B.yy,
209
- v[1],
210
- b,
211
- a
212
- ].concat(Bt)), typeof it < "u")
213
- return it;
214
- M && (u = u.slice(0, -1 * M * 2), b = b.slice(0, -1 * M), a = a.slice(0, -1 * M)), u.push(this.productions_[v[1]][0]), b.push(O.$), a.push(O._$), dt = F[u[u.length - 2]][u[u.length - 1]], u.push(dt);
198
+ if (O = this.productions_[B[1]][1], q.$ = w[w.length - O], q._$ = {
199
+ first_line: r[r.length - (O || 1)].first_line,
200
+ last_line: r[r.length - 1].last_line,
201
+ first_column: r[r.length - (O || 1)].first_column,
202
+ last_column: r[r.length - 1].last_column
203
+ }, ci && (q._$.range = [
204
+ r[r.length - (O || 1)].range[0],
205
+ r[r.length - 1].range[1]
206
+ ]), pt = this.performAction.apply(q, [
207
+ f,
208
+ It,
209
+ lt,
210
+ Y.yy,
211
+ B[1],
212
+ w,
213
+ r
214
+ ].concat(li)), typeof pt < "u")
215
+ return pt;
216
+ O && (x = x.slice(0, -1 * O * 2), w = w.slice(0, -1 * O), r = r.slice(0, -1 * O)), x.push(this.productions_[B[1]][0]), w.push(q.$), r.push(q._$), Bt = at[x[x.length - 2]][x[x.length - 1]], x.push(Bt);
215
217
  break;
216
218
  case 3:
217
219
  return !0;
218
220
  }
219
221
  }
220
222
  return !0;
221
- }
222
- }, It = /* @__PURE__ */ (function() {
223
- var V = {
223
+ }, "parse")
224
+ }, Et = /* @__PURE__ */ (function() {
225
+ var F = {
224
226
  EOF: 1,
225
- parseError: function(l, u) {
227
+ parseError: /* @__PURE__ */ a(function(u, x) {
226
228
  if (this.yy.parser)
227
- this.yy.parser.parseError(l, u);
229
+ this.yy.parser.parseError(u, x);
228
230
  else
229
- throw new Error(l);
230
- },
231
+ throw new Error(u);
232
+ }, "parseError"),
231
233
  // resets the lexer, sets new input
232
- setInput: function(r, l) {
233
- return this.yy = l || this.yy || {}, this._input = r, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
234
+ setInput: /* @__PURE__ */ a(function(h, u) {
235
+ return this.yy = u || this.yy || {}, this._input = h, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
234
236
  first_line: 1,
235
237
  first_column: 0,
236
238
  last_line: 1,
237
239
  last_column: 0
238
240
  }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
239
- },
241
+ }, "setInput"),
240
242
  // consumes and returns one char from the input
241
- input: function() {
242
- var r = this._input[0];
243
- this.yytext += r, this.yyleng++, this.offset++, this.match += r, this.matched += r;
244
- var l = r.match(/(?:\r\n?|\n).*/g);
245
- return l ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), r;
246
- },
243
+ input: /* @__PURE__ */ a(function() {
244
+ var h = this._input[0];
245
+ this.yytext += h, this.yyleng++, this.offset++, this.match += h, this.matched += h;
246
+ var u = h.match(/(?:\r\n?|\n).*/g);
247
+ return u ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), h;
248
+ }, "input"),
247
249
  // unshifts one char (or a string) into the input
248
- unput: function(r) {
249
- var l = r.length, u = r.split(/(?:\r\n?|\n)/g);
250
- this._input = r + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - l), this.offset -= l;
251
- var g = this.match.split(/(?:\r\n?|\n)/g);
252
- this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), u.length - 1 && (this.yylineno -= u.length - 1);
253
- var b = this.yylloc.range;
250
+ unput: /* @__PURE__ */ a(function(h) {
251
+ var u = h.length, x = h.split(/(?:\r\n?|\n)/g);
252
+ this._input = h + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - u), this.offset -= u;
253
+ var d = this.match.split(/(?:\r\n?|\n)/g);
254
+ this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), x.length - 1 && (this.yylineno -= x.length - 1);
255
+ var w = this.yylloc.range;
254
256
  return this.yylloc = {
255
257
  first_line: this.yylloc.first_line,
256
258
  last_line: this.yylineno + 1,
257
259
  first_column: this.yylloc.first_column,
258
- last_column: u ? (u.length === g.length ? this.yylloc.first_column : 0) + g[g.length - u.length].length - u[0].length : this.yylloc.first_column - l
259
- }, this.options.ranges && (this.yylloc.range = [b[0], b[0] + this.yyleng - l]), this.yyleng = this.yytext.length, this;
260
- },
260
+ last_column: x ? (x.length === d.length ? this.yylloc.first_column : 0) + d[d.length - x.length].length - x[0].length : this.yylloc.first_column - u
261
+ }, this.options.ranges && (this.yylloc.range = [w[0], w[0] + this.yyleng - u]), this.yyleng = this.yytext.length, this;
262
+ }, "unput"),
261
263
  // When called from action, caches matched text and appends it on next action
262
- more: function() {
264
+ more: /* @__PURE__ */ a(function() {
263
265
  return this._more = !0, this;
264
- },
266
+ }, "more"),
265
267
  // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
266
- reject: function() {
268
+ reject: /* @__PURE__ */ a(function() {
267
269
  if (this.options.backtrack_lexer)
268
270
  this._backtrack = !0;
269
271
  else
@@ -274,31 +276,31 @@ Expecting ` + j.join(", ") + ", got '" + (this.terminals_[D] || D) + "'" : et =
274
276
  line: this.yylineno
275
277
  });
276
278
  return this;
277
- },
279
+ }, "reject"),
278
280
  // retain first n characters of the match
279
- less: function(r) {
280
- this.unput(this.match.slice(r));
281
- },
281
+ less: /* @__PURE__ */ a(function(h) {
282
+ this.unput(this.match.slice(h));
283
+ }, "less"),
282
284
  // displays already matched input, i.e. for error messages
283
- pastInput: function() {
284
- var r = this.matched.substr(0, this.matched.length - this.match.length);
285
- return (r.length > 20 ? "..." : "") + r.substr(-20).replace(/\n/g, "");
286
- },
285
+ pastInput: /* @__PURE__ */ a(function() {
286
+ var h = this.matched.substr(0, this.matched.length - this.match.length);
287
+ return (h.length > 20 ? "..." : "") + h.substr(-20).replace(/\n/g, "");
288
+ }, "pastInput"),
287
289
  // displays upcoming input, i.e. for error messages
288
- upcomingInput: function() {
289
- var r = this.match;
290
- return r.length < 20 && (r += this._input.substr(0, 20 - r.length)), (r.substr(0, 20) + (r.length > 20 ? "..." : "")).replace(/\n/g, "");
291
- },
290
+ upcomingInput: /* @__PURE__ */ a(function() {
291
+ var h = this.match;
292
+ return h.length < 20 && (h += this._input.substr(0, 20 - h.length)), (h.substr(0, 20) + (h.length > 20 ? "..." : "")).replace(/\n/g, "");
293
+ }, "upcomingInput"),
292
294
  // displays the character position where the lexing error occurred, i.e. for error messages
293
- showPosition: function() {
294
- var r = this.pastInput(), l = new Array(r.length + 1).join("-");
295
- return r + this.upcomingInput() + `
296
- ` + l + "^";
297
- },
295
+ showPosition: /* @__PURE__ */ a(function() {
296
+ var h = this.pastInput(), u = new Array(h.length + 1).join("-");
297
+ return h + this.upcomingInput() + `
298
+ ` + u + "^";
299
+ }, "showPosition"),
298
300
  // test the lexed token: return FALSE when not a match, otherwise return token
299
- test_match: function(r, l) {
300
- var u, g, b;
301
- if (this.options.backtrack_lexer && (b = {
301
+ test_match: /* @__PURE__ */ a(function(h, u) {
302
+ var x, d, w;
303
+ if (this.options.backtrack_lexer && (w = {
302
304
  yylineno: this.yylineno,
303
305
  yylloc: {
304
306
  first_line: this.yylloc.first_line,
@@ -317,80 +319,80 @@ Expecting ` + j.join(", ") + ", got '" + (this.terminals_[D] || D) + "'" : et =
317
319
  yy: this.yy,
318
320
  conditionStack: this.conditionStack.slice(0),
319
321
  done: this.done
320
- }, this.options.ranges && (b.yylloc.range = this.yylloc.range.slice(0))), g = r[0].match(/(?:\r\n?|\n).*/g), g && (this.yylineno += g.length), this.yylloc = {
322
+ }, this.options.ranges && (w.yylloc.range = this.yylloc.range.slice(0))), d = h[0].match(/(?:\r\n?|\n).*/g), d && (this.yylineno += d.length), this.yylloc = {
321
323
  first_line: this.yylloc.last_line,
322
324
  last_line: this.yylineno + 1,
323
325
  first_column: this.yylloc.last_column,
324
- last_column: g ? g[g.length - 1].length - g[g.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + r[0].length
325
- }, this.yytext += r[0], this.match += r[0], this.matches = r, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(r[0].length), this.matched += r[0], u = this.performAction.call(this, this.yy, this, l, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), u)
326
- return u;
326
+ last_column: d ? d[d.length - 1].length - d[d.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + h[0].length
327
+ }, this.yytext += h[0], this.match += h[0], this.matches = h, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(h[0].length), this.matched += h[0], x = this.performAction.call(this, this.yy, this, u, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), x)
328
+ return x;
327
329
  if (this._backtrack) {
328
- for (var a in b)
329
- this[a] = b[a];
330
+ for (var r in w)
331
+ this[r] = w[r];
330
332
  return !1;
331
333
  }
332
334
  return !1;
333
- },
335
+ }, "test_match"),
334
336
  // return next match in input
335
- next: function() {
337
+ next: /* @__PURE__ */ a(function() {
336
338
  if (this.done)
337
339
  return this.EOF;
338
340
  this._input || (this.done = !0);
339
- var r, l, u, g;
341
+ var h, u, x, d;
340
342
  this._more || (this.yytext = "", this.match = "");
341
- for (var b = this._currentRules(), a = 0; a < b.length; a++)
342
- if (u = this._input.match(this.rules[b[a]]), u && (!l || u[0].length > l[0].length)) {
343
- if (l = u, g = a, this.options.backtrack_lexer) {
344
- if (r = this.test_match(u, b[a]), r !== !1)
345
- return r;
343
+ for (var w = this._currentRules(), r = 0; r < w.length; r++)
344
+ if (x = this._input.match(this.rules[w[r]]), x && (!u || x[0].length > u[0].length)) {
345
+ if (u = x, d = r, this.options.backtrack_lexer) {
346
+ if (h = this.test_match(x, w[r]), h !== !1)
347
+ return h;
346
348
  if (this._backtrack) {
347
- l = !1;
349
+ u = !1;
348
350
  continue;
349
351
  } else
350
352
  return !1;
351
353
  } else if (!this.options.flex)
352
354
  break;
353
355
  }
354
- return l ? (r = this.test_match(l, b[g]), r !== !1 ? r : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
356
+ return u ? (h = this.test_match(u, w[d]), h !== !1 ? h : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
355
357
  ` + this.showPosition(), {
356
358
  text: "",
357
359
  token: null,
358
360
  line: this.yylineno
359
361
  });
360
- },
362
+ }, "next"),
361
363
  // return next match that has a token
362
- lex: function() {
363
- var l = this.next();
364
- return l || this.lex();
365
- },
364
+ lex: /* @__PURE__ */ a(function() {
365
+ var u = this.next();
366
+ return u || this.lex();
367
+ }, "lex"),
366
368
  // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
367
- begin: function(l) {
368
- this.conditionStack.push(l);
369
- },
369
+ begin: /* @__PURE__ */ a(function(u) {
370
+ this.conditionStack.push(u);
371
+ }, "begin"),
370
372
  // pop the previously active lexer condition state off the condition stack
371
- popState: function() {
372
- var l = this.conditionStack.length - 1;
373
- return l > 0 ? this.conditionStack.pop() : this.conditionStack[0];
374
- },
373
+ popState: /* @__PURE__ */ a(function() {
374
+ var u = this.conditionStack.length - 1;
375
+ return u > 0 ? this.conditionStack.pop() : this.conditionStack[0];
376
+ }, "popState"),
375
377
  // produce the lexer rule set which is active for the currently active lexer condition state
376
- _currentRules: function() {
378
+ _currentRules: /* @__PURE__ */ a(function() {
377
379
  return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
378
- },
380
+ }, "_currentRules"),
379
381
  // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
380
- topState: function(l) {
381
- return l = this.conditionStack.length - 1 - Math.abs(l || 0), l >= 0 ? this.conditionStack[l] : "INITIAL";
382
- },
382
+ topState: /* @__PURE__ */ a(function(u) {
383
+ return u = this.conditionStack.length - 1 - Math.abs(u || 0), u >= 0 ? this.conditionStack[u] : "INITIAL";
384
+ }, "topState"),
383
385
  // alias for begin(condition)
384
- pushState: function(l) {
385
- this.begin(l);
386
- },
386
+ pushState: /* @__PURE__ */ a(function(u) {
387
+ this.begin(u);
388
+ }, "pushState"),
387
389
  // return the number of states currently on the stack
388
- stateStackSize: function() {
390
+ stateStackSize: /* @__PURE__ */ a(function() {
389
391
  return this.conditionStack.length;
390
- },
392
+ }, "stateStackSize"),
391
393
  options: { "case-insensitive": !0 },
392
- performAction: function(l, u, g, b) {
393
- switch (g) {
394
+ performAction: /* @__PURE__ */ a(function(u, x, d, w) {
395
+ switch (d) {
394
396
  case 0:
395
397
  break;
396
398
  case 1:
@@ -424,102 +426,107 @@ Expecting ` + j.join(", ") + ", got '" + (this.terminals_[D] || D) + "'" : et =
424
426
  case 14:
425
427
  return 5;
426
428
  case 15:
427
- return 8;
429
+ return 5;
428
430
  case 16:
429
- return this.pushState("axis_data"), "X_AXIS";
431
+ return 8;
430
432
  case 17:
431
- return this.pushState("axis_data"), "Y_AXIS";
433
+ return this.pushState("axis_data"), "X_AXIS";
432
434
  case 18:
433
- return this.pushState("axis_band_data"), 24;
435
+ return this.pushState("axis_data"), "Y_AXIS";
434
436
  case 19:
435
- return 31;
437
+ return this.pushState("axis_band_data"), 24;
436
438
  case 20:
437
- return this.pushState("data"), 16;
439
+ return 31;
438
440
  case 21:
439
- return this.pushState("data"), 18;
441
+ return this.pushState("data"), 16;
440
442
  case 22:
441
- return this.pushState("data_inner"), 24;
443
+ return this.pushState("data"), 18;
442
444
  case 23:
443
- return 27;
445
+ return this.pushState("data_inner"), 24;
444
446
  case 24:
445
- return this.popState(), 26;
447
+ return 27;
446
448
  case 25:
449
+ return this.popState(), 26;
450
+ case 26:
447
451
  this.popState();
448
452
  break;
449
- case 26:
453
+ case 27:
450
454
  this.pushState("string");
451
455
  break;
452
- case 27:
456
+ case 28:
453
457
  this.popState();
454
458
  break;
455
- case 28:
456
- return "STR";
457
459
  case 29:
458
- return 24;
460
+ return "STR";
459
461
  case 30:
460
- return 26;
462
+ return 24;
461
463
  case 31:
462
- return 43;
464
+ return 26;
463
465
  case 32:
464
- return "COLON";
466
+ return 43;
465
467
  case 33:
466
- return 44;
468
+ return "COLON";
467
469
  case 34:
468
- return 28;
470
+ return 44;
469
471
  case 35:
470
- return 45;
472
+ return 28;
471
473
  case 36:
472
- return 46;
474
+ return 45;
473
475
  case 37:
474
- return 48;
476
+ return 46;
475
477
  case 38:
476
- return 50;
478
+ return 48;
477
479
  case 39:
478
- return 47;
480
+ return 50;
479
481
  case 40:
480
- return 41;
482
+ return 47;
481
483
  case 41:
482
- return 49;
484
+ return 41;
483
485
  case 42:
484
- return 42;
486
+ return 49;
485
487
  case 43:
486
- break;
488
+ return 42;
487
489
  case 44:
488
- return 35;
490
+ break;
489
491
  case 45:
492
+ return 35;
493
+ case 46:
490
494
  return 36;
491
495
  }
492
- },
493
- rules: [/^(?:%%(?!\{)[^\n]*)/i, /^(?:[^\}]%%[^\n]*)/i, /^(?:(\r?\n))/i, /^(?:(\r?\n))/i, /^(?:[\n\r]+)/i, /^(?:%%[^\n]*)/i, /^(?:title\b)/i, /^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:\{)/i, /^(?:[^\}]*)/i, /^(?:xychart-beta\b)/i, /^(?:(?:vertical|horizontal))/i, /^(?:x-axis\b)/i, /^(?:y-axis\b)/i, /^(?:\[)/i, /^(?:-->)/i, /^(?:line\b)/i, /^(?:bar\b)/i, /^(?:\[)/i, /^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i, /^(?:\])/i, /^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i, /^(?:["])/i, /^(?:["])/i, /^(?:[^"]*)/i, /^(?:\[)/i, /^(?:\])/i, /^(?:[A-Za-z]+)/i, /^(?::)/i, /^(?:\+)/i, /^(?:,)/i, /^(?:=)/i, /^(?:\*)/i, /^(?:#)/i, /^(?:[\_])/i, /^(?:\.)/i, /^(?:&)/i, /^(?:-)/i, /^(?:[0-9]+)/i, /^(?:\s+)/i, /^(?:;)/i, /^(?:$)/i],
494
- conditions: { data_inner: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 20, 21, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45], inclusive: !0 }, data: { rules: [0, 1, 3, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 20, 21, 22, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45], inclusive: !0 }, axis_band_data: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 20, 21, 24, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45], inclusive: !0 }, axis_data: { rules: [0, 1, 2, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 19, 20, 21, 23, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45], inclusive: !0 }, acc_descr_multiline: { rules: [12, 13], inclusive: !1 }, acc_descr: { rules: [10], inclusive: !1 }, acc_title: { rules: [8], inclusive: !1 }, title: { rules: [], inclusive: !1 }, md_string: { rules: [], inclusive: !1 }, string: { rules: [27, 28], inclusive: !1 }, INITIAL: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 20, 21, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45], inclusive: !0 } }
496
+ }, "anonymous"),
497
+ rules: [/^(?:%%(?!\{)[^\n]*)/i, /^(?:[^\}]%%[^\n]*)/i, /^(?:(\r?\n))/i, /^(?:(\r?\n))/i, /^(?:[\n\r]+)/i, /^(?:%%[^\n]*)/i, /^(?:title\b)/i, /^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:\{)/i, /^(?:[^\}]*)/i, /^(?:xychart-beta\b)/i, /^(?:xychart\b)/i, /^(?:(?:vertical|horizontal))/i, /^(?:x-axis\b)/i, /^(?:y-axis\b)/i, /^(?:\[)/i, /^(?:-->)/i, /^(?:line\b)/i, /^(?:bar\b)/i, /^(?:\[)/i, /^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i, /^(?:\])/i, /^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i, /^(?:["])/i, /^(?:["])/i, /^(?:[^"]*)/i, /^(?:\[)/i, /^(?:\])/i, /^(?:[A-Za-z]+)/i, /^(?::)/i, /^(?:\+)/i, /^(?:,)/i, /^(?:=)/i, /^(?:\*)/i, /^(?:#)/i, /^(?:[\_])/i, /^(?:\.)/i, /^(?:&)/i, /^(?:-)/i, /^(?:[0-9]+)/i, /^(?:\s+)/i, /^(?:;)/i, /^(?:$)/i],
498
+ conditions: { data_inner: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 21, 22, 24, 25, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46], inclusive: !0 }, data: { rules: [0, 1, 3, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 21, 22, 23, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46], inclusive: !0 }, axis_band_data: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 21, 22, 25, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46], inclusive: !0 }, axis_data: { rules: [0, 1, 2, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 19, 20, 21, 22, 24, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46], inclusive: !0 }, acc_descr_multiline: { rules: [12, 13], inclusive: !1 }, acc_descr: { rules: [10], inclusive: !1 }, acc_title: { rules: [8], inclusive: !1 }, title: { rules: [], inclusive: !1 }, md_string: { rules: [], inclusive: !1 }, string: { rules: [28, 29], inclusive: !1 }, INITIAL: { rules: [0, 1, 4, 5, 6, 7, 9, 11, 14, 15, 16, 17, 18, 21, 22, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46], inclusive: !0 } }
495
499
  };
496
- return V;
500
+ return F;
497
501
  })();
498
- K.lexer = It;
499
- function Z() {
502
+ $.lexer = Et;
503
+ function N() {
500
504
  this.yy = {};
501
505
  }
502
- return Z.prototype = K, K.Parser = Z, new Z();
506
+ return a(N, "Parser"), N.prototype = $, $.Parser = N, new N();
503
507
  })();
504
- nt.parser = nt;
505
- const ti = nt;
506
- function mt(e) {
508
+ bt.parser = bt;
509
+ var Ti = bt;
510
+ function At(e) {
507
511
  return e.type === "bar";
508
512
  }
513
+ a(At, "isBarPlot");
509
514
  function _t(e) {
510
515
  return e.type === "band";
511
516
  }
512
- function N(e) {
517
+ a(_t, "isBandAxisData");
518
+ function G(e) {
513
519
  return e.type === "linear";
514
520
  }
515
- class kt {
521
+ a(G, "isLinearAxisData");
522
+ var j, Ht = (j = class {
516
523
  constructor(t) {
517
524
  this.parentGroup = t;
518
525
  }
519
526
  getMaxDimension(t, i) {
520
527
  if (!this.parentGroup)
521
528
  return {
522
- width: t.reduce((o, c) => Math.max(c.length, o), 0) * i,
529
+ width: t.reduce((o, g) => Math.max(g.length, o), 0) * i,
523
530
  height: i
524
531
  };
525
532
  const s = {
@@ -527,14 +534,12 @@ class kt {
527
534
  height: 0
528
535
  }, n = this.parentGroup.append("g").attr("visibility", "hidden").attr("font-size", i);
529
536
  for (const o of t) {
530
- const c = Qt(n, 1, o), f = c ? c.width : o.length * i, d = c ? c.height : i;
531
- s.width = Math.max(s.width, f), s.height = Math.max(s.height, d);
537
+ const g = Si(n, 1, o), m = g ? g.width : o.length * i, p = g ? g.height : i;
538
+ s.width = Math.max(s.width, m), s.height = Math.max(s.height, p);
532
539
  }
533
540
  return n.remove(), s;
534
541
  }
535
- }
536
- const yt = 0.7, bt = 0.2;
537
- class Rt {
542
+ }, a(j, "TextDimensionCalculatorWithFont"), j), Ft = 0.7, Ot = 0.2, Q, Ut = (Q = class {
538
543
  constructor(t, i, s, n) {
539
544
  this.axisConfig = t, this.title = i, this.textDimensionCalculator = s, this.axisThemeConfig = n, this.boundingRect = { x: 0, y: 0, width: 0, height: 0 }, this.axisPosition = "left", this.showTitle = !1, this.showLabel = !1, this.showTick = !1, this.showAxisLine = !1, this.outerPadding = 0, this.titleTextHeight = 0, this.labelTextHeight = 0, this.range = [0, 10], this.boundingRect = { x: 0, y: 0, width: 0, height: 0 }, this.axisPosition = "left";
540
545
  }
@@ -561,12 +566,12 @@ class Rt {
561
566
  );
562
567
  }
563
568
  recalculateOuterPaddingToDrawBar() {
564
- yt * this.getTickDistance() > this.outerPadding * 2 && (this.outerPadding = Math.floor(yt * this.getTickDistance() / 2)), this.recalculateScale();
569
+ Ft * this.getTickDistance() > this.outerPadding * 2 && (this.outerPadding = Math.floor(Ft * this.getTickDistance() / 2)), this.recalculateScale();
565
570
  }
566
571
  calculateSpaceIfDrawnHorizontally(t) {
567
572
  let i = t.height;
568
573
  if (this.axisConfig.showAxisLine && i > this.axisConfig.axisLineWidth && (i -= this.axisConfig.axisLineWidth, this.showAxisLine = !0), this.axisConfig.showLabel) {
569
- const s = this.getLabelDimension(), n = bt * t.width;
574
+ const s = this.getLabelDimension(), n = Ot * t.width;
570
575
  this.outerPadding = Math.min(s.width / 2, n);
571
576
  const o = s.height + this.axisConfig.labelPadding * 2;
572
577
  this.labelTextHeight = s.height, o <= i && (i -= o, this.showLabel = !0);
@@ -583,7 +588,7 @@ class Rt {
583
588
  calculateSpaceIfDrawnVertical(t) {
584
589
  let i = t.width;
585
590
  if (this.axisConfig.showAxisLine && i > this.axisConfig.axisLineWidth && (i -= this.axisConfig.axisLineWidth, this.showAxisLine = !0), this.axisConfig.showLabel) {
586
- const s = this.getLabelDimension(), n = bt * t.height;
591
+ const s = this.getLabelDimension(), n = Ot * t.height;
587
592
  this.outerPadding = Math.min(s.height / 2, n);
588
593
  const o = s.width + this.axisConfig.labelPadding * 2;
589
594
  o <= i && (i -= o, this.showLabel = !0);
@@ -787,48 +792,46 @@ class Rt {
787
792
  throw Error("Drawing of right axis is not implemented");
788
793
  return this.axisPosition === "bottom" ? this.getDrawableElementsForBottomAxis() : this.axisPosition === "top" ? this.getDrawableElementsForTopAxis() : [];
789
794
  }
790
- }
791
- class ii extends Rt {
795
+ }, a(Q, "BaseAxis"), Q), K, Di = (K = class extends Ut {
792
796
  constructor(t, i, s, n, o) {
793
- super(t, n, o, i), this.categories = s, this.scale = st().domain(this.categories).range(this.getRange());
797
+ super(t, n, o, i), this.categories = s, this.scale = yt().domain(this.categories).range(this.getRange());
794
798
  }
795
799
  setRange(t) {
796
800
  super.setRange(t);
797
801
  }
798
802
  recalculateScale() {
799
- this.scale = st().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(0.5), St.trace("BandAxis axis final categories, range: ", this.categories, this.getRange());
803
+ this.scale = yt().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(0.5), Nt.trace("BandAxis axis final categories, range: ", this.categories, this.getRange());
800
804
  }
801
805
  getTickValues() {
802
806
  return this.categories;
803
807
  }
804
808
  getScaleValue(t) {
805
- return this.scale(t) || this.getRange()[0];
809
+ return this.scale(t) ?? this.getRange()[0];
806
810
  }
807
- }
808
- class ei extends Rt {
811
+ }, a(K, "BandAxis"), K), Z, vi = (Z = class extends Ut {
809
812
  constructor(t, i, s, n, o) {
810
- super(t, n, o, i), this.domain = s, this.scale = ft().domain(this.domain).range(this.getRange());
813
+ super(t, n, o, i), this.domain = s, this.scale = zt().domain(this.domain).range(this.getRange());
811
814
  }
812
815
  getTickValues() {
813
816
  return this.scale.ticks();
814
817
  }
815
818
  recalculateScale() {
816
819
  const t = [...this.domain];
817
- this.axisPosition === "left" && t.reverse(), this.scale = ft().domain(t).range(this.getRange());
820
+ this.axisPosition === "left" && t.reverse(), this.scale = zt().domain(t).range(this.getRange());
818
821
  }
819
822
  getScaleValue(t) {
820
823
  return this.scale(t);
821
824
  }
822
- }
823
- function At(e, t, i, s) {
824
- const n = new kt(s);
825
- return _t(e) ? new ii(
825
+ }, a(Z, "LinearAxis"), Z);
826
+ function wt(e, t, i, s) {
827
+ const n = new Ht(s);
828
+ return _t(e) ? new Di(
826
829
  t,
827
830
  i,
828
831
  e.categories,
829
832
  e.title,
830
833
  n
831
- ) : new ei(
834
+ ) : new vi(
832
835
  t,
833
836
  i,
834
837
  [e.min, e.max],
@@ -836,7 +839,8 @@ function At(e, t, i, s) {
836
839
  n
837
840
  );
838
841
  }
839
- class si {
842
+ a(wt, "getAxis");
843
+ var J, Pi = (J = class {
840
844
  constructor(t, i, s, n) {
841
845
  this.textDimensionCalculator = t, this.chartConfig = i, this.chartData = s, this.chartThemeConfig = n, this.boundingRect = {
842
846
  x: 0,
@@ -877,12 +881,13 @@ class si {
877
881
  ]
878
882
  }), t;
879
883
  }
884
+ }, a(J, "ChartTitle"), J);
885
+ function $t(e, t, i, s) {
886
+ const n = new Ht(s);
887
+ return new Pi(n, e, t, i);
880
888
  }
881
- function ni(e, t, i, s) {
882
- const n = new kt(s);
883
- return new si(n, e, t, i);
884
- }
885
- class ai {
889
+ a($t, "getChartTitleComponent");
890
+ var tt, Li = (tt = class {
886
891
  constructor(t, i, s, n, o) {
887
892
  this.plotData = t, this.xAxis = i, this.yAxis = s, this.orientation = n, this.plotIndex = o;
888
893
  }
@@ -892,7 +897,7 @@ class ai {
892
897
  this.yAxis.getScaleValue(s[1])
893
898
  ]);
894
899
  let i;
895
- return this.orientation === "horizontal" ? i = pt().y((s) => s[0]).x((s) => s[1])(t) : i = pt().x((s) => s[0]).y((s) => s[1])(t), i ? [
900
+ return this.orientation === "horizontal" ? i = Wt().y((s) => s[0]).x((s) => s[1])(t) : i = Wt().x((s) => s[0]).y((s) => s[1])(t), i ? [
896
901
  {
897
902
  groupTexts: ["plot", `line-plot-${this.plotIndex}`],
898
903
  type: "path",
@@ -906,10 +911,9 @@ class ai {
906
911
  }
907
912
  ] : [];
908
913
  }
909
- }
910
- class oi {
911
- constructor(t, i, s, n, o, c) {
912
- this.barData = t, this.boundingRect = i, this.xAxis = s, this.yAxis = n, this.orientation = o, this.plotIndex = c;
914
+ }, a(tt, "LinePlot"), tt), it, Ei = (it = class {
915
+ constructor(t, i, s, n, o, g) {
916
+ this.barData = t, this.boundingRect = i, this.xAxis = s, this.yAxis = n, this.orientation = o, this.plotIndex = g;
913
917
  }
914
918
  getDrawableElement() {
915
919
  const t = this.barData.data.map((o) => [
@@ -946,8 +950,7 @@ class oi {
946
950
  }
947
951
  ];
948
952
  }
949
- }
950
- class ri {
953
+ }, a(it, "BarPlot"), it), et, Ii = (et = class {
951
954
  constructor(t, i, s) {
952
955
  this.chartConfig = t, this.chartData = i, this.chartThemeConfig = s, this.boundingRect = {
953
956
  x: 0,
@@ -976,7 +979,7 @@ class ri {
976
979
  switch (s.type) {
977
980
  case "line":
978
981
  {
979
- const n = new ai(
982
+ const n = new Li(
980
983
  s,
981
984
  this.xAxis,
982
985
  this.yAxis,
@@ -988,7 +991,7 @@ class ri {
988
991
  break;
989
992
  case "bar":
990
993
  {
991
- const n = new oi(
994
+ const n = new Ei(
992
995
  s,
993
996
  this.boundingRect,
994
997
  this.xAxis,
@@ -1002,16 +1005,17 @@ class ri {
1002
1005
  }
1003
1006
  return t;
1004
1007
  }
1008
+ }, a(et, "BasePlot"), et);
1009
+ function qt(e, t, i) {
1010
+ return new Ii(e, t, i);
1005
1011
  }
1006
- function hi(e, t, i) {
1007
- return new ri(e, t, i);
1008
- }
1009
- class li {
1012
+ a(qt, "getPlotComponent");
1013
+ var st, Mi = (st = class {
1010
1014
  constructor(t, i, s, n) {
1011
1015
  this.chartConfig = t, this.chartData = i, this.componentStore = {
1012
- title: ni(t, i, s, n),
1013
- plot: hi(t, i, s),
1014
- xAxis: At(
1016
+ title: $t(t, i, s, n),
1017
+ plot: qt(t, i, s),
1018
+ xAxis: wt(
1015
1019
  i.xAxis,
1016
1020
  t.xAxis,
1017
1021
  {
@@ -1022,7 +1026,7 @@ class li {
1022
1026
  },
1023
1027
  n
1024
1028
  ),
1025
- yAxis: At(
1029
+ yAxis: wt(
1026
1030
  i.yAxis,
1027
1031
  t.yAxis,
1028
1032
  {
@@ -1036,46 +1040,46 @@ class li {
1036
1040
  };
1037
1041
  }
1038
1042
  calculateVerticalSpace() {
1039
- let t = this.chartConfig.width, i = this.chartConfig.height, s = 0, n = 0, o = Math.floor(t * this.chartConfig.plotReservedSpacePercent / 100), c = Math.floor(
1043
+ let t = this.chartConfig.width, i = this.chartConfig.height, s = 0, n = 0, o = Math.floor(t * this.chartConfig.plotReservedSpacePercent / 100), g = Math.floor(
1040
1044
  i * this.chartConfig.plotReservedSpacePercent / 100
1041
- ), f = this.componentStore.plot.calculateSpace({
1045
+ ), m = this.componentStore.plot.calculateSpace({
1042
1046
  width: o,
1043
- height: c
1047
+ height: g
1044
1048
  });
1045
- t -= f.width, i -= f.height, f = this.componentStore.title.calculateSpace({
1049
+ t -= m.width, i -= m.height, m = this.componentStore.title.calculateSpace({
1046
1050
  width: this.chartConfig.width,
1047
1051
  height: i
1048
- }), n = f.height, i -= f.height, this.componentStore.xAxis.setAxisPosition("bottom"), f = this.componentStore.xAxis.calculateSpace({
1052
+ }), n = m.height, i -= m.height, this.componentStore.xAxis.setAxisPosition("bottom"), m = this.componentStore.xAxis.calculateSpace({
1049
1053
  width: t,
1050
1054
  height: i
1051
- }), i -= f.height, this.componentStore.yAxis.setAxisPosition("left"), f = this.componentStore.yAxis.calculateSpace({
1055
+ }), i -= m.height, this.componentStore.yAxis.setAxisPosition("left"), m = this.componentStore.yAxis.calculateSpace({
1052
1056
  width: t,
1053
1057
  height: i
1054
- }), s = f.width, t -= f.width, t > 0 && (o += t, t = 0), i > 0 && (c += i, i = 0), this.componentStore.plot.calculateSpace({
1058
+ }), s = m.width, t -= m.width, t > 0 && (o += t, t = 0), i > 0 && (g += i, i = 0), this.componentStore.plot.calculateSpace({
1055
1059
  width: o,
1056
- height: c
1057
- }), this.componentStore.plot.setBoundingBoxXY({ x: s, y: n }), this.componentStore.xAxis.setRange([s, s + o]), this.componentStore.xAxis.setBoundingBoxXY({ x: s, y: n + c }), this.componentStore.yAxis.setRange([n, n + c]), this.componentStore.yAxis.setBoundingBoxXY({ x: 0, y: n }), this.chartData.plots.some((d) => mt(d)) && this.componentStore.xAxis.recalculateOuterPaddingToDrawBar();
1060
+ height: g
1061
+ }), this.componentStore.plot.setBoundingBoxXY({ x: s, y: n }), this.componentStore.xAxis.setRange([s, s + o]), this.componentStore.xAxis.setBoundingBoxXY({ x: s, y: n + g }), this.componentStore.yAxis.setRange([n, n + g]), this.componentStore.yAxis.setBoundingBoxXY({ x: 0, y: n }), this.chartData.plots.some((p) => At(p)) && this.componentStore.xAxis.recalculateOuterPaddingToDrawBar();
1058
1062
  }
1059
1063
  calculateHorizontalSpace() {
1060
- let t = this.chartConfig.width, i = this.chartConfig.height, s = 0, n = 0, o = 0, c = Math.floor(t * this.chartConfig.plotReservedSpacePercent / 100), f = Math.floor(
1064
+ let t = this.chartConfig.width, i = this.chartConfig.height, s = 0, n = 0, o = 0, g = Math.floor(t * this.chartConfig.plotReservedSpacePercent / 100), m = Math.floor(
1061
1065
  i * this.chartConfig.plotReservedSpacePercent / 100
1062
- ), d = this.componentStore.plot.calculateSpace({
1063
- width: c,
1064
- height: f
1066
+ ), p = this.componentStore.plot.calculateSpace({
1067
+ width: g,
1068
+ height: m
1065
1069
  });
1066
- t -= d.width, i -= d.height, d = this.componentStore.title.calculateSpace({
1070
+ t -= p.width, i -= p.height, p = this.componentStore.title.calculateSpace({
1067
1071
  width: this.chartConfig.width,
1068
1072
  height: i
1069
- }), s = d.height, i -= d.height, this.componentStore.xAxis.setAxisPosition("left"), d = this.componentStore.xAxis.calculateSpace({
1073
+ }), s = p.height, i -= p.height, this.componentStore.xAxis.setAxisPosition("left"), p = this.componentStore.xAxis.calculateSpace({
1070
1074
  width: t,
1071
1075
  height: i
1072
- }), t -= d.width, n = d.width, this.componentStore.yAxis.setAxisPosition("top"), d = this.componentStore.yAxis.calculateSpace({
1076
+ }), t -= p.width, n = p.width, this.componentStore.yAxis.setAxisPosition("top"), p = this.componentStore.yAxis.calculateSpace({
1073
1077
  width: t,
1074
1078
  height: i
1075
- }), i -= d.height, o = s + d.height, t > 0 && (c += t, t = 0), i > 0 && (f += i, i = 0), this.componentStore.plot.calculateSpace({
1076
- width: c,
1077
- height: f
1078
- }), this.componentStore.plot.setBoundingBoxXY({ x: n, y: o }), this.componentStore.yAxis.setRange([n, n + c]), this.componentStore.yAxis.setBoundingBoxXY({ x: n, y: s }), this.componentStore.xAxis.setRange([o, o + f]), this.componentStore.xAxis.setBoundingBoxXY({ x: 0, y: o }), this.chartData.plots.some((R) => mt(R)) && this.componentStore.xAxis.recalculateOuterPaddingToDrawBar();
1079
+ }), i -= p.height, o = s + p.height, t > 0 && (g += t, t = 0), i > 0 && (m += i, i = 0), this.componentStore.plot.calculateSpace({
1080
+ width: g,
1081
+ height: m
1082
+ }), this.componentStore.plot.setBoundingBoxXY({ x: n, y: o }), this.componentStore.yAxis.setRange([n, n + g]), this.componentStore.yAxis.setBoundingBoxXY({ x: n, y: s }), this.componentStore.xAxis.setRange([o, o + m]), this.componentStore.xAxis.setBoundingBoxXY({ x: 0, y: o }), this.chartData.plots.some((k) => At(k)) && this.componentStore.xAxis.recalculateOuterPaddingToDrawBar();
1079
1083
  }
1080
1084
  calculateSpace() {
1081
1085
  this.chartConfig.chartOrientation === "horizontal" ? this.calculateHorizontalSpace() : this.calculateVerticalSpace();
@@ -1088,25 +1092,25 @@ class li {
1088
1092
  t.push(...i.getDrawableElements());
1089
1093
  return t;
1090
1094
  }
1091
- }
1092
- class ci {
1095
+ }, a(st, "Orchestrator"), st), nt, Vi = (nt = class {
1093
1096
  static build(t, i, s, n) {
1094
- return new li(t, i, s, n).getDrawableElement();
1097
+ return new Mi(t, i, s, n).getDrawableElement();
1095
1098
  }
1099
+ }, a(nt, "XYChartBuilder"), nt), rt = 0, Gt, ot = Tt(), ht = Rt(), A = Dt(), Ct = ht.plotColorPalette.split(",").map((e) => e.trim()), gt = !1, kt = !1;
1100
+ function Rt() {
1101
+ const e = wi(), t = St();
1102
+ return Yt(e.xyChart, t.themeVariables.xyChart);
1096
1103
  }
1097
- let X = 0, Tt, Y = Pt(), H = Dt(), y = Lt(), at = H.plotColorPalette.split(",").map((e) => e.trim()), G = !1, rt = !1;
1098
- function Dt() {
1099
- const e = jt(), t = ot();
1100
- return Ct(e.xyChart, t.themeVariables.xyChart);
1101
- }
1102
- function Pt() {
1103
- const e = ot();
1104
- return Ct(
1105
- qt.xyChart,
1104
+ a(Rt, "getChartDefaultThemeConfig");
1105
+ function Tt() {
1106
+ const e = St();
1107
+ return Yt(
1108
+ Ai.xyChart,
1106
1109
  e.xyChart
1107
1110
  );
1108
1111
  }
1109
- function Lt() {
1112
+ a(Tt, "getChartDefaultConfig");
1113
+ function Dt() {
1110
1114
  return {
1111
1115
  yAxis: {
1112
1116
  type: "linear",
@@ -1123,160 +1127,214 @@ function Lt() {
1123
1127
  plots: []
1124
1128
  };
1125
1129
  }
1126
- function ht(e) {
1127
- const t = ot();
1128
- return Gt(e.trim(), t);
1130
+ a(Dt, "getChartDefaultData");
1131
+ function xt(e) {
1132
+ const t = St();
1133
+ return Ci(e.trim(), t);
1129
1134
  }
1130
- function ui(e) {
1131
- Tt = e;
1135
+ a(xt, "textSanitizer");
1136
+ function jt(e) {
1137
+ Gt = e;
1132
1138
  }
1133
- function gi(e) {
1134
- e === "horizontal" ? Y.chartOrientation = "horizontal" : Y.chartOrientation = "vertical";
1139
+ a(jt, "setTmpSVGG");
1140
+ function Qt(e) {
1141
+ e === "horizontal" ? ot.chartOrientation = "horizontal" : ot.chartOrientation = "vertical";
1135
1142
  }
1136
- function xi(e) {
1137
- y.xAxis.title = ht(e.text);
1143
+ a(Qt, "setOrientation");
1144
+ function Kt(e) {
1145
+ A.xAxis.title = xt(e.text);
1138
1146
  }
1139
- function Et(e, t) {
1140
- y.xAxis = { type: "linear", title: y.xAxis.title, min: e, max: t }, G = !0;
1147
+ a(Kt, "setXAxisTitle");
1148
+ function vt(e, t) {
1149
+ A.xAxis = { type: "linear", title: A.xAxis.title, min: e, max: t }, gt = !0;
1141
1150
  }
1142
- function di(e) {
1143
- y.xAxis = {
1151
+ a(vt, "setXAxisRangeData");
1152
+ function Zt(e) {
1153
+ A.xAxis = {
1144
1154
  type: "band",
1145
- title: y.xAxis.title,
1146
- categories: e.map((t) => ht(t.text))
1147
- }, G = !0;
1155
+ title: A.xAxis.title,
1156
+ categories: e.map((t) => xt(t.text))
1157
+ }, gt = !0;
1148
1158
  }
1149
- function fi(e) {
1150
- y.yAxis.title = ht(e.text);
1159
+ a(Zt, "setXAxisBand");
1160
+ function Jt(e) {
1161
+ A.yAxis.title = xt(e.text);
1151
1162
  }
1152
- function pi(e, t) {
1153
- y.yAxis = { type: "linear", title: y.yAxis.title, min: e, max: t }, rt = !0;
1163
+ a(Jt, "setYAxisTitle");
1164
+ function ti(e, t) {
1165
+ A.yAxis = { type: "linear", title: A.yAxis.title, min: e, max: t }, kt = !0;
1154
1166
  }
1155
- function mi(e) {
1156
- const t = Math.min(...e), i = Math.max(...e), s = N(y.yAxis) ? y.yAxis.min : 1 / 0, n = N(y.yAxis) ? y.yAxis.max : -1 / 0;
1157
- y.yAxis = {
1167
+ a(ti, "setYAxisRangeData");
1168
+ function ii(e) {
1169
+ const t = Math.min(...e), i = Math.max(...e), s = G(A.yAxis) ? A.yAxis.min : 1 / 0, n = G(A.yAxis) ? A.yAxis.max : -1 / 0;
1170
+ A.yAxis = {
1158
1171
  type: "linear",
1159
- title: y.yAxis.title,
1172
+ title: A.yAxis.title,
1160
1173
  min: Math.min(s, t),
1161
1174
  max: Math.max(n, i)
1162
1175
  };
1163
1176
  }
1164
- function vt(e) {
1177
+ a(ii, "setYAxisRangeFromPlotData");
1178
+ function Pt(e) {
1165
1179
  let t = [];
1166
1180
  if (e.length === 0)
1167
1181
  return t;
1168
- if (!G) {
1169
- const i = N(y.xAxis) ? y.xAxis.min : 1 / 0, s = N(y.xAxis) ? y.xAxis.max : -1 / 0;
1170
- Et(Math.min(i, 1), Math.max(s, e.length));
1182
+ if (!gt) {
1183
+ const i = G(A.xAxis) ? A.xAxis.min : 1 / 0, s = G(A.xAxis) ? A.xAxis.max : -1 / 0;
1184
+ vt(Math.min(i, 1), Math.max(s, e.length));
1171
1185
  }
1172
- if (rt || mi(e), _t(y.xAxis) && (t = y.xAxis.categories.map((i, s) => [i, e[s]])), N(y.xAxis)) {
1173
- const i = y.xAxis.min, s = y.xAxis.max, n = (s - i + 1) / e.length, o = [];
1174
- for (let c = i; c <= s; c += n)
1175
- o.push(`${c}`);
1176
- t = o.map((c, f) => [c, e[f]]);
1186
+ if (kt || ii(e), _t(A.xAxis) && (t = A.xAxis.categories.map((i, s) => [i, e[s]])), G(A.xAxis)) {
1187
+ const i = A.xAxis.min, s = A.xAxis.max, n = (s - i) / (e.length - 1), o = [];
1188
+ for (let g = i; g <= s; g += n)
1189
+ o.push(`${g}`);
1190
+ t = o.map((g, m) => [g, e[m]]);
1177
1191
  }
1178
1192
  return t;
1179
1193
  }
1180
- function Mt(e) {
1181
- return at[e === 0 ? 0 : e % at.length];
1194
+ a(Pt, "transformDataWithoutCategory");
1195
+ function Lt(e) {
1196
+ return Ct[e === 0 ? 0 : e % Ct.length];
1182
1197
  }
1183
- function yi(e, t) {
1184
- const i = vt(t);
1185
- y.plots.push({
1198
+ a(Lt, "getPlotColorFromPalette");
1199
+ function ei(e, t) {
1200
+ const i = Pt(t);
1201
+ A.plots.push({
1186
1202
  type: "line",
1187
- strokeFill: Mt(X),
1203
+ strokeFill: Lt(rt),
1188
1204
  strokeWidth: 2,
1189
1205
  data: i
1190
- }), X++;
1206
+ }), rt++;
1191
1207
  }
1192
- function bi(e, t) {
1193
- const i = vt(t);
1194
- y.plots.push({
1208
+ a(ei, "setLineData");
1209
+ function si(e, t) {
1210
+ const i = Pt(t);
1211
+ A.plots.push({
1195
1212
  type: "bar",
1196
- fill: Mt(X),
1213
+ fill: Lt(rt),
1197
1214
  data: i
1198
- }), X++;
1215
+ }), rt++;
1199
1216
  }
1200
- function Ai() {
1201
- if (y.plots.length === 0)
1217
+ a(si, "setBarData");
1218
+ function ni() {
1219
+ if (A.plots.length === 0)
1202
1220
  throw Error("No Plot to render, please provide a plot with some data");
1203
- return y.title = wt(), ci.build(Y, y, H, Tt);
1221
+ return A.title = Xt(), Vi.build(ot, A, ht, Gt);
1204
1222
  }
1205
- function wi() {
1206
- return H;
1223
+ a(ni, "getDrawableElem");
1224
+ function ai() {
1225
+ return ht;
1207
1226
  }
1208
- function Si() {
1209
- return Y;
1227
+ a(ai, "getChartThemeConfig");
1228
+ function ri() {
1229
+ return ot;
1210
1230
  }
1211
- const Ci = function() {
1212
- Ut(), X = 0, Y = Pt(), y = Lt(), H = Dt(), at = H.plotColorPalette.split(",").map((e) => e.trim()), G = !1, rt = !1;
1213
- }, _i = {
1214
- getDrawableElem: Ai,
1215
- clear: Ci,
1216
- setAccTitle: Yt,
1217
- getAccTitle: Xt,
1218
- setDiagramTitle: Nt,
1219
- getDiagramTitle: wt,
1220
- getAccDescription: Ft,
1221
- setAccDescription: zt,
1222
- setOrientation: gi,
1223
- setXAxisTitle: xi,
1224
- setXAxisRangeData: Et,
1225
- setXAxisBand: di,
1226
- setYAxisTitle: fi,
1227
- setYAxisRangeData: pi,
1228
- setLineData: yi,
1229
- setBarData: bi,
1230
- setTmpSVGG: ui,
1231
- getChartThemeConfig: wi,
1232
- getChartConfig: Si
1233
- }, ki = (e, t, i, s) => {
1234
- const n = s.db, o = n.getChartThemeConfig(), c = n.getChartConfig();
1235
- function f(p) {
1236
- return p === "top" ? "text-before-edge" : "middle";
1231
+ a(ri, "getChartConfig");
1232
+ function oi() {
1233
+ return A;
1234
+ }
1235
+ a(oi, "getXYChartData");
1236
+ var Bi = /* @__PURE__ */ a(function() {
1237
+ bi(), rt = 0, ot = Tt(), A = Dt(), ht = Rt(), Ct = ht.plotColorPalette.split(",").map((e) => e.trim()), gt = !1, kt = !1;
1238
+ }, "clear"), Wi = {
1239
+ getDrawableElem: ni,
1240
+ clear: Bi,
1241
+ setAccTitle: pi,
1242
+ getAccTitle: fi,
1243
+ setDiagramTitle: di,
1244
+ getDiagramTitle: Xt,
1245
+ getAccDescription: xi,
1246
+ setAccDescription: gi,
1247
+ setOrientation: Qt,
1248
+ setXAxisTitle: Kt,
1249
+ setXAxisRangeData: vt,
1250
+ setXAxisBand: Zt,
1251
+ setYAxisTitle: Jt,
1252
+ setYAxisRangeData: ti,
1253
+ setLineData: ei,
1254
+ setBarData: si,
1255
+ setTmpSVGG: jt,
1256
+ getChartThemeConfig: ai,
1257
+ getChartConfig: ri,
1258
+ getXYChartData: oi
1259
+ }, zi = /* @__PURE__ */ a((e, t, i, s) => {
1260
+ const n = s.db, o = n.getChartThemeConfig(), g = n.getChartConfig(), m = n.getXYChartData().plots[0].data.map((y) => y[1]);
1261
+ function p(y) {
1262
+ return y === "top" ? "text-before-edge" : "middle";
1237
1263
  }
1238
- function d(p) {
1239
- return p === "left" ? "start" : p === "right" ? "end" : "middle";
1264
+ a(p, "getDominantBaseLine");
1265
+ function k(y) {
1266
+ return y === "left" ? "start" : y === "right" ? "end" : "middle";
1240
1267
  }
1241
- function R(p) {
1242
- return `translate(${p.x}, ${p.y}) rotate(${p.rotation || 0})`;
1268
+ a(k, "getTextAnchor");
1269
+ function v(y) {
1270
+ return `translate(${y.x}, ${y.y}) rotate(${y.rotation || 0})`;
1243
1271
  }
1244
- St.debug(`Rendering xychart chart
1272
+ a(v, "getTextTransformation"), Nt.debug(`Rendering xychart chart
1245
1273
  ` + e);
1246
- const _ = Ht(t), A = _.append("g").attr("class", "main"), m = A.append("rect").attr("width", c.width).attr("height", c.height).attr("class", "background");
1247
- $t(_, c.height, c.width, !0), _.attr("viewBox", `0 0 ${c.width} ${c.height}`), m.attr("fill", o.backgroundColor), n.setTmpSVGG(_.append("g").attr("class", "mermaid-tmp-group"));
1248
- const T = n.getDrawableElem(), S = {};
1249
- function P(p) {
1250
- let C = A, h = "";
1251
- for (const [L] of p.entries()) {
1252
- let z = A;
1253
- L > 0 && S[h] && (z = S[h]), h += p[L], C = S[h], C || (C = S[h] = z.append("g").attr("class", p[L]));
1274
+ const C = mi(t), b = C.append("g").attr("class", "main"), E = b.append("rect").attr("width", g.width).attr("height", g.height).attr("class", "background");
1275
+ yi(C, g.height, g.width, !0), C.attr("viewBox", `0 0 ${g.width} ${g.height}`), E.attr("fill", o.backgroundColor), n.setTmpSVGG(C.append("g").attr("class", "mermaid-tmp-group"));
1276
+ const D = n.getDrawableElem(), P = {};
1277
+ function I(y) {
1278
+ let _ = b, c = "";
1279
+ for (const [W] of y.entries()) {
1280
+ let z = b;
1281
+ W > 0 && P[c] && (z = P[c]), c += y[W], _ = P[c], _ || (_ = P[c] = z.append("g").attr("class", y[W]));
1254
1282
  }
1255
- return C;
1283
+ return _;
1256
1284
  }
1257
- for (const p of T) {
1258
- if (p.data.length === 0)
1285
+ a(I, "getGroup");
1286
+ for (const y of D) {
1287
+ if (y.data.length === 0)
1259
1288
  continue;
1260
- const C = P(p.groupTexts);
1261
- switch (p.type) {
1289
+ const _ = I(y.groupTexts);
1290
+ switch (y.type) {
1262
1291
  case "rect":
1263
- C.selectAll("rect").data(p.data).enter().append("rect").attr("x", (h) => h.x).attr("y", (h) => h.y).attr("width", (h) => h.width).attr("height", (h) => h.height).attr("fill", (h) => h.fill).attr("stroke", (h) => h.strokeFill).attr("stroke-width", (h) => h.strokeWidth);
1292
+ if (_.selectAll("rect").data(y.data).enter().append("rect").attr("x", (c) => c.x).attr("y", (c) => c.y).attr("width", (c) => c.width).attr("height", (c) => c.height).attr("fill", (c) => c.fill).attr("stroke", (c) => c.strokeFill).attr("stroke-width", (c) => c.strokeWidth), g.showDataLabel)
1293
+ if (g.chartOrientation === "horizontal") {
1294
+ let c = function(l, L) {
1295
+ const { data: S, label: R } = l;
1296
+ return L * R.length * W <= S.width - 10;
1297
+ };
1298
+ a(c, "fitsHorizontally");
1299
+ const W = 0.7, z = y.data.map((l, L) => ({ data: l, label: m[L].toString() })).filter((l) => l.data.width > 0 && l.data.height > 0), U = z.map((l) => {
1300
+ const { data: L } = l;
1301
+ let S = L.height * 0.7;
1302
+ for (; !c(l, S) && S > 0; )
1303
+ S -= 1;
1304
+ return S;
1305
+ }), X = Math.floor(Math.min(...U));
1306
+ _.selectAll("text").data(z).enter().append("text").attr("x", (l) => l.data.x + l.data.width - 10).attr("y", (l) => l.data.y + l.data.height / 2).attr("text-anchor", "end").attr("dominant-baseline", "middle").attr("fill", "black").attr("font-size", `${X}px`).text((l) => l.label);
1307
+ } else {
1308
+ let c = function(l, L, S) {
1309
+ const { data: R, label: $ } = l, N = L * $.length * 0.7, F = R.x + R.width / 2, h = F - N / 2, u = F + N / 2, x = h >= R.x && u <= R.x + R.width, d = R.y + S + L <= R.y + R.height;
1310
+ return x && d;
1311
+ };
1312
+ a(c, "fitsInBar");
1313
+ const W = 10, z = y.data.map((l, L) => ({ data: l, label: m[L].toString() })).filter((l) => l.data.width > 0 && l.data.height > 0), U = z.map((l) => {
1314
+ const { data: L, label: S } = l;
1315
+ let R = L.width / (S.length * 0.7);
1316
+ for (; !c(l, R, W) && R > 0; )
1317
+ R -= 1;
1318
+ return R;
1319
+ }), X = Math.floor(Math.min(...U));
1320
+ _.selectAll("text").data(z).enter().append("text").attr("x", (l) => l.data.x + l.data.width / 2).attr("y", (l) => l.data.y + W).attr("text-anchor", "middle").attr("dominant-baseline", "hanging").attr("fill", "black").attr("font-size", `${X}px`).text((l) => l.label);
1321
+ }
1264
1322
  break;
1265
1323
  case "text":
1266
- C.selectAll("text").data(p.data).enter().append("text").attr("x", 0).attr("y", 0).attr("fill", (h) => h.fill).attr("font-size", (h) => h.fontSize).attr("dominant-baseline", (h) => f(h.verticalPos)).attr("text-anchor", (h) => d(h.horizontalPos)).attr("transform", (h) => R(h)).text((h) => h.text);
1324
+ _.selectAll("text").data(y.data).enter().append("text").attr("x", 0).attr("y", 0).attr("fill", (c) => c.fill).attr("font-size", (c) => c.fontSize).attr("dominant-baseline", (c) => p(c.verticalPos)).attr("text-anchor", (c) => k(c.horizontalPos)).attr("transform", (c) => v(c)).text((c) => c.text);
1267
1325
  break;
1268
1326
  case "path":
1269
- C.selectAll("path").data(p.data).enter().append("path").attr("d", (h) => h.path).attr("fill", (h) => h.fill ? h.fill : "none").attr("stroke", (h) => h.strokeFill).attr("stroke-width", (h) => h.strokeWidth);
1327
+ _.selectAll("path").data(y.data).enter().append("path").attr("d", (c) => c.path).attr("fill", (c) => c.fill ? c.fill : "none").attr("stroke", (c) => c.strokeFill).attr("stroke-width", (c) => c.strokeWidth);
1270
1328
  break;
1271
1329
  }
1272
1330
  }
1273
- }, Ri = {
1274
- draw: ki
1275
- }, Mi = {
1276
- parser: ti,
1277
- db: _i,
1278
- renderer: Ri
1331
+ }, "draw"), Fi = {
1332
+ draw: zi
1333
+ }, Hi = {
1334
+ parser: Ti,
1335
+ db: Wi,
1336
+ renderer: Fi
1279
1337
  };
1280
1338
  export {
1281
- Mi as diagram
1339
+ Hi as diagram
1282
1340
  };