@silurus/ooxml 0.89.0 → 0.89.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/THIRD_PARTY_NOTICES.md +1 -1
  2. package/dist/assets/render-worker-C5G_Nr_A.js +35 -0
  3. package/dist/assets/render-worker-DQfWdNsm.js +16 -0
  4. package/dist/assets/render-worker-Ds7LjwU-.js +15 -0
  5. package/dist/bounded-raw-part-cache-CsnNptAy.js +33925 -0
  6. package/dist/{canvas-viewer-mechanics-DfQqRKkD.js → canvas-viewer-mechanics-BZ8QCrRi.js} +2 -2
  7. package/dist/{cfb-guard-9QTRTg7f.js → cfb-guard-dNeUiANF.js} +1 -1
  8. package/dist/chart-ex.mjs +477 -477
  9. package/dist/{comment-overlay-controller-B5_zGgG5.js → comment-overlay-controller-CBvQx-En.js} +16 -16
  10. package/dist/{comment-ui-runtime-D_sb2K6s.js → comment-ui-runtime-BKidRH36.js} +3 -3
  11. package/dist/{comment-ui-runtime-Jy-3goA9.js → comment-ui-runtime-C47QoDUy.js} +3 -3
  12. package/dist/{document-model-source-BKNrXjAL.js → document-model-source-MzFPrxt0.js} +44 -44
  13. package/dist/{document-pull-client-CxONDGbk.js → document-pull-client-BoJeuURD.js} +6102 -7994
  14. package/dist/{document-pull-worker-AMyXYpPq.js → document-pull-worker-CaP8XESP.js} +18 -18
  15. package/dist/{docx-D91ER1_S.js → docx-BN70UhvX.js} +24 -24
  16. package/dist/{docx-DhDnKEI6.js → docx-BRRtSvk3.js} +556 -556
  17. package/dist/{docx-model-source-CdrSt3hF.js → docx-model-source-CTO9iw_W.js} +12 -12
  18. package/dist/docx.mjs +4 -4
  19. package/dist/{drawingml-shape-ChcGZNd8.js → drawingml-shape-CHmq8kpM.js} +55 -55
  20. package/dist/{duotone-ekYik4ix.js → duotone-DN8P4aXe.js} +1 -1
  21. package/dist/{emf-UT6I8rVi.js → emf-CGFQIz6c.js} +60 -60
  22. package/dist/{font-preload-demand-CdJZUMCT.js → font-preload-demand-Dmy31xt-.js} +2 -2
  23. package/dist/{grid-geometry-uQOgViJU.js → grid-geometry-C3IG20ut.js} +1 -1
  24. package/dist/{host-layout-measure-CCEgaC_v.js → host-layout-measure-DsuQ2UJs.js} +1 -1
  25. package/dist/index.mjs +3 -3
  26. package/dist/internal-companion.mjs +2 -2
  27. package/dist/{line-distribute-CPOV6csk.js → line-distribute-Bu8psjGd.js} +153 -70
  28. package/dist/{model-source-DJGzDtGb.js → model-source-s5hRpk4w.js} +4 -4
  29. package/dist/{model-source-session-Bu9CHFHc.js → model-source-session-6fuaqbGs.js} +18 -18
  30. package/dist/{model-source-session-CDuijwv1.js → model-source-session-DqrR4XHR.js} +2 -2
  31. package/dist/{model-source-session-sKpNiIJI.js → model-source-session-cPJSF_Ak.js} +10 -10
  32. package/dist/node.mjs +5 -5
  33. package/dist/{bounded-raw-part-cache-B7JoC1CD.js → plot-area-frame-Bs_j4uu7.js} +15189 -37964
  34. package/dist/{pptx-C_uxLVKB.js → pptx-CaJ6ILnw.js} +9 -9
  35. package/dist/{pptx-CDP9dZHe.js → pptx-_BOGcBym.js} +58 -58
  36. package/dist/{pptx-model-source-O7LhpOjz.js → pptx-model-source-B_9afw9R.js} +5 -5
  37. package/dist/pptx.mjs +5 -5
  38. package/dist/{presentation-model-source-tmROzteR.js → presentation-model-source-CGHLyX32.js} +5 -5
  39. package/dist/region-map.mjs +53 -53
  40. package/dist/{render-CJVglUHl.js → render-CzbDzRKa.js} +2 -2
  41. package/dist/{render-worker-host-BseIaVvm.js → render-worker-host-B1u6BOUd.js} +1 -1
  42. package/dist/{render-worker-host-CyxPU4JU.js → render-worker-host-C-EECo68.js} +1 -1
  43. package/dist/{render-worker-host-aF6aWkC0.js → render-worker-host-DDqZTCVf.js} +1 -1
  44. package/dist/renderer-CD2cvVAF.js +5823 -0
  45. package/dist/{renderer-CkGLj0CC.js → renderer-DRoeb14O.js} +696 -696
  46. package/dist/{resource-measurement-mXw-WjMF.js → resource-measurement-Dhhm7P_l.js} +162 -161
  47. package/dist/{session-Csv9maad.js → session-XPmC0CUd.js} +176 -176
  48. package/dist/{slide-pull-client-DRZYwBTu.js → slide-pull-client-tq7U_fYg.js} +1454 -1484
  49. package/dist/{three-d-BK5siJgJ.js → three-d-BKwNPAP4.js} +107 -107
  50. package/dist/three-d.mjs +625 -625
  51. package/dist/{wasm-runtime-generation-DX4y0Ecl.js → wasm-runtime-generation-D6TKZdNb.js} +4 -4
  52. package/dist/{workbook-model-source-BTC4ISTS.js → workbook-model-source-BIGrfZy6.js} +6 -6
  53. package/dist/worker-source-DrwhR9fw.js +22 -0
  54. package/dist/{worksheet-pull-client-CkHgbtyM.js → worksheet-pull-client-ClvPO_Jf.js} +74 -74
  55. package/dist/{xlsx-CpSDPAEU.js → xlsx-CsmREBaZ.js} +430 -420
  56. package/dist/{xlsx-D5569TPf.js → xlsx-DmHfeNNp.js} +24 -24
  57. package/dist/{xlsx-model-source-DPSkjFic.js → xlsx-model-source-D1flORqy.js} +55 -55
  58. package/dist/xlsx.mjs +5 -5
  59. package/package.json +1 -1
  60. package/dist/assets/render-worker-CUOU6mL2.js +0 -16
  61. package/dist/assets/render-worker-DOqrFhSU.js +0 -15
  62. package/dist/assets/render-worker-DvWUdZUN.js +0 -35
  63. package/dist/plot-area-frame-CaJFvZ7p.js +0 -8502
  64. package/dist/renderer-Czw1cCC7.js +0 -5823
  65. package/dist/worker-source-I1cIYBel.js +0 -22
package/dist/three-d.mjs CHANGED
@@ -1,24 +1,24 @@
1
- import { $i as e, Aa as t, Ai as n, Bi as r, Cn as i, Di as a, Ei as o, Fa as s, Fi as c, Ga as l, Gi as u, Hi as d, Ia as f, Ki as p, La as m, Li as h, Ln as g, Ma as _, Mi as v, Na as y, Nt as b, Oi as x, Ot as S, Pi as C, Qi as w, Ri as T, Rn as E, Sa as D, Ti as O, Vi as k, Wa as A, Yi as j, Zi as M, aa as N, ai as P, ba as F, bn as I, br as L, ca as R, ea as z, fa as B, ia as V, ja as H, ji as ee, ka as U, ki as te, l as W, la as G, li as K, ma as q, n as J, na as ne, oa as Y, oi as re, on as X, pa as ie, pi as ae, qa as oe, qi as se, qt as ce, ra as le, si as ue, sn as de, sr as Z, t as fe, ua as pe, v as me, vn as he, xn as ge, xr as _e, xt as ve, yn as ye, za as be, zi as xe, zn as Se } from "./plot-area-frame-CaJFvZ7p.js";
2
- import { a as Ce, c as we, i as Te, m as Ee, n as De, o as Oe, p as ke, r as Ae, s as je, t as Me, u as Ne, v as Pe, y as Fe } from "./three-d-BK5siJgJ.js";
1
+ import { $a as e, Ba as t, Bi as n, Ca as r, Cn as i, Fi as a, Ga as o, Ha as s, Ii as c, Ja as l, Ji as u, Ka as d, Ki as f, Li as p, Ln as m, Nt as h, Ot as g, Pi as _, Ra as v, Ri as y, Rn as b, Rr as x, Sa as S, Si as C, Ui as w, Va as T, Vi as E, Wa as D, Wi as O, Xi as k, Yi as A, Zi as j, _a as M, bn as N, ca as P, da as F, ea as I, eo as L, fa as R, gi as z, ha as B, hi as V, ia as H, ja as U, ka as W, l as ee, la as G, ma as K, mi as te, n as q, na as ne, no as J, oa as Y, on as X, pa as re, qi as Z, qt as ie, sa as ae, sn as oe, sr as se, t as ce, ta as le, v as ue, va as de, vi as fe, vn as pe, xa as me, xn as he, xt as ge, ya as _e, yn as ve, za as ye, zi as be, zn as xe, zr as Se } from "./plot-area-frame-Bs_j4uu7.js";
2
+ import { a as Ce, c as we, i as Te, m as Ee, n as De, o as Oe, p as ke, r as Ae, s as je, t as Me, u as Ne, v as Pe, y as Fe } from "./three-d-BKwNPAP4.js";
3
3
  import { t as Ie } from "./renderer-module-contract-CWM7jv6d.js";
4
4
  //#region packages/core/src/chart/three-d-datum-style.ts
5
- function Le(e, t, n, r) {
6
- return A(e, r) ? n : t.chartexFormatIdx ?? r;
7
- }
8
- function Re(e, t, n, r, i) {
9
- let a = Le(e, t, r, i), o = be(e, "dataPoint3D", i), s = oe(e, "dataPoint3D"), c = U(n?.chartexStyle, s, r);
10
- if (c !== void 0) return c;
11
- if (n?.fillHidden === !0) {
12
- let e = H(s);
5
+ function Le(t, n, r, i) {
6
+ return e(t, i) ? r : n.chartexFormatIdx ?? i;
7
+ }
8
+ function Re(e, n, r, i, a) {
9
+ let o = Le(e, n, i, a), c = l(e, "dataPoint3D", a), u = J(e, "dataPoint3D"), d = v(r?.chartexStyle, u, i);
10
+ if (d !== void 0) return d;
11
+ if (r?.fillHidden === !0) {
12
+ let e = t(u);
13
13
  if (e !== void 0) return e;
14
14
  }
15
- if (n?.color === "00000000") return null;
16
- if (n?.color) return {
15
+ if (r?.color === "00000000") return null;
16
+ if (r?.color) return {
17
17
  fillType: "solid",
18
- color: n.color
18
+ color: r.color
19
19
  };
20
- let l = U(t.chartexStyle, s, a);
21
- return l === void 0 ? y(o, s, a, n?.chartexStyle, t.chartexStyle) : l;
20
+ let f = v(n.chartexStyle, u, o);
21
+ return f === void 0 ? s(c, u, o, r?.chartexStyle, n.chartexStyle) : f;
22
22
  }
23
23
  //#endregion
24
24
  //#region packages/core/src/chart/three-d-mesh.ts
@@ -887,7 +887,7 @@ function yt(e) {
887
887
  return t;
888
888
  }
889
889
  function bt(e, t, n) {
890
- let r = j(t?.fontSizeHpt ?? e.legendFontSizeHpt, n) ?? 9 * n, i = t?.fontFace ?? e.legendFontFace, a = t?.fontBold ?? e.legendFontBold ?? !1;
890
+ let r = H(t?.fontSizeHpt ?? e.legendFontSizeHpt, n) ?? 9 * n, i = t?.fontFace ?? e.legendFontFace, a = t?.fontBold ?? e.legendFontBold ?? !1;
891
891
  return {
892
892
  fontPx: r,
893
893
  font: `${t?.fontItalic ?? e.legendFontItalic ?? !1 ? "italic " : ""}${a ? "bold " : ""}${r}px ${Lt(e, i)}`,
@@ -901,7 +901,7 @@ var xt = [
901
901
  "A5A5A5",
902
902
  "FFC000",
903
903
  "5B9BD5"
904
- ], St = de, Ct = X, wt = new Set([
904
+ ], St = oe, Ct = X, wt = new Set([
905
905
  "line",
906
906
  "stackedLine",
907
907
  "stackedLinePct",
@@ -916,7 +916,7 @@ var xt = [
916
916
  "stackedBarHPct"
917
917
  ]);
918
918
  function Tt(e, t) {
919
- let n = Number.isFinite(t) && t > 0 ? t / D : 1, r = Number.isFinite(e) && e >= 0 ? e / F : 0;
919
+ let n = Number.isFinite(t) && t > 0 ? t / U : 1, r = Number.isFinite(e) && e >= 0 ? e / W : 0;
920
920
  return Math.max(.25, r) * n;
921
921
  }
922
922
  function Et(e, t) {
@@ -932,7 +932,7 @@ function Ot(e, t, n) {
932
932
  let r = 0;
933
933
  for (let i of e) for (let e of [t(i), n(i)]) {
934
934
  if (e == null) continue;
935
- let t = K(e);
935
+ let t = fe(e);
936
936
  if (e.fillType === "gradient" && t > St || t > Ct - r) return !1;
937
937
  r += t;
938
938
  }
@@ -974,7 +974,7 @@ function Mt(e) {
974
974
  [e.threeD?.sideWall, "wall"],
975
975
  [e.threeD?.backWall, "wall"]
976
976
  ]) {
977
- let i = m(e, n, r);
977
+ let i = d(e, n, r);
978
978
  t.push({
979
979
  fill: i.fill,
980
980
  line: i.line
@@ -1066,36 +1066,36 @@ function Nt(e, t) {
1066
1066
  fill: e
1067
1067
  };
1068
1068
  }
1069
- function $(e, n, r, i, a, o = !0) {
1070
- let c = o && n.dataPointColors?.[i] ? `#${n.dataPointColors[i]}` : Dt(a, n), u = A(e, a) ? i : n.chartexFormatIdx ?? a, d = n.seriesType ?? e.chartType, f = d === "line" || d === "stackedLine" || d === "stackedLinePct", p = be(e, "dataPoint3D", a), m = oe(e, "dataPoint3D"), h, g = c, v = Re(e, n, r, i, a);
1071
- v !== void 0 && ({color: g, fill: h} = Nt(v, g));
1072
- let y, b = null, x = t(r?.chartexStyle, m, i);
1073
- if (x === void 0 && r?.lineHidden === !0 && (x = _(m)), x !== void 0) x?.fillType === "solid" ? b = `#${x.color}` : y = x;
1074
- else if (r?.lineColor) b = `#${r.lineColor}`;
1069
+ function $(t, n, r, i, a, o = !0) {
1070
+ let s = o && n.dataPointColors?.[i] ? `#${n.dataPointColors[i]}` : Dt(a, n), c = e(t, a) ? i : n.chartexFormatIdx ?? a, u = n.seriesType ?? t.chartType, d = u === "line" || u === "stackedLine" || u === "stackedLinePct", f = l(t, "dataPoint3D", a), p = J(t, "dataPoint3D"), m, h = s, g = Re(t, n, r, i, a);
1071
+ g !== void 0 && ({color: h, fill: m} = Nt(g, h));
1072
+ let _, v = null, y = ye(r?.chartexStyle, p, i);
1073
+ if (y === void 0 && r?.lineHidden === !0 && (y = T(p)), y !== void 0) y?.fillType === "solid" ? v = `#${y.color}` : _ = y;
1074
+ else if (r?.lineColor) v = `#${r.lineColor}`;
1075
1075
  else {
1076
- let e = t(n.chartexStyle, m, u);
1077
- if (e === void 0 && n.lineHidden === !0 && (e = _(m)), e !== void 0) e?.fillType === "solid" ? b = `#${e.color}` : y = e;
1078
- else if (n.lineColor) b = `#${n.lineColor}`;
1079
- else if (f) y = h === null ? null : h;
1076
+ let e = ye(n.chartexStyle, p, c);
1077
+ if (e === void 0 && n.lineHidden === !0 && (e = T(p)), e !== void 0) e?.fillType === "solid" ? v = `#${e.color}` : _ = e;
1078
+ else if (n.lineColor) v = `#${n.lineColor}`;
1079
+ else if (d) _ = m === null ? null : m;
1080
1080
  else {
1081
- let e = s(p, m, u, r?.chartexStyle, n.chartexStyle);
1082
- e !== void 0 && (e?.fillType === "solid" ? b = `#${e.color}` : y = e);
1081
+ let e = D(f, p, c, r?.chartexStyle, n.chartexStyle);
1082
+ e !== void 0 && (e?.fillType === "solid" ? v = `#${e.color}` : _ = e);
1083
1083
  }
1084
1084
  }
1085
- let S = f ? void 0 : p, C = r?.chartexStyle?.lineCap ?? n.chartexStyle?.lineCap ?? S?.lineCap, w = r?.chartexStyle?.lineJoin ?? n.chartexStyle?.lineJoin ?? S?.lineJoin, T = l(r?.lineDash == null ? r?.chartexStyle : {
1085
+ let b = d ? void 0 : f, x = r?.chartexStyle?.lineCap ?? n.chartexStyle?.lineCap ?? b?.lineCap, S = r?.chartexStyle?.lineJoin ?? n.chartexStyle?.lineJoin ?? b?.lineJoin, C = L(r?.lineDash == null ? r?.chartexStyle : {
1086
1086
  lineDash: r.lineDash,
1087
1087
  lineDashAuthored: !0
1088
- }, n.chartexStyle, S);
1088
+ }, n.chartexStyle, b);
1089
1089
  return {
1090
- color: g,
1091
- fill: h,
1092
- lineColor: b,
1093
- lineFill: y,
1094
- lineWidthEmu: r?.lineWidthEmu ?? r?.chartexStyle?.lineWidthEmu ?? n.lineWidthEmu ?? n.chartexStyle?.lineWidthEmu ?? S?.lineWidthEmu,
1095
- lineDash: T?.lineDash,
1096
- lineCustomDash: T?.lineCustomDash,
1097
- lineCap: C === "rnd" ? "round" : C === "sq" ? "square" : "butt",
1098
- lineJoin: w === "round" || w === "bevel" ? w : "miter"
1090
+ color: h,
1091
+ fill: m,
1092
+ lineColor: v,
1093
+ lineFill: _,
1094
+ lineWidthEmu: r?.lineWidthEmu ?? r?.chartexStyle?.lineWidthEmu ?? n.lineWidthEmu ?? n.chartexStyle?.lineWidthEmu ?? b?.lineWidthEmu,
1095
+ lineDash: C?.lineDash,
1096
+ lineCustomDash: C?.lineCustomDash,
1097
+ lineCap: x === "rnd" ? "round" : x === "sq" ? "square" : "butt",
1098
+ lineJoin: S === "round" || S === "bevel" ? S : "miter"
1099
1099
  };
1100
1100
  }
1101
1101
  function Pt(e) {
@@ -1113,7 +1113,7 @@ function Ft(e, t) {
1113
1113
  }, i = Math.hypot(r.x, r.y, r.z), a = Math.max(0, (n.x * r.x + n.y * r.y + n.z * r.z) / i);
1114
1114
  return Math.max(.78, Math.min(1, .78 + .24 * a));
1115
1115
  }
1116
- var It = (e) => `"${e && !e.startsWith("+") ? e.replace(/["\\]/g, "") : "Arial"}"`, Lt = (e, t) => It(ve(e, t)), Rt = (e, t, n = "minor") => It((t?.startsWith("+mj-") ? e.themeMajorFontLatin : t?.startsWith("+mn-") ? e.themeMinorFontLatin : t) ?? (n === "major" ? e.themeMajorFontLatin : e.themeMinorFontLatin));
1116
+ var It = (e) => `"${e && !e.startsWith("+") ? e.replace(/["\\]/g, "") : "Arial"}"`, Lt = (e, t) => It(ge(e, t)), Rt = (e, t, n = "minor") => It((t?.startsWith("+mj-") ? e.themeMajorFontLatin : t?.startsWith("+mn-") ? e.themeMinorFontLatin : t) ?? (n === "major" ? e.themeMajorFontLatin : e.themeMinorFontLatin));
1117
1117
  function zt(e, t) {
1118
1118
  if (t.length) {
1119
1119
  e.beginPath(), e.moveTo(t[0].x, t[0].y);
@@ -1385,7 +1385,7 @@ function Gt(e, t, n, r, i, a, o) {
1385
1385
  return h;
1386
1386
  }
1387
1387
  function Kt(e, t) {
1388
- t.paint !== null && (t.paint === void 0 ? Vt(e, t.points, t.color, t.shade) : (zt(e, t.points), e.fillStyle = t.paint, e.fill()), t.outline && (e.strokeStyle = t.outlineColor ?? "rgba(0,0,0,0.42)", e.lineWidth = t.outlineWidth ?? .75, e.setLineDash(_e(t.outlineDash ?? "solid", e.lineWidth)), e.lineCap = t.outlineCap ?? "butt", e.lineJoin = t.outlineJoin ?? "miter", t.outline && (zt(e, t.points), e.stroke()), e.setLineDash([])));
1388
+ t.paint !== null && (t.paint === void 0 ? Vt(e, t.points, t.color, t.shade) : (zt(e, t.points), e.fillStyle = t.paint, e.fill()), t.outline && (e.strokeStyle = t.outlineColor ?? "rgba(0,0,0,0.42)", e.lineWidth = t.outlineWidth ?? .75, e.setLineDash(Se(t.outlineDash ?? "solid", e.lineWidth)), e.lineCap = t.outlineCap ?? "butt", e.lineJoin = t.outlineJoin ?? "miter", t.outline && (zt(e, t.points), e.stroke()), e.setLineDash([])));
1389
1389
  }
1390
1390
  function qt(e, t) {
1391
1391
  let n = t.filter((e) => e.paint !== null && e.points.length >= 3);
@@ -1407,7 +1407,7 @@ function Jt(e, t, n, r, i) {
1407
1407
  for (let e of a) e.paint = null;
1408
1408
  return;
1409
1409
  }
1410
- let o = a.flatMap((e) => e.points), s = Math.min(...o.map((e) => e.x)), c = Math.max(...o.map((e) => e.x)), l = Math.min(...o.map((e) => e.y)), u = Math.max(...o.map((e) => e.y)), d = Z(r, e, s, l, c - s, u - l, i);
1410
+ let o = a.flatMap((e) => e.points), s = Math.min(...o.map((e) => e.x)), c = Math.max(...o.map((e) => e.x)), l = Math.min(...o.map((e) => e.y)), u = Math.max(...o.map((e) => e.y)), d = se(r, e, s, l, c - s, u - l, i);
1411
1411
  for (let e of a) e.paint = d;
1412
1412
  }
1413
1413
  function Yt(e, t) {
@@ -1421,21 +1421,21 @@ function Zt(e) {
1421
1421
  return Math.max(e * 1.2, 10);
1422
1422
  }
1423
1423
  function Qt(e, t) {
1424
- let n = Math.max(1, ...e.map(le));
1424
+ let n = Math.max(1, ...e.map(R));
1425
1425
  return n > 1 ? (n - 1) * Zt(t) : 0;
1426
1426
  }
1427
1427
  function $t(e, t, n, r, i, a = 1, o = 6, s = 0) {
1428
1428
  if (i || r === 0) {
1429
- e.textAlign = i ? "right" : "center", e.textBaseline = i ? "middle" : a < 0 ? "bottom" : "top", Y(e, t, n.x + (i ? -o : 0), n.y + (i ? 0 : a * o), s);
1429
+ e.textAlign = i ? "right" : "center", e.textBaseline = i ? "middle" : a < 0 ? "bottom" : "top", B(e, t, n.x + (i ? -o : 0), n.y + (i ? 0 : a * o), s);
1430
1430
  return;
1431
1431
  }
1432
- e.save(), e.translate(n.x, n.y + a * o), e.rotate(r), e.textAlign = a < 0 ? "left" : "right", e.textBaseline = "middle", Y(e, t, 0, 0, s), e.restore();
1432
+ e.save(), e.translate(n.x, n.y + a * o), e.rotate(r), e.textAlign = a < 0 ? "left" : "right", e.textBaseline = "middle", B(e, t, 0, 0, s), e.restore();
1433
1433
  }
1434
- function en(e, t, n, r, i, a, o, s = void 0, c = 0, l = D, u = void 0, d = void 0, f = 0, p = f, m = void 0, h = void 0, g = void 0, _ = void 0, v = void 0) {
1434
+ function en(e, t, n, r, i, a, o, s = void 0, c = 0, l = U, u = void 0, d = void 0, f = 0, p = f, m = void 0, h = void 0, g = void 0, _ = void 0, v = void 0) {
1435
1435
  if (!(r > 0) || !Number.isFinite(t.x) || !Number.isFinite(t.y)) return;
1436
1436
  let y = r / 2;
1437
1437
  if (u !== void 0 || d !== void 0) {
1438
- E(e, u, d, f, {
1438
+ b(e, u, d, f, {
1439
1439
  x: t.x - y,
1440
1440
  y: t.y - y,
1441
1441
  w: r,
@@ -1444,8 +1444,8 @@ function en(e, t, n, r, i, a, o, s = void 0, c = 0, l = D, u = void 0, d = void
1444
1444
  return;
1445
1445
  }
1446
1446
  e.beginPath();
1447
- let b = m === void 0 ? a : m == null ? null : m.fillType === "solid" ? `#${m.color}` : Z(m, e, t.x - y, t.y - y, r, r, c);
1448
- switch (b && (e.strokeStyle = b, e.lineWidth = o, e.setLineDash(L(g, h, o)), e.lineCap = _ === "rnd" ? "round" : _ === "sq" ? "square" : "butt", e.lineJoin = v === "round" || v === "bevel" ? v : "miter"), n) {
1447
+ let S = m === void 0 ? a : m == null ? null : m.fillType === "solid" ? `#${m.color}` : se(m, e, t.x - y, t.y - y, r, r, c);
1448
+ switch (S && (e.strokeStyle = S, e.lineWidth = o, e.setLineDash(x(g, h, o)), e.lineCap = _ === "rnd" ? "round" : _ === "sq" ? "square" : "butt", e.lineJoin = v === "round" || v === "bevel" ? v : "miter"), n) {
1449
1449
  case "square":
1450
1450
  e.rect(t.x - y, t.y - y, r, r);
1451
1451
  break;
@@ -1458,7 +1458,7 @@ function en(e, t, n, r, i, a, o, s = void 0, c = 0, l = D, u = void 0, d = void
1458
1458
  case "x":
1459
1459
  case "plus": {
1460
1460
  let r = n === "x";
1461
- e.moveTo(t.x - y, t.y + (r ? -y : 0)), e.lineTo(t.x + y, t.y + (r ? y : 0)), e.moveTo(t.x + (r ? -y : 0), t.y + y), e.lineTo(t.x + (r ? y : 0), t.y - y), b && e.stroke();
1461
+ e.moveTo(t.x - y, t.y + (r ? -y : 0)), e.lineTo(t.x + y, t.y + (r ? y : 0)), e.moveTo(t.x + (r ? -y : 0), t.y + y), e.lineTo(t.x + (r ? y : 0), t.y - y), S && e.stroke();
1462
1462
  return;
1463
1463
  }
1464
1464
  case "dash":
@@ -1475,207 +1475,207 @@ function en(e, t, n, r, i, a, o, s = void 0, c = 0, l = D, u = void 0, d = void
1475
1475
  e.ellipse(t.x, t.y, r * .25, r * .1, 0, 0, Math.PI * 2);
1476
1476
  break;
1477
1477
  case "picture":
1478
- s?.fillType === "image" && me(e, s, t.x - y, t.y - y, r, r, l, c), b && e.strokeRect(t.x - y, t.y - y, r, r);
1478
+ s?.fillType === "image" && ue(e, s, t.x - y, t.y - y, r, r, l, c), S && e.strokeRect(t.x - y, t.y - y, r, r);
1479
1479
  return;
1480
1480
  default:
1481
1481
  e.arc(t.x, t.y, y, 0, Math.PI * 2);
1482
1482
  break;
1483
1483
  }
1484
- let x = s?.fillType === "image" ? s : void 0, S = x ? null : s === void 0 ? i === "transparent" ? null : i : s == null ? null : Z(s, e, t.x - y, t.y - y, r, r, c);
1485
- S == null ? x && (e.save(), e.clip(), me(e, x, t.x - y, t.y - y, r, r, l, c), e.restore()) : (e.fillStyle = S, e.fill()), b && e.stroke();
1486
- }
1487
- function tn(e, t, r, i, s, l, u, d, f, p = 0, m, h, g = "t", _ = u, y = !0, b, S, C = l, w = 0) {
1488
- let T = h, E = r.seriesDataLabels;
1489
- if (x(E, T) || t.showDataLabelsOverMax !== !0 && S != null && Number.isFinite(S) && C > S) return;
1490
- let D = T?.showVal ?? E?.showVal ?? t.showDataLabels, k = T?.showCatName ?? E?.showCatName ?? !1, A = T?.showSerName ?? E?.showSerName ?? !1, M = T?.showPercent ?? E?.showPercent ?? !1, N = T?.text, P = I({
1491
- customText: N,
1492
- showCategory: k,
1493
- showSeries: A,
1494
- showValue: D,
1484
+ let C = s?.fillType === "image" ? s : void 0, w = C ? null : s === void 0 ? i === "transparent" ? null : i : s == null ? null : se(s, e, t.x - y, t.y - y, r, r, c);
1485
+ w == null ? C && (e.save(), e.clip(), ue(e, C, t.x - y, t.y - y, r, r, l, c), e.restore()) : (e.fillStyle = w, e.fill()), S && e.stroke();
1486
+ }
1487
+ function tn(e, t, r, i, o, s, l, u, d, f = 0, m, h, g = "t", v = l, b = !0, x, S, C = s, w = 0) {
1488
+ let T = h, D = r.seriesDataLabels;
1489
+ if (p(D, T) || t.showDataLabelsOverMax !== !0 && S != null && Number.isFinite(S) && C > S) return;
1490
+ let k = T?.showVal ?? D?.showVal ?? t.showDataLabels, A = T?.showCatName ?? D?.showCatName ?? !1, j = T?.showSerName ?? D?.showSerName ?? !1, M = T?.showPercent ?? D?.showPercent ?? !1, P = T?.text, F = N({
1491
+ customText: P,
1492
+ showCategory: A,
1493
+ showSeries: j,
1494
+ showValue: k,
1495
1495
  showPercent: M,
1496
- category: r.categories?.[s] ?? t.categories[s] ?? `${s + 1}`,
1496
+ category: r.categories?.[o] ?? t.categories[o] ?? `${o + 1}`,
1497
1497
  seriesName: r.name || `Series ${i + 1}`,
1498
- sourceValue: l,
1499
- valueDivisor: b?.divisor,
1498
+ sourceValue: s,
1499
+ valueDivisor: x?.divisor,
1500
1500
  percentRatio: m != null && Number.isFinite(m) ? m : void 0,
1501
- formatCode: T?.formatCode ?? E?.formatCode ?? t.dataLabelFormatCode ?? r.valFormatCode,
1502
- percentFormatCode: T?.formatCode ?? E?.formatCode ?? t.dataLabelFormatCode ?? "0%",
1501
+ formatCode: T?.formatCode ?? D?.formatCode ?? t.dataLabelFormatCode ?? r.valFormatCode,
1502
+ percentFormatCode: T?.formatCode ?? D?.formatCode ?? t.dataLabelFormatCode ?? "0%",
1503
1503
  date1904: t.date1904,
1504
- separator: T?.separator ?? E?.separator
1504
+ separator: T?.separator ?? D?.separator
1505
1505
  });
1506
- if (!P) return;
1507
- let L = j(T?.fontSizeHpt ?? E?.fontSizeHpt ?? t.dataLabelFontSizeHpt, f) ?? 9 * f, R = T?.fontBold ?? E?.fontBold ?? t.dataLabelFontBold ?? !1, z = te(T, E), B = Rt(t, T?.fontFace ?? E?.fontFace ?? t.dataLabelFontFace);
1508
- e.font = `${z.fontItalic ? "italic " : ""}${R ? "bold " : ""}${L}px ${B}`;
1509
- let V = `#${T?.fontColor ?? E?.fontColor ?? r.labelColor ?? t.dataLabelFontColor ?? "111111"}`, H = N && T?.richRuns?.length ? Fe(e, {
1506
+ if (!F) return;
1507
+ let I = H(T?.fontSizeHpt ?? D?.fontSizeHpt ?? t.dataLabelFontSizeHpt, d) ?? 9 * d, L = T?.fontBold ?? D?.fontBold ?? t.dataLabelFontBold ?? !1, R = y(T, D), z = Rt(t, T?.fontFace ?? D?.fontFace ?? t.dataLabelFontFace);
1508
+ e.font = `${R.fontItalic ? "italic " : ""}${L ? "bold " : ""}${I}px ${z}`;
1509
+ let B = `#${T?.fontColor ?? D?.fontColor ?? r.labelColor ?? t.dataLabelFontColor ?? "111111"}`, V = P && T?.richRuns?.length ? Fe(e, {
1510
1510
  runs: T.richRuns,
1511
- ptToPx: f,
1512
- fontFamily: B,
1513
- fallbackBold: R,
1514
- fallbackItalic: z.fontItalic,
1515
- fallbackBaseline: z.fontBaseline,
1516
- fallbackColorHidden: z.fontPaintAuthored === !0 && (z.fontHidden === !0 || z.fontColor == null),
1511
+ ptToPx: d,
1512
+ fontFamily: z,
1513
+ fallbackBold: L,
1514
+ fallbackItalic: R.fontItalic,
1515
+ fallbackBaseline: R.fontBaseline,
1516
+ fallbackColorHidden: R.fontPaintAuthored === !0 && (R.fontHidden === !0 || R.fontColor == null),
1517
1517
  fontFamilyForFace: (e) => Rt(t, e)
1518
- }, L, V) : null, U = H ? [] : n(P, Math.max(L, d.w * .45), Math.max(L * 1.2, d.h * .35), L * 1.2, (t) => e.measureText(t).width, z);
1519
- if (!H && !U.length) return;
1520
- let W = H?.width ?? Math.max(...U.map((t) => e.measureText(t).width)), G = H?.height ?? U.length * L * 1.2, K = a(z, f), q = ee(W + K.left + K.right, G + K.top + K.bottom, z.textRotation, z.textVerticalMode), J = c({
1518
+ }, I, B) : null, U = V ? [] : be(F, Math.max(I, u.w * .45), Math.max(I * 1.2, u.h * .35), I * 1.2, (t) => e.measureText(t).width, R);
1519
+ if (!V && !U.length) return;
1520
+ let ee = V?.width ?? Math.max(...U.map((t) => e.measureText(t).width)), G = V?.height ?? U.length * I * 1.2, K = c(R, d), te = n(ee + K.left + K.right, G + K.top + K.bottom, R.textRotation, R.textVerticalMode), q = O({
1521
1521
  kind: "point",
1522
- x: u.x,
1523
- y: u.y,
1524
- position: T?.position ?? E?.position ?? t.dataLabelPosition ?? g,
1525
- markerGap: p
1526
- }, d, {
1527
- w: q.w,
1528
- h: q.h
1529
- }, L, T?.manualLayout, d);
1530
- if (!J) return;
1531
- let ne = he(T?.labelBox, E?.labelBox);
1532
- E?.showLeaderLines && E.leaderLineHidden !== !0 && y && (e.beginPath(), e.moveTo(_.x, _.y), e.lineTo(Math.max(J.rect.x, Math.min(_.x, J.rect.x + J.rect.w)), Math.max(J.rect.y, Math.min(_.y, J.rect.y + J.rect.h))), e.strokeStyle = `#${E.leaderLineColor ?? "808080"}`, e.lineWidth = E.leaderLineWidthEmu == null ? .75 * f : Math.max(.25, E.leaderLineWidthEmu / F * f), e.setLineDash(_e(E.leaderLineDash ?? "solid", e.lineWidth)), e.stroke()), ye(e, ne, J.rect, f, w), e.save(), e.beginPath(), e.rect(J.clip.x, J.clip.y, J.clip.w, J.clip.h), e.clip();
1533
- let Y = o(z, J.textAlign), re = O(J.x, J.y, J.rect, G + K.top + K.bottom, z, T?.manualLayout != null, Y, J.textAlign, W + K.left + K.right, q.radians), X = v(e, re.x, re.y, q.radians, Y, J.textBaseline, K);
1534
- if (H) {
1535
- Pe(e, H, X.x, X.y, Y, J.textBaseline, T?.manualLayout ? Math.max(0, J.rect.w - K.left - K.right) : H.width), e.restore();
1522
+ x: l.x,
1523
+ y: l.y,
1524
+ position: T?.position ?? D?.position ?? t.dataLabelPosition ?? g,
1525
+ markerGap: f
1526
+ }, u, {
1527
+ w: te.w,
1528
+ h: te.h
1529
+ }, I, T?.manualLayout, u);
1530
+ if (!q) return;
1531
+ let ne = pe(T?.labelBox, D?.labelBox);
1532
+ D?.showLeaderLines && D.leaderLineHidden !== !0 && b && (e.beginPath(), e.moveTo(v.x, v.y), e.lineTo(Math.max(q.rect.x, Math.min(v.x, q.rect.x + q.rect.w)), Math.max(q.rect.y, Math.min(v.y, q.rect.y + q.rect.h))), e.strokeStyle = `#${D.leaderLineColor ?? "808080"}`, e.lineWidth = D.leaderLineWidthEmu == null ? .75 * d : Math.max(.25, D.leaderLineWidthEmu / W * d), e.setLineDash(Se(D.leaderLineDash ?? "solid", e.lineWidth)), e.stroke()), ve(e, ne, q.rect, d, w), e.save(), e.beginPath(), e.rect(q.clip.x, q.clip.y, q.clip.w, q.clip.h), e.clip();
1533
+ let J = a(R, q.textAlign), Y = _(q.x, q.y, q.rect, G + K.top + K.bottom, R, T?.manualLayout != null, J, q.textAlign, ee + K.left + K.right, te.radians), X = E(e, Y.x, Y.y, te.radians, J, q.textBaseline, K);
1534
+ if (V) {
1535
+ Pe(e, V, X.x, X.y, J, q.textBaseline, T?.manualLayout ? Math.max(0, q.rect.w - K.left - K.right) : V.width), e.restore();
1536
1536
  return;
1537
1537
  }
1538
- if (!(z.fontPaintAuthored === !0 && (z.fontHidden === !0 || z.fontColor == null))) {
1539
- e.fillStyle = V, e.textAlign = Y, e.textBaseline = "middle";
1540
- let t = L * 1.2, n = (z.fontBaseline ?? 0) * L, r = X.y - (U.length - 1) * t / 2 - n;
1538
+ if (!(R.fontPaintAuthored === !0 && (R.fontHidden === !0 || R.fontColor == null))) {
1539
+ e.fillStyle = B, e.textAlign = J, e.textBaseline = "middle";
1540
+ let t = I * 1.2, n = (R.fontBaseline ?? 0) * I, r = X.y - (U.length - 1) * t / 2 - n;
1541
1541
  U.forEach((n, i) => e.fillText(n, X.x, r + i * t));
1542
1542
  }
1543
1543
  e.restore();
1544
1544
  }
1545
1545
  function nn(e, t, n) {
1546
1546
  let r = t.seriesDataLabels;
1547
- return x(r, n) ? !1 : n?.text ? !0 : (n?.showVal ?? r?.showVal ?? e.showDataLabels) || (n?.showCatName ?? r?.showCatName ?? !1) || (n?.showSerName ?? r?.showSerName ?? !1) || (n?.showPercent ?? r?.showPercent ?? !1);
1548
- }
1549
- function rn(t, n, r, i, a, o) {
1550
- let s = d(n, r.h, i), c = n.titleRichRuns?.length ? {
1551
- ...s,
1552
- bandH: s.bandH + z(n.title, s.fontPx)
1553
- } : s;
1554
- if (n.title) {
1555
- t.font = `${n.titleFontBold === !1 ? "" : "bold "}${c.fontPx}px ${Lt(n, n.titleFontFace)}`, t.fillStyle = n.titleFontColor ? `#${n.titleFontColor}` : "#111111", t.textAlign = "center", t.textBaseline = "top";
1556
- let i = R(t, n.title), a = {
1557
- x: r.x + (r.w - i) / 2,
1558
- y: r.y + c.topPad,
1559
- w: i,
1560
- h: Math.max(1, c.fontPx) + z(n.title, c.fontPx)
1561
- }, o = n.titleManualLayout ? e({
1562
- ...n.titleManualLayout,
1547
+ return p(r, n) ? !1 : n?.text ? !0 : (n?.showVal ?? r?.showVal ?? e.showDataLabels) || (n?.showCatName ?? r?.showCatName ?? !1) || (n?.showSerName ?? r?.showSerName ?? !1) || (n?.showPercent ?? r?.showPercent ?? !1);
1548
+ }
1549
+ function rn(e, t, n, r, i, a) {
1550
+ let o = j(t, n.h, r), s = t.titleRichRuns?.length ? {
1551
+ ...o,
1552
+ bandH: o.bandH + G(t.title, o.fontPx)
1553
+ } : o;
1554
+ if (t.title) {
1555
+ e.font = `${t.titleFontBold === !1 ? "" : "bold "}${s.fontPx}px ${Lt(t, t.titleFontFace)}`, e.fillStyle = t.titleFontColor ? `#${t.titleFontColor}` : "#111111", e.textAlign = "center", e.textBaseline = "top";
1556
+ let r = M(e, t.title), i = {
1557
+ x: n.x + (n.w - r) / 2,
1558
+ y: n.y + s.topPad,
1559
+ w: r,
1560
+ h: Math.max(1, s.fontPx) + G(t.title, s.fontPx)
1561
+ }, a = t.titleManualLayout ? P({
1562
+ ...t.titleManualLayout,
1563
1563
  w: void 0,
1564
1564
  h: void 0
1565
- }, r, a) : null;
1566
- Y(t, n.title, o ? o.x + o.w / 2 : r.x + r.w / 2, o?.y ?? a.y, c.fontPx);
1565
+ }, n, i) : null;
1566
+ B(e, t.title, a ? a.x + a.w / 2 : n.x + n.w / 2, a?.y ?? i.y, s.fontPx);
1567
1567
  }
1568
- let l = yt(n);
1569
- t.save();
1570
- let f = (n.chartType === "pie" ? n.series[0]?.categories?.length ? n.series[0].categories : n.categories : n.series.map((e, t) => e.name || `Series ${t + 1}`)).flatMap((e, t) => l.get(t)?.deleted === !0 ? [] : [{
1568
+ let c = yt(t);
1569
+ e.save();
1570
+ let l = (t.chartType === "pie" ? t.series[0]?.categories?.length ? t.series[0].categories : t.categories : t.series.map((e, t) => e.name || `Series ${t + 1}`)).flatMap((e, t) => c.get(t)?.deleted === !0 ? [] : [{
1571
1571
  label: e,
1572
1572
  index: t
1573
- }]), m = f.map((e) => bt(n, l.get(e.index), i)), g = Math.max(0, ...m.map((e) => e.fontPx)), _ = f.map((e, n) => (t.font = m[n].font, 7 * i + 4 + R(t, e.label))), v = se(n, r.w, r.h, {
1574
- itemWidths: _,
1575
- rowHeight: Math.max(g * 1.45, 12) + Qt(f.map((e) => e.label), g),
1573
+ }]), d = l.map((e) => bt(t, c.get(e.index), r)), p = Math.max(0, ...d.map((e) => e.fontPx)), m = l.map((t, n) => (e.font = d[n].font, 7 * r + 4 + M(e, t.label))), h = ne(t, n.w, n.h, {
1574
+ itemWidths: m,
1575
+ rowHeight: Math.max(p * 1.45, 12) + Qt(l.map((e) => e.label), p),
1576
1576
  itemGap: 12,
1577
1577
  horizontalPadding: 8,
1578
1578
  verticalPadding: 4
1579
1579
  });
1580
- t.restore();
1581
- let y = p(v, n.legendOverlay === !0), b = u(n, r.w, r.h, i), x = k(n.catAxisTitleTextVerticalInsetEmu, i), S = k(n.valAxisTitleTextVerticalInsetEmu, i), C = a === "horizontal" ? n.catAxisTitle ? b.catFontPx + x + xe(r.w) + 4 + h(n.catAxisTitle, b.catFontPx, "left", n.catAxisTitleRotation, n.catAxisTitleVerticalMode) : 0 : a === "vertical" ? b.valBandW : 0, w = a === "horizontal" ? n.valAxisTitle ? b.valFontPx + S + xe(r.h) + 4 + h(n.valAxisTitle, b.valFontPx, "horizontal", n.valAxisTitleRotation, n.valAxisTitleVerticalMode) : 0 : a === "vertical" ? b.catBandH : 0, T = M(n, r.x, r.y, r.w, r.h, i, {
1582
- titleBand: c,
1583
- legendReserve: v,
1580
+ e.restore();
1581
+ let g = le(h, t.legendOverlay === !0), _ = I(t, n.w, n.h, r), v = k(t.catAxisTitleTextVerticalInsetEmu, r), y = k(t.valAxisTitleTextVerticalInsetEmu, r), b = i === "horizontal" ? t.catAxisTitle ? _.catFontPx + v + u(n.w) + 4 + f(t.catAxisTitle, _.catFontPx, "left", t.catAxisTitleRotation, t.catAxisTitleVerticalMode) : 0 : i === "vertical" ? _.valBandW : 0, x = i === "horizontal" ? t.valAxisTitle ? _.valFontPx + y + u(n.h) + 4 + f(t.valAxisTitle, _.valFontPx, "horizontal", t.valAxisTitleRotation, t.valAxisTitleVerticalMode) : 0 : i === "vertical" ? _.catBandH : 0, S = Y(t, n.x, n.y, n.w, n.h, r, {
1582
+ titleBand: s,
1583
+ legendReserve: h,
1584
1584
  pad: {
1585
- t: c.bandH + y.legTopH + r.h * .04,
1586
- r: y.legRightW + r.w * .05,
1587
- b: y.legBottomH + r.h * .19 + w,
1588
- l: y.legLeftW + r.w * .13 + C
1585
+ t: s.bandH + g.legTopH + n.h * .04,
1586
+ r: g.legRightW + n.w * .05,
1587
+ b: g.legBottomH + n.h * .19 + x,
1588
+ l: g.legLeftW + n.w * .13 + b
1589
1589
  },
1590
1590
  honorPlotAreaManualLayout: !0,
1591
1591
  manualOuterInsets: {
1592
- t: c.bandH,
1593
- r: y.legRightW,
1594
- b: y.legBottomH + w,
1595
- l: y.legLeftW + C
1592
+ t: s.bandH,
1593
+ r: g.legRightW,
1594
+ b: g.legBottomH + x,
1595
+ l: g.legLeftW + b
1596
1596
  }
1597
- }), E = {
1598
- x: T.plotRect.px0,
1599
- y: T.plotRect.py0,
1600
- w: Math.max(1, T.plotRect.pw),
1601
- h: Math.max(1, T.plotRect.ph)
1597
+ }), C = {
1598
+ x: S.plotRect.px0,
1599
+ y: S.plotRect.py0,
1600
+ w: Math.max(1, S.plotRect.pw),
1601
+ h: Math.max(1, S.plotRect.ph)
1602
1602
  };
1603
- fe(t, n, E.x, E.y, E.w, E.h, i, o);
1604
- let D = v ? v.side === "r" ? {
1605
- x: r.x + r.w - v.reserveW,
1606
- y: E.y,
1607
- w: v.reserveW,
1608
- h: E.h
1609
- } : v.side === "l" ? {
1610
- x: r.x,
1611
- y: E.y,
1612
- w: v.reserveW,
1613
- h: E.h
1614
- } : v.side === "t" ? {
1615
- x: r.x + 4,
1616
- y: r.y + c.bandH,
1617
- w: Math.max(1, r.w - 8),
1618
- h: v.reserveH
1603
+ ce(e, t, C.x, C.y, C.w, C.h, r, a);
1604
+ let w = h ? h.side === "r" ? {
1605
+ x: n.x + n.w - h.reserveW,
1606
+ y: C.y,
1607
+ w: h.reserveW,
1608
+ h: C.h
1609
+ } : h.side === "l" ? {
1610
+ x: n.x,
1611
+ y: C.y,
1612
+ w: h.reserveW,
1613
+ h: C.h
1614
+ } : h.side === "t" ? {
1615
+ x: n.x + 4,
1616
+ y: n.y + s.bandH,
1617
+ w: Math.max(1, n.w - 8),
1618
+ h: h.reserveH
1619
1619
  } : {
1620
- x: r.x + 4,
1621
- y: r.y + r.h - v.reserveH,
1622
- w: Math.max(1, r.w - 8),
1623
- h: v.reserveH
1620
+ x: n.x + 4,
1621
+ y: n.y + n.h - h.reserveH,
1622
+ w: Math.max(1, n.w - 8),
1623
+ h: h.reserveH
1624
1624
  } : null;
1625
1625
  return {
1626
- plot: E,
1627
- legend: (D && n.legendManualLayout ? e(n.legendManualLayout, r, D) : null) ?? D,
1626
+ plot: C,
1627
+ legend: (w && t.legendManualLayout ? P(t.legendManualLayout, n, w) : null) ?? w,
1628
1628
  legendMeasure: {
1629
- labels: f.map((e) => e.label),
1630
- styles: m,
1631
- itemWidths: _
1629
+ labels: l.map((e) => e.label),
1630
+ styles: d,
1631
+ itemWidths: m
1632
1632
  }
1633
1633
  };
1634
1634
  }
1635
- function an(t, n, i, a, o, s, c, l, u, d, f, p, m, h) {
1636
- t.save(), t.font = `${d ? "italic " : ""}${u ? "bold " : ""}${s}px ${c}`, t.fillStyle = l ? `#${l}` : "#555";
1637
- let g = m ? n : on(t, n, h), _ = r(o, f, p), v = a;
1638
- if (m) {
1639
- let n = R(t, g), r = s + z(g, s), o = Math.abs(Math.cos(_)), c = Math.abs(Math.sin(_)), l = {
1640
- x: a.x - (n * o + r * c) / 2,
1641
- y: a.y - (n * c + r * o) / 2,
1642
- w: n * o + r * c,
1643
- h: n * c + r * o
1644
- }, u = e({
1645
- ...m,
1635
+ function an(e, t, n, r, i, a, o, s, c, l, u, d, f, p) {
1636
+ e.save(), e.font = `${l ? "italic " : ""}${c ? "bold " : ""}${a}px ${o}`, e.fillStyle = s ? `#${s}` : "#555";
1637
+ let m = f ? t : on(e, t, p), h = A(i, u, d), g = r;
1638
+ if (f) {
1639
+ let t = M(e, m), i = a + G(m, a), o = Math.abs(Math.cos(h)), s = Math.abs(Math.sin(h)), c = {
1640
+ x: r.x - (t * o + i * s) / 2,
1641
+ y: r.y - (t * s + i * o) / 2,
1642
+ w: t * o + i * s,
1643
+ h: t * s + i * o
1644
+ }, l = P({
1645
+ ...f,
1646
1646
  w: void 0,
1647
1647
  h: void 0
1648
- }, i, l);
1649
- u && (v = {
1650
- x: u.x + u.w / 2,
1651
- y: u.y + u.h / 2
1648
+ }, n, c);
1649
+ l && (g = {
1650
+ x: l.x + l.w / 2,
1651
+ y: l.y + l.h / 2
1652
1652
  });
1653
1653
  }
1654
- t.translate(v.x, v.y), _ && t.rotate(_), t.textAlign = "center", t.textBaseline = "middle", Y(t, g, 0, 0, s), t.restore();
1654
+ e.translate(g.x, g.y), h && e.rotate(h), e.textAlign = "center", e.textBaseline = "middle", B(e, m, 0, 0, a), e.restore();
1655
1655
  }
1656
1656
  function on(e, t, n) {
1657
- let r = V(t);
1658
- return r.length === 1 ? G(e, t, n) : r.map((t) => G(e, t, n)).join("\n");
1657
+ let r = re(t);
1658
+ return r.length === 1 ? de(e, t, n) : r.map((t) => de(e, t, n)).join("\n");
1659
1659
  }
1660
1660
  function sn(e, t, n, r, i, a) {
1661
1661
  if (t.valAxisTitle) {
1662
- let o = T(t.valAxisTitleFontSizeHpt, a), s = i ? "horizontal" : "left", c = h(t.valAxisTitle, o, s, t.valAxisTitleRotation, t.valAxisTitleVerticalMode) / 2;
1662
+ let o = Z(t.valAxisTitleFontSizeHpt, a), s = i ? "horizontal" : "left", c = f(t.valAxisTitle, o, s, t.valAxisTitleRotation, t.valAxisTitleVerticalMode) / 2;
1663
1663
  an(e, t.valAxisTitle, n, i ? {
1664
1664
  x: r.x + r.w / 2,
1665
- y: r.y + r.h + xe(n.h) + o / 2 + c
1665
+ y: r.y + r.h + u(n.h) + o / 2 + c
1666
1666
  } : {
1667
- x: r.x - xe(n.w) - o / 2 - c,
1667
+ x: r.x - u(n.w) - o / 2 - c,
1668
1668
  y: r.y + r.h / 2
1669
1669
  }, s, o, Rt(t, t.valAxisTitleFontFace, "major"), t.valAxisTitleFontColor, t.valAxisTitleFontBold ?? !0, t.valAxisTitleFontItalic ?? !1, t.valAxisTitleRotation, t.valAxisTitleVerticalMode, t.valAxisTitleManualLayout, i ? r.w : r.h);
1670
1670
  }
1671
1671
  if (t.catAxisTitle) {
1672
- let o = T(t.catAxisTitleFontSizeHpt, a), s = i ? "left" : "horizontal", c = h(t.catAxisTitle, o, s, t.catAxisTitleRotation, t.catAxisTitleVerticalMode) / 2;
1672
+ let o = Z(t.catAxisTitleFontSizeHpt, a), s = i ? "left" : "horizontal", c = f(t.catAxisTitle, o, s, t.catAxisTitleRotation, t.catAxisTitleVerticalMode) / 2;
1673
1673
  an(e, t.catAxisTitle, n, i ? {
1674
- x: r.x - xe(n.w) - o / 2 - c,
1674
+ x: r.x - u(n.w) - o / 2 - c,
1675
1675
  y: r.y + r.h / 2
1676
1676
  } : {
1677
1677
  x: r.x + r.w / 2,
1678
- y: r.y + r.h + xe(n.h) + o / 2 + c
1678
+ y: r.y + r.h + u(n.h) + o / 2 + c
1679
1679
  }, s, o, Rt(t, t.catAxisTitleFontFace, "major"), t.catAxisTitleFontColor, t.catAxisTitleFontBold ?? !0, t.catAxisTitleFontItalic ?? !1, t.catAxisTitleRotation, t.catAxisTitleVerticalMode, t.catAxisTitleManualLayout, i ? r.h : r.w);
1680
1680
  }
1681
1681
  }
@@ -1701,98 +1701,98 @@ function cn(e, t, n, r, i, a, o, s, c, l, u) {
1701
1701
  x: -b.x,
1702
1702
  y: -b.y
1703
1703
  }), d.lineHidden || (yn(e, _n(d.lineColor, d.lineWidthEmu, d.lineDash, u)), e.beginPath(), e.moveTo(g.x, g.y), e.lineTo(_.x, _.y), e.stroke());
1704
- let C = Math.max(1, Math.floor(d.tickMarkSkip ?? 1)), w = Math.max(1, Math.floor(d.tickLabelSkip ?? 1)), E = d.majorTickMark ?? "out", D = j(d.fontSizeHpt, u) ?? 9 * u;
1705
- if (e.font = `${d.fontItalic ? "italic " : ""}${d.fontBold ? "bold " : ""}${D}px ${Rt(t, d.fontFace)}`, e.fillStyle = d.fontColor ? `#${d.fontColor}` : "#595959", e.textAlign = Math.abs(b.x) < .2 ? "center" : b.x < 0 ? "right" : "left", e.textBaseline = Math.abs(b.y) < .2 ? "middle" : b.y < 0 ? "bottom" : "top", l && !d.lineHidden && E !== "none") {
1704
+ let C = Math.max(1, Math.floor(d.tickMarkSkip ?? 1)), w = Math.max(1, Math.floor(d.tickLabelSkip ?? 1)), T = d.majorTickMark ?? "out", E = H(d.fontSizeHpt, u) ?? 9 * u;
1705
+ if (e.font = `${d.fontItalic ? "italic " : ""}${d.fontBold ? "bold " : ""}${E}px ${Rt(t, d.fontFace)}`, e.fillStyle = d.fontColor ? `#${d.fontColor}` : "#595959", e.textAlign = Math.abs(b.x) < .2 ? "center" : b.x < 0 ? "right" : "left", e.textBaseline = Math.abs(b.y) < .2 ? "middle" : b.y < 0 ? "bottom" : "top", l && !d.lineHidden && T !== "none") {
1706
1706
  yn(e, vn(d.lineColor, d.lineWidthEmu, d.lineDash, u));
1707
1707
  let n = t.series.length;
1708
1708
  for (let t = 0; t <= n; t += C) {
1709
- let i = t / n, a = d.orientation === "maxMin" ? 1 - i : i, o = r.project(m, h, a), s = 6 * u, c = E === "cross" ? s / 2 : E === "out" ? s : 0, l = E === "cross" ? s / 2 : E === "in" ? s : 0;
1709
+ let i = t / n, a = d.orientation === "maxMin" ? 1 - i : i, o = r.project(m, h, a), s = 6 * u, c = T === "cross" ? s / 2 : T === "out" ? s : 0, l = T === "cross" ? s / 2 : T === "in" ? s : 0;
1710
1710
  e.beginPath(), e.moveTo(o.x + b.x * c, o.y + b.y * c), e.lineTo(o.x - b.x * l, o.y - b.y * l), e.stroke();
1711
1711
  }
1712
1712
  }
1713
1713
  for (let n = 0; n < t.series.length; n++) {
1714
1714
  let i = r.seriesDepth(n, t.series.length, !1), a = d.orientation === "maxMin" ? 1 - i : i, o = r.project(m, h, a);
1715
- if (!l && !d.lineHidden && n % C === 0 && E !== "none") {
1716
- let t = 6 * u, n = E === "cross" ? t / 2 : E === "out" ? t : 0, r = E === "cross" ? t / 2 : E === "in" ? t : 0;
1715
+ if (!l && !d.lineHidden && n % C === 0 && T !== "none") {
1716
+ let t = 6 * u, n = T === "cross" ? t / 2 : T === "out" ? t : 0, r = T === "cross" ? t / 2 : T === "in" ? t : 0;
1717
1717
  e.beginPath(), e.moveTo(o.x + b.x * n, o.y + b.y * n), e.lineTo(o.x - b.x * r, o.y - b.y * r), e.stroke();
1718
1718
  }
1719
- d.tickLabelPos !== "none" && n % w === 0 && Y(e, t.series[n].name || `Series ${n + 1}`, o.x + b.x * (6 * u + 3), o.y + b.y * (6 * u + 3), N(D));
1719
+ d.tickLabelPos !== "none" && n % w === 0 && B(e, t.series[n].name || `Series ${n + 1}`, o.x + b.x * (6 * u + 3), o.y + b.y * (6 * u + 3), K(E));
1720
1720
  }
1721
1721
  if (e.setLineDash([]), d.title) {
1722
- let i = T(d.titleFontSizeHpt, u), a = D + i + 12 + ne(t.series.map((e, t) => e.name || `Series ${t + 1}`), N(D)) + z(d.title, i) / 2;
1722
+ let i = Z(d.titleFontSizeHpt, u), a = E + i + 12 + F(t.series.map((e, t) => e.name || `Series ${t + 1}`), K(E)) + G(d.title, i) / 2;
1723
1723
  an(e, d.title, n, {
1724
1724
  x: S.x + b.x * a,
1725
1725
  y: S.y + b.y * a
1726
1726
  }, "horizontal", i, Rt(t, d.titleFontFace, "major"), d.titleFontColor, d.titleFontBold ?? !0, d.titleFontItalic ?? !1, d.titleRotation, d.titleVerticalMode, d.titleManualLayout, Math.max(r.front.w, r.front.h));
1727
1727
  }
1728
1728
  }
1729
- function ln(e, n, r, i, a, o, s) {
1730
- let c = be(e, "dataPointMarker", a), u = oe(e, "dataPointMarker"), d = n.chartexFormatIdx ?? a, p = U(r?.markerStyle, u, i), m = U(n.markerStyle, u, d), h = p !== void 0 || r?.markerFillPaint !== void 0 || r?.markerFill != null || r?.color != null || r?.markerFillPaintAuthored === !0 && r.markerStyle?.fillHidden !== !0, _ = m !== void 0 || n.markerFillPaint !== void 0 || n.markerFill != null || n.markerFillPaintAuthored === !0 && n.markerStyle?.fillHidden !== !0, v = y(c, u, d), b = h ? p ?? r?.markerFillPaint : _ ? m ?? n.markerFillPaint : v, x = ue(n, r, i, o), S = b;
1729
+ function ln(e, t, n, r, i, a, c) {
1730
+ let u = l(e, "dataPointMarker", i), d = J(e, "dataPointMarker"), f = t.chartexFormatIdx ?? i, p = v(n?.markerStyle, d, r), h = v(t.markerStyle, d, f), g = p !== void 0 || n?.markerFillPaint !== void 0 || n?.markerFill != null || n?.color != null || n?.markerFillPaintAuthored === !0 && n.markerStyle?.fillHidden !== !0, _ = h !== void 0 || t.markerFillPaint !== void 0 || t.markerFill != null || t.markerFillPaintAuthored === !0 && t.markerStyle?.fillHidden !== !0, y = s(u, d, f), b = g ? p ?? n?.markerFillPaint : _ ? h ?? t.markerFillPaint : y, x = z(t, n, r, a), S = b;
1731
1731
  b?.fillType === "solid" ? (x = b.color, S = void 0) : b === null && (x = "00000000");
1732
- let C = t(r?.markerStyle, u, i), w = t(n.markerStyle, u, d), T = C !== void 0 || r?.markerLine != null || r?.markerLinePaintAuthored === !0 && r.markerStyle?.lineHidden !== !0, E = w !== void 0 || n.markerLine != null || n.markerLinePaintAuthored === !0 && n.markerStyle?.lineHidden !== !0, D = f(c, d), O = T ? C ?? (r?.markerLinePaintAuthored === !0 ? null : void 0) : E ? w ?? (n.markerLinePaintAuthored === !0 ? null : void 0) : D, k = r?.markerLine ?? n.markerLine ?? n.lineColor ?? o, A = O;
1732
+ let C = ye(n?.markerStyle, d, r), w = ye(t.markerStyle, d, f), T = C !== void 0 || n?.markerLine != null || n?.markerLinePaintAuthored === !0 && n.markerStyle?.lineHidden !== !0, E = w !== void 0 || t.markerLine != null || t.markerLinePaintAuthored === !0 && t.markerStyle?.lineHidden !== !0, D = o(u, f), O = T ? C ?? (n?.markerLinePaintAuthored === !0 ? null : void 0) : E ? w ?? (t.markerLinePaintAuthored === !0 ? null : void 0) : D, k = n?.markerLine ?? t.markerLine ?? t.lineColor ?? a, A = O;
1733
1733
  O?.fillType === "solid" ? (k = O.color, A = void 0) : O === null && (k = "00000000");
1734
- let j = r?.markerStyle ?? n.markerStyle ?? c, M = l(r?.markerStyle, n.markerStyle, c);
1734
+ let j = n?.markerStyle ?? t.markerStyle ?? u, M = L(n?.markerStyle, t.markerStyle, u);
1735
1735
  return {
1736
1736
  fill: x,
1737
1737
  fillPaint: S,
1738
1738
  line: k,
1739
1739
  linePaint: A,
1740
- lineWidth: (r?.markerLineWidthEmu ?? n.markerLineWidthEmu ?? j?.lineWidthEmu) == null ? Math.max(.75, s) : Math.max(.25, (r?.markerLineWidthEmu ?? n.markerLineWidthEmu ?? j?.lineWidthEmu ?? 0) / F * s),
1740
+ lineWidth: (n?.markerLineWidthEmu ?? t.markerLineWidthEmu ?? j?.lineWidthEmu) == null ? Math.max(.75, c) : Math.max(.25, (n?.markerLineWidthEmu ?? t.markerLineWidthEmu ?? j?.lineWidthEmu ?? 0) / W * c),
1741
1741
  lineDash: M?.lineDash,
1742
1742
  lineCustomDash: M?.lineCustomDash,
1743
1743
  lineCap: j?.lineCap,
1744
1744
  lineJoin: j?.lineJoin,
1745
- effectDirect: g(r?.markerStyle, r?.chartexStyle, n.markerStyle),
1746
- effectFallback: c,
1747
- effectIndex: r?.markerStyle || r?.chartexStyle ? i : d,
1748
- effectFallbackIndex: d
1745
+ effectDirect: m(n?.markerStyle, n?.chartexStyle, t.markerStyle),
1746
+ effectFallback: u,
1747
+ effectIndex: n?.markerStyle || n?.chartexStyle ? r : f,
1748
+ effectFallbackIndex: f
1749
1749
  };
1750
1750
  }
1751
- function un(e, t, n, r, i, a, o, s, c, l, u, d) {
1752
- let f = $(t, n, r, i, a, d), p = Le(t, n, i, a), m = {
1751
+ function un(e, t, n, r, i, a, o, s, c, u, d, f) {
1752
+ let p = $(t, n, r, i, a, f), h = Le(t, n, i, a), g = {
1753
1753
  x: o,
1754
1754
  y: s - c / 2,
1755
1755
  w: c,
1756
1756
  h: c
1757
- }, h = (e) => {
1758
- if (f.fill !== null) {
1759
- let t = f.fill === void 0 ? f.color : f.fill.fillType === "image" ? null : Z(f.fill, e, m.x, m.y, m.w, m.h, u);
1760
- t && (e.fillStyle = t, e.fillRect(m.x, m.y, m.w, m.h));
1757
+ }, _ = (e) => {
1758
+ if (p.fill !== null) {
1759
+ let t = p.fill === void 0 ? p.color : p.fill.fillType === "image" ? null : se(p.fill, e, g.x, g.y, g.w, g.h, d);
1760
+ t && (e.fillStyle = t, e.fillRect(g.x, g.y, g.w, g.h));
1761
1761
  }
1762
- let t = f.lineFill === void 0 ? f.lineColor : f.lineFill == null || f.lineFill.fillType === "image" ? null : Z(f.lineFill, e, m.x, m.y, m.w, m.h, u);
1763
- t && (e.strokeStyle = t, e.lineWidth = f.lineWidthEmu == null ? .75 * l : Math.max(.25, f.lineWidthEmu / F * l), e.setLineDash(L(f.lineCustomDash, f.lineDash, e.lineWidth)), e.lineCap = f.lineCap, e.lineJoin = f.lineJoin, e.strokeRect(m.x, m.y, m.w, m.h), e.setLineDash([]));
1764
- }, _ = g(r?.chartexStyle, n.chartexStyle);
1765
- E(e, _, be(t, "dataPoint3D", a), _ === r?.chartexStyle ? i : p, m, l, h, p);
1762
+ let t = p.lineFill === void 0 ? p.lineColor : p.lineFill == null || p.lineFill.fillType === "image" ? null : se(p.lineFill, e, g.x, g.y, g.w, g.h, d);
1763
+ t && (e.strokeStyle = t, e.lineWidth = p.lineWidthEmu == null ? .75 * u : Math.max(.25, p.lineWidthEmu / W * u), e.setLineDash(x(p.lineCustomDash, p.lineDash, e.lineWidth)), e.lineCap = p.lineCap, e.lineJoin = p.lineJoin, e.strokeRect(g.x, g.y, g.w, g.h), e.setLineDash([]));
1764
+ }, v = m(r?.chartexStyle, n.chartexStyle);
1765
+ b(e, v, l(t, "dataPoint3D", a), v === r?.chartexStyle ? i : h, g, u, _, h);
1766
1766
  }
1767
- function dn(e, t, n, r, i, a, o, s, c, l) {
1768
- let u = $(t, n, void 0, r, r, !1), d = u.lineFill === void 0 ? u.lineColor == null ? u.fill : {
1767
+ function dn(e, t, n, r, i, a, o, s, c, u) {
1768
+ let d = $(t, n, void 0, r, r, !1), f = d.lineFill === void 0 ? d.lineColor == null ? d.fill : {
1769
1769
  fillType: "solid",
1770
- color: u.lineColor.replace(/^#/, "")
1771
- } : u.lineFill;
1772
- if (d !== null) {
1773
- let i = u.lineWidthEmu == null ? Math.max(1, 2 * c) : Math.max(.5, u.lineWidthEmu / F * c), f = {
1770
+ color: d.lineColor.replace(/^#/, "")
1771
+ } : d.lineFill;
1772
+ if (f !== null) {
1773
+ let i = d.lineWidthEmu == null ? Math.max(1, 2 * c) : Math.max(.5, d.lineWidthEmu / W * c), p = {
1774
1774
  x: a,
1775
1775
  y: o - i / 2,
1776
1776
  w: s,
1777
1777
  h: i
1778
- }, p = d === void 0 ? u.color : d.fillType === "image" ? null : d.fillType === "solid" ? `#${d.color}` : Z(d, e, a, o - i / 2, s, i, l);
1779
- if (p) {
1780
- let m = (t) => {
1781
- t.beginPath(), t.moveTo(a, o), t.lineTo(a + s, o), t.strokeStyle = t === e ? p : d === void 0 ? u.color : d.fillType === "image" ? "rgba(0,0,0,0)" : d.fillType === "solid" ? `#${d.color}` : Z(d, t, a, o - i / 2, s, i, l) ?? "rgba(0,0,0,0)", t.lineWidth = i, t.setLineDash(L(u.lineCustomDash, u.lineDash, i)), t.stroke(), t.setLineDash([]);
1782
- }, h = Le(t, n, r, r);
1783
- E(e, g(n.chartexStyle), be(t, "dataPoint3D", r), h, f, c, m, h);
1778
+ }, h = f === void 0 ? d.color : f.fillType === "image" ? null : f.fillType === "solid" ? `#${f.color}` : se(f, e, a, o - i / 2, s, i, u);
1779
+ if (h) {
1780
+ let g = (t) => {
1781
+ t.beginPath(), t.moveTo(a, o), t.lineTo(a + s, o), t.strokeStyle = t === e ? h : f === void 0 ? d.color : f.fillType === "image" ? "rgba(0,0,0,0)" : f.fillType === "solid" ? `#${f.color}` : se(f, t, a, o - i / 2, s, i, u) ?? "rgba(0,0,0,0)", t.lineWidth = i, t.setLineDash(x(d.lineCustomDash, d.lineDash, i)), t.stroke(), t.setLineDash([]);
1782
+ }, _ = Le(t, n, r, r);
1783
+ b(e, m(n.chartexStyle), l(t, "dataPoint3D", r), _, p, c, g, _);
1784
1784
  }
1785
1785
  }
1786
1786
  if (n.showMarker !== !0 || n.markerSymbol === "none") return;
1787
- let f = n.markerSymbol ?? "circle", p = ln(t, n, void 0, r, r, i.replace(/^#/, ""), c);
1787
+ let p = n.markerSymbol ?? "circle", h = ln(t, n, void 0, r, r, i.replace(/^#/, ""), c);
1788
1788
  en(e, {
1789
1789
  x: a + s / 2,
1790
1790
  y: o
1791
- }, f, Math.min(s, Math.max(2, (n.markerSize ?? 5) * c)), p.fill === "00000000" ? "transparent" : `#${p.fill.replace(/^#/, "")}`, p.line === "00000000" ? "rgba(0,0,0,0)" : `#${p.line.replace(/^#/, "")}`, p.lineWidth, p.fillPaint, l, c, p.effectDirect, p.effectFallback, p.effectIndex, p.effectFallbackIndex, p.linePaint, p.lineDash, p.lineCustomDash, p.lineCap, p.lineJoin);
1791
+ }, p, Math.min(s, Math.max(2, (n.markerSize ?? 5) * c)), h.fill === "00000000" ? "transparent" : `#${h.fill.replace(/^#/, "")}`, h.line === "00000000" ? "rgba(0,0,0,0)" : `#${h.line.replace(/^#/, "")}`, h.lineWidth, h.fillPaint, u, c, h.effectDirect, h.effectFallback, h.effectIndex, h.effectFallbackIndex, h.linePaint, h.lineDash, h.lineCustomDash, h.lineCap, h.lineJoin);
1792
1792
  }
1793
1793
  function fn(e, t, n, r, i = !1, a, o = 0) {
1794
1794
  if (!n) return;
1795
- ce(e, t, n, r, o);
1795
+ ie(e, t, n, r, o);
1796
1796
  let s = new Map(t.series[0]?.dataPointOverrides?.map((e) => [e.idx, e]) ?? []), c = i ? (t.series[0]?.categories?.length ? t.series[0].categories : t.categories).map((e, n) => {
1797
1797
  let r = t.series[0]?.dataPointColors?.[n];
1798
1798
  return {
@@ -1814,14 +1814,14 @@ function fn(e, t, n, r, i = !1, a, o = 0) {
1814
1814
  e.textAlign = "left", e.textBaseline = "middle";
1815
1815
  let p = Math.max(0, ...f.map((e) => e.fontPx)), m = Math.max(p * 1.45, 12), h = Math.min(7 * r, m * .7), g = m + Qt(u.map((e) => e.label), p);
1816
1816
  if (t.legendPos === "t" || t.legendPos === "b" || t.legendManualLayout != null && n.w >= n.h) {
1817
- let s = d ? a.itemWidths : u.map((t, n) => (e.font = f[n].font, h + 4 + R(e, t.label))), c = w(s, Math.max(1, n.w - 8), 12).slice(0, Math.max(0, Math.floor((n.h - 4 + 1e-6) / g))), l = n.y + 2 + g / 2;
1817
+ let s = d ? a.itemWidths : u.map((t, n) => (e.font = f[n].font, h + 4 + M(e, t.label))), c = ae(s, Math.max(1, n.w - 8), 12).slice(0, Math.max(0, Math.floor((n.h - 4 + 1e-6) / g))), l = n.y + 2 + g / 2;
1818
1818
  for (let a of c) {
1819
1819
  let c = a.map((e) => Math.min(n.w, s[e])), d = c.reduce((e, t) => e + t, 0) + Math.max(0, a.length - 1) * 12, p = n.x + Math.max(4, (n.w - d) / 2);
1820
1820
  for (let n = 0; n < a.length; n++) {
1821
1821
  let s = a[n], d = u[s], m = f[s];
1822
1822
  e.font = m.font;
1823
1823
  let g = Math.max(0, c[n] - h - 4);
1824
- !i && t.chartType.toLowerCase().includes("line") && d.series ? dn(e, t, d.series, d.seriesIndex, d.color, p, l, h, r, o) : d.series && un(e, t, d.series, d.point, d.sourceIndex, d.seriesIndex, p, l, h, r, o, i), e.fillStyle = m.color, Y(e, d.label, p + h + 4, l, Zt(m.fontPx), g), p += c[n] + 12;
1824
+ !i && t.chartType.toLowerCase().includes("line") && d.series ? dn(e, t, d.series, d.seriesIndex, d.color, p, l, h, r, o) : d.series && un(e, t, d.series, d.point, d.sourceIndex, d.seriesIndex, p, l, h, r, o, i), e.fillStyle = m.color, B(e, d.label, p + h + 4, l, Zt(m.fontPx), g), p += c[n] + 12;
1825
1825
  }
1826
1826
  l += g;
1827
1827
  }
@@ -1831,7 +1831,7 @@ function fn(e, t, n, r, i = !1, a, o = 0) {
1831
1831
  for (let a = 0; a < u.length; a++) {
1832
1832
  let s = u[a], c = f[a];
1833
1833
  e.font = c.font;
1834
- let l = n.x + 8 + h, d = Math.max(0, n.x + n.w - 4 - l), p = Math.max(c.fontPx * 1.2, 10), g = V(s.label), v = (t) => C(t, d, p * (i ? 1 : 2), p, (t) => e.measureText(t).width), y = g.length === 1 ? v(s.label) : g.flatMap(v);
1834
+ let l = n.x + 8 + h, d = Math.max(0, n.x + n.w - 4 - l), p = Math.max(c.fontPx * 1.2, 10), g = re(s.label), v = (t) => w(t, d, p * (i ? 1 : 2), p, (t) => e.measureText(t).width), y = g.length === 1 ? v(s.label) : g.flatMap(v);
1835
1835
  if (y.length === 0) continue;
1836
1836
  let b = Math.max(m, y.length * p + 2);
1837
1837
  if (_ + b > n.y + n.h + 1e-6) break;
@@ -1843,7 +1843,7 @@ function fn(e, t, n, r, i = !1, a, o = 0) {
1843
1843
  }
1844
1844
  function pn(e, t, n, r, i, a) {
1845
1845
  let o = i ? 100 : 1, s = e.valAxisMinorTickMark ?? "none";
1846
- return b({
1846
+ return h({
1847
1847
  dataMin: t,
1848
1848
  dataMax: n,
1849
1849
  explicitMin: e.valMin == null ? i ? t : null : e.valMin * o,
@@ -1896,23 +1896,23 @@ function hn(e) {
1896
1896
  };
1897
1897
  }
1898
1898
  function gn(e, t, n, r, i = "A6A6A6", a = .75) {
1899
- let o = t != null && Number.isFinite(t) && t >= 0 ? Math.max(.25, t / F * r) : a * r;
1899
+ let o = t != null && Number.isFinite(t) && t >= 0 ? Math.max(.25, t / W * r) : a * r;
1900
1900
  return {
1901
1901
  color: `#${e ?? i}`,
1902
1902
  width: o,
1903
- dash: _e(n ?? "solid", o)
1903
+ dash: Se(n ?? "solid", o)
1904
1904
  };
1905
1905
  }
1906
1906
  function _n(e, t, n, r) {
1907
1907
  let i = gn(e, t, n, r, "898989", 1);
1908
1908
  if (t == null || !Number.isFinite(t) || t < 0) return i;
1909
- let a = t / F * r;
1909
+ let a = t / W * r;
1910
1910
  if (!(a > 0)) return i;
1911
1911
  let o = a;
1912
1912
  return {
1913
1913
  ...i,
1914
1914
  width: o,
1915
- dash: _e(n ?? "solid", o)
1915
+ dash: Se(n ?? "solid", o)
1916
1916
  };
1917
1917
  }
1918
1918
  function vn(e, t, n, r) {
@@ -1922,14 +1922,14 @@ function yn(e, t) {
1922
1922
  e.strokeStyle = t.color, e.lineWidth = t.width, e.setLineDash(t.dash);
1923
1923
  }
1924
1924
  function bn(e, t, n, r, i, a, o, s, c) {
1925
- let { front: l } = n, u = l.x, d = l.x + l.w, f = hn(n), { sideX: p, floorY: h, oppositeFloorY: g, nearDepth: _, farDepth: v } = f, y = Dn(t, n, r, a, o, s, i), b = [], x = t.catAxisLinePaintAuthored === !0, S = t.valAxisLinePaintAuthored === !0, C = i === "vertical" ? x && !t.catAxisHidden && !t.catAxisLineHidden : S && !t.valAxisHidden && !t.valAxisLineHidden, w = i === "vertical" ? S && !t.valAxisHidden && !t.valAxisLineHidden : x && !t.catAxisHidden && !t.catAxisLineHidden;
1926
- C && b.push([y.horizontalStart, y.horizontalEnd]), w && b.push([y.verticalStart, y.verticalEnd]);
1927
- let T = t.threeD?.seriesAxis, E = T?.linePaintAuthored === !0;
1928
- if (T && !T.hidden && !T.lineHidden && E && t.threeD?.barGrouping === "standard" && t.series.length > 0) {
1929
- let e = i === "vertical" ? f.seriesAxisX : y.axisX, t = i === "horizontal" ? h === n.front.y ? n.front.y + n.front.h : n.front.y : h;
1925
+ let { front: l } = n, u = l.x, f = l.x + l.w, p = hn(n), { sideX: m, floorY: h, oppositeFloorY: g, nearDepth: _, farDepth: v } = p, y = Dn(t, n, r, a, o, s, i), b = [], C = t.catAxisLinePaintAuthored === !0, w = t.valAxisLinePaintAuthored === !0, T = i === "vertical" ? C && !t.catAxisHidden && !t.catAxisLineHidden : w && !t.valAxisHidden && !t.valAxisLineHidden, E = i === "vertical" ? w && !t.valAxisHidden && !t.valAxisLineHidden : C && !t.catAxisHidden && !t.catAxisLineHidden;
1926
+ T && b.push([y.horizontalStart, y.horizontalEnd]), E && b.push([y.verticalStart, y.verticalEnd]);
1927
+ let D = t.threeD?.seriesAxis, O = D?.linePaintAuthored === !0;
1928
+ if (D && !D.hidden && !D.lineHidden && O && t.threeD?.barGrouping === "standard" && t.series.length > 0) {
1929
+ let e = i === "vertical" ? p.seriesAxisX : y.axisX, t = i === "horizontal" ? h === n.front.y ? n.front.y + n.front.h : n.front.y : h;
1930
1930
  b.push([n.project(e, t, _), n.project(e, t, v)]);
1931
1931
  }
1932
- let D = (e, t) => Math.hypot(e.x - t.x, e.y - t.y) <= 1e-6, O = (e, t) => b.some(([n, r]) => D(e, n) && D(t, r) || D(e, r) && D(t, n)), k = (e, t) => {
1932
+ let k = (e, t) => Math.hypot(e.x - t.x, e.y - t.y) <= 1e-6, A = (e, t) => b.some(([n, r]) => k(e, n) && k(t, r) || k(e, r) && k(t, n)), j = (e, t) => {
1933
1933
  let r = Ce(n, e, t?.thicknessPercent), i = r.faces.map((e, t) => ({
1934
1934
  scenePoints: e,
1935
1935
  faceIndex: t
@@ -1944,19 +1944,19 @@ function bn(e, t, n, r, i, a, o, s, c) {
1944
1944
  faces: i,
1945
1945
  visibleFaceIndices: new Set(i.map((e) => e.faceIndex))
1946
1946
  };
1947
- }, A = k("floor", t.threeD?.floor), j = k("sideWall", t.threeD?.sideWall), M = k("backWall", t.threeD?.backWall), N = A.faces, P = j.faces, I = M.faces, R = (i, a, o, s) => {
1948
- let l = m(t, a, o), u = i.faces;
1947
+ }, M = j("floor", t.threeD?.floor), N = j("sideWall", t.threeD?.sideWall), P = j("backWall", t.threeD?.backWall), F = M.faces, I = N.faces, L = P.faces, R = (i, a, o, s) => {
1948
+ let l = d(t, a, o), u = i.faces;
1949
1949
  if (!l.fill || !u.length) return;
1950
1950
  if (l.fill.fillType === "image") {
1951
- let t = l.fill, o = ke(i.slab, c), u = W(l.fill, o ? J(l.fill, o.widthPt, o.heightPt) : void 0);
1951
+ let t = l.fill, o = ke(i.slab, c), u = ee(l.fill, o ? q(l.fill, o.widthPt, o.heightPt) : void 0);
1952
1952
  if (!u) return;
1953
- Ee(e, l.fill, u, a, s, i.slab, i.faces.map((e) => e.faceIndex), (e) => n.projectUnbounded(e.x, e.y, e.depth), r.max - r.min, (e, n) => W(t, J(t, e, n)), c);
1953
+ Ee(e, l.fill, u, a, s, i.slab, i.faces.map((e) => e.faceIndex), (e) => n.projectUnbounded(e.x, e.y, e.depth), r.max - r.min, (e, n) => ee(t, q(t, e, n)), c);
1954
1954
  return;
1955
1955
  }
1956
- let d = u.flatMap((e) => e.points), f = Math.min(...d.map((e) => e.x)), p = Math.max(...d.map((e) => e.x)), h = Math.min(...d.map((e) => e.y)), g = Math.max(...d.map((e) => e.y)), _ = l.fill.fillType === "solid" ? `#${l.fill.color}` : Z(l.fill, e, f, h, p - f, g - h);
1956
+ let f = u.flatMap((e) => e.points), p = Math.min(...f.map((e) => e.x)), m = Math.max(...f.map((e) => e.x)), h = Math.min(...f.map((e) => e.y)), g = Math.max(...f.map((e) => e.y)), _ = l.fill.fillType === "solid" ? `#${l.fill.color}` : se(l.fill, e, p, h, m - p, g - h);
1957
1957
  if (_) for (let t of u) t.points.length < 3 || (zt(e, t.points), e.fillStyle = _, e.fill());
1958
1958
  };
1959
- R(A, t.threeD?.floor, "floor", "floor"), R(j, t.threeD?.sideWall, "wall", "sideWall"), R(M, t.threeD?.backWall, "wall", "backWall");
1959
+ R(M, t.threeD?.floor, "floor", "floor"), R(N, t.threeD?.sideWall, "wall", "sideWall"), R(P, t.threeD?.backWall, "wall", "backWall");
1960
1960
  let z = (t, r, i, a, o = !0) => {
1961
1961
  for (let s of Oe(t.slab, r, i, a)) {
1962
1962
  if (!o && s.faceIndex !== 0 || !t.visibleFaceIndices.has(s.faceIndex)) continue;
@@ -1968,14 +1968,14 @@ function bn(e, t, n, r, i, a, o, s, c) {
1968
1968
  for (let a of t) {
1969
1969
  let t = r.fraction(a);
1970
1970
  if (o) {
1971
- i === "horizontal" ? (z(A, "floor", "x", t), z(M, "backWall", "x", t)) : (z(j, "sideWall", "y", t), z(M, "backWall", "y", t));
1971
+ i === "horizontal" ? (z(M, "floor", "x", t), z(P, "backWall", "x", t)) : (z(N, "sideWall", "y", t), z(P, "backWall", "y", t));
1972
1972
  continue;
1973
1973
  }
1974
1974
  if (i === "horizontal") {
1975
1975
  let r = l.x + t * l.w, i = n.project(r, h, v), a = n.project(r, g, v);
1976
1976
  e.beginPath(), e.moveTo(i.x, i.y), e.lineTo(a.x, a.y), e.stroke();
1977
1977
  } else {
1978
- let r = l.y + l.h - t * l.h, i = n.project(p, r, _), a = n.project(p, r, v), o = n.project(p === u ? d : u, r, v);
1978
+ let r = l.y + l.h - t * l.h, i = n.project(m, r, _), a = n.project(m, r, v), o = n.project(m === u ? f : u, r, v);
1979
1979
  e.beginPath(), e.moveTo(i.x, i.y), e.lineTo(a.x, a.y), e.stroke(), e.beginPath(), e.moveTo(a.x, a.y), e.lineTo(o.x, o.y), e.stroke();
1980
1980
  }
1981
1981
  }
@@ -1983,28 +1983,28 @@ function bn(e, t, n, r, i, a, o, s, c) {
1983
1983
  t.valAxisMinorGridlines === !0 && B(r.minorTicks, gn(t.valAxisMinorGridlineColor, t.valAxisMinorGridlineWidthEmu, t.valAxisMinorGridlineDash, c, "D9D9D9", .5), !0), t.valAxisMajorGridlines === !0 && B(r.majorTicks, gn(t.valAxisGridlineColor, t.valAxisGridlineWidthEmu, t.valAxisGridlineDash, c, "898989", 1), !0);
1984
1984
  let V = (t, n) => {
1985
1985
  yn(e, n);
1986
- for (let e of t) i === "vertical" ? (z(A, "floor", "x", e), z(M, "backWall", "x", e)) : (z(j, "sideWall", "y", e), z(M, "backWall", "y", e));
1986
+ for (let e of t) i === "vertical" ? (z(M, "floor", "x", e), z(P, "backWall", "x", e)) : (z(N, "sideWall", "y", e), z(P, "backWall", "y", e));
1987
1987
  };
1988
- t.catAxisMinorGridlines === !0 && V(ie(a, o), gn(t.catAxisMinorGridlineColor, t.catAxisMinorGridlineWidthEmu, t.catAxisMinorGridlineDash, c, "E0E0E0", .5)), t.catAxisMajorGridlines === !0 && V(pe(a, o), gn(t.catAxisGridlineColor, t.catAxisGridlineWidthEmu, t.catAxisGridlineDash, c, "E0E0E0", .5));
1988
+ t.catAxisMinorGridlines === !0 && V(S(a, o), gn(t.catAxisMinorGridlineColor, t.catAxisMinorGridlineWidthEmu, t.catAxisMinorGridlineDash, c, "E0E0E0", .5)), t.catAxisMajorGridlines === !0 && V(_e(a, o), gn(t.catAxisGridlineColor, t.catAxisGridlineWidthEmu, t.catAxisGridlineDash, c, "E0E0E0", .5));
1989
1989
  let H = (n, r, i) => {
1990
1990
  if (!n.length) return;
1991
- let a = m(t, r, i);
1991
+ let a = d(t, r, i);
1992
1992
  if (a.line === null) return;
1993
1993
  let o = a.line ?? {
1994
1994
  fillType: "solid",
1995
1995
  color: "898989"
1996
- }, s = n.flatMap((e) => e.points), l = Math.min(...s.map((e) => e.x)), u = Math.max(...s.map((e) => e.x)), d = Math.min(...s.map((e) => e.y)), f = Math.max(...s.map((e) => e.y)), p = o.fillType === "solid" ? `#${o.color}` : Z(o, e, l, d, u - l, f - d);
1997
- if (!p) return;
1998
- let h = a.lineWidthEmu == null ? c : Math.max(.25, a.lineWidthEmu / F * c);
1999
- e.strokeStyle = p, e.lineWidth = h, e.setLineDash(L(a.lineCustomDash, a.lineDash, h)), e.lineCap = a.lineCap === "rnd" ? "round" : a.lineCap === "sq" ? "square" : "butt", e.lineJoin = a.lineJoin === "round" || a.lineJoin === "bevel" ? a.lineJoin : "miter";
1996
+ }, s = n.flatMap((e) => e.points), l = Math.min(...s.map((e) => e.x)), u = Math.max(...s.map((e) => e.x)), f = Math.min(...s.map((e) => e.y)), p = Math.max(...s.map((e) => e.y)), m = o.fillType === "solid" ? `#${o.color}` : se(o, e, l, f, u - l, p - f);
1997
+ if (!m) return;
1998
+ let h = a.lineWidthEmu == null ? c : Math.max(.25, a.lineWidthEmu / W * c);
1999
+ e.strokeStyle = m, e.lineWidth = h, e.setLineDash(x(a.lineCustomDash, a.lineDash, h)), e.lineCap = a.lineCap === "rnd" ? "round" : a.lineCap === "sq" ? "square" : "butt", e.lineJoin = a.lineJoin === "round" || a.lineJoin === "bevel" ? a.lineJoin : "miter";
2000
2000
  for (let t of n) {
2001
2001
  if (t.points.length < 2) continue;
2002
2002
  let n = t.points.map((e, n) => ({
2003
2003
  start: e,
2004
2004
  end: t.points[(n + 1) % t.points.length]
2005
2005
  }));
2006
- if (n.some((e) => O(e.start, e.end))) {
2007
- for (let t of n) O(t.start, t.end) || (e.beginPath(), e.moveTo(t.start.x, t.start.y), e.lineTo(t.end.x, t.end.y), e.stroke());
2006
+ if (n.some((e) => A(e.start, e.end))) {
2007
+ for (let t of n) A(t.start, t.end) || (e.beginPath(), e.moveTo(t.start.x, t.start.y), e.lineTo(t.end.x, t.end.y), e.stroke());
2008
2008
  continue;
2009
2009
  }
2010
2010
  e.beginPath(), e.moveTo(t.points[0].x, t.points[0].y);
@@ -2012,7 +2012,7 @@ function bn(e, t, n, r, i, a, o, s, c) {
2012
2012
  e.lineTo(t.points[0].x, t.points[0].y), e.closePath(), e.stroke();
2013
2013
  }
2014
2014
  };
2015
- H(N, t.threeD?.floor, "floor"), H(P, t.threeD?.sideWall, "wall"), H(I, t.threeD?.backWall, "wall"), e.setLineDash([]);
2015
+ H(F, t.threeD?.floor, "floor"), H(I, t.threeD?.sideWall, "wall"), H(L, t.threeD?.backWall, "wall"), e.setLineDash([]);
2016
2016
  }
2017
2017
  function xn(e, t, n, r, i, a, o, s, c) {
2018
2018
  let l = Dn(t, n, r, i, a, o, c), u = c === "vertical" ? !t.catAxisHidden && !t.catAxisLineHidden : !t.valAxisHidden && !t.valAxisLineHidden, d = c === "vertical" ? !t.valAxisHidden && !t.valAxisLineHidden : !t.catAxisHidden && !t.catAxisLineHidden;
@@ -2049,189 +2049,189 @@ function En(e, t, n, r) {
2049
2049
  let i = Tn(e, "major", n);
2050
2050
  return Math.max(r, i + 3 * n);
2051
2051
  }
2052
- function Dn(e, t, n, r, i, a, o) {
2053
- let { front: s } = t, c = (e) => Math.max(0, Math.min(1, e)), l = t.topology.axisX === "min" ? s.x : s.x + s.w, u = t.topology.axisY === "min" ? s.y : s.y + s.h, d = () => {
2052
+ function Dn(e, t, n, i, a, o, s) {
2053
+ let { front: c } = t, l = (e) => Math.max(0, Math.min(1, e)), u = t.topology.axisX === "min" ? c.x : c.x + c.w, d = t.topology.axisY === "min" ? c.y : c.y + c.h, f = () => {
2054
2054
  if (e.catAxisCrossesAt != null && Number.isFinite(e.catAxisCrossesAt)) {
2055
2055
  let t = e.chartType.endsWith("Pct") ? e.catAxisCrossesAt * 100 : e.catAxisCrossesAt;
2056
- return c(n.fraction(t));
2056
+ return l(n.fraction(t));
2057
2057
  }
2058
2058
  let t = e.catAxisCrosses ?? "autoZero";
2059
- return c(t === "min" ? n.fraction(n.min) : t === "max" ? n.fraction(n.max) : n.fraction(0));
2060
- }, f = () => {
2059
+ return l(t === "min" ? n.fraction(n.min) : t === "max" ? n.fraction(n.max) : n.fraction(0));
2060
+ }, p = () => {
2061
2061
  let t = e.valAxisCrossesAt;
2062
- if (t != null && Number.isFinite(t)) return q(t - 1, r, i, a);
2062
+ if (t != null && Number.isFinite(t)) return r(t - 1, i, a, o);
2063
2063
  let n = e.valAxisCrosses;
2064
2064
  if (n !== "min" && n !== "max") return null;
2065
- let o = +(n === "max");
2066
- return a ? 1 - o : o;
2067
- }, p = d(), m = f(), h = o === "horizontal" ? s.x + p * s.w : m == null ? l : s.x + m * s.w, g = o === "vertical" ? s.y + s.h - p * s.h : m == null ? u : s.y + m * s.h, _ = t.topology.nearDepth;
2065
+ let s = +(n === "max");
2066
+ return o ? 1 - s : s;
2067
+ }, m = f(), h = p(), g = s === "horizontal" ? c.x + m * c.w : h == null ? u : c.x + h * c.w, _ = s === "vertical" ? c.y + c.h - m * c.h : h == null ? d : c.y + h * c.h, v = t.topology.nearDepth;
2068
2068
  return {
2069
- axisX: h,
2070
- axisY: g,
2071
- depth: _,
2072
- horizontalStart: t.project(s.x, g, _),
2073
- horizontalEnd: t.project(s.x + s.w, g, _),
2074
- verticalStart: t.project(h, s.y + s.h, _),
2075
- verticalEnd: t.project(h, s.y, _)
2069
+ axisX: g,
2070
+ axisY: _,
2071
+ depth: v,
2072
+ horizontalStart: t.project(c.x, _, v),
2073
+ horizontalEnd: t.project(c.x + c.w, _, v),
2074
+ verticalStart: t.project(g, c.y + c.h, v),
2075
+ verticalEnd: t.project(g, c.y, v)
2076
2076
  };
2077
2077
  }
2078
- function On(e, t, n, r, i, a, o, s, c, l) {
2079
- let { front: u } = n, d = Dn(t, n, r, i, a, o, s), { axisX: f, axisY: p, depth: m } = d, h = n.project(u.x + u.w / 2, u.y + u.h / 2, m), g = t.valAxisMinorTickMark ?? "none", _ = c ? vn : _n;
2078
+ function On(e, t, n, i, a, o, s, c, l, u) {
2079
+ let { front: d } = n, f = Dn(t, n, i, a, o, s, c), { axisX: p, axisY: m, depth: h } = f, g = n.project(d.x + d.w / 2, d.y + d.h / 2, h), _ = t.valAxisMinorTickMark ?? "none", v = l ? vn : _n;
2080
2080
  if (!t.valAxisHidden && !t.valAxisLineHidden) {
2081
- yn(e, _(t.valAxisLineColor, t.valAxisLineWidthEmu, t.valAxisLineDash, l));
2082
- let i = (e) => s === "horizontal" ? n.project(u.x + r.fraction(e) * u.w, p, m) : n.project(f, u.y + u.h - r.fraction(e) * u.h, m), a = s === "horizontal" ? d.horizontalStart : d.verticalStart, o = s === "horizontal" ? d.horizontalEnd : d.verticalEnd;
2083
- for (let n of r.majorTicks) Cn(e, t.valAxisMajorTickMark, i(n), a, o, h, s === "vertical" ? "horizontal" : "vertical", "major", l);
2084
- for (let t of r.minorTicks) Cn(e, g, i(t), a, o, h, s === "vertical" ? "horizontal" : "vertical", "minor", l);
2081
+ yn(e, v(t.valAxisLineColor, t.valAxisLineWidthEmu, t.valAxisLineDash, u));
2082
+ let r = (e) => c === "horizontal" ? n.project(d.x + i.fraction(e) * d.w, m, h) : n.project(p, d.y + d.h - i.fraction(e) * d.h, h), a = c === "horizontal" ? f.horizontalStart : f.verticalStart, o = c === "horizontal" ? f.horizontalEnd : f.verticalEnd;
2083
+ for (let n of i.majorTicks) Cn(e, t.valAxisMajorTickMark, r(n), a, o, g, c === "vertical" ? "horizontal" : "vertical", "major", u);
2084
+ for (let t of i.minorTicks) Cn(e, _, r(t), a, o, g, c === "vertical" ? "horizontal" : "vertical", "minor", u);
2085
2085
  }
2086
2086
  if (!t.catAxisHidden && !t.catAxisLineHidden) {
2087
- yn(e, _(t.catAxisLineColor, t.catAxisLineWidthEmu, t.catAxisLineDash, l));
2088
- let r = s === "vertical" ? d.horizontalStart : d.verticalStart, g = s === "vertical" ? d.horizontalEnd : d.verticalEnd, v = Math.max(1, Math.floor(t.catAxisTickMarkSkip ?? 1)), y = (i) => {
2089
- let a = s === "vertical" ? n.project(u.x + i * u.w, p, m) : n.project(f, u.y + i * u.h, m);
2090
- Cn(e, t.catAxisMajorTickMark, a, r, g, h, s === "vertical" ? "vertical" : "horizontal", "major", l);
2087
+ yn(e, v(t.catAxisLineColor, t.catAxisLineWidthEmu, t.catAxisLineDash, u));
2088
+ let i = c === "vertical" ? f.horizontalStart : f.verticalStart, _ = c === "vertical" ? f.horizontalEnd : f.verticalEnd, y = Math.max(1, Math.floor(t.catAxisTickMarkSkip ?? 1)), b = (r) => {
2089
+ let a = c === "vertical" ? n.project(d.x + r * d.w, m, h) : n.project(p, d.y + r * d.h, h);
2090
+ Cn(e, t.catAxisMajorTickMark, a, i, _, g, c === "vertical" ? "vertical" : "horizontal", "major", u);
2091
2091
  };
2092
- if (c) {
2093
- let e = pe(i, a);
2094
- for (let t = 0; t < e.length; t += v) y(o ? 1 - e[t] : e[t]);
2095
- } else for (let e = 0; e < i; e += v) y(q(e, i, a, o));
2096
- let b = t.catAxisMinorUnit;
2097
- if (t.catAxisMinorTickMark && t.catAxisMinorTickMark !== "none" && b != null && Number.isFinite(b) && b > 0) {
2098
- let c = t.catAxisMajorUnit != null && Number.isFinite(t.catAxisMajorUnit) && t.catAxisMajorUnit > 0 ? t.catAxisMajorUnit : v, d = Math.min(512, Math.ceil(i / b));
2099
- for (let _ = 1; _ < d; _++) {
2100
- let d = _ * b;
2101
- if (!(d < i)) break;
2102
- if (Math.abs(d / c - Math.round(d / c)) < 1e-9) continue;
2103
- let v = q(d, i, a, o), y = s === "vertical" ? n.project(u.x + v * u.w, p, m) : n.project(f, u.y + v * u.h, m);
2104
- Cn(e, t.catAxisMinorTickMark, y, r, g, h, s === "vertical" ? "vertical" : "horizontal", "minor", l);
2092
+ if (l) {
2093
+ let e = _e(a, o);
2094
+ for (let t = 0; t < e.length; t += y) b(s ? 1 - e[t] : e[t]);
2095
+ } else for (let e = 0; e < a; e += y) b(r(e, a, o, s));
2096
+ let x = t.catAxisMinorUnit;
2097
+ if (t.catAxisMinorTickMark && t.catAxisMinorTickMark !== "none" && x != null && Number.isFinite(x) && x > 0) {
2098
+ let l = t.catAxisMajorUnit != null && Number.isFinite(t.catAxisMajorUnit) && t.catAxisMajorUnit > 0 ? t.catAxisMajorUnit : y, f = Math.min(512, Math.ceil(a / x));
2099
+ for (let v = 1; v < f; v++) {
2100
+ let f = v * x;
2101
+ if (!(f < a)) break;
2102
+ if (Math.abs(f / l - Math.round(f / l)) < 1e-9) continue;
2103
+ let y = r(f, a, o, s), b = c === "vertical" ? n.project(d.x + y * d.w, m, h) : n.project(p, d.y + y * d.h, h);
2104
+ Cn(e, t.catAxisMinorTickMark, b, i, _, g, c === "vertical" ? "vertical" : "horizontal", "minor", u);
2105
2105
  }
2106
2106
  }
2107
2107
  }
2108
2108
  e.setLineDash([]);
2109
2109
  }
2110
- function kn(e, t, n, r, a) {
2110
+ function kn(e, t, n, a, o) {
2111
2111
  if (!t.threeD) return !1;
2112
- let o = t.chartType === "clusteredBar" || t.chartType === "clusteredBarH" || t.chartType.startsWith("stackedBar"), s = t.chartType.endsWith("H") || t.chartType.includes("BarH"), c = t.chartType.startsWith("stacked"), l = o && !c && t.threeD.barGrouping === "standard", { plot: u, legend: d, legendMeasure: f } = rn(e, t, n, r, s ? "horizontal" : "vertical", a), p = Te(t.threeD, u, {
2113
- sceneDepthScale: o ? l ? .65 : .1 : .4,
2114
- perspectiveTangentGain: l ? 1 : 2,
2115
- sceneHeightScale: !o && !(t.threeD.heightPercentAuthored ?? t.threeD.heightPercent != null) ? 1 / 3 : void 0
2112
+ let s = t.chartType === "clusteredBar" || t.chartType === "clusteredBarH" || t.chartType.startsWith("stackedBar"), c = t.chartType.endsWith("H") || t.chartType.includes("BarH"), u = t.chartType.startsWith("stacked"), d = s && !u && t.threeD.barGrouping === "standard", { plot: f, legend: p, legendMeasure: h } = rn(e, t, n, a, c ? "horizontal" : "vertical", o), _ = Te(t.threeD, f, {
2113
+ sceneDepthScale: s ? d ? .65 : .1 : .4,
2114
+ perspectiveTangentGain: d ? 1 : 2,
2115
+ sceneHeightScale: !s && !(t.threeD.heightPercentAuthored ?? t.threeD.heightPercent != null) ? 1 / 3 : void 0
2116
2116
  });
2117
- if (!p) return !0;
2118
- p = De(p, t.threeD, u);
2119
- let m = t.chartType.endsWith("Pct"), h = t.series.find((e) => (e.categories?.length ?? 0) > 0)?.categories ?? t.categories, _ = Math.max(1, h.length, ...t.series.map((e) => e.values.length)), v = m ? kt(t, _) : void 0, y = t.catAxisOrientation === "maxMin", b = t.catAxisCrossBetween === "between", x = t.dispBlanksAs ?? "gap", C = t.valAxisLogBase != null && Number.isFinite(t.valAxisLogBase) && t.valAxisLogBase >= 2, w = (e, n) => {
2117
+ if (!_) return !0;
2118
+ _ = De(_, t.threeD, f);
2119
+ let v = t.chartType.endsWith("Pct"), y = t.series.find((e) => (e.categories?.length ?? 0) > 0)?.categories ?? t.categories, b = Math.max(1, y.length, ...t.series.map((e) => e.values.length)), S = v ? kt(t, b) : void 0, w = t.catAxisOrientation === "maxMin", T = t.catAxisCrossBetween === "between", E = t.dispBlanksAs ?? "gap", D = t.valAxisLogBase != null && Number.isFinite(t.valAxisLogBase) && t.valAxisLogBase >= 2, O = (e, n) => {
2120
2120
  let r = t.series[e]?.values[n];
2121
- return r != null && Number.isFinite(r) && (!C || r > 0) || r == null && (c || x === "zero");
2122
- }, T = (e, n) => At(t, e, n, v), E = 0, O = 0;
2123
- if (c) {
2124
- for (let e = 0; e < _; e++) {
2121
+ return r != null && Number.isFinite(r) && (!D || r > 0) || r == null && (u || E === "zero");
2122
+ }, k = (e, n) => At(t, e, n, S), A = 0, j = 0;
2123
+ if (u) {
2124
+ for (let e = 0; e < b; e++) {
2125
2125
  let n = 0, r = 0;
2126
2126
  for (let i = 0; i < t.series.length; i++) {
2127
- let t = T(i, e);
2127
+ let t = k(i, e);
2128
2128
  t >= 0 ? n = jt(n, t) : r = jt(r, t);
2129
2129
  }
2130
- E = Math.min(E, r), O = Math.max(O, n);
2130
+ A = Math.min(A, r), j = Math.max(j, n);
2131
2131
  }
2132
- m && (E = E < 0 ? -100 : 0, O = O > 0 ? 100 : 0, E === 0 && O === 0 && (O = 1));
2132
+ v && (A = A < 0 ? -100 : 0, j = j > 0 ? 100 : 0, A === 0 && j === 0 && (j = 1));
2133
2133
  } else {
2134
- let e = S(t.series.flatMap((e) => e.values).filter((e) => e != null && Number.isFinite(e) && (!C || e > 0)), C ? {
2134
+ let e = g(t.series.flatMap((e) => e.values).filter((e) => e != null && Number.isFinite(e) && (!D || e > 0)), D ? {
2135
2135
  min: 1,
2136
2136
  max: 10
2137
2137
  } : {
2138
2138
  min: 0,
2139
2139
  max: 1
2140
2140
  });
2141
- E = C ? e.min : Math.min(0, e.min), O = C ? e.max : Math.max(0, e.max);
2141
+ A = D ? e.min : Math.min(0, e.min), j = D ? e.max : Math.max(0, e.max);
2142
2142
  }
2143
- let k = s ? p.project(p.front.x, p.topology.axisY === "min" ? p.front.y : p.front.y + p.front.h, p.topology.nearDepth) : p.project(p.topology.axisX === "min" ? p.front.x : p.front.x + p.front.w, p.front.y, p.topology.nearDepth), A = s ? p.project(p.front.x + p.front.w, p.topology.axisY === "min" ? p.front.y : p.front.y + p.front.h, p.topology.nearDepth) : p.project(p.topology.axisX === "min" ? p.front.x : p.front.x + p.front.w, p.front.y + p.front.h, p.topology.nearDepth), M = Math.hypot(A.x - k.x, A.y - k.y) / r, I = pn(t, E, O, M, m, s ? "horizontal" : "vertical"), z = (e) => Number.isFinite(e) ? Math.max(I.min, Math.min(I.max, e)) : I.min;
2144
- o || bn(e, t, p, I, s ? "horizontal" : "vertical", _, b, y, r);
2145
- let { front: V } = p, H = Math.max(1, t.series.length), ee = [], U = t.series.map((e) => new Map(e.dataPointOverrides?.map((e) => [e.idx, e]) ?? [])), te = t.series.map((e) => new Map(e.dataLabelOverrides?.map((e) => [e.idx, e]) ?? []));
2146
- if (o) {
2147
- let i = p.prismInterval(0, 1, !0), o = [], u = Array(_).fill(0), d = Array(_).fill(0), f = (s ? V.h : V.w) / _, h = t.barGapWidth != null && Number.isFinite(t.barGapWidth) && t.barGapWidth >= 0 ? t.barGapWidth : 150;
2143
+ let N = c ? _.project(_.front.x, _.topology.axisY === "min" ? _.front.y : _.front.y + _.front.h, _.topology.nearDepth) : _.project(_.topology.axisX === "min" ? _.front.x : _.front.x + _.front.w, _.front.y, _.topology.nearDepth), P = c ? _.project(_.front.x + _.front.w, _.topology.axisY === "min" ? _.front.y : _.front.y + _.front.h, _.topology.nearDepth) : _.project(_.topology.axisX === "min" ? _.front.x : _.front.x + _.front.w, _.front.y + _.front.h, _.topology.nearDepth), F = Math.hypot(P.x - N.x, P.y - N.y) / a, I = pn(t, A, j, F, v, c ? "horizontal" : "vertical"), L = (e) => Number.isFinite(e) ? Math.max(I.min, Math.min(I.max, e)) : I.min;
2144
+ s || bn(e, t, _, I, c ? "horizontal" : "vertical", b, T, w, a);
2145
+ let { front: R } = _, z = Math.max(1, t.series.length), ee = [], G = t.series.map((e) => new Map(e.dataPointOverrides?.map((e) => [e.idx, e]) ?? [])), q = t.series.map((e) => new Map(e.dataLabelOverrides?.map((e) => [e.idx, e]) ?? []));
2146
+ if (s) {
2147
+ let r = _.prismInterval(0, 1, !0), i = [], s = Array(b).fill(0), f = Array(b).fill(0), p = (c ? R.h : R.w) / b, h = t.barGapWidth != null && Number.isFinite(t.barGapWidth) && t.barGapWidth >= 0 ? t.barGapWidth : 150;
2148
2148
  for (let e = 0; e < t.series.length; e++) {
2149
- let n = t.series[e], a = l ? p.prismInterval(e, H, !1) : i, g = je(f, h, l ? 0 : e, l ? 1 : H, c || l);
2150
- for (let i = 0; i < _; i++) {
2151
- if (!w(e, i)) continue;
2152
- let l = T(e, i), p = $(t, n, U[e].get(i), i, e), h = p.fill === null ? "transparent" : p.color, v = p.lineFill !== null && (p.lineColor != null || p.lineFill !== void 0), b = c ? l >= 0 ? u[i] : d[i] : 0, x = jt(b, l);
2153
- c && (l >= 0 ? u[i] = x : d[i] = x);
2154
- let S = z(b), E = z(x), O = n.threeDShape ?? t.threeD.shape ?? "box", k = O === "cone" || O === "pyramid", A = O === "coneToMax" || O === "pyramidToMax", j = (e) => {
2155
- if (!k) return 1;
2156
- let t = C && !(b > 0) ? I.min : b, n = I.fraction(t), r = I.fraction(x), i = I.fraction(e), a = r - n;
2149
+ let n = t.series[e], o = d ? _.prismInterval(e, z, !1) : r, l = je(p, h, d ? 0 : e, d ? 1 : z, u || d);
2150
+ for (let r = 0; r < b; r++) {
2151
+ if (!O(e, r)) continue;
2152
+ let d = k(e, r), m = $(t, n, G[e].get(r), r, e), h = m.fill === null ? "transparent" : m.color, g = m.lineFill !== null && (m.lineColor != null || m.lineFill !== void 0), _ = u ? d >= 0 ? s[r] : f[r] : 0, y = jt(_, d);
2153
+ u && (d >= 0 ? s[r] = y : f[r] = y);
2154
+ let x = L(_), S = L(y), C = n.threeDShape ?? t.threeD.shape ?? "box", T = C === "cone" || C === "pyramid", E = C === "coneToMax" || C === "pyramidToMax", A = (e) => {
2155
+ if (!T) return 1;
2156
+ let t = D && !(_ > 0) ? I.min : _, n = I.fraction(t), r = I.fraction(y), i = I.fraction(e), a = r - n;
2157
2157
  return a === 0 || !Number.isFinite(a) || !Number.isFinite(i - n) ? +(e === t) : Math.max(0, Math.min(1, 1 - (i - n) / a));
2158
- }, M = (e) => {
2159
- if (!A) return 1;
2160
- let t = x >= b ? I.max : I.min, n = C ? I.min : 0, r = I.fraction(t), i = I.fraction(n), a = I.fraction(e), o = Math.abs(r - i);
2158
+ }, j = (e) => {
2159
+ if (!E) return 1;
2160
+ let t = y >= _ ? I.max : I.min, n = D ? I.min : 0, r = I.fraction(t), i = I.fraction(n), a = I.fraction(e), o = Math.abs(r - i);
2161
2161
  return !(o > 0) || ![
2162
2162
  r,
2163
2163
  i,
2164
2164
  a
2165
2165
  ].every(Number.isFinite) ? we(e, I.min, I.max) : Math.max(0, Math.min(1, Math.abs(r - a) / o));
2166
- }, N = A ? M(S) : j(S), P = A ? M(E) : j(E);
2167
- if (s) {
2168
- let t = V.x + I.fraction(S) * V.w, n = V.x + I.fraction(E) * V.w, s = y ? _ - 1 - i : i, c = V.y + s * f + g.offset;
2169
- o.push({
2166
+ }, M = E ? j(x) : A(x), N = E ? j(S) : A(S);
2167
+ if (c) {
2168
+ let t = R.x + I.fraction(x) * R.w, n = R.x + I.fraction(S) * R.w, s = w ? b - 1 - r : r, c = R.y + s * p + l.offset;
2169
+ i.push({
2170
2170
  x: Math.min(t, n),
2171
2171
  y: c,
2172
2172
  width: Math.abs(n - t),
2173
- height: g.size,
2174
- nearDepth: a.near,
2175
- farDepth: a.far,
2176
- categoryIndex: i,
2173
+ height: l.size,
2174
+ nearDepth: o.near,
2175
+ farDepth: o.far,
2176
+ categoryIndex: r,
2177
2177
  seriesIndex: e,
2178
2178
  color: h,
2179
- fillPaint: p.fill,
2180
- lineFill: p.lineFill,
2181
- shape: O,
2179
+ fillPaint: m.fill,
2180
+ lineFill: m.lineFill,
2181
+ shape: C,
2182
2182
  baseCoord: t,
2183
2183
  endCoord: n,
2184
- baseScale: N,
2185
- endScale: P,
2184
+ baseScale: M,
2185
+ endScale: N,
2186
2186
  omitBaseCap: !1,
2187
2187
  omitEndCap: !1,
2188
- outline: v,
2189
- outlineColor: p.lineColor ?? "rgba(0,0,0,0.42)",
2190
- outlineWidth: p.lineWidthEmu == null ? .75 * r / D : Tt(p.lineWidthEmu, r),
2191
- outlineDash: p.lineDash ?? "solid",
2192
- outlineCustomDash: p.lineCustomDash,
2193
- outlineCap: p.lineCap,
2194
- outlineJoin: p.lineJoin,
2195
- labelValue: m ? l / 100 : l,
2196
- plottedLabelValue: x
2188
+ outline: g,
2189
+ outlineColor: m.lineColor ?? "rgba(0,0,0,0.42)",
2190
+ outlineWidth: m.lineWidthEmu == null ? .75 * a / U : Tt(m.lineWidthEmu, a),
2191
+ outlineDash: m.lineDash ?? "solid",
2192
+ outlineCustomDash: m.lineCustomDash,
2193
+ outlineCap: m.lineCap,
2194
+ outlineJoin: m.lineJoin,
2195
+ labelValue: v ? d / 100 : d,
2196
+ plottedLabelValue: y
2197
2197
  });
2198
2198
  } else {
2199
- let t = V.y + V.h - I.fraction(S) * V.h, n = V.y + V.h - I.fraction(E) * V.h, s = y ? _ - 1 - i : i, c = V.x + s * f + g.offset;
2200
- o.push({
2199
+ let t = R.y + R.h - I.fraction(x) * R.h, n = R.y + R.h - I.fraction(S) * R.h, s = w ? b - 1 - r : r, c = R.x + s * p + l.offset;
2200
+ i.push({
2201
2201
  x: c,
2202
2202
  y: Math.min(t, n),
2203
- width: g.size,
2203
+ width: l.size,
2204
2204
  height: Math.abs(n - t),
2205
- nearDepth: a.near,
2206
- farDepth: a.far,
2207
- categoryIndex: i,
2205
+ nearDepth: o.near,
2206
+ farDepth: o.far,
2207
+ categoryIndex: r,
2208
2208
  seriesIndex: e,
2209
2209
  color: h,
2210
- fillPaint: p.fill,
2211
- lineFill: p.lineFill,
2212
- shape: O,
2210
+ fillPaint: m.fill,
2211
+ lineFill: m.lineFill,
2212
+ shape: C,
2213
2213
  baseCoord: t,
2214
2214
  endCoord: n,
2215
- baseScale: N,
2216
- endScale: P,
2215
+ baseScale: M,
2216
+ endScale: N,
2217
2217
  omitBaseCap: !1,
2218
2218
  omitEndCap: !1,
2219
- outline: v,
2220
- outlineColor: p.lineColor ?? "rgba(0,0,0,0.42)",
2221
- outlineWidth: p.lineWidthEmu == null ? .75 * r / D : Tt(p.lineWidthEmu, r),
2222
- outlineDash: p.lineDash ?? "solid",
2223
- outlineCustomDash: p.lineCustomDash,
2224
- outlineCap: p.lineCap,
2225
- outlineJoin: p.lineJoin,
2226
- labelValue: m ? l / 100 : l,
2227
- plottedLabelValue: x
2219
+ outline: g,
2220
+ outlineColor: m.lineColor ?? "rgba(0,0,0,0.42)",
2221
+ outlineWidth: m.lineWidthEmu == null ? .75 * a / U : Tt(m.lineWidthEmu, a),
2222
+ outlineDash: m.lineDash ?? "solid",
2223
+ outlineCustomDash: m.lineCustomDash,
2224
+ outlineCap: m.lineCap,
2225
+ outlineJoin: m.lineJoin,
2226
+ labelValue: v ? d / 100 : d,
2227
+ plottedLabelValue: y
2228
2228
  });
2229
2229
  }
2230
2230
  }
2231
2231
  }
2232
- if (c) {
2233
- let e = Et(o, _);
2234
- for (let t = 0; t < _; t++) {
2232
+ if (u) {
2233
+ let e = Et(i, b);
2234
+ for (let t = 0; t < b; t++) {
2235
2235
  let n = e[t];
2236
2236
  for (let e of [-1, 1]) {
2237
2237
  let t = n.filter((t) => Math.sign(t.labelValue) === e && !Bt(t.color) && Math.abs(t.endCoord - t.baseCoord) > 1e-9).sort((e, t) => e.seriesIndex - t.seriesIndex);
@@ -2247,70 +2247,70 @@ function kn(e, t, n, r, a) {
2247
2247
  }
2248
2248
  }
2249
2249
  }
2250
- bn(e, t, p, I, s ? "horizontal" : "vertical", _, b, y, r);
2251
- let v = {
2250
+ bn(e, t, _, I, c ? "horizontal" : "vertical", b, T, w, a);
2251
+ let g = {
2252
2252
  remaining: rt,
2253
2253
  exceeded: !1
2254
- }, x = o.map((t) => {
2255
- let n = Ut(p, t.shape, s, t.x, t.y, t.width, t.height, t.baseCoord, t.endCoord, t.nearDepth, t.farDepth, t.color, t.baseScale, t.endScale, t.omitBaseCap, t.omitEndCap, t.outline && t.outlineColor ? {
2254
+ }, y = i.map((t) => {
2255
+ let n = Ut(_, t.shape, c, t.x, t.y, t.width, t.height, t.baseCoord, t.endCoord, t.nearDepth, t.farDepth, t.color, t.baseScale, t.endScale, t.omitBaseCap, t.omitEndCap, t.outline && t.outlineColor ? {
2256
2256
  color: t.outlineColor,
2257
2257
  width: t.outlineWidth,
2258
- dash: L(t.outlineCustomDash, t.outlineDash, t.outlineWidth),
2258
+ dash: x(t.outlineCustomDash, t.outlineDash, t.outlineWidth),
2259
2259
  cap: t.outlineCap,
2260
2260
  join: t.outlineJoin
2261
- } : void 0, v);
2262
- return Jt(e, n, "fill", t.fillPaint, a), Jt(e, n, "outline", t.lineFill, a), {
2261
+ } : void 0, g);
2262
+ return Jt(e, n, "fill", t.fillPaint, o), Jt(e, n, "outline", t.lineFill, o), {
2263
2263
  item: t,
2264
2264
  faces: n
2265
2265
  };
2266
- }), S = x.flatMap((e) => e.faces);
2267
- if (v.exceeded) return Yt(e, n), !0;
2266
+ }), S = y.flatMap((e) => e.faces);
2267
+ if (g.exceeded) return Yt(e, n), !0;
2268
2268
  for (let t of nt(S)) Kt(e, t);
2269
- for (let { item: n, faces: i } of x) {
2270
- let a = t.series[n.seriesIndex], o = U[n.seriesIndex].get(n.categoryIndex), s = Le(t, a, n.categoryIndex, n.seriesIndex), c = g(o?.chartexStyle), l = g(a.chartexStyle);
2271
- Se(e, c ?? l, be(t, "dataPoint3D", n.seriesIndex), c ? n.categoryIndex : s, r, (e) => qt(e, i), s);
2269
+ for (let { item: n, faces: r } of y) {
2270
+ let i = t.series[n.seriesIndex], o = G[n.seriesIndex].get(n.categoryIndex), s = Le(t, i, n.categoryIndex, n.seriesIndex), c = m(o?.chartexStyle), u = m(i.chartexStyle);
2271
+ xe(e, c ?? u, l(t, "dataPoint3D", n.seriesIndex), c ? n.categoryIndex : s, a, (e) => qt(e, r), s);
2272
2272
  }
2273
- for (let i of o) {
2274
- let o = t.series[i.seriesIndex], c = s ? p.project(i.endCoord, i.y + i.height / 2, (i.nearDepth + i.farDepth) / 2) : p.project(i.x + i.width / 2, i.endCoord, (i.nearDepth + i.farDepth) / 2), l = te[i.seriesIndex].get(i.categoryIndex);
2275
- nn(t, o, l) && ee.push(() => tn(e, t, o, i.seriesIndex, i.categoryIndex, i.labelValue, c, n, r, 0, void 0, l, "t", c, !0, t.valAxisDisplayUnits, I.max, i.plottedLabelValue, a));
2273
+ for (let r of i) {
2274
+ let i = t.series[r.seriesIndex], s = c ? _.project(r.endCoord, r.y + r.height / 2, (r.nearDepth + r.farDepth) / 2) : _.project(r.x + r.width / 2, r.endCoord, (r.nearDepth + r.farDepth) / 2), l = q[r.seriesIndex].get(r.categoryIndex);
2275
+ nn(t, i, l) && ee.push(() => tn(e, t, i, r.seriesIndex, r.categoryIndex, r.labelValue, s, n, a, 0, void 0, l, "t", s, !0, t.valAxisDisplayUnits, I.max, r.plottedLabelValue, o));
2276
2276
  }
2277
2277
  } else {
2278
- let i = t.series.map(() => Array(_).fill(0)), o = t.series.map(() => Array(_).fill(0));
2279
- if (c) {
2280
- let e = Array(_).fill(0), n = Array(_).fill(0);
2281
- for (let r = 0; r < t.series.length; r++) for (let t = 0; t < _; t++) {
2282
- let a = T(r, t), s = a >= 0 ? e[t] : n[t];
2283
- i[r][t] = s, o[r][t] = jt(s, a), a >= 0 ? e[t] = jt(e[t], a) : n[t] = jt(n[t], a);
2278
+ let i = t.series.map(() => Array(b).fill(0)), s = t.series.map(() => Array(b).fill(0));
2279
+ if (u) {
2280
+ let e = Array(b).fill(0), n = Array(b).fill(0);
2281
+ for (let r = 0; r < t.series.length; r++) for (let t = 0; t < b; t++) {
2282
+ let a = k(r, t), o = a >= 0 ? e[t] : n[t];
2283
+ i[r][t] = o, s[r][t] = jt(o, a), a >= 0 ? e[t] = jt(e[t], a) : n[t] = jt(n[t], a);
2284
2284
  }
2285
2285
  }
2286
- let s = (e) => {
2287
- let t = p.seriesDepth(e, H, c), n = 0, r = 0;
2288
- for (let i = 0; i < _; i++) {
2289
- if (!w(e, i)) continue;
2290
- let a = c ? o[e][i] : T(e, i), s = V.x + q(i, _, b, y) * V.w, l = V.y + V.h - I.fraction(z(a)) * V.h;
2291
- n += p.cameraDepth(s, l, t), r++;
2286
+ let c = (e) => {
2287
+ let t = _.seriesDepth(e, z, u), n = 0, i = 0;
2288
+ for (let a = 0; a < b; a++) {
2289
+ if (!O(e, a)) continue;
2290
+ let o = u ? s[e][a] : k(e, a), c = R.x + r(a, b, T, w) * R.w, l = R.y + R.h - I.fraction(L(o)) * R.h;
2291
+ n += _.cameraDepth(c, l, t), i++;
2292
2292
  }
2293
- return r > 0 ? n / r : -Infinity;
2294
- }, l = t.series.map((e, t) => t).sort((e, t) => s(e) - s(t) || t - e), u = t.series.map((e, n) => $(t, e, void 0, n, n)), d = [], f = [], h = !1;
2295
- for (let s of l) {
2296
- if (h) break;
2297
- let l = t.series[s], g = u[s], v = g.fill === null ? "transparent" : g.color, S = c ? p.prismInterval(0, 1, !0) : p.prismInterval(s, H, !1), C = V.x + V.w / 2, E = V.y + V.h / 2, D = p.cameraDepth(C, E, S.near) >= p.cameraDepth(C, E, S.far) ? S.near : S.far, O = [], k = [], A = [], j = [], M = [], N = [], R = [], z = [], B = [], W = [];
2298
- for (let e = 0; e < _; e++) {
2299
- if (!w(s, e)) {
2300
- O.push(null), k.push(null), A.push(null), j.push(null), M.push(null), N.push(null), R.push(null), z.push(null), B.push(null), W.push(null);
2293
+ return i > 0 ? n / i : -Infinity;
2294
+ }, l = t.series.map((e, t) => t).sort((e, t) => c(e) - c(t) || t - e), d = t.series.map((e, n) => $(t, e, void 0, n, n)), f = [], p = [], m = !1;
2295
+ for (let c of l) {
2296
+ if (m) break;
2297
+ let l = t.series[c], h = d[c], g = h.fill === null ? "transparent" : h.color, y = u ? _.prismInterval(0, 1, !0) : _.prismInterval(c, z, !1), S = R.x + R.w / 2, D = R.y + R.h / 2, A = _.cameraDepth(S, D, y.near) >= _.cameraDepth(S, D, y.far) ? y.near : y.far, j = [], M = [], N = [], P = [], F = [], L = [], B = [], H = [], U = [], K = [];
2298
+ for (let e = 0; e < b; e++) {
2299
+ if (!O(c, e)) {
2300
+ j.push(null), M.push(null), N.push(null), P.push(null), F.push(null), L.push(null), B.push(null), H.push(null), U.push(null), K.push(null);
2301
2301
  continue;
2302
2302
  }
2303
- let n = c ? o[s][e] : T(s, e), r = c ? i[s][e] : 0, a = V.x + q(e, _, b, y) * V.w, l = I.fraction(n), u = I.fraction(r), d = Number.isFinite(u) ? u : r <= I.min ? 0 : 1, f = Number.isFinite(l) && l >= 0 && l <= 1, m = Number.isFinite(l) ? Math.max(0, Math.min(1, l)) : n <= I.min ? 0 : 1, h = V.y + V.h - m * V.h, g = V.y + V.h - Math.max(0, Math.min(1, d)) * V.h;
2304
- O.push(t.chartType.toLowerCase().includes("area") || f ? p.project(a, h, D) : null), k.push(p.project(a, g, D)), A.push(f ? p.cameraDepth(a, h, D) : null), j.push(p.cameraDepth(a, g, D)), M.push(n), N.push(a), R.push(h), z.push(g), B.push(l), W.push(d);
2303
+ let n = u ? s[c][e] : k(c, e), a = u ? i[c][e] : 0, o = R.x + r(e, b, T, w) * R.w, l = I.fraction(n), d = I.fraction(a), f = Number.isFinite(d) ? d : a <= I.min ? 0 : 1, p = Number.isFinite(l) && l >= 0 && l <= 1, m = Number.isFinite(l) ? Math.max(0, Math.min(1, l)) : n <= I.min ? 0 : 1, h = R.y + R.h - m * R.h, g = R.y + R.h - Math.max(0, Math.min(1, f)) * R.h;
2304
+ j.push(t.chartType.toLowerCase().includes("area") || p ? _.project(o, h, A) : null), M.push(_.project(o, g, A)), N.push(p ? _.cameraDepth(o, h, A) : null), P.push(_.cameraDepth(o, g, A)), F.push(n), L.push(o), B.push(h), H.push(g), U.push(l), K.push(f);
2305
2305
  }
2306
- let G = [], K = null;
2307
- for (let e = 0; e < O.length; e++) {
2308
- let t = O[e], n = k[e];
2306
+ let ne = [], J = null;
2307
+ for (let e = 0; e < j.length; e++) {
2308
+ let t = j[e], n = M[e];
2309
2309
  if (!t || !n) {
2310
- x === "gap" && (K && G.push(K), K = null);
2310
+ E === "gap" && (J && ne.push(J), J = null);
2311
2311
  continue;
2312
2312
  }
2313
- K ??= {
2313
+ J ??= {
2314
2314
  upper: [],
2315
2315
  lower: [],
2316
2316
  upperDepths: [],
@@ -2321,74 +2321,74 @@ function kn(e, t, n, r, a) {
2321
2321
  lowerYs: [],
2322
2322
  upperFractions: [],
2323
2323
  lowerFractions: []
2324
- }, K.upper.push(t), K.lower.push(n), K.upperDepths.push(A[e] ?? 0), K.lowerDepths.push(j[e] ?? 0), K.indices.push(e), K.sceneXs.push(N[e] ?? 0), K.upperYs.push(R[e] ?? 0), K.lowerYs.push(z[e] ?? 0), K.upperFractions.push(B[e] ?? 0), K.lowerFractions.push(W[e] ?? 0);
2324
+ }, J.upper.push(t), J.lower.push(n), J.upperDepths.push(N[e] ?? 0), J.lowerDepths.push(P[e] ?? 0), J.indices.push(e), J.sceneXs.push(L[e] ?? 0), J.upperYs.push(B[e] ?? 0), J.lowerYs.push(H[e] ?? 0), J.upperFractions.push(U[e] ?? 0), J.lowerFractions.push(K[e] ?? 0);
2325
2325
  }
2326
- K && G.push(K);
2327
- let J = [], ne = [];
2326
+ J && ne.push(J);
2327
+ let Y = [], X = [];
2328
2328
  if (t.chartType.toLowerCase().includes("area")) {
2329
- for (let t of G) {
2329
+ for (let t of ne) {
2330
2330
  let n = null;
2331
2331
  for (let r = 0; r + 1 < t.upper.length; r++) {
2332
2332
  let i = Xe(t.lowerFractions[r], t.lowerFractions[r + 1], t.upperFractions[r], t.upperFractions[r + 1]);
2333
2333
  for (let a = 0; a < i.length; a++) {
2334
- let o = i[a], s = t.sceneXs[r] + (t.sceneXs[r + 1] - t.sceneXs[r]) * o.startT, c = t.sceneXs[r] + (t.sceneXs[r + 1] - t.sceneXs[r]) * o.endT, l = V.y + V.h - o.lowerStart * V.h, u = V.y + V.h - o.lowerEnd * V.h, f = V.y + V.h - o.upperStart * V.h, m = V.y + V.h - o.upperEnd * V.h, g = {
2335
- ...p.project(s, f, D),
2336
- cameraDepth: p.cameraDepth(s, f, D),
2337
- cameraWeight: p.cameraProjectionWeight(s, f, D)
2338
- }, _ = {
2339
- ...p.project(c, m, D),
2340
- cameraDepth: p.cameraDepth(c, m, D),
2341
- cameraWeight: p.cameraProjectionWeight(c, m, D)
2334
+ let o = i[a], s = t.sceneXs[r] + (t.sceneXs[r + 1] - t.sceneXs[r]) * o.startT, c = t.sceneXs[r] + (t.sceneXs[r + 1] - t.sceneXs[r]) * o.endT, l = R.y + R.h - o.lowerStart * R.h, u = R.y + R.h - o.lowerEnd * R.h, d = R.y + R.h - o.upperStart * R.h, p = R.y + R.h - o.upperEnd * R.h, h = {
2335
+ ..._.project(s, d, A),
2336
+ cameraDepth: _.cameraDepth(s, d, A),
2337
+ cameraWeight: _.cameraProjectionWeight(s, d, A)
2338
+ }, v = {
2339
+ ..._.project(c, p, A),
2340
+ cameraDepth: _.cameraDepth(c, p, A),
2341
+ cameraWeight: _.cameraProjectionWeight(c, p, A)
2342
2342
  };
2343
- n != null && Math.hypot(n.at(-1).x - g.x, n.at(-1).y - g.y) <= 1e-8 ? n.push(_) : (n && n.length >= 2 && J.push(n), n = [g, _]);
2344
- let y = Ht(p, s, c, l, u, f, m, S.near, S.far, v, r === 0 && a === 0 && o.startT === 0, r + 2 === t.upper.length && a + 1 === i.length && o.endT === 1);
2345
- for (let t of y) {
2346
- if (d.length >= 1e4) {
2347
- h = !0;
2343
+ n != null && Math.hypot(n.at(-1).x - h.x, n.at(-1).y - h.y) <= 1e-8 ? n.push(v) : (n && n.length >= 2 && Y.push(n), n = [h, v]);
2344
+ let b = Ht(_, s, c, l, u, d, p, y.near, y.far, g, r === 0 && a === 0 && o.startT === 0, r + 2 === t.upper.length && a + 1 === i.length && o.endT === 1);
2345
+ for (let t of b) {
2346
+ if (f.length >= 1e4) {
2347
+ m = !0;
2348
2348
  break;
2349
2349
  }
2350
- d.push({
2350
+ f.push({
2351
2351
  points: t.points,
2352
2352
  cameraDepth: t.cameraDepth,
2353
2353
  cameraDepths: t.cameraDepths,
2354
2354
  cameraWeights: t.cameraWeights,
2355
2355
  layer: 0,
2356
2356
  paint: () => Kt(e, t)
2357
- }), ne.push(t);
2357
+ }), X.push(t);
2358
2358
  }
2359
- if (h) break;
2359
+ if (m) break;
2360
2360
  }
2361
- if (h) break;
2361
+ if (m) break;
2362
2362
  }
2363
- if (n && n.length >= 2 && J.push(n), h) break;
2363
+ if (n && n.length >= 2 && Y.push(n), m) break;
2364
2364
  }
2365
- Jt(e, ne, "fill", g.fill, a);
2365
+ Jt(e, X, "fill", h.fill, o);
2366
2366
  }
2367
- let Y = [];
2367
+ let re = [];
2368
2368
  if (!t.chartType.toLowerCase().includes("area")) {
2369
2369
  let e = [], t = null;
2370
- for (let n = 0; n < _; n++) {
2371
- let r = M[n], i = r == null ? NaN : I.fraction(r);
2372
- if (r == null || !Number.isFinite(i)) {
2373
- x === "gap" && t && (e.push(t), t = null);
2370
+ for (let n = 0; n < b; n++) {
2371
+ let i = F[n], a = i == null ? NaN : I.fraction(i);
2372
+ if (i == null || !Number.isFinite(a)) {
2373
+ E === "gap" && t && (e.push(t), t = null);
2374
2374
  continue;
2375
2375
  }
2376
2376
  t ??= [], t.push({
2377
- x: V.x + q(n, _, b, y) * V.w,
2378
- fraction: i,
2377
+ x: R.x + r(n, b, T, w) * R.w,
2378
+ fraction: a,
2379
2379
  ownerIndex: n
2380
2380
  });
2381
2381
  }
2382
2382
  t && e.push(t);
2383
2383
  let n = (e) => {
2384
- let t = Math.max(0, Math.min(1, e.fraction)), n = V.y + V.h - t * V.h;
2384
+ let t = Math.max(0, Math.min(1, e.fraction)), n = R.y + R.h - t * R.h;
2385
2385
  return {
2386
- ...p.project(e.x, n, D),
2387
- cameraDepth: p.cameraDepth(e.x, n, D),
2388
- cameraWeight: p.cameraProjectionWeight(e.x, n, D)
2386
+ ..._.project(e.x, n, A),
2387
+ cameraDepth: _.cameraDepth(e.x, n, A),
2388
+ cameraWeight: _.cameraProjectionWeight(e.x, n, A)
2389
2389
  };
2390
- }, r = (e) => {
2391
- e && e.path.length >= 2 && Y.push(e);
2390
+ }, i = (e) => {
2391
+ e && e.path.length >= 2 && re.push(e);
2392
2392
  };
2393
2393
  for (let t of e) {
2394
2394
  if (t.length < 2) continue;
@@ -2415,82 +2415,82 @@ function kn(e, t, n, r, a) {
2415
2415
  });
2416
2416
  }
2417
2417
  }
2418
- let i = null, a = 0;
2418
+ let r = null, a = 0;
2419
2419
  for (let t = 0; t + 1 < e.length; t++) {
2420
- let o = e[t], s = e[t + 1], c = (e) => p.project(e.x, V.y + V.h - e.fraction * V.h, D), l = c(o), u = c(s), d = Math.hypot(u.x - l.x, u.y - l.y), f = Number.isFinite(d) ? d : Math.hypot(s.x - o.x, (s.fraction - o.fraction) * V.h), m = Ye(o.fraction, s.fraction);
2421
- if (!m || m.endT - m.startT <= 1e-12) {
2422
- r(i), i = null, a += f;
2420
+ let o = e[t], s = e[t + 1], c = (e) => _.project(e.x, R.y + R.h - e.fraction * R.h, A), l = c(o), u = c(s), d = Math.hypot(u.x - l.x, u.y - l.y), f = Number.isFinite(d) ? d : Math.hypot(s.x - o.x, (s.fraction - o.fraction) * R.h), p = Ye(o.fraction, s.fraction);
2421
+ if (!p || p.endT - p.startT <= 1e-12) {
2422
+ i(r), r = null, a += f;
2423
2423
  continue;
2424
2424
  }
2425
- let h = (e) => ({
2425
+ let m = (e) => ({
2426
2426
  x: o.x + (s.x - o.x) * e,
2427
2427
  fraction: o.fraction + (s.fraction - o.fraction) * e,
2428
2428
  ownerIndex: s.ownerIndex
2429
- }), g = c(h(m.startT)), _ = Math.hypot(g.x - l.x, g.y - l.y), v = n(h(m.startT)), y = n(h(m.endT)), b = h(m.startT), x = h(m.endT), S = (e) => ({
2429
+ }), h = c(m(p.startT)), g = Math.hypot(h.x - l.x, h.y - l.y), v = n(m(p.startT)), y = n(m(p.endT)), b = m(p.startT), x = m(p.endT), S = (e) => ({
2430
2430
  x: e.x,
2431
- y: V.y + V.h - Math.max(0, Math.min(1, e.fraction)) * V.h
2431
+ y: R.y + R.h - Math.max(0, Math.min(1, e.fraction)) * R.h
2432
2432
  });
2433
- i != null && Math.hypot(i.path.at(-1).x - v.x, i.path.at(-1).y - v.y) <= 1e-8 && i.ownerIndex === s.ownerIndex ? (i.path.push(y), i.modelPath.push(S(x)), i.endClipped = t + 1 < e.length - 1 || m.endT < 1) : (r(i), i = {
2433
+ r != null && Math.hypot(r.path.at(-1).x - v.x, r.path.at(-1).y - v.y) <= 1e-8 && r.ownerIndex === s.ownerIndex ? (r.path.push(y), r.modelPath.push(S(x)), r.endClipped = t + 1 < e.length - 1 || p.endT < 1) : (i(r), r = {
2434
2434
  path: [v, y],
2435
2435
  modelPath: [S(b), S(x)],
2436
2436
  ownerIndex: s.ownerIndex,
2437
- startClipped: t > 0 || m.startT > 0,
2438
- endClipped: t + 1 < e.length - 1 || m.endT < 1,
2439
- dashOffset: a + (Number.isFinite(_) ? _ : f * m.startT)
2437
+ startClipped: t > 0 || p.startT > 0,
2438
+ endClipped: t + 1 < e.length - 1 || p.endT < 1,
2439
+ dashOffset: a + (Number.isFinite(g) ? g : f * p.startT)
2440
2440
  }), a += f;
2441
2441
  }
2442
- r(i);
2442
+ i(r);
2443
2443
  }
2444
2444
  }
2445
- let X = t.chartType.toLowerCase().includes("area"), ie = l.lineHidden != null || l.lineColor != null || l.lineWidthEmu != null || l.chartexStyle?.lineHidden != null || l.chartexStyle?.lineColors?.some(Boolean) || l.chartexStyle?.lineWidthEmu != null || l.chartexStyle?.lineDash != null || l.chartexStyle?.lineCap != null || l.chartexStyle?.lineJoin != null || g.lineColor != null || g.lineFill !== void 0;
2446
- if (!X || g.lineFill !== null && ie) {
2447
- let n = /* @__PURE__ */ new Map(), i = (e) => {
2448
- let r = U[s].get(e);
2449
- if (!Pt(r)) return g;
2445
+ let Z = t.chartType.toLowerCase().includes("area"), ie = l.lineHidden != null || l.lineColor != null || l.lineWidthEmu != null || l.chartexStyle?.lineHidden != null || l.chartexStyle?.lineColors?.some(Boolean) || l.chartexStyle?.lineWidthEmu != null || l.chartexStyle?.lineDash != null || l.chartexStyle?.lineCap != null || l.chartexStyle?.lineJoin != null || h.lineColor != null || h.lineFill !== void 0;
2446
+ if (!Z || h.lineFill !== null && ie) {
2447
+ let n = /* @__PURE__ */ new Map(), r = (e) => {
2448
+ let r = G[c].get(e);
2449
+ if (!Pt(r)) return h;
2450
2450
  let i = n.get(e);
2451
- return i || (i = $(t, l, r, e, s), n.set(e, i)), i;
2452
- }, o = /* @__PURE__ */ new Map(), c = {
2451
+ return i || (i = $(t, l, r, e, c), n.set(e, i)), i;
2452
+ }, i = /* @__PURE__ */ new Map(), s = {
2453
2453
  remaining: rt,
2454
2454
  exceeded: !1
2455
- }, u = (t, n, i, a = i, s = 0, l) => {
2455
+ }, u = (t, n, r, o = r, c = 0, l) => {
2456
2456
  if (n.lineFill === null) return;
2457
- let u = n === g ? v : n.color, f = n.lineColor ?? Ne(u, .7), m = n.lineWidthEmu ? Math.max(.5, n.lineWidthEmu / F) * r : X ? .75 * r : Math.max(1, 2 * r), _ = {
2458
- width: m,
2459
- dash: L(n.lineCustomDash, n.lineDash, m),
2460
- dashOffset: s,
2457
+ let u = n === h ? g : n.color, d = n.lineColor ?? Ne(u, .7), p = n.lineWidthEmu ? Math.max(.5, n.lineWidthEmu / W) * a : Z ? .75 * a : Math.max(1, 2 * a), v = {
2458
+ width: p,
2459
+ dash: x(n.lineCustomDash, n.lineDash, p),
2460
+ dashOffset: c,
2461
2461
  lineCap: n.lineCap,
2462
- startCap: i,
2463
- endCap: a,
2462
+ startCap: r,
2463
+ endCap: o,
2464
2464
  lineJoin: n.lineJoin
2465
2465
  };
2466
- if (!X && l && l.length >= 2) {
2466
+ if (!Z && l && l.length >= 2) {
2467
2467
  let t = dt(l.map((e) => ({
2468
2468
  ...e,
2469
2469
  cameraDepth: 0,
2470
2470
  cameraWeight: 1
2471
- })), _);
2471
+ })), v);
2472
2472
  if (t == null) {
2473
- h = !0;
2473
+ m = !0;
2474
2474
  return;
2475
2475
  }
2476
- let r = o.get(n) ?? [];
2476
+ let r = i.get(n) ?? [];
2477
2477
  for (let n of t) {
2478
2478
  let t = qe({
2479
2479
  outline: n.points,
2480
- nearDepth: S.near,
2481
- farDepth: S.far
2480
+ nearDepth: y.near,
2481
+ farDepth: y.far
2482
2482
  });
2483
2483
  if (!t) continue;
2484
- let i = Wt(p, t, f, void 0, c).map((e) => ({
2484
+ let i = Wt(_, t, d, void 0, s).map((e) => ({
2485
2485
  ...e,
2486
2486
  paintRole: "outline"
2487
2487
  }));
2488
- if (c.exceeded) {
2489
- h = !0;
2488
+ if (s.exceeded) {
2489
+ m = !0;
2490
2490
  return;
2491
2491
  }
2492
2492
  r.push(...i);
2493
- for (let t of i) d.push({
2493
+ for (let t of i) f.push({
2494
2494
  points: t.points,
2495
2495
  cameraDepth: t.cameraDepth,
2496
2496
  cameraDepths: t.cameraDepths,
@@ -2499,30 +2499,30 @@ function kn(e, t, n, r, a) {
2499
2499
  paint: () => Kt(e, t)
2500
2500
  });
2501
2501
  }
2502
- o.set(n, r);
2502
+ i.set(n, r);
2503
2503
  return;
2504
2504
  }
2505
- let y = dt(t, _);
2506
- if (y == null) {
2507
- h = !0;
2505
+ let b = dt(t, v);
2506
+ if (b == null) {
2507
+ m = !0;
2508
2508
  return;
2509
2509
  }
2510
- if (d.length + y.length > 1e4) {
2511
- h = !0;
2510
+ if (f.length + b.length > 1e4) {
2511
+ m = !0;
2512
2512
  return;
2513
2513
  }
2514
- for (let t of y) {
2514
+ for (let t of b) {
2515
2515
  let r = {
2516
2516
  points: t.points,
2517
- color: f,
2517
+ color: d,
2518
2518
  paintRole: "outline",
2519
2519
  shade: 0,
2520
2520
  cameraDepth: t.cameraDepth,
2521
2521
  cameraDepths: t.cameraDepths,
2522
2522
  cameraWeights: t.cameraWeights,
2523
2523
  outline: !1
2524
- }, i = o.get(n) ?? [];
2525
- i.push(r), o.set(n, i), d.push({
2524
+ }, a = i.get(n) ?? [];
2525
+ a.push(r), i.set(n, a), f.push({
2526
2526
  points: t.points,
2527
2527
  cameraDepth: t.cameraDepth,
2528
2528
  cameraDepths: t.cameraDepths,
@@ -2532,89 +2532,89 @@ function kn(e, t, n, r, a) {
2532
2532
  });
2533
2533
  }
2534
2534
  };
2535
- if (X) for (let e of J) u(e, g, g.lineCap);
2536
- else for (let e of Y) {
2537
- let t = i(e.ownerIndex);
2535
+ if (Z) for (let e of Y) u(e, h, h.lineCap);
2536
+ else for (let e of re) {
2537
+ let t = r(e.ownerIndex);
2538
2538
  u(e.path, t, e.startClipped ? "butt" : t.lineCap, e.endClipped ? "butt" : t.lineCap, e.dashOffset, e.modelPath);
2539
2539
  }
2540
- for (let [t, n] of o) Jt(e, n, "outline", t.lineFill, a);
2540
+ for (let [t, n] of i) Jt(e, n, "outline", t.lineFill, o);
2541
2541
  }
2542
- let oe = (X ? l.showMarker === !0 || ae(l) : l.showMarker === !0) && l.markerSymbol !== "none";
2543
- if ((t.chartType.toLowerCase().includes("line") || X) && (oe || re(l))) for (let n = 0; n < O.length; n++) {
2544
- let i = O[n];
2545
- if (!i) continue;
2546
- let o = U[s].get(n), c = P(l, o, "circle", oe);
2547
- if (c === "none") continue;
2548
- let u = o?.markerSize ?? l.markerSize ?? 5, d = ln(t, l, o, n, s, l.color ?? xt[s % xt.length], r);
2549
- f.push(() => en(e, i, c, Math.max(2, u) * r, d.fill === "00000000" ? "transparent" : `#${d.fill.replace(/^#/, "")}`, d.line === "00000000" ? "rgba(0,0,0,0)" : `#${d.line.replace(/^#/, "")}`, d.lineWidth, d.fillPaint, a, r, d.effectDirect, d.effectFallback, d.effectIndex, d.effectFallbackIndex, d.linePaint, d.lineDash, d.lineCustomDash, d.lineCap, d.lineJoin));
2542
+ let ae = (Z ? l.showMarker === !0 || C(l) : l.showMarker === !0) && l.markerSymbol !== "none";
2543
+ if ((t.chartType.toLowerCase().includes("line") || Z) && (ae || V(l))) for (let n = 0; n < j.length; n++) {
2544
+ let r = j[n];
2545
+ if (!r) continue;
2546
+ let i = G[c].get(n), s = te(l, i, "circle", ae);
2547
+ if (s === "none") continue;
2548
+ let u = i?.markerSize ?? l.markerSize ?? 5, d = ln(t, l, i, n, c, l.color ?? xt[c % xt.length], a);
2549
+ p.push(() => en(e, r, s, Math.max(2, u) * a, d.fill === "00000000" ? "transparent" : `#${d.fill.replace(/^#/, "")}`, d.line === "00000000" ? "rgba(0,0,0,0)" : `#${d.line.replace(/^#/, "")}`, d.lineWidth, d.fillPaint, o, a, d.effectDirect, d.effectFallback, d.effectIndex, d.effectFallbackIndex, d.linePaint, d.lineDash, d.lineCustomDash, d.lineCap, d.lineJoin));
2550
2550
  }
2551
- for (let i = 0; i < O.length; i++) {
2552
- let u = O[i];
2553
- if (!u) continue;
2554
- let d = T(s, i), f = U[s].get(i), p = f?.markerSize ?? l.markerSize ?? 5, h = te[s].get(i);
2555
- nn(t, l, h) && ee.push(() => tn(e, t, l, s, i, m ? d / 100 : d, u, n, r, l.showMarker === !0 || f?.markerSymbol != null ? p * r / 2 : 0, void 0, h, "t", u, !0, t.valAxisDisplayUnits, I.max, c ? o[s][i] : d, a));
2551
+ for (let r = 0; r < j.length; r++) {
2552
+ let i = j[r];
2553
+ if (!i) continue;
2554
+ let d = k(c, r), f = G[c].get(r), p = f?.markerSize ?? l.markerSize ?? 5, m = q[c].get(r);
2555
+ nn(t, l, m) && ee.push(() => tn(e, t, l, c, r, v ? d / 100 : d, i, n, a, l.showMarker === !0 || f?.markerSymbol != null ? p * a / 2 : 0, void 0, m, "t", i, !0, t.valAxisDisplayUnits, I.max, u ? s[c][r] : d, o));
2556
2556
  }
2557
2557
  }
2558
- if (h) return Yt(e, n), !0;
2559
- for (let e of nt(d)) e.paint();
2560
- for (let e of f) e();
2561
- }
2562
- xn(e, t, p, I, _, b, y, r, s ? "horizontal" : "vertical"), On(e, t, p, I, _, b, y, s ? "horizontal" : "vertical", o, r), cn(e, t, n, p, I, _, b, y, s ? "horizontal" : "vertical", o, r);
2563
- let W = Dn(t, p, I, _, b, y, s ? "horizontal" : "vertical"), G = (e, t) => {
2564
- if (t !== "low" && t !== "high") return W;
2565
- let n = p.topology.nearDepth, r = W.axisX, i = W.axisY;
2566
- if (e === "value" === s) {
2567
- let e = V.y, r = V.y + V.h, a = p.project(V.x + V.w / 2, e, n), o = p.project(V.x + V.w / 2, r, n), s = a.y >= o.y ? e : r;
2558
+ if (m) return Yt(e, n), !0;
2559
+ for (let e of nt(f)) e.paint();
2560
+ for (let e of p) e();
2561
+ }
2562
+ xn(e, t, _, I, b, T, w, a, c ? "horizontal" : "vertical"), On(e, t, _, I, b, T, w, c ? "horizontal" : "vertical", s, a), cn(e, t, n, _, I, b, T, w, c ? "horizontal" : "vertical", s, a);
2563
+ let ne = Dn(t, _, I, b, T, w, c ? "horizontal" : "vertical"), J = (e, t) => {
2564
+ if (t !== "low" && t !== "high") return ne;
2565
+ let n = _.topology.nearDepth, r = ne.axisX, i = ne.axisY;
2566
+ if (e === "value" === c) {
2567
+ let e = R.y, r = R.y + R.h, a = _.project(R.x + R.w / 2, e, n), o = _.project(R.x + R.w / 2, r, n), s = a.y >= o.y ? e : r;
2568
2568
  i = t === "low" ? s : s === e ? r : e;
2569
2569
  } else {
2570
- let e = V.x, i = V.x + V.w, a = p.project(e, V.y + V.h / 2, n), o = p.project(i, V.y + V.h / 2, n), s = a.x <= o.x ? e : i;
2570
+ let e = R.x, i = R.x + R.w, a = _.project(e, R.y + R.h / 2, n), o = _.project(i, R.y + R.h / 2, n), s = a.x <= o.x ? e : i;
2571
2571
  r = t === "low" ? s : s === e ? i : e;
2572
2572
  }
2573
2573
  return {
2574
2574
  axisX: r,
2575
2575
  axisY: i,
2576
2576
  depth: n,
2577
- horizontalStart: p.project(V.x, i, n),
2578
- horizontalEnd: p.project(V.x + V.w, i, n),
2579
- verticalStart: p.project(r, V.y + V.h, n),
2580
- verticalEnd: p.project(r, V.y, n)
2577
+ horizontalStart: _.project(R.x, i, n),
2578
+ horizontalEnd: _.project(R.x + R.w, i, n),
2579
+ verticalStart: _.project(r, R.y + R.h, n),
2580
+ verticalEnd: _.project(r, R.y, n)
2581
2581
  };
2582
- }, K = G("value", t.valAxisTickLabelPos), J = G("category", t.catAxisTickLabelPos), ne = j(t.valAxisFontSizeHpt, r) ?? 9 * r;
2583
- if (e.font = `${t.valAxisFontItalic ? "italic " : ""}${t.valAxisFontBold ? "bold " : ""}${ne}px ${Lt(t, t.valAxisFontFace)}`, e.fillStyle = t.valAxisFontColor ? `#${t.valAxisFontColor}` : "#595959", e.textAlign = s ? "center" : "right", e.textBaseline = s ? "top" : "middle", !t.valAxisHidden && t.valAxisTickLabelPos !== "none") {
2584
- let { axisX: n, axisY: a, depth: o } = K, c = p.project(V.x + V.w / 2, V.y + V.h / 2, o), l = Sn(s ? K.horizontalStart : K.verticalStart, s ? K.horizontalEnd : K.verticalEnd, c, s ? "vertical" : "horizontal");
2582
+ }, Y = J("value", t.valAxisTickLabelPos), X = J("category", t.catAxisTickLabelPos), re = H(t.valAxisFontSizeHpt, a) ?? 9 * a;
2583
+ if (e.font = `${t.valAxisFontItalic ? "italic " : ""}${t.valAxisFontBold ? "bold " : ""}${re}px ${Lt(t, t.valAxisFontFace)}`, e.fillStyle = t.valAxisFontColor ? `#${t.valAxisFontColor}` : "#595959", e.textAlign = c ? "center" : "right", e.textBaseline = c ? "top" : "middle", !t.valAxisHidden && t.valAxisTickLabelPos !== "none") {
2584
+ let { axisX: n, axisY: r, depth: o } = Y, s = _.project(R.x + R.w / 2, R.y + R.h / 2, o), l = Sn(c ? Y.horizontalStart : Y.verticalStart, c ? Y.horizontalEnd : Y.verticalEnd, s, c ? "vertical" : "horizontal");
2585
2585
  e.textAlign = Math.abs(l.x) < .2 ? "center" : l.x < 0 ? "right" : "left", e.textBaseline = Math.abs(l.y) < .2 ? "middle" : l.y < 0 ? "bottom" : "top";
2586
- let u = En(t.valAxisMajorTickMark, t.valAxisLineHidden, r, 5), d = t.valAxisDisplayUnits?.divisor;
2587
- for (let r of I.majorTicks) {
2588
- let c = s ? p.project(V.x + I.fraction(r) * V.w, a, o) : p.project(n, V.y + V.h - I.fraction(r) * V.h, o);
2589
- Y(e, i(m ? r / 100 : d != null && Number.isFinite(d) && d > 0 ? r / d : r, m ? t.valAxisFormatCode ?? "0%" : t.valAxisFormatCode, t.date1904), c.x + l.x * u, c.y + l.y * u, N(ne));
2586
+ let u = En(t.valAxisMajorTickMark, t.valAxisLineHidden, a, 5), d = t.valAxisDisplayUnits?.divisor;
2587
+ for (let a of I.majorTicks) {
2588
+ let s = c ? _.project(R.x + I.fraction(a) * R.w, r, o) : _.project(n, R.y + R.h - I.fraction(a) * R.h, o);
2589
+ B(e, i(v ? a / 100 : d != null && Number.isFinite(d) && d > 0 ? a / d : a, v ? t.valAxisFormatCode ?? "0%" : t.valAxisFormatCode, t.date1904), s.x + l.x * u, s.y + l.y * u, K(re));
2590
2590
  }
2591
2591
  }
2592
- let X = j(t.catAxisFontSizeHpt, r) ?? 9 * r;
2593
- if (e.font = `${t.catAxisFontItalic ? "italic " : ""}${t.catAxisFontBold ? "bold " : ""}${X}px ${Lt(t, t.catAxisFontFace)}`, e.fillStyle = t.catAxisFontColor ? `#${t.catAxisFontColor}` : "#595959", !t.catAxisHidden && t.catAxisTickLabelPos !== "none") {
2594
- let n = B(En(t.catAxisMajorTickMark, t.catAxisLineHidden, r, 6), t.catAxisLabelOffsetPercent), i = Array.from({ length: _ }, (e, n) => ge(String(h[n] ?? n + 1), t.catAxisFormatCode, t.date1904)), a = Xt(t);
2595
- if (a == null && (a = 0, !s && _ > 1)) {
2596
- let t = Infinity, n = null, r = J.axisY;
2597
- for (let e = 0; e < _; e++) {
2598
- let i = q(e, _, b, y), a = p.project(V.x + i * V.w, r, p.topology.nearDepth);
2599
- n && (t = Math.min(t, Math.hypot(a.x - n.x, a.y - n.y))), n = a;
2592
+ let Z = H(t.catAxisFontSizeHpt, a) ?? 9 * a;
2593
+ if (e.font = `${t.catAxisFontItalic ? "italic " : ""}${t.catAxisFontBold ? "bold " : ""}${Z}px ${Lt(t, t.catAxisFontFace)}`, e.fillStyle = t.catAxisFontColor ? `#${t.catAxisFontColor}` : "#595959", !t.catAxisHidden && t.catAxisTickLabelPos !== "none") {
2594
+ let n = me(En(t.catAxisMajorTickMark, t.catAxisLineHidden, a, 6), t.catAxisLabelOffsetPercent), i = Array.from({ length: b }, (e, n) => he(String(y[n] ?? n + 1), t.catAxisFormatCode, t.date1904)), o = Xt(t);
2595
+ if (o == null && (o = 0, !c && b > 1)) {
2596
+ let t = Infinity, n = null, a = X.axisY;
2597
+ for (let e = 0; e < b; e++) {
2598
+ let i = r(e, b, T, w), o = _.project(R.x + i * R.w, a, _.topology.nearDepth);
2599
+ n && (t = Math.min(t, Math.hypot(o.x - n.x, o.y - n.y))), n = o;
2600
2600
  }
2601
- Math.max(0, ...i.map((t) => R(e, t))) > t * .9 && (a = -Math.PI / 4);
2601
+ Math.max(0, ...i.map((t) => M(e, t))) > t * .9 && (o = -Math.PI / 4);
2602
2602
  }
2603
- let o = Math.max(1, Math.floor(t.catAxisTickLabelSkip ?? 1));
2604
- for (let t = 0; t < _; t += o) {
2605
- let r = q(t, _, b, y), { axisX: o, axisY: c, depth: l } = J, u = s ? p.project(o, V.y + q(t, _, b, y) * V.h, l) : p.project(V.x + r * V.w, c, l);
2606
- if (s) {
2607
- let r = p.project(o, V.y + V.h / 2, l), a = p.project(V.x + V.w / 2, V.y + V.h / 2, l), s = r.x <= a.x;
2608
- e.textAlign = s ? "right" : "left", e.textBaseline = "middle", Y(e, i[t], u.x + (s ? -n : n), u.y, N(X));
2603
+ let s = Math.max(1, Math.floor(t.catAxisTickLabelSkip ?? 1));
2604
+ for (let t = 0; t < b; t += s) {
2605
+ let a = r(t, b, T, w), { axisX: s, axisY: l, depth: u } = X, d = c ? _.project(s, R.y + r(t, b, T, w) * R.h, u) : _.project(R.x + a * R.w, l, u);
2606
+ if (c) {
2607
+ let r = _.project(s, R.y + R.h / 2, u), a = _.project(R.x + R.w / 2, R.y + R.h / 2, u), o = r.x <= a.x;
2608
+ e.textAlign = o ? "right" : "left", e.textBaseline = "middle", B(e, i[t], d.x + (o ? -n : n), d.y, K(Z));
2609
2609
  } else {
2610
- let r = p.project(V.x + V.w / 2, V.y + V.h / 2, l), o = Sn(J.horizontalStart, J.horizontalEnd, r, "vertical");
2611
- $t(e, i[t], u, a, s, o.y < 0 ? -1 : 1, n, N(X));
2610
+ let r = _.project(R.x + R.w / 2, R.y + R.h / 2, u), a = Sn(X.horizontalStart, X.horizontalEnd, r, "vertical");
2611
+ $t(e, i[t], d, o, c, a.y < 0 ? -1 : 1, n, K(Z));
2612
2612
  }
2613
2613
  }
2614
2614
  }
2615
- sn(e, t, n, u, s, r);
2615
+ sn(e, t, n, f, c, a);
2616
2616
  for (let e of ee) e();
2617
- return fn(e, t, d, r, !1, f, a), !0;
2617
+ return fn(e, t, p, a, !1, h, o), !0;
2618
2618
  }
2619
2619
  function An(e, t, n, r, i) {
2620
2620
  if (!t.threeD || t.chartType !== "pie") return !1;
@@ -2628,38 +2628,38 @@ function An(e, t, n, r, i) {
2628
2628
  if (!(s > 0)) return !0;
2629
2629
  let c = o.reduce((e, t) => e + t.value / s, 0);
2630
2630
  if (!(c > 0) || !Number.isFinite(c)) return !0;
2631
- let { plot: l, legend: u, legendMeasure: d } = rn(e, t, n, r, "radial", i), f = Te({
2631
+ let { plot: u, legend: d, legendMeasure: f } = rn(e, t, n, r, "radial", i), p = Te({
2632
2632
  ...t.threeD,
2633
2633
  rotationY: t.threeD.rotationY ?? 0,
2634
2634
  heightPercent: void 0,
2635
2635
  depthPercent: 100
2636
- }, l, {
2636
+ }, u, {
2637
2637
  sceneDepthScale: 1,
2638
2638
  sceneHeightScale: .15
2639
2639
  });
2640
- if (!f) return !0;
2641
- let p = new Map(a.dataPointOverrides?.map((e) => [e.idx, e]) ?? []), m = 0;
2642
- for (let e of p.values()) e.explosion != null && Number.isFinite(e.explosion) && (m = Math.max(m, Math.max(0, Math.min(100, e.explosion)) / 100));
2643
- let { scene: h } = f, _ = Math.min(h.w * .45 / (1 + m), f.modelDepth * .45 / (1 + m), h.h / .45);
2644
- if (!(_ > 0)) return !0;
2645
- let v = h.x + h.w / 2, y = h.y + h.h / 2, b = .5, x = _ * .3 * Ae(t.threeD), S = 0, C = [], w = new Map(a.dataLabelOverrides?.map((e) => [e.idx, e]) ?? []), T = Math.max(48, Math.min(128, Math.ceil(Math.PI * 2 * _ / 4)));
2640
+ if (!p) return !0;
2641
+ let h = new Map(a.dataPointOverrides?.map((e) => [e.idx, e]) ?? []), g = 0;
2642
+ for (let e of h.values()) e.explosion != null && Number.isFinite(e.explosion) && (g = Math.max(g, Math.max(0, Math.min(100, e.explosion)) / 100));
2643
+ let { scene: _ } = p, v = Math.min(_.w * .45 / (1 + g), p.modelDepth * .45 / (1 + g), _.h / .45);
2644
+ if (!(v > 0)) return !0;
2645
+ let y = _.x + _.w / 2, b = _.y + _.h / 2, S = .5, C = v * .3 * Ae(t.threeD), w = 0, T = [], E = new Map(a.dataLabelOverrides?.map((e) => [e.idx, e]) ?? []), D = Math.max(48, Math.min(128, Math.ceil(Math.PI * 2 * v / 4)));
2646
2646
  for (let e of o) {
2647
- let n = e.value / s / c, r = mn(t.firstSliceAngle, S, n), i = p.get(e.index), o = $(t, a, i, e.index, 0), l = r.middle, u = i?.explosion != null && Number.isFinite(i.explosion) ? Math.max(0, Math.min(100, i.explosion)) / 100 : 0, d = v + Math.cos(l) * _ * u, m = b + Math.sin(l) * _ * u / f.modelDepth, h = Math.max(2, Math.ceil(T * n)), g = Je({
2647
+ let n = e.value / s / c, r = mn(t.firstSliceAngle, w, n), i = h.get(e.index), o = $(t, a, i, e.index, 0), l = r.middle, u = i?.explosion != null && Number.isFinite(i.explosion) ? Math.max(0, Math.min(100, i.explosion)) / 100 : 0, d = y + Math.cos(l) * v * u, f = S + Math.sin(l) * v * u / p.modelDepth, m = Math.max(2, Math.ceil(D * n)), g = Je({
2648
2648
  centerX: d,
2649
- centerY: y,
2650
- centerDepth: m,
2651
- radius: _,
2652
- modelDepth: f.modelDepth,
2653
- thickness: x,
2649
+ centerY: b,
2650
+ centerDepth: f,
2651
+ radius: v,
2652
+ modelDepth: p.modelDepth,
2653
+ thickness: C,
2654
2654
  startAngle: r.start,
2655
2655
  endAngle: r.end,
2656
- segments: h
2656
+ segments: m
2657
2657
  });
2658
2658
  if (!g) {
2659
- S += n;
2659
+ w += n;
2660
2660
  continue;
2661
2661
  }
2662
- C.push({
2662
+ T.push({
2663
2663
  index: e.index,
2664
2664
  start: r.start,
2665
2665
  end: r.end,
@@ -2668,8 +2668,8 @@ function An(e, t, n, r, i) {
2668
2668
  value: e.value,
2669
2669
  percentValue: n,
2670
2670
  centerX: d,
2671
- centerDepth: m,
2672
- segments: h,
2671
+ centerDepth: f,
2672
+ segments: m,
2673
2673
  mesh: g,
2674
2674
  lineColor: o.lineColor,
2675
2675
  lineFill: o.lineFill,
@@ -2678,56 +2678,56 @@ function An(e, t, n, r, i) {
2678
2678
  lineCustomDash: o.lineCustomDash,
2679
2679
  lineCap: o.lineCap,
2680
2680
  lineJoin: o.lineJoin
2681
- }), S += n;
2681
+ }), w += n;
2682
2682
  }
2683
- f = Me(f, C.flatMap((e) => e.mesh.vertices), l, .08);
2684
- let E = [], D = {
2683
+ p = Me(p, T.flatMap((e) => e.mesh.vertices), u, .08);
2684
+ let O = [], k = {
2685
2685
  remaining: rt,
2686
2686
  exceeded: !1
2687
- }, O = (e) => {
2688
- let t = e.lineWidthEmu == null ? .75 * r : Math.max(.25, e.lineWidthEmu / F * r);
2687
+ }, A = (e) => {
2688
+ let t = e.lineWidthEmu == null ? .75 * r : Math.max(.25, e.lineWidthEmu / W * r);
2689
2689
  return e.lineFill !== null && (e.lineColor != null || e.lineFill !== void 0) ? {
2690
2690
  color: e.lineColor ?? "rgba(0,0,0,0.42)",
2691
2691
  width: t,
2692
- dash: L(e.lineCustomDash, e.lineDash, t),
2692
+ dash: x(e.lineCustomDash, e.lineDash, t),
2693
2693
  cap: e.lineCap,
2694
2694
  join: e.lineJoin
2695
2695
  } : void 0;
2696
- }, k = C.map((t) => {
2697
- let n = Wt(f, t.mesh, t.color, void 0, D);
2696
+ }, j = T.map((t) => {
2697
+ let n = Wt(p, t.mesh, t.color, void 0, k);
2698
2698
  return Jt(e, n, "fill", t.fillPaint, i), {
2699
2699
  slice: t,
2700
2700
  faces: n
2701
2701
  };
2702
- }), A = k.flatMap((e) => e.faces), M = [], N = C.map(O), P = N[0], R = (e) => e == null ? null : [
2702
+ }), M = j.flatMap((e) => e.faces), P = [], F = T.map(A), I = F[0], L = (e) => e == null ? null : [
2703
2703
  e.color,
2704
2704
  e.width,
2705
2705
  e.dash.join(","),
2706
2706
  e.cap,
2707
2707
  e.join
2708
- ].join("|"), z = P != null && C.every((e) => e.lineFill === void 0) && N.every((e) => R(e) === R(P)) && C.every((e) => Math.abs(e.centerX - v) < 1e-9 && Math.abs(e.centerDepth - b) < 1e-9);
2709
- if (z) M.push(...Gt(f, C, y, _, x, P, D));
2710
- else for (let t = 0; t < C.length; t++) {
2711
- let n = N[t];
2708
+ ].join("|"), R = I != null && T.every((e) => e.lineFill === void 0) && F.every((e) => L(e) === L(I)) && T.every((e) => Math.abs(e.centerX - y) < 1e-9 && Math.abs(e.centerDepth - S) < 1e-9);
2709
+ if (R) P.push(...Gt(p, T, b, v, C, I, k));
2710
+ else for (let t = 0; t < T.length; t++) {
2711
+ let n = F[t];
2712
2712
  if (!n) continue;
2713
- let r = Wt(f, C[t].mesh, "transparent", n, D, !0);
2714
- Jt(e, r, "outline", C[t].lineFill, i), M.push(...r);
2713
+ let r = Wt(p, T[t].mesh, "transparent", n, k, !0);
2714
+ Jt(e, r, "outline", T[t].lineFill, i), P.push(...r);
2715
2715
  }
2716
- if (D.exceeded) return Yt(e, n), !0;
2717
- if (z) {
2718
- for (let t of nt(A)) Kt(e, t);
2716
+ if (k.exceeded) return Yt(e, n), !0;
2717
+ if (R) {
2719
2718
  for (let t of nt(M)) Kt(e, t);
2720
- } else for (let t of nt([...A, ...M])) Kt(e, t);
2721
- for (let { slice: n, faces: i } of k) {
2722
- let o = p.get(n.index), s = Le(t, a, n.index, 0), c = g(o?.chartexStyle);
2723
- Se(e, c ?? g(a.chartexStyle), be(t, "dataPoint3D", 0), c ? n.index : s, r, (e) => qt(e, i), s);
2724
- }
2725
- for (let n of C) {
2726
- let o = (n.start + n.end) / 2, s = w.get(n.index);
2719
+ for (let t of nt(P)) Kt(e, t);
2720
+ } else for (let t of nt([...M, ...P])) Kt(e, t);
2721
+ for (let { slice: n, faces: i } of j) {
2722
+ let o = h.get(n.index), s = Le(t, a, n.index, 0), c = m(o?.chartexStyle);
2723
+ xe(e, c ?? m(a.chartexStyle), l(t, "dataPoint3D", 0), c ? n.index : s, r, (e) => qt(e, i), s);
2724
+ }
2725
+ for (let n of T) {
2726
+ let o = (n.start + n.end) / 2, s = E.get(n.index);
2727
2727
  if (nn(t, a, s)) {
2728
- let c = a.seriesDataLabels, u = j(s?.fontSizeHpt ?? c?.fontSizeHpt ?? t.dataLabelFontSizeHpt, r) ?? 9 * r;
2729
- e.font = `${s?.fontBold ?? c?.fontBold ?? t.dataLabelFontBold ? "bold " : ""}${u}px ${Rt(t, s?.fontFace ?? c?.fontFace ?? t.dataLabelFontFace)}`;
2730
- let d = I({
2728
+ let c = a.seriesDataLabels, l = H(s?.fontSizeHpt ?? c?.fontSizeHpt ?? t.dataLabelFontSizeHpt, r) ?? 9 * r;
2729
+ e.font = `${s?.fontBold ?? c?.fontBold ?? t.dataLabelFontBold ? "bold " : ""}${l}px ${Rt(t, s?.fontFace ?? c?.fontFace ?? t.dataLabelFontFace)}`;
2730
+ let d = N({
2731
2731
  customText: s?.text,
2732
2732
  showCategory: s?.showCatName ?? c?.showCatName ?? !1,
2733
2733
  showSeries: s?.showSerName ?? c?.showSerName ?? !1,
@@ -2740,37 +2740,37 @@ function An(e, t, n, r, i) {
2740
2740
  formatCode: s?.formatCode ?? c?.formatCode ?? t.dataLabelFormatCode ?? a.valFormatCode,
2741
2741
  separator: s?.separator ?? c?.separator,
2742
2742
  date1904: t.date1904
2743
- }), p = Rt(t, s?.fontFace ?? c?.fontFace ?? t.dataLabelFontFace), m = s?.text && s.richRuns?.length ? Fe(e, {
2743
+ }), f = Rt(t, s?.fontFace ?? c?.fontFace ?? t.dataLabelFontFace), m = s?.text && s.richRuns?.length ? Fe(e, {
2744
2744
  runs: s.richRuns,
2745
2745
  ptToPx: r,
2746
- fontFamily: p,
2746
+ fontFamily: f,
2747
2747
  fallbackBold: s.fontBold ?? c?.fontBold ?? t.dataLabelFontBold ?? !1,
2748
2748
  fontFamilyForFace: (e) => Rt(t, e)
2749
- }, u, `#${s.fontColor ?? c?.fontColor ?? a.labelColor ?? t.dataLabelFontColor ?? "111111"}`) : null, h = s?.position ?? c?.position ?? t.dataLabelPosition, g = y - x / 2, v = y + x / 2, b = f.cameraDepth(n.centerX, g, n.centerDepth) >= f.cameraDepth(n.centerX, v, n.centerDepth) ? g : v, S = 0, C = null;
2749
+ }, l, `#${s.fontColor ?? c?.fontColor ?? a.labelColor ?? t.dataLabelFontColor ?? "111111"}`) : null, h = s?.position ?? c?.position ?? t.dataLabelPosition, g = b - C / 2, _ = b + C / 2, y = p.cameraDepth(n.centerX, g, n.centerDepth) >= p.cameraDepth(n.centerX, _, n.centerDepth) ? g : _, x = 0, S = null;
2750
2750
  for (let e = 0; e <= 12; e++) {
2751
- let t = n.start + (n.end - n.start) * e / 12, r = f.project(n.centerX + Math.cos(t) * _ * .64, b, n.centerDepth + Math.sin(t) * _ * .64 / f.modelDepth);
2752
- C && (S += Math.hypot(r.x - C.x, r.y - C.y)), C = r;
2751
+ let t = n.start + (n.end - n.start) * e / 12, r = p.project(n.centerX + Math.cos(t) * v * .64, y, n.centerDepth + Math.sin(t) * v * .64 / p.modelDepth);
2752
+ S && (x += Math.hypot(r.x - S.x, r.y - S.y)), S = r;
2753
2753
  }
2754
- let w = (h == null || h === "bestFit") && (n.percentValue === 0 || S < (m?.width ?? e.measureText(d).width)) || h === "outEnd", T = _ * (w ? 1.12 : .64), D = f.project(n.centerX + Math.cos(o) * T, b, n.centerDepth + Math.sin(o) * T / f.modelDepth), O = f.project(n.centerX + Math.cos(o) * _, b, n.centerDepth + Math.sin(o) * _ / f.modelDepth);
2755
- E.push(() => tn(e, t, a, 0, n.index, n.value, D, l, r, 0, n.percentValue, s, "ctr", O, w, void 0, void 0, void 0, i));
2754
+ let w = (h == null || h === "bestFit") && (n.percentValue === 0 || x < (m?.width ?? e.measureText(d).width)) || h === "outEnd", T = v * (w ? 1.12 : .64), E = p.project(n.centerX + Math.cos(o) * T, y, n.centerDepth + Math.sin(o) * T / p.modelDepth), D = p.project(n.centerX + Math.cos(o) * v, y, n.centerDepth + Math.sin(o) * v / p.modelDepth);
2755
+ O.push(() => tn(e, t, a, 0, n.index, n.value, E, u, r, 0, n.percentValue, s, "ctr", D, w, void 0, void 0, void 0, i));
2756
2756
  }
2757
2757
  }
2758
- for (let e of E) e();
2759
- let B = a.categories?.length ? a.categories : t.categories, V = Array.from({ length: B.length }, (e, n) => {
2760
- let r = p.get(n), i = Re(t, a, r, n, 0);
2758
+ for (let e of O) e();
2759
+ let z = a.categories?.length ? a.categories : t.categories, B = Array.from({ length: z.length }, (e, n) => {
2760
+ let r = h.get(n), i = Re(t, a, r, n, 0);
2761
2761
  if (i === null) return "00000000";
2762
2762
  let o = i?.fillType === "solid" ? i.color : r?.color ?? a.dataPointColors?.[n] ?? a.color;
2763
2763
  return o === "00000000" ? "00000000" : Ne(o ? `#${o}` : Dt(n), .8).replace(/^#/, "");
2764
2764
  });
2765
2765
  return fn(e, {
2766
2766
  ...t,
2767
- categories: B,
2767
+ categories: z,
2768
2768
  series: [{
2769
2769
  ...a,
2770
- categories: B,
2771
- dataPointColors: V
2770
+ categories: z,
2771
+ dataPointColors: B
2772
2772
  }]
2773
- }, u, r, !0, d, i), !0;
2773
+ }, d, r, !0, f, i), !0;
2774
2774
  }
2775
2775
  function jn(e, t, n, r, i = 0) {
2776
2776
  return !t.threeD || !(t.chartType === "pie" || wt.has(t.chartType)) ? !1 : Mt(t) ? An(e, t, n, r, i) ? !0 : kn(e, t, n, r, i) : (Yt(e, n), !0);