@silurus/ooxml 0.88.0 → 0.89.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.
Files changed (128) hide show
  1. package/README.md +118 -23
  2. package/THIRD_PARTY_NOTICES.md +7 -6
  3. package/dist/abort-VrnK7mdP.js +10 -0
  4. package/dist/assets/render-worker-CUOU6mL2.js +16 -0
  5. package/dist/assets/render-worker-DOqrFhSU.js +15 -0
  6. package/dist/assets/render-worker-DvWUdZUN.js +35 -0
  7. package/dist/bounded-raw-part-cache-B7JoC1CD.js +64586 -0
  8. package/dist/bundled-asset-url-E2nXURF9.js +15 -0
  9. package/dist/canvas-viewer-mechanics-DfQqRKkD.js +675 -0
  10. package/dist/cfb-guard-9QTRTg7f.js +528 -0
  11. package/dist/chart-ex.mjs +692 -688
  12. package/dist/comment-overlay-controller-B5_zGgG5.js +994 -0
  13. package/dist/comment-ui-runtime-B7ZvovcS.js +2 -0
  14. package/dist/{comment-ui-runtime-DcJOYlw-.js → comment-ui-runtime-D_sb2K6s.js} +5 -5
  15. package/dist/{comment-ui-runtime-CWGqn5Vr.js → comment-ui-runtime-Jy-3goA9.js} +5 -5
  16. package/dist/delimited-text-worker-host-CikWU6_m.js +27 -0
  17. package/dist/document-model-source-BKNrXjAL.js +249 -0
  18. package/dist/document-pull-client-CxONDGbk.js +37833 -0
  19. package/dist/document-pull-worker-AMyXYpPq.js +104 -0
  20. package/dist/docx-D91ER1_S.js +495 -0
  21. package/dist/docx-DhDnKEI6.js +3563 -0
  22. package/dist/docx-model-source-CdrSt3hF.js +98 -0
  23. package/dist/docx-source-worker.mjs +455 -0
  24. package/dist/docx.mjs +7 -7
  25. package/dist/docx_parser_bg.wasm +0 -0
  26. package/dist/drawingml-shape-ChcGZNd8.js +310 -0
  27. package/dist/duotone-ekYik4ix.js +126 -0
  28. package/dist/emf-UT6I8rVi.js +1790 -0
  29. package/dist/font-preload-demand-CdJZUMCT.js +2058 -0
  30. package/dist/grid-geometry-uQOgViJU.js +384 -0
  31. package/dist/host-layout-DVMw8hDY.js +56 -0
  32. package/dist/host-layout-measure-CCEgaC_v.js +7 -0
  33. package/dist/in-process-pull-transport-DuXcPZng.js +29 -0
  34. package/dist/index.mjs +4 -4
  35. package/dist/internal-companion.mjs +12 -0
  36. package/dist/line-distribute-CPOV6csk.js +2716 -0
  37. package/dist/math.mjs +2 -2
  38. package/dist/mathjax-stix2.js +10 -10
  39. package/dist/model-source-DJGzDtGb.js +61 -0
  40. package/dist/model-source-kz_NkZqT.js +179 -0
  41. package/dist/model-source-session-Bu9CHFHc.js +71 -0
  42. package/dist/model-source-session-CDuijwv1.js +85 -0
  43. package/dist/model-source-session-sKpNiIJI.js +58 -0
  44. package/dist/node.mjs +7 -1327
  45. package/dist/{pixel-budget-9P63Bsk5.js → pixel-budget-BpTYrepD.js} +13 -10
  46. package/dist/plot-area-frame-CaJFvZ7p.js +8502 -0
  47. package/dist/pptx-CDP9dZHe.js +2936 -0
  48. package/dist/pptx-C_uxLVKB.js +183 -0
  49. package/dist/pptx-model-source-O7LhpOjz.js +37 -0
  50. package/dist/pptx-source-worker.mjs +446 -0
  51. package/dist/pptx.mjs +8 -7
  52. package/dist/pptx_parser_bg.wasm +0 -0
  53. package/dist/presentation-model-source-tmROzteR.js +77 -0
  54. package/dist/raster-target-YQ4G6rxo.js +42 -0
  55. package/dist/region-map.mjs +114 -150
  56. package/dist/{render-D3iqVKCo.js → render-CJVglUHl.js} +3 -3
  57. package/dist/{render-worker-host-B5wQfB7U.js → render-worker-host-BseIaVvm.js} +1 -1
  58. package/dist/{render-worker-host-D4123J27.js → render-worker-host-CyxPU4JU.js} +1 -1
  59. package/dist/{render-worker-host-Di3LxLc0.js → render-worker-host-aF6aWkC0.js} +1 -1
  60. package/dist/renderer-CkGLj0CC.js +5170 -0
  61. package/dist/renderer-Czw1cCC7.js +5823 -0
  62. package/dist/resource-measurement-mXw-WjMF.js +771 -0
  63. package/dist/session-Csv9maad.js +656 -0
  64. package/dist/slide-pull-client-DRZYwBTu.js +6515 -0
  65. package/dist/three-d-BK5siJgJ.js +878 -0
  66. package/dist/three-d.mjs +960 -945
  67. package/dist/{raster-target-ojDdQizC.js → tiff-contract-C6M3QcPp.js} +1 -42
  68. package/dist/tiff.mjs +401 -248
  69. package/dist/types/chart-ex.d.ts +149 -2
  70. package/dist/types/docx.d.ts +333 -96
  71. package/dist/types/index.d.ts +566 -301
  72. package/dist/types/internal-companion.d.ts +11 -0
  73. package/dist/types/math.d.ts +1 -1
  74. package/dist/types/node.d.ts +422 -9
  75. package/dist/types/pptx.d.ts +302 -95
  76. package/dist/types/region-map.d.ts +149 -2
  77. package/dist/types/three-d.d.ts +149 -2
  78. package/dist/types/tiff.d.ts +1 -1
  79. package/dist/types/xlsx.d.ts +343 -132
  80. package/dist/wasm-loader-rlgHmcSv.js +35 -0
  81. package/dist/wasm-runtime-generation-DX4y0Ecl.js +97 -0
  82. package/dist/workbook-model-source-BTC4ISTS.js +94 -0
  83. package/dist/worker-source-I1cIYBel.js +22 -0
  84. package/dist/worker-source-SbudzjYL.js +22 -0
  85. package/dist/worker-source-UAi3GNcM.js +22 -0
  86. package/dist/worksheet-pull-client-CkHgbtyM.js +579 -0
  87. package/dist/xlsx-CpSDPAEU.js +5809 -0
  88. package/dist/xlsx-D5569TPf.js +534 -0
  89. package/dist/xlsx-model-source-DPSkjFic.js +309 -0
  90. package/dist/xlsx-source-worker.mjs +525 -0
  91. package/dist/xlsx.mjs +8 -7
  92. package/dist/xlsx_parser_bg.wasm +0 -0
  93. package/package.json +42 -16
  94. package/dist/assets/render-worker-1uPAxMZr.js +0 -31
  95. package/dist/assets/render-worker-BlvJybji.js +0 -10
  96. package/dist/assets/render-worker-CzmiJfFL.js +0 -11
  97. package/dist/bounded-raw-part-cache-Cg1BsSZQ.js +0 -119
  98. package/dist/canvas-viewer-mechanics-DbLz0rYW.js +0 -1384
  99. package/dist/cjk-fallback-bLI3z70h.js +0 -46
  100. package/dist/comment-occurrence-C8Y2uoVr.js +0 -6
  101. package/dist/comment-ui-runtime-BsK8pmUT.js +0 -2
  102. package/dist/comments-Diid5ujN.js +0 -246
  103. package/dist/delimited-text-worker-host-BVY-Ecni.js +0 -27
  104. package/dist/document-pull-client-B9PTM-pL.js +0 -27280
  105. package/dist/docx-BF9WXrYH.js +0 -3103
  106. package/dist/dom-interaction-boundary-Cnm8DSBN.js +0 -223
  107. package/dist/highlight-rect-C5hkRqUr.js +0 -13
  108. package/dist/hyperlink-Cxzhet30.js +0 -36446
  109. package/dist/line-distribute-D1WNHKz_.js +0 -1023
  110. package/dist/line-metrics-B60C86uh.js +0 -60
  111. package/dist/plot-area-frame-DLTYKHNP.js +0 -4354
  112. package/dist/pptx-DkyYBYoL.js +0 -3065
  113. package/dist/renderer-B4GZb5We.js +0 -6492
  114. package/dist/resource-measurement-SHQCbkh2.js +0 -150
  115. package/dist/session-BGq81gRQ.js +0 -743
  116. package/dist/slide-pull-client-DiPnm240.js +0 -6253
  117. package/dist/source-key-DIJG8BA0.js +0 -42
  118. package/dist/three-d-DJBl8g8M.js +0 -1162
  119. package/dist/transfer-p6iCC2R7.js +0 -6
  120. package/dist/units-BzZ0gAxs.js +0 -4
  121. package/dist/worksheet-pull-client-BM8ywvbu.js +0 -458
  122. package/dist/xlsx-C9NVjgaV.js +0 -8484
  123. /package/dist/{chunk-DmhlhrBa.js → chunk-Dy4uBu1J.js} +0 -0
  124. /package/dist/{mathjax-DoyWZbSp.js → mathjax-BhwN6ilc.js} +0 -0
  125. /package/dist/{read-only-comment-decoration-Dz7eTQ4d.js → read-only-comment-decoration-PidH0wnP.js} +0 -0
  126. /package/dist/{read-only-comment-margin-DkgzASAl.js → read-only-comment-margin-B52rDVKo.js} +0 -0
  127. /package/dist/{renderer-module-contract-D91rkYHH.js → renderer-module-contract-CWM7jv6d.js} +0 -0
  128. /package/dist/{visible-index-BgiHEc1z.js → visible-index-FeVA0mGE.js} +0 -0
package/dist/chart-ex.mjs CHANGED
@@ -1,502 +1,476 @@
1
- import { $ as e, $n as t, An as n, D as r, F as i, Gn as a, H as o, I as s, In as c, L as l, N as u, On as d, P as f, Pn as p, Q as m, R as h, Sn as g, T as _, X as v, Y as y, Yt as b, Z as x, Zn as S, dt as C, et as ee, ft as w, g as T, ir as E, jn as D, kn as O, pr as k, r as A, t as j, ut as M, v as N, zn as P } from "./plot-area-frame-DLTYKHNP.js";
2
- import { A as F, C as I, D as te, E as L, F as ne, I as R, L as re, M as ie, N as ae, O as oe, P as se, R as ce, S as le, T as ue, _ as de, a as z, b as fe, c as pe, d as me, f as he, g as ge, h as _e, i as ve, k as ye, l as B, m as V, n as H, o as U, p as be, r as xe, s as Se, t as Ce, u as we, v as Te, w as Ee, x as De, y as Oe, z as ke } from "./renderer-B4GZb5We.js";
3
- import { C as Ae, S as je } from "./three-d-DJBl8g8M.js";
4
- import { t as Me } from "./renderer-module-contract-D91rkYHH.js";
5
- function Ne(e) {
6
- return e != null && Number.isFinite(e) ? e : null;
7
- }
8
- function Pe(e) {
9
- return Object.is(e, -0) ? "0" : String(Number.isInteger(e) ? e : Number(e.toPrecision(6)));
10
- }
11
- function Fe(e, t) {
12
- if (e.length > 1048576) return { kind: "tooManyInputPoints" };
13
- let n = t.intervalClosed === "r" ? "r" : "l", r = Ne(t.underflow), i = Ne(t.overflow);
14
- r != null && i != null && r >= i && (r = null, i = null);
15
- let a = (e) => r != null && (n === "r" ? e <= r : e < r), o = (e) => i != null && (n === "r" ? e > i : e >= i), s = Infinity, c = -Infinity, l = 0, u = 0, d = 0;
16
- for (let t of e) {
17
- let e = Ne(t);
18
- e != null && (a(e) ? u++ : o(e) ? d++ : (l++, s = Math.min(s, e), c = Math.max(c, e)));
19
- }
20
- if (l + u + d === 0) return {
21
- kind: "bins",
22
- categories: [],
23
- counts: []
24
- };
25
- let f = [], p = [];
26
- if (r != null && (f.push(`${n === "r" ? "≤" : "<"} ${Pe(r)}`), p.push(u)), l > 0) {
27
- let u = r ?? s, d = i ?? c, m = d - u;
28
- if (!Number.isFinite(m)) f.push(`${Pe(u)} – ${Pe(d)}`), p.push(l);
29
- else {
30
- let s = Ne(t.binSize), c;
31
- c = s != null && s > 0 && m > 0 ? Math.max(1, Math.ceil(m / s)) : t.binCount != null && Number.isFinite(t.binCount) && t.binCount > 0 ? Math.max(1, Math.floor(t.binCount)) : Math.max(1, Math.ceil(Math.sqrt(l)));
32
- let d = m <= 0 ? 1 : Math.min(512, c), h = m > 0 && s != null && s > 0 && c <= 512, g = m === 0 ? 1 : h ? s : m / d, _ = Array(d).fill(0);
33
- for (let t of e) {
34
- let e = Ne(t);
35
- if (e == null || a(e) || o(e)) continue;
36
- let r = h ? (e - u) / g : m === 0 ? 0 : (e - u) / m * d, i = n === "r" ? Math.ceil(r) - 1 : Math.floor(r), s = Math.max(0, Math.min(d - 1, i));
37
- _[s]++;
38
- }
39
- for (let e = 0; e < d; e++) {
40
- let t = h ? u + g * e : u + e / d * m, a = h ? t + g : u + m * ((e + 1) / d), o = i == null ? a : Math.min(a, i), s = n === "r" && (r != null || e > 0) ? ">" : "≥", c = n === "l" && (i != null || e < d - 1) ? "<" : "≤";
41
- f.push(`${s} ${Pe(t)} – ${c} ${Pe(o)}`), p.push(_[e]);
42
- }
43
- }
44
- }
45
- return i != null && (f.push(`${n === "r" ? ">" : "≥"} ${Pe(i)}`), p.push(d)), {
46
- kind: "bins",
47
- categories: f,
48
- counts: p
49
- };
50
- }
51
- //#endregion
52
- //#region packages/core/src/chart/pareto-layout.ts
53
- function Ie(e, t) {
54
- return e == null ? e : e.flatMap((e) => {
55
- let n = t.get(e.idx);
56
- return n == null ? [] : [{
57
- ...e,
58
- idx: n
59
- }];
60
- });
61
- }
62
- function W(e, t) {
63
- return e == null ? e : t.map((t) => e[t] ?? null);
64
- }
65
- function G(e, t, n = {}) {
66
- let r = e.values.map((e, t) => ({
67
- value: e,
68
- sourceIndex: t
69
- })).filter((e) => e.value != null && Number.isFinite(e.value) && e.value >= 0);
70
- n.sortDescending !== !1 && r.sort((e, t) => t.value - e.value || e.sourceIndex - t.sourceIndex);
71
- let i = r[0]?.value ?? 0, a = i > 0 ? r.reduce((e, t) => e + t.value / i, 0) : 0, o = 0, s = r.map((n) => (i > 0 && (o += n.value / i), {
72
- sourceIndex: n.sourceIndex,
73
- category: e.categories?.[n.sourceIndex] ?? t[n.sourceIndex] ?? String(n.sourceIndex + 1),
74
- value: n.value,
75
- cumulativeFraction: a > 0 ? o >= a ? 1 : o / a : 0
76
- })), c = s.map((e) => e.sourceIndex), l = new Map(c.map((e, t) => [e, t])), u = s.map((e) => e.category), d = {
77
- ...e,
78
- categories: u,
79
- catFormatCodes: W(e.catFormatCodes, c),
80
- dataPointColors: W(e.dataPointColors, c),
81
- dataLabelColors: W(e.dataLabelColors, c),
82
- dataPointOverrides: Ie(e.dataPointOverrides, l),
83
- dataLabelOverrides: Ie(e.dataLabelOverrides, l)
84
- };
85
- return {
86
- points: s,
87
- categories: u,
88
- orderedSeries: {
89
- ...d,
90
- values: s.map((e) => e.value)
91
- },
92
- series: {
93
- ...d,
94
- values: s.map((e) => e.cumulativeFraction)
95
- }
96
- };
97
- }
98
- //#endregion
1
+ import { $ as e, $n as t, Aa as n, Ba as r, Fn as i, Gi as a, Ia as o, Ii as s, In as c, J as l, Ki as u, Ln as d, Ma as f, Mt as p, Nn as m, Pn as h, Qn as g, R as _, Rn as ee, Rt as v, S as y, Ui as b, Ut as x, Wi as S, Wt as C, Y as w, Yi as T, Yt as E, Zi as te, Zn as D, Zt as O, _n as k, aa as A, b as j, bt as M, ca as ne, ct as N, er as P, fn as F, ga as I, gn as L, hn as re, in as R, it as z, jt as ie, li as B, mn as ae, na as oe, nt as se, oa as ce, on as le, ot as ue, pn as de, qa as fe, rt as pe, s as me, st as he, t as ge, ta as V, tt as _e, x as H, xn as ve, yt as ye, zt as be } from "./plot-area-frame-CaJFvZ7p.js";
2
+ import { A as xe, C as Se, D as Ce, E as we, O as Te, S as Ee, T as De, _ as U, a as Oe, b as ke, c as Ae, d as je, f as Me, g as Ne, i as Pe, j as Fe, k as Ie, l as Le, m as Re, o as ze, p as Be, s as Ve, u as He, v as Ue, w as We, x as Ge, y as W } from "./renderer-Czw1cCC7.js";
3
+ import { t as G } from "./renderer-module-contract-CWM7jv6d.js";
99
4
  //#region packages/core/src/chart/chart-ex-renderer.ts
100
- function K(e) {
101
- return !e || e.fillNoStyle === !0 ? !1 : e.fillPaintAuthored === !0 || e.fillHidden === !0 || e.fillColors?.some((e) => e != null) === !0 || e.fillPaints?.some((e) => e != null) === !0;
102
- }
103
- function q(e, t, n, r) {
104
- return t?.fillHidden === !0 || t?.color != null || K(t?.chartexStyle) ? U(e, r, 3, t?.fillHidden === !0 ? {
105
- ...t.chartexStyle,
106
- fillHidden: !0,
107
- fillPaintAuthored: !0
108
- } : t?.chartexStyle, t?.color) : n?.chartexStyle?.fillPaintAuthored === !0 ? U(e, r, 3, n.chartexStyle, n.color) : U(e, r, 3, n?.chartexStyle, n?.color);
109
- }
110
- function Le(e) {
111
- let t = e?.chartexStyle;
112
- return e?.lineHidden != null || e?.lineColor != null || e?.lineWidthEmu != null || e?.lineDash != null || t?.linePaintAuthored === !0 || t?.lineHidden != null || t?.lineColors?.some((e) => e != null) === !0 || t?.linePaints?.some((e) => e != null) === !0 || t?.lineWidthEmu != null || t?.lineDash != null || t?.lineCustomDash != null || t?.lineCap != null || t?.lineJoin != null;
113
- }
114
- function Re(e, n, a, o = 1) {
115
- let s = 0, c = Math.max(1, a?.w ?? 32 * o), u = Math.max(1, a?.h ?? 16 * o), d = i(e, ({ label: i, linkedStyleIndex: a }) => {
116
- let d = i.labelBox, f = l(d), p = f ? e.chartStyleRoles?.dataLabelCallout ?? e.chartStyleRoles?.dataLabel : e.chartStyleRoles?.dataLabel, m = f ? k(e, "dataLabelCallout") ?? k(e, "dataLabel") : k(e, "dataLabel"), g = h(d, p, m, p != null, 0, a)?.fillPaint, _ = S(d?.style, m, 0), v = d?.borderHidden === !0 ? t(m) : void 0, y = d?.borderColor != null || d?.borderFill != null || _ !== void 0 || v !== void 0 || d?.borderPaintAuthored === !0 && d?.borderHidden !== !0, x = _ === void 0 ? v === void 0 ? d?.borderFill ?? (d?.borderColor ? {
5
+ function Ke(e, t, r, i = 1) {
6
+ let a = 0, s = Math.max(1, r?.w ?? 32 * i), c = Math.max(1, r?.h ?? 16 * i), l = ae(e, ({ label: r, linkedStyleIndex: l }) => {
7
+ let u = r.labelBox, d = L(u), p = d ? e.chartStyleRoles?.dataLabelCallout ?? e.chartStyleRoles?.dataLabel : e.chartStyleRoles?.dataLabel, m = d ? fe(e, "dataLabelCallout") ?? fe(e, "dataLabel") : fe(e, "dataLabel"), h = k(u, p, m, p != null, 0, l)?.fillPaint, g = n(u?.style, m, 0), _ = u?.borderHidden === !0 ? f(m) : void 0, ee = u?.borderColor != null || u?.borderFill != null || g !== void 0 || _ !== void 0 || u?.borderPaintAuthored === !0 && u?.borderHidden !== !0, v = g === void 0 ? _ === void 0 ? u?.borderFill ?? (u?.borderColor ? {
117
8
  fillType: "solid",
118
- color: d.borderColor
119
- } : y ? null : E(p, a)) : v : _;
120
- for (let e of [g, x]) {
9
+ color: u.borderColor
10
+ } : ee ? null : o(p, l)) : _ : g;
11
+ for (let e of [h, v]) {
121
12
  if (!e) continue;
122
- let t = e.fillType === "image" ? A(e, n, c, u, o) ?? 1048577 : b(e);
123
- if (e.fillType === "gradient" && t > 4096 || t > 1048576 - s) {
124
- s = r + 1;
13
+ let n = e.fillType === "image" ? me(e, t, s, c, i) ?? 1048577 : B(e);
14
+ if (e.fillType === "gradient" && n > 4096 || n > 1048576 - a) {
15
+ a = le + 1;
125
16
  return;
126
17
  }
127
- s += t;
18
+ a += n;
128
19
  }
129
20
  });
130
- return d === "not-hierarchy" ? null : d === "too-large" ? r + 1 : s;
21
+ return l === "not-hierarchy" ? null : l === "too-large" ? le + 1 : a;
131
22
  }
132
- function ze(e, t, n = 1) {
23
+ function K(e, t, n, r) {
24
+ if (!e.chartexParetoOutlineOwner) return t;
25
+ let i = t.chartexFormatIdx ?? n, a = t.lineColor ?? U(e, i, r, t.chartexStyle);
26
+ return {
27
+ ...t,
28
+ chartexStyle: {
29
+ ...t.chartexStyle,
30
+ fillHidden: !0,
31
+ fillPaintAuthored: !0
32
+ },
33
+ lineColor: a,
34
+ lineHidden: !1
35
+ };
36
+ }
37
+ function qe(e, t, n = 1) {
38
+ if (e.chartexSuppressGeometry) return 0;
133
39
  if (![
134
40
  "waterfall",
135
41
  "funnel",
136
42
  "boxWhisker",
137
43
  "sunburst",
138
- "treemap"
44
+ "treemap",
45
+ "clusteredColumn",
46
+ "histogram",
47
+ "pareto",
48
+ "paretoLine"
139
49
  ].includes(e.chartType)) return null;
140
- let i = 0, a = (e) => {
141
- if (!e || i > 1048576) return;
142
- let a = e.fillType === "image" ? A(e, void 0, Math.max(1, t.w), Math.max(1, t.h), n) : b(e);
143
- e.fillType === "gradient" && a > 4096 || a > 1048576 - i ? i = r + 1 : i += a;
144
- }, o = (t, n, r, i) => {
145
- let o = ae(e, t, n, r, i, "#000000", { linkedNoStyleFallback: !0 });
146
- o.visible && a(o.paint ?? {
50
+ let r = 0, i = (e) => {
51
+ if (!e || r > 1048576) return;
52
+ let i = e.fillType === "image" ? me(e, void 0, Math.max(1, t.w), Math.max(1, t.h), n) : B(e);
53
+ e.fillType === "gradient" && i > 4096 || i > 1048576 - r ? r = le + 1 : r += i;
54
+ }, a = (t, n, r, a) => {
55
+ let o = Fe(e, t, n, r, a, "#000000", { linkedNoStyleFallback: !0 });
56
+ o.visible && i(o.paint ?? {
147
57
  fillType: "solid",
148
58
  color: "000000"
149
59
  });
150
- };
151
- if (e.chartType === "waterfall") {
152
- let t = e.series[0], n = t?.values ?? [], r = I(t?.dataPointOverrides), i = u(n, e.categories.length, e.subtotalIndices);
153
- if (i.cumulativeOverflow || i.rawMax <= i.rawMin) return 0;
154
- for (let n = 0; n < i.bars.length; n++) {
155
- let s = i.bars[n];
156
- if (!s.paintSlot) continue;
157
- let c = s.semanticIndex, l = r.get(n);
158
- a(q(e, l, t, c)), o(e.chartexDataPointStyle, Le(l) ? l : t, c, 3);
60
+ }, o = (t, n, a, o) => {
61
+ i(Ie(e, t, n, a, o));
62
+ let s = xe(e, t, n, a, o, "#000000");
63
+ if (s.visible && !Ge(s) && i(s.paint ?? {
64
+ fillType: "solid",
65
+ color: "000000"
66
+ }), r > 1048576) return !1;
67
+ }, s = (t, n) => {
68
+ let r = [e.chartexDataPointStyle, e.chartexDataPointLineStyle];
69
+ Te(e, Se(t, n), r, r, n, 1, "#000000", { linkedNoStyleFallback: !0 }).visible && i({
70
+ fillType: "solid",
71
+ color: "000000"
72
+ });
73
+ }, c = j(e, (t, n, r) => n === 0 ? K(e, t, n, r) : t);
74
+ if (c) {
75
+ if (c.kind === "tooManyInputPoints") return le + 1;
76
+ if (y(c, o), r > 1048576 || (H(c, o), r > 1048576)) return r;
77
+ if (e.chartType === "pareto" && c.series.length > 0) {
78
+ let t = e.chartexParetoOwnerIndex ?? 0, n = c.series[t], r = e.series.find((e) => e.seriesType === "line");
79
+ s(r ?? n, r?.chartexFormatIdx ?? n?.chartexFormatIdx ?? 0);
80
+ }
81
+ } else if (e.chartType === "paretoLine") {
82
+ let t = e.series[0];
83
+ t && x(t, e.categories, { sortDescending: e.chartexParetoSortDescending ?? !1 }).points.length > 0 && s(t, v(t, 0));
84
+ } else if (e.chartType === "waterfall") {
85
+ let t = e.series[0], n = t?.values ?? [], r = be(t?.dataPointOverrides), a = F(n, e.categories.length, e.subtotalIndices);
86
+ if (a.cumulativeOverflow || a.rawMax <= a.rawMin) return 0;
87
+ for (let n = 0; n < a.bars.length; n++) {
88
+ let o = a.bars[n];
89
+ if (!o.paintSlot) continue;
90
+ let s = o.semanticIndex, c = r.get(n);
91
+ i(Ie(e, t, c, s, 3));
92
+ let l = xe(e, t, c, s, 3, "#000000");
93
+ l.visible && !Ge(l) && i(l.paint ?? {
94
+ fillType: "solid",
95
+ color: "000000"
96
+ });
159
97
  }
160
98
  } else if (e.chartType === "funnel") {
161
99
  let t = e.series[0], n = t?.values ?? [], r = Math.max(n.length, e.categories.length);
162
100
  if (n.some((e) => e != null && e > 0)) {
163
- let i = U(e, 0, 1, t?.chartexStyle, t?.color);
164
- for (let s = 0; s < r; s++) (n[s] ?? 0) > 0 && (a(i), o(e.chartexDataPointStyle, t, 0, 1));
101
+ let a = be(t?.dataPointOverrides);
102
+ for (let o = 0; o < r; o++) {
103
+ if (!((n[o] ?? 0) > 0)) continue;
104
+ let r = a.get(o);
105
+ i(Ie(e, t, r, 0, 1));
106
+ let s = xe(e, t, r, 0, 1, "#000000");
107
+ s.visible && i(s.paint ?? {
108
+ fillType: "solid",
109
+ color: "000000"
110
+ });
111
+ }
165
112
  }
166
113
  } else if (e.chartType === "boxWhisker") {
167
114
  let t = e.chartexBox, n = t?.series.length ?? 0;
168
115
  for (let r = 0; r < n; r++) {
169
- let i = t.series[r], s = i.chartexFormatIdx ?? r, c = U(e, s, n, i.chartexStyle, i.color);
170
- for (let t of i.valuesByCategory) w(t, i.quartileMethod) && (a(c), o(e.chartexDataPointStyle, i, s, n));
116
+ let o = t.series[r], s = o.chartexFormatIdx ?? r, c = Ue(e, s, n, o.chartexStyle, o.color);
117
+ for (let t of o.valuesByCategory) P(t, o.quartileMethod) && (i(c), a(e.chartexDataPointStyle, Se(o, s), s, n));
171
118
  }
172
119
  } else {
173
120
  let t = e.series[0], n = 1;
174
- if (f(e, ({ node: e }) => {
121
+ de(e, ({ node: e }) => {
175
122
  n = Math.max(n, e.branchIndex + 1);
176
- }), f(e, ({ node: r, paintsBody: i }) => {
177
- i && (a(U(e, r.branchIndex, n, t?.chartexStyle, t?.color)), o(e.chartexDataPointStyle, t, r.branchIndex, n));
178
- }) === "too-large") return r + 1;
123
+ });
124
+ let r = be(t?.dataPointOverrides);
125
+ if (de(e, ({ node: a, paintsBody: o }) => {
126
+ if (!o) return;
127
+ let s = r.get(a.labelIndex);
128
+ i(Ie(e, t, s, a.branchIndex, n));
129
+ let c = xe(e, t, s, a.branchIndex, n, "#000000", e.chartexDataPointStyle, { linkedNoStyleFallback: e.chartType === "treemap" });
130
+ c.visible && i(c.paint ?? {
131
+ fillType: "solid",
132
+ color: "000000"
133
+ });
134
+ }) === "too-large") return le + 1;
179
135
  }
180
- return i;
136
+ return r;
181
137
  }
182
- function Be(e, t, n, r, i = 0) {
183
- let a = t.series[0];
184
- if (!a) return;
185
- let o = Fe(a.values, t.chartexHistogramBinning ?? {});
186
- if (o.kind === "tooManyInputPoints") {
187
- ye(e, n, _ + 1);
138
+ function Je(e, t, n, i, a = 0) {
139
+ let o = t.series[0];
140
+ if (!o) return;
141
+ let s = C(o.values, t.chartexHistogramBinning ?? {}, o.valFormatCode, t.date1904 === !0);
142
+ if (s.kind === "tooManyInputPoints") {
143
+ Le(e, n, R + 1);
188
144
  return;
189
145
  }
190
- F(e, {
191
- ...t,
146
+ ze(e, r(t, {
192
147
  chartType: "clusteredBar",
193
- categories: o.categories,
148
+ categories: s.categories,
194
149
  series: [{
195
- ...a,
150
+ ...o,
196
151
  categories: void 0,
197
- values: o.counts
152
+ values: s.counts,
153
+ valFormatCode: null
198
154
  }]
199
- }, n, r, { gapPolicy: "chartex" }, i);
155
+ }), n, i, { gapPolicy: "chartex" }, a);
200
156
  }
201
- function Ve(t, r, i, l, d) {
202
- let { x: f, y: m, w: h, h: g } = i, _ = r.series[0]?.values ?? [], v = r.categories, y = Math.max(_.length, v.length);
203
- if (y === 0 || ye(t, i, y)) return;
204
- let { bars: b, rawMax: x, rawMin: S, cumulativeOverflow: C } = u(_, v.length, r.subtotalIndices);
205
- if (C) {
206
- t.fillStyle = "#888", t.font = "12px sans-serif", t.textAlign = "center", t.textBaseline = "middle", t.fillText("(chart values out of range)", f + h / 2, m + g / 2);
157
+ function Ye(t, n, i, o, s) {
158
+ let { x: c, y: f, w: p, h: m } = i, h = n.series[0]?.values ?? [], g = n.categories, v = Math.max(h.length, g.length);
159
+ if (v === 0 || Le(t, i, v)) return;
160
+ let { bars: y, rawMax: b, rawMin: x, cumulativeOverflow: S } = F(h, g.length, n.subtotalIndices);
161
+ if (S) {
162
+ t.fillStyle = "#888", t.font = "12px sans-serif", t.textAlign = "center", t.textBaseline = "middle", t.fillText("(chart values out of range)", c + p / 2, f + m / 2);
207
163
  return;
208
164
  }
209
- if (x <= S) return;
210
- let w = r.subtotalIndices.length === 0 && b.every((e, t) => !e.hasValue || _[t] >= 0), T = !r.valAxisHidden && r.valAxisTickLabelPos !== "none" && !w, E = Ee(t, r, h, g, l), O = n(r, h, g, l), k = xe(r.valAxisFontSizeHpt, g, l), A = xe(r.catAxisFontSizeHpt, g, l), M = V(r, r.valAxisFontFace, "minor"), P = V(r, r.catAxisFontFace, "minor"), F = oe(r, S, x, g / l);
165
+ if (b <= x) return;
166
+ let C = n.subtotalIndices.length === 0 && y.every((e, t) => !e.hasValue || h[t] >= 0), E = !n.valAxisHidden && n.valAxisTickLabelPos !== "none" && !C, D = Ae(t, n, p, m, o), k = a(n, p, m, o), j = _(n.valAxisFontSizeHpt, m, o), P = _(n.catAxisFontSizeHpt, m, o), L = M(n, n.valAxisFontFace, "minor"), R = M(n, n.catAxisFontFace, "minor"), ie = se(n, x, b, m / o);
211
167
  t.save();
212
- let L = 0;
213
- if (T) {
214
- t.font = be(k, M, r.valAxisFontBold ?? !1, r.valAxisFontItalic ?? !1);
168
+ let B = 0;
169
+ if (E) {
170
+ t.font = ye(j, L, n.valAxisFontBold ?? !1, n.valAxisFontItalic ?? !1);
215
171
  let e = 0;
216
- for (let n of F.majorLines) e = Math.max(e, t.measureText(le(r, n, !1)).width);
217
- L = e + 8;
172
+ for (let r of ie.majorLines) e = Math.max(e, ne(t, _e(n, r, !1)));
173
+ B = e + 8;
218
174
  }
219
- let ie = Math.max(1, h - O.valBandW - L - h * .02) / y;
220
- t.font = be(A, P, r.catAxisFontBold ?? !1, r.catAxisFontItalic ?? !1);
221
- let fe = v.slice(0, y).map((e) => ke(t, o(e, r.catAxisFormatCode, r.date1904), Math.max(1, ie - 8))), he = 0;
222
- for (let e of fe) e.some(Boolean) && (he = Math.max(he, e.length));
223
- let ve = r.catAxisHidden || he === 0 ? 0 : he * (A + 2) + 4, B = r.series[0], Se = I(B?.dataLabelOverrides), we = I(B?.dataPointOverrides), Ae = B?.chartexStyle, je = `#${B?.color ?? z(r, 0, 3, Ae)}`, Me = `#${z(r, 1, 3, Ae)}`, Ne = `#${z(r, 2, 3, Ae)}`, Pe = U(r, 0, 3, Ae, B?.color), Fe = U(r, 1, 3, Ae), Ie = U(r, 2, 3, Ae), W = {
224
- ...r,
175
+ let ae = E ? oe(ie.majorLines.map((e) => _e(n, e, !1)), A(j)) / 2 : 0, le = Math.max(1, p - k.valBandW - B - p * .02) / v;
176
+ t.font = ye(P, R, n.catAxisFontBold ?? !1, n.catAxisFontItalic ?? !1);
177
+ let de = g.slice(0, v).map((e) => N(t, ve(e, n.catAxisFormatCode, n.date1904), Math.max(1, le - 8))), fe = 0;
178
+ for (let e of de) e.some(Boolean) && (fe = Math.max(fe, e.length));
179
+ let me = n.catAxisHidden || fe === 0 ? 0 : fe * (P + 2) + 4, V = n.series[0], H = be(V?.dataLabelOverrides), Ce = be(V?.dataPointOverrides), Ee = V?.chartexStyle, De = `#${V?.color ?? U(n, 0, 3, Ee)}`, Oe = `#${U(n, 1, 3, Ee)}`, Pe = `#${U(n, 2, 3, Ee)}`, Fe = Ue(n, 0, 3, Ee, V?.color), Re = Ue(n, 1, 3, Ee), ze = Ue(n, 2, 3, Ee), W = r(n, {
225
180
  chartType: "clusteredBar",
226
181
  series: [
227
- pe(r, "Increase", B, r.chartexDataPointStyle, 0, 3, je),
228
- pe(r, "Decrease", B, r.chartexDataPointStyle, 1, 3, Me),
229
- pe(r, "Total", B, r.chartexDataPointStyle, 2, 3, Ne)
182
+ ke(n, "Increase", V, n.chartexDataPointStyle, 0, 3, De, !1, !0, !0),
183
+ ke(n, "Decrease", V, n.chartexDataPointStyle, 1, 3, Oe, !1, !0, !0),
184
+ ke(n, "Total", V, n.chartexDataPointStyle, 2, 3, Pe, !1, !0, !0)
230
185
  ]
231
- }, G = ue(t, W, h, g, .22, l), { legRightW: K, legLeftW: Re, legTopH: ze, legBottomH: Be } = D(G, r.legendOverlay === !0), Ve = c(r, f, m, h, g, l, {
232
- titleBand: E,
233
- legendSideReserveFrac: 0,
186
+ }), G = Be(t, W, p, m, o), { legRightW: Ke, legLeftW: K, legTopH: qe, legBottomH: Je } = u(G, n.legendOverlay === !0), Ye = te(n, c, f, p, m, o, {
187
+ titleBand: D,
234
188
  legendReserve: G,
235
189
  pad: {
236
- t: E.bandH + ze + k / 2 + 2,
237
- r: K + h * .02,
238
- b: Be + O.catBandH + ve,
239
- l: Re + O.valBandW + (r.valAxisHidden ? h * .02 : Math.max(h * .03, L))
190
+ t: D.bandH + qe + j / 2 + 2 + ae,
191
+ r: Ke + p * .02,
192
+ b: Je + k.catBandH + me,
193
+ l: K + k.valBandW + (n.valAxisHidden ? p * .02 : Math.max(p * .03, B))
240
194
  },
241
195
  honorPlotAreaManualLayout: !0
242
196
  });
243
- Te(t, r, f, m, h, g, m + Ve.title.topPad, Ve.title.fontPx);
244
- let { px0: J, py0: Y, pw: X, ph: Z } = Ve.plotRect;
245
- j(t, r, J, Y, X, Z, l, d);
246
- let He = oe(r, S, x, Z / l), Q = (e) => Y + Z - He.frac(e) * Z, Ue = N(r.valAxisLineColor, r.valAxisLineWidthEmu, l), We = N(r.catAxisLineColor, r.catAxisLineWidthEmu, l), Ge = re(r, l);
247
- if (!r.valAxisHidden) {
248
- t.font = be(k, M, r.valAxisFontBold ?? !1, r.valAxisFontItalic ?? !1), t.fillStyle = r.valAxisFontColor ? `#${r.valAxisFontColor}` : "#595959", t.textAlign = "right", t.textBaseline = "middle";
249
- let e = ce(r, l);
250
- for (let n of He.minorLines) R(t, J, X, Q(n), !1, e);
251
- for (let e of He.majorLines) {
252
- let n = Q(e);
253
- if (De(r)) {
254
- t.strokeStyle = Ge.color, t.lineWidth = Ge.width;
255
- let e = Ge.dash.length > 0 && t.getLineDash ? t.getLineDash() : [];
256
- Ge.dash.length > 0 && t.setLineDash(Ge.dash), t.beginPath(), t.moveTo(J, n), t.lineTo(J + X, n), t.stroke(), Ge.dash.length > 0 && t.setLineDash(e);
197
+ Ve(t, n, c, f, p, m, f + Ye.title.topPad, Ye.title.fontPx);
198
+ let { px0: q, py0: J, pw: Y, ph: X } = Ye.plotRect;
199
+ if (Y <= 0 || X <= 0) return;
200
+ ge(t, n, q, J, Y, X, o, s);
201
+ let Xe = se(n, x, b, X / o), Z = (e) => J + X - Xe.frac(e) * X, Q = O(n.valAxisLineColor, n.valAxisLineWidthEmu, o), Ze = O(n.catAxisLineColor, n.catAxisLineWidthEmu, o), Qe = ue(n, o);
202
+ if (!n.valAxisHidden) {
203
+ t.font = ye(j, L, n.valAxisFontBold ?? !1, n.valAxisFontItalic ?? !1), t.fillStyle = n.valAxisFontColor ? `#${n.valAxisFontColor}` : "#595959", t.textAlign = "right", t.textBaseline = "middle";
204
+ let r = he(n, o);
205
+ for (let e of Xe.minorLines) z(t, q, Y, Z(e), !1, r);
206
+ for (let r of Xe.majorLines) {
207
+ let i = Z(r);
208
+ if (e(n)) {
209
+ t.strokeStyle = Qe.color, t.lineWidth = Qe.width;
210
+ let e = Qe.dash.length > 0 && t.getLineDash ? t.getLineDash() : [];
211
+ Qe.dash.length > 0 && t.setLineDash(Qe.dash), t.beginPath(), t.moveTo(q, i), t.lineTo(q + Y, i), t.stroke(), Qe.dash.length > 0 && t.setLineDash(e);
257
212
  }
258
- T && t.fillText(le(r, e, !1), J - 4, n), _e(t, r.valAxisMajorTickMark, "val", J, n, Ue.color, Ue.width, !1, r.valAxisLineHidden, "major", l, r.valAxisLineDash);
213
+ E && ce(t, _e(n, r, !1), q - 4, i, A(j)), l(t, n.valAxisMajorTickMark, "val", q, i, Q.color, Q.width, !1, n.valAxisLineHidden, "major", o, n.valAxisLineDash);
259
214
  }
260
- for (let e of He.minorTicks) _e(t, r.valAxisMinorTickMark, "val", J, Q(e), Ue.color, Ue.width, !1, r.valAxisLineHidden, "minor", l, r.valAxisLineDash);
215
+ for (let e of Xe.minorTicks) l(t, n.valAxisMinorTickMark, "val", q, Z(e), Q.color, Q.width, !1, n.valAxisLineHidden, "minor", o, n.valAxisLineDash);
261
216
  }
262
- let Ke = !r.valAxisHidden && !r.valAxisLineHidden, qe = !r.catAxisHidden && !r.catAxisLineHidden;
263
- Ke && ne(t, J, Y, J, Y + Z, Ue.color, Ue.width, r.valAxisLineDash), qe && ne(t, J, Y + Z, J + X, Y + Z, We.color, We.width, r.catAxisLineDash);
264
- let Je = X / y, $ = Je / (1 + a(r.barGapWidth, "chartex") / 100);
265
- b.forEach((n, i) => {
266
- let a = J + Je * i + (Je - $) / 2, o = Math.min(Q(n.start), Q(n.end)), c = Math.max(Q(n.start), Q(n.end)), u = Math.max(1, c - o), x = n.semanticIndex, S = we.get(i), C = q(r, S, B, x), w = S?.color ? `#${S.color}` : n.isSub ? Ne : n.isPos ? je : Me, T = me(r, r.chartexDataPointStyle, "line", x, 3), E = Le(S) ? S : B;
267
- if (n.paintSlot && ee(t, e(S?.chartexStyle, B?.chartexStyle), r.chartexDataPointStyle, x, {
268
- x: a,
269
- y: o,
217
+ let $e = !n.valAxisHidden && !n.valAxisLineHidden, et = !n.catAxisHidden && !n.catAxisLineHidden;
218
+ $e && pe(t, q, J, q, J + X, Q.color, Q.width, n.valAxisLineDash), et && pe(t, q, J + X, q + Y, J + X, Ze.color, Ze.width, n.catAxisLineDash);
219
+ let tt = Y / v, $ = tt / (1 + I(n.barGapWidth, "chartex") / 100);
220
+ y.forEach((e, r) => {
221
+ let i = q + tt * r + (tt - $) / 2, a = Math.min(Z(e.start), Z(e.end)), l = Math.max(Z(e.start), Z(e.end)), u = Math.max(1, l - a), b = e.semanticIndex, x = Ce.get(r), S = Ie(n, V, x, b, 3), C = x?.color ? `#${x.color}` : e.isSub ? Pe : e.isPos ? De : Oe, w = We(n, n.chartexDataPointStyle, "line", b, 3), E = xe(n, V, x, b, 3, w ? `#${w}` : C);
222
+ if (e.paintSlot && ee(t, d(x?.chartexStyle, V?.chartexStyle), n.chartexDataPointStyle, b, {
223
+ x: i,
224
+ y: a,
270
225
  w: $,
271
226
  h: u
272
- }, l, (e) => {
273
- C && te(e, C, {
274
- x: a,
275
- y: o,
227
+ }, o, (e) => {
228
+ S && we(e, S, {
229
+ x: i,
230
+ y: a,
231
+ w: $,
232
+ h: u
233
+ }, C, o, s), !Ge(E) && Ne(e, E, o, {
234
+ x: i,
235
+ y: a,
276
236
  w: $,
277
237
  h: u
278
- }, w, l, d), Ce(e, r, r.chartexDataPointStyle, E, x, 3, T ? `#${T}` : w, l) && e.strokeRect(a, o, $, u);
279
- }), n.paintSlot && b[i + 1]?.paintSlot && i < y - 1 && r.chartexConnectorLines !== !1) {
280
- let e = J + Je * (i + 1) + (Je - $) / 2, s = n.isPos ? o : c;
238
+ }, s) && e.strokeRect(i, a, $, u);
239
+ }), e.paintSlot && y[r + 1]?.paintSlot && r < v - 1 && n.chartexConnectorLines !== !1) {
240
+ let s = q + tt * (r + 1) + (tt - $) / 2, c = e.isPos ? a : l;
281
241
  t.save();
282
- let u = ae(r, r.chartexSeriesLineStyle, B, x, 3, "#000000", { linkedNoStyleFallback: !0 });
283
- H(t, u, l) && (u.widthEmu ?? (t.lineWidth = .75 * l), t.beginPath(), t.moveTo(a + $, s), t.lineTo(e, s), t.stroke()), t.restore();
242
+ let u = [n.chartexSeriesLineStyle, n.chartexDataPointLineStyle], d = Te(n, Se(V, b), u, u, b, 3, "#000000", { linkedNoStyleFallback: !0 });
243
+ Ne(t, d, o) && (d.widthEmu ?? (t.lineWidth = .75 * o), t.beginPath(), t.moveTo(i + $, c), t.lineTo(s, c), t.stroke()), t.restore();
284
244
  }
285
- let D = n.hasValue ? _[i] : 0, O = s(r, B, i, v[i] ?? "", D, {
286
- visible: r.showDataLabels,
245
+ let te = e.hasValue ? h[r] : 0, D = re(n, V, r, g[r] ?? "", te, {
246
+ visible: n.showDataLabels,
287
247
  showVal: !0,
288
248
  showCatName: !1
289
- }, Se, !n.hasValue);
290
- if (O) {
291
- let e = B?.dataLabelColors?.[i] ?? O.fontColor ?? null, n = e ? `#${e}` : r.dataLabelFontColor ? `#${r.dataLabelFontColor}` : "#595959", s = p(O.fontSizeHpt, l) ?? xe(r.dataLabelFontSizeHpt, g, l), c = O.fontBold ?? r.dataLabelFontBold ?? !1, _ = V(r, O.fontFace ?? r.dataLabelFontFace, "minor");
292
- t.font = `${O.textStyle.fontItalic ? "italic " : ""}${c ? "bold " : ""}${s}px ${_}`, de(t, O.text, {
249
+ }, H, !e.hasValue);
250
+ if (D) {
251
+ let e = V?.dataLabelColors?.[r] ?? D.fontColor ?? null, l = e ? `#${e}` : n.dataLabelFontColor ? `#${n.dataLabelFontColor}` : "#595959", d = T(D.fontSizeHpt, o) ?? _(n.dataLabelFontSizeHpt, m, o), h = D.fontBold ?? n.dataLabelFontBold ?? !1, g = M(n, D.fontFace ?? n.dataLabelFontFace, "minor");
252
+ t.font = `${D.textStyle.fontItalic ? "italic " : ""}${h ? "bold " : ""}${d}px ${g}`, He(t, D.text, {
293
253
  kind: "bar",
294
254
  rect: {
295
- x: a,
296
- y: o,
255
+ x: i,
256
+ y: a,
297
257
  w: $,
298
258
  h: u
299
259
  },
300
260
  orientation: "vertical",
301
- negative: D < 0,
302
- position: O.position ?? "outEnd"
261
+ negative: te < 0,
262
+ position: D.position ?? "outEnd"
303
263
  }, {
304
- x: J,
305
- y: Y,
306
- w: X,
307
- h: Z
308
- }, s, n, O.manualLayout, {
309
- x: f,
310
- y: m,
311
- w: h,
312
- h: g
313
- }, se(r, O.richRuns, l, _, c, O.textStyle), void 0, O.textStyle, l, O.labelBox, d);
264
+ x: q,
265
+ y: J,
266
+ w: Y,
267
+ h: X
268
+ }, d, l, D.manualLayout, {
269
+ x: c,
270
+ y: f,
271
+ w: p,
272
+ h: m
273
+ }, je(n, D.richRuns, o, g, h, D.textStyle), void 0, D.textStyle, o, D.labelBox, s);
314
274
  }
315
- }), t.textAlign = "center", t.textBaseline = "top", t.fillStyle = r.catAxisFontColor ? `#${r.catAxisFontColor}` : "#595959", t.font = be(A, P, r.catAxisFontBold ?? !1, r.catAxisFontItalic ?? !1);
316
- let Ye = Y + Z + 4;
317
- for (let e = 0; e < y && !r.catAxisHidden; e++) {
318
- let n = J + Je * e + Je / 2;
319
- (fe[e] ?? []).forEach((e, r) => e && t.fillText(e, n, Ye + r * (A + 2)));
275
+ }), t.textAlign = "center", t.textBaseline = "top", t.fillStyle = n.catAxisFontColor ? `#${n.catAxisFontColor}` : "#595959", t.font = ye(P, R, n.catAxisFontBold ?? !1, n.catAxisFontItalic ?? !1);
276
+ let nt = J + X + 4;
277
+ for (let e = 0; e < v && !n.catAxisHidden; e++) {
278
+ let n = q + tt * e + tt / 2;
279
+ (de[e] ?? []).forEach((e, r) => e && t.fillText(e, n, nt + r * (P + 2)));
320
280
  }
321
- ge(t, r, f, m, h, g, J, Y, X, Z, Re, Be, O.catFontPx, O.valFontPx), Oe(t, W, G, f, m, h, g, J, Y, X, Z, E.bandH + 2, l, [
322
- Pe,
281
+ w(t, n, c, f, p, m, q, J, Y, X, K, Je, k.catFontPx, k.valFontPx), Me(t, W, G, c, f, p, m, q, J, Y, X, D.bandH + 2, o, [
323
282
  Fe,
324
- Ie
325
- ], d), t.restore();
283
+ Re,
284
+ ze
285
+ ], s), t.restore();
326
286
  }
327
- function J(e, t, n, r, i) {
328
- let o = t.series[0]?.values ?? [], l = Math.max(o.length, t.categories.length);
329
- if (l === 0 || ye(e, n, l)) return;
330
- let u = 0;
331
- for (let e = 0; e < l; e++) u = Math.max(u, o[e] ?? 0);
332
- if (!(u > 0)) return;
333
- let { x: d, y: f, w: m, h } = n, g = Ee(e, t, m, h, r), _ = t.series[0], v = I(_?.dataLabelOverrides), y = `#${_?.color ?? z(t, 0, 1, _?.chartexStyle)}`, b = U(t, 0, 1, _?.chartexStyle, _?.color), x = {
287
+ function q(e, t, n, r, i) {
288
+ let a = t.series[0]?.values ?? [], o = Math.max(a.length, t.categories.length);
289
+ if (o === 0 || Le(e, n, o)) return;
290
+ let s = 0;
291
+ for (let e = 0; e < o; e++) s = Math.max(s, a[e] ?? 0);
292
+ if (!(s > 0)) return;
293
+ let { x: c, y: l, w: f, h: p } = n, m = Ae(e, t, f, p, r), h = t.series[0], g = be(h?.dataLabelOverrides), v = `#${h?.color ?? U(t, 0, 1, h?.chartexStyle)}`, y = Ue(t, 0, 1, h?.chartexStyle, h?.color), b = {
334
294
  ...t,
335
- series: [pe(t, _?.name ?? "", _, t.chartexDataPointStyle, 0, 1, y)]
336
- }, S = ue(e, x, m, h, .22, r), { legRightW: C, legLeftW: w, legTopH: T, legBottomH: E } = D(S, t.legendOverlay === !0), O = xe(t.catAxisFontSizeHpt, h, r);
337
- e.save(), e.font = be(O, V(t, t.catAxisFontFace, "minor"), t.catAxisFontBold ?? !1, t.catAxisFontItalic ?? !1);
295
+ series: [ke(t, h?.name ?? "", h, t.chartexDataPointStyle, 0, 1, v)]
296
+ }, x = Be(e, b, f, p, r), { legRightW: S, legLeftW: C, legTopH: w, legBottomH: E } = u(x, t.legendOverlay === !0), D = _(t.catAxisFontSizeHpt, p, r);
297
+ e.save(), e.font = ye(D, M(t, t.catAxisFontFace, "minor"), t.catAxisFontBold ?? !1, t.catAxisFontItalic ?? !1);
338
298
  let k = 0;
339
299
  if (!t.catAxisHidden) {
340
- for (let n = 0; n < Math.min(l, t.categories.length); n++) k = Math.max(k, e.measureText(t.categories[n]).width);
300
+ for (let n = 0; n < Math.min(o, t.categories.length); n++) k = Math.max(k, ne(e, t.categories[n]));
341
301
  t.categories.length > 0 && (k += 10);
342
302
  }
343
- let A = c(t, d, f, m, h, r, {
344
- titleBand: g,
345
- legendSideReserveFrac: .22,
346
- legendReserve: S,
303
+ let j = te(t, c, l, f, p, r, {
304
+ titleBand: m,
305
+ legendReserve: x,
347
306
  pad: {
348
- t: g.bandH + T + 2,
349
- r: C + m * .02,
350
- b: E + h * .02,
351
- l: w + k + m * .02
307
+ t: m.bandH + w + 2,
308
+ r: S + f * .02,
309
+ b: E + p * .02,
310
+ l: C + k + f * .02
352
311
  },
353
312
  honorPlotAreaManualLayout: !0
354
313
  });
355
- Te(e, t, d, f, m, h, f + A.title.topPad, A.title.fontPx);
356
- let { px0: M, py0: P, pw: F, ph: L } = A.plotRect;
357
- j(e, t, M, P, F, L, r, i);
358
- let ne = L / l, R = ne / (1 + a(t.barGapWidth, "chartex") / 100);
359
- for (let n = 0; n < l; n++) {
360
- let a = Math.max(0, o[n] ?? 0), c = F * a / u, l = M + (F - c) / 2, g = P + ne * n + (ne - R) / 2, x = (e) => {
361
- b && c > 0 ? te(e, b, {
362
- x: l,
363
- y: g,
364
- w: c,
365
- h: R
366
- }, y, r, i) : b && (e.fillStyle = Se(e, b, l, g, c, R, y, i), e.fillRect(l, g, c, R)), Ce(e, t, t.chartexDataPointStyle, _, 0, 1, y, r) && e.strokeRect(l, g, c, R);
314
+ Ve(e, t, c, l, f, p, l + j.title.topPad, j.title.fontPx);
315
+ let { px0: N, py0: P, pw: F, ph: L } = j.plotRect;
316
+ if (F <= 0 || L <= 0) return;
317
+ ge(e, t, N, P, F, L, r, i);
318
+ let R = L / o, z = R / (1 + I(t.barGapWidth, "chartex") / 100), ie = be(h?.dataPointOverrides);
319
+ for (let n = 0; n < o; n++) {
320
+ let o = Math.max(0, a[n] ?? 0), u = F * o / s, m = N + (F - u) / 2, y = P + R * n + (R - z) / 2, b = ie.get(n), x = Ie(t, h, b, 0, 1), S = xe(t, h, b, 0, 1, v), C = (e) => {
321
+ x && u > 0 ? we(e, x, {
322
+ x: m,
323
+ y,
324
+ w: u,
325
+ h: z
326
+ }, v, r, i) : x && (e.fillStyle = W(e, x, m, y, u, z, v, i), e.fillRect(m, y, u, z)), Ne(e, S, r, u > 0 ? {
327
+ x: m,
328
+ y,
329
+ w: u,
330
+ h: z
331
+ } : void 0, i) && e.strokeRect(m, y, u, z);
367
332
  };
368
- c > 0 ? ee(e, _?.chartexStyle, t.chartexDataPointStyle, 0, {
369
- x: l,
370
- y: g,
371
- w: c,
372
- h: R
373
- }, r, x) : x(e);
374
- let S = t.categories[n];
375
- !t.catAxisHidden && S != null && (e.fillStyle = t.catAxisFontColor ? `#${t.catAxisFontColor}` : "#595959", e.textAlign = "right", e.textBaseline = "middle", e.fillText(S, M - 6, g + R / 2));
376
- let C = s(t, _, n, S ?? "", a, {
333
+ u > 0 ? ee(e, d(b?.chartexStyle, h?.chartexStyle), t.chartexDataPointStyle, 0, {
334
+ x: m,
335
+ y,
336
+ w: u,
337
+ h: z
338
+ }, r, C) : C(e);
339
+ let w = t.categories[n];
340
+ !t.catAxisHidden && w != null && (e.fillStyle = t.catAxisFontColor ? `#${t.catAxisFontColor}` : "#595959", e.textAlign = "right", e.textBaseline = "middle", ce(e, w, N - 6, y + z / 2, A(D)));
341
+ let E = re(t, h, n, w ?? "", o, {
377
342
  visible: !1,
378
343
  showVal: !1,
379
344
  showCatName: !1
380
- }, v);
381
- if (C) {
382
- let n = p(C.fontSizeHpt, r) ?? xe(t.dataLabelFontSizeHpt, h, r), a = V(t, C.fontFace ?? t.dataLabelFontFace, "minor");
383
- e.font = `${C.textStyle.fontItalic ? "italic " : ""}${C.fontBold ? "bold " : ""}${n}px ${a}`, de(e, C.text, {
345
+ }, g);
346
+ if (E) {
347
+ let n = T(E.fontSizeHpt, r) ?? _(t.dataLabelFontSizeHpt, p, r), a = M(t, E.fontFace ?? t.dataLabelFontFace, "minor");
348
+ e.font = `${E.textStyle.fontItalic ? "italic " : ""}${E.fontBold ? "bold " : ""}${n}px ${a}`, He(e, E.text, {
384
349
  kind: "bar",
385
350
  rect: {
386
- x: l,
387
- y: g,
388
- w: c,
389
- h: R
351
+ x: m,
352
+ y,
353
+ w: u,
354
+ h: z
390
355
  },
391
356
  orientation: "horizontal",
392
357
  negative: !1,
393
- position: C.position ?? "ctr"
358
+ position: E.position ?? "ctr"
394
359
  }, {
395
- x: M,
360
+ x: N,
396
361
  y: P,
397
362
  w: F,
398
363
  h: L
399
- }, n, C.fontColor ? `#${C.fontColor}` : "#ffffff", C.manualLayout, {
400
- x: d,
401
- y: f,
402
- w: m,
403
- h
404
- }, se(t, C.richRuns, r, a, C.fontBold ?? !1, C.textStyle), void 0, C.textStyle, r, C.labelBox, i);
364
+ }, n, E.fontColor ? `#${E.fontColor}` : "#ffffff", E.manualLayout, {
365
+ x: c,
366
+ y: l,
367
+ w: f,
368
+ h: p
369
+ }, je(t, E.richRuns, r, a, E.fontBold ?? !1, E.textStyle), void 0, E.textStyle, r, E.labelBox, i);
405
370
  }
406
371
  }
407
372
  if (!t.catAxisHidden && !t.catAxisLineHidden) {
408
- let n = N(t.catAxisLineColor, t.catAxisLineWidthEmu, r);
409
- e.strokeStyle = n.color, e.lineWidth = n.width, e.beginPath(), e.moveTo(M, P), e.lineTo(M, P + L), e.stroke();
373
+ let n = O(t.catAxisLineColor, t.catAxisLineWidthEmu, r);
374
+ e.strokeStyle = n.color, e.lineWidth = n.width, e.beginPath(), e.moveTo(N, P), e.lineTo(N, P + L), e.stroke();
410
375
  }
411
- Oe(e, x, S, d, f, m, h, M, P, F, L, g.bandH + 2, r, [b], i), e.restore();
376
+ Me(e, b, x, c, l, f, p, N, P, F, L, m.bandH + 2, r, [y], i), e.restore();
412
377
  }
413
- function Y(e, t, n, r, i = 0) {
414
- let a = t.series[0];
415
- if (!a || ye(e, n, Math.max(t.categories.length, a.categories?.length ?? 0, a.values.length))) return;
416
- let o = G(a, t.categories, { sortDescending: !1 });
417
- if (o.points.length === 0) return;
418
- let s = we(a, 0), c = ae(t, t.chartexDataPointLineStyle, a, s, 1, ve(0, a), { linkedNoStyleFallback: !0 });
419
- ie(e, {
420
- ...t,
378
+ function J(e, t, n, i, a = 0) {
379
+ let o = t.series[0];
380
+ if (!o || Le(e, n, Math.max(t.categories.length, o.categories?.length ?? 0, o.values.length))) return;
381
+ let s = x(o, t.categories, { sortDescending: t.chartexParetoSortDescending ?? !1 });
382
+ if (s.points.length === 0) return;
383
+ let c = v(o, 0), l = [t.chartexDataPointStyle, t.chartexDataPointLineStyle], u = Te(t, Se(o, c), l, l, c, 1, `#${U(t, c, 1, o.chartexStyle)}`, { linkedNoStyleFallback: !0 });
384
+ Pe(e, r(t, {
421
385
  chartType: "line",
422
- categories: o.categories,
386
+ categories: t.chartexParetoFlatEndpoint ? [...s.categories, ""] : s.categories,
423
387
  series: [{
424
- ...o.series,
388
+ ...s.series,
389
+ values: t.chartexParetoFlatEndpoint ? [...s.series.values, 1] : s.series.values,
425
390
  showMarker: !1,
426
- lineHidden: !c.visible,
427
- lineColor: c.color.replace(/^#/, ""),
428
- lineWidthEmu: c.widthEmu,
391
+ lineHidden: !u.visible,
392
+ lineColor: u.color.replace(/^#/, ""),
393
+ lineWidthEmu: u.widthEmu ?? 9525,
429
394
  chartexStyle: {
430
- lineDash: c.dash,
431
- lineCap: c.cap,
432
- lineJoin: c.join
395
+ lineDash: u.dash,
396
+ lineCap: u.cap,
397
+ lineJoin: u.join
433
398
  }
434
399
  }],
435
400
  catAxisHidden: !1,
436
- catAxisTickLabelPos: "none",
401
+ catAxisTickLabelPos: t.chartexParetoSortDescending == null || !(o.categories ?? t.categories).some((e) => e != null && e !== "") ? "none" : "nextTo",
437
402
  showLegend: !1,
438
403
  valMin: t.valMin ?? 0,
439
- valMax: t.valMax ?? 1.2,
440
- valAxisMajorUnit: t.valAxisMajorUnit ?? .2
441
- }, n, r, i);
404
+ valMax: t.valMax ?? (t.valAxisFormatCode === "0%" ? 1 : 1.2),
405
+ valAxisMajorUnit: t.valAxisMajorUnit ?? (t.valAxisFormatCode === "0%" ? .1 : .2)
406
+ }), n, i, a);
407
+ }
408
+ function Y(e) {
409
+ return {
410
+ min: e.secondaryValAxis?.min ?? 0,
411
+ max: e.secondaryValAxis?.max ?? 1,
412
+ title: e.secondaryValAxis?.title ?? null,
413
+ hidden: e.secondaryValAxis?.hidden ?? !1,
414
+ formatCode: e.secondaryValAxis?.formatCode ?? "0%",
415
+ fontColor: e.secondaryValAxis?.fontColor ?? null,
416
+ fontSizeHpt: e.secondaryValAxis?.fontSizeHpt ?? null,
417
+ fontFace: e.secondaryValAxis?.fontFace ?? null,
418
+ lineColor: e.secondaryValAxis?.lineColor ?? null,
419
+ lineWidthEmu: e.secondaryValAxis?.lineWidthEmu ?? null,
420
+ lineHidden: e.secondaryValAxis?.lineHidden ?? !1,
421
+ majorTickMark: e.secondaryValAxis?.majorTickMark ?? "out",
422
+ minorTickMark: e.secondaryValAxis?.minorTickMark ?? null,
423
+ majorUnit: e.secondaryValAxis?.majorUnit ?? null,
424
+ minorUnit: e.secondaryValAxis?.minorUnit ?? null,
425
+ titleFontSizeHpt: e.secondaryValAxis?.titleFontSizeHpt ?? null,
426
+ titleFontBold: e.secondaryValAxis?.titleFontBold ?? null,
427
+ titleFontColor: e.secondaryValAxis?.titleFontColor ?? null,
428
+ titleFontFace: e.secondaryValAxis?.titleFontFace ?? null
429
+ };
442
430
  }
443
- function X(e, t, n, r, i = 0) {
444
- let a = t.series[0];
445
- if (!a || ye(e, n, Math.max(t.categories.length, a.categories?.length ?? 0, a.values.length))) return;
446
- let o = G(a, t.categories);
447
- if (o.points.length === 0) return;
448
- let s = t.series.find((e) => e.seriesType === "line"), c = s?.chartexFormatIdx ?? a.chartexFormatIdx ?? 0, l = {
449
- ...s ?? o.series,
450
- name: s?.name || "Cumulative %",
451
- values: o.series.values,
452
- categories: o.categories,
453
- color: s?.color ?? me(t, t.chartexDataPointLineStyle, "line", c, 1) ?? a.lineColor ?? a.color,
431
+ function X(e, t, n, i, a = 0) {
432
+ let o = t.series.filter((e) => e.seriesType !== "line"), s = t.chartexParetoOwnerIndex ?? 0, c = o[s];
433
+ if (!c || o.length === 0 || Le(e, n, Math.max(t.categories.length, ...o.map((e) => e.values.length)))) return;
434
+ let l = o.map((e, n) => x(n === 0 ? K(t, e, n, o.length) : e, t.categories, {
435
+ sortDescending: t.chartexParetoSortDescending ?? !0,
436
+ keepUnvaluedCategories: !0
437
+ })), u = l[s], d = l[0];
438
+ if (u.points.length === 0 || d.points.length === 0) return;
439
+ let f = t.chartexParetoFlatEndpoint === !0 && d.categories.length === d.points.length, p = t.series.find((e) => e.seriesType === "line"), m = p?.chartexFormatIdx ?? c.chartexFormatIdx ?? 0, h = {
440
+ ...p ?? u.series,
441
+ name: p?.name || "Cumulative %",
442
+ values: u.series.values,
443
+ categories: d.categories,
444
+ color: p?.color ?? We(t, t.chartexDataPointLineStyle, "line", m, 1) ?? c.lineColor ?? c.color,
454
445
  seriesType: "line",
455
446
  useSecondaryAxis: !0,
456
447
  showMarker: !1
457
- }, u = {
458
- min: t.secondaryValAxis?.min ?? 0,
459
- max: t.secondaryValAxis?.max ?? 1,
460
- title: t.secondaryValAxis?.title ?? null,
461
- hidden: t.secondaryValAxis?.hidden ?? !1,
462
- formatCode: t.secondaryValAxis?.formatCode ?? "0%",
463
- fontColor: t.secondaryValAxis?.fontColor ?? null,
464
- fontSizeHpt: t.secondaryValAxis?.fontSizeHpt ?? null,
465
- fontFace: t.secondaryValAxis?.fontFace ?? null,
466
- lineColor: t.secondaryValAxis?.lineColor ?? null,
467
- lineWidthEmu: t.secondaryValAxis?.lineWidthEmu ?? null,
468
- lineHidden: t.secondaryValAxis?.lineHidden ?? !1,
469
- majorTickMark: t.secondaryValAxis?.majorTickMark ?? "out",
470
- minorTickMark: t.secondaryValAxis?.minorTickMark ?? null,
471
- majorUnit: t.secondaryValAxis?.majorUnit ?? null,
472
- minorUnit: t.secondaryValAxis?.minorUnit ?? null,
473
- titleFontSizeHpt: t.secondaryValAxis?.titleFontSizeHpt ?? null,
474
- titleFontBold: t.secondaryValAxis?.titleFontBold ?? null,
475
- titleFontColor: t.secondaryValAxis?.titleFontColor ?? null,
476
- titleFontFace: t.secondaryValAxis?.titleFontFace ?? null
477
- };
478
- F(e, {
479
- ...t,
448
+ }, g = Y(t);
449
+ ze(e, r(t, {
480
450
  chartType: "clusteredBar",
481
- categories: o.categories,
482
- series: [{
483
- ...o.orderedSeries,
451
+ categories: f ? [...d.categories, ""] : d.categories,
452
+ series: [...l.map((e) => ({
453
+ ...e.orderedSeries,
454
+ values: f ? [...e.orderedSeries.values, null] : e.orderedSeries.values,
484
455
  seriesType: null,
485
456
  useSecondaryAxis: !1
486
- }, l],
487
- secondaryValAxis: u
488
- }, n, r, {
457
+ })), f ? {
458
+ ...h,
459
+ values: [...h.values, 1]
460
+ } : h],
461
+ secondaryValAxis: g
462
+ }), n, i, {
489
463
  gapPolicy: "chartex",
490
464
  semanticLineNoStyleFallback: !0
491
- }, i);
465
+ }, a);
492
466
  }
493
- var Z = 7, He = .05, Q = 1.2;
494
- function Ue(e, t, n, r) {
467
+ var Xe = 7, Z = .05, Q = 1.2;
468
+ function Ze(e, t, n, r) {
495
469
  let i = (r ?? t) - (n ?? e);
496
470
  if (!(i > 0) || !Number.isFinite(i)) return null;
497
- let a = je(i, Z);
471
+ let a = ie(i, Xe);
498
472
  if (!(a > 0) || !Number.isFinite(a)) return null;
499
- let o = e - i * He, s = t + i * He;
473
+ let o = e - i * Z, s = t + i * Z;
500
474
  e >= 0 && (e === 0 || t > Q * e) && (o = 0), t <= 0 && (t === 0 || Math.abs(e) > Q * Math.abs(t)) && (s = 0);
501
475
  let c = n ?? Math.floor(o / a) * a, l = r ?? Math.ceil(s / a) * a;
502
476
  return ![c, l].every(Number.isFinite) || !(l > c) ? null : {
@@ -505,102 +479,108 @@ function Ue(e, t, n, r) {
505
479
  majorUnit: a
506
480
  };
507
481
  }
508
- function We(t, r, i, o, s) {
509
- let l = 3 * o, u = r.chartexBox;
510
- if (!u || u.categories.length === 0 || u.series.length === 0) return;
511
- let { x: f, y: p, w: m, h } = i;
512
- if (ye(t, i, C(u.series.map((e) => e.valuesByCategory), 1e4))) return;
513
- let _ = () => {
514
- t.fillStyle = "#888", t.font = "12px sans-serif", t.textAlign = "center", t.textBaseline = "middle", t.fillText("(chart values out of range)", f + m / 2, p + h / 2);
515
- }, v = (e) => {
482
+ function Qe(e, n, r, i, o) {
483
+ let c = 3 * i, f = n.chartexBox;
484
+ if (!f || f.categories.length === 0 || f.series.length === 0) return;
485
+ let { x: m, y: h, w: y, h: x } = r;
486
+ if (Le(e, r, t(f.series.map((e) => e.valuesByCategory), 1e4))) return;
487
+ let C = () => {
488
+ e.fillStyle = "#888", e.font = "12px sans-serif", e.textAlign = "center", e.textBaseline = "middle", e.fillText("(chart values out of range)", m + y / 2, h + x / 2);
489
+ }, T = (e) => {
516
490
  let t = e.max - e.min, n = t / e.step;
517
491
  return Number.isFinite(e.min) && Number.isFinite(e.max) && Number.isFinite(e.step) && Number.isFinite(t) && Number.isFinite(n) && e.max > e.min && e.step > 0 && n <= 1e3 && e.min + e.step > e.min;
518
- }, y = Infinity, b = -Infinity;
519
- for (let e of u.series) for (let t of e.valuesByCategory) for (let e of t) Number.isFinite(e) && (e < y && (y = e), e > b && (b = e));
520
- if (!isFinite(y) || !isFinite(b)) return;
521
- if (!Number.isFinite(b - y)) {
522
- _();
492
+ }, k = Infinity, j = -Infinity;
493
+ for (let e of f.series) for (let t of e.valuesByCategory) for (let e of t) Number.isFinite(e) && (e < k && (k = e), e > j && (j = e));
494
+ if (!isFinite(k) || !isFinite(j)) return;
495
+ if (!Number.isFinite(j - k)) {
496
+ C();
523
497
  return;
524
498
  }
525
- let x = r.valAxisMajorUnit == null ? Ue(y, b, r.valMin, r.valMax) : null, S = x ? {
526
- ...r,
527
- valMin: x.min,
528
- valMax: x.max,
529
- valAxisMajorUnit: x.majorUnit
530
- } : r, E = V(r, r.valAxisFontFace, "minor"), k = xe(r.valAxisFontSizeHpt, h, o), A = P(k), F = he(o), I = Ae({
531
- dataMin: y,
532
- dataMax: b,
533
- explicitMin: S.valMin,
534
- explicitMax: S.valMax,
535
- axisLenPt: h / o,
536
- majorUnit: S.valAxisMajorUnit
499
+ let N = n.valAxisMajorUnit == null ? Ze(k, j, n.valMin, n.valMax) : null, F = N ? {
500
+ ...n,
501
+ valMin: N.min,
502
+ valMax: N.max,
503
+ valAxisMajorUnit: N.majorUnit
504
+ } : n, L = M(n, n.valAxisFontFace, "minor"), re = _(n.valAxisFontSizeHpt, x, i), R = V(re), ie = Oe(i), B = p({
505
+ dataMin: k,
506
+ dataMax: j,
507
+ explicitMin: F.valMin,
508
+ explicitMax: F.valMax,
509
+ axisLenPt: x / i,
510
+ majorUnit: F.valAxisMajorUnit
537
511
  });
538
- if (!v({
539
- min: I.min,
540
- max: I.max,
541
- step: I.majorUnit
512
+ if (!T({
513
+ min: B.min,
514
+ max: B.max,
515
+ step: B.majorUnit
542
516
  })) {
543
- _();
517
+ C();
544
518
  return;
545
519
  }
546
- let L = 0;
547
- if (!r.valAxisHidden) {
548
- let e = t.font;
549
- t.font = be(k, E, r.valAxisFontBold ?? !1, r.valAxisFontItalic ?? !1);
550
- let n = 0;
551
- for (let e of I.majorTicks) {
552
- let i = le(r, e, !1);
553
- n = Math.max(n, t.measureText(i).width);
520
+ let ae = 0;
521
+ if (!n.valAxisHidden) {
522
+ let t = e.font;
523
+ e.font = ye(re, L, n.valAxisFontBold ?? !1, n.valAxisFontItalic ?? !1);
524
+ let r = 0;
525
+ for (let t of B.majorTicks) {
526
+ let i = _e(n, t, !1);
527
+ r = Math.max(r, ne(e, i));
554
528
  }
555
- t.font = e, L = n + A + g * o;
529
+ e.font = t, ae = r + R + s * i;
556
530
  }
557
- let ie = Ee(t, r, m, h, o), se = xe(r.catAxisFontSizeHpt, h, o), de = xe(r.valAxisFontSizeHpt, h, o), ve = n(r, m, h, o), H = u.series.length, Se = u.series.map((e, t) => we(e, t)), De = u.series.map((e, t) => {
558
- let n = Se[t], i = e.color ?? z(r, n, H, e.chartexStyle);
559
- return pe(r, e.name, e, r.chartexDataPointStyle, n, H, i, !0);
560
- }), ke = {
561
- ...r,
562
- series: De
563
- }, je = ue(t, ke, m, h, .22, o), { legRightW: Me, legLeftW: Ne, legTopH: Pe, legBottomH: Fe } = D(je, r.legendOverlay === !0), Ie = c(r, f, p, m, h, o, {
564
- titleBand: ie,
565
- legendSideReserveFrac: .22,
566
- legendReserve: je,
531
+ let le = Ae(e, n, y, x, i), de = _(n.catAxisFontSizeHpt, x, i), fe = _(n.valAxisFontSizeHpt, x, i), me = a(n, y, x, i), H = f.series.length, ve = f.series.map((e, t) => v(e, t)), be = f.series.map((e, t) => {
532
+ let r = ve[t], i = e.color ?? U(n, r, H, e.chartexStyle), a = ke(n, e.name, Se(e, r) ?? e, n.chartexDataPointStyle, r, H, i, !0), o = Ce(n, e, r, H, i);
533
+ return o.darkened && a.lineColor != null ? {
534
+ ...a,
535
+ lineColor: o.line.color.replace(/^#/, "")
536
+ } : a;
537
+ }), xe = {
538
+ ...n,
539
+ series: be
540
+ }, Te = Be(e, xe, y, x, i), { legRightW: De, legLeftW: je, legTopH: Pe, legBottomH: Ie } = u(Te, n.legendOverlay === !0), ze = n.valAxisHidden ? 0 : oe(B.majorTicks.map((e) => _e(n, e, !1)), A(re)) / 2, He = n.catAxisHidden ? 0 : oe(f.categories, A(de)), Ge = te(n, m, h, y, x, i, {
541
+ titleBand: le,
542
+ legendReserve: Te,
567
543
  pad: {
568
- t: ie.bandH + Pe + de / 2 + 2,
569
- r: Me + m * .02,
570
- b: Fe + ve.catBandH + (r.catAxisHidden ? h * .02 : d(se)),
571
- l: Ne + ve.valBandW + (r.valAxisHidden ? m * .02 : L)
544
+ t: le.bandH + Pe + fe / 2 + 2 + ze,
545
+ r: De + y * .02,
546
+ b: Ie + me.catBandH + (n.catAxisHidden ? x * .02 : b(de) + He),
547
+ l: je + me.valBandW + (n.valAxisHidden ? y * .02 : ae)
572
548
  },
573
549
  honorPlotAreaManualLayout: !0
574
- }), { px0: W, py0: G, pw: K, ph: q } = Ie.plotRect;
575
- j(t, r, W, G, K, q, o, s);
576
- let Le = u.categories, Re = Le.length, ze = oe(S, y, b, q / o);
577
- if (!v(ze)) {
578
- _();
550
+ }), { px0: W, py0: G, pw: Ke, ph: K } = Ge.plotRect;
551
+ if (Ke <= 0 || K <= 0) {
552
+ Ve(e, n, m, h, y, x, h + Ge.title.topPad, Ge.title.fontPx);
553
+ return;
554
+ }
555
+ ge(e, n, W, G, Ke, K, i, o);
556
+ let qe = f.categories, Je = qe.length, Ye = se(F, k, j, K / i);
557
+ if (!T(Ye)) {
558
+ C();
579
559
  return;
580
560
  }
581
- Te(t, r, f, p, m, h, p + Ie.title.topPad, Ie.title.fontPx);
582
- let { min: Be, max: Ve } = ze, J = Ve - Be, Y = (e) => G + q * (1 - (e - Be) / J), X = N(r.valAxisLineColor, r.valAxisLineWidthEmu, o), Z = re(r, o);
583
- if (t.save(), !r.valAxisHidden) {
584
- if (t.font = be(k, E, r.valAxisFontBold ?? !1, r.valAxisFontItalic ?? !1), t.textAlign = "right", t.textBaseline = "middle", r.valAxisMinorGridlines) {
585
- let e = ce(r, o);
586
- for (let n of ze.minorLines) R(t, W, K, Y(n), !1, e);
561
+ Ve(e, n, m, h, y, x, h + Ge.title.topPad, Ge.title.fontPx);
562
+ let { min: q, max: J } = Ye, Y = J - q, X = (e) => G + K * (1 - (e - q) / Y), Xe = O(n.valAxisLineColor, n.valAxisLineWidthEmu, i), Z = ue(n, i);
563
+ if (e.save(), !n.valAxisHidden) {
564
+ if (e.font = ye(re, L, n.valAxisFontBold ?? !1, n.valAxisFontItalic ?? !1), e.textAlign = "right", e.textBaseline = "middle", n.valAxisMinorGridlines) {
565
+ let t = he(n, i);
566
+ for (let n of Ye.minorLines) z(e, W, Ke, X(n), !1, t);
587
567
  }
588
- for (let e of ze.majorLines) {
589
- let n = Y(e);
590
- if (r.valAxisMajorGridlines !== !1) {
591
- t.strokeStyle = Z.color, t.lineWidth = Z.width;
592
- let e = Z.dash.length > 0 && t.getLineDash ? t.getLineDash() : [];
593
- Z.dash.length > 0 && t.setLineDash(Z.dash), t.beginPath(), t.moveTo(W, n), t.lineTo(W + K, n), t.stroke(), Z.dash.length > 0 && t.setLineDash(e);
568
+ for (let t of Ye.majorLines) {
569
+ let r = X(t);
570
+ if (n.valAxisMajorGridlines !== !1) {
571
+ e.strokeStyle = Z.color, e.lineWidth = Z.width;
572
+ let t = Z.dash.length > 0 && e.getLineDash ? e.getLineDash() : [];
573
+ Z.dash.length > 0 && e.setLineDash(Z.dash), e.beginPath(), e.moveTo(W, r), e.lineTo(W + Ke, r), e.stroke(), Z.dash.length > 0 && e.setLineDash(t);
594
574
  }
595
- t.fillStyle = r.valAxisFontColor ? `#${r.valAxisFontColor}` : "#595959", t.fillText(le(r, e, !1), W - F, n), _e(t, r.valAxisMajorTickMark, "val", W, n, X.color, X.width, !1, r.valAxisLineHidden, "major", o, r.valAxisLineDash);
575
+ e.fillStyle = n.valAxisFontColor ? `#${n.valAxisFontColor}` : "#595959", ce(e, _e(n, t, !1), W - ie, r, A(re)), l(e, n.valAxisMajorTickMark, "val", W, r, Xe.color, Xe.width, !1, n.valAxisLineHidden, "major", i, n.valAxisLineDash);
596
576
  }
597
- for (let e of ze.minorTicks) _e(t, r.valAxisMinorTickMark, "val", W, Y(e), X.color, X.width, !1, r.valAxisLineHidden, "minor", o, r.valAxisLineDash);
598
- r.valAxisLineHidden || ne(t, W, G, W, G + q, X.color, X.width, r.valAxisLineDash);
577
+ for (let t of Ye.minorTicks) l(e, n.valAxisMinorTickMark, "val", W, X(t), Xe.color, Xe.width, !1, n.valAxisLineHidden, "minor", i, n.valAxisLineDash);
578
+ n.valAxisLineHidden || pe(e, W, G, W, G + K, Xe.color, Xe.width, n.valAxisLineDash);
599
579
  }
600
- let He = N(r.catAxisLineColor, r.catAxisLineWidthEmu, o);
601
- !r.catAxisHidden && !r.catAxisLineHidden && ne(t, W, G + q, W + K, G + q, He.color, He.width, r.catAxisLineDash);
602
- let Q = K / Re, We = a(r.barGapWidth, "chartex"), Ge = (e) => `#${u.series[e].color ?? z(r, Se[e], H, u.series[e].chartexStyle)}`, Ke = (e) => U(r, Se[e], H, u.series[e].chartexStyle, u.series[e].color), qe = u.series.map((e) => e.valuesByCategory.map((t) => w(t, e.quartileMethod))), Je = (e, t) => {
603
- let n = M(W, K, u.oneBoxPerSeries ? 1 : Re, H, u.oneBoxPerSeries ? 0 : e, t, We);
580
+ let Q = O(n.catAxisLineColor, n.catAxisLineWidthEmu, i);
581
+ !n.catAxisHidden && !n.catAxisLineHidden && pe(e, W, G + K, W + Ke, G + K, Q.color, Q.width, n.catAxisLineDash);
582
+ let Qe = Ke / Je, $e = I(n.barGapWidth, "chartex"), et = (e) => `#${f.series[e].color ?? U(n, ve[e], H, f.series[e].chartexStyle)}`, tt = (e) => Ue(n, ve[e], H, f.series[e].chartexStyle, f.series[e].color), $ = f.series.map((e) => e.valuesByCategory.map((t) => P(t, e.quartileMethod))), nt = n.chartStyleMarkerSymbol ?? n.chartexMarkerSymbol ?? "circle", rt = f.series.map((e, t) => nt === "none" ? $[t].map(() => []) : g($[t], e.showNonoutliers, e.showOutliers, X, 3 * i)), it = (e, t) => {
583
+ let n = D(W, Ke, f.oneBoxPerSeries ? 1 : Je, H, f.oneBoxPerSeries ? 0 : e, t, $e);
604
584
  return n ? {
605
585
  bx: n.boxX,
606
586
  boxW: n.boxWidth,
@@ -610,174 +590,179 @@ function We(t, r, i, o, s) {
610
590
  boxW: 0,
611
591
  cx: W
612
592
  };
613
- };
614
- for (let e = 0; e < H; e++) {
615
- let n = u.series[e];
616
- if (!n.meanLine) continue;
617
- let i = r.chartexDataPointLineStyle ?? r.chartexDataPointStyle, a = n.lineColor ? `#${n.lineColor}` : Ge(e);
618
- if (t.save(), Ce(t, r, i, n, Se[e], H, a, o) || n.lineColor != null) {
619
- n.lineColor && (t.strokeStyle = a), n.lineWidthEmu && (t.lineWidth = T(n.lineWidthEmu, o));
620
- let r = !1;
621
- t.beginPath();
622
- for (let n = 0; n < Re; n++) {
623
- let i = qe[e][n];
593
+ }, at = (t, r) => {
594
+ let a = f.series[t], s = $[t][r];
595
+ if (!s) return;
596
+ let { bx: l, boxW: u, cx: p } = it(r, t), m = et(t), h = tt(t), g = n.chartexDataPointStyle, _ = n.chartexDataPointMarkerStyle ?? g, v = ve[t], y = Se(a, v) ?? a, b = We(n, g, "line", v, H), x = y.lineColor ? `#${y.lineColor}` : b ? `#${b}` : m, S = Ce(n, a, v, H, x).line, C = We(n, _, "fill", v, H), w = Ee(n, v, H, a.chartexStyle, a.color, _), T = Fe(n, _, y, v, H, We(n, _, "line", v, H) ?? x, { linkedNoStyleFallback: !0 }), te = d(a.chartexStyle), D = X(s.q1), O = X(s.q3), k = Math.min(D, O), A = Math.max(1, Math.abs(D - O)), j = u * .4;
597
+ if (Ne(e, S, i)) {
598
+ let t = X(s.whiskerHi), n = X(s.whiskerLo);
599
+ e.beginPath(), s.whiskerHi > s.q3 && (e.moveTo(p, t), e.lineTo(p, O)), s.whiskerLo < s.q1 && (e.moveTo(p, D), e.lineTo(p, n)), s.whiskerHi >= s.q3 && (e.moveTo(p - j / 2, t), e.lineTo(p + j / 2, t)), s.whiskerLo <= s.q1 && (e.moveTo(p - j / 2, n), e.lineTo(p + j / 2, n)), e.stroke();
600
+ }
601
+ ee(e, a.chartexStyle, g, v, {
602
+ x: l,
603
+ y: k,
604
+ w: u,
605
+ h: A
606
+ }, i, (e) => {
607
+ if (h && we(e, h, {
608
+ x: l,
609
+ y: k,
610
+ w: u,
611
+ h: A
612
+ }, m, i, o), Ne(e, S, i, {
613
+ x: l,
614
+ y: k,
615
+ w: u,
616
+ h: A
617
+ }, o)) {
618
+ let t = e.lineWidth;
619
+ e.strokeRect(l + t / 2, k + t / 2, u - t, A - t);
620
+ }
621
+ });
622
+ let M = X(s.median);
623
+ Ne(e, S, i) && (e.beginPath(), e.moveTo(l, M), e.lineTo(l + u, M), e.stroke());
624
+ for (let n of rt[t][r]) Re(e, p, X(n), nt, 3, w ? C ? `#${C}` : m : "transparent", T.visible ? T.color : null, i, T.widthEmu == null ? 1 : E(T.widthEmu, i), w, o, T.visible ? T.paint : null, T.dash, T.customDash, T.cap, T.join, !1, te, _, v, v);
625
+ if (a.meanMarker) {
626
+ let t = X(s.mean), n = c;
627
+ Ne(e, S, i) && (e.beginPath(), e.moveTo(p - n, t - n), e.lineTo(p + n, t + n), e.moveTo(p + n, t - n), e.lineTo(p - n, t + n), e.stroke());
628
+ }
629
+ }, ot = (t) => {
630
+ let r = f.series[t];
631
+ if (!r.meanLine) return;
632
+ let a = Ce(n, r, ve[t], H, et(t)).line;
633
+ if (e.save(), Ne(e, a, i)) {
634
+ let n = !1;
635
+ e.beginPath();
636
+ for (let r = 0; r < Je; r++) {
637
+ let i = $[t][r];
624
638
  if (!i) {
625
- r = !1;
639
+ n = !1;
626
640
  continue;
627
641
  }
628
- let { cx: a } = Je(n, e), o = Y(i.mean);
629
- r ? t.lineTo(a, o) : t.moveTo(a, o), r = !0;
642
+ let { cx: a } = it(r, t), o = X(i.mean);
643
+ n ? e.lineTo(a, o) : e.moveTo(a, o), n = !0;
630
644
  }
631
- t.stroke();
645
+ e.stroke();
632
646
  }
633
- t.restore();
647
+ e.restore();
648
+ };
649
+ for (let e = 0; e < H; e++) {
650
+ for (let t = 0; t < Je; t++) at(e, t);
651
+ ot(e);
634
652
  }
635
- let $ = xe(r.catAxisFontSizeHpt, h, o), Ye = O($);
636
- for (let n = 0; n < Re; n++) {
637
- let i = W + Q * (n + .5);
638
- r.catAxisHidden || _e(t, r.catAxisMajorTickMark, "cat", G + q, i, He.color, He.width, !1, r.catAxisLineHidden, "major", o, r.catAxisLineDash);
639
- for (let i = 0; i < H; i++) {
640
- let a = u.series[i], c = qe[i][n];
641
- if (!c) continue;
642
- let { bx: d, boxW: f, cx: p } = Je(n, i), m = Ge(i), h = Ke(i), g = r.chartexDataPointStyle, _ = r.chartexDataPointLineStyle ?? g, v = r.chartexDataPointMarkerStyle ?? g, y = Se[i], b = me(r, g, "line", y, H), x = a.lineColor ? `#${a.lineColor}` : b ? `#${b}` : m, S = a.lineWidthEmu ? T(a.lineWidthEmu, o) : g?.lineWidthEmu == null ? 1 : T(g.lineWidthEmu, o), C = me(r, _, "line", y, H), w = me(r, v, "fill", y, H), E = B(r, y, H, a.chartexStyle, a.color, v), D = me(r, v, "line", y, H), O = ae(r, v, a, y, H, D ?? x, { linkedNoStyleFallback: !0 }), k = e(a.chartexStyle), A = (e, n) => Ce(t, r, e, a, y, H, n, o, { linkedNoStyleFallback: !0 }), j = Y(c.q1), M = Y(c.q3), N = Math.min(j, M), P = Math.max(1, Math.abs(j - M)), F = f * .4;
643
- A(_, C ?? x) && (t.beginPath(), t.moveTo(p, Y(c.whiskerHi)), t.lineTo(p, M), t.moveTo(p, j), t.lineTo(p, Y(c.whiskerLo)), t.moveTo(p - F / 2, Y(c.whiskerHi)), t.lineTo(p + F / 2, Y(c.whiskerHi)), t.moveTo(p - F / 2, Y(c.whiskerLo)), t.lineTo(p + F / 2, Y(c.whiskerLo)), t.stroke()), ee(t, a.chartexStyle, g, y, {
644
- x: d,
645
- y: N,
646
- w: f,
647
- h: P
648
- }, o, (e) => {
649
- h && te(e, h, {
650
- x: d,
651
- y: N,
652
- w: f,
653
- h: P
654
- }, m, o, s), Ce(e, r, g, a, y, H, x, o, { linkedNoStyleFallback: !0 }) && e.strokeRect(d + S / 2, N + S / 2, f - S, P - S);
655
- });
656
- let I = Y(c.median);
657
- if (A(_, C ?? x) && (t.beginPath(), t.moveTo(d, I), t.lineTo(d + f, I), t.stroke()), a.showNonoutliers) {
658
- let e = r.chartStyleMarkerSymbol ?? r.chartexMarkerSymbol ?? "circle";
659
- for (let n of c.inner) e !== "none" && fe(t, p, Y(n), e, 3, E ? w ? `#${w}` : m : "transparent", O.visible ? O.color : null, o, O.widthEmu == null ? 1 : T(O.widthEmu, o), E, s, O.visible ? O.paint : null, O.dash, O.customDash, O.cap, O.join, !1, k, v, y, y);
660
- }
661
- if (a.meanMarker) {
662
- let e = Y(c.mean), n = l;
663
- A(v, D ?? x) && (t.beginPath(), t.moveTo(p - n, e - n), t.lineTo(p + n, e + n), t.moveTo(p + n, e - n), t.lineTo(p - n, e + n), t.stroke());
664
- }
665
- if (a.showOutliers) {
666
- let e = r.chartStyleMarkerSymbol ?? r.chartexMarkerSymbol ?? "circle";
667
- for (let n of c.outliers) e !== "none" && fe(t, p, Y(n), e, 3, E ? w ? `#${w}` : m : "transparent", O.visible ? O.color : null, o, O.widthEmu == null ? 1 : T(O.widthEmu, o), E, s, O.visible ? O.paint : null, O.dash, O.customDash, O.cap, O.join, !1, k, v, y, y);
668
- }
669
- }
670
- if (!r.catAxisHidden) {
671
- t.font = be($, V(r, r.catAxisFontFace, "minor"), r.catAxisFontBold ?? !1, r.catAxisFontItalic ?? !1), t.fillStyle = r.catAxisFontColor ? `#${r.catAxisFontColor}` : "#595959", t.textAlign = "center", t.textBaseline = "top";
672
- let e = Le[n];
673
- t.fillText(e, i, G + q + Ye);
653
+ let st = _(n.catAxisFontSizeHpt, x, i), ct = S(st);
654
+ for (let t = 0; t < Je; t++) {
655
+ let r = W + Qe * (t + .5);
656
+ if (n.catAxisHidden || l(e, n.catAxisMajorTickMark, "cat", G + K, r, Q.color, Q.width, !1, n.catAxisLineHidden, "major", i, n.catAxisLineDash), !n.catAxisHidden) {
657
+ e.font = ye(st, M(n, n.catAxisFontFace, "minor"), n.catAxisFontBold ?? !1, n.catAxisFontItalic ?? !1), e.fillStyle = n.catAxisFontColor ? `#${n.catAxisFontColor}` : "#595959", e.textAlign = "center", e.textBaseline = "top";
658
+ let i = qe[t];
659
+ ce(e, i, r, G + K + ct, A(st));
674
660
  }
675
661
  }
676
- t.restore(), ge(t, r, f, p, m, h, W, G, K, q, Ne, Fe, ve.catFontPx, ve.valFontPx), Oe(t, ke, je, f, p, m, h, W, G, K, q, ie.bandH + 2, o, u.series.map((e, t) => Ke(t)), s);
662
+ e.restore(), w(e, n, m, h, y, x, W, G, Ke, K, je, Ie, me.catFontPx, me.valFontPx), Me(e, xe, Te, m, h, y, x, W, G, Ke, K, le.bandH + 2, i, f.series.map((e, t) => tt(t)), o);
677
663
  }
678
- var Ge = .18;
679
- function Ke(e, t, n, r, i) {
680
- let a = t.chartexSunburst;
681
- if (!a || a.rows.length === 0) return;
682
- let { x: o, y: l, w: u, h: d } = n;
683
- if (v(a.rows)) {
684
- ye(e, n, _ + 1);
664
+ var $e = .18;
665
+ function et(e, t, n, a, o) {
666
+ let s = t.chartexSunburst;
667
+ if (!s || s.rows.length === 0) return;
668
+ let { x: l, y: u, w: f, h: p } = n;
669
+ if (h(s.rows)) {
670
+ Le(e, n, R + 1);
685
671
  return;
686
672
  }
687
- let f = y(a.rows);
688
- if (f.layoutWeight <= 0 || f.children.length === 0) return;
689
- let h = t.series[0], g = I(h?.dataLabelOverrides), b = f.children.map((e, n) => U(t, n, f.children.length, h?.chartexStyle, h?.color)), S = {
690
- ...t,
673
+ let g = m(s.rows);
674
+ if (g.layoutWeight <= 0 || g.children.length === 0) return;
675
+ let _ = t.series[0], v = be(_?.dataLabelOverrides), y = g.children.map((e, n) => Ue(t, n, g.children.length, _?.chartexStyle, _?.color)), b = r(t, {
691
676
  chartType: "clusteredBar",
692
- series: f.children.map((e) => {
693
- let n = z(t, e.branchIndex, f.children.length, h?.chartexStyle);
694
- return pe(t, e.label, h, t.chartexDataPointStyle, e.branchIndex, f.children.length, n, !1, !1);
677
+ series: g.children.map((e) => {
678
+ let n = U(t, e.branchIndex, g.children.length, _?.chartexStyle);
679
+ return ke(t, e.label, _, t.chartexDataPointStyle, e.branchIndex, g.children.length, n, !1, !1);
695
680
  })
696
- }, C = ue(e, S, u, d, .22, r), w = c(t, o, l, u, d, r, {
681
+ }), x = Be(e, b, f, p, a), S = te(t, l, u, f, p, a, {
697
682
  titleTopPadFrac: .035,
698
683
  titleBottomPadFrac: .035,
699
- legendSideReserveFrac: 0,
700
- legendReserve: C,
684
+ legendReserve: x,
701
685
  radialGapFrac: .02,
702
686
  honorPlotAreaManualLayout: !0
703
687
  });
704
- Te(e, t, o, l, u, d, l + w.title.topPad, w.title.fontPx);
705
- let { px0: T, py0: E, pw: D, ph: O } = w.plotRect;
706
- j(e, t, T, E, D, O, r, i);
707
- let k = T + D / 2, A = E + O / 2, M = Math.min(D, O) * .46;
708
- f.a0 = -Math.PI / 2, f.a1 = -Math.PI / 2 + Math.PI * 2, x(f);
709
- let N = m(f) + 1, P = M * Ge, F = (M - P) / N, te = (e) => `#${z(t, e, f.children.length, h?.chartexStyle)}`, ne = (e) => U(t, e, f.children.length, h?.chartexStyle, h?.color), R = h?.seriesDataLabels, re = V(t, R?.fontFace ?? t.dataLabelFontFace, "minor"), ie = p(R?.fontSizeHpt, r) ?? Math.max(7, Math.min(13, M * .075)), ae = R?.fontColor ? `#${R.fontColor}` : "#ffffff", oe = Array.from({ length: N }, () => []), ce = [f];
710
- for (; ce.length > 0;) {
711
- let e = ce.pop();
712
- e.depth >= 0 && oe[e.depth].push(e);
713
- for (let t = e.children.length - 1; t >= 0; t--) ce.push(e.children[t]);
688
+ Ve(e, t, l, u, f, p, u + S.title.topPad, S.title.fontPx);
689
+ let { px0: C, py0: w, pw: E, ph: D } = S.plotRect;
690
+ if (!(E > 0) || !(D > 0)) return;
691
+ ge(e, t, C, w, E, D, a, o);
692
+ let O = C + E / 2, k = w + D / 2, A = Math.min(E, D) * .46;
693
+ g.a0 = -Math.PI / 2, g.a1 = -Math.PI / 2 + Math.PI * 2, i(g);
694
+ let j = c(g) + 1, ne = A * $e, N = (A - ne) / j, P = (e) => `#${U(t, e, g.children.length, _?.chartexStyle)}`, F = be(_?.dataPointOverrides), I = _?.seriesDataLabels, L = M(t, I?.fontFace ?? t.dataLabelFontFace, "minor"), z = T(I?.fontSizeHpt, a) ?? Math.max(7, Math.min(13, A * .075)), ie = I?.fontColor ? `#${I.fontColor}` : "#ffffff", B = Array.from({ length: j }, () => []), ae = [g];
695
+ for (; ae.length > 0;) {
696
+ let e = ae.pop();
697
+ e.depth >= 0 && B[e.depth].push(e);
698
+ for (let t = e.children.length - 1; t >= 0; t--) ae.push(e.children[t]);
714
699
  }
715
700
  e.save();
716
- for (let n = 0; n < N; n++) {
717
- let a = P + n * F, c = a + F;
718
- for (let m of oe[n]) {
719
- let n = m.a1 - m.a0;
701
+ for (let n = 0; n < j; n++) {
702
+ let r = ne + n * N, i = r + N;
703
+ for (let s of B[n]) {
704
+ let n = s.a1 - s.a0;
720
705
  if (n <= 1e-4) continue;
721
- let _ = ne(m.branchIndex), v = {
722
- x: k - c,
723
- y: A - c,
724
- w: c * 2,
725
- h: c * 2
706
+ let c = F.get(s.labelIndex), m = Ie(t, _, c, s.branchIndex, g.children.length), h = xe(t, _, c, s.branchIndex, g.children.length, "#ffffff"), y = {
707
+ x: O - i,
708
+ y: k - i,
709
+ w: i * 2,
710
+ h: i * 2
726
711
  };
727
- ee(e, h?.chartexStyle, t.chartexDataPointStyle, h?.chartexFormatIdx ?? 0, v, r, (e) => {
728
- e.beginPath(), e.arc(k, A, c, m.a0, m.a1), e.arc(k, A, a, m.a1, m.a0, !0), e.closePath(), _ && L(e, _, v, te(m.branchIndex), r, i), Ce(e, t, t.chartexDataPointStyle, t.series[0], m.branchIndex, f.children.length, "#ffffff", r) && e.stroke();
729
- }, m.branchIndex);
730
- let y = s(t, h, m.labelIndex, m.label, m.value, {
712
+ ee(e, d(c?.chartexStyle, _?.chartexStyle), t.chartexDataPointStyle, _?.chartexFormatIdx ?? 0, y, a, (e) => {
713
+ e.beginPath(), e.arc(O, k, i, s.a0, s.a1), e.arc(O, k, r, s.a1, s.a0, !0), e.closePath(), m && De(e, m, y, P(s.branchIndex), a, o), Ne(e, h, a, y, o) && e.stroke();
714
+ }, s.branchIndex);
715
+ let b = re(t, _, s.labelIndex, s.label, s.value, {
731
716
  visible: !1,
732
717
  showVal: !1,
733
718
  showCatName: !1
734
- }, g);
735
- if (!y) continue;
736
- let b = y.text, x = p(y.fontSizeHpt, r) ?? ie, S = y.fontColor ? `#${y.fontColor}` : ae, C = y.fontFace ? V(t, y.fontFace, "minor") : re, w = (m.a0 + m.a1) / 2, j = (a + c) / 2, M = F - 4, N = n * j;
737
- if (!y.manualLayout && M < x * .9 && N < x * .9) continue;
738
- let P = k + Math.cos(w) * j, I = A + Math.sin(w) * j;
739
- if (e.font = `${y.textStyle.fontItalic ? "italic " : ""}${y.fontBold ? "bold " : ""}${x}px ${C}`, y.manualLayout) {
740
- de(e, b, {
719
+ }, v);
720
+ if (!b) continue;
721
+ let x = b.text, S = T(b.fontSizeHpt, a) ?? z, te = b.fontColor ? `#${b.fontColor}` : ie, A = b.fontFace ? M(t, b.fontFace, "minor") : L, j = (s.a0 + s.a1) / 2, ne = (r + i) / 2, I = N - 4, R = n * ne;
722
+ if (!b.manualLayout && I < S * .9 && R < S * .9) continue;
723
+ let B = O + Math.cos(j) * ne, ae = k + Math.sin(j) * ne;
724
+ if (e.font = `${b.textStyle.fontItalic ? "italic " : ""}${b.fontBold ? "bold " : ""}${S}px ${A}`, b.manualLayout) {
725
+ He(e, x, {
741
726
  kind: "point",
742
- x: P,
743
- y: I,
744
- position: y.position ?? "ctr"
727
+ x: B,
728
+ y: ae,
729
+ position: b.position ?? "ctr"
745
730
  }, {
746
- x: T,
747
- y: E,
748
- w: D,
749
- h: O
750
- }, x, S, y.manualLayout, {
751
- x: o,
752
- y: l,
753
- w: u,
754
- h: d
755
- }, se(t, y.richRuns, r, C, y.fontBold ?? !1, y.textStyle), void 0, y.textStyle, r, y.labelBox, i);
731
+ x: C,
732
+ y: w,
733
+ w: E,
734
+ h: D
735
+ }, S, te, b.manualLayout, {
736
+ x: l,
737
+ y: u,
738
+ w: f,
739
+ h: p
740
+ }, je(t, b.richRuns, a, A, b.fontBold ?? !1, b.textStyle), void 0, b.textStyle, a, b.labelBox, o);
756
741
  continue;
757
742
  }
758
- e.save(), e.translate(P, I);
759
- let R = w, oe = R * 180 / Math.PI % 360;
760
- (oe > 90 || oe < -90) && (R += Math.PI), e.rotate(R), e.font = `${y.textStyle.fontItalic ? "italic " : ""}${y.fontBold ? "bold " : ""}${x}px ${C}`, de(e, b, {
743
+ e.save(), e.translate(B, ae);
744
+ let oe = j, se = oe * 180 / Math.PI % 360;
745
+ (se > 90 || se < -90) && (oe += Math.PI), e.rotate(oe), e.font = `${b.textStyle.fontItalic ? "italic " : ""}${b.fontBold ? "bold " : ""}${S}px ${A}`, He(e, x, {
761
746
  kind: "point",
762
747
  x: 0,
763
748
  y: 0,
764
- position: y.position ?? "ctr"
749
+ position: b.position ?? "ctr"
765
750
  }, {
766
- x: -M / 2,
767
- y: -N / 2,
768
- w: M,
769
- h: N
770
- }, x, S, void 0, {
771
- x: -M / 2,
772
- y: -N / 2,
773
- w: M,
774
- h: N
775
- }, se(t, y.richRuns, r, C, y.fontBold ?? !1, y.textStyle), void 0, y.textStyle, r, y.labelBox, i), e.restore();
751
+ x: -I / 2,
752
+ y: -R / 2,
753
+ w: I,
754
+ h: R
755
+ }, S, te, void 0, {
756
+ x: -I / 2,
757
+ y: -R / 2,
758
+ w: I,
759
+ h: R
760
+ }, je(t, b.richRuns, a, A, b.fontBold ?? !1, b.textStyle), void 0, b.textStyle, a, b.labelBox, o), e.restore();
776
761
  }
777
762
  }
778
- e.restore(), Oe(e, S, C, o, l, u, d, T, E, D, O, w.title.bandH + 2, r, b, i);
763
+ e.restore(), Me(e, b, x, l, u, f, p, C, w, E, D, S.title.bandH + 2, a, y, o);
779
764
  }
780
- function qe(e, t) {
765
+ function tt(e, t) {
781
766
  let n = e.map((e, t) => ({
782
767
  node: e,
783
768
  index: t,
@@ -840,143 +825,162 @@ function qe(e, t) {
840
825
  }
841
826
  return p(c, l), o;
842
827
  }
843
- function Je(e, t, n, r, i) {
844
- let a = t.chartexTreemap;
845
- if (!a || a.rows.length === 0) return;
846
- if (v(a.rows)) {
847
- ye(e, n, _ + 1);
828
+ function $(e, t, n, i, a) {
829
+ let o = t.chartexTreemap;
830
+ if (!o || o.rows.length === 0) return;
831
+ if (h(o.rows)) {
832
+ Le(e, n, R + 1);
848
833
  return;
849
834
  }
850
- let o = y(a.rows, !0);
851
- if (o.layoutWeight <= 0 || o.children.length === 0) return;
852
- let l = t.series[0], u = o.children.map((e) => U(t, e.branchIndex, o.children.length, l?.chartexStyle, l?.color)), d = {
853
- ...t,
835
+ let s = m(o.rows, !0);
836
+ if (s.layoutWeight <= 0 || s.children.length === 0) return;
837
+ let c = t.series[0], l = s.children.map((e) => Ue(t, e.branchIndex, s.children.length, c?.chartexStyle, c?.color)), u = r(t, {
854
838
  chartType: "clusteredBar",
855
- series: o.children.map((e) => {
856
- let n = z(t, e.branchIndex, o.children.length, l?.chartexStyle);
857
- return pe(t, e.label, l, t.chartexDataPointStyle, e.branchIndex, o.children.length, n, !0, !1);
839
+ series: s.children.map((e) => {
840
+ let n = U(t, e.branchIndex, s.children.length, c?.chartexStyle);
841
+ return ke(t, e.label, c, t.chartexDataPointStyle, e.branchIndex, s.children.length, n);
858
842
  })
859
- }, f = ue(e, d, n.w, n.h, .22, r), m = c(t, n.x, n.y, n.w, n.h, r, {
843
+ }), f = Be(e, u, n.w, n.h, i), p = te(t, n.x, n.y, n.w, n.h, i, {
860
844
  titleTopPadFrac: .035,
861
845
  titleBottomPadFrac: .035,
862
- legendSideReserveFrac: 0,
863
846
  legendReserve: f,
864
847
  radialGapFrac: .015,
865
848
  honorPlotAreaManualLayout: !0
866
849
  });
867
- Te(e, t, n.x, n.y, n.w, n.h, n.y + m.title.topPad, m.title.fontPx);
868
- let { px0: h, py0: g, pw: b, ph: x } = m.plotRect;
869
- j(e, t, h, g, b, x, r, i);
870
- let S = {
871
- x: h,
872
- y: g,
873
- w: b,
874
- h: x
875
- }, C = a.parentLabelLayout ?? "overlapping", w = t.series[0]?.seriesDataLabels, T = V(t, w?.fontFace ?? t.dataLabelFontFace, "minor"), E = p(w?.fontSizeHpt, r) ?? Math.max(8, Math.min(13, m.plotRect.ph * .025)), D = w?.fontColor ? `#${w.fontColor}` : "#ffffff", O = new Map((t.series[0]?.dataLabelOverrides ?? []).map((e) => [e.idx, e])), k = t.chartBg ? t.chartBg.startsWith("#") ? t.chartBg : `#${t.chartBg}` : "#ffffff", A = (a, c) => {
876
- if (c.w < .5 || c.h < .5) return;
877
- let u = `#${z(t, a.branchIndex, o.children.length, l?.chartexStyle)}`, d = U(t, a.branchIndex, o.children.length, l?.chartexStyle, l?.color), f = O.get(a.labelIndex), m = f?.fontColor ? `#${f.fontColor}` : D, h = p(f?.fontSizeHpt, r) ?? E, g = f?.fontBold ?? w?.fontBold ?? !1;
878
- if (a.children.length > 0) {
879
- let o = s(t, l, a.labelIndex, a.label, a.value, {
880
- visible: C !== "none",
850
+ Ve(e, t, n.x, n.y, n.w, n.h, n.y + p.title.topPad, p.title.fontPx);
851
+ let { px0: g, py0: _, pw: v, ph: y } = p.plotRect;
852
+ if (!(v > 0) || !(y > 0)) return;
853
+ ge(e, t, g, _, v, y, i, a);
854
+ let b = {
855
+ x: g,
856
+ y: _,
857
+ w: v,
858
+ h: y
859
+ }, x = o.parentLabelLayout ?? "overlapping", S = t.series[0]?.seriesDataLabels, C = M(t, S?.fontFace ?? t.dataLabelFontFace, "minor"), w = T(S?.fontSizeHpt, i) ?? Math.max(8, Math.min(13, p.plotRect.ph * .025)), E = S?.fontColor ? `#${S.fontColor}` : "#ffffff", D = new Map((t.series[0]?.dataLabelOverrides ?? []).map((e) => [e.idx, e])), O = t.chartBg ? t.chartBg.startsWith("#") ? t.chartBg : `#${t.chartBg}` : "#ffffff", k = be(c?.dataPointOverrides), A = (r, o) => {
860
+ if (o.w < .5 || o.h < .5) return;
861
+ let l = `#${U(t, r.branchIndex, s.children.length, c?.chartexStyle)}`, u = k.get(r.labelIndex), f = Ie(t, c, u, r.branchIndex, s.children.length), p = d(u?.chartexStyle, c?.chartexStyle), m = D.get(r.labelIndex), h = m?.fontColor ? `#${m.fontColor}` : E, g = T(m?.fontSizeHpt, i) ?? w, _ = m?.fontBold ?? S?.fontBold ?? !1;
862
+ if (r.children.length > 0) {
863
+ let s = re(t, c, r.labelIndex, r.label, r.value, {
864
+ visible: x !== "none",
881
865
  showVal: !1,
882
866
  showCatName: !0
883
- }, O, !0), p = o != null && (C !== "overlapping" || a.depth === 0), _ = h, v = o?.fontFace ? V(t, o.fontFace, "minor") : T, y = C === "banner" && p ? Math.min(c.h * .28, _ + 7) : 0;
884
- y > 0 && ee(e, l?.chartexStyle, t.chartexDataPointStyle, l?.chartexFormatIdx ?? 0, {
885
- x: c.x,
886
- y: c.y,
887
- w: c.w,
867
+ }, D, !0), u = s != null && (x !== "overlapping" || r.depth === 0), d = g, v = s?.fontFace ? M(t, s.fontFace, "minor") : C, y = x === "banner" && u ? Math.min(o.h * .28, d + 7) : 0;
868
+ y > 0 && ee(e, p, t.chartexDataPointStyle, c?.chartexFormatIdx ?? 0, {
869
+ x: o.x,
870
+ y: o.y,
871
+ w: o.w,
888
872
  h: y
889
- }, r, (e) => {
890
- d && te(e, d, {
891
- x: c.x,
892
- y: c.y,
893
- w: c.w,
873
+ }, i, (e) => {
874
+ f && we(e, f, {
875
+ x: o.x,
876
+ y: o.y,
877
+ w: o.w,
894
878
  h: y
895
- }, u, r, i);
896
- }, a.branchIndex);
897
- let b = {
898
- x: c.x,
899
- y: c.y + y,
900
- w: c.w,
901
- h: Math.max(0, c.h - y)
879
+ }, l, i, a);
880
+ }, r.branchIndex);
881
+ let S = {
882
+ x: o.x,
883
+ y: o.y + y,
884
+ w: o.w,
885
+ h: Math.max(0, o.h - y)
902
886
  };
903
- for (let e of qe(a.children, b)) A(e.node, e.rect);
904
- if (p && (o.manualLayout || c.w > _ * 2 && c.h > _ + 4)) {
905
- e.font = `${g ? "bold " : ""}${_}px ${v}`;
906
- let a = y > 0 ? {
907
- x: c.x,
908
- y: c.y,
909
- w: c.w,
887
+ for (let e of tt(r.children, S)) A(e.node, e.rect);
888
+ if (u && (s.manualLayout || o.w > d * 2 && o.h > d + 4)) {
889
+ e.font = `${_ ? "bold " : ""}${d}px ${v}`;
890
+ let r = y > 0 ? {
891
+ x: o.x,
892
+ y: o.y,
893
+ w: o.w,
910
894
  h: y
911
- } : c, s = f?.position ?? "inBase";
912
- de(e, o.text, o.manualLayout ? {
895
+ } : o, c = m?.position ?? "inBase";
896
+ He(e, s.text, s.manualLayout ? {
913
897
  kind: "point",
914
- x: c.x + c.w / 2,
915
- y: c.y + c.h / 2,
916
- position: s
898
+ x: o.x + o.w / 2,
899
+ y: o.y + o.h / 2,
900
+ position: c
917
901
  } : {
918
902
  kind: "box",
919
- rect: a,
920
- position: s
921
- }, o.manualLayout ? S : a, _, m, o.manualLayout, n, se(t, o.richRuns, r, v, g, o.textStyle), void 0, o.textStyle, r, o.labelBox, i);
903
+ rect: r,
904
+ position: c
905
+ }, s.manualLayout ? b : r, d, h, s.manualLayout, n, je(t, s.richRuns, i, v, _, s.textStyle), void 0, s.textStyle, i, s.labelBox, a);
922
906
  }
923
907
  return;
924
908
  }
925
- ee(e, l?.chartexStyle, t.chartexDataPointStyle, l?.chartexFormatIdx ?? 0, c, r, (e) => {
926
- d && te(e, d, c, u, r, i), Ce(e, t, t.chartexDataPointStyle, t.series[0], a.branchIndex, o.children.length, k, r, { linkedNoStyleFallback: !0 }) && e.strokeRect(c.x, c.y, c.w, c.h);
927
- }, a.branchIndex);
928
- let _ = s(t, l, a.labelIndex, a.label, a.value, {
909
+ ee(e, p, t.chartexDataPointStyle, c?.chartexFormatIdx ?? 0, o, i, (e) => {
910
+ f && we(e, f, o, l, i, a), Ne(e, xe(t, c, u, r.branchIndex, s.children.length, O, t.chartexDataPointStyle, { linkedNoStyleFallback: !0 }), i, o, a) && e.strokeRect(o.x, o.y, o.w, o.h);
911
+ }, r.branchIndex);
912
+ let v = re(t, c, r.labelIndex, r.label, r.value, {
929
913
  visible: !1,
930
914
  showVal: !1,
931
915
  showCatName: !1
932
- }, O);
933
- if (!_) return;
934
- let v = p(_.fontSizeHpt, r) ?? h;
935
- if (!_.manualLayout && (c.w <= v * 1.2 || c.h <= v * 1.2)) return;
936
- let y = _.fontFace ? V(t, _.fontFace, "minor") : T;
937
- e.font = `${_.fontBold ? "bold " : ""}${v}px ${y}`;
938
- let b = c, x = _.position === "outEnd" ? "inEnd" : _.position ?? "ctr";
939
- de(e, _.text, _.manualLayout ? {
916
+ }, D);
917
+ if (!v) return;
918
+ let y = T(v.fontSizeHpt, i) ?? g;
919
+ if (!v.manualLayout && (o.w <= y * 1.2 || o.h <= y * 1.2)) return;
920
+ let te = v.fontFace ? M(t, v.fontFace, "minor") : C;
921
+ e.font = `${v.fontBold ? "bold " : ""}${y}px ${te}`;
922
+ let j = o, ne = v.position === "outEnd" ? "inEnd" : v.position ?? "ctr";
923
+ He(e, v.text, v.manualLayout ? {
940
924
  kind: "point",
941
- x: c.x + c.w / 2,
942
- y: c.y + c.h / 2,
943
- position: x
925
+ x: o.x + o.w / 2,
926
+ y: o.y + o.h / 2,
927
+ position: ne
944
928
  } : {
945
929
  kind: "box",
946
- rect: b,
947
- position: x
948
- }, _.manualLayout ? S : b, v, _.fontColor ? `#${_.fontColor}` : m, _.manualLayout, n, se(t, _.richRuns, r, y, _.fontBold ?? !1, _.textStyle), void 0, _.textStyle, r, _.labelBox, i);
930
+ rect: j,
931
+ position: ne
932
+ }, v.manualLayout ? b : j, y, v.fontColor ? `#${v.fontColor}` : h, v.manualLayout, n, je(t, v.richRuns, i, te, v.fontBold ?? !1, v.textStyle), void 0, v.textStyle, i, v.labelBox, a);
949
933
  };
950
- e.save(), e.beginPath(), e.rect(h, g, b, x), e.clip();
951
- for (let e of qe(o.children, {
952
- x: h,
953
- y: g,
954
- w: b,
955
- h: x
934
+ e.save(), e.beginPath(), e.rect(g, _, v, y), e.clip();
935
+ for (let e of tt(s.children, {
936
+ x: g,
937
+ y: _,
938
+ w: v,
939
+ h: y
956
940
  })) A(e.node, e.rect);
957
- e.restore(), Oe(e, d, f, n.x, n.y, n.w, n.h, h, g, b, x, m.title.bandH + 2, r, u, i);
941
+ e.restore(), Me(e, u, f, n.x, n.y, n.w, n.h, g, _, v, y, p.title.bandH + 2, i, l, a);
958
942
  }
959
- function $(e, t, n, r, i = 0) {
960
- let a = Re(t, void 0, n, r), o = ze(t, n, r);
961
- if (a != null && a > 1048576 || o != null && o > 1048576 || a != null && o != null && a > 1048576 - o) return ye(e, n, _ + 1), !0;
943
+ function nt(e, t, n, i, a = 0) {
944
+ let o = Ke(t, void 0, n, i), s = qe(t, n, i);
945
+ if (o != null && o > 1048576 || s != null && s > 1048576 || o != null && s != null && o > 1048576 - s) return Le(e, n, R + 1), !0;
946
+ if (t.chartexSuppressGeometry) {
947
+ let r = Ae(e, t, n.w, n.h, i);
948
+ return Ve(e, t, n.x, n.y, n.w, n.h, n.y + r.topPad, r.fontPx), !0;
949
+ }
962
950
  switch (t.chartType) {
963
- case "waterfall": return Ve(e, t, n, r, i), !0;
964
- case "clusteredColumn": return F(e, {
965
- ...t,
966
- chartType: "clusteredBar"
967
- }, n, r, { gapPolicy: "chartex" }, i), !0;
968
- case "histogram": return Be(e, t, n, r, i), !0;
969
- case "funnel": return J(e, t, n, r, i), !0;
970
- case "paretoLine": return Y(e, t, n, r, i), !0;
971
- case "pareto": return X(e, t, n, r, i), !0;
972
- case "boxWhisker": return We(e, t, n, r, i), !0;
973
- case "sunburst": return Ke(e, t, n, r, i), !0;
974
- case "treemap": return Je(e, t, n, r, i), !0;
951
+ case "waterfall": return Ye(e, t, n, i, a), !0;
952
+ case "clusteredColumn": {
953
+ let o = t.series.map((e, n) => n === 0 ? K(t, e, n, t.series.length) : e), s = t.chartexParetoSortDescending ? o.map((e) => x(e, t.categories, {
954
+ sortDescending: !0,
955
+ keepUnvaluedCategories: !0
956
+ }).orderedSeries) : o, c = t.chartexShowUnpairedPercentageAxis && s[0] ? [{
957
+ ...s[0],
958
+ name: "",
959
+ values: [],
960
+ seriesType: "line",
961
+ useSecondaryAxis: !0,
962
+ lineHidden: !0,
963
+ showMarker: !1
964
+ }] : [];
965
+ return ze(e, r(t, {
966
+ chartType: "clusteredBar",
967
+ categories: s[0]?.categories ?? t.categories,
968
+ series: [...s, ...c],
969
+ secondaryValAxis: c.length > 0 ? Y(t) : t.secondaryValAxis
970
+ }), n, i, { gapPolicy: "chartex" }, a), !0;
971
+ }
972
+ case "histogram": return Je(e, t, n, i, a), !0;
973
+ case "funnel": return q(e, t, n, i, a), !0;
974
+ case "paretoLine": return J(e, t, n, i, a), !0;
975
+ case "pareto": return X(e, t, n, i, a), !0;
976
+ case "boxWhisker": return Qe(e, t, n, i, a), !0;
977
+ case "sunburst": return et(e, t, n, i, a), !0;
978
+ case "treemap": return $(e, t, n, i, a), !0;
975
979
  default: return !1;
976
980
  }
977
981
  }
978
982
  //#endregion
979
983
  //#region src/chart-ex.ts
980
- var Ye = Me({ render: $ }, "chartEx");
984
+ var rt = G({ render: nt }, "chartEx");
981
985
  //#endregion
982
- export { Ye as chartEx };
986
+ export { rt as chartEx };