@carbon/charts 1.11.8 → 1.11.9

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 (47) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/dist/{_baseEach-9b6a12fa.mjs → _baseEach-c7ca68a6.mjs} +2 -2
  3. package/dist/{_baseEach-9b6a12fa.mjs.map → _baseEach-c7ca68a6.mjs.map} +1 -1
  4. package/dist/{_baseEach-326db134.js → _baseEach-e8e98018.js} +2 -2
  5. package/dist/{_baseEach-326db134.js.map → _baseEach-e8e98018.js.map} +1 -1
  6. package/dist/{angle-utils-264ed176.mjs → angle-utils-7efc92a5.mjs} +2 -2
  7. package/dist/angle-utils-7efc92a5.mjs.map +1 -0
  8. package/dist/{angle-utils-ccc0d890.js → angle-utils-a22da679.js} +2 -2
  9. package/dist/angle-utils-a22da679.js.map +1 -0
  10. package/dist/{choropleth-300f112d.js → choropleth-16598e45.js} +4 -4
  11. package/dist/choropleth-16598e45.js.map +1 -0
  12. package/dist/{choropleth-9123f871.mjs → choropleth-8d45a771.mjs} +4 -4
  13. package/dist/choropleth-8d45a771.mjs.map +1 -0
  14. package/dist/color-scale-utils-56bbe3f2.js +2 -0
  15. package/dist/color-scale-utils-56bbe3f2.js.map +1 -0
  16. package/dist/{color-scale-utils-b9604b2c.mjs → color-scale-utils-a737b2e5.mjs} +908 -910
  17. package/dist/color-scale-utils-a737b2e5.mjs.map +1 -0
  18. package/dist/components/index.js +1 -1
  19. package/dist/components/index.mjs +4 -4
  20. package/dist/demo/index.js +1 -1
  21. package/dist/demo/index.mjs +5 -5
  22. package/dist/{index-4b5d1e49.mjs → index-daeaa9f4.mjs} +28 -28
  23. package/dist/index-daeaa9f4.mjs.map +1 -0
  24. package/dist/{index-eace9da9.js → index-e014597a.js} +2 -2
  25. package/dist/index-e014597a.js.map +1 -0
  26. package/dist/index.js +1 -1
  27. package/dist/index.js.map +1 -1
  28. package/dist/index.mjs +8 -8
  29. package/dist/index.mjs.map +1 -1
  30. package/dist/model/index.js +2 -2
  31. package/dist/model/index.js.map +1 -1
  32. package/dist/model/index.mjs +117 -117
  33. package/dist/model/index.mjs.map +1 -1
  34. package/dist/model/model.d.ts +1 -1
  35. package/dist/services/index.js +1 -1
  36. package/dist/services/index.mjs +4 -4
  37. package/dist/tools.d.ts +5 -8
  38. package/package.json +2 -2
  39. package/dist/angle-utils-264ed176.mjs.map +0 -1
  40. package/dist/angle-utils-ccc0d890.js.map +0 -1
  41. package/dist/choropleth-300f112d.js.map +0 -1
  42. package/dist/choropleth-9123f871.mjs.map +0 -1
  43. package/dist/color-scale-utils-2cd523be.js +0 -2
  44. package/dist/color-scale-utils-2cd523be.js.map +0 -1
  45. package/dist/color-scale-utils-b9604b2c.mjs.map +0 -1
  46. package/dist/index-4b5d1e49.mjs.map +0 -1
  47. package/dist/index-eace9da9.js.map +0 -1
@@ -1,7 +1,7 @@
1
- import { S as z, V as F, ab as U, g as u, z as b, e as G, y as j, a9 as M, M as k, ac as L, f as _, v as V, a0 as K, a1 as y, O as R, _ as x } from "../color-scale-utils-b9604b2c.mjs";
1
+ import { S as z, V as F, ab as U, g as u, z as b, e as G, y as j, a9 as M, M as k, ac as L, f as _, v as V, a0 as K, a1 as y, O as R, _ as x } from "../color-scale-utils-a737b2e5.mjs";
2
2
  import { bin as Z, stack as A, stackOffsetDiverging as H, scaleOrdinal as $, quantile as E, ascending as Q, min as P, max as N, extent as W, scaleLinear as X, scaleQuantize as Y } from "d3";
3
3
  import { S as D, _ as B, d as w, e as O, s as J } from "../enums-a96ef472.mjs";
4
- import { b as tt } from "../_baseEach-9b6a12fa.mjs";
4
+ import { b as tt } from "../_baseEach-c7ca68a6.mjs";
5
5
  import "../index-becfb567.mjs";
6
6
  function et(h, t, e, s) {
7
7
  for (var a = -1, o = h == null ? 0 : h.length; ++a < o; ) {
@@ -28,10 +28,10 @@ function ot(h) {
28
28
  }
29
29
  return s;
30
30
  }
31
- var it = Object.prototype, rt = it.hasOwnProperty, nt = at(function(h, t, e) {
32
- rt.call(h, e) ? h[e].push(t) : U(h, e, [t]);
31
+ var it = Object.prototype, nt = it.hasOwnProperty, rt = at(function(h, t, e) {
32
+ nt.call(h, e) ? h[e].push(t) : U(h, e, [t]);
33
33
  });
34
- const lt = nt;
34
+ const lt = rt;
35
35
  class m {
36
36
  constructor(t) {
37
37
  this.state = {
@@ -44,23 +44,23 @@ class m {
44
44
  const e = this.getOptions();
45
45
  let s = this.getData();
46
46
  const a = this.getDataGroups(), { groupMapsTo: o } = u(e, "data"), i = u(e, "axes");
47
- return t && (s = s.filter((r) => t.includes(r[o]))), i && Object.keys(i).forEach((r) => {
48
- const n = i[r].mapsTo, l = i[r].scaleType;
47
+ return t && (s = s.filter((n) => t.includes(n[o]))), i && Object.keys(i).forEach((n) => {
48
+ const r = i[n].mapsTo, l = i[n].scaleType;
49
49
  if ((l === D.LINEAR || l === D.LOG) && (s = s.map((c) => ({
50
50
  ...c,
51
- [n]: c[n] === null ? c[n] : Number(c[n])
52
- }))), n && i[r].domain)
51
+ [r]: c[r] === null ? c[r] : Number(c[r])
52
+ }))), r && i[n].domain)
53
53
  if (l === D.LABELS)
54
54
  s = s.filter(
55
- (c) => i[r].domain.includes(c[n])
55
+ (c) => i[n].domain.includes(c[r])
56
56
  );
57
57
  else {
58
- const [c, p] = i[r].domain;
58
+ const [c, p] = i[n].domain;
59
59
  s = s.filter(
60
- (g) => !(n in g) || g[n] >= c && g[n] <= p
60
+ (g) => !(r in g) || g[r] >= c && g[r] <= p
61
61
  );
62
62
  }
63
- }), s.filter((r) => a.find((n) => n.name === r[o]));
63
+ }), s.filter((n) => a.find((r) => r.name === n[o]));
64
64
  }
65
65
  /**
66
66
  * Charts that have group configs passed into them, only want to retrieve the display data relevant to that chart
@@ -71,7 +71,7 @@ class m {
71
71
  return null;
72
72
  const { ACTIVE: e } = b.items.status, s = this.getDataGroups(t), { groupMapsTo: a } = this.getOptions().data;
73
73
  return this.getAllDataFromDomain(t).filter((i) => s.find(
74
- (r) => r.name === i[a] && r.status === e
74
+ (n) => n.name === i[a] && n.status === e
75
75
  ));
76
76
  }
77
77
  getData() {
@@ -108,14 +108,14 @@ class m {
108
108
  return lt(t, "group");
109
109
  }
110
110
  getBinConfigurations() {
111
- const t = this.getDisplayData(), e = this.getOptions(), s = this.services.cartesianScales.getMainXAxisPosition(), a = this.services.cartesianScales.getDomainIdentifier(), o = e.axes[s], { groupMapsTo: i } = e.data, { bins: r = j.defaultBins } = o, n = Array.isArray(r), l = Z().value((d) => d[a]).thresholds(r)(t);
112
- if (n)
113
- l[l.length - 1].x1 = r[r.length - 1];
111
+ const t = this.getDisplayData(), e = this.getOptions(), s = this.services.cartesianScales.getMainXAxisPosition(), a = this.services.cartesianScales.getDomainIdentifier(), o = e.axes[s], { groupMapsTo: i } = e.data, { bins: n = j.defaultBins } = o, r = Array.isArray(n), l = Z().value((d) => d[a]).thresholds(n)(t);
112
+ if (r)
113
+ l[l.length - 1].x1 = n[n.length - 1];
114
114
  else {
115
115
  const d = l[0].x1 - l[0].x0;
116
116
  l[l.length - 1].x1 = +l[l.length - 1].x0 + d;
117
117
  }
118
- const c = n ? [r[0], r[r.length - 1]] : [l[0].x0, l[l.length - 1].x1], p = Array.from(new Set(t.map((d) => d[i]))), g = [];
118
+ const c = r ? [n[0], n[n.length - 1]] : [l[0].x0, l[l.length - 1].x1], p = Array.from(new Set(t.map((d) => d[i]))), g = [];
119
119
  return l.forEach((d) => {
120
120
  const f = `${d.x0}-${d.x1}`, T = this.aggregateBinDataByGroup(d);
121
121
  p.forEach((C) => {
@@ -135,9 +135,9 @@ class m {
135
135
  const t = this.getOptions(), { groupMapsTo: e } = t.data, s = this.getActiveDataGroupNames(), { bins: a } = this.getBinConfigurations(), o = this.getDataValuesGroupedByKeys({
136
136
  bins: a
137
137
  });
138
- return A().keys(s)(o).map((i, r) => Object.keys(i).filter((n) => !isNaN(n)).map((n) => {
139
- const l = i[n];
140
- return l[e] = s[r], l;
138
+ return A().keys(s)(o).map((i, n) => Object.keys(i).filter((r) => !isNaN(r)).map((r) => {
139
+ const l = i[r];
140
+ return l[e] = s[n], l;
141
141
  }));
142
142
  }
143
143
  getGroupedData(t) {
@@ -153,56 +153,56 @@ class m {
153
153
  getStackKeys({ bins: t = null, groups: e = null } = { bins: null, groups: null }) {
154
154
  const s = this.getOptions(), a = this.getDisplayData(e);
155
155
  let o;
156
- t ? o = t.map((n) => `${n.x0}-${n.x1}`) : o = M(
157
- a.map((n) => {
158
- const l = this.services.cartesianScales.getDomainIdentifier(n);
159
- return n[l] instanceof Date ? k(n[l]) : n[l] && typeof n[l].toString == "function" ? n[l].toString() : n[l];
156
+ t ? o = t.map((r) => `${r.x0}-${r.x1}`) : o = M(
157
+ a.map((r) => {
158
+ const l = this.services.cartesianScales.getDomainIdentifier(r);
159
+ return r[l] instanceof Date ? k(r[l]) : r[l] && typeof r[l].toString == "function" ? r[l].toString() : r[l];
160
160
  })
161
161
  );
162
- const i = this.services.cartesianScales.domainAxisPosition, r = s.axes[i].scaleType;
163
- return r === D.TIME ? o.sort((n, l) => {
164
- const c = new Date(n), p = new Date(l);
162
+ const i = this.services.cartesianScales.domainAxisPosition, n = s.axes[i].scaleType;
163
+ return n === D.TIME ? o.sort((r, l) => {
164
+ const c = new Date(r), p = new Date(l);
165
165
  return c - p;
166
- }) : (r === D.LOG || r === D.LINEAR) && o.sort((n, l) => n - l), o;
166
+ }) : (n === D.LOG || n === D.LINEAR) && o.sort((r, l) => r - l), o;
167
167
  }
168
168
  getDataValuesGroupedByKeys({ bins: t = null, groups: e = null }) {
169
- const s = this.getOptions(), { groupMapsTo: a } = s.data, o = this.getDisplayData(e), i = this.getDataGroupNames(), r = this.getStackKeys({ bins: t, groups: e });
170
- return t ? r.map((n) => {
171
- const [l, c] = n.split("-"), p = { x0: l, x1: c }, g = t.find((d) => d.x0.toString() === l.toString());
169
+ const s = this.getOptions(), { groupMapsTo: a } = s.data, o = this.getDisplayData(e), i = this.getDataGroupNames(), n = this.getStackKeys({ bins: t, groups: e });
170
+ return t ? n.map((r) => {
171
+ const [l, c] = r.split("-"), p = { x0: l, x1: c }, g = t.find((d) => d.x0.toString() === l.toString());
172
172
  return i.forEach((d) => {
173
173
  p[d] = g.filter(
174
174
  (f) => f[a] === d
175
175
  ).length;
176
176
  }), p;
177
- }) : r.map((n) => {
178
- const l = { sharedStackKey: n };
177
+ }) : n.map((r) => {
178
+ const l = { sharedStackKey: r };
179
179
  return i.forEach((c) => {
180
180
  const p = o.find((d) => {
181
181
  const f = this.services.cartesianScales.getDomainIdentifier(d);
182
- return d[a] === c && Object.prototype.hasOwnProperty.call(d, f) && (d[f] instanceof Date ? k(d[f]) === n : d[f].toString() === n);
182
+ return d[a] === c && Object.prototype.hasOwnProperty.call(d, f) && (d[f] instanceof Date ? k(d[f]) === r : d[f].toString() === r);
183
183
  }), g = this.services.cartesianScales.getRangeIdentifier(l);
184
184
  l[c] = p ? p[g] : null;
185
185
  }), l;
186
186
  });
187
187
  }
188
188
  getStackedData({ percentage: t = !1, groups: e = null, divergent: s = !1 }) {
189
- const a = this.getOptions(), { groupMapsTo: o } = a.data, i = this.getActiveDataGroupNames(e), r = this.getDataValuesGroupedByKeys({
189
+ const a = this.getOptions(), { groupMapsTo: o } = a.data, i = this.getActiveDataGroupNames(e), n = this.getDataValuesGroupedByKeys({
190
190
  groups: e
191
191
  });
192
192
  if (t) {
193
- const l = ot(r.map((c) => [c.sharedStackKey, 0]));
194
- r.forEach((c) => {
193
+ const l = ot(n.map((c) => [c.sharedStackKey, 0]));
194
+ n.forEach((c) => {
195
195
  i.forEach((p) => {
196
196
  l[c.sharedStackKey] += c[p];
197
197
  });
198
- }), r.forEach((c) => {
198
+ }), n.forEach((c) => {
199
199
  i.forEach((p) => {
200
200
  const g = l[c.sharedStackKey];
201
201
  l[c.sharedStackKey] ? c[p] = c[p] / g * 100 : c[p] = 0;
202
202
  });
203
203
  });
204
204
  }
205
- return (s ? A().offset(H) : A()).keys(i)(r).map((l, c) => Object.keys(l).filter((p) => !isNaN(p)).map((p) => {
205
+ return (s ? A().offset(H) : A()).keys(i)(n).map((l, c) => Object.keys(l).filter((p) => !isNaN(p)).map((p) => {
206
206
  const g = l[p];
207
207
  return g[o] = i[c], g;
208
208
  }));
@@ -261,8 +261,8 @@ class m {
261
261
  a.forEach((c, p) => {
262
262
  a[p].status = c.name === t ? e : s;
263
263
  });
264
- const r = a.filter((c) => c.status === e), n = this.getOptions();
265
- a.some((c) => c.status === s) ? n.data.selectedGroups = r.map((c) => c.name) : n.data.selectedGroups = [], this.services.events.dispatchEvent(B.Legend.ITEMS_UPDATE, {
264
+ const n = a.filter((c) => c.status === e), r = this.getOptions();
265
+ a.some((c) => c.status === s) ? r.data.selectedGroups = n.map((c) => c.name) : r.data.selectedGroups = [], this.services.events.dispatchEvent(B.Legend.ITEMS_UPDATE, {
266
266
  dataGroups: a
267
267
  }), this.set({
268
268
  dataGroups: a
@@ -272,7 +272,7 @@ class m {
272
272
  * Should the data point be filled?
273
273
  * @param group
274
274
  * @param key
275
- * @param value
275
+ * @param data
276
276
  * @param defaultFilled the default for this chart
277
277
  */
278
278
  getIsFilled(t, e, s, a) {
@@ -319,17 +319,17 @@ class m {
319
319
  );
320
320
  const e = [], { datasets: s, labels: a } = t;
321
321
  return s.forEach((o) => {
322
- o.data.forEach((i, r) => {
323
- let n;
322
+ o.data.forEach((i, n) => {
323
+ let r;
324
324
  const l = u(o, "label");
325
325
  if (l === null) {
326
- const p = u(a, r);
327
- p ? n = p : n = "Ungrouped";
326
+ const p = u(a, n);
327
+ p ? r = p : r = "Ungrouped";
328
328
  } else
329
- n = l;
329
+ r = l;
330
330
  const c = {
331
- group: n,
332
- key: a[r]
331
+ group: r,
332
+ key: a[n]
333
333
  };
334
334
  isNaN(i) ? (c.value = i.value, c.date = i.date) : c.value = i, e.push(c);
335
335
  });
@@ -363,14 +363,14 @@ class m {
363
363
  }) : this.allDataGroups = this.getDataGroupNames();
364
364
  }
365
365
  generateDataGroups(t) {
366
- const { groupMapsTo: e } = this.getOptions().data, { ACTIVE: s, DISABLED: a } = b.items.status, o = this.getOptions(), i = M(t.map((n) => n[e]));
366
+ const { groupMapsTo: e } = this.getOptions().data, { ACTIVE: s, DISABLED: a } = b.items.status, o = this.getOptions(), i = M(t.map((r) => r[e]));
367
367
  o.data.selectedGroups.length && (o.data.selectedGroups.every(
368
368
  (l) => i.includes(l)
369
369
  ) || (o.data.selectedGroups = []));
370
- const r = (n) => !o.data.selectedGroups.length || o.data.selectedGroups.includes(n) ? s : a;
371
- return i.map((n) => ({
372
- name: n,
373
- status: r(n)
370
+ const n = (r) => !o.data.selectedGroups.length || o.data.selectedGroups.includes(r) ? s : a;
371
+ return i.map((r) => ({
372
+ name: r,
373
+ status: n(r)
374
374
  }));
375
375
  }
376
376
  /*
@@ -398,10 +398,10 @@ class m {
398
398
  let s = u(t, "option");
399
399
  const a = V.pairingOptions, o = e > 5 ? 14 : e, i = `${o}-color`;
400
400
  s = s <= a[i] ? s : 1;
401
- const r = this.allDataGroups.map(
402
- (n, l) => `${o}-${s}-${l % 14 + 1}`
401
+ const n = this.allDataGroups.map(
402
+ (r, l) => `${o}-${s}-${l % 14 + 1}`
403
403
  );
404
- this.colorClassNames = $().range(r).domain(this.allDataGroups);
404
+ this.colorClassNames = $().range(n).domain(this.allDataGroups);
405
405
  }
406
406
  }
407
407
  class S extends m {
@@ -428,25 +428,25 @@ class S extends m {
428
428
  }), a;
429
429
  }
430
430
  getTabularDataArray() {
431
- const t = this.getDisplayData(), e = this.getOptions(), { groupMapsTo: s } = e.data, { cartesianScales: a } = this.services, { primaryDomain: o, primaryRange: i, secondaryDomain: r, secondaryRange: n } = this.assignRangeAndDomains(), l = a.getDomainAxisScaleType();
431
+ const t = this.getDisplayData(), e = this.getOptions(), { groupMapsTo: s } = e.data, { cartesianScales: a } = this.services, { primaryDomain: o, primaryRange: i, secondaryDomain: n, secondaryRange: r } = this.assignRangeAndDomains(), l = a.getDomainAxisScaleType();
432
432
  let c;
433
433
  return l === D.TIME && (c = (g) => K(g, "MMM d, yyyy")), [
434
434
  [
435
435
  "Group",
436
436
  o.label,
437
437
  i.label,
438
- ...r ? [r.label] : [],
439
- ...n ? [n.label] : []
438
+ ...n ? [n.label] : [],
439
+ ...r ? [r.label] : []
440
440
  ],
441
441
  ...t.map((g) => [
442
442
  g[s],
443
443
  g[o.identifier] === null ? "&ndash;" : c ? c(g[o.identifier]) : g[o.identifier],
444
444
  g[i.identifier] === null || isNaN(g[i.identifier]) ? "&ndash;" : g[i.identifier].toLocaleString(),
445
- ...r ? [
446
- g[r.identifier] === null ? "&ndash;" : g[r.identifier]
447
- ] : [],
448
445
  ...n ? [
449
- g[n.identifier] === null || isNaN(g[n.identifier]) ? "&ndash;" : g[n.identifier]
446
+ g[n.identifier] === null ? "&ndash;" : g[n.identifier]
447
+ ] : [],
448
+ ...r ? [
449
+ g[r.identifier] === null || isNaN(g[r.identifier]) ? "&ndash;" : g[r.identifier]
450
450
  ] : []
451
451
  ])
452
452
  ];
@@ -473,13 +473,13 @@ class S extends m {
473
473
  const { cartesianScales: a } = this.services;
474
474
  if (e && a.domainAxisPosition && a.rangeAxisPosition) {
475
475
  const o = a.getDomainIdentifier(), i = a.getRangeIdentifier();
476
- let r = e.map((n) => n[o].getTime());
477
- r = M(r).sort(), s = r.map((n) => {
476
+ let n = e.map((r) => r[o].getTime());
477
+ n = M(n).sort(), s = n.map((r) => {
478
478
  let l = 0;
479
479
  const c = {};
480
480
  return e.forEach((p) => {
481
- p[o].getTime() === n && (l += p[i]);
482
- }), c[o] = new Date(n), c[i] = l, c;
481
+ p[o].getTime() === r && (l += p[i]);
482
+ }), c[o] = new Date(r), c[i] = l, c;
483
483
  });
484
484
  }
485
485
  this.set({ zoomBarData: s });
@@ -495,8 +495,8 @@ class S extends m {
495
495
  return Object.keys(O).forEach((a) => {
496
496
  const o = O[a], i = e.axes[o];
497
497
  if (i && i.scaleType === D.TIME) {
498
- const r = i.mapsTo;
499
- (r !== null || r !== void 0) && s.push(r);
498
+ const n = i.mapsTo;
499
+ (n !== null || n !== void 0) && s.push(n);
500
500
  }
501
501
  }), s.length > 0 && t.forEach((a) => {
502
502
  s.forEach((o) => {
@@ -534,14 +534,14 @@ class Dt extends S {
534
534
  getBoxplotData() {
535
535
  const t = this.getOptions(), { groupMapsTo: e } = t.data, s = this.getGroupedData(), a = [];
536
536
  for (const { name: o, data: i } of s) {
537
- const r = this.services.cartesianScales.getRangeIdentifier(), n = i.map((v) => v[r]).sort(Q), l = {
537
+ const n = this.services.cartesianScales.getRangeIdentifier(), r = i.map((v) => v[n]).sort(Q), l = {
538
538
  [e]: o,
539
- counts: n,
540
- quartiles: this.getBoxQuartiles(n),
539
+ counts: r,
540
+ quartiles: this.getBoxQuartiles(r),
541
541
  outliers: null,
542
542
  whiskers: null
543
543
  }, c = l.quartiles.q_25, p = l.quartiles.q_75, g = (p - c) * 1.5, d = c - g, f = p + g, T = [], C = [];
544
- for (const v of n)
544
+ for (const v of r)
545
545
  v < d || v > f ? T.push(v) : C.push(v);
546
546
  l.outliers = T;
547
547
  const I = P(C), q = N(C);
@@ -566,7 +566,7 @@ class Dt extends S {
566
566
  u(o, "quartiles", "q_75") !== null ? u(o, "quartiles", "q_75").toLocaleString() : "&ndash;",
567
567
  u(o, "whiskers", "max") !== null ? u(o, "whiskers", "max").toLocaleString() : "&ndash;",
568
568
  u(o, "quartiles", "q_75") !== null && u(o, "quartiles", "q_25") !== null ? (u(o, "quartiles", "q_75") - u(o, "quartiles", "q_25")).toLocaleString() : "&ndash;",
569
- i.map((r) => r.toLocaleString()).join(",")
569
+ i.map((n) => n.toLocaleString()).join(",")
570
570
  ];
571
571
  })
572
572
  ];
@@ -602,13 +602,13 @@ class ft extends S {
602
602
  const t = this.getDisplayData(), e = this.getOptions(), { groupMapsTo: s } = e.data, a = this.services.cartesianScales.getRangeIdentifier(), o = u(e, "bullet", "performanceAreaTitles");
603
603
  return [
604
604
  ["Title", "Group", "Value", "Target", "Percentage", "Performance"],
605
- ...t.map((r) => [
606
- r.title,
607
- r[s],
608
- r.value === null ? "&ndash;" : r.value,
609
- u(r, "marker") === null ? "&ndash;" : r.marker,
610
- u(r, "marker") === null ? "&ndash;" : `${Math.floor(r[a] / r.marker * 100)}%`,
611
- o[this.getMatchingRangeIndexForDatapoint(r)]
605
+ ...t.map((n) => [
606
+ n.title,
607
+ n[s],
608
+ n.value === null ? "&ndash;" : n.value,
609
+ u(n, "marker") === null ? "&ndash;" : n.marker,
610
+ u(n, "marker") === null ? "&ndash;" : `${Math.floor(n[a] / n.marker * 100)}%`,
611
+ o[this.getMatchingRangeIndexForDatapoint(n)]
612
612
  ])
613
613
  ];
614
614
  }
@@ -685,7 +685,7 @@ class yt extends m {
685
685
  const e = this.getDisplayData(), s = t || this.getOptions(), a = e.length === 1 && u(e, 0, "children") ? u(e, 0, "children") : e;
686
686
  let o = this.getHierarchyLevel();
687
687
  return a.some((i) => {
688
- if (i.children && i.children.some((r) => r.children))
688
+ if (i.children && i.children.some((n) => n.children))
689
689
  return o = 3, !1;
690
690
  }), u(s, "canvasZoom", "enabled") === !0 && o > 2 ? {
691
691
  legend: {
@@ -750,10 +750,10 @@ class yt extends m {
750
750
  getChildrenDatums(t, e, s = [], a = 0) {
751
751
  const o = e;
752
752
  return t.forEach((i) => {
753
- const r = i.name;
754
- let n = 0;
753
+ const n = i.name;
754
+ let r = 0;
755
755
  if (i.children)
756
- i.children.length > 0 && (typeof i.value == "number" && (a += i.value), n += this.getChildrenDatums(i.children, r, s, n), s.push([r, o, n]), a += n);
756
+ i.children.length > 0 && (typeof i.value == "number" && (a += i.value), r += this.getChildrenDatums(i.children, n, s, r), s.push([n, o, r]), a += r);
757
757
  else {
758
758
  let l = 0;
759
759
  typeof i.value == "number" && (l = i.value, a += i.value), s.push([i.name, o, l]);
@@ -878,10 +878,10 @@ class Ct extends S {
878
878
  };
879
879
  }), t.forEach((i) => {
880
880
  this._matrix[i] = G(o);
881
- }), this.getDisplayData().forEach((i, r) => {
881
+ }), this.getDisplayData().forEach((i, n) => {
882
882
  this._matrix[i[s]][i[a]] = {
883
883
  value: i.value,
884
- index: r
884
+ index: n
885
885
  };
886
886
  });
887
887
  }
@@ -906,12 +906,12 @@ class Ct extends S {
906
906
  y(this._matrix) && this.getMatrix();
907
907
  const t = this.getUniqueDomain(), e = this.getUniqueRanges(), s = this.services.cartesianScales.getDomainIdentifier(), a = this.services.cartesianScales.getRangeIdentifier(), o = [];
908
908
  return t.forEach((i) => {
909
- e.forEach((r) => {
910
- const n = {
911
- value: this._matrix[i][r].value,
912
- index: this._matrix[i][r].index
909
+ e.forEach((n) => {
910
+ const r = {
911
+ value: this._matrix[i][n].value,
912
+ index: this._matrix[i][n].index
913
913
  };
914
- n[s] = i, n[a] = r, o.push(n);
914
+ r[s] = i, r[a] = n, o.push(r);
915
915
  });
916
916
  }), o;
917
917
  }
@@ -939,15 +939,15 @@ class Ct extends S {
939
939
  let a = u(t, "color", "pairing", "option");
940
940
  const o = this.getValueDomain(), i = o[0] < 0 && o[1] > 0 ? "diverge" : "mono";
941
941
  (a < 1 && a > 4 && i === "mono" || a < 1 && a > 2 && i === "diverge") && (a = 1);
942
- const r = s ? e : [];
942
+ const n = s ? e : [];
943
943
  if (!s) {
944
944
  const l = i === "diverge" ? 17 : 11;
945
945
  for (let c = 1; c < l + 1; c++)
946
- r.push(`fill-${i}-${a}-${c}`);
946
+ n.push(`fill-${i}-${a}-${c}`);
947
947
  }
948
- this._colorScale = Y().domain(o).range(r);
949
- const n = u(this.getOptions(), "color");
950
- this._colorScale = R(this.getDisplayData(), n);
948
+ this._colorScale = Y().domain(o).range(n);
949
+ const r = u(this.getOptions(), "color");
950
+ this._colorScale = R(this.getDisplayData(), r);
951
951
  }
952
952
  }
953
953
  class St extends S {
@@ -960,7 +960,7 @@ class St extends S {
960
960
  ],
961
961
  ...x(s, 0).map((o, i) => [
962
962
  `${x(o, "data.x0")} – ${x(o, "data.x1")}`,
963
- ...s.map((r) => x(r[i], `data.${x(r[i], e)}`))
963
+ ...s.map((n) => x(n[i], `data.${x(n[i], e)}`))
964
964
  ])
965
965
  ];
966
966
  }
@@ -985,10 +985,10 @@ class Tt extends m {
985
985
  * Get the associated status for the data by checking the ranges
986
986
  */
987
987
  getStatus() {
988
- const t = this.getOptions(), e = u(this.getDisplayData()), s = (e == null ? void 0 : e.reduce((i, r) => i + r.value, 0)) ?? 0, a = u(t, "meter", "proportional") ? s : s > 100 ? 100 : s, o = u(t, "meter", "status", "ranges");
988
+ const t = this.getOptions(), e = u(this.getDisplayData()), s = (e == null ? void 0 : e.reduce((i, n) => i + n.value, 0)) ?? 0, a = u(t, "meter", "proportional") ? s : s > 100 ? 100 : s, o = u(t, "meter", "status", "ranges");
989
989
  if (o) {
990
990
  const i = o.filter(
991
- (r) => r.range[0] <= a && a <= r.range[1]
991
+ (n) => n.range[0] <= a && a <= n.range[1]
992
992
  );
993
993
  if (i.length > 0)
994
994
  return i[0].status;
@@ -997,22 +997,22 @@ class Tt extends m {
997
997
  }
998
998
  getTabularDataArray() {
999
999
  const t = this.getDisplayData(), e = this.getOptions(), { groupMapsTo: s } = e.data, a = this.getStatus(), o = u(e, "meter", "proportional");
1000
- let i = [], r;
1000
+ let i = [], n;
1001
1001
  if (o === null) {
1002
- r = 100;
1003
- const n = t[0];
1002
+ n = 100;
1003
+ const r = t[0];
1004
1004
  i = [
1005
1005
  ["Group", "Value", ...a ? ["Status"] : []],
1006
- [n[s], n.value, ...a ? [a] : []]
1006
+ [r[s], r.value, ...a ? [a] : []]
1007
1007
  ];
1008
1008
  } else {
1009
- const n = u(o, "total");
1010
- r = n || this.getMaximumDomain(t), i = [
1009
+ const r = u(o, "total");
1010
+ n = r || this.getMaximumDomain(t), i = [
1011
1011
  ["Group", "Value", "Percentage of total"],
1012
1012
  ...t.map((l) => [
1013
1013
  l[s],
1014
1014
  l.value,
1015
- (l.value / r * 100).toFixed(2) + " %"
1015
+ (l.value / n * 100).toFixed(2) + " %"
1016
1016
  ])
1017
1017
  ];
1018
1018
  }
@@ -1024,13 +1024,13 @@ class bt extends S {
1024
1024
  super(t);
1025
1025
  }
1026
1026
  getTabularDataArray() {
1027
- const t = this.getOptions(), e = this.getGroupedData(), { angle: s, value: a } = u(t, "radar", "axes"), o = u(e, "0", "data").map((r) => r[s]);
1027
+ const t = this.getOptions(), e = this.getGroupedData(), { angle: s, value: a } = u(t, "radar", "axes"), o = u(e, "0", "data").map((n) => n[s]);
1028
1028
  return [
1029
1029
  ["Group", ...o],
1030
- ...e.map((r) => [
1031
- r.name,
1030
+ ...e.map((n) => [
1031
+ n.name,
1032
1032
  ...o.map(
1033
- (n, l) => u(r, "data", l, a) !== null ? u(r, "data", l, a).toLocaleString() : "&ndash;"
1033
+ (r, l) => u(n, "data", l, a) !== null ? u(n, "data", l, a).toLocaleString() : "&ndash;"
1034
1034
  )
1035
1035
  ])
1036
1036
  ];
@@ -1078,10 +1078,10 @@ class At extends m {
1078
1078
  const t = this.getDisplayData(), e = this.getOptions(), { fontSizeMapsTo: s, wordMapsTo: a } = e.wordCloud, { groupMapsTo: o } = e.data;
1079
1079
  return [
1080
1080
  [e.tooltip.wordLabel, "Group", e.tooltip.valueLabel],
1081
- ...t.map((r) => [
1082
- r[a],
1083
- r[o],
1084
- r[s]
1081
+ ...t.map((n) => [
1082
+ n[a],
1083
+ n[o],
1084
+ n[s]
1085
1085
  ])
1086
1086
  ];
1087
1087
  }