@arcgis/charts-components 5.2.0-next.60 → 5.2.0-next.62

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 (141) hide show
  1. package/dist/cdn/{BXBY6D2F.js → 3IUZSUBJ.js} +1 -1
  2. package/dist/cdn/{DPTA2AET.js → 4DXQ255M.js} +1 -1
  3. package/dist/cdn/{67QYTLMM.js → 4F2MTKVF.js} +1 -1
  4. package/dist/cdn/4HNA5BEL.js +2 -0
  5. package/dist/cdn/{PLEC3GNT.js → 4II4V3R4.js} +1 -1
  6. package/dist/cdn/{ZWIF7LHW.js → 4SV3ARJE.js} +1 -1
  7. package/dist/cdn/{WTJ2NJ76.js → 5K4LYQAP.js} +1 -1
  8. package/dist/cdn/{2RYKKN36.js → 65QZ37RL.js} +1 -1
  9. package/dist/cdn/{O3VKOV2W.js → 6T37GQMM.js} +1 -1
  10. package/dist/cdn/{4COV22K4.js → 6ZJ4DH7D.js} +1 -1
  11. package/dist/cdn/{LGTXQIF7.js → 7H7MFSEY.js} +1 -1
  12. package/dist/cdn/{3YCGBAQY.js → 7JW7BKCY.js} +1 -1
  13. package/dist/cdn/{GARBFC7Q.js → 7Q5SYLKV.js} +1 -1
  14. package/dist/cdn/{BLZLMGO6.js → AJAOQCPS.js} +1 -1
  15. package/dist/cdn/{3AYXOX4U.js → AMM6O6DA.js} +1 -1
  16. package/dist/cdn/{JBFVGQSP.js → BIABAOQA.js} +1 -1
  17. package/dist/cdn/{Y5ZH7VS4.js → BP3IZMZQ.js} +1 -1
  18. package/dist/cdn/{WFW6BNDT.js → CNIDLTWS.js} +1 -1
  19. package/dist/cdn/{DGV6S2W3.js → CUW7EDSM.js} +1 -1
  20. package/dist/cdn/{QZCTLQBM.js → D5IKYXWS.js} +1 -1
  21. package/dist/cdn/DA4QOTYN.js +2 -0
  22. package/dist/cdn/{XM2GVJT3.js → DQXO7PWX.js} +1 -1
  23. package/dist/cdn/{6MNV7FJC.js → DT4C4JZW.js} +1 -1
  24. package/dist/cdn/{SYVPFDIW.js → EEF2GZWF.js} +1 -1
  25. package/dist/cdn/ELRXL4GL.js +2 -0
  26. package/dist/cdn/{6DOANSRL.js → FLA3PJ5I.js} +18 -18
  27. package/dist/cdn/{EUOJG5H6.js → FZOZWZSG.js} +1 -1
  28. package/dist/cdn/{AYUYEY5H.js → G3I2WY7S.js} +1 -1
  29. package/dist/cdn/{MJTWR33N.js → GK3ESMF2.js} +1 -1
  30. package/dist/cdn/{I3XBTQKJ.js → GQKDPSP6.js} +1 -1
  31. package/dist/cdn/{Z3LGGHZN.js → GRIVRWCF.js} +1 -1
  32. package/dist/cdn/{OWWQ5SYW.js → HHZSG3K6.js} +1 -1
  33. package/dist/cdn/{ZGBULDPL.js → IB5R6XBE.js} +1 -1
  34. package/dist/cdn/{EOHKNJSJ.js → INSAYWFB.js} +1 -1
  35. package/dist/cdn/{ZLXYBOM3.js → IP7NR32G.js} +1 -1
  36. package/dist/cdn/IPMFDZBI.js +2 -0
  37. package/dist/cdn/{JGESKW6S.js → JBO56HPJ.js} +1 -1
  38. package/dist/cdn/{RICA7GJM.js → JE4ZLQEX.js} +1 -1
  39. package/dist/cdn/JT2CHRVO.js +2 -0
  40. package/dist/cdn/JYS5HVHP.js +2 -0
  41. package/dist/cdn/{HOIPLQXD.js → KBMGQ3H6.js} +1 -1
  42. package/dist/cdn/{EAV3KAS7.js → KO6XLCKT.js} +1 -1
  43. package/dist/cdn/LK7Y2TPS.js +2 -0
  44. package/dist/cdn/{5YP7P6S3.js → LNMXGS7N.js} +1 -1
  45. package/dist/cdn/{HUNN3ERX.js → LYLK7H23.js} +1 -1
  46. package/dist/cdn/{2G65P262.js → MIL4ALAU.js} +1 -1
  47. package/dist/cdn/{NK66D65H.js → MIMPZBTK.js} +1 -1
  48. package/dist/cdn/{EMBMJCFZ.js → MN5LEOFQ.js} +1 -1
  49. package/dist/cdn/{5EYVH3PA.js → MRA3XRKD.js} +1 -1
  50. package/dist/cdn/{MXE4VPZS.js → MYAMCWA2.js} +1 -1
  51. package/dist/cdn/{TEWEPSIO.js → N2BF3AIP.js} +1 -1
  52. package/dist/cdn/{SUNHJPBW.js → NQYCZQ27.js} +1 -1
  53. package/dist/cdn/{UM7RIOCE.js → NSS4WWO7.js} +1 -1
  54. package/dist/cdn/{Y2WHHAAA.js → P7VFYZRI.js} +1 -1
  55. package/dist/cdn/{T62EETHJ.js → PZFM3BRK.js} +1 -1
  56. package/dist/cdn/PZUVU7CC.js +3 -0
  57. package/dist/cdn/{SQIKFO32.js → Q376XO5C.js} +1 -1
  58. package/dist/cdn/{VA6KJZ2Y.js → QGKWF4LR.js} +1 -1
  59. package/dist/cdn/QS6QHTAG.js +2 -0
  60. package/dist/cdn/{A36KQ6YP.js → QSFEGKYQ.js} +1 -1
  61. package/dist/cdn/{M744CFJ2.js → QXN2LIUA.js} +1 -1
  62. package/dist/cdn/{QTSF2LK7.js → R7VPFCG2.js} +1 -1
  63. package/dist/cdn/{BKK57XHL.js → S3YPXZ3Y.js} +1 -1
  64. package/dist/cdn/{J3CL6KB6.js → S7B57I24.js} +1 -1
  65. package/dist/cdn/{ANHW36VW.js → SSYHOPL2.js} +1 -1
  66. package/dist/cdn/{DBAM7MH7.js → SYU55EDE.js} +1 -1
  67. package/dist/cdn/{BHGOAHMJ.js → TGABTYRZ.js} +1 -1
  68. package/dist/cdn/{WZOHQJFB.js → TGXTKIAA.js} +1 -1
  69. package/dist/cdn/{JS6A5QAV.js → TRXKI7AQ.js} +1 -1
  70. package/dist/cdn/{KDCZQ6UT.js → V2POH2WS.js} +1 -1
  71. package/dist/cdn/{ISK4QVLY.js → VZPJL27P.js} +1 -1
  72. package/dist/cdn/WOE4UHYG.js +2 -0
  73. package/dist/cdn/WUUBA4AY.js +2 -0
  74. package/dist/cdn/{P5QEJOJS.js → X3B7R2CE.js} +1 -1
  75. package/dist/cdn/{JYITKARU.js → X4RUTR6U.js} +1 -1
  76. package/dist/cdn/{5MPXETTU.js → X7BEP5KL.js} +1 -1
  77. package/dist/cdn/{INISFVAK.js → XM6OTYSW.js} +1 -1
  78. package/dist/cdn/XS5G7ML2.js +2 -0
  79. package/dist/cdn/{KWA7OWHO.js → YN4QD76O.js} +1 -1
  80. package/dist/cdn/YQJBJRP7.js +2 -0
  81. package/dist/cdn/{L7TUV2MY.js → YWJTHRQP.js} +1 -1
  82. package/dist/cdn/{7DIQIFKR.js → ZOZ72K4S.js} +1 -1
  83. package/dist/cdn/index.js +1 -1
  84. package/dist/cdn/model/shared/setup-utils.js +1 -1
  85. package/dist/chunks/bar-chart-model.js +10 -10
  86. package/dist/chunks/box-plot-data.js +271 -279
  87. package/dist/chunks/box-plot-model.js +161 -146
  88. package/dist/chunks/chart-model.js +1 -1
  89. package/dist/chunks/class-breaks.js +66 -66
  90. package/dist/chunks/combo-bar-line-chart-model.js +12 -12
  91. package/dist/chunks/data.js +1 -1
  92. package/dist/chunks/gauge-model.js +1 -1
  93. package/dist/chunks/heat-chart-model.js +25 -25
  94. package/dist/chunks/histogram-model.js +1 -1
  95. package/dist/chunks/index2.js +2026 -2088
  96. package/dist/chunks/index4.js +1 -1
  97. package/dist/chunks/line-chart-model.js +11 -11
  98. package/dist/chunks/model-with-x-guides.js +5 -5
  99. package/dist/chunks/model-with-y-guides.js +33 -48
  100. package/dist/chunks/pie-chart-data.js +165 -189
  101. package/dist/chunks/pie-chart-model.js +9 -9
  102. package/dist/chunks/radar-chart-model.js +7 -7
  103. package/dist/chunks/scatterplot-model.js +1 -1
  104. package/dist/chunks/serial-chart-data.js +745 -770
  105. package/dist/chunks/serial-chart-model.js +19 -11
  106. package/dist/chunks/utils.js +36 -38
  107. package/dist/chunks/web-component-utils.js +38 -38
  108. package/dist/chunks/x-bounds.js +1 -1
  109. package/dist/components/arcgis-chart/customElement.d.ts +53 -11
  110. package/dist/components/arcgis-chart/customElement.js +2226 -2210
  111. package/dist/components/arcgis-charts-config-create-flow/customElement.js +1 -1
  112. package/dist/components/arcgis-charts-config-pie-chart-slices/customElement.js +67 -68
  113. package/dist/components/arcgis-charts-config-pie-chart-slices-popover/customElement.js +5 -5
  114. package/dist/docs/api.json +1 -1
  115. package/dist/docs/docs.json +1 -1
  116. package/dist/docs/vscode.html-custom-data.json +1 -1
  117. package/dist/docs/web-types.json +1 -1
  118. package/dist/index.js +171 -172
  119. package/dist/model/box-plot-model/box-plot-model.d.ts +7 -1
  120. package/dist/model/heat-chart-model/heat-chart-model.d.ts +20 -0
  121. package/dist/model/mixins/model-with-multi-axes.d.ts +61 -98
  122. package/dist/model/serial-chart-model/serial-chart-model.d.ts +12 -1
  123. package/dist/utils/chart-config/converter/index.js +26 -26
  124. package/dist/utils/data/categorical-data/index.d.ts +1 -1
  125. package/dist/utils/data/index.d.ts +1 -2
  126. package/dist/utils/layer/query-features/index.d.ts +2 -18
  127. package/dist/utils/layer/query-parser/index.d.ts +1 -2
  128. package/package.json +3 -3
  129. package/dist/cdn/3UHXOKCR.js +0 -2
  130. package/dist/cdn/54W4C75M.js +0 -2
  131. package/dist/cdn/6PIQ2O5S.js +0 -2
  132. package/dist/cdn/7CMQGTU6.js +0 -2
  133. package/dist/cdn/EBSQRCQQ.js +0 -2
  134. package/dist/cdn/EDVN42ME.js +0 -2
  135. package/dist/cdn/H2EMIJME.js +0 -2
  136. package/dist/cdn/JEVWE6ER.js +0 -2
  137. package/dist/cdn/O3DJD5IR.js +0 -2
  138. package/dist/cdn/V5W5LNFT.js +0 -2
  139. package/dist/cdn/V6LKZUEZ.js +0 -3
  140. package/dist/cdn/XKZ44LA2.js +0 -2
  141. package/dist/cdn/YVSZN6IH.js +0 -2
@@ -1,156 +1,154 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import { substitute as M } from "@arcgis/core/intl.js";
3
- import { memoize as j, isEmpty as ce, isEqual as de, cloneDeep as X } from "lodash-es";
4
- import { B as u } from "./common.js";
5
- import { u as I, b as R, c as ye, d as ue, s as K, f as fe } from "./utils.js";
6
- import { g as q } from "./utils2.js";
7
- import { b as me } from "./series-length.js";
8
- import { s as z } from "./data.js";
9
- import { R as Se } from "./rest-js-object-literals.js";
10
- import { u as f, n as p, p as h } from "./chart-object-literals.js";
11
- import { D as E, g as C, _ as J, a0 as _, n as H, E as Q, h as U, $ as pe, K as ge, F as xe } from "./index.js";
12
- import { d as w } from "./index3.js";
13
- import { bf as P, bg as be, aH as D, bc as he, aM as Fe, ad as Ae, a6 as G } from "./index2.js";
14
- import { i as V } from "./index4.js";
15
- const Ge = (s, e) => e?.series?.[s]?.name, Ze = (s, e, t) => {
2
+ import { substitute as v } from "@arcgis/core/intl.js";
3
+ import { memoize as K, isEmpty as re, isEqual as ne, cloneDeep as U } from "lodash-es";
4
+ import { B as f } from "./common.js";
5
+ import { u as M, b as W, c as le, d as ae, s as E } from "./utils.js";
6
+ import { g as k } from "./utils2.js";
7
+ import { b as de } from "./series-length.js";
8
+ import { s as N } from "./data.js";
9
+ import { R as ce } from "./rest-js-object-literals.js";
10
+ import { u as p, n as S, p as x } from "./chart-object-literals.js";
11
+ import { D as $, g as h, _ as ye, a0 as ue, n as fe, E as j, h as z, $ as me, K as Se, F as pe } from "./index.js";
12
+ import { d as A } from "./index3.js";
13
+ import { bf as I, bg as ge, aH as D, bc as xe, aM as be, ad as he, a6 as X } from "./index2.js";
14
+ import { i as P } from "./index4.js";
15
+ const _e = (s, e) => e?.series?.[s]?.name, He = (s, e, t) => {
16
16
  const o = t;
17
17
  o?.series?.[e] !== void 0 && (o.series[e].name = s);
18
- }, es = (s, e) => {
18
+ }, Qe = (s, e) => {
19
19
  let t;
20
20
  const o = e.series?.[s];
21
- return o?.type === f.BoxPlotSeries ? t = o.fillSymbol?.color : o?.type === f.LineSeries && (t = o.lineSymbol?.color), t;
22
- }, Be = (s) => {
21
+ return o?.type === p.BoxPlotSeries ? t = o.fillSymbol?.color : o?.type === p.LineSeries && (t = o.lineSymbol?.color), t;
22
+ }, Fe = (s) => {
23
23
  const e = s.series[0];
24
- return s.showMean === !0 && P(e) ? e.fillSymbol?.color : void 0;
25
- }, Ce = (s, e) => {
24
+ return s.showMean === !0 && I(e) ? e.fillSymbol?.color : void 0;
25
+ }, Ae = (s, e) => {
26
26
  const t = e.series[0];
27
- e.showMean === !0 && P(t) && (t.fillSymbol !== void 0 ? t.fillSymbol.color = s : t.fillSymbol = {
28
- ...E(),
27
+ e.showMean === !0 && I(t) && (t.fillSymbol !== void 0 ? t.fillSymbol.color = s : t.fillSymbol = {
28
+ ...$(),
29
29
  color: s
30
30
  });
31
- }, ss = (s, e, t) => {
31
+ }, Ge = (s, e, t) => {
32
32
  const i = t?.series?.[e];
33
- i?.type === f.BoxPlotSeries && i.fillSymbol !== void 0 ? i.fillSymbol.color = s : i?.type === f.LineSeries && i.lineSymbol !== void 0 && (i.lineSymbol.color = s, i.markerSymbol !== void 0 && (i.markerSymbol.color = s));
34
- }, we = (s) => s.series.map((e) => e.id), Le = (s, e) => {
33
+ i?.type === p.BoxPlotSeries && i.fillSymbol !== void 0 ? i.fillSymbol.color = s : i?.type === p.LineSeries && i.lineSymbol !== void 0 && (i.lineSymbol.color = s, i.markerSymbol !== void 0 && (i.markerSymbol.color = s));
34
+ }, Be = (s) => s.series.map((e) => e.id), Ce = (s, e) => {
35
35
  e?.series?.sort(
36
36
  (t, o) => s.findIndex((i) => t.id === i) - s.findIndex((i) => o.id === i)
37
37
  );
38
- }, ts = (s, e, t) => {
39
- const o = we(t), [i] = o.splice(s, 1);
40
- o.splice(e, 0, i), Le(o, t);
41
- }, is = (s) => N(s) ? s.series.findIndex((e) => e.type === f.BoxPlotSeries) : -1;
42
- function Te(s, e, t) {
43
- const o = re(s, e, t), i = me(s), r = V(s);
44
- return o === i || r;
38
+ }, Ze = (s, e, t) => {
39
+ const o = Be(t), [i] = o.splice(s, 1);
40
+ o.splice(e, 0, i), Ce(o, t);
41
+ }, es = (s) => V(s) ? s.series.findIndex((e) => e.type === p.BoxPlotSeries) : -1;
42
+ function we(s, e, t) {
43
+ const o = Z(s, e, t), i = de(s), n = P(s);
44
+ return o === i || n;
45
45
  }
46
- function Z(s, e, t) {
47
- const o = T(s, e, t), i = q(1, s), r = V(s);
48
- return o === i || r;
46
+ function R(s, e, t) {
47
+ const o = T(s, e, t), i = k(1, s), n = P(s);
48
+ return o === i || n;
49
49
  }
50
- function ve(s) {
51
- const { config: e, layerInfo: t, newCategory: o } = s, { layerFieldsInfo: i } = t, r = L(e), l = o !== C ? w(i, r) : "", n = q(0, e), a = V(e);
52
- return l === n || a || n.trim() === "";
50
+ function Le(s) {
51
+ const { config: e, layerInfo: t, newCategory: o } = s, { layerFieldsInfo: i } = t, n = w(e), r = o !== h ? A(i, n) : "", l = k(0, e), a = P(e);
52
+ return r === l || a || l.trim() === "";
53
53
  }
54
- const L = (s) => D(s)?.x ?? C, Me = j(
54
+ const w = (s) => D(s)?.x ?? h, Te = K(
55
55
  (s) => {
56
56
  const e = D(s), t = e?.query?.where?.split("=")[0].trim() ?? "";
57
- return he(e?.query?.where) ? "" : t;
57
+ return xe(e?.query?.where) ? "" : t;
58
58
  },
59
59
  (s) => D(s)?.query?.where
60
- ), ee = j(
60
+ ), J = K(
61
61
  // without memoizing, the worst case efficiency is O(series.length), best case is O(1)
62
62
  // with memoizing, the worst case efficiency for repeated calls becomes O(1)
63
- (s) => Fe(s?.series).filter((e) => e !== ""),
63
+ (s) => be(s?.series).filter((e) => e !== ""),
64
64
  // using series array address as key, since a change to the numeric fields will always rebuild a fresh series array
65
65
  (s) => s?.series
66
66
  ), O = (s) => {
67
- const { category: e, seriesIndex: t, y: o, commonStrings: i } = s, l = {
68
- ...Q(i, t),
69
- x: e === void 0 || e === "" ? C : e,
67
+ const { category: e, seriesIndex: t, y: o, commonStrings: i } = s, r = {
68
+ ...j(i, t),
69
+ x: e === void 0 || e === "" ? h : e,
70
70
  y: o,
71
71
  query: {}
72
72
  };
73
- return X(l);
74
- }, Oe = (s) => {
75
- const { category: e, seriesIndex: t, y: o, commonStrings: i } = s, l = {
76
- ...pe({ commonStrings: i, seriesIndex: t }),
77
- x: e === void 0 || e === "" ? C : e,
73
+ return U(r);
74
+ }, ve = (s) => {
75
+ const { category: e, seriesIndex: t, y: o, commonStrings: i } = s, r = {
76
+ ...me({ commonStrings: i, seriesIndex: t }),
77
+ x: e === void 0 || e === "" ? h : e,
78
78
  y: o,
79
79
  query: {}
80
80
  };
81
- return X(l);
81
+ return U(r);
82
82
  };
83
- function se(s) {
84
- const { x: e, y: t, seriesTemplate: o, commonStrings: i } = s, { id: r, fillSymbol: l } = o ?? {}, n = Q(i), a = r ?? `series_${Date.now()}`;
85
- return n.id = a, n.name = a, n.x = e, n.y = t, l ? n.fillSymbol = l : n.fillSymbol && (n.fillSymbol.color = U, n.fillSymbol?.outline && (n.fillSymbol.outline.color = U)), n;
83
+ function _(s) {
84
+ const { x: e, y: t, seriesTemplate: o, commonStrings: i } = s, { id: n, fillSymbol: r } = o ?? {}, l = j(i), a = n ?? `series_${Date.now()}`;
85
+ return l.id = a, l.name = a, l.x = e, l.y = t, r ? l.fillSymbol = r : l.fillSymbol && (l.fillSymbol.color = z, l.fillSymbol?.outline && (l.fillSymbol.outline.color = z)), l;
86
86
  }
87
- function te(s) {
88
- const { numericFields: e, config: t, layerInfo: o, category: i, commonStrings: r } = s, { layerFieldsInfo: l } = o, n = [], a = i ?? L(t);
89
- let y = !1;
90
- const c = z({
87
+ function H(s) {
88
+ const { numericFields: e, config: t, layerInfo: o, category: i, commonStrings: n } = s, { layerFieldsInfo: r } = o, l = [], a = i ?? w(t), y = N({
91
89
  fieldName: a,
92
90
  numericFields: e,
93
- fieldList: l
91
+ fieldList: r
94
92
  });
95
93
  if (e.length === 0) {
96
- const m = O({
94
+ const d = O({
97
95
  y: "",
98
96
  seriesIndex: 0,
99
97
  category: a,
100
- commonStrings: r
98
+ commonStrings: n
101
99
  });
102
- n.push(m);
103
- } else if (c) {
104
- const m = e.length > 1 ? e : e[0], F = O({
105
- y: m,
100
+ l.push(d);
101
+ } else if (y) {
102
+ const d = e.length > 1 ? e : e[0], u = O({
103
+ y: d,
106
104
  seriesIndex: 0,
107
105
  category: a,
108
- commonStrings: r
109
- }), x = e.length > 1 ? r.axisLabels.values : w(o.layerFieldsInfo, e[0]), g = {
110
- ...F,
111
- id: e[0],
112
- name: x,
113
- x: c ? C : a
114
- }, S = t.series.find((d) => de(m, d.y) && d.query?.where === void 0);
115
- S !== void 0 && (!t.colorMatch && "fillSymbol" in S && (g.fillSymbol = S.fillSymbol, y = !0), g.id = S.id, g.name = S.name), n.push(g);
106
+ commonStrings: n
107
+ }), F = t.series.find((C) => ne(d, C.y) && C.query?.where === void 0), c = I(F) ? F : void 0, m = c?.id ?? e[0], g = e.length > 1 ? n.axisLabels.values : A(o.layerFieldsInfo, e[0]), b = c?.name ?? g, B = {
108
+ ...c ?? u,
109
+ id: m,
110
+ name: b,
111
+ x: y ? h : a
112
+ };
113
+ l.push(B);
116
114
  } else
117
- for (let m = 0; m < e.length; m += 1) {
118
- const F = e[m], x = O({
119
- y: F,
120
- seriesIndex: m,
115
+ for (let d = 0; d < e.length; d += 1) {
116
+ const u = e[d], F = O({
117
+ y: u,
118
+ seriesIndex: d,
121
119
  category: a,
122
- commonStrings: r
123
- }), g = w(l, F), S = {
124
- ...x,
125
- id: F,
126
- name: g,
120
+ commonStrings: n
121
+ }), c = t.series.find((C) => u === C.y), m = I(c) ? c : void 0, g = m?.id ?? u, b = m?.name ?? A(r, u), B = {
122
+ ...m ?? F,
123
+ id: g,
124
+ name: b,
127
125
  x: a
128
- }, d = t.series.find((B) => F === B.y);
129
- d !== void 0 && (!t.colorMatch && "fillSymbol" in d && (S.fillSymbol = d.fillSymbol, y = !0), S.id = d.id, S.name = d.name), n.push(S);
126
+ };
127
+ l.push(B);
130
128
  }
131
- return t.series.length === 1 && n.length === 1 && !t.colorMatch && "fillSymbol" in t.series[0] && (n[0].fillSymbol = t.series[0].fillSymbol, y = !0), t.colorMatch = !y, n;
129
+ return t.series.length === 1 && l.length === 1 && "fillSymbol" in t.series[0] && (l[0].fillSymbol = t.series[0].fillSymbol), l;
132
130
  }
133
- const ie = (s) => s?.query?.where?.split("=")[1].trim().replace(/'/gu, "") ?? "", Ie = (s) => s.series.some((e) => e.type === f.LineSeries) && s.series.some((e) => e.type === f.BoxPlotSeries);
134
- function Pe(s, e, t) {
131
+ const Q = (s) => s?.query?.where?.split("=")[1].trim().replace(/'/gu, "") ?? "", Oe = (s) => s.series.some((e) => e.type === p.LineSeries) && s.series.some((e) => e.type === p.BoxPlotSeries);
132
+ function Me(s, e, t) {
135
133
  const o = [];
136
134
  return s.forEach((i) => {
137
- if (i.type === f.BoxPlotSeries) {
138
- const { type: r, fillSymbol: l, ...n } = i;
135
+ if (i.type === p.BoxPlotSeries) {
136
+ const { type: n, fillSymbol: r, ...l } = i;
139
137
  o.push({
140
- ...n,
141
- type: f.LineSeries,
138
+ ...l,
139
+ type: p.LineSeries,
142
140
  lineSymbol: {
143
- ..._({ width: H }),
144
- ...l !== void 0 ? { color: l.color } : {}
141
+ ...ue({ width: fe }),
142
+ ...r !== void 0 ? { color: r.color } : {}
145
143
  },
146
144
  markerSymbol: {
147
- ...J(),
148
- ...l !== void 0 ? { color: l.color } : {}
145
+ ...ye(),
146
+ ...r !== void 0 ? { color: r.color } : {}
149
147
  }
150
148
  });
151
149
  }
152
150
  }), o.unshift(
153
- se({
151
+ _({
154
152
  x: s[0].x,
155
153
  y: s[0].y,
156
154
  seriesTemplate: t,
@@ -158,218 +156,211 @@ function Pe(s, e, t) {
158
156
  })
159
157
  ), o;
160
158
  }
161
- function De(s) {
159
+ function Ie(s) {
162
160
  const e = s.slice(1), t = [];
163
161
  return e.forEach((o) => {
164
- if (o.type === f.LineSeries) {
165
- const { type: i, lineSymbol: r, markerSymbol: l, ...n } = o, a = E();
162
+ if (o.type === p.LineSeries) {
163
+ const { type: i, lineSymbol: n, markerSymbol: r, ...l } = o, a = $();
166
164
  t.push({
167
- ...n,
168
- type: f.BoxPlotSeries,
165
+ ...l,
166
+ type: p.BoxPlotSeries,
169
167
  fillSymbol: {
170
168
  ...a,
171
- color: r?.color
169
+ color: n?.color
172
170
  }
173
171
  });
174
172
  }
175
173
  }), t;
176
174
  }
177
- function oe(s) {
175
+ function G(s) {
178
176
  const { formerSeries: e, newSeries: t, showMean: o } = s;
179
177
  let i = t;
180
- const r = (a) => a.type === (o ? f.LineSeries : f.BoxPlotSeries), l = e.filter(r).map((a) => a.id), n = t.filter(r).map((a) => a.id);
181
- return l.length === n.length && JSON.stringify(l) !== JSON.stringify(n) && (i = i.sort(
182
- (a, y) => l.findIndex((c) => c === a.id) - l.findIndex((c) => c === y.id)
178
+ const n = (a) => a.type === (o ? p.LineSeries : p.BoxPlotSeries), r = e.filter(n).map((a) => a.id), l = t.filter(n).map((a) => a.id);
179
+ return r.length === l.length && JSON.stringify(r) !== JSON.stringify(l) && (i = i.sort(
180
+ (a, y) => r.findIndex((d) => d === a.id) - r.findIndex((d) => d === y.id)
183
181
  )), i;
184
182
  }
185
- async function Ve(s) {
186
- const { config: e, layerInfo: t, commonStrings: o, splitByField: i, numericFields: r, category: l } = s, { layer: n, layerFieldsInfo: a } = t, { fetchNullValues: y } = D(e)?.query ?? {}, c = l ?? L(e), { categoriesArray: m, splitByFieldType: F } = await fe({
183
+ function Pe(s) {
184
+ const {
187
185
  config: e,
188
- layer: n,
189
- layerFieldsInfo: a,
190
- xAxisField: W(c) ? void 0 : c,
191
- aggregationFields: r,
186
+ layerInfo: t,
187
+ commonStrings: o,
192
188
  splitByField: i,
193
- fetchNullValues: y,
194
- errorStrings: o.errorStrings
195
- });
196
- let x = [], g = !1;
197
- const S = Ie(e);
198
- if (m.length === 0) {
199
- x = te({
200
- numericFields: r,
201
- category: c,
189
+ numericFields: n,
190
+ category: r,
191
+ splitByFieldInfos: l
192
+ } = s, a = r ?? w(e), { categoriesArray: y, splitByFieldType: d } = l;
193
+ let u = [];
194
+ const F = Oe(e);
195
+ if (y.length === 0) {
196
+ u = H({
197
+ numericFields: n,
198
+ category: a,
202
199
  config: e,
203
200
  layerInfo: t,
204
201
  commonStrings: o
205
202
  });
206
- for (const d of x)
207
- d.query && (d.query.where = `${i}=''`);
203
+ for (const c of u)
204
+ c.query && (c.query.where = `${i}=''`);
208
205
  } else
209
- for (let d = 0; d < m.length; d += 1) {
210
- const B = m[d], v = {
211
- y: r,
212
- seriesIndex: d,
213
- category: c,
206
+ for (let c = 0; c < y.length; c += 1) {
207
+ const m = y[c], g = {
208
+ y: n,
209
+ seriesIndex: c,
210
+ category: a,
214
211
  commonStrings: o
215
- }, Y = S ? Oe(v) : O(v), ne = G({
212
+ }, b = F ? ve(g) : O(g), L = X({
216
213
  queryObject: t.layer,
217
214
  fieldName: i,
218
- fieldValue: B ?? ""
219
- }), k = `${B}`, A = {
220
- ...Y,
221
- id: k,
222
- name: ne ?? k,
223
- x: c === void 0 || c === "" ? C : c,
215
+ fieldValue: m ?? ""
216
+ }), B = `${m}`, C = e.series.find((oe) => Q(oe) === B), te = C?.name ?? L ?? B, q = C ?? b, ie = {
217
+ ...q,
218
+ id: B,
219
+ name: te,
220
+ x: a === void 0 || a === "" ? h : a,
221
+ y: b.y,
222
+ // always update y values based on default generated value
224
223
  query: {
225
- ...Y.query,
226
- where: `${i}=${F === Se.String && B !== null ? `'${B}'` : B}`
224
+ ...q.query,
225
+ where: `${i}=${d === ce.String && m !== null ? `'${m}'` : m}`
227
226
  }
228
- }, b = e.series.find((ae) => ie(ae) === k);
229
- b !== void 0 && (e.colorMatch || (A.type === f.BoxPlotSeries ? P(b) ? A.fillSymbol = b.fillSymbol : A.fillSymbol = {
230
- ...E(),
231
- color: b.lineSymbol?.color
232
- } : P(b) ? (A.lineSymbol = {
233
- ..._({ width: H }),
234
- ...b.fillSymbol !== void 0 ? { color: b.fillSymbol.color } : {}
235
- }, A.markerSymbol = {
236
- ...J(),
237
- ...b.fillSymbol !== void 0 ? { color: b.fillSymbol.color } : {}
238
- }) : (A.lineSymbol = b.lineSymbol, A.markerSymbol = b.markerSymbol), g = !0), A.id = b.id, A.name = b.name), x.push(A);
227
+ };
228
+ u.push(ie);
239
229
  }
240
- if (x = oe({
230
+ if (u = G({
241
231
  formerSeries: e.series,
242
- newSeries: x,
243
- showMean: N(e)
244
- }), e.colorMatch = !g, N(e)) {
245
- const d = e.series.find((v) => v.type === f.BoxPlotSeries), B = se({
246
- x: c,
247
- y: r,
248
- seriesTemplate: d,
232
+ newSeries: u,
233
+ showMean: V(e)
234
+ }), V(e)) {
235
+ const c = e.series.find((g) => g.type === p.BoxPlotSeries), m = _({
236
+ x: a,
237
+ y: n,
238
+ seriesTemplate: c,
249
239
  commonStrings: o
250
240
  });
251
- x.unshift(B);
241
+ u.unshift(m);
252
242
  }
253
- return x;
243
+ return u;
254
244
  }
255
- const os = async (s) => {
256
- const { splitByField: e, numericFields: t, category: o, config: i, layerInfo: r, commonStrings: l } = s, { layerFieldsInfo: n } = r, a = qe(o, t, e), y = Ae(n), c = L(i), m = Te(i, r, l), F = Z(i, r, l), x = ve({ config: i, layerInfo: r, newCategory: o });
257
- let g = R(i);
258
- if (!y.includes(c) && y.includes(o) ? g = ge() : y.includes(c) && !y.includes(o) && (g = xe()), g !== void 0 && ue(i, l, g), $(a ? { newShowMeanLines: i.showMean, config: i, commonStrings: l } : { newShowMeanLines: !1, config: i, commonStrings: l }), i.series = a ? await Ve({
245
+ const ss = (s) => {
246
+ const { splitByField: e, numericFields: t, category: o, config: i, layerInfo: n, commonStrings: r, splitByFieldInfos: l } = s, { layerFieldsInfo: a } = n, y = ke(o, t, e), d = he(a), u = w(i), F = we(i, n, r), c = R(i, n, r), m = Le({ config: i, layerInfo: n, newCategory: o });
247
+ let g = W(i);
248
+ if (!d.includes(u) && d.includes(o) ? g = Se() : d.includes(u) && !d.includes(o) && (g = pe()), g !== void 0 && ae(i, r, g), Y(y ? { newShowMeanLines: i.showMean, config: i, commonStrings: r } : { newShowMeanLines: !1, config: i, commonStrings: r }), i.series = y && l ? Pe({
259
249
  config: i,
260
- layerInfo: r,
250
+ layerInfo: n,
261
251
  splitByField: e,
262
252
  numericFields: t,
263
253
  category: o,
264
- commonStrings: l
265
- }) : te({
254
+ commonStrings: r,
255
+ splitByFieldInfos: l
256
+ }) : H({
266
257
  numericFields: t,
267
258
  config: i,
268
- layerInfo: r,
259
+ layerInfo: n,
269
260
  category: o,
270
- commonStrings: l
271
- }), x) {
272
- const d = z({
261
+ commonStrings: r
262
+ }), m) {
263
+ const L = N({
273
264
  fieldName: o,
274
265
  numericFields: t,
275
- fieldList: n
276
- }) ? "" : w(n, o);
277
- I(i, 0, d);
266
+ fieldList: a
267
+ }) ? "" : A(a, o);
268
+ M(i, 0, L);
278
269
  }
279
- if (F) {
280
- const S = T(i, r, l);
281
- I(i, 1, S);
270
+ if (c) {
271
+ const b = T(i, n, r);
272
+ M(i, 1, b);
282
273
  }
283
- i?.title !== void 0 && m && (i.title.content.text = re(i, r, l)), K({ config: i, value: null, axisIndex: 1, isMax: !1 }), K({ config: i, value: null, axisIndex: 1, isMax: !0 });
284
- }, ke = (s) => s?.standardizeValues ?? !1;
274
+ i?.title !== void 0 && F && (i.title.content.text = Z(i, n, r)), E({ config: i, value: null, axisIndex: 1, isMax: !1 }), E({ config: i, value: null, axisIndex: 1, isMax: !0 });
275
+ }, De = (s) => s?.standardizeValues ?? !1;
285
276
  function T(s, e, t) {
286
277
  const { layerFieldsInfo: o } = e;
287
- let r = ke(s) ? t.axisLabels.standardizedValues : t.axisLabels.values, l = s?.series?.map((n) => n.y).flat();
288
- return l = [...new Set(l)], l.length === 1 && (r = w(o, l[0])), r;
278
+ let n = De(s) ? t.axisLabels.standardizedValues : t.axisLabels.values, r = s?.series?.map((l) => l.y).flat();
279
+ return r = [...new Set(r)], r.length === 1 && (n = A(o, r[0])), n;
289
280
  }
290
- function re(s, e, t) {
291
- const { layerFieldsInfo: o } = e, i = L(s), r = ee(s), l = Me(s), n = r.map((c) => w(o ?? [], c)).join(", "), a = w(o ?? [], i);
281
+ function Z(s, e, t) {
282
+ const { layerFieldsInfo: o } = e, i = w(s), n = J(s), r = Te(s), l = n.map((d) => A(o ?? [], d)).join(", "), a = A(o ?? [], i);
292
283
  let y = "";
293
- return r.length > 0 && (i !== C && l !== "" ? y = M(t.titleLabels.distributionOfFieldsByCategoryAndSplitBy, {
294
- valueFields: n,
284
+ return n.length > 0 && (i !== h && r !== "" ? y = v(t.titleLabels.distributionOfFieldsByCategoryAndSplitBy, {
285
+ valueFields: l,
295
286
  category: a,
296
- splitByField: l
297
- }) : i !== C ? y = M(t.titleLabels.distributionOfFieldsByCategory, {
298
- valueFields: n,
287
+ splitByField: r
288
+ }) : i !== h ? y = v(t.titleLabels.distributionOfFieldsByCategory, {
289
+ valueFields: l,
299
290
  category: a
300
- }) : l !== "" ? y = M(t.titleLabels.distributionOfFieldsByCategory, {
301
- valueFields: n,
302
- category: l
303
- }) : y = M(t.titleLabels.distributionOfField, {
304
- valueField: n
291
+ }) : r !== "" ? y = v(t.titleLabels.distributionOfFieldsByCategory, {
292
+ valueFields: l,
293
+ category: r
294
+ }) : y = v(t.titleLabels.distributionOfField, {
295
+ valueField: l
305
296
  })), y;
306
297
  }
307
- const rs = (s) => {
298
+ const ts = (s) => {
308
299
  const { series: e, splitByField: t, layerInfo: o, commonStrings: i } = s;
309
- let r = typeof e.y == "string" ? w(o.layerFieldsInfo, e.y) : i.axisLabels.values;
310
- return ce(t) || (r = ie(e)), r = G({
300
+ let n = typeof e.y == "string" ? A(o.layerFieldsInfo, e.y) : i.axisLabels.values;
301
+ return re(t) || (n = Q(e)), n = X({
311
302
  queryObject: o.layer,
312
303
  fieldName: t,
313
- fieldValue: r ?? ""
314
- }) ?? r, r ?? e.id;
315
- }, ls = (s) => s?.showOutliers ?? !1, ns = (s) => {
304
+ fieldValue: n ?? ""
305
+ }) ?? n, n ?? e.id;
306
+ }, is = (s) => s?.showOutliers ?? !1, os = (s) => {
316
307
  const { newShowOutliers: e, config: t, layerInfo: o, commonStrings: i } = s;
317
- if (t.showOutliers = e, Z(t, o, i)) {
318
- const l = T(t, o, i);
319
- I(t, 1, l);
308
+ if (t.showOutliers = e, R(t, o, i)) {
309
+ const r = T(t, o, i);
310
+ M(t, 1, r);
320
311
  }
321
- }, as = (s) => {
322
- const { newStandardizeValues: e, config: t, layerInfo: o, commonStrings: i } = s, r = q(1, t), l = T(t, o, i), n = V(t);
323
- if (t.standardizeValues = e, r === l || n) {
312
+ }, rs = (s) => {
313
+ const { newStandardizeValues: e, config: t, layerInfo: o, commonStrings: i } = s, n = k(1, t), r = T(t, o, i), l = P(t);
314
+ if (t.standardizeValues = e, n === r || l) {
324
315
  const a = T(t, o, i);
325
- I(t, 1, a);
316
+ M(t, 1, a);
326
317
  }
327
- }, le = (s) => {
328
- let e = u.xAxisAsc;
329
- const t = s.orderOptions?.data?.orderType ?? p.Category, o = s.orderOptions?.data && "orderBy" in s.orderOptions.data ? s.orderOptions.data.orderBy : h.Ascending;
318
+ }, ee = (s) => {
319
+ let e = f.xAxisAsc;
320
+ const t = s.orderOptions?.data?.orderType ?? S.Category, o = s.orderOptions?.data && "orderBy" in s.orderOptions.data ? s.orderOptions.data.orderBy : x.Ascending;
330
321
  switch (t) {
331
- case p.Category:
332
- e = Array.isArray(o) ? u.customSort : o === h.Ascending ? u.xAxisAsc : u.xAxisDesc;
322
+ case S.Category:
323
+ e = Array.isArray(o) ? f.customSort : o === x.Ascending ? f.xAxisAsc : f.xAxisDesc;
333
324
  break;
334
- case p.Mean:
335
- e = o === h.Ascending ? u.meanAsc : u.meanDesc;
325
+ case S.Mean:
326
+ e = o === x.Ascending ? f.meanAsc : f.meanDesc;
336
327
  break;
337
- case p.Median:
338
- e = o === h.Ascending ? u.medianAsc : u.medianDesc;
328
+ case S.Median:
329
+ e = o === x.Ascending ? f.medianAsc : f.medianDesc;
339
330
  break;
340
331
  }
341
332
  return e;
342
- }, cs = (s, e, t) => {
343
- let o = p.Category, i = h.Ascending;
344
- if (e.orderOptions = e.orderOptions ?? {}, s === u.customSort && t !== void 0)
333
+ }, ns = (s, e, t) => {
334
+ let o = S.Category, i = x.Ascending;
335
+ if (e.orderOptions = e.orderOptions ?? {}, s === f.customSort && t !== void 0)
345
336
  e.orderOptions.data = {
346
- orderType: p.Category,
337
+ orderType: S.Category,
347
338
  orderBy: t
348
339
  };
349
340
  else {
350
341
  switch (s) {
351
- case u.xAxisAsc: {
352
- o = p.Category, i = h.Ascending;
342
+ case f.xAxisAsc: {
343
+ o = S.Category, i = x.Ascending;
353
344
  break;
354
345
  }
355
- case u.xAxisDesc: {
356
- o = p.Category, i = h.Descending;
346
+ case f.xAxisDesc: {
347
+ o = S.Category, i = x.Descending;
357
348
  break;
358
349
  }
359
- case u.meanAsc: {
360
- o = p.Mean, i = h.Ascending;
350
+ case f.meanAsc: {
351
+ o = S.Mean, i = x.Ascending;
361
352
  break;
362
353
  }
363
- case u.meanDesc: {
364
- o = p.Mean, i = h.Descending;
354
+ case f.meanDesc: {
355
+ o = S.Mean, i = x.Descending;
365
356
  break;
366
357
  }
367
- case u.medianAsc: {
368
- o = p.Median, i = h.Ascending;
358
+ case f.medianAsc: {
359
+ o = S.Median, i = x.Ascending;
369
360
  break;
370
361
  }
371
- case u.medianDesc: {
372
- o = p.Median, i = h.Descending;
362
+ case f.medianDesc: {
363
+ o = S.Median, i = x.Descending;
373
364
  break;
374
365
  }
375
366
  }
@@ -378,71 +369,72 @@ const rs = (s) => {
378
369
  orderBy: i
379
370
  };
380
371
  }
381
- }, N = (s) => s.showMean ?? !1, $ = (s) => {
382
- const { newShowMeanLines: e = !1, config: t, commonStrings: o, previousMeanLinesBoxColor: i } = s, r = e ? i : Be(t), l = (e ?? !1) !== (t.showMean ?? !1);
383
- if (t.showMean = e, l) {
384
- let n;
385
- e ? n = be(t.series) ? Pe(t.series, o) : t.series : n = De(t.series), n && (n = oe({
372
+ }, V = (s) => s.showMean ?? !1, Y = (s) => {
373
+ const { newShowMeanLines: e = !1, config: t, commonStrings: o, previousMeanLinesBoxColor: i } = s, n = e ? i : Fe(t), r = (e ?? !1) !== (t.showMean ?? !1);
374
+ if (t.showMean = e, r) {
375
+ let l;
376
+ e ? l = ge(t.series) ? Me(t.series, o) : t.series : l = Ie(t.series), l && (l = G({
386
377
  formerSeries: t.series,
387
- newSeries: n,
378
+ newSeries: l,
388
379
  showMean: e
389
- }), t.series = n);
380
+ }), t.series = l);
390
381
  }
391
- return e && i !== void 0 && Ce(i, t), { previousMeanLinesBoxColor: r };
392
- }, ds = (s) => {
382
+ return e && i !== void 0 && Ae(i, t), { previousMeanLinesBoxColor: n };
383
+ }, ls = (s) => {
393
384
  let e = [];
394
385
  const t = s.orderOptions?.data?.orderType;
395
- return le(s) === u.customSort && t === p.Category && (e = s.orderOptions?.data?.orderBy), e;
396
- }, ys = (s, e) => {
386
+ return ee(s) === f.customSort && t === S.Category && (e = s.orderOptions?.data?.orderBy), e;
387
+ }, as = (s, e) => {
397
388
  e.orderOptions ??= {};
398
389
  const t = e.orderOptions?.data?.orderType;
399
- le(e) === u.customSort && t === p.Category && (e.orderOptions.data = {
400
- orderType: p.Category,
390
+ ee(e) === f.customSort && t === S.Category && (e.orderOptions.data = {
391
+ orderType: S.Category,
401
392
  orderBy: s
402
393
  });
403
- }, us = async (s) => {
404
- const { config: e, layerInfo: t, errorStrings: o } = s, i = L(e), r = R(e)?.type, l = ee(e);
405
- let n = [];
406
- return r === f.CategoryAxisFormat && (z({
394
+ }, ds = async (s) => {
395
+ const { config: e, layerInfo: t, errorStrings: o } = s, i = w(e), n = W(e)?.type, r = J(e);
396
+ let l = [];
397
+ return n === p.CategoryAxisFormat && (N({
407
398
  fieldName: i,
408
- numericFields: l,
399
+ numericFields: r,
409
400
  fieldList: t.layerFieldsInfo
410
- }) ? n = l : W(i) || (n = await ye({
401
+ }) ? l = r : se(i) || (l = await le({
411
402
  layerInfo: t,
412
403
  config: e,
413
404
  category: i,
414
405
  errorStrings: o
415
- }))), n;
416
- }, W = (s) => s.trim() === "" || s === C, Ne = (s, e) => e.length > 1 && !W(s), qe = (s, e, t) => !Ne(s, e) && t !== "";
406
+ }))), l;
407
+ }, se = (s) => s.trim() === "" || s === h, Ve = (s, e) => e.length > 1 && !se(s), ke = (s, e, t) => !Ve(s, e) && t !== "";
417
408
  export {
418
- is as A,
419
- re as B,
420
- T as C,
421
- rs as D,
422
- L as a,
423
- ee as b,
424
- Me as c,
425
- ls as d,
426
- ns as e,
427
- ke as f,
428
- N as g,
429
- as as h,
430
- le as i,
431
- cs as j,
432
- us as k,
433
- ds as l,
434
- ys as m,
435
- $ as n,
436
- Be as o,
437
- Ce as p,
438
- qe as q,
439
- os as r,
440
- Ne as s,
441
- Ge as t,
442
- Ze as u,
443
- es as v,
444
- ss as w,
445
- we as x,
446
- Le as y,
447
- ts as z
409
+ Ze as A,
410
+ es as B,
411
+ Z as C,
412
+ T as D,
413
+ ts as E,
414
+ w as a,
415
+ J as b,
416
+ Te as c,
417
+ is as d,
418
+ os as e,
419
+ De as f,
420
+ V as g,
421
+ rs as h,
422
+ ee as i,
423
+ ns as j,
424
+ ds as k,
425
+ ls as l,
426
+ as as m,
427
+ Y as n,
428
+ Fe as o,
429
+ Ae as p,
430
+ ke as q,
431
+ ss as r,
432
+ Ve as s,
433
+ se as t,
434
+ _e as u,
435
+ He as v,
436
+ Qe as w,
437
+ Ge as x,
438
+ Be as y,
439
+ Ce as z
448
440
  };