@kong-ui-public/analytics-chart 0.16.11 → 0.16.12
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.
- package/dist/types/composables/useBarChartOptions.d.ts +1 -0
- package/dist/types/composables/useBarChartOptions.d.ts.map +1 -1
- package/dist/types/composables/useExploreResultToDatasets.d.ts.map +1 -1
- package/dist/types/types/dataset-generation-types.d.ts +14 -0
- package/dist/types/types/dataset-generation-types.d.ts.map +1 -0
- package/dist/types/types/index.d.ts +1 -0
- package/dist/types/types/index.d.ts.map +1 -1
- package/dist/vitals-chart.es.js +916 -896
- package/dist/vitals-chart.umd.js +7 -7
- package/package.json +1 -1
package/dist/vitals-chart.es.js
CHANGED
|
@@ -1296,9 +1296,9 @@ function pa(n, t, e, i) {
|
|
|
1296
1296
|
function mu(n, t, e, i, r) {
|
|
1297
1297
|
let a, s, o, l, c, u, d, h;
|
|
1298
1298
|
const f = t.pointStyle, g = t.rotation, v = t.radius;
|
|
1299
|
-
let
|
|
1299
|
+
let p = (g || 0) * Fs;
|
|
1300
1300
|
if (f && typeof f == "object" && (a = f.toString(), a === "[object HTMLImageElement]" || a === "[object HTMLCanvasElement]")) {
|
|
1301
|
-
n.save(), n.translate(e, i), n.rotate(
|
|
1301
|
+
n.save(), n.translate(e, i), n.rotate(p), n.drawImage(f, -f.width / 2, -f.height / 2, f.width, f.height), n.restore();
|
|
1302
1302
|
return;
|
|
1303
1303
|
}
|
|
1304
1304
|
if (!(isNaN(v) || v <= 0)) {
|
|
@@ -1307,33 +1307,33 @@ function mu(n, t, e, i, r) {
|
|
|
1307
1307
|
r ? n.ellipse(e, i, r / 2, v, 0, 0, gt) : n.arc(e, i, v, 0, gt), n.closePath();
|
|
1308
1308
|
break;
|
|
1309
1309
|
case "triangle":
|
|
1310
|
-
u = r ? r / 2 : v, n.moveTo(e + Math.sin(
|
|
1310
|
+
u = r ? r / 2 : v, n.moveTo(e + Math.sin(p) * u, i - Math.cos(p) * v), p += lr, n.lineTo(e + Math.sin(p) * u, i - Math.cos(p) * v), p += lr, n.lineTo(e + Math.sin(p) * u, i - Math.cos(p) * v), n.closePath();
|
|
1311
1311
|
break;
|
|
1312
1312
|
case "rectRounded":
|
|
1313
|
-
c = v * 0.516, l = v - c, s = Math.cos(
|
|
1313
|
+
c = v * 0.516, l = v - c, s = Math.cos(p + re) * l, d = Math.cos(p + re) * (r ? r / 2 - c : l), o = Math.sin(p + re) * l, h = Math.sin(p + re) * (r ? r / 2 - c : l), n.arc(e - d, i - o, c, p - X, p - mt), n.arc(e + h, i - s, c, p - mt, p), n.arc(e + d, i + o, c, p, p + mt), n.arc(e - h, i + s, c, p + mt, p + X), n.closePath();
|
|
1314
1314
|
break;
|
|
1315
1315
|
case "rect":
|
|
1316
1316
|
if (!g) {
|
|
1317
1317
|
l = Math.SQRT1_2 * v, u = r ? r / 2 : l, n.rect(e - u, i - l, 2 * u, 2 * l);
|
|
1318
1318
|
break;
|
|
1319
1319
|
}
|
|
1320
|
-
|
|
1320
|
+
p += re;
|
|
1321
1321
|
case "rectRot":
|
|
1322
|
-
d = Math.cos(
|
|
1322
|
+
d = Math.cos(p) * (r ? r / 2 : v), s = Math.cos(p) * v, o = Math.sin(p) * v, h = Math.sin(p) * (r ? r / 2 : v), n.moveTo(e - d, i - o), n.lineTo(e + h, i - s), n.lineTo(e + d, i + o), n.lineTo(e - h, i + s), n.closePath();
|
|
1323
1323
|
break;
|
|
1324
1324
|
case "crossRot":
|
|
1325
|
-
|
|
1325
|
+
p += re;
|
|
1326
1326
|
case "cross":
|
|
1327
|
-
d = Math.cos(
|
|
1327
|
+
d = Math.cos(p) * (r ? r / 2 : v), s = Math.cos(p) * v, o = Math.sin(p) * v, h = Math.sin(p) * (r ? r / 2 : v), n.moveTo(e - d, i - o), n.lineTo(e + d, i + o), n.moveTo(e + h, i - s), n.lineTo(e - h, i + s);
|
|
1328
1328
|
break;
|
|
1329
1329
|
case "star":
|
|
1330
|
-
d = Math.cos(
|
|
1330
|
+
d = Math.cos(p) * (r ? r / 2 : v), s = Math.cos(p) * v, o = Math.sin(p) * v, h = Math.sin(p) * (r ? r / 2 : v), n.moveTo(e - d, i - o), n.lineTo(e + d, i + o), n.moveTo(e + h, i - s), n.lineTo(e - h, i + s), p += re, d = Math.cos(p) * (r ? r / 2 : v), s = Math.cos(p) * v, o = Math.sin(p) * v, h = Math.sin(p) * (r ? r / 2 : v), n.moveTo(e - d, i - o), n.lineTo(e + d, i + o), n.moveTo(e + h, i - s), n.lineTo(e - h, i + s);
|
|
1331
1331
|
break;
|
|
1332
1332
|
case "line":
|
|
1333
|
-
s = r ? r / 2 : Math.cos(
|
|
1333
|
+
s = r ? r / 2 : Math.cos(p) * v, o = Math.sin(p) * v, n.moveTo(e - s, i - o), n.lineTo(e + s, i + o);
|
|
1334
1334
|
break;
|
|
1335
1335
|
case "dash":
|
|
1336
|
-
n.moveTo(e, i), n.lineTo(e + Math.cos(
|
|
1336
|
+
n.moveTo(e, i), n.lineTo(e + Math.cos(p) * (r ? r / 2 : v), i + Math.sin(p) * v);
|
|
1337
1337
|
break;
|
|
1338
1338
|
case !1:
|
|
1339
1339
|
n.closePath();
|
|
@@ -2002,18 +2002,18 @@ function Cu(n, t, e) {
|
|
|
2002
2002
|
n
|
|
2003
2003
|
];
|
|
2004
2004
|
const { property: i, start: r, end: a } = e, s = t.length, { compare: o, between: l, normalize: c } = ku(i), { start: u, end: d, loop: h, style: f } = rg(n, t, e), g = [];
|
|
2005
|
-
let v = !1,
|
|
2006
|
-
const
|
|
2005
|
+
let v = !1, p = null, m, b, x;
|
|
2006
|
+
const y = () => l(r, x, m) && o(r, x) !== 0, w = () => o(a, m) === 0 || l(a, x, m), _ = () => v || y(), M = () => !v || w();
|
|
2007
2007
|
for (let T = u, D = u; T <= d; ++T)
|
|
2008
|
-
b = t[T % s], !b.skip && (
|
|
2009
|
-
start:
|
|
2008
|
+
b = t[T % s], !b.skip && (m = c(b[i]), m !== x && (v = l(m, r, a), p === null && _() && (p = o(m, r) === 0 ? T : D), p !== null && M() && (g.push(Ho({
|
|
2009
|
+
start: p,
|
|
2010
2010
|
end: T,
|
|
2011
2011
|
loop: h,
|
|
2012
2012
|
count: s,
|
|
2013
2013
|
style: f
|
|
2014
|
-
})),
|
|
2015
|
-
return
|
|
2016
|
-
start:
|
|
2014
|
+
})), p = null), D = T, x = m));
|
|
2015
|
+
return p !== null && g.push(Ho({
|
|
2016
|
+
start: p,
|
|
2017
2017
|
end: d,
|
|
2018
2018
|
loop: h,
|
|
2019
2019
|
count: s,
|
|
@@ -2081,7 +2081,7 @@ function $o(n, t, e, i) {
|
|
|
2081
2081
|
function lg(n, t, e, i) {
|
|
2082
2082
|
const r = n._chart.getContext(), a = Bo(n.options), { _datasetIndex: s, options: { spanGaps: o } } = n, l = e.length, c = [];
|
|
2083
2083
|
let u = a, d = t[0].start, h = d;
|
|
2084
|
-
function f(g, v,
|
|
2084
|
+
function f(g, v, p, m) {
|
|
2085
2085
|
const b = o ? -1 : 1;
|
|
2086
2086
|
if (g !== v) {
|
|
2087
2087
|
for (g += l; e[g % l].skip; )
|
|
@@ -2091,24 +2091,24 @@ function lg(n, t, e, i) {
|
|
|
2091
2091
|
g % l !== v % l && (c.push({
|
|
2092
2092
|
start: g % l,
|
|
2093
2093
|
end: v % l,
|
|
2094
|
-
loop:
|
|
2095
|
-
style:
|
|
2096
|
-
}), u =
|
|
2094
|
+
loop: p,
|
|
2095
|
+
style: m
|
|
2096
|
+
}), u = m, d = v % l);
|
|
2097
2097
|
}
|
|
2098
2098
|
}
|
|
2099
2099
|
for (const g of t) {
|
|
2100
2100
|
d = o ? d : g.start;
|
|
2101
|
-
let v = e[d % l],
|
|
2101
|
+
let v = e[d % l], p;
|
|
2102
2102
|
for (h = d + 1; h <= g.end; h++) {
|
|
2103
|
-
const
|
|
2104
|
-
|
|
2103
|
+
const m = e[h % l];
|
|
2104
|
+
p = Bo(i.setContext(Xe(r, {
|
|
2105
2105
|
type: "segment",
|
|
2106
2106
|
p0: v,
|
|
2107
|
-
p1:
|
|
2107
|
+
p1: m,
|
|
2108
2108
|
p0DataIndex: (h - 1) % l,
|
|
2109
2109
|
p1DataIndex: h % l,
|
|
2110
2110
|
datasetIndex: s
|
|
2111
|
-
}))), cg(
|
|
2111
|
+
}))), cg(p, u) && f(d, h - 1, g.loop, u), v = m, u = p;
|
|
2112
2112
|
}
|
|
2113
2113
|
d < h - 1 && f(d, h - 1, g.loop, u);
|
|
2114
2114
|
}
|
|
@@ -2475,10 +2475,10 @@ function Ko(n, t) {
|
|
|
2475
2475
|
const { chart: e, _cachedMeta: i } = n, r = e._stacks || (e._stacks = {}), { iScale: a, vScale: s, index: o } = i, l = a.axis, c = s.axis, u = bg(a, s, i), d = t.length;
|
|
2476
2476
|
let h;
|
|
2477
2477
|
for (let f = 0; f < d; ++f) {
|
|
2478
|
-
const g = t[f], { [l]: v, [c]:
|
|
2479
|
-
h =
|
|
2478
|
+
const g = t[f], { [l]: v, [c]: p } = g, m = g._stacks || (g._stacks = {});
|
|
2479
|
+
h = m[c] = xg(r, u, v), h[o] = p, h._top = Go(h, s, !0, i.type), h._bottom = Go(h, s, !1, i.type);
|
|
2480
2480
|
const b = h._visualValues || (h._visualValues = {});
|
|
2481
|
-
b[o] =
|
|
2481
|
+
b[o] = p;
|
|
2482
2482
|
}
|
|
2483
2483
|
}
|
|
2484
2484
|
function zr(n, t) {
|
|
@@ -3035,18 +3035,18 @@ class ni extends le {
|
|
|
3035
3035
|
const g = this.getParsed(f), v = a || U(g[o.axis]) ? {
|
|
3036
3036
|
base: l,
|
|
3037
3037
|
head: l
|
|
3038
|
-
} : this._calculateBarValuePixels(f),
|
|
3038
|
+
} : this._calculateBarValuePixels(f), p = this._calculateBarIndexPixels(f, u), m = (g._stacks || {})[o.axis], b = {
|
|
3039
3039
|
horizontal: c,
|
|
3040
3040
|
base: v.base,
|
|
3041
|
-
enableBorderRadius: !
|
|
3042
|
-
x: c ? v.head :
|
|
3043
|
-
y: c ?
|
|
3044
|
-
height: c ?
|
|
3045
|
-
width: c ? Math.abs(v.size) :
|
|
3041
|
+
enableBorderRadius: !m || $r(g._custom) || s === m._top || s === m._bottom,
|
|
3042
|
+
x: c ? v.head : p.center,
|
|
3043
|
+
y: c ? p.center : v.head,
|
|
3044
|
+
height: c ? p.size : Math.abs(v.size),
|
|
3045
|
+
width: c ? Math.abs(v.size) : p.size
|
|
3046
3046
|
};
|
|
3047
3047
|
h && (b.options = d || this.resolveDataElementOptions(f, t[f].active ? "active" : r));
|
|
3048
|
-
const
|
|
3049
|
-
Eg(b,
|
|
3048
|
+
const x = b.options || t[f].options;
|
|
3049
|
+
Eg(b, x, m, s), Rg(b, x, u.ratio), this.updateElement(t[f], f, b, r);
|
|
3050
3050
|
}
|
|
3051
3051
|
}
|
|
3052
3052
|
_getStacks(t, e) {
|
|
@@ -3088,20 +3088,20 @@ class ni extends le {
|
|
|
3088
3088
|
const { _cachedMeta: { vScale: e, _stacked: i, index: r }, options: { base: a, minBarLength: s } } = this, o = a || 0, l = this.getParsed(t), c = l._custom, u = $r(c);
|
|
3089
3089
|
let d = l[e.axis], h = 0, f = i ? this.applyStack(e, l, i) : d, g, v;
|
|
3090
3090
|
f !== d && (h = f - d, f = d), u && (d = c.barStart, f = c.barEnd - c.barStart, d !== 0 && pe(d) !== pe(c.barEnd) && (h = 0), h += d);
|
|
3091
|
-
const
|
|
3092
|
-
let
|
|
3093
|
-
if (this.chart.getDataVisibility(t) ? g = e.getPixelForValue(h + f) : g =
|
|
3094
|
-
v = Og(v, e, o) * s, d === o && (
|
|
3095
|
-
const b = e.getPixelForDecimal(0),
|
|
3096
|
-
|
|
3097
|
-
}
|
|
3098
|
-
if (
|
|
3091
|
+
const p = !U(a) && !u ? a : h;
|
|
3092
|
+
let m = e.getPixelForValue(p);
|
|
3093
|
+
if (this.chart.getDataVisibility(t) ? g = e.getPixelForValue(h + f) : g = m, v = g - m, Math.abs(v) < s) {
|
|
3094
|
+
v = Og(v, e, o) * s, d === o && (m -= v / 2);
|
|
3095
|
+
const b = e.getPixelForDecimal(0), x = e.getPixelForDecimal(1), y = Math.min(b, x), w = Math.max(b, x);
|
|
3096
|
+
m = Math.max(Math.min(m, w), y), g = m + v, i && !u && (l._stacks[e.axis]._visualValues[r] = e.getValueForPixel(g) - e.getValueForPixel(m));
|
|
3097
|
+
}
|
|
3098
|
+
if (m === e.getPixelForValue(o)) {
|
|
3099
3099
|
const b = pe(v) * e.getLineWidthForValue(o) / 2;
|
|
3100
|
-
|
|
3100
|
+
m += b, v -= b;
|
|
3101
3101
|
}
|
|
3102
3102
|
return {
|
|
3103
3103
|
size: v,
|
|
3104
|
-
base:
|
|
3104
|
+
base: m,
|
|
3105
3105
|
head: g,
|
|
3106
3106
|
center: g + v / 2
|
|
3107
3107
|
};
|
|
@@ -3208,8 +3208,8 @@ class Gi extends le {
|
|
|
3208
3208
|
updateElements(t, e, i, r) {
|
|
3209
3209
|
const a = r === "reset", { iScale: s, vScale: o } = this._cachedMeta, { sharedOptions: l, includeOptions: c } = this._getSharedOptions(e, r), u = s.axis, d = o.axis;
|
|
3210
3210
|
for (let h = e; h < e + i; h++) {
|
|
3211
|
-
const f = t[h], g = !a && this.getParsed(h), v = {},
|
|
3212
|
-
v.skip = isNaN(
|
|
3211
|
+
const f = t[h], g = !a && this.getParsed(h), v = {}, p = v[u] = a ? s.getPixelForDecimal(0.5) : s.getPixelForValue(g[u]), m = v[d] = a ? o.getBasePixel() : o.getPixelForValue(g[d]);
|
|
3212
|
+
v.skip = isNaN(p) || isNaN(m), c && (v.options = l || this.resolveDataElementOptions(h, f.active ? "active" : r), a && (v.options.radius = 0)), this.updateElement(f, h, v, r);
|
|
3213
3213
|
}
|
|
3214
3214
|
}
|
|
3215
3215
|
resolveDataElementOptions(t, e) {
|
|
@@ -3249,8 +3249,8 @@ S(Gi, "id", "bubble"), S(Gi, "defaults", {
|
|
|
3249
3249
|
function Lg(n, t, e) {
|
|
3250
3250
|
let i = 1, r = 1, a = 0, s = 0;
|
|
3251
3251
|
if (t < gt) {
|
|
3252
|
-
const o = n, l = o + t, c = Math.cos(o), u = Math.sin(o), d = Math.cos(l), h = Math.sin(l), f = (
|
|
3253
|
-
i = (v -
|
|
3252
|
+
const o = n, l = o + t, c = Math.cos(o), u = Math.sin(o), d = Math.cos(l), h = Math.sin(l), f = (x, y, w) => ci(x, o, l, !0) ? 1 : Math.max(y, y * e, w, w * e), g = (x, y, w) => ci(x, o, l, !0) ? -1 : Math.min(y, y * e, w, w * e), v = f(0, c, d), p = f(mt, u, h), m = g(X, c, d), b = g(X + mt, u, h);
|
|
3253
|
+
i = (v - m) / 2, r = (p - b) / 2, a = -(v + m) / 2, s = -(p + b) / 2;
|
|
3254
3254
|
}
|
|
3255
3255
|
return {
|
|
3256
3256
|
ratioX: i,
|
|
@@ -3299,29 +3299,29 @@ class Fe extends le {
|
|
|
3299
3299
|
};
|
|
3300
3300
|
}
|
|
3301
3301
|
update(t) {
|
|
3302
|
-
const e = this.chart, { chartArea: i } = e, r = this._cachedMeta, a = r.data, s = this.getMaxBorderWidth() + this.getMaxOffset(a) + this.options.spacing, o = Math.max((Math.min(i.width, i.height) - s) / 2, 0), l = Math.min(Xh(this.options.cutout, o), 1), c = this._getRingWeight(this.index), { circumference: u, rotation: d } = this._getRotationExtents(), { ratioX: h, ratioY: f, offsetX: g, offsetY: v } = Lg(d, u, l),
|
|
3303
|
-
this.offsetX = g *
|
|
3302
|
+
const e = this.chart, { chartArea: i } = e, r = this._cachedMeta, a = r.data, s = this.getMaxBorderWidth() + this.getMaxOffset(a) + this.options.spacing, o = Math.max((Math.min(i.width, i.height) - s) / 2, 0), l = Math.min(Xh(this.options.cutout, o), 1), c = this._getRingWeight(this.index), { circumference: u, rotation: d } = this._getRotationExtents(), { ratioX: h, ratioY: f, offsetX: g, offsetY: v } = Lg(d, u, l), p = (i.width - s) / h, m = (i.height - s) / f, b = Math.max(Math.min(p, m) / 2, 0), x = au(this.options.radius, b), y = Math.max(x * l, 0), w = (x - y) / this._getVisibleDatasetWeightTotal();
|
|
3303
|
+
this.offsetX = g * x, this.offsetY = v * x, r.total = this.calculateTotal(), this.outerRadius = x - w * this._getRingWeightOffset(this.index), this.innerRadius = Math.max(this.outerRadius - w * c, 0), this.updateElements(a, 0, a.length, t);
|
|
3304
3304
|
}
|
|
3305
3305
|
_circumference(t, e) {
|
|
3306
3306
|
const i = this.options, r = this._cachedMeta, a = this._getCircumference();
|
|
3307
3307
|
return e && i.animation.animateRotate || !this.chart.getDataVisibility(t) || r._parsed[t] === null || r.data[t].hidden ? 0 : this.calculateCircumference(r._parsed[t] * a / gt);
|
|
3308
3308
|
}
|
|
3309
3309
|
updateElements(t, e, i, r) {
|
|
3310
|
-
const a = r === "reset", s = this.chart, o = s.chartArea, c = s.options.animation, u = (o.left + o.right) / 2, d = (o.top + o.bottom) / 2, h = a && c.animateScale, f = h ? 0 : this.innerRadius, g = h ? 0 : this.outerRadius, { sharedOptions: v, includeOptions:
|
|
3311
|
-
let
|
|
3310
|
+
const a = r === "reset", s = this.chart, o = s.chartArea, c = s.options.animation, u = (o.left + o.right) / 2, d = (o.top + o.bottom) / 2, h = a && c.animateScale, f = h ? 0 : this.innerRadius, g = h ? 0 : this.outerRadius, { sharedOptions: v, includeOptions: p } = this._getSharedOptions(e, r);
|
|
3311
|
+
let m = this._getRotation(), b;
|
|
3312
3312
|
for (b = 0; b < e; ++b)
|
|
3313
|
-
|
|
3313
|
+
m += this._circumference(b, a);
|
|
3314
3314
|
for (b = e; b < e + i; ++b) {
|
|
3315
|
-
const
|
|
3315
|
+
const x = this._circumference(b, a), y = t[b], w = {
|
|
3316
3316
|
x: u + this.offsetX,
|
|
3317
3317
|
y: d + this.offsetY,
|
|
3318
|
-
startAngle:
|
|
3319
|
-
endAngle:
|
|
3320
|
-
circumference:
|
|
3318
|
+
startAngle: m,
|
|
3319
|
+
endAngle: m + x,
|
|
3320
|
+
circumference: x,
|
|
3321
3321
|
outerRadius: g,
|
|
3322
3322
|
innerRadius: f
|
|
3323
3323
|
};
|
|
3324
|
-
|
|
3324
|
+
p && (w.options = v || this.resolveDataElementOptions(b, y.active ? "active" : r)), m += x, this.updateElement(y, b, w, r);
|
|
3325
3325
|
}
|
|
3326
3326
|
}
|
|
3327
3327
|
calculateTotal() {
|
|
@@ -3462,16 +3462,16 @@ class ii extends le {
|
|
|
3462
3462
|
}, t), this.updateElements(r, o, l, t);
|
|
3463
3463
|
}
|
|
3464
3464
|
updateElements(t, e, i, r) {
|
|
3465
|
-
const a = r === "reset", { iScale: s, vScale: o, _stacked: l, _dataset: c } = this._cachedMeta, { sharedOptions: u, includeOptions: d } = this._getSharedOptions(e, r), h = s.axis, f = o.axis, { spanGaps: g, segment: v } = this.options,
|
|
3466
|
-
let
|
|
3467
|
-
for (let w = 0; w <
|
|
3468
|
-
const _ = t[w], M =
|
|
3465
|
+
const a = r === "reset", { iScale: s, vScale: o, _stacked: l, _dataset: c } = this._cachedMeta, { sharedOptions: u, includeOptions: d } = this._getSharedOptions(e, r), h = s.axis, f = o.axis, { spanGaps: g, segment: v } = this.options, p = je(g) ? g : Number.POSITIVE_INFINITY, m = this.chart._animationsDisabled || a || r === "none", b = e + i, x = t.length;
|
|
3466
|
+
let y = e > 0 && this.getParsed(e - 1);
|
|
3467
|
+
for (let w = 0; w < x; ++w) {
|
|
3468
|
+
const _ = t[w], M = m ? _ : {};
|
|
3469
3469
|
if (w < e || w >= b) {
|
|
3470
3470
|
M.skip = !0;
|
|
3471
3471
|
continue;
|
|
3472
3472
|
}
|
|
3473
3473
|
const T = this.getParsed(w), D = U(T[f]), O = M[h] = s.getPixelForValue(T[h], w), R = M[f] = a || D ? o.getBasePixel() : o.getPixelForValue(l ? this.applyStack(o, T, l) : T[f], w);
|
|
3474
|
-
M.skip = isNaN(O) || isNaN(R) || D, M.stop = w > 0 && Math.abs(T[h] -
|
|
3474
|
+
M.skip = isNaN(O) || isNaN(R) || D, M.stop = w > 0 && Math.abs(T[h] - y[h]) > p, v && (M.parsed = T, M.raw = c.data[w]), d && (M.options = u || this.resolveDataElementOptions(w, _.active ? "active" : r)), m || this.updateElement(_, w, M, r), y = T;
|
|
3475
3475
|
}
|
|
3476
3476
|
}
|
|
3477
3477
|
getMaxOverflow() {
|
|
@@ -3540,19 +3540,19 @@ class ri extends le {
|
|
|
3540
3540
|
for (g = 0; g < e; ++g)
|
|
3541
3541
|
f += this._computeAngle(g, r, v);
|
|
3542
3542
|
for (g = e; g < e + i; g++) {
|
|
3543
|
-
const
|
|
3544
|
-
let
|
|
3545
|
-
f = b, a && (l.animateScale && (
|
|
3546
|
-
const
|
|
3543
|
+
const p = t[g];
|
|
3544
|
+
let m = f, b = f + this._computeAngle(g, r, v), x = s.getDataVisibility(g) ? c.getDistanceFromCenterForValue(this.getParsed(g).r) : 0;
|
|
3545
|
+
f = b, a && (l.animateScale && (x = 0), l.animateRotate && (m = b = h));
|
|
3546
|
+
const y = {
|
|
3547
3547
|
x: u,
|
|
3548
3548
|
y: d,
|
|
3549
3549
|
innerRadius: 0,
|
|
3550
|
-
outerRadius:
|
|
3551
|
-
startAngle:
|
|
3550
|
+
outerRadius: x,
|
|
3551
|
+
startAngle: m,
|
|
3552
3552
|
endAngle: b,
|
|
3553
|
-
options: this.resolveDataElementOptions(g,
|
|
3553
|
+
options: this.resolveDataElementOptions(g, p.active ? "active" : r)
|
|
3554
3554
|
};
|
|
3555
|
-
this.updateElement(
|
|
3555
|
+
this.updateElement(p, g, y, r);
|
|
3556
3556
|
}
|
|
3557
3557
|
}
|
|
3558
3558
|
countVisibleElements() {
|
|
@@ -3729,11 +3729,11 @@ class Zi extends le {
|
|
|
3729
3729
|
!this.datasetElementType && t && (this.datasetElementType = this.chart.registry.getElement("line")), super.addElements();
|
|
3730
3730
|
}
|
|
3731
3731
|
updateElements(t, e, i, r) {
|
|
3732
|
-
const a = r === "reset", { iScale: s, vScale: o, _stacked: l, _dataset: c } = this._cachedMeta, u = this.resolveDataElementOptions(e, r), d = this.getSharedOptions(u), h = this.includeOptions(r, d), f = s.axis, g = o.axis, { spanGaps: v, segment:
|
|
3733
|
-
let
|
|
3734
|
-
for (let
|
|
3735
|
-
const w = t[
|
|
3736
|
-
M.skip = isNaN(D) || isNaN(O) || T, M.stop =
|
|
3732
|
+
const a = r === "reset", { iScale: s, vScale: o, _stacked: l, _dataset: c } = this._cachedMeta, u = this.resolveDataElementOptions(e, r), d = this.getSharedOptions(u), h = this.includeOptions(r, d), f = s.axis, g = o.axis, { spanGaps: v, segment: p } = this.options, m = je(v) ? v : Number.POSITIVE_INFINITY, b = this.chart._animationsDisabled || a || r === "none";
|
|
3733
|
+
let x = e > 0 && this.getParsed(e - 1);
|
|
3734
|
+
for (let y = e; y < e + i; ++y) {
|
|
3735
|
+
const w = t[y], _ = this.getParsed(y), M = b ? w : {}, T = U(_[g]), D = M[f] = s.getPixelForValue(_[f], y), O = M[g] = a || T ? o.getBasePixel() : o.getPixelForValue(l ? this.applyStack(o, _, l) : _[g], y);
|
|
3736
|
+
M.skip = isNaN(D) || isNaN(O) || T, M.stop = y > 0 && Math.abs(_[f] - x[f]) > m, p && (M.parsed = _, M.raw = c.data[y]), h && (M.options = d || this.resolveDataElementOptions(y, w.active ? "active" : r)), b || this.updateElement(w, y, M, r), x = _;
|
|
3737
3737
|
}
|
|
3738
3738
|
this.updateSharedOptions(d, r, u);
|
|
3739
3739
|
}
|
|
@@ -3909,14 +3909,14 @@ function Wg(n, t, e, i, r, a) {
|
|
|
3909
3909
|
const g = u.getCenterPoint(r);
|
|
3910
3910
|
if (!(!!a || n.isPointInArea(g)) && !f)
|
|
3911
3911
|
return;
|
|
3912
|
-
const
|
|
3913
|
-
|
|
3912
|
+
const p = o(t, g);
|
|
3913
|
+
p < l ? (s = [
|
|
3914
3914
|
{
|
|
3915
3915
|
element: u,
|
|
3916
3916
|
datasetIndex: d,
|
|
3917
3917
|
index: h
|
|
3918
3918
|
}
|
|
3919
|
-
], l =
|
|
3919
|
+
], l = p) : p === l && s.push({
|
|
3920
3920
|
element: u,
|
|
3921
3921
|
datasetIndex: d,
|
|
3922
3922
|
index: h
|
|
@@ -4169,7 +4169,7 @@ var $t = {
|
|
|
4169
4169
|
ct(n.boxes, (v) => {
|
|
4170
4170
|
typeof v.beforeLayout == "function" && v.beforeLayout();
|
|
4171
4171
|
});
|
|
4172
|
-
const u = l.reduce((v,
|
|
4172
|
+
const u = l.reduce((v, p) => p.box.options && p.box.options.display === !1 ? v : v + 1, 0) || 1, d = Object.freeze({
|
|
4173
4173
|
outerWidth: t,
|
|
4174
4174
|
outerHeight: e,
|
|
4175
4175
|
padding: r,
|
|
@@ -4194,8 +4194,8 @@ var $t = {
|
|
|
4194
4194
|
height: f.h,
|
|
4195
4195
|
width: f.w
|
|
4196
4196
|
}, ct(o.chartArea, (v) => {
|
|
4197
|
-
const
|
|
4198
|
-
Object.assign(
|
|
4197
|
+
const p = v.box;
|
|
4198
|
+
Object.assign(p, n.chartArea), p.update(f.w, f.h, {
|
|
4199
4199
|
left: 0,
|
|
4200
4200
|
top: 0,
|
|
4201
4201
|
right: 0,
|
|
@@ -4558,20 +4558,20 @@ function bp(n, t, e) {
|
|
|
4558
4558
|
function yp(n, t, e, i) {
|
|
4559
4559
|
const { top: r, left: a, bottom: s, right: o, chart: l } = n, { chartArea: c, scales: u } = l;
|
|
4560
4560
|
let d = 0, h, f, g;
|
|
4561
|
-
const v = s - r,
|
|
4561
|
+
const v = s - r, p = o - a;
|
|
4562
4562
|
if (n.isHorizontal()) {
|
|
4563
4563
|
if (f = Wt(i, a, o), j(e)) {
|
|
4564
|
-
const
|
|
4565
|
-
g = u[
|
|
4564
|
+
const m = Object.keys(e)[0], b = e[m];
|
|
4565
|
+
g = u[m].getPixelForValue(b) + v - t;
|
|
4566
4566
|
} else
|
|
4567
4567
|
e === "center" ? g = (c.bottom + c.top) / 2 + v - t : g = ol(n, e, t);
|
|
4568
4568
|
h = o - a;
|
|
4569
4569
|
} else {
|
|
4570
4570
|
if (j(e)) {
|
|
4571
|
-
const
|
|
4572
|
-
f = u[
|
|
4571
|
+
const m = Object.keys(e)[0], b = e[m];
|
|
4572
|
+
f = u[m].getPixelForValue(b) - p + t;
|
|
4573
4573
|
} else
|
|
4574
|
-
e === "center" ? f = (c.left + c.right) / 2 -
|
|
4574
|
+
e === "center" ? f = (c.left + c.right) / 2 - p + t : f = ol(n, e, t);
|
|
4575
4575
|
g = Wt(i, s, r), d = e === "left" ? -mt : mt;
|
|
4576
4576
|
}
|
|
4577
4577
|
return {
|
|
@@ -4756,15 +4756,15 @@ class cn extends Ft {
|
|
|
4756
4756
|
if (s) {
|
|
4757
4757
|
const l = ul(r, e.options.font);
|
|
4758
4758
|
if (o ? (t.width = this.maxWidth, t.height = Fn(a) + l) : (t.height = this.maxHeight, t.width = Fn(a) + l), i.display && this.ticks.length) {
|
|
4759
|
-
const { first: c, last: u, widest: d, highest: h } = this._getLabelSizes(), f = i.padding * 2, g = At(this.labelRotation), v = Math.cos(g),
|
|
4759
|
+
const { first: c, last: u, widest: d, highest: h } = this._getLabelSizes(), f = i.padding * 2, g = At(this.labelRotation), v = Math.cos(g), p = Math.sin(g);
|
|
4760
4760
|
if (o) {
|
|
4761
|
-
const
|
|
4762
|
-
t.height = Math.min(this.maxHeight, t.height +
|
|
4761
|
+
const m = i.mirror ? 0 : p * d.width + v * h.height;
|
|
4762
|
+
t.height = Math.min(this.maxHeight, t.height + m + f);
|
|
4763
4763
|
} else {
|
|
4764
|
-
const
|
|
4765
|
-
t.width = Math.min(this.maxWidth, t.width +
|
|
4764
|
+
const m = i.mirror ? 0 : v * d.width + p * h.height;
|
|
4765
|
+
t.width = Math.min(this.maxWidth, t.width + m + f);
|
|
4766
4766
|
}
|
|
4767
|
-
this._calculatePadding(c, u,
|
|
4767
|
+
this._calculatePadding(c, u, p, v);
|
|
4768
4768
|
}
|
|
4769
4769
|
}
|
|
4770
4770
|
this._handleMargins(), o ? (this.width = this._length = e.width - this._margins.left - this._margins.right, this.height = t.height) : (this.width = t.width, this.height = this._length = e.height - this._margins.top - this._margins.bottom);
|
|
@@ -4813,17 +4813,17 @@ class cn extends Ft {
|
|
|
4813
4813
|
}
|
|
4814
4814
|
_computeLabelSizes(t, e, i) {
|
|
4815
4815
|
const { ctx: r, _longestTextCache: a } = this, s = [], o = [], l = Math.floor(e / ll(e, i));
|
|
4816
|
-
let c = 0, u = 0, d, h, f, g, v,
|
|
4816
|
+
let c = 0, u = 0, d, h, f, g, v, p, m, b, x, y, w;
|
|
4817
4817
|
for (d = 0; d < e; d += l) {
|
|
4818
|
-
if (g = t[d].label, v = this._resolveTickFontOptions(d), r.font =
|
|
4818
|
+
if (g = t[d].label, v = this._resolveTickFontOptions(d), r.font = p = v.string, m = a[p] = a[p] || {
|
|
4819
4819
|
data: {},
|
|
4820
4820
|
gc: []
|
|
4821
|
-
}, b = v.lineHeight,
|
|
4822
|
-
|
|
4821
|
+
}, b = v.lineHeight, x = y = 0, !U(g) && !nt(g))
|
|
4822
|
+
x = cr(r, m.data, m.gc, x, g), y = b;
|
|
4823
4823
|
else if (nt(g))
|
|
4824
4824
|
for (h = 0, f = g.length; h < f; ++h)
|
|
4825
|
-
w = g[h], !U(w) && !nt(w) && (
|
|
4826
|
-
s.push(
|
|
4825
|
+
w = g[h], !U(w) && !nt(w) && (x = cr(r, m.data, m.gc, x, w), y += b);
|
|
4826
|
+
s.push(x), o.push(y), c = Math.max(x, c), u = Math.max(y, u);
|
|
4827
4827
|
}
|
|
4828
4828
|
pp(a, e);
|
|
4829
4829
|
const _ = s.indexOf(c), M = o.indexOf(u), T = (D) => ({
|
|
@@ -4884,39 +4884,39 @@ class cn extends Ft {
|
|
|
4884
4884
|
return t !== "auto" ? !!t : this.getMatchingVisibleMetas().length > 0;
|
|
4885
4885
|
}
|
|
4886
4886
|
_computeGridLineItems(t) {
|
|
4887
|
-
const e = this.axis, i = this.chart, r = this.options, { grid: a, position: s, border: o } = r, l = a.offset, c = this.isHorizontal(), d = this.ticks.length + (l ? 1 : 0), h = Fn(a), f = [], g = o.setContext(this.getContext()), v = g.display ? g.width : 0,
|
|
4887
|
+
const e = this.axis, i = this.chart, r = this.options, { grid: a, position: s, border: o } = r, l = a.offset, c = this.isHorizontal(), d = this.ticks.length + (l ? 1 : 0), h = Fn(a), f = [], g = o.setContext(this.getContext()), v = g.display ? g.width : 0, p = v / 2, m = function(z) {
|
|
4888
4888
|
return Ke(i, z, v);
|
|
4889
4889
|
};
|
|
4890
|
-
let b,
|
|
4890
|
+
let b, x, y, w, _, M, T, D, O, R, P, Q;
|
|
4891
4891
|
if (s === "top")
|
|
4892
|
-
b =
|
|
4892
|
+
b = m(this.bottom), M = this.bottom - h, D = b - p, R = m(t.top) + p, Q = t.bottom;
|
|
4893
4893
|
else if (s === "bottom")
|
|
4894
|
-
b =
|
|
4894
|
+
b = m(this.top), R = t.top, Q = m(t.bottom) - p, M = b + p, D = this.top + h;
|
|
4895
4895
|
else if (s === "left")
|
|
4896
|
-
b =
|
|
4896
|
+
b = m(this.right), _ = this.right - h, T = b - p, O = m(t.left) + p, P = t.right;
|
|
4897
4897
|
else if (s === "right")
|
|
4898
|
-
b =
|
|
4898
|
+
b = m(this.left), O = t.left, P = m(t.right) - p, _ = b + p, T = this.left + h;
|
|
4899
4899
|
else if (e === "x") {
|
|
4900
4900
|
if (s === "center")
|
|
4901
|
-
b =
|
|
4901
|
+
b = m((t.top + t.bottom) / 2 + 0.5);
|
|
4902
4902
|
else if (j(s)) {
|
|
4903
4903
|
const z = Object.keys(s)[0], G = s[z];
|
|
4904
|
-
b =
|
|
4904
|
+
b = m(this.chart.scales[z].getPixelForValue(G));
|
|
4905
4905
|
}
|
|
4906
|
-
R = t.top, Q = t.bottom, M = b +
|
|
4906
|
+
R = t.top, Q = t.bottom, M = b + p, D = M + h;
|
|
4907
4907
|
} else if (e === "y") {
|
|
4908
4908
|
if (s === "center")
|
|
4909
|
-
b =
|
|
4909
|
+
b = m((t.left + t.right) / 2);
|
|
4910
4910
|
else if (j(s)) {
|
|
4911
4911
|
const z = Object.keys(s)[0], G = s[z];
|
|
4912
|
-
b =
|
|
4912
|
+
b = m(this.chart.scales[z].getPixelForValue(G));
|
|
4913
4913
|
}
|
|
4914
|
-
_ = b -
|
|
4914
|
+
_ = b - p, T = _ - h, O = t.left, P = t.right;
|
|
4915
4915
|
}
|
|
4916
4916
|
const _t = W(r.ticks.maxTicksLimit, d), N = Math.max(1, Math.ceil(d / _t));
|
|
4917
|
-
for (
|
|
4918
|
-
const z = this.getContext(
|
|
4919
|
-
|
|
4917
|
+
for (x = 0; x < d; x += N) {
|
|
4918
|
+
const z = this.getContext(x), G = a.setContext(z), Lt = o.setContext(z), k = G.lineWidth, L = G.color, F = Lt.dash || [], B = Lt.dashOffset, V = G.tickWidth, q = G.tickColor, yt = G.tickBorderDash || [], pt = G.tickBorderDashOffset;
|
|
4919
|
+
y = gp(this, x, l), y !== void 0 && (w = Ke(i, y, k), c ? _ = T = O = P = w : M = D = R = Q = w, f.push({
|
|
4920
4920
|
tx1: _,
|
|
4921
4921
|
ty1: M,
|
|
4922
4922
|
tx2: T,
|
|
@@ -4938,8 +4938,8 @@ class cn extends Ft {
|
|
|
4938
4938
|
return this._ticksLength = d, this._borderValue = b, f;
|
|
4939
4939
|
}
|
|
4940
4940
|
_computeLabelItems(t) {
|
|
4941
|
-
const e = this.axis, i = this.options, { position: r, ticks: a } = i, s = this.isHorizontal(), o = this.ticks, { align: l, crossAlign: c, padding: u, mirror: d } = a, h = Fn(i.grid), f = h + u, g = d ? -u : f, v = -At(this.labelRotation),
|
|
4942
|
-
let
|
|
4941
|
+
const e = this.axis, i = this.options, { position: r, ticks: a } = i, s = this.isHorizontal(), o = this.ticks, { align: l, crossAlign: c, padding: u, mirror: d } = a, h = Fn(i.grid), f = h + u, g = d ? -u : f, v = -At(this.labelRotation), p = [];
|
|
4942
|
+
let m, b, x, y, w, _, M, T, D, O, R, P, Q = "middle";
|
|
4943
4943
|
if (r === "top")
|
|
4944
4944
|
_ = this.bottom - g, M = this._getXAxisLabelAlignment();
|
|
4945
4945
|
else if (r === "bottom")
|
|
@@ -4969,16 +4969,16 @@ class cn extends Ft {
|
|
|
4969
4969
|
}
|
|
4970
4970
|
e === "y" && (l === "start" ? Q = "top" : l === "end" && (Q = "bottom"));
|
|
4971
4971
|
const _t = this._getLabelSizes();
|
|
4972
|
-
for (
|
|
4973
|
-
|
|
4974
|
-
const N = a.setContext(this.getContext(
|
|
4975
|
-
T = this.getPixelForTick(
|
|
4972
|
+
for (m = 0, b = o.length; m < b; ++m) {
|
|
4973
|
+
x = o[m], y = x.label;
|
|
4974
|
+
const N = a.setContext(this.getContext(m));
|
|
4975
|
+
T = this.getPixelForTick(m) + a.labelOffset, D = this._resolveTickFontOptions(m), O = D.lineHeight, R = nt(y) ? y.length : 1;
|
|
4976
4976
|
const z = R / 2, G = N.color, Lt = N.textStrokeColor, k = N.textStrokeWidth;
|
|
4977
4977
|
let L = M;
|
|
4978
|
-
s ? (w = T, M === "inner" && (
|
|
4978
|
+
s ? (w = T, M === "inner" && (m === b - 1 ? L = this.options.reverse ? "left" : "right" : m === 0 ? L = this.options.reverse ? "right" : "left" : L = "center"), r === "top" ? c === "near" || v !== 0 ? P = -R * O + O / 2 : c === "center" ? P = -_t.highest.height / 2 - z * O + O : P = -_t.highest.height + O / 2 : c === "near" || v !== 0 ? P = O / 2 : c === "center" ? P = _t.highest.height / 2 - z * O : P = _t.highest.height - R * O, d && (P *= -1), v !== 0 && !N.showLabelBackdrop && (w += O / 2 * Math.sin(v))) : (_ = T, P = (1 - R) * O / 2);
|
|
4979
4979
|
let F;
|
|
4980
4980
|
if (N.showLabelBackdrop) {
|
|
4981
|
-
const B = Rt(N.backdropPadding), V = _t.heights[
|
|
4981
|
+
const B = Rt(N.backdropPadding), V = _t.heights[m], q = _t.widths[m];
|
|
4982
4982
|
let yt = P - B.top, pt = 0 - B.left;
|
|
4983
4983
|
switch (Q) {
|
|
4984
4984
|
case "middle":
|
|
@@ -5004,8 +5004,8 @@ class cn extends Ft {
|
|
|
5004
5004
|
color: N.backdropColor
|
|
5005
5005
|
};
|
|
5006
5006
|
}
|
|
5007
|
-
|
|
5008
|
-
label:
|
|
5007
|
+
p.push({
|
|
5008
|
+
label: y,
|
|
5009
5009
|
font: D,
|
|
5010
5010
|
textOffset: P,
|
|
5011
5011
|
options: {
|
|
@@ -5023,7 +5023,7 @@ class cn extends Ft {
|
|
|
5023
5023
|
}
|
|
5024
5024
|
});
|
|
5025
5025
|
}
|
|
5026
|
-
return
|
|
5026
|
+
return p;
|
|
5027
5027
|
}
|
|
5028
5028
|
_getXAxisLabelAlignment() {
|
|
5029
5029
|
const { position: t, ticks: e } = this.options;
|
|
@@ -6227,27 +6227,27 @@ function hr(n, t, e, i, r, a) {
|
|
|
6227
6227
|
const N = u > 0 ? u - i : 0, z = d > 0 ? d - i : 0, G = (N + z) / 2, Lt = G !== 0 ? g * G / (G + i) : g;
|
|
6228
6228
|
f = (g - Lt) / 2;
|
|
6229
6229
|
}
|
|
6230
|
-
const v = Math.max(1e-3, g * d - e / X) / d,
|
|
6230
|
+
const v = Math.max(1e-3, g * d - e / X) / d, p = (g - v) / 2, m = l + p + f, b = r - p - f, { outerStart: x, outerEnd: y, innerStart: w, innerEnd: _ } = Vp(t, h, d, b - m), M = d - x, T = d - y, D = m + x / M, O = b - y / T, R = h + w, P = h + _, Q = m + w / R, _t = b - _ / P;
|
|
6231
6231
|
if (n.beginPath(), a) {
|
|
6232
6232
|
const N = (D + O) / 2;
|
|
6233
|
-
if (n.arc(s, o, d, D, N), n.arc(s, o, d, N, O),
|
|
6233
|
+
if (n.arc(s, o, d, D, N), n.arc(s, o, d, N, O), y > 0) {
|
|
6234
6234
|
const k = gn(T, O, s, o);
|
|
6235
|
-
n.arc(k.x, k.y,
|
|
6235
|
+
n.arc(k.x, k.y, y, O, b + mt);
|
|
6236
6236
|
}
|
|
6237
6237
|
const z = gn(P, b, s, o);
|
|
6238
6238
|
if (n.lineTo(z.x, z.y), _ > 0) {
|
|
6239
6239
|
const k = gn(P, _t, s, o);
|
|
6240
6240
|
n.arc(k.x, k.y, _, b + mt, _t + Math.PI);
|
|
6241
6241
|
}
|
|
6242
|
-
const G = (b - _ / h + (
|
|
6243
|
-
if (n.arc(s, o, h, b - _ / h, G, !0), n.arc(s, o, h, G,
|
|
6242
|
+
const G = (b - _ / h + (m + w / h)) / 2;
|
|
6243
|
+
if (n.arc(s, o, h, b - _ / h, G, !0), n.arc(s, o, h, G, m + w / h, !0), w > 0) {
|
|
6244
6244
|
const k = gn(R, Q, s, o);
|
|
6245
|
-
n.arc(k.x, k.y, w, Q + Math.PI,
|
|
6245
|
+
n.arc(k.x, k.y, w, Q + Math.PI, m - mt);
|
|
6246
6246
|
}
|
|
6247
|
-
const Lt = gn(M,
|
|
6248
|
-
if (n.lineTo(Lt.x, Lt.y),
|
|
6247
|
+
const Lt = gn(M, m, s, o);
|
|
6248
|
+
if (n.lineTo(Lt.x, Lt.y), x > 0) {
|
|
6249
6249
|
const k = gn(M, D, s, o);
|
|
6250
|
-
n.arc(k.x, k.y,
|
|
6250
|
+
n.arc(k.x, k.y, x, m - mt, D);
|
|
6251
6251
|
}
|
|
6252
6252
|
} else {
|
|
6253
6253
|
n.moveTo(s, o);
|
|
@@ -6308,8 +6308,8 @@ class qn extends Ft {
|
|
|
6308
6308
|
"innerRadius",
|
|
6309
6309
|
"outerRadius",
|
|
6310
6310
|
"circumference"
|
|
6311
|
-
], r), f = (this.options.spacing + this.options.borderWidth) / 2, v = W(h, c - l) >= gt || ci(s, l, c),
|
|
6312
|
-
return v &&
|
|
6311
|
+
], r), f = (this.options.spacing + this.options.borderWidth) / 2, v = W(h, c - l) >= gt || ci(s, l, c), p = Me(o, u + f, d + f);
|
|
6312
|
+
return v && p;
|
|
6313
6313
|
}
|
|
6314
6314
|
getCenterPoint(e) {
|
|
6315
6315
|
const { x: i, y: r, startAngle: a, endAngle: s, innerRadius: o, outerRadius: l } = this.getProps([
|
|
@@ -6384,17 +6384,17 @@ function Zp(n, t, e, i) {
|
|
|
6384
6384
|
}
|
|
6385
6385
|
function Qp(n, t, e, i) {
|
|
6386
6386
|
const r = t.points, { count: a, start: s, ilen: o } = $u(r, e, i), { move: l = !0, reverse: c } = i || {};
|
|
6387
|
-
let u = 0, d = 0, h, f, g, v,
|
|
6388
|
-
const b = (
|
|
6389
|
-
v !==
|
|
6387
|
+
let u = 0, d = 0, h, f, g, v, p, m;
|
|
6388
|
+
const b = (y) => (s + (c ? o - y : y)) % a, x = () => {
|
|
6389
|
+
v !== p && (n.lineTo(u, p), n.lineTo(u, v), n.lineTo(u, m));
|
|
6390
6390
|
};
|
|
6391
6391
|
for (l && (f = r[b(0)], n.moveTo(f.x, f.y)), h = 0; h <= o; ++h) {
|
|
6392
6392
|
if (f = r[b(h)], f.skip)
|
|
6393
6393
|
continue;
|
|
6394
|
-
const
|
|
6395
|
-
_ === g ? (w < v ? v = w : w >
|
|
6394
|
+
const y = f.x, w = f.y, _ = y | 0;
|
|
6395
|
+
_ === g ? (w < v ? v = w : w > p && (p = w), u = (d * u + y) / ++d) : (x(), n.lineTo(y, w), g = _, d = 0, v = p = w), m = w;
|
|
6396
6396
|
}
|
|
6397
|
-
|
|
6397
|
+
x();
|
|
6398
6398
|
}
|
|
6399
6399
|
function xa(n) {
|
|
6400
6400
|
const t = n.options, e = t.borderDash && t.borderDash.length;
|
|
@@ -6463,8 +6463,8 @@ class Ye extends Ft {
|
|
|
6463
6463
|
o.push(f);
|
|
6464
6464
|
continue;
|
|
6465
6465
|
}
|
|
6466
|
-
const v = Math.abs((r - f[e]) / (g[e] - f[e])),
|
|
6467
|
-
|
|
6466
|
+
const v = Math.abs((r - f[e]) / (g[e] - f[e])), p = l(f, g, v, i.stepped);
|
|
6467
|
+
p[e] = t[e], o.push(p);
|
|
6468
6468
|
}
|
|
6469
6469
|
return o.length === 1 ? o[0] : o;
|
|
6470
6470
|
}
|
|
@@ -6777,23 +6777,23 @@ function mm(n, t, e, i, r) {
|
|
|
6777
6777
|
const c = t + e - 1;
|
|
6778
6778
|
let u = t, d, h, f, g, v;
|
|
6779
6779
|
for (s[l++] = n[u], d = 0; d < a - 2; d++) {
|
|
6780
|
-
let
|
|
6781
|
-
const
|
|
6782
|
-
for (b =
|
|
6783
|
-
|
|
6784
|
-
|
|
6780
|
+
let p = 0, m = 0, b;
|
|
6781
|
+
const x = Math.floor((d + 1) * o) + 1 + t, y = Math.min(Math.floor((d + 2) * o) + 1, e) + t, w = y - x;
|
|
6782
|
+
for (b = x; b < y; b++)
|
|
6783
|
+
p += n[b].x, m += n[b].y;
|
|
6784
|
+
p /= w, m /= w;
|
|
6785
6785
|
const _ = Math.floor(d * o) + 1 + t, M = Math.min(Math.floor((d + 1) * o) + 1, e) + t, { x: T, y: D } = n[u];
|
|
6786
6786
|
for (f = g = -1, b = _; b < M; b++)
|
|
6787
|
-
g = 0.5 * Math.abs((T -
|
|
6787
|
+
g = 0.5 * Math.abs((T - p) * (n[b].y - D) - (T - n[b].x) * (m - D)), g > f && (f = g, h = n[b], v = b);
|
|
6788
6788
|
s[l++] = h, u = v;
|
|
6789
6789
|
}
|
|
6790
6790
|
return s[l++] = n[c], s;
|
|
6791
6791
|
}
|
|
6792
6792
|
function vm(n, t, e, i) {
|
|
6793
6793
|
let r = 0, a = 0, s, o, l, c, u, d, h, f, g, v;
|
|
6794
|
-
const
|
|
6794
|
+
const p = [], m = t + e - 1, b = n[t].x, y = n[m].x - b;
|
|
6795
6795
|
for (s = t; s < t + e; ++s) {
|
|
6796
|
-
o = n[s], l = (o.x - b) /
|
|
6796
|
+
o = n[s], l = (o.x - b) / y * i, c = o.y;
|
|
6797
6797
|
const w = l | 0;
|
|
6798
6798
|
if (w === u)
|
|
6799
6799
|
c < g ? (g = c, d = s) : c > v && (v = c, h = s), r = (a * r + o.x) / ++a;
|
|
@@ -6801,18 +6801,18 @@ function vm(n, t, e, i) {
|
|
|
6801
6801
|
const _ = s - 1;
|
|
6802
6802
|
if (!U(d) && !U(h)) {
|
|
6803
6803
|
const M = Math.min(d, h), T = Math.max(d, h);
|
|
6804
|
-
M !== f && M !== _ &&
|
|
6804
|
+
M !== f && M !== _ && p.push({
|
|
6805
6805
|
...n[M],
|
|
6806
6806
|
x: r
|
|
6807
|
-
}), T !== f && T !== _ &&
|
|
6807
|
+
}), T !== f && T !== _ && p.push({
|
|
6808
6808
|
...n[T],
|
|
6809
6809
|
x: r
|
|
6810
6810
|
});
|
|
6811
6811
|
}
|
|
6812
|
-
s > 0 && _ !== f &&
|
|
6812
|
+
s > 0 && _ !== f && p.push(n[_]), p.push(o), u = w, a = 0, g = v = c, d = h = f = s;
|
|
6813
6813
|
}
|
|
6814
6814
|
}
|
|
6815
|
-
return
|
|
6815
|
+
return p;
|
|
6816
6816
|
}
|
|
6817
6817
|
function qu(n) {
|
|
6818
6818
|
if (n._decimated) {
|
|
@@ -7201,11 +7201,11 @@ function kl(n, t) {
|
|
|
7201
7201
|
let v;
|
|
7202
7202
|
if (f) {
|
|
7203
7203
|
g ? n.closePath() : Cl(n, i, d, r);
|
|
7204
|
-
const
|
|
7204
|
+
const p = !!i.pathSegment(n, c, {
|
|
7205
7205
|
move: g,
|
|
7206
7206
|
reverse: !0
|
|
7207
7207
|
});
|
|
7208
|
-
v = g &&
|
|
7208
|
+
v = g && p, v || Cl(n, i, u, r);
|
|
7209
7209
|
}
|
|
7210
7210
|
n.closePath(), n.fill(v ? "evenodd" : "nonzero"), n.restore();
|
|
7211
7211
|
}
|
|
@@ -7304,31 +7304,31 @@ class Pl extends Ft {
|
|
|
7304
7304
|
a.textAlign = "left", a.textBaseline = "middle";
|
|
7305
7305
|
let h = -1, f = -u;
|
|
7306
7306
|
return this.legendItems.forEach((g, v) => {
|
|
7307
|
-
const
|
|
7308
|
-
(v === 0 || c[c.length - 1] +
|
|
7307
|
+
const p = i + e / 2 + a.measureText(g.text).width;
|
|
7308
|
+
(v === 0 || c[c.length - 1] + p + 2 * o > s) && (d += u, c[c.length - (v > 0 ? 0 : 1)] = 0, f += u, h++), l[v] = {
|
|
7309
7309
|
left: 0,
|
|
7310
7310
|
top: f,
|
|
7311
7311
|
row: h,
|
|
7312
|
-
width:
|
|
7312
|
+
width: p,
|
|
7313
7313
|
height: r
|
|
7314
|
-
}, c[c.length - 1] +=
|
|
7314
|
+
}, c[c.length - 1] += p + o;
|
|
7315
7315
|
}), d;
|
|
7316
7316
|
}
|
|
7317
7317
|
_fitCols(t, e, i, r) {
|
|
7318
7318
|
const { ctx: a, maxHeight: s, options: { labels: { padding: o } } } = this, l = this.legendHitBoxes = [], c = this.columnSizes = [], u = s - t;
|
|
7319
7319
|
let d = o, h = 0, f = 0, g = 0, v = 0;
|
|
7320
|
-
return this.legendItems.forEach((
|
|
7321
|
-
const { itemWidth: b, itemHeight:
|
|
7322
|
-
|
|
7320
|
+
return this.legendItems.forEach((p, m) => {
|
|
7321
|
+
const { itemWidth: b, itemHeight: x } = zm(i, e, a, p, r);
|
|
7322
|
+
m > 0 && f + x + 2 * o > u && (d += h + o, c.push({
|
|
7323
7323
|
width: h,
|
|
7324
7324
|
height: f
|
|
7325
|
-
}), g += h + o, v++, h = f = 0), l[
|
|
7325
|
+
}), g += h + o, v++, h = f = 0), l[m] = {
|
|
7326
7326
|
left: g,
|
|
7327
7327
|
top: f,
|
|
7328
7328
|
col: v,
|
|
7329
7329
|
width: b,
|
|
7330
|
-
height:
|
|
7331
|
-
}, h = Math.max(h, b), f +=
|
|
7330
|
+
height: x
|
|
7331
|
+
}, h = Math.max(h, b), f += x + o;
|
|
7332
7332
|
}), d += h, c.push({
|
|
7333
7333
|
width: h,
|
|
7334
7334
|
height: f
|
|
@@ -7361,7 +7361,7 @@ class Pl extends Ft {
|
|
|
7361
7361
|
const { options: t, columnSizes: e, lineWidths: i, ctx: r } = this, { align: a, labels: s } = t, o = Dt.color, l = yn(t.rtl, this.left, this.width), c = vt(s.font), { padding: u } = s, d = c.size, h = d / 2;
|
|
7362
7362
|
let f;
|
|
7363
7363
|
this.drawTitle(), r.textAlign = l.textAlign("left"), r.textBaseline = "middle", r.lineWidth = 0.5, r.font = c.string;
|
|
7364
|
-
const { boxWidth: g, boxHeight: v, itemHeight:
|
|
7364
|
+
const { boxWidth: g, boxHeight: v, itemHeight: p } = Ol(s, d), m = function(_, M, T) {
|
|
7365
7365
|
if (isNaN(g) || g <= 0 || isNaN(v) || v < 0)
|
|
7366
7366
|
return;
|
|
7367
7367
|
r.save();
|
|
@@ -7386,28 +7386,28 @@ class Pl extends Ft {
|
|
|
7386
7386
|
}
|
|
7387
7387
|
r.restore();
|
|
7388
7388
|
}, b = function(_, M, T) {
|
|
7389
|
-
sn(r, T.text, _, M +
|
|
7389
|
+
sn(r, T.text, _, M + p / 2, c, {
|
|
7390
7390
|
strikethrough: T.hidden,
|
|
7391
7391
|
textAlign: l.textAlign(T.textAlign)
|
|
7392
7392
|
});
|
|
7393
|
-
},
|
|
7394
|
-
|
|
7393
|
+
}, x = this.isHorizontal(), y = this._computeTitleHeight();
|
|
7394
|
+
x ? f = {
|
|
7395
7395
|
x: Wt(a, this.left + u, this.right - i[0]),
|
|
7396
|
-
y: this.top + u +
|
|
7396
|
+
y: this.top + u + y,
|
|
7397
7397
|
line: 0
|
|
7398
7398
|
} : f = {
|
|
7399
7399
|
x: this.left + u,
|
|
7400
|
-
y: Wt(a, this.top +
|
|
7400
|
+
y: Wt(a, this.top + y + u, this.bottom - e[0].height),
|
|
7401
7401
|
line: 0
|
|
7402
7402
|
}, Du(this.ctx, t.textDirection);
|
|
7403
|
-
const w =
|
|
7403
|
+
const w = p + u;
|
|
7404
7404
|
this.legendItems.forEach((_, M) => {
|
|
7405
7405
|
r.strokeStyle = _.fontColor, r.fillStyle = _.fontColor;
|
|
7406
7406
|
const T = r.measureText(_.text).width, D = l.textAlign(_.textAlign || (_.textAlign = s.textAlign)), O = g + h + T;
|
|
7407
7407
|
let R = f.x, P = f.y;
|
|
7408
|
-
l.setWidth(this.width),
|
|
7408
|
+
l.setWidth(this.width), x ? M > 0 && R + O + u > this.right && (P = f.y += w, f.line++, R = f.x = Wt(a, this.left + u, this.right - i[f.line])) : M > 0 && P + w > this.bottom && (R = f.x = R + e[f.line].width + u, f.line++, P = f.y = Wt(a, this.top + y + u, this.bottom - e[f.line].height));
|
|
7409
7409
|
const Q = l.x(R);
|
|
7410
|
-
if (
|
|
7410
|
+
if (m(Q, P, _), R = uf(D, R + g + h, x ? R + O : this.right, t.rtl), b(l.x(R), P, _), x)
|
|
7411
7411
|
f.x += O + u;
|
|
7412
7412
|
else if (typeof _.text != "string") {
|
|
7413
7413
|
const _t = c.lineHeight;
|
|
@@ -7425,7 +7425,7 @@ class Pl extends Ft {
|
|
|
7425
7425
|
if (this.isHorizontal())
|
|
7426
7426
|
h = Math.max(...this.lineWidths), u = this.top + c, d = Wt(t.align, d, this.right - h);
|
|
7427
7427
|
else {
|
|
7428
|
-
const g = this.columnSizes.reduce((v,
|
|
7428
|
+
const g = this.columnSizes.reduce((v, p) => Math.max(v, p.height), 0);
|
|
7429
7429
|
u = c + Wt(t.align, this.top, this.bottom - g - t.labels.padding - this._computeTitleHeight());
|
|
7430
7430
|
}
|
|
7431
7431
|
const f = Wt(o, d, d + h);
|
|
@@ -7764,20 +7764,20 @@ function Gm(n, t) {
|
|
|
7764
7764
|
}
|
|
7765
7765
|
function El(n, t) {
|
|
7766
7766
|
const e = n.chart.ctx, { body: i, footer: r, title: a } = n, { boxWidth: s, boxHeight: o } = t, l = vt(t.bodyFont), c = vt(t.titleFont), u = vt(t.footerFont), d = a.length, h = r.length, f = i.length, g = Rt(t.padding);
|
|
7767
|
-
let v = g.height,
|
|
7768
|
-
if (
|
|
7769
|
-
const
|
|
7770
|
-
v += f *
|
|
7767
|
+
let v = g.height, p = 0, m = i.reduce((y, w) => y + w.before.length + w.lines.length + w.after.length, 0);
|
|
7768
|
+
if (m += n.beforeBody.length + n.afterBody.length, d && (v += d * c.lineHeight + (d - 1) * t.titleSpacing + t.titleMarginBottom), m) {
|
|
7769
|
+
const y = t.displayColors ? Math.max(o, l.lineHeight) : l.lineHeight;
|
|
7770
|
+
v += f * y + (m - f) * l.lineHeight + (m - 1) * t.bodySpacing;
|
|
7771
7771
|
}
|
|
7772
7772
|
h && (v += t.footerMarginTop + h * u.lineHeight + (h - 1) * t.footerSpacing);
|
|
7773
7773
|
let b = 0;
|
|
7774
|
-
const
|
|
7775
|
-
|
|
7774
|
+
const x = function(y) {
|
|
7775
|
+
p = Math.max(p, e.measureText(y).width + b);
|
|
7776
7776
|
};
|
|
7777
|
-
return e.save(), e.font = c.string, ct(n.title,
|
|
7778
|
-
ct(
|
|
7779
|
-
}), b = 0, e.font = u.string, ct(n.footer,
|
|
7780
|
-
width:
|
|
7777
|
+
return e.save(), e.font = c.string, ct(n.title, x), e.font = l.string, ct(n.beforeBody.concat(n.afterBody), x), b = t.displayColors ? s + 2 + t.boxPadding : 0, ct(i, (y) => {
|
|
7778
|
+
ct(y.before, x), ct(y.lines, x), ct(y.after, x);
|
|
7779
|
+
}), b = 0, e.font = u.string, ct(n.footer, x), e.restore(), p += g.width, {
|
|
7780
|
+
width: p,
|
|
7781
7781
|
height: v
|
|
7782
7782
|
};
|
|
7783
7783
|
}
|
|
@@ -7980,13 +7980,13 @@ class Ma extends Ft {
|
|
|
7980
7980
|
}
|
|
7981
7981
|
getCaretPosition(t, e, i) {
|
|
7982
7982
|
const { xAlign: r, yAlign: a } = this, { caretSize: s, cornerRadius: o } = i, { topLeft: l, topRight: c, bottomLeft: u, bottomRight: d } = ze(o), { x: h, y: f } = t, { width: g, height: v } = e;
|
|
7983
|
-
let
|
|
7984
|
-
return a === "center" ? (
|
|
7985
|
-
x1:
|
|
7986
|
-
x2:
|
|
7983
|
+
let p, m, b, x, y, w;
|
|
7984
|
+
return a === "center" ? (y = f + v / 2, r === "left" ? (p = h, m = p - s, x = y + s, w = y - s) : (p = h + g, m = p + s, x = y - s, w = y + s), b = p) : (r === "left" ? m = h + Math.max(l, u) + s : r === "right" ? m = h + g - Math.max(c, d) - s : m = this.caretX, a === "top" ? (x = f, y = x - s, p = m - s, b = m + s) : (x = f + v, y = x + s, p = m + s, b = m - s), w = x), {
|
|
7985
|
+
x1: p,
|
|
7986
|
+
x2: m,
|
|
7987
7987
|
x3: b,
|
|
7988
|
-
y1:
|
|
7989
|
-
y2:
|
|
7988
|
+
y1: x,
|
|
7989
|
+
y2: y,
|
|
7990
7990
|
y3: w
|
|
7991
7991
|
};
|
|
7992
7992
|
}
|
|
@@ -8007,24 +8007,24 @@ class Ma extends Ft {
|
|
|
8007
8007
|
pointStyle: o.pointStyle,
|
|
8008
8008
|
rotation: o.rotation,
|
|
8009
8009
|
borderWidth: 1
|
|
8010
|
-
},
|
|
8011
|
-
t.strokeStyle = a.multiKeyBackground, t.fillStyle = a.multiKeyBackground, pa(t, v,
|
|
8010
|
+
}, p = r.leftForLtr(h, c) + c / 2, m = g + l / 2;
|
|
8011
|
+
t.strokeStyle = a.multiKeyBackground, t.fillStyle = a.multiKeyBackground, pa(t, v, p, m), t.strokeStyle = s.borderColor, t.fillStyle = s.backgroundColor, pa(t, v, p, m);
|
|
8012
8012
|
} else {
|
|
8013
8013
|
t.lineWidth = j(s.borderWidth) ? Math.max(...Object.values(s.borderWidth)) : s.borderWidth || 1, t.strokeStyle = s.borderColor, t.setLineDash(s.borderDash || []), t.lineDashOffset = s.borderDashOffset || 0;
|
|
8014
|
-
const v = r.leftForLtr(h, c),
|
|
8015
|
-
Object.values(
|
|
8014
|
+
const v = r.leftForLtr(h, c), p = r.leftForLtr(r.xPlus(h, 1), c - 2), m = ze(s.borderRadius);
|
|
8015
|
+
Object.values(m).some((b) => b !== 0) ? (t.beginPath(), t.fillStyle = a.multiKeyBackground, Mn(t, {
|
|
8016
8016
|
x: v,
|
|
8017
8017
|
y: g,
|
|
8018
8018
|
w: c,
|
|
8019
8019
|
h: l,
|
|
8020
|
-
radius:
|
|
8020
|
+
radius: m
|
|
8021
8021
|
}), t.fill(), t.stroke(), t.fillStyle = s.backgroundColor, t.beginPath(), Mn(t, {
|
|
8022
|
-
x:
|
|
8022
|
+
x: p,
|
|
8023
8023
|
y: g + 1,
|
|
8024
8024
|
w: c - 2,
|
|
8025
8025
|
h: l - 2,
|
|
8026
|
-
radius:
|
|
8027
|
-
}), t.fill()) : (t.fillStyle = a.multiKeyBackground, t.fillRect(v, g, c, l), t.strokeRect(v, g, c, l), t.fillStyle = s.backgroundColor, t.fillRect(
|
|
8026
|
+
radius: m
|
|
8027
|
+
}), t.fill()) : (t.fillStyle = a.multiKeyBackground, t.fillRect(v, g, c, l), t.strokeRect(v, g, c, l), t.fillStyle = s.backgroundColor, t.fillRect(p, g + 1, c - 2, l - 2));
|
|
8028
8028
|
}
|
|
8029
8029
|
t.fillStyle = this.labelTextColors[i];
|
|
8030
8030
|
}
|
|
@@ -8033,12 +8033,12 @@ class Ma extends Ft {
|
|
|
8033
8033
|
let h = d.lineHeight, f = 0;
|
|
8034
8034
|
const g = yn(i.rtl, this.x, this.width), v = function(T) {
|
|
8035
8035
|
e.fillText(T, g.x(t.x + f), t.y + h / 2), t.y += h + a;
|
|
8036
|
-
},
|
|
8037
|
-
let
|
|
8038
|
-
for (e.textAlign = s, e.textBaseline = "middle", e.font = d.string, t.x = $i(this,
|
|
8039
|
-
for (
|
|
8040
|
-
v(
|
|
8041
|
-
ct(
|
|
8036
|
+
}, p = g.textAlign(s);
|
|
8037
|
+
let m, b, x, y, w, _, M;
|
|
8038
|
+
for (e.textAlign = s, e.textBaseline = "middle", e.font = d.string, t.x = $i(this, p, i), e.fillStyle = i.bodyColor, ct(this.beforeBody, v), f = o && p !== "right" ? s === "center" ? c / 2 + u : c + 2 + u : 0, y = 0, _ = r.length; y < _; ++y) {
|
|
8039
|
+
for (m = r[y], b = this.labelTextColors[y], e.fillStyle = b, ct(m.before, v), x = m.lines, o && x.length && (this._drawColorBox(e, t, y, g, i), h = Math.max(d.lineHeight, l)), w = 0, M = x.length; w < M; ++w)
|
|
8040
|
+
v(x[w]), h = d.lineHeight;
|
|
8041
|
+
ct(m.after, v);
|
|
8042
8042
|
}
|
|
8043
8043
|
f = 0, h = d.lineHeight, ct(this.afterBody, v), t.y -= a;
|
|
8044
8044
|
}
|
|
@@ -8328,24 +8328,24 @@ S(Ta, "id", "category"), S(Ta, "defaults", {
|
|
|
8328
8328
|
}
|
|
8329
8329
|
});
|
|
8330
8330
|
function s0(n, t) {
|
|
8331
|
-
const e = [], { bounds: r, step: a, min: s, max: o, precision: l, count: c, maxTicks: u, maxDigits: d, includeBounds: h } = n, f = a || 1, g = u - 1, { min: v, max:
|
|
8332
|
-
let w = Po((
|
|
8333
|
-
if (w < 1e-14 && !
|
|
8331
|
+
const e = [], { bounds: r, step: a, min: s, max: o, precision: l, count: c, maxTicks: u, maxDigits: d, includeBounds: h } = n, f = a || 1, g = u - 1, { min: v, max: p } = t, m = !U(s), b = !U(o), x = !U(c), y = (p - v) / (d + 1);
|
|
8332
|
+
let w = Po((p - v) / g / f) * f, _, M, T, D;
|
|
8333
|
+
if (w < 1e-14 && !m && !b)
|
|
8334
8334
|
return [
|
|
8335
8335
|
{
|
|
8336
8336
|
value: v
|
|
8337
8337
|
},
|
|
8338
8338
|
{
|
|
8339
|
-
value:
|
|
8339
|
+
value: p
|
|
8340
8340
|
}
|
|
8341
8341
|
];
|
|
8342
|
-
D = Math.ceil(
|
|
8342
|
+
D = Math.ceil(p / w) - Math.floor(v / w), D > g && (w = Po(D * w / g / f) * f), U(l) || (_ = Math.pow(10, l), w = Math.ceil(w * _) / _), r === "ticks" ? (M = Math.floor(v / w) * w, T = Math.ceil(p / w) * w) : (M = v, T = p), m && b && a && nf((o - s) / a, w / 1e3) ? (D = Math.round(Math.min((o - s) / w, u)), w = (o - s) / D, M = s, T = o) : x ? (M = m ? s : M, T = b ? o : T, D = c - 1, w = (T - M) / D) : (D = (T - M) / w, Jn(D, Math.round(D), w / 1e3) ? D = Math.round(D) : D = Math.ceil(D));
|
|
8343
8343
|
const O = Math.max(Eo(w), Eo(M));
|
|
8344
8344
|
_ = Math.pow(10, U(l) ? O : l), M = Math.round(M * _) / _, T = Math.round(T * _) / _;
|
|
8345
8345
|
let R = 0;
|
|
8346
|
-
for (
|
|
8346
|
+
for (m && (h && M !== s ? (e.push({
|
|
8347
8347
|
value: s
|
|
8348
|
-
}), M < s && R++, Jn(Math.round((M + R * w) * _) / _, s, Fl(s,
|
|
8348
|
+
}), M < s && R++, Jn(Math.round((M + R * w) * _) / _, s, Fl(s, y, n)) && R++) : M < s && R++); R < D; ++R) {
|
|
8349
8349
|
const P = Math.round((M + R * w) * _) / _;
|
|
8350
8350
|
if (b && P > o)
|
|
8351
8351
|
break;
|
|
@@ -8353,7 +8353,7 @@ function s0(n, t) {
|
|
|
8353
8353
|
value: P
|
|
8354
8354
|
});
|
|
8355
8355
|
}
|
|
8356
|
-
return b && h && T !== o ? e.length && Jn(e[e.length - 1].value, o, Fl(o,
|
|
8356
|
+
return b && h && T !== o ? e.length && Jn(e[e.length - 1].value, o, Fl(o, y, n)) ? e[e.length - 1].value = o : e.push({
|
|
8357
8357
|
value: o
|
|
8358
8358
|
}) : (!b || T === o) && e.push({
|
|
8359
8359
|
value: T
|
|
@@ -8576,8 +8576,8 @@ function u0(n) {
|
|
|
8576
8576
|
r[l] = c.padding;
|
|
8577
8577
|
const u = n.getPointPosition(l, n.drawingArea + r[l], o), d = vt(c.font), h = c0(n.ctx, d, n._pointLabels[l]);
|
|
8578
8578
|
i[l] = h;
|
|
8579
|
-
const f = Jt(n.getIndexAngle(l) + o), g = Math.round(Dr(f)), v = Ul(g, u.x, h.w, 0, 180),
|
|
8580
|
-
d0(e, t, f, v,
|
|
8579
|
+
const f = Jt(n.getIndexAngle(l) + o), g = Math.round(Dr(f)), v = Ul(g, u.x, h.w, 0, 180), p = Ul(g, u.y, h.h, 90, 270);
|
|
8580
|
+
d0(e, t, f, v, p);
|
|
8581
8581
|
}
|
|
8582
8582
|
n.setCenterPoint(t.l - e.l, e.r - t.r, t.t - e.t, e.b - t.b), n._pointLabelItems = g0(n, i, r);
|
|
8583
8583
|
}
|
|
@@ -9592,10 +9592,10 @@ function Js(n, t) {
|
|
|
9592
9592
|
throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");
|
|
9593
9593
|
var g = /* @__PURE__ */ new Date(0);
|
|
9594
9594
|
g.setUTCFullYear(d + 1, 0, f), g.setUTCHours(0, 0, 0, 0);
|
|
9595
|
-
var v = on(g, t),
|
|
9596
|
-
|
|
9597
|
-
var
|
|
9598
|
-
return u.getTime() >= v.getTime() ? d + 1 : u.getTime() >=
|
|
9595
|
+
var v = on(g, t), p = /* @__PURE__ */ new Date(0);
|
|
9596
|
+
p.setUTCFullYear(d, 0, f), p.setUTCHours(0, 0, 0, 0);
|
|
9597
|
+
var m = on(p, t);
|
|
9598
|
+
return u.getTime() >= v.getTime() ? d + 1 : u.getTime() >= m.getTime() ? d : d - 1;
|
|
9599
9599
|
}
|
|
9600
9600
|
function pv(n, t) {
|
|
9601
9601
|
var e, i, r, a, s, o, l, c;
|
|
@@ -10717,12 +10717,12 @@ var ob = {
|
|
|
10717
10717
|
const dd = ob;
|
|
10718
10718
|
var lb = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, cb = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, ub = /^'([^]*?)'?$/, db = /''/g, hb = /[a-zA-Z]/;
|
|
10719
10719
|
function fb(n, t, e) {
|
|
10720
|
-
var i, r, a, s, o, l, c, u, d, h, f, g, v,
|
|
10720
|
+
var i, r, a, s, o, l, c, u, d, h, f, g, v, p, m, b, x, y;
|
|
10721
10721
|
I(2, arguments);
|
|
10722
10722
|
var w = String(t), _ = Ge(), M = (i = (r = e == null ? void 0 : e.locale) !== null && r !== void 0 ? r : _.locale) !== null && i !== void 0 ? i : dd, T = bt((a = (s = (o = (l = e == null ? void 0 : e.firstWeekContainsDate) !== null && l !== void 0 ? l : e == null || (c = e.locale) === null || c === void 0 || (u = c.options) === null || u === void 0 ? void 0 : u.firstWeekContainsDate) !== null && o !== void 0 ? o : _.firstWeekContainsDate) !== null && s !== void 0 ? s : (d = _.locale) === null || d === void 0 || (h = d.options) === null || h === void 0 ? void 0 : h.firstWeekContainsDate) !== null && a !== void 0 ? a : 1);
|
|
10723
10723
|
if (!(T >= 1 && T <= 7))
|
|
10724
10724
|
throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");
|
|
10725
|
-
var D = bt((f = (g = (v = (
|
|
10725
|
+
var D = bt((f = (g = (v = (p = e == null ? void 0 : e.weekStartsOn) !== null && p !== void 0 ? p : e == null || (m = e.locale) === null || m === void 0 || (b = m.options) === null || b === void 0 ? void 0 : b.weekStartsOn) !== null && v !== void 0 ? v : _.weekStartsOn) !== null && g !== void 0 ? g : (x = _.locale) === null || x === void 0 || (y = x.options) === null || y === void 0 ? void 0 : y.weekStartsOn) !== null && f !== void 0 ? f : 0);
|
|
10726
10726
|
if (!(D >= 0 && D <= 6))
|
|
10727
10727
|
throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");
|
|
10728
10728
|
if (!M.localize)
|
|
@@ -11719,7 +11719,7 @@ function eo(n, t, e) {
|
|
|
11719
11719
|
var d = Ge(), h = bt((i = (r = (a = (s = e == null ? void 0 : e.weekStartsOn) !== null && s !== void 0 ? s : e == null || (o = e.locale) === null || o === void 0 || (l = o.options) === null || l === void 0 ? void 0 : l.weekStartsOn) !== null && a !== void 0 ? a : d.weekStartsOn) !== null && r !== void 0 ? r : (c = d.locale) === null || c === void 0 || (u = c.options) === null || u === void 0 ? void 0 : u.weekStartsOn) !== null && i !== void 0 ? i : 0);
|
|
11720
11720
|
if (!(h >= 0 && h <= 6))
|
|
11721
11721
|
throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");
|
|
11722
|
-
var f = Y(n), g = bt(t), v = f.getUTCDay(),
|
|
11722
|
+
var f = Y(n), g = bt(t), v = f.getUTCDay(), p = g % 7, m = (p + 7) % 7, b = (m < h ? 7 : 0) + g - v;
|
|
11723
11723
|
return f.setUTCDate(f.getUTCDate() + b), f;
|
|
11724
11724
|
}
|
|
11725
11725
|
var Ub = /* @__PURE__ */ function(n) {
|
|
@@ -12558,7 +12558,7 @@ var Bb = /* @__PURE__ */ function(n) {
|
|
|
12558
12558
|
T: new ry()
|
|
12559
12559
|
}, sy = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, oy = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, ly = /^'([^]*?)'?$/, cy = /''/g, uy = /\S/, dy = /[a-zA-Z]/;
|
|
12560
12560
|
function hy(n, t, e, i) {
|
|
12561
|
-
var r, a, s, o, l, c, u, d, h, f, g, v,
|
|
12561
|
+
var r, a, s, o, l, c, u, d, h, f, g, v, p, m, b, x, y, w;
|
|
12562
12562
|
I(3, arguments);
|
|
12563
12563
|
var _ = String(n), M = String(t), T = Ge(), D = (r = (a = i == null ? void 0 : i.locale) !== null && a !== void 0 ? a : T.locale) !== null && r !== void 0 ? r : dd;
|
|
12564
12564
|
if (!D.match)
|
|
@@ -12566,7 +12566,7 @@ function hy(n, t, e, i) {
|
|
|
12566
12566
|
var O = bt((s = (o = (l = (c = i == null ? void 0 : i.firstWeekContainsDate) !== null && c !== void 0 ? c : i == null || (u = i.locale) === null || u === void 0 || (d = u.options) === null || d === void 0 ? void 0 : d.firstWeekContainsDate) !== null && l !== void 0 ? l : T.firstWeekContainsDate) !== null && o !== void 0 ? o : (h = T.locale) === null || h === void 0 || (f = h.options) === null || f === void 0 ? void 0 : f.firstWeekContainsDate) !== null && s !== void 0 ? s : 1);
|
|
12567
12567
|
if (!(O >= 1 && O <= 7))
|
|
12568
12568
|
throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");
|
|
12569
|
-
var R = bt((g = (v = (
|
|
12569
|
+
var R = bt((g = (v = (p = (m = i == null ? void 0 : i.weekStartsOn) !== null && m !== void 0 ? m : i == null || (b = i.locale) === null || b === void 0 || (x = b.options) === null || x === void 0 ? void 0 : x.weekStartsOn) !== null && p !== void 0 ? p : T.weekStartsOn) !== null && v !== void 0 ? v : (y = T.locale) === null || y === void 0 || (w = y.options) === null || w === void 0 ? void 0 : w.weekStartsOn) !== null && g !== void 0 ? g : 0);
|
|
12570
12570
|
if (!(R >= 0 && R <= 6))
|
|
12571
12571
|
throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");
|
|
12572
12572
|
if (M === "")
|
|
@@ -12801,7 +12801,7 @@ function Ay(n) {
|
|
|
12801
12801
|
var t = n / $0;
|
|
12802
12802
|
return Math.floor(t);
|
|
12803
12803
|
}
|
|
12804
|
-
var zt = /* @__PURE__ */ ((n) => (n.DOUGHNUT = "Doughnut", n.HORIZONTAL_BAR = "HorizontalBar", n.VERTICAL_BAR = "VerticalBar", n.TIMESERIES_LINE = "Line", n.TIMESERIES_BAR = "TimeSeriesBar", n))(zt || {}), no = /* @__PURE__ */ ((n) => (n.GAUGE = "Gauge", n.TOPN = "TopN", n))(no || {}),
|
|
12804
|
+
var zt = /* @__PURE__ */ ((n) => (n.DOUGHNUT = "Doughnut", n.HORIZONTAL_BAR = "HorizontalBar", n.VERTICAL_BAR = "VerticalBar", n.TIMESERIES_LINE = "Line", n.TIMESERIES_BAR = "TimeSeriesBar", n))(zt || {}), no = /* @__PURE__ */ ((n) => (n.GAUGE = "Gauge", n.TOPN = "TopN", n))(no || {}), Ct = /* @__PURE__ */ ((n) => (n.Hidden = "hidden", n.Right = "right", n.Bottom = "bottom", n))(Ct || {}), Kn = /* @__PURE__ */ ((n) => (n.Hidden = "hidden", n.SingleMetric = "single", n.Full = "full", n))(Kn || {});
|
|
12805
12805
|
const io = (n, t) => {
|
|
12806
12806
|
var i, r;
|
|
12807
12807
|
const { tooltip: e } = t;
|
|
@@ -12843,7 +12843,7 @@ var Aa = { exports: {} }, yd = { exports: {} };
|
|
|
12843
12843
|
}
|
|
12844
12844
|
n.exports = t, n.exports.__esModule = !0, n.exports.default = n.exports;
|
|
12845
12845
|
})(yd);
|
|
12846
|
-
var
|
|
12846
|
+
var kt = yd.exports, Ra = { exports: {} }, La = { exports: {} }, xd = { exports: {} };
|
|
12847
12847
|
(function(n) {
|
|
12848
12848
|
function t(e) {
|
|
12849
12849
|
"@babel/helpers - typeof";
|
|
@@ -12868,7 +12868,7 @@ var wd = xd.exports, Ia = { exports: {} };
|
|
|
12868
12868
|
})(Ia, Ia.exports);
|
|
12869
12869
|
var Vt = Ia.exports;
|
|
12870
12870
|
(function(n, t) {
|
|
12871
|
-
var e =
|
|
12871
|
+
var e = kt.default;
|
|
12872
12872
|
Object.defineProperty(t, "__esModule", {
|
|
12873
12873
|
value: !0
|
|
12874
12874
|
}), t.default = a;
|
|
@@ -12880,7 +12880,7 @@ var Vt = Ia.exports;
|
|
|
12880
12880
|
})(La, La.exports);
|
|
12881
12881
|
var Wy = La.exports, Na = { exports: {} };
|
|
12882
12882
|
(function(n, t) {
|
|
12883
|
-
var e =
|
|
12883
|
+
var e = kt.default;
|
|
12884
12884
|
Object.defineProperty(t, "__esModule", {
|
|
12885
12885
|
value: !0
|
|
12886
12886
|
}), t.default = a;
|
|
@@ -12894,7 +12894,7 @@ var Wy = La.exports, Na = { exports: {} };
|
|
|
12894
12894
|
})(Na, Na.exports);
|
|
12895
12895
|
var me = Na.exports;
|
|
12896
12896
|
(function(n, t) {
|
|
12897
|
-
var e =
|
|
12897
|
+
var e = kt.default;
|
|
12898
12898
|
Object.defineProperty(t, "__esModule", {
|
|
12899
12899
|
value: !0
|
|
12900
12900
|
}), t.default = s;
|
|
@@ -12923,7 +12923,7 @@ var Uy = Ra.exports, Fa = { exports: {} }, Ya = { exports: {} }, Wa = { exports:
|
|
|
12923
12923
|
var un = Wa.exports;
|
|
12924
12924
|
const zy = /* @__PURE__ */ wi(un);
|
|
12925
12925
|
(function(n, t) {
|
|
12926
|
-
var e =
|
|
12926
|
+
var e = kt.default;
|
|
12927
12927
|
Object.defineProperty(t, "__esModule", {
|
|
12928
12928
|
value: !0
|
|
12929
12929
|
}), t.default = s;
|
|
@@ -12937,7 +12937,7 @@ const zy = /* @__PURE__ */ wi(un);
|
|
|
12937
12937
|
})(Ya, Ya.exports);
|
|
12938
12938
|
var Hy = Ya.exports;
|
|
12939
12939
|
(function(n, t) {
|
|
12940
|
-
var e =
|
|
12940
|
+
var e = kt.default;
|
|
12941
12941
|
Object.defineProperty(t, "__esModule", {
|
|
12942
12942
|
value: !0
|
|
12943
12943
|
}), t.default = s;
|
|
@@ -12951,7 +12951,7 @@ var Hy = Ya.exports;
|
|
|
12951
12951
|
})(Fa, Fa.exports);
|
|
12952
12952
|
var $y = Fa.exports, Ua = { exports: {} }, za = { exports: {} };
|
|
12953
12953
|
(function(n, t) {
|
|
12954
|
-
var e =
|
|
12954
|
+
var e = kt.default;
|
|
12955
12955
|
Object.defineProperty(t, "__esModule", {
|
|
12956
12956
|
value: !0
|
|
12957
12957
|
}), t.default = s;
|
|
@@ -12967,7 +12967,7 @@ var $y = Fa.exports, Ua = { exports: {} }, za = { exports: {} };
|
|
|
12967
12967
|
})(za, za.exports);
|
|
12968
12968
|
var By = za.exports, Ha = { exports: {} }, $a = { exports: {} };
|
|
12969
12969
|
(function(n, t) {
|
|
12970
|
-
var e =
|
|
12970
|
+
var e = kt.default;
|
|
12971
12971
|
Object.defineProperty(t, "__esModule", {
|
|
12972
12972
|
value: !0
|
|
12973
12973
|
}), t.default = a;
|
|
@@ -12981,7 +12981,7 @@ var By = za.exports, Ha = { exports: {} }, $a = { exports: {} };
|
|
|
12981
12981
|
})($a, $a.exports);
|
|
12982
12982
|
var ao = $a.exports, Ba = { exports: {} }, ja = { exports: {} };
|
|
12983
12983
|
(function(n, t) {
|
|
12984
|
-
var e =
|
|
12984
|
+
var e = kt.default;
|
|
12985
12985
|
Object.defineProperty(t, "__esModule", {
|
|
12986
12986
|
value: !0
|
|
12987
12987
|
}), t.default = s;
|
|
@@ -12999,7 +12999,7 @@ var ao = $a.exports, Ba = { exports: {} }, ja = { exports: {} };
|
|
|
12999
12999
|
})(ja, ja.exports);
|
|
13000
13000
|
var _d = ja.exports;
|
|
13001
13001
|
(function(n, t) {
|
|
13002
|
-
var e =
|
|
13002
|
+
var e = kt.default;
|
|
13003
13003
|
Object.defineProperty(t, "__esModule", {
|
|
13004
13004
|
value: !0
|
|
13005
13005
|
}), t.default = s;
|
|
@@ -13015,7 +13015,7 @@ var _d = ja.exports;
|
|
|
13015
13015
|
})(Ba, Ba.exports);
|
|
13016
13016
|
var jy = Ba.exports;
|
|
13017
13017
|
(function(n, t) {
|
|
13018
|
-
var e =
|
|
13018
|
+
var e = kt.default;
|
|
13019
13019
|
Object.defineProperty(t, "__esModule", {
|
|
13020
13020
|
value: !0
|
|
13021
13021
|
}), t.default = l;
|
|
@@ -13041,56 +13041,56 @@ function Xy(n) {
|
|
|
13041
13041
|
Md = n;
|
|
13042
13042
|
}
|
|
13043
13043
|
(function(n, t) {
|
|
13044
|
-
var e =
|
|
13044
|
+
var e = kt.default;
|
|
13045
13045
|
Object.defineProperty(t, "__esModule", {
|
|
13046
13046
|
value: !0
|
|
13047
13047
|
}), t.default = o;
|
|
13048
13048
|
var i = e(me), r = e(Vt), a = e(un), s = dn;
|
|
13049
13049
|
function o(l, c) {
|
|
13050
|
-
var u, d, h, f, g, v,
|
|
13050
|
+
var u, d, h, f, g, v, p, m;
|
|
13051
13051
|
(0, r.default)(1, arguments);
|
|
13052
|
-
var b = (0, s.getDefaultOptions)(),
|
|
13053
|
-
if (!(
|
|
13052
|
+
var b = (0, s.getDefaultOptions)(), x = (0, a.default)((u = (d = (h = (f = c == null ? void 0 : c.weekStartsOn) !== null && f !== void 0 ? f : c == null || (g = c.locale) === null || g === void 0 || (v = g.options) === null || v === void 0 ? void 0 : v.weekStartsOn) !== null && h !== void 0 ? h : b.weekStartsOn) !== null && d !== void 0 ? d : (p = b.locale) === null || p === void 0 || (m = p.options) === null || m === void 0 ? void 0 : m.weekStartsOn) !== null && u !== void 0 ? u : 0);
|
|
13053
|
+
if (!(x >= 0 && x <= 6))
|
|
13054
13054
|
throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");
|
|
13055
|
-
var
|
|
13056
|
-
return
|
|
13055
|
+
var y = (0, i.default)(l), w = y.getUTCDay(), _ = (w < x ? 7 : 0) + w - x;
|
|
13056
|
+
return y.setUTCDate(y.getUTCDate() - _), y.setUTCHours(0, 0, 0, 0), y;
|
|
13057
13057
|
}
|
|
13058
13058
|
n.exports = t.default;
|
|
13059
13059
|
})(qa, qa.exports);
|
|
13060
13060
|
var so = qa.exports, Xa = { exports: {} }, Ga = { exports: {} };
|
|
13061
13061
|
(function(n, t) {
|
|
13062
|
-
var e =
|
|
13062
|
+
var e = kt.default;
|
|
13063
13063
|
Object.defineProperty(t, "__esModule", {
|
|
13064
13064
|
value: !0
|
|
13065
13065
|
}), t.default = l;
|
|
13066
13066
|
var i = e(me), r = e(Vt), a = e(so), s = e(un), o = dn;
|
|
13067
13067
|
function l(c, u) {
|
|
13068
|
-
var d, h, f, g, v,
|
|
13068
|
+
var d, h, f, g, v, p, m, b;
|
|
13069
13069
|
(0, r.default)(1, arguments);
|
|
13070
|
-
var
|
|
13070
|
+
var x = (0, i.default)(c), y = x.getUTCFullYear(), w = (0, o.getDefaultOptions)(), _ = (0, s.default)((d = (h = (f = (g = u == null ? void 0 : u.firstWeekContainsDate) !== null && g !== void 0 ? g : u == null || (v = u.locale) === null || v === void 0 || (p = v.options) === null || p === void 0 ? void 0 : p.firstWeekContainsDate) !== null && f !== void 0 ? f : w.firstWeekContainsDate) !== null && h !== void 0 ? h : (m = w.locale) === null || m === void 0 || (b = m.options) === null || b === void 0 ? void 0 : b.firstWeekContainsDate) !== null && d !== void 0 ? d : 1);
|
|
13071
13071
|
if (!(_ >= 1 && _ <= 7))
|
|
13072
13072
|
throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");
|
|
13073
13073
|
var M = /* @__PURE__ */ new Date(0);
|
|
13074
|
-
M.setUTCFullYear(
|
|
13074
|
+
M.setUTCFullYear(y + 1, 0, _), M.setUTCHours(0, 0, 0, 0);
|
|
13075
13075
|
var T = (0, a.default)(M, u), D = /* @__PURE__ */ new Date(0);
|
|
13076
|
-
D.setUTCFullYear(
|
|
13076
|
+
D.setUTCFullYear(y, 0, _), D.setUTCHours(0, 0, 0, 0);
|
|
13077
13077
|
var O = (0, a.default)(D, u);
|
|
13078
|
-
return
|
|
13078
|
+
return x.getTime() >= T.getTime() ? y + 1 : x.getTime() >= O.getTime() ? y : y - 1;
|
|
13079
13079
|
}
|
|
13080
13080
|
n.exports = t.default;
|
|
13081
13081
|
})(Ga, Ga.exports);
|
|
13082
13082
|
var Td = Ga.exports;
|
|
13083
13083
|
(function(n, t) {
|
|
13084
|
-
var e =
|
|
13084
|
+
var e = kt.default;
|
|
13085
13085
|
Object.defineProperty(t, "__esModule", {
|
|
13086
13086
|
value: !0
|
|
13087
13087
|
}), t.default = l;
|
|
13088
13088
|
var i = e(Td), r = e(Vt), a = e(so), s = e(un), o = dn;
|
|
13089
13089
|
function l(c, u) {
|
|
13090
|
-
var d, h, f, g, v,
|
|
13090
|
+
var d, h, f, g, v, p, m, b;
|
|
13091
13091
|
(0, r.default)(1, arguments);
|
|
13092
|
-
var
|
|
13093
|
-
_.setUTCFullYear(w, 0,
|
|
13092
|
+
var x = (0, o.getDefaultOptions)(), y = (0, s.default)((d = (h = (f = (g = u == null ? void 0 : u.firstWeekContainsDate) !== null && g !== void 0 ? g : u == null || (v = u.locale) === null || v === void 0 || (p = v.options) === null || p === void 0 ? void 0 : p.firstWeekContainsDate) !== null && f !== void 0 ? f : x.firstWeekContainsDate) !== null && h !== void 0 ? h : (m = x.locale) === null || m === void 0 || (b = m.options) === null || b === void 0 ? void 0 : b.firstWeekContainsDate) !== null && d !== void 0 ? d : 1), w = (0, i.default)(c, u), _ = /* @__PURE__ */ new Date(0);
|
|
13093
|
+
_.setUTCFullYear(w, 0, y), _.setUTCHours(0, 0, 0, 0);
|
|
13094
13094
|
var M = (0, a.default)(_, u);
|
|
13095
13095
|
return M;
|
|
13096
13096
|
}
|
|
@@ -13098,7 +13098,7 @@ var Td = Ga.exports;
|
|
|
13098
13098
|
})(Xa, Xa.exports);
|
|
13099
13099
|
var Gy = Xa.exports;
|
|
13100
13100
|
(function(n, t) {
|
|
13101
|
-
var e =
|
|
13101
|
+
var e = kt.default;
|
|
13102
13102
|
Object.defineProperty(t, "__esModule", {
|
|
13103
13103
|
value: !0
|
|
13104
13104
|
}), t.default = l;
|
|
@@ -13124,7 +13124,7 @@ var Ky = Va.exports, Ka = { exports: {} };
|
|
|
13124
13124
|
})(Ka, Ka.exports);
|
|
13125
13125
|
var Dd = Ka.exports, Za = { exports: {} };
|
|
13126
13126
|
(function(n, t) {
|
|
13127
|
-
var e =
|
|
13127
|
+
var e = kt.default;
|
|
13128
13128
|
Object.defineProperty(t, "__esModule", {
|
|
13129
13129
|
value: !0
|
|
13130
13130
|
}), t.default = void 0;
|
|
@@ -13185,7 +13185,7 @@ var Dd = Ka.exports, Za = { exports: {} };
|
|
|
13185
13185
|
})(Za, Za.exports);
|
|
13186
13186
|
var Zy = Za.exports;
|
|
13187
13187
|
(function(n, t) {
|
|
13188
|
-
var e =
|
|
13188
|
+
var e = kt.default;
|
|
13189
13189
|
Object.defineProperty(t, "__esModule", {
|
|
13190
13190
|
value: !0
|
|
13191
13191
|
}), t.default = void 0;
|
|
@@ -13200,51 +13200,51 @@ var Zy = Za.exports;
|
|
|
13200
13200
|
night: "night"
|
|
13201
13201
|
}, d = {
|
|
13202
13202
|
// Era
|
|
13203
|
-
G: function(
|
|
13204
|
-
var
|
|
13203
|
+
G: function(m, b, x) {
|
|
13204
|
+
var y = m.getUTCFullYear() > 0 ? 1 : 0;
|
|
13205
13205
|
switch (b) {
|
|
13206
13206
|
case "G":
|
|
13207
13207
|
case "GG":
|
|
13208
13208
|
case "GGG":
|
|
13209
|
-
return
|
|
13209
|
+
return x.era(y, {
|
|
13210
13210
|
width: "abbreviated"
|
|
13211
13211
|
});
|
|
13212
13212
|
case "GGGGG":
|
|
13213
|
-
return
|
|
13213
|
+
return x.era(y, {
|
|
13214
13214
|
width: "narrow"
|
|
13215
13215
|
});
|
|
13216
13216
|
case "GGGG":
|
|
13217
13217
|
default:
|
|
13218
|
-
return
|
|
13218
|
+
return x.era(y, {
|
|
13219
13219
|
width: "wide"
|
|
13220
13220
|
});
|
|
13221
13221
|
}
|
|
13222
13222
|
},
|
|
13223
13223
|
// Year
|
|
13224
|
-
y: function(
|
|
13224
|
+
y: function(m, b, x) {
|
|
13225
13225
|
if (b === "yo") {
|
|
13226
|
-
var
|
|
13227
|
-
return
|
|
13226
|
+
var y = m.getUTCFullYear(), w = y > 0 ? y : 1 - y;
|
|
13227
|
+
return x.ordinalNumber(w, {
|
|
13228
13228
|
unit: "year"
|
|
13229
13229
|
});
|
|
13230
13230
|
}
|
|
13231
|
-
return c.default.y(
|
|
13231
|
+
return c.default.y(m, b);
|
|
13232
13232
|
},
|
|
13233
13233
|
// Local week-numbering year
|
|
13234
|
-
Y: function(
|
|
13235
|
-
var w = (0, o.default)(
|
|
13234
|
+
Y: function(m, b, x, y) {
|
|
13235
|
+
var w = (0, o.default)(m, y), _ = w > 0 ? w : 1 - w;
|
|
13236
13236
|
if (b === "YY") {
|
|
13237
13237
|
var M = _ % 100;
|
|
13238
13238
|
return (0, l.default)(M, 2);
|
|
13239
13239
|
}
|
|
13240
|
-
return b === "Yo" ?
|
|
13240
|
+
return b === "Yo" ? x.ordinalNumber(_, {
|
|
13241
13241
|
unit: "year"
|
|
13242
13242
|
}) : (0, l.default)(_, b.length);
|
|
13243
13243
|
},
|
|
13244
13244
|
// ISO week-numbering year
|
|
13245
|
-
R: function(
|
|
13246
|
-
var
|
|
13247
|
-
return (0, l.default)(
|
|
13245
|
+
R: function(m, b) {
|
|
13246
|
+
var x = (0, a.default)(m);
|
|
13247
|
+
return (0, l.default)(x, b.length);
|
|
13248
13248
|
},
|
|
13249
13249
|
// Extended year. This is a single number designating the year of this calendar system.
|
|
13250
13250
|
// The main difference between `y` and `u` localizers are B.C. years:
|
|
@@ -13255,419 +13255,419 @@ var Zy = Za.exports;
|
|
|
13255
13255
|
// | BC 2 | 2 | -1 |
|
|
13256
13256
|
// Also `yy` always returns the last two digits of a year,
|
|
13257
13257
|
// while `uu` pads single digit years to 2 characters and returns other years unchanged.
|
|
13258
|
-
u: function(
|
|
13259
|
-
var
|
|
13260
|
-
return (0, l.default)(
|
|
13258
|
+
u: function(m, b) {
|
|
13259
|
+
var x = m.getUTCFullYear();
|
|
13260
|
+
return (0, l.default)(x, b.length);
|
|
13261
13261
|
},
|
|
13262
13262
|
// Quarter
|
|
13263
|
-
Q: function(
|
|
13264
|
-
var
|
|
13263
|
+
Q: function(m, b, x) {
|
|
13264
|
+
var y = Math.ceil((m.getUTCMonth() + 1) / 3);
|
|
13265
13265
|
switch (b) {
|
|
13266
13266
|
case "Q":
|
|
13267
|
-
return String(
|
|
13267
|
+
return String(y);
|
|
13268
13268
|
case "QQ":
|
|
13269
|
-
return (0, l.default)(
|
|
13269
|
+
return (0, l.default)(y, 2);
|
|
13270
13270
|
case "Qo":
|
|
13271
|
-
return
|
|
13271
|
+
return x.ordinalNumber(y, {
|
|
13272
13272
|
unit: "quarter"
|
|
13273
13273
|
});
|
|
13274
13274
|
case "QQQ":
|
|
13275
|
-
return
|
|
13275
|
+
return x.quarter(y, {
|
|
13276
13276
|
width: "abbreviated",
|
|
13277
13277
|
context: "formatting"
|
|
13278
13278
|
});
|
|
13279
13279
|
case "QQQQQ":
|
|
13280
|
-
return
|
|
13280
|
+
return x.quarter(y, {
|
|
13281
13281
|
width: "narrow",
|
|
13282
13282
|
context: "formatting"
|
|
13283
13283
|
});
|
|
13284
13284
|
case "QQQQ":
|
|
13285
13285
|
default:
|
|
13286
|
-
return
|
|
13286
|
+
return x.quarter(y, {
|
|
13287
13287
|
width: "wide",
|
|
13288
13288
|
context: "formatting"
|
|
13289
13289
|
});
|
|
13290
13290
|
}
|
|
13291
13291
|
},
|
|
13292
13292
|
// Stand-alone quarter
|
|
13293
|
-
q: function(
|
|
13294
|
-
var
|
|
13293
|
+
q: function(m, b, x) {
|
|
13294
|
+
var y = Math.ceil((m.getUTCMonth() + 1) / 3);
|
|
13295
13295
|
switch (b) {
|
|
13296
13296
|
case "q":
|
|
13297
|
-
return String(
|
|
13297
|
+
return String(y);
|
|
13298
13298
|
case "qq":
|
|
13299
|
-
return (0, l.default)(
|
|
13299
|
+
return (0, l.default)(y, 2);
|
|
13300
13300
|
case "qo":
|
|
13301
|
-
return
|
|
13301
|
+
return x.ordinalNumber(y, {
|
|
13302
13302
|
unit: "quarter"
|
|
13303
13303
|
});
|
|
13304
13304
|
case "qqq":
|
|
13305
|
-
return
|
|
13305
|
+
return x.quarter(y, {
|
|
13306
13306
|
width: "abbreviated",
|
|
13307
13307
|
context: "standalone"
|
|
13308
13308
|
});
|
|
13309
13309
|
case "qqqqq":
|
|
13310
|
-
return
|
|
13310
|
+
return x.quarter(y, {
|
|
13311
13311
|
width: "narrow",
|
|
13312
13312
|
context: "standalone"
|
|
13313
13313
|
});
|
|
13314
13314
|
case "qqqq":
|
|
13315
13315
|
default:
|
|
13316
|
-
return
|
|
13316
|
+
return x.quarter(y, {
|
|
13317
13317
|
width: "wide",
|
|
13318
13318
|
context: "standalone"
|
|
13319
13319
|
});
|
|
13320
13320
|
}
|
|
13321
13321
|
},
|
|
13322
13322
|
// Month
|
|
13323
|
-
M: function(
|
|
13324
|
-
var
|
|
13323
|
+
M: function(m, b, x) {
|
|
13324
|
+
var y = m.getUTCMonth();
|
|
13325
13325
|
switch (b) {
|
|
13326
13326
|
case "M":
|
|
13327
13327
|
case "MM":
|
|
13328
|
-
return c.default.M(
|
|
13328
|
+
return c.default.M(m, b);
|
|
13329
13329
|
case "Mo":
|
|
13330
|
-
return
|
|
13330
|
+
return x.ordinalNumber(y + 1, {
|
|
13331
13331
|
unit: "month"
|
|
13332
13332
|
});
|
|
13333
13333
|
case "MMM":
|
|
13334
|
-
return
|
|
13334
|
+
return x.month(y, {
|
|
13335
13335
|
width: "abbreviated",
|
|
13336
13336
|
context: "formatting"
|
|
13337
13337
|
});
|
|
13338
13338
|
case "MMMMM":
|
|
13339
|
-
return
|
|
13339
|
+
return x.month(y, {
|
|
13340
13340
|
width: "narrow",
|
|
13341
13341
|
context: "formatting"
|
|
13342
13342
|
});
|
|
13343
13343
|
case "MMMM":
|
|
13344
13344
|
default:
|
|
13345
|
-
return
|
|
13345
|
+
return x.month(y, {
|
|
13346
13346
|
width: "wide",
|
|
13347
13347
|
context: "formatting"
|
|
13348
13348
|
});
|
|
13349
13349
|
}
|
|
13350
13350
|
},
|
|
13351
13351
|
// Stand-alone month
|
|
13352
|
-
L: function(
|
|
13353
|
-
var
|
|
13352
|
+
L: function(m, b, x) {
|
|
13353
|
+
var y = m.getUTCMonth();
|
|
13354
13354
|
switch (b) {
|
|
13355
13355
|
case "L":
|
|
13356
|
-
return String(
|
|
13356
|
+
return String(y + 1);
|
|
13357
13357
|
case "LL":
|
|
13358
|
-
return (0, l.default)(
|
|
13358
|
+
return (0, l.default)(y + 1, 2);
|
|
13359
13359
|
case "Lo":
|
|
13360
|
-
return
|
|
13360
|
+
return x.ordinalNumber(y + 1, {
|
|
13361
13361
|
unit: "month"
|
|
13362
13362
|
});
|
|
13363
13363
|
case "LLL":
|
|
13364
|
-
return
|
|
13364
|
+
return x.month(y, {
|
|
13365
13365
|
width: "abbreviated",
|
|
13366
13366
|
context: "standalone"
|
|
13367
13367
|
});
|
|
13368
13368
|
case "LLLLL":
|
|
13369
|
-
return
|
|
13369
|
+
return x.month(y, {
|
|
13370
13370
|
width: "narrow",
|
|
13371
13371
|
context: "standalone"
|
|
13372
13372
|
});
|
|
13373
13373
|
case "LLLL":
|
|
13374
13374
|
default:
|
|
13375
|
-
return
|
|
13375
|
+
return x.month(y, {
|
|
13376
13376
|
width: "wide",
|
|
13377
13377
|
context: "standalone"
|
|
13378
13378
|
});
|
|
13379
13379
|
}
|
|
13380
13380
|
},
|
|
13381
13381
|
// Local week of year
|
|
13382
|
-
w: function(
|
|
13383
|
-
var w = (0, s.default)(
|
|
13384
|
-
return b === "wo" ?
|
|
13382
|
+
w: function(m, b, x, y) {
|
|
13383
|
+
var w = (0, s.default)(m, y);
|
|
13384
|
+
return b === "wo" ? x.ordinalNumber(w, {
|
|
13385
13385
|
unit: "week"
|
|
13386
13386
|
}) : (0, l.default)(w, b.length);
|
|
13387
13387
|
},
|
|
13388
13388
|
// ISO week of year
|
|
13389
|
-
I: function(
|
|
13390
|
-
var
|
|
13391
|
-
return b === "Io" ?
|
|
13389
|
+
I: function(m, b, x) {
|
|
13390
|
+
var y = (0, r.default)(m);
|
|
13391
|
+
return b === "Io" ? x.ordinalNumber(y, {
|
|
13392
13392
|
unit: "week"
|
|
13393
|
-
}) : (0, l.default)(
|
|
13393
|
+
}) : (0, l.default)(y, b.length);
|
|
13394
13394
|
},
|
|
13395
13395
|
// Day of the month
|
|
13396
|
-
d: function(
|
|
13397
|
-
return b === "do" ?
|
|
13396
|
+
d: function(m, b, x) {
|
|
13397
|
+
return b === "do" ? x.ordinalNumber(m.getUTCDate(), {
|
|
13398
13398
|
unit: "date"
|
|
13399
|
-
}) : c.default.d(
|
|
13399
|
+
}) : c.default.d(m, b);
|
|
13400
13400
|
},
|
|
13401
13401
|
// Day of year
|
|
13402
|
-
D: function(
|
|
13403
|
-
var
|
|
13404
|
-
return b === "Do" ?
|
|
13402
|
+
D: function(m, b, x) {
|
|
13403
|
+
var y = (0, i.default)(m);
|
|
13404
|
+
return b === "Do" ? x.ordinalNumber(y, {
|
|
13405
13405
|
unit: "dayOfYear"
|
|
13406
|
-
}) : (0, l.default)(
|
|
13406
|
+
}) : (0, l.default)(y, b.length);
|
|
13407
13407
|
},
|
|
13408
13408
|
// Day of week
|
|
13409
|
-
E: function(
|
|
13410
|
-
var
|
|
13409
|
+
E: function(m, b, x) {
|
|
13410
|
+
var y = m.getUTCDay();
|
|
13411
13411
|
switch (b) {
|
|
13412
13412
|
case "E":
|
|
13413
13413
|
case "EE":
|
|
13414
13414
|
case "EEE":
|
|
13415
|
-
return
|
|
13415
|
+
return x.day(y, {
|
|
13416
13416
|
width: "abbreviated",
|
|
13417
13417
|
context: "formatting"
|
|
13418
13418
|
});
|
|
13419
13419
|
case "EEEEE":
|
|
13420
|
-
return
|
|
13420
|
+
return x.day(y, {
|
|
13421
13421
|
width: "narrow",
|
|
13422
13422
|
context: "formatting"
|
|
13423
13423
|
});
|
|
13424
13424
|
case "EEEEEE":
|
|
13425
|
-
return
|
|
13425
|
+
return x.day(y, {
|
|
13426
13426
|
width: "short",
|
|
13427
13427
|
context: "formatting"
|
|
13428
13428
|
});
|
|
13429
13429
|
case "EEEE":
|
|
13430
13430
|
default:
|
|
13431
|
-
return
|
|
13431
|
+
return x.day(y, {
|
|
13432
13432
|
width: "wide",
|
|
13433
13433
|
context: "formatting"
|
|
13434
13434
|
});
|
|
13435
13435
|
}
|
|
13436
13436
|
},
|
|
13437
13437
|
// Local day of week
|
|
13438
|
-
e: function(
|
|
13439
|
-
var w =
|
|
13438
|
+
e: function(m, b, x, y) {
|
|
13439
|
+
var w = m.getUTCDay(), _ = (w - y.weekStartsOn + 8) % 7 || 7;
|
|
13440
13440
|
switch (b) {
|
|
13441
13441
|
case "e":
|
|
13442
13442
|
return String(_);
|
|
13443
13443
|
case "ee":
|
|
13444
13444
|
return (0, l.default)(_, 2);
|
|
13445
13445
|
case "eo":
|
|
13446
|
-
return
|
|
13446
|
+
return x.ordinalNumber(_, {
|
|
13447
13447
|
unit: "day"
|
|
13448
13448
|
});
|
|
13449
13449
|
case "eee":
|
|
13450
|
-
return
|
|
13450
|
+
return x.day(w, {
|
|
13451
13451
|
width: "abbreviated",
|
|
13452
13452
|
context: "formatting"
|
|
13453
13453
|
});
|
|
13454
13454
|
case "eeeee":
|
|
13455
|
-
return
|
|
13455
|
+
return x.day(w, {
|
|
13456
13456
|
width: "narrow",
|
|
13457
13457
|
context: "formatting"
|
|
13458
13458
|
});
|
|
13459
13459
|
case "eeeeee":
|
|
13460
|
-
return
|
|
13460
|
+
return x.day(w, {
|
|
13461
13461
|
width: "short",
|
|
13462
13462
|
context: "formatting"
|
|
13463
13463
|
});
|
|
13464
13464
|
case "eeee":
|
|
13465
13465
|
default:
|
|
13466
|
-
return
|
|
13466
|
+
return x.day(w, {
|
|
13467
13467
|
width: "wide",
|
|
13468
13468
|
context: "formatting"
|
|
13469
13469
|
});
|
|
13470
13470
|
}
|
|
13471
13471
|
},
|
|
13472
13472
|
// Stand-alone local day of week
|
|
13473
|
-
c: function(
|
|
13474
|
-
var w =
|
|
13473
|
+
c: function(m, b, x, y) {
|
|
13474
|
+
var w = m.getUTCDay(), _ = (w - y.weekStartsOn + 8) % 7 || 7;
|
|
13475
13475
|
switch (b) {
|
|
13476
13476
|
case "c":
|
|
13477
13477
|
return String(_);
|
|
13478
13478
|
case "cc":
|
|
13479
13479
|
return (0, l.default)(_, b.length);
|
|
13480
13480
|
case "co":
|
|
13481
|
-
return
|
|
13481
|
+
return x.ordinalNumber(_, {
|
|
13482
13482
|
unit: "day"
|
|
13483
13483
|
});
|
|
13484
13484
|
case "ccc":
|
|
13485
|
-
return
|
|
13485
|
+
return x.day(w, {
|
|
13486
13486
|
width: "abbreviated",
|
|
13487
13487
|
context: "standalone"
|
|
13488
13488
|
});
|
|
13489
13489
|
case "ccccc":
|
|
13490
|
-
return
|
|
13490
|
+
return x.day(w, {
|
|
13491
13491
|
width: "narrow",
|
|
13492
13492
|
context: "standalone"
|
|
13493
13493
|
});
|
|
13494
13494
|
case "cccccc":
|
|
13495
|
-
return
|
|
13495
|
+
return x.day(w, {
|
|
13496
13496
|
width: "short",
|
|
13497
13497
|
context: "standalone"
|
|
13498
13498
|
});
|
|
13499
13499
|
case "cccc":
|
|
13500
13500
|
default:
|
|
13501
|
-
return
|
|
13501
|
+
return x.day(w, {
|
|
13502
13502
|
width: "wide",
|
|
13503
13503
|
context: "standalone"
|
|
13504
13504
|
});
|
|
13505
13505
|
}
|
|
13506
13506
|
},
|
|
13507
13507
|
// ISO day of week
|
|
13508
|
-
i: function(
|
|
13509
|
-
var
|
|
13508
|
+
i: function(m, b, x) {
|
|
13509
|
+
var y = m.getUTCDay(), w = y === 0 ? 7 : y;
|
|
13510
13510
|
switch (b) {
|
|
13511
13511
|
case "i":
|
|
13512
13512
|
return String(w);
|
|
13513
13513
|
case "ii":
|
|
13514
13514
|
return (0, l.default)(w, b.length);
|
|
13515
13515
|
case "io":
|
|
13516
|
-
return
|
|
13516
|
+
return x.ordinalNumber(w, {
|
|
13517
13517
|
unit: "day"
|
|
13518
13518
|
});
|
|
13519
13519
|
case "iii":
|
|
13520
|
-
return
|
|
13520
|
+
return x.day(y, {
|
|
13521
13521
|
width: "abbreviated",
|
|
13522
13522
|
context: "formatting"
|
|
13523
13523
|
});
|
|
13524
13524
|
case "iiiii":
|
|
13525
|
-
return
|
|
13525
|
+
return x.day(y, {
|
|
13526
13526
|
width: "narrow",
|
|
13527
13527
|
context: "formatting"
|
|
13528
13528
|
});
|
|
13529
13529
|
case "iiiiii":
|
|
13530
|
-
return
|
|
13530
|
+
return x.day(y, {
|
|
13531
13531
|
width: "short",
|
|
13532
13532
|
context: "formatting"
|
|
13533
13533
|
});
|
|
13534
13534
|
case "iiii":
|
|
13535
13535
|
default:
|
|
13536
|
-
return
|
|
13536
|
+
return x.day(y, {
|
|
13537
13537
|
width: "wide",
|
|
13538
13538
|
context: "formatting"
|
|
13539
13539
|
});
|
|
13540
13540
|
}
|
|
13541
13541
|
},
|
|
13542
13542
|
// AM or PM
|
|
13543
|
-
a: function(
|
|
13544
|
-
var
|
|
13543
|
+
a: function(m, b, x) {
|
|
13544
|
+
var y = m.getUTCHours(), w = y / 12 >= 1 ? "pm" : "am";
|
|
13545
13545
|
switch (b) {
|
|
13546
13546
|
case "a":
|
|
13547
13547
|
case "aa":
|
|
13548
|
-
return
|
|
13548
|
+
return x.dayPeriod(w, {
|
|
13549
13549
|
width: "abbreviated",
|
|
13550
13550
|
context: "formatting"
|
|
13551
13551
|
});
|
|
13552
13552
|
case "aaa":
|
|
13553
|
-
return
|
|
13553
|
+
return x.dayPeriod(w, {
|
|
13554
13554
|
width: "abbreviated",
|
|
13555
13555
|
context: "formatting"
|
|
13556
13556
|
}).toLowerCase();
|
|
13557
13557
|
case "aaaaa":
|
|
13558
|
-
return
|
|
13558
|
+
return x.dayPeriod(w, {
|
|
13559
13559
|
width: "narrow",
|
|
13560
13560
|
context: "formatting"
|
|
13561
13561
|
});
|
|
13562
13562
|
case "aaaa":
|
|
13563
13563
|
default:
|
|
13564
|
-
return
|
|
13564
|
+
return x.dayPeriod(w, {
|
|
13565
13565
|
width: "wide",
|
|
13566
13566
|
context: "formatting"
|
|
13567
13567
|
});
|
|
13568
13568
|
}
|
|
13569
13569
|
},
|
|
13570
13570
|
// AM, PM, midnight, noon
|
|
13571
|
-
b: function(
|
|
13572
|
-
var
|
|
13573
|
-
switch (
|
|
13571
|
+
b: function(m, b, x) {
|
|
13572
|
+
var y = m.getUTCHours(), w;
|
|
13573
|
+
switch (y === 12 ? w = u.noon : y === 0 ? w = u.midnight : w = y / 12 >= 1 ? "pm" : "am", b) {
|
|
13574
13574
|
case "b":
|
|
13575
13575
|
case "bb":
|
|
13576
|
-
return
|
|
13576
|
+
return x.dayPeriod(w, {
|
|
13577
13577
|
width: "abbreviated",
|
|
13578
13578
|
context: "formatting"
|
|
13579
13579
|
});
|
|
13580
13580
|
case "bbb":
|
|
13581
|
-
return
|
|
13581
|
+
return x.dayPeriod(w, {
|
|
13582
13582
|
width: "abbreviated",
|
|
13583
13583
|
context: "formatting"
|
|
13584
13584
|
}).toLowerCase();
|
|
13585
13585
|
case "bbbbb":
|
|
13586
|
-
return
|
|
13586
|
+
return x.dayPeriod(w, {
|
|
13587
13587
|
width: "narrow",
|
|
13588
13588
|
context: "formatting"
|
|
13589
13589
|
});
|
|
13590
13590
|
case "bbbb":
|
|
13591
13591
|
default:
|
|
13592
|
-
return
|
|
13592
|
+
return x.dayPeriod(w, {
|
|
13593
13593
|
width: "wide",
|
|
13594
13594
|
context: "formatting"
|
|
13595
13595
|
});
|
|
13596
13596
|
}
|
|
13597
13597
|
},
|
|
13598
13598
|
// in the morning, in the afternoon, in the evening, at night
|
|
13599
|
-
B: function(
|
|
13600
|
-
var
|
|
13601
|
-
switch (
|
|
13599
|
+
B: function(m, b, x) {
|
|
13600
|
+
var y = m.getUTCHours(), w;
|
|
13601
|
+
switch (y >= 17 ? w = u.evening : y >= 12 ? w = u.afternoon : y >= 4 ? w = u.morning : w = u.night, b) {
|
|
13602
13602
|
case "B":
|
|
13603
13603
|
case "BB":
|
|
13604
13604
|
case "BBB":
|
|
13605
|
-
return
|
|
13605
|
+
return x.dayPeriod(w, {
|
|
13606
13606
|
width: "abbreviated",
|
|
13607
13607
|
context: "formatting"
|
|
13608
13608
|
});
|
|
13609
13609
|
case "BBBBB":
|
|
13610
|
-
return
|
|
13610
|
+
return x.dayPeriod(w, {
|
|
13611
13611
|
width: "narrow",
|
|
13612
13612
|
context: "formatting"
|
|
13613
13613
|
});
|
|
13614
13614
|
case "BBBB":
|
|
13615
13615
|
default:
|
|
13616
|
-
return
|
|
13616
|
+
return x.dayPeriod(w, {
|
|
13617
13617
|
width: "wide",
|
|
13618
13618
|
context: "formatting"
|
|
13619
13619
|
});
|
|
13620
13620
|
}
|
|
13621
13621
|
},
|
|
13622
13622
|
// Hour [1-12]
|
|
13623
|
-
h: function(
|
|
13623
|
+
h: function(m, b, x) {
|
|
13624
13624
|
if (b === "ho") {
|
|
13625
|
-
var
|
|
13626
|
-
return
|
|
13625
|
+
var y = m.getUTCHours() % 12;
|
|
13626
|
+
return y === 0 && (y = 12), x.ordinalNumber(y, {
|
|
13627
13627
|
unit: "hour"
|
|
13628
13628
|
});
|
|
13629
13629
|
}
|
|
13630
|
-
return c.default.h(
|
|
13630
|
+
return c.default.h(m, b);
|
|
13631
13631
|
},
|
|
13632
13632
|
// Hour [0-23]
|
|
13633
|
-
H: function(
|
|
13634
|
-
return b === "Ho" ?
|
|
13633
|
+
H: function(m, b, x) {
|
|
13634
|
+
return b === "Ho" ? x.ordinalNumber(m.getUTCHours(), {
|
|
13635
13635
|
unit: "hour"
|
|
13636
|
-
}) : c.default.H(
|
|
13636
|
+
}) : c.default.H(m, b);
|
|
13637
13637
|
},
|
|
13638
13638
|
// Hour [0-11]
|
|
13639
|
-
K: function(
|
|
13640
|
-
var
|
|
13641
|
-
return b === "Ko" ?
|
|
13639
|
+
K: function(m, b, x) {
|
|
13640
|
+
var y = m.getUTCHours() % 12;
|
|
13641
|
+
return b === "Ko" ? x.ordinalNumber(y, {
|
|
13642
13642
|
unit: "hour"
|
|
13643
|
-
}) : (0, l.default)(
|
|
13643
|
+
}) : (0, l.default)(y, b.length);
|
|
13644
13644
|
},
|
|
13645
13645
|
// Hour [1-24]
|
|
13646
|
-
k: function(
|
|
13647
|
-
var
|
|
13648
|
-
return
|
|
13646
|
+
k: function(m, b, x) {
|
|
13647
|
+
var y = m.getUTCHours();
|
|
13648
|
+
return y === 0 && (y = 24), b === "ko" ? x.ordinalNumber(y, {
|
|
13649
13649
|
unit: "hour"
|
|
13650
|
-
}) : (0, l.default)(
|
|
13650
|
+
}) : (0, l.default)(y, b.length);
|
|
13651
13651
|
},
|
|
13652
13652
|
// Minute
|
|
13653
|
-
m: function(
|
|
13654
|
-
return b === "mo" ?
|
|
13653
|
+
m: function(m, b, x) {
|
|
13654
|
+
return b === "mo" ? x.ordinalNumber(m.getUTCMinutes(), {
|
|
13655
13655
|
unit: "minute"
|
|
13656
|
-
}) : c.default.m(
|
|
13656
|
+
}) : c.default.m(m, b);
|
|
13657
13657
|
},
|
|
13658
13658
|
// Second
|
|
13659
|
-
s: function(
|
|
13660
|
-
return b === "so" ?
|
|
13659
|
+
s: function(m, b, x) {
|
|
13660
|
+
return b === "so" ? x.ordinalNumber(m.getUTCSeconds(), {
|
|
13661
13661
|
unit: "second"
|
|
13662
|
-
}) : c.default.s(
|
|
13662
|
+
}) : c.default.s(m, b);
|
|
13663
13663
|
},
|
|
13664
13664
|
// Fraction of second
|
|
13665
|
-
S: function(
|
|
13666
|
-
return c.default.S(
|
|
13665
|
+
S: function(m, b) {
|
|
13666
|
+
return c.default.S(m, b);
|
|
13667
13667
|
},
|
|
13668
13668
|
// Timezone (ISO-8601. If offset is 0, output is always `'Z'`)
|
|
13669
|
-
X: function(
|
|
13670
|
-
var w =
|
|
13669
|
+
X: function(m, b, x, y) {
|
|
13670
|
+
var w = y._originalDate || m, _ = w.getTimezoneOffset();
|
|
13671
13671
|
if (_ === 0)
|
|
13672
13672
|
return "Z";
|
|
13673
13673
|
switch (b) {
|
|
@@ -13683,8 +13683,8 @@ var Zy = Za.exports;
|
|
|
13683
13683
|
}
|
|
13684
13684
|
},
|
|
13685
13685
|
// Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)
|
|
13686
|
-
x: function(
|
|
13687
|
-
var w =
|
|
13686
|
+
x: function(m, b, x, y) {
|
|
13687
|
+
var w = y._originalDate || m, _ = w.getTimezoneOffset();
|
|
13688
13688
|
switch (b) {
|
|
13689
13689
|
case "x":
|
|
13690
13690
|
return f(_);
|
|
@@ -13698,8 +13698,8 @@ var Zy = Za.exports;
|
|
|
13698
13698
|
}
|
|
13699
13699
|
},
|
|
13700
13700
|
// Timezone (GMT)
|
|
13701
|
-
O: function(
|
|
13702
|
-
var w =
|
|
13701
|
+
O: function(m, b, x, y) {
|
|
13702
|
+
var w = y._originalDate || m, _ = w.getTimezoneOffset();
|
|
13703
13703
|
switch (b) {
|
|
13704
13704
|
case "O":
|
|
13705
13705
|
case "OO":
|
|
@@ -13711,8 +13711,8 @@ var Zy = Za.exports;
|
|
|
13711
13711
|
}
|
|
13712
13712
|
},
|
|
13713
13713
|
// Timezone (specific non-location)
|
|
13714
|
-
z: function(
|
|
13715
|
-
var w =
|
|
13714
|
+
z: function(m, b, x, y) {
|
|
13715
|
+
var w = y._originalDate || m, _ = w.getTimezoneOffset();
|
|
13716
13716
|
switch (b) {
|
|
13717
13717
|
case "z":
|
|
13718
13718
|
case "zz":
|
|
@@ -13724,33 +13724,33 @@ var Zy = Za.exports;
|
|
|
13724
13724
|
}
|
|
13725
13725
|
},
|
|
13726
13726
|
// Seconds timestamp
|
|
13727
|
-
t: function(
|
|
13728
|
-
var w =
|
|
13727
|
+
t: function(m, b, x, y) {
|
|
13728
|
+
var w = y._originalDate || m, _ = Math.floor(w.getTime() / 1e3);
|
|
13729
13729
|
return (0, l.default)(_, b.length);
|
|
13730
13730
|
},
|
|
13731
13731
|
// Milliseconds timestamp
|
|
13732
|
-
T: function(
|
|
13733
|
-
var w =
|
|
13732
|
+
T: function(m, b, x, y) {
|
|
13733
|
+
var w = y._originalDate || m, _ = w.getTime();
|
|
13734
13734
|
return (0, l.default)(_, b.length);
|
|
13735
13735
|
}
|
|
13736
13736
|
};
|
|
13737
|
-
function h(
|
|
13738
|
-
var b =
|
|
13737
|
+
function h(p, m) {
|
|
13738
|
+
var b = p > 0 ? "-" : "+", x = Math.abs(p), y = Math.floor(x / 60), w = x % 60;
|
|
13739
13739
|
if (w === 0)
|
|
13740
|
-
return b + String(
|
|
13741
|
-
var _ =
|
|
13742
|
-
return b + String(
|
|
13740
|
+
return b + String(y);
|
|
13741
|
+
var _ = m || "";
|
|
13742
|
+
return b + String(y) + _ + (0, l.default)(w, 2);
|
|
13743
13743
|
}
|
|
13744
|
-
function f(
|
|
13745
|
-
if (
|
|
13746
|
-
var b =
|
|
13747
|
-
return b + (0, l.default)(Math.abs(
|
|
13744
|
+
function f(p, m) {
|
|
13745
|
+
if (p % 60 === 0) {
|
|
13746
|
+
var b = p > 0 ? "-" : "+";
|
|
13747
|
+
return b + (0, l.default)(Math.abs(p) / 60, 2);
|
|
13748
13748
|
}
|
|
13749
|
-
return g(
|
|
13749
|
+
return g(p, m);
|
|
13750
13750
|
}
|
|
13751
|
-
function g(
|
|
13752
|
-
var b =
|
|
13753
|
-
return
|
|
13751
|
+
function g(p, m) {
|
|
13752
|
+
var b = m || "", x = p > 0 ? "-" : "+", y = Math.abs(p), w = (0, l.default)(Math.floor(y / 60), 2), _ = (0, l.default)(y % 60, 2);
|
|
13753
|
+
return x + w + b + _;
|
|
13754
13754
|
}
|
|
13755
13755
|
var v = d;
|
|
13756
13756
|
t.default = v, n.exports = t.default;
|
|
@@ -13960,7 +13960,7 @@ var ax = ns.exports, is = { exports: {} }, rs = { exports: {} };
|
|
|
13960
13960
|
})(rs, rs.exports);
|
|
13961
13961
|
var sx = rs.exports;
|
|
13962
13962
|
(function(n, t) {
|
|
13963
|
-
var e =
|
|
13963
|
+
var e = kt.default;
|
|
13964
13964
|
Object.defineProperty(t, "__esModule", {
|
|
13965
13965
|
value: !0
|
|
13966
13966
|
}), t.default = void 0;
|
|
@@ -14035,7 +14035,7 @@ var lx = as.exports, ss = { exports: {} }, os = { exports: {} };
|
|
|
14035
14035
|
})(os, os.exports);
|
|
14036
14036
|
var cx = os.exports;
|
|
14037
14037
|
(function(n, t) {
|
|
14038
|
-
var e =
|
|
14038
|
+
var e = kt.default;
|
|
14039
14039
|
Object.defineProperty(t, "__esModule", {
|
|
14040
14040
|
value: !0
|
|
14041
14041
|
}), t.default = void 0;
|
|
@@ -14119,17 +14119,17 @@ var cx = os.exports;
|
|
|
14119
14119
|
night: "at night"
|
|
14120
14120
|
}
|
|
14121
14121
|
}, u = function(g, v) {
|
|
14122
|
-
var
|
|
14123
|
-
if (
|
|
14124
|
-
switch (
|
|
14122
|
+
var p = Number(g), m = p % 100;
|
|
14123
|
+
if (m > 20 || m < 10)
|
|
14124
|
+
switch (m % 10) {
|
|
14125
14125
|
case 1:
|
|
14126
|
-
return
|
|
14126
|
+
return p + "st";
|
|
14127
14127
|
case 2:
|
|
14128
|
-
return
|
|
14128
|
+
return p + "nd";
|
|
14129
14129
|
case 3:
|
|
14130
|
-
return
|
|
14130
|
+
return p + "rd";
|
|
14131
14131
|
}
|
|
14132
|
-
return
|
|
14132
|
+
return p + "th";
|
|
14133
14133
|
}, d = {
|
|
14134
14134
|
ordinalNumber: u,
|
|
14135
14135
|
era: (0, i.default)({
|
|
@@ -14170,10 +14170,10 @@ var ux = ss.exports, ls = { exports: {} }, cs = { exports: {} };
|
|
|
14170
14170
|
var o = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, l = o.width, c = l && a.matchPatterns[l] || a.matchPatterns[a.defaultMatchWidth], u = s.match(c);
|
|
14171
14171
|
if (!u)
|
|
14172
14172
|
return null;
|
|
14173
|
-
var d = u[0], h = l && a.parsePatterns[l] || a.parsePatterns[a.defaultParseWidth], f = Array.isArray(h) ? r(h, function(
|
|
14174
|
-
return
|
|
14175
|
-
}) : i(h, function(
|
|
14176
|
-
return
|
|
14173
|
+
var d = u[0], h = l && a.parsePatterns[l] || a.parsePatterns[a.defaultParseWidth], f = Array.isArray(h) ? r(h, function(p) {
|
|
14174
|
+
return p.test(d);
|
|
14175
|
+
}) : i(h, function(p) {
|
|
14176
|
+
return p.test(d);
|
|
14177
14177
|
}), g;
|
|
14178
14178
|
g = a.valueCallback ? a.valueCallback(f) : f, g = o.valueCallback ? o.valueCallback(g) : g;
|
|
14179
14179
|
var v = s.slice(d.length);
|
|
@@ -14221,7 +14221,7 @@ var dx = cs.exports, us = { exports: {} };
|
|
|
14221
14221
|
})(us, us.exports);
|
|
14222
14222
|
var hx = us.exports;
|
|
14223
14223
|
(function(n, t) {
|
|
14224
|
-
var e =
|
|
14224
|
+
var e = kt.default;
|
|
14225
14225
|
Object.defineProperty(t, "__esModule", {
|
|
14226
14226
|
value: !0
|
|
14227
14227
|
}), t.default = void 0;
|
|
@@ -14255,7 +14255,7 @@ var hx = us.exports;
|
|
|
14255
14255
|
}, v = {
|
|
14256
14256
|
narrow: /^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,
|
|
14257
14257
|
any: /^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i
|
|
14258
|
-
},
|
|
14258
|
+
}, p = {
|
|
14259
14259
|
any: {
|
|
14260
14260
|
am: /^a/i,
|
|
14261
14261
|
pm: /^p/i,
|
|
@@ -14266,12 +14266,12 @@ var hx = us.exports;
|
|
|
14266
14266
|
evening: /evening/i,
|
|
14267
14267
|
night: /night/i
|
|
14268
14268
|
}
|
|
14269
|
-
},
|
|
14269
|
+
}, m = {
|
|
14270
14270
|
ordinalNumber: (0, r.default)({
|
|
14271
14271
|
matchPattern: a,
|
|
14272
14272
|
parsePattern: s,
|
|
14273
|
-
valueCallback: function(
|
|
14274
|
-
return parseInt(
|
|
14273
|
+
valueCallback: function(y) {
|
|
14274
|
+
return parseInt(y, 10);
|
|
14275
14275
|
}
|
|
14276
14276
|
}),
|
|
14277
14277
|
era: (0, i.default)({
|
|
@@ -14285,8 +14285,8 @@ var hx = us.exports;
|
|
|
14285
14285
|
defaultMatchWidth: "wide",
|
|
14286
14286
|
parsePatterns: u,
|
|
14287
14287
|
defaultParseWidth: "any",
|
|
14288
|
-
valueCallback: function(
|
|
14289
|
-
return
|
|
14288
|
+
valueCallback: function(y) {
|
|
14289
|
+
return y + 1;
|
|
14290
14290
|
}
|
|
14291
14291
|
}),
|
|
14292
14292
|
month: (0, i.default)({
|
|
@@ -14304,15 +14304,15 @@ var hx = us.exports;
|
|
|
14304
14304
|
dayPeriod: (0, i.default)({
|
|
14305
14305
|
matchPatterns: v,
|
|
14306
14306
|
defaultMatchWidth: "any",
|
|
14307
|
-
parsePatterns:
|
|
14307
|
+
parsePatterns: p,
|
|
14308
14308
|
defaultParseWidth: "any"
|
|
14309
14309
|
})
|
|
14310
|
-
}, b =
|
|
14310
|
+
}, b = m;
|
|
14311
14311
|
t.default = b, n.exports = t.default;
|
|
14312
14312
|
})(ls, ls.exports);
|
|
14313
14313
|
var fx = ls.exports;
|
|
14314
14314
|
(function(n, t) {
|
|
14315
|
-
var e =
|
|
14315
|
+
var e = kt.default;
|
|
14316
14316
|
Object.defineProperty(t, "__esModule", {
|
|
14317
14317
|
value: !0
|
|
14318
14318
|
}), t.default = void 0;
|
|
@@ -14332,7 +14332,7 @@ var fx = ls.exports;
|
|
|
14332
14332
|
})(es, es.exports);
|
|
14333
14333
|
var gx = es.exports;
|
|
14334
14334
|
(function(n, t) {
|
|
14335
|
-
var e =
|
|
14335
|
+
var e = kt.default;
|
|
14336
14336
|
Object.defineProperty(t, "__esModule", {
|
|
14337
14337
|
value: !0
|
|
14338
14338
|
}), t.default = void 0;
|
|
@@ -14341,12 +14341,12 @@ var gx = es.exports;
|
|
|
14341
14341
|
})(ts, ts.exports);
|
|
14342
14342
|
var px = ts.exports;
|
|
14343
14343
|
(function(n, t) {
|
|
14344
|
-
var e =
|
|
14344
|
+
var e = kt.default;
|
|
14345
14345
|
Object.defineProperty(t, "__esModule", {
|
|
14346
14346
|
value: !0
|
|
14347
|
-
}), t.default =
|
|
14348
|
-
var i = e(Uy), r = e($y), a = e(me), s = e(Qy), o = e(Jy), l = e(Sd), c = _i, u = e(un), d = e(Vt), h = dn, f = e(px), g = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, v = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,
|
|
14349
|
-
function
|
|
14347
|
+
}), t.default = x;
|
|
14348
|
+
var i = e(Uy), r = e($y), a = e(me), s = e(Qy), o = e(Jy), l = e(Sd), c = _i, u = e(un), d = e(Vt), h = dn, f = e(px), g = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, v = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, p = /^'([^]*?)'?$/, m = /''/g, b = /[a-zA-Z]/;
|
|
14349
|
+
function x(w, _, M) {
|
|
14350
14350
|
var T, D, O, R, P, Q, _t, N, z, G, Lt, k, L, F, B, V, q, yt;
|
|
14351
14351
|
(0, d.default)(2, arguments);
|
|
14352
14352
|
var pt = String(_), it = (0, h.getDefaultOptions)(), ht = (T = (D = M == null ? void 0 : M.locale) !== null && D !== void 0 ? D : it.locale) !== null && T !== void 0 ? T : f.default, et = (0, u.default)((O = (R = (P = (Q = M == null ? void 0 : M.firstWeekContainsDate) !== null && Q !== void 0 ? Q : M == null || (_t = M.locale) === null || _t === void 0 || (N = _t.options) === null || N === void 0 ? void 0 : N.firstWeekContainsDate) !== null && P !== void 0 ? P : it.firstWeekContainsDate) !== null && R !== void 0 ? R : (z = it.locale) === null || z === void 0 || (G = z.options) === null || G === void 0 ? void 0 : G.firstWeekContainsDate) !== null && O !== void 0 ? O : 1);
|
|
@@ -14379,7 +14379,7 @@ var px = ts.exports;
|
|
|
14379
14379
|
return "'";
|
|
14380
14380
|
var Oe = Zt[0];
|
|
14381
14381
|
if (Oe === "'")
|
|
14382
|
-
return
|
|
14382
|
+
return y(Zt);
|
|
14383
14383
|
var Pi = s.default[Oe];
|
|
14384
14384
|
if (Pi)
|
|
14385
14385
|
return !(M != null && M.useAdditionalWeekYearTokens) && (0, c.isProtectedWeekYearToken)(Zt) && (0, c.throwProtectedError)(Zt, _, String(w)), !(M != null && M.useAdditionalDayOfYearTokens) && (0, c.isProtectedDayOfYearToken)(Zt) && (0, c.throwProtectedError)(Zt, _, String(w)), Pi(Ci, Zt, ht.localize, Rn);
|
|
@@ -14389,9 +14389,9 @@ var px = ts.exports;
|
|
|
14389
14389
|
}).join("");
|
|
14390
14390
|
return Oi;
|
|
14391
14391
|
}
|
|
14392
|
-
function
|
|
14393
|
-
var _ = w.match(
|
|
14394
|
-
return _ ? _[1].replace(
|
|
14392
|
+
function y(w) {
|
|
14393
|
+
var _ = w.match(p);
|
|
14394
|
+
return _ ? _[1].replace(m, "'") : w;
|
|
14395
14395
|
}
|
|
14396
14396
|
n.exports = t.default;
|
|
14397
14397
|
})(Aa, Aa.exports);
|
|
@@ -14848,7 +14848,7 @@ var hs = { exports: {} }, fs = { exports: {} };
|
|
|
14848
14848
|
})(fs, fs.exports);
|
|
14849
14849
|
var jx = fs.exports;
|
|
14850
14850
|
(function(n, t) {
|
|
14851
|
-
var e =
|
|
14851
|
+
var e = kt.default;
|
|
14852
14852
|
Object.defineProperty(t, "__esModule", {
|
|
14853
14853
|
value: !0
|
|
14854
14854
|
}), t.default = r;
|
|
@@ -14945,6 +14945,7 @@ function nw(n) {
|
|
|
14945
14945
|
var i, r, a, s, o, l, c, u;
|
|
14946
14946
|
return {
|
|
14947
14947
|
indexAxis: n.indexAxis,
|
|
14948
|
+
skipNull: !0,
|
|
14948
14949
|
scales: {
|
|
14949
14950
|
x: {
|
|
14950
14951
|
border: {
|
|
@@ -15090,9 +15091,9 @@ var Pd = { exports: {} };
|
|
|
15090
15091
|
var aw = Pd.exports;
|
|
15091
15092
|
const xn = /* @__PURE__ */ wi(aw);
|
|
15092
15093
|
function sw(n, t, e) {
|
|
15093
|
-
const { i18n: i } =
|
|
15094
|
+
const { i18n: i } = St.useI18n();
|
|
15094
15095
|
return { legendValues: A(() => n.value.datasets.reduce((a, s) => {
|
|
15095
|
-
const o = s.total ? s.total : s.data.reduce((c, u) => c + (typeof u == "number" ? Number(u) || 0 : Number(u.y) || 0), 0);
|
|
15096
|
+
const o = s.total ? s.total : s.data.reduce((c, u) => c + (typeof u == "number" ? Number(u) || 0 : Number(u && u.y) || 0), 0);
|
|
15096
15097
|
let l;
|
|
15097
15098
|
if (e.value === "bytes")
|
|
15098
15099
|
l = isNaN(o) ? "0" : Ks(o);
|
|
@@ -15882,13 +15883,13 @@ function Qw(n) {
|
|
|
15882
15883
|
if (!l.length || n.tooltipState.locked)
|
|
15883
15884
|
return !1;
|
|
15884
15885
|
const u = this.chart.canvas.getBoundingClientRect(), d = n.tooltipState.width || this.width, h = n.tooltipState.height || this.height, f = u.width / 2, g = u.height / 2, v = ro(c, d, f);
|
|
15885
|
-
let
|
|
15886
|
-
const
|
|
15887
|
-
return h > u.height && (
|
|
15886
|
+
let p = Yy(c, h, g);
|
|
15887
|
+
const m = c.y < g ? "top" : "bottom", b = c.x < f ? "left" : "center";
|
|
15888
|
+
return h > u.height && (p = 0), {
|
|
15888
15889
|
x: v,
|
|
15889
|
-
y:
|
|
15890
|
+
y: p,
|
|
15890
15891
|
xAlign: b,
|
|
15891
|
-
yAlign:
|
|
15892
|
+
yAlign: m
|
|
15892
15893
|
};
|
|
15893
15894
|
};
|
|
15894
15895
|
const r = A(() => {
|
|
@@ -15969,40 +15970,59 @@ function Qw(n) {
|
|
|
15969
15970
|
}))
|
|
15970
15971
|
};
|
|
15971
15972
|
}
|
|
15972
|
-
function Jw(n
|
|
15973
|
-
const {
|
|
15973
|
+
function Jw(n) {
|
|
15974
|
+
const {
|
|
15975
|
+
isMultiMetric: t,
|
|
15976
|
+
hasDimensions: e,
|
|
15977
|
+
metricNames: i,
|
|
15978
|
+
barSegmentLabels: r,
|
|
15979
|
+
pivotRecords: a,
|
|
15980
|
+
rowLabels: s,
|
|
15981
|
+
colorPalette: o
|
|
15982
|
+
} = n, { i18n: l } = St.useI18n();
|
|
15983
|
+
return t ? i.map((c) => ({
|
|
15984
|
+
// @ts-ignore - dynamic i18n key
|
|
15985
|
+
label: l && l.te(`chartLabels.${c}`) && l.t(`chartLabels.${c}`) || c,
|
|
15986
|
+
backgroundColor: si(i.indexOf(c), ce),
|
|
15987
|
+
data: s.map((u, d) => e ? a[`${u},${c}`] || 0 : a[`${d},${c}`] || null)
|
|
15988
|
+
})) : Array.from(r).flatMap((c, u) => {
|
|
15989
|
+
if (!c)
|
|
15990
|
+
return [];
|
|
15991
|
+
const d = Array.isArray(o) ? si(u, o) : o[c] || si(u);
|
|
15992
|
+
return {
|
|
15993
|
+
// @ts-ignore - dynamic i18n key
|
|
15994
|
+
label: l && l.te(`chartLabels.${c}`) && l.t(`chartLabels.${c}`) || c,
|
|
15995
|
+
backgroundColor: d,
|
|
15996
|
+
data: s.map((h) => a[`${h},${c}`] || null)
|
|
15997
|
+
};
|
|
15998
|
+
});
|
|
15999
|
+
}
|
|
16000
|
+
function t_(n, t) {
|
|
16001
|
+
const { i18n: e } = St.useI18n();
|
|
15974
16002
|
return A(() => {
|
|
15975
16003
|
try {
|
|
15976
16004
|
if (t.value && "meta" in t.value && "records" in t.value) {
|
|
15977
16005
|
const r = t.value.records, { dimensions: a, metricNames: s } = t.value.meta, o = a && Object.keys(a), l = s && s.length > 1, c = a && o && (o.length === 1 ? o[0] !== "Organization" : o.length > 0);
|
|
15978
16006
|
if (!r.length || !s)
|
|
15979
16007
|
return { datasets: [], labels: [] };
|
|
15980
|
-
const u = c && o || s, d = u[0], h = u.length > 1 ? u[1] : u[0], f = Object.fromEntries(l ? r.flatMap((
|
|
15981
|
-
const
|
|
16008
|
+
const u = c && o || s, d = u[0], h = u.length > 1 ? u[1] : u[0], f = Object.fromEntries(l ? r.flatMap((m) => s.map((b, x) => {
|
|
16009
|
+
const y = m.event[d], w = c ? `${y},${b}` : `${x},${b}`, _ = m.event[b];
|
|
15982
16010
|
return [w, _];
|
|
15983
|
-
})) : r.map((
|
|
15984
|
-
const b = c ? `${
|
|
15985
|
-
return [b,
|
|
16011
|
+
})) : r.map((m) => {
|
|
16012
|
+
const b = c ? `${m.event[d]},${m.event[h]}` : `${d},${h}`, x = m.event[s[0]];
|
|
16013
|
+
return [b, x];
|
|
15986
16014
|
})), g = c && a[d] || s, v = c && a[h] || s;
|
|
15987
16015
|
return !g || !v ? { labels: [], datasets: [] } : {
|
|
15988
|
-
labels: c ? a[d].map((
|
|
15989
|
-
datasets:
|
|
15990
|
-
|
|
15991
|
-
|
|
15992
|
-
|
|
15993
|
-
|
|
15994
|
-
|
|
15995
|
-
|
|
15996
|
-
|
|
15997
|
-
|
|
15998
|
-
U(y) && (y = ce);
|
|
15999
|
-
const x = {}, w = Array.isArray(y) ? si(b, y) : y[p] || si(b);
|
|
16000
|
-
return x[p] = w, {
|
|
16001
|
-
// @ts-ignore - dynamic i18n key
|
|
16002
|
-
label: e && e.te(`chartLabels.${p}`) && e.t(`chartLabels.${p}`) || p,
|
|
16003
|
-
backgroundColor: w,
|
|
16004
|
-
data: g.map((_) => f[`${_},${p}`] || 0)
|
|
16005
|
-
};
|
|
16016
|
+
labels: c ? a[d].map((m) => e && e.te(`chartLabels.${m}`) && e.t(`chartLabels.${m}`) || m) : s.map((m) => e && e.te(`chartLabels.${m}`) && e.t(`chartLabels.${m}`) || m),
|
|
16017
|
+
datasets: Jw({
|
|
16018
|
+
isMultiMetric: l,
|
|
16019
|
+
hasDimensions: c,
|
|
16020
|
+
metricNames: s,
|
|
16021
|
+
dimensionFieldNames: u,
|
|
16022
|
+
barSegmentLabels: v,
|
|
16023
|
+
pivotRecords: f,
|
|
16024
|
+
rowLabels: g,
|
|
16025
|
+
colorPalette: n.colorPalette || ce
|
|
16006
16026
|
})
|
|
16007
16027
|
};
|
|
16008
16028
|
}
|
|
@@ -16012,7 +16032,7 @@ function Jw(n, t) {
|
|
|
16012
16032
|
return { labels: [], datasets: [] };
|
|
16013
16033
|
});
|
|
16014
16034
|
}
|
|
16015
|
-
const
|
|
16035
|
+
const e_ = (n, t, e = 1) => Array(Math.ceil((t - n) / e)).fill(n).map((i, r) => i + r * e), n_ = (n) => {
|
|
16016
16036
|
if (typeof n == "string") {
|
|
16017
16037
|
const t = +n;
|
|
16018
16038
|
if (t)
|
|
@@ -16026,15 +16046,15 @@ const t_ = (n, t, e = 1) => Array(Math.ceil((t - n) / e)).fill(n).map((i, r) =>
|
|
|
16026
16046
|
}
|
|
16027
16047
|
}
|
|
16028
16048
|
return n;
|
|
16029
|
-
},
|
|
16049
|
+
}, i_ = (n, t, e, i, r) => {
|
|
16030
16050
|
const s = Math.max(
|
|
16031
16051
|
t - 6e4,
|
|
16032
16052
|
Math.max(...(r || []).map((c) => new Date(c.timestamp).valueOf()))
|
|
16033
16053
|
), o = Math.floor((n - i) / e) * e + i, l = Math.floor((s - i) / e) * e + i + e;
|
|
16034
|
-
return
|
|
16054
|
+
return e_(o, l, e);
|
|
16035
16055
|
};
|
|
16036
|
-
function
|
|
16037
|
-
const { i18n: e } =
|
|
16056
|
+
function r_(n, t) {
|
|
16057
|
+
const { i18n: e } = St.useI18n();
|
|
16038
16058
|
return A(() => {
|
|
16039
16059
|
try {
|
|
16040
16060
|
if (t.value && "meta" in t.value && "records" in t.value) {
|
|
@@ -16046,23 +16066,23 @@ function i_(n, t) {
|
|
|
16046
16066
|
return console.error("Invalid step value:", h), { datasets: [] };
|
|
16047
16067
|
if (!r.length)
|
|
16048
16068
|
return { datasets: [] };
|
|
16049
|
-
const f =
|
|
16069
|
+
const f = n_(o), g = i_(o, l, h, f, r), v = /* @__PURE__ */ new Set(), p = r != null && r.length ? r.reduce((y, w) => {
|
|
16050
16070
|
const _ = new Date(w.timestamp).valueOf(), M = w.event;
|
|
16051
16071
|
for (const T of s)
|
|
16052
|
-
v.add(T), _ in
|
|
16072
|
+
v.add(T), _ in y || (y[_] = {}), T in y[_] || (y[_][T] = {});
|
|
16053
16073
|
for (const T of s)
|
|
16054
16074
|
d.forEach((D) => {
|
|
16055
|
-
M[u] === D || T === D ? (
|
|
16075
|
+
M[u] === D || T === D ? (y[_][T] || (y[_][T] = {}), y[_][T][D] = Math.round(Number(M[T]) * 1e3) / 1e3) : c.length || (y[_][T] || (y[_][T] = {}), y[_][T][D] = Math.round(Number(M[D]) * 1e3) / 1e3);
|
|
16056
16076
|
});
|
|
16057
|
-
return
|
|
16058
|
-
}, {}) : {},
|
|
16059
|
-
const M = g.map((P) => P in
|
|
16077
|
+
return y;
|
|
16078
|
+
}, {}) : {}, m = s.length === 1 ? s.flatMap((y) => d.map((w) => [y, w])) : d.map((y) => [y, y]), b = {}, x = [...m].map(([y, w], _) => {
|
|
16079
|
+
const M = g.map((P) => P in p && y in p[P] ? { x: P, y: p[P][y][w] || 0 } : { x: P, y: 0 });
|
|
16060
16080
|
let { colorPalette: T, fill: D } = n;
|
|
16061
16081
|
U(T) && (T = ce);
|
|
16062
16082
|
const O = Array.isArray(T) ? si(_, T) : T[w] || si(_), R = yr(O, 50);
|
|
16063
16083
|
return b[w] = O, {
|
|
16064
16084
|
rawDimension: w,
|
|
16065
|
-
rawMetric:
|
|
16085
|
+
rawMetric: y,
|
|
16066
16086
|
// @ts-ignore - dynamic i18n key
|
|
16067
16087
|
label: e && e.te(`chartLabels.${w}`) && e.t(`chartLabels.${w}`) || w,
|
|
16068
16088
|
borderColor: R,
|
|
@@ -16073,8 +16093,8 @@ function i_(n, t) {
|
|
|
16073
16093
|
fill: D
|
|
16074
16094
|
};
|
|
16075
16095
|
});
|
|
16076
|
-
return
|
|
16077
|
-
datasets:
|
|
16096
|
+
return x.sort((y, w) => Number(y.total) < Number(w.total) ? -1 : 1), {
|
|
16097
|
+
datasets: x,
|
|
16078
16098
|
colorMap: b
|
|
16079
16099
|
};
|
|
16080
16100
|
}
|
|
@@ -16084,7 +16104,7 @@ function i_(n, t) {
|
|
|
16084
16104
|
return { labels: [], datasets: [] };
|
|
16085
16105
|
});
|
|
16086
16106
|
}
|
|
16087
|
-
const
|
|
16107
|
+
const a_ = (n, t) => {
|
|
16088
16108
|
ee(
|
|
16089
16109
|
[n, t],
|
|
16090
16110
|
(e, i, r) => {
|
|
@@ -16099,16 +16119,16 @@ const r_ = (n, t) => {
|
|
|
16099
16119
|
},
|
|
16100
16120
|
{ immediate: !0 }
|
|
16101
16121
|
);
|
|
16102
|
-
},
|
|
16122
|
+
}, St = {
|
|
16103
16123
|
useBarChartOptions: nw,
|
|
16104
16124
|
useChartJSCommon: rw,
|
|
16105
16125
|
useChartLegendValues: sw,
|
|
16106
|
-
useExploreResultToDatasets:
|
|
16107
|
-
useExploreResultToTimeDataset:
|
|
16126
|
+
useExploreResultToDatasets: t_,
|
|
16127
|
+
useExploreResultToTimeDataset: r_,
|
|
16108
16128
|
useDoughnutChartOptions: ow,
|
|
16109
16129
|
useLinechartOptions: Qw,
|
|
16110
16130
|
useI18n: Th,
|
|
16111
|
-
useReportChartDataForSynthetics:
|
|
16131
|
+
useReportChartDataForSynthetics: a_
|
|
16112
16132
|
};
|
|
16113
16133
|
/*!
|
|
16114
16134
|
* chartjs-plugin-annotation v3.0.1
|
|
@@ -16135,7 +16155,7 @@ const Dc = {
|
|
|
16135
16155
|
* @return {AnnotationElement[]} - elements that are found (only 1 element)
|
|
16136
16156
|
*/
|
|
16137
16157
|
nearest(n, t, e) {
|
|
16138
|
-
return
|
|
16158
|
+
return l_(n, t, e);
|
|
16139
16159
|
},
|
|
16140
16160
|
/**
|
|
16141
16161
|
* x mode returns the elements that hit-test at the current x coordinate
|
|
@@ -16162,29 +16182,29 @@ const Dc = {
|
|
|
16162
16182
|
function uo(n, t, e) {
|
|
16163
16183
|
return (Dc.modes[e.mode] || Dc.modes.nearest)(n, t, e);
|
|
16164
16184
|
}
|
|
16165
|
-
function
|
|
16185
|
+
function s_(n, t, e) {
|
|
16166
16186
|
return e !== "x" && e !== "y" ? n.inRange(t.x, t.y, "x", !0) || n.inRange(t.x, t.y, "y", !0) : n.inRange(t.x, t.y, e, !0);
|
|
16167
16187
|
}
|
|
16168
|
-
function
|
|
16188
|
+
function o_(n, t, e) {
|
|
16169
16189
|
return e === "x" ? { x: n.x, y: t.y } : e === "y" ? { x: t.x, y: n.y } : t;
|
|
16170
16190
|
}
|
|
16171
16191
|
function nr(n, t, e) {
|
|
16172
|
-
return n.visibleElements.filter((i) => e.intersect ? i.inRange(t.x, t.y) :
|
|
16192
|
+
return n.visibleElements.filter((i) => e.intersect ? i.inRange(t.x, t.y) : s_(i, t, e.axis));
|
|
16173
16193
|
}
|
|
16174
|
-
function
|
|
16194
|
+
function l_(n, t, e) {
|
|
16175
16195
|
let i = Number.POSITIVE_INFINITY;
|
|
16176
16196
|
return nr(n, t, e).reduce((r, a) => {
|
|
16177
|
-
const s = a.getCenterPoint(), o =
|
|
16197
|
+
const s = a.getCenterPoint(), o = o_(t, s, e.axis), l = _n(t, o);
|
|
16178
16198
|
return l < i ? (r = [a], i = l) : l === i && r.push(a), r;
|
|
16179
16199
|
}, []).sort((r, a) => r._index - a._index).slice(0, 1);
|
|
16180
16200
|
}
|
|
16181
|
-
const
|
|
16182
|
-
function
|
|
16201
|
+
const c_ = (n, t) => t > n || n.length > t.length && n.slice(0, t.length) === t, en = 1e-3, Lr = (n, t, e) => Math.min(e, Math.max(t, n));
|
|
16202
|
+
function u_(n, t, e) {
|
|
16183
16203
|
for (const i of Object.keys(n))
|
|
16184
16204
|
n[i] = Lr(n[i], t, e);
|
|
16185
16205
|
return n;
|
|
16186
16206
|
}
|
|
16187
|
-
function
|
|
16207
|
+
function d_(n, t, e, i) {
|
|
16188
16208
|
if (!n || !t || e <= 0)
|
|
16189
16209
|
return !1;
|
|
16190
16210
|
const r = i / 2;
|
|
@@ -16198,14 +16218,14 @@ function Pn(n, t) {
|
|
|
16198
16218
|
const { centerX: e, centerY: i } = n.getProps(["centerX", "centerY"], t);
|
|
16199
16219
|
return { x: e, y: i };
|
|
16200
16220
|
}
|
|
16201
|
-
function
|
|
16221
|
+
function h_(n, t, e, i = !0) {
|
|
16202
16222
|
const r = e.split(".");
|
|
16203
16223
|
let a = 0;
|
|
16204
16224
|
for (const s of t.split(".")) {
|
|
16205
16225
|
const o = r[a++];
|
|
16206
16226
|
if (parseInt(s, 10) < parseInt(o, 10))
|
|
16207
16227
|
break;
|
|
16208
|
-
if (
|
|
16228
|
+
if (c_(o, s)) {
|
|
16209
16229
|
if (i)
|
|
16210
16230
|
throw new Error(`${n} v${e} is not supported. v${t} or newer is required.`);
|
|
16211
16231
|
return !1;
|
|
@@ -16213,7 +16233,7 @@ function d_(n, t, e, i = !0) {
|
|
|
16213
16233
|
}
|
|
16214
16234
|
return !0;
|
|
16215
16235
|
}
|
|
16216
|
-
const Nd = (n) => typeof n == "string" && n.endsWith("%"), Fd = (n) => parseFloat(n) / 100, Yd = (n) => Lr(Fd(n), 0, 1), Vi = (n, t) => ({ x: n, y: t, x2: n, y2: t, width: 0, height: 0 }),
|
|
16236
|
+
const Nd = (n) => typeof n == "string" && n.endsWith("%"), Fd = (n) => parseFloat(n) / 100, Yd = (n) => Lr(Fd(n), 0, 1), Vi = (n, t) => ({ x: n, y: t, x2: n, y2: t, width: 0, height: 0 }), f_ = {
|
|
16217
16237
|
box: (n) => Vi(n.centerX, n.centerY),
|
|
16218
16238
|
ellipse: (n) => ({ centerX: n.centerX, centerY: n.centerX, radius: 0, width: 0, height: 0 }),
|
|
16219
16239
|
label: (n) => Vi(n.centerX, n.centerY),
|
|
@@ -16227,7 +16247,7 @@ function ho(n, t) {
|
|
|
16227
16247
|
function Ve(n, t, e = !0) {
|
|
16228
16248
|
return typeof t == "number" ? t : Nd(t) ? (e ? Yd(t) : Fd(t)) * n : n;
|
|
16229
16249
|
}
|
|
16230
|
-
function
|
|
16250
|
+
function g_(n, t) {
|
|
16231
16251
|
const { x: e, width: i } = n, r = t.textAlign;
|
|
16232
16252
|
return r === "center" ? e + i / 2 : r === "end" || r === "right" ? e + i : e;
|
|
16233
16253
|
}
|
|
@@ -16250,7 +16270,7 @@ function Mi(n, t, e) {
|
|
|
16250
16270
|
return zd(t, e);
|
|
16251
16271
|
} else
|
|
16252
16272
|
return;
|
|
16253
|
-
return
|
|
16273
|
+
return p_(n, t, e);
|
|
16254
16274
|
}
|
|
16255
16275
|
function Ud(n, t, e) {
|
|
16256
16276
|
let i = !1;
|
|
@@ -16260,16 +16280,16 @@ function Ud(n, t, e) {
|
|
|
16260
16280
|
}
|
|
16261
16281
|
function zd(n, t) {
|
|
16262
16282
|
const e = t.type || "line";
|
|
16263
|
-
return
|
|
16283
|
+
return f_[e](n);
|
|
16264
16284
|
}
|
|
16265
|
-
function
|
|
16285
|
+
function p_(n, t, e) {
|
|
16266
16286
|
const i = lt(e.init, [{ chart: n, properties: t, options: e }]);
|
|
16267
16287
|
if (i === !0)
|
|
16268
16288
|
return zd(t, e);
|
|
16269
16289
|
if (j(i))
|
|
16270
16290
|
return i;
|
|
16271
16291
|
}
|
|
16272
|
-
const ca = /* @__PURE__ */ new Map(),
|
|
16292
|
+
const ca = /* @__PURE__ */ new Map(), m_ = (n) => isNaN(n) || n <= 0, v_ = (n) => n.reduce(function(t, e) {
|
|
16273
16293
|
return t += e.string, t;
|
|
16274
16294
|
}, "");
|
|
16275
16295
|
function Ir(n) {
|
|
@@ -16295,8 +16315,8 @@ function po(n, t) {
|
|
|
16295
16315
|
width: Ve(e.width, t.width),
|
|
16296
16316
|
height: Ve(e.height, t.height)
|
|
16297
16317
|
};
|
|
16298
|
-
const i = t.font, r = nt(i) ? i.map((l) => vt(l)) : [vt(i)], a = t.textStrokeWidth, s = nt(e) ? e : [e], o = s.join() +
|
|
16299
|
-
return ca.has(o) || ca.set(o,
|
|
16318
|
+
const i = t.font, r = nt(i) ? i.map((l) => vt(l)) : [vt(i)], a = t.textStrokeWidth, s = nt(e) ? e : [e], o = s.join() + v_(r) + a + (n._measureText ? "-spriting" : "");
|
|
16319
|
+
return ca.has(o) || ca.set(o, __(n, s, r, a)), ca.get(o);
|
|
16300
16320
|
}
|
|
16301
16321
|
function Hd(n, t, e) {
|
|
16302
16322
|
const { x: i, y: r, width: a, height: s } = t;
|
|
@@ -16307,32 +16327,32 @@ function Hd(n, t, e) {
|
|
|
16307
16327
|
y: r,
|
|
16308
16328
|
w: a,
|
|
16309
16329
|
h: s,
|
|
16310
|
-
radius:
|
|
16330
|
+
radius: u_(ze(e.borderRadius), 0, Math.min(a, s) / 2)
|
|
16311
16331
|
}), n.closePath(), n.fill(), o && (n.shadowColor = e.borderShadowColor, n.stroke()), n.restore();
|
|
16312
16332
|
}
|
|
16313
|
-
function
|
|
16333
|
+
function b_(n, t, e) {
|
|
16314
16334
|
const i = e.content;
|
|
16315
16335
|
if (Ir(i)) {
|
|
16316
|
-
n.save(), n.globalAlpha =
|
|
16336
|
+
n.save(), n.globalAlpha = D_(e.opacity, i.style.opacity), n.drawImage(i, t.x, t.y, t.width, t.height), n.restore();
|
|
16317
16337
|
return;
|
|
16318
16338
|
}
|
|
16319
|
-
const r = nt(i) ? i : [i], a = e.font, s = nt(a) ? a.map((d) => vt(d)) : [vt(a)], o = e.color, l = nt(o) ? o : [o], c =
|
|
16320
|
-
n.save(), n.textBaseline = "middle", n.textAlign = e.textAlign,
|
|
16339
|
+
const r = nt(i) ? i : [i], a = e.font, s = nt(a) ? a.map((d) => vt(d)) : [vt(a)], o = e.color, l = nt(o) ? o : [o], c = g_(t, e), u = t.y + e.textStrokeWidth / 2;
|
|
16340
|
+
n.save(), n.textBaseline = "middle", n.textAlign = e.textAlign, y_(n, e) && M_(n, { x: c, y: u }, r, s), T_(n, { x: c, y: u }, r, { fonts: s, colors: l }), n.restore();
|
|
16321
16341
|
}
|
|
16322
|
-
function
|
|
16342
|
+
function y_(n, t) {
|
|
16323
16343
|
if (t.textStrokeWidth > 0)
|
|
16324
16344
|
return n.lineJoin = "round", n.miterLimit = 2, n.lineWidth = t.textStrokeWidth, n.strokeStyle = t.textStrokeColor, !0;
|
|
16325
16345
|
}
|
|
16326
|
-
function
|
|
16346
|
+
function x_(n, t, e, i) {
|
|
16327
16347
|
const { radius: r, options: a } = t, s = a.pointStyle, o = a.rotation;
|
|
16328
16348
|
let l = (o || 0) * Fs;
|
|
16329
16349
|
if (Ir(s)) {
|
|
16330
16350
|
n.save(), n.translate(e, i), n.rotate(l), n.drawImage(s, -s.width / 2, -s.height / 2, s.width, s.height), n.restore();
|
|
16331
16351
|
return;
|
|
16332
16352
|
}
|
|
16333
|
-
|
|
16353
|
+
m_(r) || w_(n, { x: e, y: i, radius: r, rotation: o, style: s, rad: l });
|
|
16334
16354
|
}
|
|
16335
|
-
function
|
|
16355
|
+
function w_(n, { x: t, y: e, radius: i, rotation: r, style: a, rad: s }) {
|
|
16336
16356
|
let o, l, c, u;
|
|
16337
16357
|
switch (n.beginPath(), a) {
|
|
16338
16358
|
default:
|
|
@@ -16370,7 +16390,7 @@ function x_(n, { x: t, y: e, radius: i, rotation: r, style: a, rad: s }) {
|
|
|
16370
16390
|
}
|
|
16371
16391
|
n.fill();
|
|
16372
16392
|
}
|
|
16373
|
-
function
|
|
16393
|
+
function __(n, t, e, i) {
|
|
16374
16394
|
n.save();
|
|
16375
16395
|
const r = t.length;
|
|
16376
16396
|
let a = 0, s = i;
|
|
@@ -16382,7 +16402,7 @@ function w_(n, t, e, i) {
|
|
|
16382
16402
|
}
|
|
16383
16403
|
return n.restore(), { width: a, height: s };
|
|
16384
16404
|
}
|
|
16385
|
-
function
|
|
16405
|
+
function M_(n, { x: t, y: e }, i, r) {
|
|
16386
16406
|
n.beginPath();
|
|
16387
16407
|
let a = 0;
|
|
16388
16408
|
i.forEach(function(s, o) {
|
|
@@ -16390,14 +16410,14 @@ function __(n, { x: t, y: e }, i, r) {
|
|
|
16390
16410
|
n.font = l.string, n.strokeText(s, t, e + c / 2 + a), a += c;
|
|
16391
16411
|
}), n.stroke();
|
|
16392
16412
|
}
|
|
16393
|
-
function
|
|
16413
|
+
function T_(n, { x: t, y: e }, i, { fonts: r, colors: a }) {
|
|
16394
16414
|
let s = 0;
|
|
16395
16415
|
i.forEach(function(o, l) {
|
|
16396
16416
|
const c = a[Math.min(l, a.length - 1)], u = r[Math.min(l, r.length - 1)], d = u.lineHeight;
|
|
16397
16417
|
n.beginPath(), n.font = u.string, n.fillStyle = c, n.fillText(o, t, e + d / 2 + s), s += d, n.fill();
|
|
16398
16418
|
});
|
|
16399
16419
|
}
|
|
16400
|
-
function
|
|
16420
|
+
function D_(n, t) {
|
|
16401
16421
|
const e = je(n) ? n : t;
|
|
16402
16422
|
return je(e) ? Lr(e, 0, 1) : 1;
|
|
16403
16423
|
}
|
|
@@ -16466,22 +16486,22 @@ function jd(n, t) {
|
|
|
16466
16486
|
radius: i
|
|
16467
16487
|
};
|
|
16468
16488
|
}
|
|
16469
|
-
return
|
|
16489
|
+
return k_(n, t);
|
|
16470
16490
|
}
|
|
16471
|
-
function
|
|
16491
|
+
function S_(n, t) {
|
|
16472
16492
|
const { scales: e, chartArea: i } = n, r = e[t.scaleID], a = { x: i.left, y: i.top, x2: i.right, y2: i.bottom };
|
|
16473
|
-
return r ?
|
|
16493
|
+
return r ? C_(r, a, t) : O_(e, a, t), a;
|
|
16474
16494
|
}
|
|
16475
16495
|
function Vd(n, t) {
|
|
16476
16496
|
const e = mo(n, t);
|
|
16477
16497
|
return e.initProperties = Mi(n, e, t), e.elements = [{
|
|
16478
16498
|
type: "label",
|
|
16479
16499
|
optionScope: "label",
|
|
16480
|
-
properties:
|
|
16500
|
+
properties: A_(n, e, t),
|
|
16481
16501
|
initProperties: e.initProperties
|
|
16482
16502
|
}], e;
|
|
16483
16503
|
}
|
|
16484
|
-
function
|
|
16504
|
+
function k_(n, t) {
|
|
16485
16505
|
const e = Bd(n, t), i = t.radius * 2;
|
|
16486
16506
|
return {
|
|
16487
16507
|
x: e.x - t.radius + t.xAdjust,
|
|
@@ -16502,11 +16522,11 @@ function kc(n, t) {
|
|
|
16502
16522
|
end: Math.max(e.start, e.end)
|
|
16503
16523
|
};
|
|
16504
16524
|
}
|
|
16505
|
-
function
|
|
16525
|
+
function C_(n, t, e) {
|
|
16506
16526
|
const i = Cn(n, e.value, NaN), r = Cn(n, e.endValue, i);
|
|
16507
16527
|
n.isHorizontal() ? (t.x = i, t.x2 = r) : (t.y = i, t.y2 = r);
|
|
16508
16528
|
}
|
|
16509
|
-
function
|
|
16529
|
+
function O_(n, t, e) {
|
|
16510
16530
|
for (const i of Object.keys(Sc)) {
|
|
16511
16531
|
const r = n[ln(n, e, i)];
|
|
16512
16532
|
if (r) {
|
|
@@ -16515,7 +16535,7 @@ function C_(n, t, e) {
|
|
|
16515
16535
|
}
|
|
16516
16536
|
}
|
|
16517
16537
|
}
|
|
16518
|
-
function
|
|
16538
|
+
function P_({ properties: n, options: t }, e, i, r) {
|
|
16519
16539
|
const { x: a, x2: s, width: o } = n;
|
|
16520
16540
|
return qd({ start: a, end: s, size: o, borderWidth: t.borderWidth }, {
|
|
16521
16541
|
position: i.x,
|
|
@@ -16524,7 +16544,7 @@ function O_({ properties: n, options: t }, e, i, r) {
|
|
|
16524
16544
|
size: e.width
|
|
16525
16545
|
});
|
|
16526
16546
|
}
|
|
16527
|
-
function
|
|
16547
|
+
function E_({ properties: n, options: t }, e, i, r) {
|
|
16528
16548
|
const { y: a, y2: s, height: o } = n;
|
|
16529
16549
|
return qd({ start: a, end: s, size: o, borderWidth: t.borderWidth }, {
|
|
16530
16550
|
position: i.y,
|
|
@@ -16537,10 +16557,10 @@ function qd(n, t) {
|
|
|
16537
16557
|
const { start: e, end: i, borderWidth: r } = n, { position: a, padding: { start: s, end: o }, adjust: l } = t, c = i - r - e - s - o - t.size;
|
|
16538
16558
|
return e + r / 2 + l + ho(c, a);
|
|
16539
16559
|
}
|
|
16540
|
-
function
|
|
16560
|
+
function A_(n, t, e) {
|
|
16541
16561
|
const i = e.label;
|
|
16542
16562
|
i.backgroundColor = "transparent", i.callout.display = !1;
|
|
16543
|
-
const r = fo(i.position), a = Rt(i.padding), s = po(n.ctx, i), o =
|
|
16563
|
+
const r = fo(i.position), a = Rt(i.padding), s = po(n.ctx, i), o = P_({ properties: t, options: e }, s, r, a), l = E_({ properties: t, options: e }, s, r, a), c = s.width + a.width, u = s.height + a.height;
|
|
16544
16564
|
return {
|
|
16545
16565
|
x: o,
|
|
16546
16566
|
y: l,
|
|
@@ -16561,7 +16581,7 @@ function hn(n, t, e) {
|
|
|
16561
16581
|
};
|
|
16562
16582
|
}
|
|
16563
16583
|
const Ms = ["enter", "leave"], vo = Ms.concat("click");
|
|
16564
|
-
function
|
|
16584
|
+
function R_(n, t, e) {
|
|
16565
16585
|
t.listened = Ud(e, vo, t.listeners), t.moveListened = !1, t._getElements = uo, Ms.forEach((i) => {
|
|
16566
16586
|
Gt(e[i]) && (t.moveListened = !0);
|
|
16567
16587
|
}), (!t.listened || !t.moveListened) && t.annotations.forEach((i) => {
|
|
@@ -16570,17 +16590,17 @@ function A_(n, t, e) {
|
|
|
16570
16590
|
});
|
|
16571
16591
|
});
|
|
16572
16592
|
}
|
|
16573
|
-
function
|
|
16593
|
+
function L_(n, t, e) {
|
|
16574
16594
|
if (n.listened)
|
|
16575
16595
|
switch (t.type) {
|
|
16576
16596
|
case "mousemove":
|
|
16577
16597
|
case "mouseout":
|
|
16578
|
-
return L_(n, t, e);
|
|
16579
|
-
case "click":
|
|
16580
16598
|
return I_(n, t, e);
|
|
16599
|
+
case "click":
|
|
16600
|
+
return N_(n, t, e);
|
|
16581
16601
|
}
|
|
16582
16602
|
}
|
|
16583
|
-
function
|
|
16603
|
+
function I_(n, t, e) {
|
|
16584
16604
|
if (!n.moveListened)
|
|
16585
16605
|
return;
|
|
16586
16606
|
let i;
|
|
@@ -16597,7 +16617,7 @@ function Cc({ state: n, event: t }, e, i, r) {
|
|
|
16597
16617
|
r.indexOf(s) < 0 && (a = Xd(s.options[e] || n.listeners[e], s, t) || a);
|
|
16598
16618
|
return a;
|
|
16599
16619
|
}
|
|
16600
|
-
function
|
|
16620
|
+
function N_(n, t, e) {
|
|
16601
16621
|
const i = n.listeners, r = uo(n, t, e.interaction);
|
|
16602
16622
|
let a;
|
|
16603
16623
|
for (const s of r)
|
|
@@ -16608,7 +16628,7 @@ function Xd(n, t, e) {
|
|
|
16608
16628
|
return lt(n, [t.$context, e]) === !0;
|
|
16609
16629
|
}
|
|
16610
16630
|
const wr = ["afterDraw", "beforeDraw"];
|
|
16611
|
-
function
|
|
16631
|
+
function F_(n, t, e) {
|
|
16612
16632
|
const i = t.visibleElements;
|
|
16613
16633
|
t.hooked = Ud(e, wr, t.hooks), t.hooked || i.forEach((r) => {
|
|
16614
16634
|
t.hooked || wr.forEach((a) => {
|
|
@@ -16622,31 +16642,31 @@ function Oc(n, t, e) {
|
|
|
16622
16642
|
return lt(i, [t.$context]);
|
|
16623
16643
|
}
|
|
16624
16644
|
}
|
|
16625
|
-
function
|
|
16626
|
-
const i =
|
|
16645
|
+
function Y_(n, t, e) {
|
|
16646
|
+
const i = $_(n.scales, t, e);
|
|
16627
16647
|
let r = Pc(t, i, "min", "suggestedMin");
|
|
16628
16648
|
r = Pc(t, i, "max", "suggestedMax") || r, r && Gt(t.handleTickRangeOptions) && t.handleTickRangeOptions();
|
|
16629
16649
|
}
|
|
16630
|
-
function
|
|
16650
|
+
function W_(n, t) {
|
|
16631
16651
|
for (const e of n)
|
|
16632
|
-
|
|
16652
|
+
z_(e, t);
|
|
16633
16653
|
}
|
|
16634
16654
|
function Pc(n, t, e, i) {
|
|
16635
|
-
if (wt(t[e]) && !
|
|
16655
|
+
if (wt(t[e]) && !U_(n.options, e, i)) {
|
|
16636
16656
|
const r = n[e] !== t[e];
|
|
16637
16657
|
return n[e] = t[e], r;
|
|
16638
16658
|
}
|
|
16639
16659
|
}
|
|
16640
|
-
function
|
|
16660
|
+
function U_(n, t, e) {
|
|
16641
16661
|
return Kt(n[t]) || Kt(n[e]);
|
|
16642
16662
|
}
|
|
16643
|
-
function
|
|
16663
|
+
function z_(n, t) {
|
|
16644
16664
|
for (const e of ["scaleID", "xScaleID", "yScaleID"]) {
|
|
16645
16665
|
const i = ln(t, n, e);
|
|
16646
|
-
i && !t[i] &&
|
|
16666
|
+
i && !t[i] && H_(n, e) && console.warn(`No scale found with id '${i}' for annotation '${n.id}'`);
|
|
16647
16667
|
}
|
|
16648
16668
|
}
|
|
16649
|
-
function
|
|
16669
|
+
function H_(n, t) {
|
|
16650
16670
|
if (t === "scaleID")
|
|
16651
16671
|
return !0;
|
|
16652
16672
|
const e = t.charAt(0);
|
|
@@ -16655,7 +16675,7 @@ function z_(n, t) {
|
|
|
16655
16675
|
return !0;
|
|
16656
16676
|
return !1;
|
|
16657
16677
|
}
|
|
16658
|
-
function
|
|
16678
|
+
function $_(n, t, e) {
|
|
16659
16679
|
const i = t.axis, r = t.id, a = i + "ScaleID", s = {
|
|
16660
16680
|
min: W(t.min, Number.NEGATIVE_INFINITY),
|
|
16661
16681
|
max: W(t.max, Number.POSITIVE_INFINITY)
|
|
@@ -16766,7 +16786,7 @@ class Ti extends Ft {
|
|
|
16766
16786
|
}
|
|
16767
16787
|
draw(t) {
|
|
16768
16788
|
const e = this.options, i = !Kt(this._visible) || this._visible;
|
|
16769
|
-
!e.display || !e.content || !i || (t.save(), go(t, this.getCenterPoint(), this.rotation),
|
|
16789
|
+
!e.display || !e.content || !i || (t.save(), go(t, this.getCenterPoint(), this.rotation), j_(t, this), Hd(t, this, e), b_(t, Q_(this), e), t.restore());
|
|
16770
16790
|
}
|
|
16771
16791
|
resolveElementProperties(t, e) {
|
|
16772
16792
|
let i;
|
|
@@ -16776,7 +16796,7 @@ class Ti extends Ft {
|
|
|
16776
16796
|
const { centerX: o, centerY: l } = mo(t, e);
|
|
16777
16797
|
i = { x: o, y: l };
|
|
16778
16798
|
}
|
|
16779
|
-
const r = Rt(e.padding), a = po(t.ctx, e), s =
|
|
16799
|
+
const r = Rt(e.padding), a = po(t.ctx, e), s = B_(i, a, e, r);
|
|
16780
16800
|
return {
|
|
16781
16801
|
initProperties: Mi(t, s, e),
|
|
16782
16802
|
pointX: i.x,
|
|
@@ -16849,7 +16869,7 @@ Ti.defaults = {
|
|
|
16849
16869
|
Ti.defaultRoutes = {
|
|
16850
16870
|
borderColor: "color"
|
|
16851
16871
|
};
|
|
16852
|
-
function
|
|
16872
|
+
function B_(n, t, e, i) {
|
|
16853
16873
|
const r = t.width + i.width + e.borderWidth, a = t.height + i.height + e.borderWidth, s = fo(e.position, "center"), o = Ac(n.x, r, e.xAdjust, s.x), l = Ac(n.y, a, e.yAdjust, s.y);
|
|
16854
16874
|
return {
|
|
16855
16875
|
x: o,
|
|
@@ -16865,51 +16885,51 @@ function $_(n, t, e, i) {
|
|
|
16865
16885
|
function Ac(n, t, e = 0, i) {
|
|
16866
16886
|
return n - ho(t, i) + e;
|
|
16867
16887
|
}
|
|
16868
|
-
function
|
|
16869
|
-
const { pointX: e, pointY: i, options: r } = t, a = r.callout, s = a && a.display &&
|
|
16870
|
-
if (!s ||
|
|
16888
|
+
function j_(n, t) {
|
|
16889
|
+
const { pointX: e, pointY: i, options: r } = t, a = r.callout, s = a && a.display && K_(t, a);
|
|
16890
|
+
if (!s || J_(t, a, s))
|
|
16871
16891
|
return;
|
|
16872
16892
|
if (n.save(), n.beginPath(), !qe(n, a))
|
|
16873
16893
|
return n.restore();
|
|
16874
|
-
const { separatorStart: l, separatorEnd: c } =
|
|
16894
|
+
const { separatorStart: l, separatorEnd: c } = V_(t, s), { sideStart: u, sideEnd: d } = X_(t, s, l);
|
|
16875
16895
|
(a.margin > 0 || r.borderWidth === 0) && (n.moveTo(l.x, l.y), n.lineTo(c.x, c.y)), n.moveTo(u.x, u.y), n.lineTo(d.x, d.y);
|
|
16876
16896
|
const h = hn({ x: e, y: i }, t.getCenterPoint(), At(-t.rotation));
|
|
16877
16897
|
n.lineTo(h.x, h.y), n.stroke(), n.restore();
|
|
16878
16898
|
}
|
|
16879
|
-
function
|
|
16880
|
-
const { x: e, y: i, x2: r, y2: a } = n, s =
|
|
16899
|
+
function V_(n, t) {
|
|
16900
|
+
const { x: e, y: i, x2: r, y2: a } = n, s = q_(n, t);
|
|
16881
16901
|
let o, l;
|
|
16882
16902
|
return t === "left" || t === "right" ? (o = { x: e + s, y: i }, l = { x: o.x, y: a }) : (o = { x: e, y: i + s }, l = { x: r, y: o.y }), { separatorStart: o, separatorEnd: l };
|
|
16883
16903
|
}
|
|
16884
|
-
function
|
|
16904
|
+
function q_(n, t) {
|
|
16885
16905
|
const { width: e, height: i, options: r } = n, a = r.callout.margin + r.borderWidth / 2;
|
|
16886
16906
|
return t === "right" ? e + a : t === "bottom" ? i + a : -a;
|
|
16887
16907
|
}
|
|
16888
|
-
function
|
|
16889
|
-
const { y: i, width: r, height: a, options: s } = n, o = s.callout.start, l =
|
|
16908
|
+
function X_(n, t, e) {
|
|
16909
|
+
const { y: i, width: r, height: a, options: s } = n, o = s.callout.start, l = G_(t, s.callout);
|
|
16890
16910
|
let c, u;
|
|
16891
16911
|
return t === "left" || t === "right" ? (c = { x: e.x, y: i + Ve(a, o) }, u = { x: c.x + l, y: c.y }) : (c = { x: e.x + Ve(r, o), y: e.y }, u = { x: c.x, y: c.y + l }), { sideStart: c, sideEnd: u };
|
|
16892
16912
|
}
|
|
16893
|
-
function
|
|
16913
|
+
function G_(n, t) {
|
|
16894
16914
|
const e = t.side;
|
|
16895
16915
|
return n === "left" || n === "top" ? -e : e;
|
|
16896
16916
|
}
|
|
16897
|
-
function G_(n, t) {
|
|
16898
|
-
const e = t.position;
|
|
16899
|
-
return Gd.includes(e) ? e : K_(n, t);
|
|
16900
|
-
}
|
|
16901
16917
|
function K_(n, t) {
|
|
16902
|
-
const
|
|
16903
|
-
|
|
16904
|
-
|
|
16905
|
-
|
|
16906
|
-
|
|
16918
|
+
const e = t.position;
|
|
16919
|
+
return Gd.includes(e) ? e : Z_(n, t);
|
|
16920
|
+
}
|
|
16921
|
+
function Z_(n, t) {
|
|
16922
|
+
const { x: e, y: i, x2: r, y2: a, width: s, height: o, pointX: l, pointY: c, centerX: u, centerY: d, rotation: h } = n, f = { x: u, y: d }, g = t.start, v = Ve(s, g), p = Ve(o, g), m = [e, e + v, e + v, r], b = [i + p, a, i, a], x = [];
|
|
16923
|
+
for (let y = 0; y < 4; y++) {
|
|
16924
|
+
const w = hn({ x: m[y], y: b[y] }, f, At(h));
|
|
16925
|
+
x.push({
|
|
16926
|
+
position: Gd[y],
|
|
16907
16927
|
distance: _n(w, { x: l, y: c })
|
|
16908
16928
|
});
|
|
16909
16929
|
}
|
|
16910
|
-
return
|
|
16930
|
+
return x.sort((y, w) => y.distance - w.distance)[0].position;
|
|
16911
16931
|
}
|
|
16912
|
-
function
|
|
16932
|
+
function Q_({ x: n, y: t, width: e, height: i, options: r }) {
|
|
16913
16933
|
const a = r.borderWidth / 2, s = Rt(r.padding);
|
|
16914
16934
|
return {
|
|
16915
16935
|
x: n + s.left + a,
|
|
@@ -16918,12 +16938,12 @@ function Z_({ x: n, y: t, width: e, height: i, options: r }) {
|
|
|
16918
16938
|
height: i - s.top - s.bottom - r.borderWidth
|
|
16919
16939
|
};
|
|
16920
16940
|
}
|
|
16921
|
-
function
|
|
16941
|
+
function J_(n, t, e) {
|
|
16922
16942
|
const { pointX: i, pointY: r } = n, a = t.margin;
|
|
16923
16943
|
let s = i, o = r;
|
|
16924
16944
|
return e === "left" ? s += a : e === "right" ? s -= a : e === "top" ? o += a : e === "bottom" && (o -= a), n.inRange(s, o);
|
|
16925
16945
|
}
|
|
16926
|
-
const bo = (n, t, e) => ({ x: n.x + e * (t.x - n.x), y: n.y + e * (t.y - n.y) }), Ts = (n, t, e) => bo(t, e, Math.abs((n - t.y) / (e.y - t.y))).x, Rc = (n, t, e) => bo(t, e, Math.abs((n - t.x) / (e.x - t.x))).y, Zn = (n) => n * n,
|
|
16946
|
+
const bo = (n, t, e) => ({ x: n.x + e * (t.x - n.x), y: n.y + e * (t.y - n.y) }), Ts = (n, t, e) => bo(t, e, Math.abs((n - t.y) / (e.y - t.y))).x, Rc = (n, t, e) => bo(t, e, Math.abs((n - t.x) / (e.x - t.x))).y, Zn = (n) => n * n, t1 = (n, t, { x: e, y: i, x2: r, y2: a }, s) => s === "y" ? { start: Math.min(i, a), end: Math.max(i, a), value: t } : { start: Math.min(e, r), end: Math.max(e, r), value: n }, Lc = (n, t, e, i) => (1 - i) * (1 - i) * n + 2 * (1 - i) * i * t + i * i * e, Ds = (n, t, e, i) => ({ x: Lc(n.x, t.x, e.x, i), y: Lc(n.y, t.y, e.y, i) }), Ic = (n, t, e, i) => 2 * (1 - i) * (t - n) + 2 * i * (e - t), Nc = (n, t, e, i) => -Math.atan2(Ic(n.x, t.x, e.x, i), Ic(n.y, t.y, e.y, i)) + 0.5 * X;
|
|
16927
16947
|
class Di extends Ft {
|
|
16928
16948
|
inRange(t, e, i, r) {
|
|
16929
16949
|
const a = this.options.borderWidth / 2;
|
|
@@ -16935,9 +16955,9 @@ class Di extends Ft {
|
|
|
16935
16955
|
return l.restore(), f;
|
|
16936
16956
|
}
|
|
16937
16957
|
const c = Zn(a);
|
|
16938
|
-
return
|
|
16958
|
+
return r1(this, s, c, r) || Ss(this, s, r);
|
|
16939
16959
|
}
|
|
16940
|
-
return
|
|
16960
|
+
return e1(this, { mouseX: t, mouseY: e }, i, { hBorderWidth: a, useFinalPosition: r });
|
|
16941
16961
|
}
|
|
16942
16962
|
getCenterPoint(t) {
|
|
16943
16963
|
return Pn(this, t);
|
|
@@ -16949,7 +16969,7 @@ class Di extends Ft {
|
|
|
16949
16969
|
En(t, o);
|
|
16950
16970
|
const l = Math.sqrt(Math.pow(r - e, 2) + Math.pow(a - i, 2));
|
|
16951
16971
|
if (o.curve && s)
|
|
16952
|
-
return
|
|
16972
|
+
return h1(t, this, s, l), t.restore();
|
|
16953
16973
|
const { startOpts: c, endOpts: u, startAdjust: d, endAdjust: h } = Kd(this), f = Math.atan2(a - i, r - e);
|
|
16954
16974
|
t.translate(e, i), t.rotate(f), t.beginPath(), t.moveTo(0 + d, 0), t.lineTo(l - h, 0), t.shadowColor = o.borderShadowColor, t.stroke(), ks(t, 0, d, c), ks(t, l, -h, u), t.restore();
|
|
16955
16975
|
}
|
|
@@ -16957,12 +16977,12 @@ class Di extends Ft {
|
|
|
16957
16977
|
return this.elements && this.elements[0];
|
|
16958
16978
|
}
|
|
16959
16979
|
resolveElementProperties(t, e) {
|
|
16960
|
-
const i =
|
|
16980
|
+
const i = S_(t, e), { x: r, y: a, x2: s, y2: o } = i, l = n1(i, t.chartArea), c = l ? i1({ x: r, y: a }, { x: s, y: o }, t.chartArea) : { x: r, y: a, x2: s, y2: o, width: Math.abs(s - r), height: Math.abs(o - a) };
|
|
16961
16981
|
if (c.centerX = (s + r) / 2, c.centerY = (o + a) / 2, c.initProperties = Mi(t, c, e), e.curve) {
|
|
16962
16982
|
const d = { x: c.x, y: c.y }, h = { x: c.x2, y: c.y2 };
|
|
16963
|
-
c.cp =
|
|
16983
|
+
c.cp = d1(c, e, _n(d, h));
|
|
16964
16984
|
}
|
|
16965
|
-
const u =
|
|
16985
|
+
const u = a1(t, c, e.label);
|
|
16966
16986
|
return u._visible = l, c.elements = [{
|
|
16967
16987
|
type: "label",
|
|
16968
16988
|
optionScope: "label",
|
|
@@ -17075,21 +17095,21 @@ Di.descriptors = {
|
|
|
17075
17095
|
Di.defaultRoutes = {
|
|
17076
17096
|
borderColor: "color"
|
|
17077
17097
|
};
|
|
17078
|
-
function
|
|
17079
|
-
const s =
|
|
17098
|
+
function e1(n, { mouseX: t, mouseY: e }, i, { hBorderWidth: r, useFinalPosition: a }) {
|
|
17099
|
+
const s = t1(t, e, n.getProps(["x", "y", "x2", "y2"], a), i);
|
|
17080
17100
|
return s.value >= s.start - r && s.value <= s.end + r || Ss(n, { mouseX: t, mouseY: e }, a, i);
|
|
17081
17101
|
}
|
|
17082
|
-
function
|
|
17102
|
+
function n1({ x: n, y: t, x2: e, y2: i }, { top: r, right: a, bottom: s, left: o }) {
|
|
17083
17103
|
return !(n < o && e < o || n > a && e > a || t < r && i < r || t > s && i > s);
|
|
17084
17104
|
}
|
|
17085
17105
|
function Yc({ x: n, y: t }, e, { top: i, right: r, bottom: a, left: s }) {
|
|
17086
17106
|
return n < s && (t = Rc(s, { x: n, y: t }, e), n = s), n > r && (t = Rc(r, { x: n, y: t }, e), n = r), t < i && (n = Ts(i, { x: n, y: t }, e), t = i), t > a && (n = Ts(a, { x: n, y: t }, e), t = a), { x: n, y: t };
|
|
17087
17107
|
}
|
|
17088
|
-
function
|
|
17108
|
+
function i1(n, t, e) {
|
|
17089
17109
|
const { x: i, y: r } = Yc(n, t, e), { x: a, y: s } = Yc(t, n, e);
|
|
17090
17110
|
return { x: i, y: r, x2: a, y2: s, width: Math.abs(a - i), height: Math.abs(s - r) };
|
|
17091
17111
|
}
|
|
17092
|
-
function
|
|
17112
|
+
function r1(n, { mouseX: t, mouseY: e }, i = en, r) {
|
|
17093
17113
|
const { x: a, y: s, x2: o, y2: l } = n.getProps(["x", "y", "x2", "y2"], r), c = o - a, u = l - s, d = Zn(c) + Zn(u), h = d === 0 ? -1 : ((t - a) * c + (e - s) * u) / d;
|
|
17094
17114
|
let f, g;
|
|
17095
17115
|
return h < 0 ? (f = a, g = s) : h > 1 ? (f = o, g = l) : (f = a + h * c, g = s + h * u), Zn(t - f) + Zn(e - g) <= i;
|
|
@@ -17098,22 +17118,22 @@ function Ss(n, { mouseX: t, mouseY: e }, i, r) {
|
|
|
17098
17118
|
const a = n.label;
|
|
17099
17119
|
return a.options.display && a.inRange(t, e, r, i);
|
|
17100
17120
|
}
|
|
17101
|
-
function
|
|
17121
|
+
function a1(n, t, e) {
|
|
17102
17122
|
const i = e.borderWidth, r = Rt(e.padding), a = po(n.ctx, e), s = a.width + r.width + i, o = a.height + r.height + i;
|
|
17103
|
-
return
|
|
17123
|
+
return o1(t, e, { width: s, height: o, padding: r }, n.chartArea);
|
|
17104
17124
|
}
|
|
17105
|
-
function
|
|
17125
|
+
function s1(n) {
|
|
17106
17126
|
const { x: t, y: e, x2: i, y2: r } = n, a = Math.atan2(r - e, i - t);
|
|
17107
17127
|
return a > X / 2 ? a - X : a < X / -2 ? a + X : a;
|
|
17108
17128
|
}
|
|
17109
|
-
function
|
|
17110
|
-
const { width: r, height: a, padding: s } = e, { xAdjust: o, yAdjust: l } = t, c = { x: n.x, y: n.y }, u = { x: n.x2, y: n.y2 }, d = t.rotation === "auto" ?
|
|
17129
|
+
function o1(n, t, e, i) {
|
|
17130
|
+
const { width: r, height: a, padding: s } = e, { xAdjust: o, yAdjust: l } = t, c = { x: n.x, y: n.y }, u = { x: n.x2, y: n.y2 }, d = t.rotation === "auto" ? s1(n) : At(t.rotation), h = l1(r, a, d), f = c1(n, t, { labelSize: h, padding: s }, i), g = n.cp ? Ds(c, n.cp, u, f) : bo(c, u, f), v = { size: h.w, min: i.left, max: i.right, padding: s.left }, p = { size: h.h, min: i.top, max: i.bottom, padding: s.top }, m = Uc(g.x, v) + o, b = Uc(g.y, p) + l;
|
|
17111
17131
|
return {
|
|
17112
|
-
x:
|
|
17132
|
+
x: m - r / 2,
|
|
17113
17133
|
y: b - a / 2,
|
|
17114
|
-
x2:
|
|
17134
|
+
x2: m + r / 2,
|
|
17115
17135
|
y2: b + a / 2,
|
|
17116
|
-
centerX:
|
|
17136
|
+
centerX: m,
|
|
17117
17137
|
centerY: b,
|
|
17118
17138
|
pointX: g.x,
|
|
17119
17139
|
pointY: g.y,
|
|
@@ -17122,23 +17142,23 @@ function s1(n, t, e, i) {
|
|
|
17122
17142
|
rotation: Dr(d)
|
|
17123
17143
|
};
|
|
17124
17144
|
}
|
|
17125
|
-
function
|
|
17145
|
+
function l1(n, t, e) {
|
|
17126
17146
|
const i = Math.cos(e), r = Math.sin(e);
|
|
17127
17147
|
return {
|
|
17128
17148
|
w: Math.abs(n * i) + Math.abs(t * r),
|
|
17129
17149
|
h: Math.abs(n * r) + Math.abs(t * i)
|
|
17130
17150
|
};
|
|
17131
17151
|
}
|
|
17132
|
-
function
|
|
17152
|
+
function c1(n, t, e, i) {
|
|
17133
17153
|
let r;
|
|
17134
|
-
const a =
|
|
17154
|
+
const a = u1(n, i);
|
|
17135
17155
|
return t.position === "start" ? r = Wc({ w: n.x2 - n.x, h: n.y2 - n.y }, e, t, a) : t.position === "end" ? r = 1 - Wc({ w: n.x - n.x2, h: n.y - n.y2 }, e, t, a) : r = ho(1, t.position), r;
|
|
17136
17156
|
}
|
|
17137
17157
|
function Wc(n, t, e, i) {
|
|
17138
17158
|
const { labelSize: r, padding: a } = t, s = n.w * i.dx, o = n.h * i.dy, l = s > 0 && (r.w / 2 + a.left - i.x) / s, c = o > 0 && (r.h / 2 + a.top - i.y) / o;
|
|
17139
17159
|
return Lr(Math.max(l, c), 0, 0.25);
|
|
17140
17160
|
}
|
|
17141
|
-
function
|
|
17161
|
+
function u1(n, t) {
|
|
17142
17162
|
const { x: e, x2: i, y: r, y2: a } = n, s = Math.min(r, a) - t.top, o = Math.min(e, i) - t.left, l = t.bottom - Math.max(r, a), c = t.right - Math.max(e, i);
|
|
17143
17163
|
return {
|
|
17144
17164
|
x: Math.min(o, c),
|
|
@@ -17172,7 +17192,7 @@ function ks(n, t, e, i) {
|
|
|
17172
17192
|
const { length: r, width: a, fill: s, backgroundColor: o, borderColor: l } = i, c = Math.abs(t - r) + e;
|
|
17173
17193
|
n.beginPath(), En(n, i), qe(n, i), n.moveTo(c, -a), n.lineTo(t + e, 0), n.lineTo(c, a), s === !0 ? (n.fillStyle = o || l, n.closePath(), n.fill(), n.shadowColor = "transparent") : n.shadowColor = i.borderShadowColor, n.stroke();
|
|
17174
17194
|
}
|
|
17175
|
-
function
|
|
17195
|
+
function d1(n, t, e) {
|
|
17176
17196
|
const { x: i, y: r, x2: a, y2: s, centerX: o, centerY: l } = n, c = Math.atan2(s - r, a - i), u = fo(t.controlPoint, 0), d = {
|
|
17177
17197
|
x: o + Ve(e, u.x, !1),
|
|
17178
17198
|
y: l + Ve(e, u.y, !1)
|
|
@@ -17182,15 +17202,15 @@ function u1(n, t, e) {
|
|
|
17182
17202
|
function Hc(n, { x: t, y: e }, { angle: i, adjust: r }, a) {
|
|
17183
17203
|
!a || !a.display || (n.save(), n.translate(t, e), n.rotate(i), ks(n, 0, -r, a), n.restore());
|
|
17184
17204
|
}
|
|
17185
|
-
function
|
|
17186
|
-
const { x: r, y: a, x2: s, y2: o, options: l } = t, { startOpts: c, endOpts: u, startAdjust: d, endAdjust: h } = Kd(t), f = { x: r, y: a }, g = { x: s, y: o }, v = Nc(f, e, g, 0),
|
|
17187
|
-
n.beginPath(),
|
|
17205
|
+
function h1(n, t, e, i) {
|
|
17206
|
+
const { x: r, y: a, x2: s, y2: o, options: l } = t, { startOpts: c, endOpts: u, startAdjust: d, endAdjust: h } = Kd(t), f = { x: r, y: a }, g = { x: s, y: o }, v = Nc(f, e, g, 0), p = Nc(f, e, g, 1) - X, m = Ds(f, e, g, d / i), b = Ds(f, e, g, 1 - h / i), x = new Path2D();
|
|
17207
|
+
n.beginPath(), x.moveTo(m.x, m.y), x.quadraticCurveTo(e.x, e.y, b.x, b.y), n.shadowColor = l.borderShadowColor, n.stroke(x), t.path = x, t.ctx = n, Hc(n, m, { angle: v, adjust: d }, c), Hc(n, b, { angle: p, adjust: h }, u);
|
|
17188
17208
|
}
|
|
17189
17209
|
class Si extends Ft {
|
|
17190
17210
|
inRange(t, e, i, r) {
|
|
17191
17211
|
const a = this.options.rotation, s = this.options.borderWidth;
|
|
17192
17212
|
if (i !== "x" && i !== "y")
|
|
17193
|
-
return
|
|
17213
|
+
return f1({ x: t, y: e }, this.getProps(["width", "height", "centerX", "centerY"], r), a, s);
|
|
17194
17214
|
const { x: o, y: l, x2: c, y2: u } = this.getProps(["x", "y", "x2", "y2"], r), d = s / 2, h = i === "y" ? { start: l, end: u } : { start: o, end: c }, f = hn({ x: t, y: e }, this.getCenterPoint(r), At(-a));
|
|
17195
17215
|
return f[i] >= h.start - d - en && f[i] <= h.end + d + en;
|
|
17196
17216
|
}
|
|
@@ -17242,7 +17262,7 @@ Si.descriptors = {
|
|
|
17242
17262
|
_fallback: !0
|
|
17243
17263
|
}
|
|
17244
17264
|
};
|
|
17245
|
-
function
|
|
17265
|
+
function f1(n, t, e, i) {
|
|
17246
17266
|
const { width: r, height: a, centerX: s, centerY: o } = t, l = r / 2, c = a / 2;
|
|
17247
17267
|
if (l <= 0 || c <= 0)
|
|
17248
17268
|
return !1;
|
|
@@ -17253,7 +17273,7 @@ class Nr extends Ft {
|
|
|
17253
17273
|
inRange(t, e, i, r) {
|
|
17254
17274
|
const { x: a, y: s, x2: o, y2: l, width: c } = this.getProps(["x", "y", "x2", "y2", "width"], r), u = this.options.borderWidth;
|
|
17255
17275
|
if (i !== "x" && i !== "y")
|
|
17256
|
-
return
|
|
17276
|
+
return d_({ x: t, y: e }, this.getCenterPoint(r), c / 2, u);
|
|
17257
17277
|
const d = u / 2, h = i === "y" ? { start: s, end: l, value: e } : { start: a, end: o, value: t };
|
|
17258
17278
|
return h.value >= h.start - d && h.value <= h.end + d;
|
|
17259
17279
|
}
|
|
@@ -17266,7 +17286,7 @@ class Nr extends Ft {
|
|
|
17266
17286
|
return;
|
|
17267
17287
|
t.save(), t.fillStyle = e.backgroundColor, En(t, e);
|
|
17268
17288
|
const r = qe(t, e);
|
|
17269
|
-
|
|
17289
|
+
x_(t, this, this.centerX, this.centerY), r && !Ir(e.pointStyle) && (t.shadowColor = e.borderShadowColor, t.stroke()), t.restore(), e.borderWidth = i;
|
|
17270
17290
|
}
|
|
17271
17291
|
resolveElementProperties(t, e) {
|
|
17272
17292
|
const i = jd(t, e);
|
|
@@ -17308,7 +17328,7 @@ Nr.defaultRoutes = {
|
|
|
17308
17328
|
class Fr extends Ft {
|
|
17309
17329
|
inRange(t, e, i, r) {
|
|
17310
17330
|
if (i !== "x" && i !== "y")
|
|
17311
|
-
return this.options.radius >= 0.1 && this.elements.length > 1 &&
|
|
17331
|
+
return this.options.radius >= 0.1 && this.elements.length > 1 && p1(this.elements, t, e, r);
|
|
17312
17332
|
const a = hn({ x: t, y: e }, this.getCenterPoint(r), At(-this.options.rotation)), s = this.elements.map((c) => i === "y" ? c.bY : c.bX), o = Math.min(...s), l = Math.max(...s);
|
|
17313
17333
|
return a[i] >= o && a[i] <= l;
|
|
17314
17334
|
}
|
|
@@ -17328,7 +17348,7 @@ class Fr extends Ft {
|
|
|
17328
17348
|
const i = jd(t, e), { sides: r, rotation: a } = e, s = [], o = 2 * X / r;
|
|
17329
17349
|
let l = a * Fs;
|
|
17330
17350
|
for (let c = 0; c < r; c++, l += o) {
|
|
17331
|
-
const u =
|
|
17351
|
+
const u = g1(i, e, l);
|
|
17332
17352
|
u.initProperties = Mi(t, i, e), s.push(u);
|
|
17333
17353
|
}
|
|
17334
17354
|
return i.elements = s, i;
|
|
@@ -17371,7 +17391,7 @@ Fr.defaultRoutes = {
|
|
|
17371
17391
|
borderColor: "color",
|
|
17372
17392
|
backgroundColor: "color"
|
|
17373
17393
|
};
|
|
17374
|
-
function
|
|
17394
|
+
function g1({ centerX: n, centerY: t }, { radius: e, borderWidth: i }, r) {
|
|
17375
17395
|
const a = i / 2, s = Math.sin(r), o = Math.cos(r), l = { x: n + s * e, y: t - o * e };
|
|
17376
17396
|
return {
|
|
17377
17397
|
type: "point",
|
|
@@ -17386,7 +17406,7 @@ function f1({ centerX: n, centerY: t }, { radius: e, borderWidth: i }, r) {
|
|
|
17386
17406
|
}
|
|
17387
17407
|
};
|
|
17388
17408
|
}
|
|
17389
|
-
function
|
|
17409
|
+
function p1(n, t, e, i) {
|
|
17390
17410
|
let r = !1, a = n[n.length - 1].getProps(["bX", "bY"], i);
|
|
17391
17411
|
for (const s of n) {
|
|
17392
17412
|
const o = s.getProps(["bX", "bY"], i);
|
|
@@ -17407,26 +17427,26 @@ Object.keys(He).forEach((n) => {
|
|
|
17407
17427
|
_fallback: "plugins.annotation.common"
|
|
17408
17428
|
});
|
|
17409
17429
|
});
|
|
17410
|
-
const
|
|
17430
|
+
const m1 = {
|
|
17411
17431
|
update: Object.assign
|
|
17412
|
-
},
|
|
17432
|
+
}, v1 = vo.concat(wr), $c = (n, t) => j(t) ? Os(n, t) : n, Cs = (n) => n === "color" || n === "font";
|
|
17413
17433
|
function yo(n = "line") {
|
|
17414
17434
|
return He[n] ? n : (console.warn(`Unknown annotation type: '${n}', defaulting to 'line'`), "line");
|
|
17415
17435
|
}
|
|
17416
|
-
function
|
|
17417
|
-
const r =
|
|
17436
|
+
function b1(n, t, e, i) {
|
|
17437
|
+
const r = x1(n, e.animations, i), a = t.annotations, s = M1(t.elements, a);
|
|
17418
17438
|
for (let o = 0; o < a.length; o++) {
|
|
17419
|
-
const l = a[o], c = Zd(s, o, l.type), u = l.setContext(
|
|
17420
|
-
d.skip =
|
|
17439
|
+
const l = a[o], c = Zd(s, o, l.type), u = l.setContext(_1(n, c, l)), d = c.resolveElementProperties(n, u);
|
|
17440
|
+
d.skip = y1(d), "elements" in d && (w1(c, d.elements, u, r), delete d.elements), Kt(c.x) || Object.assign(c, d), Object.assign(c, d.initProperties), d.options = Qd(u), r.update(c, d);
|
|
17421
17441
|
}
|
|
17422
17442
|
}
|
|
17423
|
-
function
|
|
17443
|
+
function y1(n) {
|
|
17424
17444
|
return isNaN(n.x) || isNaN(n.y);
|
|
17425
17445
|
}
|
|
17426
|
-
function
|
|
17427
|
-
return e === "reset" || e === "none" || e === "resize" ?
|
|
17446
|
+
function x1(n, t, e) {
|
|
17447
|
+
return e === "reset" || e === "none" || e === "resize" ? m1 : new Vs(n, t);
|
|
17428
17448
|
}
|
|
17429
|
-
function
|
|
17449
|
+
function w1(n, t, e, i) {
|
|
17430
17450
|
const r = n.elements || (n.elements = []);
|
|
17431
17451
|
r.length = t.length;
|
|
17432
17452
|
for (let a = 0; a < t.length; a++) {
|
|
@@ -17446,7 +17466,7 @@ function Qd(n) {
|
|
|
17446
17466
|
Os(n, t.defaults),
|
|
17447
17467
|
Os(n, t.defaultRoutes)
|
|
17448
17468
|
);
|
|
17449
|
-
for (const i of
|
|
17469
|
+
for (const i of v1)
|
|
17450
17470
|
e[i] = n[i];
|
|
17451
17471
|
return e;
|
|
17452
17472
|
}
|
|
@@ -17458,14 +17478,14 @@ function Os(n, t) {
|
|
|
17458
17478
|
}
|
|
17459
17479
|
return e;
|
|
17460
17480
|
}
|
|
17461
|
-
function
|
|
17481
|
+
function _1(n, t, e) {
|
|
17462
17482
|
return t.$context || (t.$context = Object.assign(Object.create(n.getContext()), {
|
|
17463
17483
|
element: t,
|
|
17464
17484
|
id: e.id,
|
|
17465
17485
|
type: "annotation"
|
|
17466
17486
|
}));
|
|
17467
17487
|
}
|
|
17468
|
-
function
|
|
17488
|
+
function M1(n, t) {
|
|
17469
17489
|
const e = t.length, i = n.length;
|
|
17470
17490
|
if (i < e) {
|
|
17471
17491
|
const r = e - i;
|
|
@@ -17474,13 +17494,13 @@ function _1(n, t) {
|
|
|
17474
17494
|
i > e && n.splice(e, i - e);
|
|
17475
17495
|
return n;
|
|
17476
17496
|
}
|
|
17477
|
-
var
|
|
17478
|
-
const Ae = /* @__PURE__ */ new Map(),
|
|
17497
|
+
var T1 = "3.0.1";
|
|
17498
|
+
const Ae = /* @__PURE__ */ new Map(), D1 = vo.concat(wr);
|
|
17479
17499
|
var Bc = {
|
|
17480
17500
|
id: "annotation",
|
|
17481
|
-
version:
|
|
17501
|
+
version: T1,
|
|
17482
17502
|
beforeRegister() {
|
|
17483
|
-
|
|
17503
|
+
h_("chart.js", "4.0", ae.version);
|
|
17484
17504
|
},
|
|
17485
17505
|
afterRegister() {
|
|
17486
17506
|
ae.register(He);
|
|
@@ -17507,15 +17527,15 @@ var Bc = {
|
|
|
17507
17527
|
j(a) ? Object.keys(a).forEach((s) => {
|
|
17508
17528
|
const o = a[s];
|
|
17509
17529
|
j(o) && (o.id = s, r.push(o));
|
|
17510
|
-
}) : nt(a) && r.push(...a),
|
|
17530
|
+
}) : nt(a) && r.push(...a), W_(r, n.scales);
|
|
17511
17531
|
},
|
|
17512
17532
|
afterDataLimits(n, t) {
|
|
17513
17533
|
const e = Ae.get(n);
|
|
17514
|
-
|
|
17534
|
+
Y_(n, t.scale, e.annotations.filter((i) => i.display && i.adjustScaleRange));
|
|
17515
17535
|
},
|
|
17516
17536
|
afterUpdate(n, t, e) {
|
|
17517
17537
|
const i = Ae.get(n);
|
|
17518
|
-
|
|
17538
|
+
R_(n, i, e), b1(n, i, e, t.mode), i.visibleElements = i.elements.filter((r) => !r.skip && r.options.display), F_(n, i, e);
|
|
17519
17539
|
},
|
|
17520
17540
|
beforeDatasetsDraw(n, t, e) {
|
|
17521
17541
|
qi(n, "beforeDatasetsDraw", e.clip);
|
|
@@ -17531,7 +17551,7 @@ var Bc = {
|
|
|
17531
17551
|
},
|
|
17532
17552
|
beforeEvent(n, t, e) {
|
|
17533
17553
|
const i = Ae.get(n);
|
|
17534
|
-
|
|
17554
|
+
L_(i, t.event, e) && (t.changed = !0);
|
|
17535
17555
|
},
|
|
17536
17556
|
afterDestroy(n) {
|
|
17537
17557
|
Ae.delete(n);
|
|
@@ -17560,7 +17580,7 @@ var Bc = {
|
|
|
17560
17580
|
},
|
|
17561
17581
|
descriptors: {
|
|
17562
17582
|
_indexable: !1,
|
|
17563
|
-
_scriptable: (n) => !
|
|
17583
|
+
_scriptable: (n) => !D1.includes(n) && n !== "init",
|
|
17564
17584
|
annotations: {
|
|
17565
17585
|
_allKeys: !1,
|
|
17566
17586
|
_fallback: (n, t) => `elements.${He[yo(t.type)].id}`
|
|
@@ -17581,12 +17601,12 @@ var Bc = {
|
|
|
17581
17601
|
function qi(n, t, e) {
|
|
17582
17602
|
const { ctx: i, chartArea: r } = n, a = Ae.get(n);
|
|
17583
17603
|
e && pi(i, r);
|
|
17584
|
-
const s =
|
|
17604
|
+
const s = S1(a.visibleElements, t).sort((o, l) => o.element.options.z - l.element.options.z);
|
|
17585
17605
|
for (const o of s)
|
|
17586
|
-
|
|
17606
|
+
k1(i, r, a, o);
|
|
17587
17607
|
e && mi(i);
|
|
17588
17608
|
}
|
|
17589
|
-
function
|
|
17609
|
+
function S1(n, t) {
|
|
17590
17610
|
const e = [];
|
|
17591
17611
|
for (const i of n)
|
|
17592
17612
|
if (i.options.drawTime === t && e.push({ element: i, main: !0 }), i.elements && i.elements.length)
|
|
@@ -17594,7 +17614,7 @@ function D1(n, t) {
|
|
|
17594
17614
|
r.options.display && r.options.drawTime === t && e.push({ element: r });
|
|
17595
17615
|
return e;
|
|
17596
17616
|
}
|
|
17597
|
-
function
|
|
17617
|
+
function k1(n, t, e, i) {
|
|
17598
17618
|
const r = i.element;
|
|
17599
17619
|
i.main ? (Oc(e, r, "beforeDraw"), r.draw(n, t), Oc(e, r, "afterDraw")) : r.draw(n, t);
|
|
17600
17620
|
}
|
|
@@ -17603,13 +17623,13 @@ const _r = "24px", Jd = (n, t) => {
|
|
|
17603
17623
|
for (const [i, r] of t)
|
|
17604
17624
|
e[i] = r;
|
|
17605
17625
|
return e;
|
|
17606
|
-
},
|
|
17626
|
+
}, C1 = (n) => (Qc("data-v-b36d8f24"), n = n(), Jc(), n), O1 = ["aria-hidden"], P1 = {
|
|
17607
17627
|
key: 0,
|
|
17608
17628
|
"data-testid": "kui-icon-svg-title"
|
|
17609
|
-
},
|
|
17629
|
+
}, E1 = /* @__PURE__ */ C1(() => /* @__PURE__ */ rt("path", {
|
|
17610
17630
|
d: "M9 20C8.45 20 7.97917 19.8042 7.5875 19.4125C7.19583 19.0208 7 18.55 7 18C7 17.45 7.19583 16.9792 7.5875 16.5875C7.97917 16.1958 8.45 16 9 16C9.55 16 10.0208 16.1958 10.4125 16.5875C10.8042 16.9792 11 17.45 11 18C11 18.55 10.8042 19.0208 10.4125 19.4125C10.0208 19.8042 9.55 20 9 20ZM15 20C14.45 20 13.9792 19.8042 13.5875 19.4125C13.1958 19.0208 13 18.55 13 18C13 17.45 13.1958 16.9792 13.5875 16.5875C13.9792 16.1958 14.45 16 15 16C15.55 16 16.0208 16.1958 16.4125 16.5875C16.8042 16.9792 17 17.45 17 18C17 18.55 16.8042 19.0208 16.4125 19.4125C16.0208 19.8042 15.55 20 15 20ZM9 14C8.45 14 7.97917 13.8042 7.5875 13.4125C7.19583 13.0208 7 12.55 7 12C7 11.45 7.19583 10.9792 7.5875 10.5875C7.97917 10.1958 8.45 10 9 10C9.55 10 10.0208 10.1958 10.4125 10.5875C10.8042 10.9792 11 11.45 11 12C11 12.55 10.8042 13.0208 10.4125 13.4125C10.0208 13.8042 9.55 14 9 14ZM15 14C14.45 14 13.9792 13.8042 13.5875 13.4125C13.1958 13.0208 13 12.55 13 12C13 11.45 13.1958 10.9792 13.5875 10.5875C13.9792 10.1958 14.45 10 15 10C15.55 10 16.0208 10.1958 16.4125 10.5875C16.8042 10.9792 17 11.45 17 12C17 12.55 16.8042 13.0208 16.4125 13.4125C16.0208 13.8042 15.55 14 15 14ZM9 8C8.45 8 7.97917 7.80417 7.5875 7.4125C7.19583 7.02083 7 6.55 7 6C7 5.45 7.19583 4.97917 7.5875 4.5875C7.97917 4.19583 8.45 4 9 4C9.55 4 10.0208 4.19583 10.4125 4.5875C10.8042 4.97917 11 5.45 11 6C11 6.55 10.8042 7.02083 10.4125 7.4125C10.0208 7.80417 9.55 8 9 8ZM15 8C14.45 8 13.9792 7.80417 13.5875 7.4125C13.1958 7.02083 13 6.55 13 6C13 5.45 13.1958 4.97917 13.5875 4.5875C13.9792 4.19583 14.45 4 15 4C15.55 4 16.0208 4.19583 16.4125 4.5875C16.8042 4.97917 17 5.45 17 6C17 6.55 16.8042 7.02083 16.4125 7.4125C16.0208 7.80417 15.55 8 15 8Z",
|
|
17611
17631
|
fill: "currentColor"
|
|
17612
|
-
}, null, -1)),
|
|
17632
|
+
}, null, -1)), A1 = /* @__PURE__ */ ne({
|
|
17613
17633
|
__name: "DragIcon",
|
|
17614
17634
|
props: {
|
|
17615
17635
|
/** The accessibility text provided to screen readers */
|
|
@@ -17695,20 +17715,20 @@ const _r = "24px", Jd = (n, t) => {
|
|
|
17695
17715
|
width: "100%",
|
|
17696
17716
|
xmlns: "http://www.w3.org/2000/svg"
|
|
17697
17717
|
}, [
|
|
17698
|
-
n.title ? (H(), dt("title",
|
|
17699
|
-
|
|
17700
|
-
], 8,
|
|
17718
|
+
n.title ? (H(), dt("title", P1, ft(n.title), 1)) : Ht("", !0),
|
|
17719
|
+
E1
|
|
17720
|
+
], 8, O1))
|
|
17701
17721
|
]),
|
|
17702
17722
|
_: 1
|
|
17703
17723
|
}, 8, ["aria-hidden", "style"]));
|
|
17704
17724
|
}
|
|
17705
|
-
}),
|
|
17725
|
+
}), R1 = /* @__PURE__ */ Jd(A1, [["__scopeId", "data-v-b36d8f24"]]), L1 = (n) => (Qc("data-v-265f642d"), n = n(), Jc(), n), I1 = ["aria-hidden"], N1 = {
|
|
17706
17726
|
key: 0,
|
|
17707
17727
|
"data-testid": "kui-icon-svg-title"
|
|
17708
|
-
},
|
|
17728
|
+
}, F1 = /* @__PURE__ */ L1(() => /* @__PURE__ */ rt("path", {
|
|
17709
17729
|
d: "M12.025 22.05C11.7583 22.05 11.5042 22 11.2625 21.9C11.0208 21.8 10.8 21.6583 10.6 21.475L2.575 13.45C2.39167 13.25 2.25 13.0292 2.15 12.7875C2.05 12.5458 2 12.2917 2 12.025C2 11.7583 2.05 11.5 2.15 11.25C2.25 11 2.39167 10.7833 2.575 10.6L10.6 2.575C10.8 2.375 11.0208 2.22917 11.2625 2.1375C11.5042 2.04583 11.7583 2 12.025 2C12.2917 2 12.55 2.04583 12.8 2.1375C13.05 2.22917 13.2667 2.375 13.45 2.575L21.475 10.6C21.675 10.7833 21.8208 11 21.9125 11.25C22.0042 11.5 22.05 11.7583 22.05 12.025C22.05 12.2917 22.0042 12.5458 21.9125 12.7875C21.8208 13.0292 21.675 13.25 21.475 13.45L13.45 21.475C13.2667 21.6583 13.05 21.8 12.8 21.9C12.55 22 12.2917 22.05 12.025 22.05ZM11.025 13.025H13.025V7.025H11.025V13.025ZM12.025 16.025C12.3083 16.025 12.5458 15.9292 12.7375 15.7375C12.9292 15.5458 13.025 15.3083 13.025 15.025C13.025 14.7417 12.9292 14.5042 12.7375 14.3125C12.5458 14.1208 12.3083 14.025 12.025 14.025C11.7417 14.025 11.5042 14.1208 11.3125 14.3125C11.1208 14.5042 11.025 14.7417 11.025 15.025C11.025 15.3083 11.1208 15.5458 11.3125 15.7375C11.5042 15.9292 11.7417 16.025 12.025 16.025Z",
|
|
17710
17730
|
fill: "currentColor"
|
|
17711
|
-
}, null, -1)),
|
|
17731
|
+
}, null, -1)), Y1 = /* @__PURE__ */ ne({
|
|
17712
17732
|
__name: "WarningIcon",
|
|
17713
17733
|
props: {
|
|
17714
17734
|
/** The accessibility text provided to screen readers */
|
|
@@ -17794,17 +17814,17 @@ const _r = "24px", Jd = (n, t) => {
|
|
|
17794
17814
|
width: "100%",
|
|
17795
17815
|
xmlns: "http://www.w3.org/2000/svg"
|
|
17796
17816
|
}, [
|
|
17797
|
-
n.title ? (H(), dt("title",
|
|
17798
|
-
|
|
17799
|
-
], 8,
|
|
17817
|
+
n.title ? (H(), dt("title", N1, ft(n.title), 1)) : Ht("", !0),
|
|
17818
|
+
F1
|
|
17819
|
+
], 8, I1))
|
|
17800
17820
|
]),
|
|
17801
17821
|
_: 1
|
|
17802
17822
|
}, 8, ["aria-hidden", "style"]));
|
|
17803
17823
|
}
|
|
17804
|
-
}),
|
|
17824
|
+
}), W1 = /* @__PURE__ */ Jd(Y1, [["__scopeId", "data-v-265f642d"]]), U1 = "#6c7489", z1 = "#995c00", H1 = "20px", $1 = "40px", B1 = { class: "tooltip-title" }, j1 = { class: "title font-bold" }, V1 = {
|
|
17805
17825
|
key: 1,
|
|
17806
17826
|
class: "subtitle"
|
|
17807
|
-
},
|
|
17827
|
+
}, q1 = { class: "tooltip" }, X1 = { key: 0 }, G1 = { class: "display-label" }, K1 = { class: "display-value" }, Z1 = /* @__PURE__ */ ne({
|
|
17808
17828
|
__name: "ChartTooltip",
|
|
17809
17829
|
props: {
|
|
17810
17830
|
showTooltip: {
|
|
@@ -17894,24 +17914,24 @@ const _r = "24px", Jd = (n, t) => {
|
|
|
17894
17914
|
style: oe({ left: n.locked ? o.value.left : n.left, top: n.locked ? o.value.top : n.top, pointerEvents: n.locked ? "all" : "none" }),
|
|
17895
17915
|
onMousedown: l
|
|
17896
17916
|
}, [
|
|
17897
|
-
rt("div",
|
|
17898
|
-
rt("span",
|
|
17899
|
-
n.locked ? (H(), Ut(ut(
|
|
17917
|
+
rt("div", B1, [
|
|
17918
|
+
rt("span", j1, ft(n.tooltipTitle), 1),
|
|
17919
|
+
n.locked ? (H(), Ut(ut(R1), {
|
|
17900
17920
|
key: 0,
|
|
17901
17921
|
class: "drag-icon",
|
|
17902
|
-
color: ut(
|
|
17922
|
+
color: ut(U1)
|
|
17903
17923
|
}, null, 8, ["color"])) : Ht("", !0),
|
|
17904
|
-
n.context ? (H(), dt("span",
|
|
17924
|
+
n.context ? (H(), dt("span", V1, ft(n.context), 1)) : Ht("", !0)
|
|
17905
17925
|
]),
|
|
17906
|
-
rt("ul",
|
|
17907
|
-
(H(!0), dt(ir, null, Es(n.series, ({ backgroundColor: g, borderColor: v, label:
|
|
17908
|
-
n.series.length ? (H(), dt("li",
|
|
17926
|
+
rt("ul", q1, [
|
|
17927
|
+
(H(!0), dt(ir, null, Es(n.series, ({ backgroundColor: g, borderColor: v, label: p, value: m }) => (H(), dt(ir, { key: p }, [
|
|
17928
|
+
n.series.length ? (H(), dt("li", X1, [
|
|
17909
17929
|
rt("div", {
|
|
17910
17930
|
class: "tooltip-legend",
|
|
17911
17931
|
style: oe({ background: g, "border-color": v })
|
|
17912
17932
|
}, null, 4),
|
|
17913
|
-
rt("span",
|
|
17914
|
-
rt("span",
|
|
17933
|
+
rt("span", G1, ft(p), 1),
|
|
17934
|
+
rt("span", K1, ft(m), 1)
|
|
17915
17935
|
])) : Ht("", !0)
|
|
17916
17936
|
], 64))), 128))
|
|
17917
17937
|
])
|
|
@@ -17923,10 +17943,10 @@ const Ce = (n, t) => {
|
|
|
17923
17943
|
for (const [i, r] of t)
|
|
17924
17944
|
e[i] = r;
|
|
17925
17945
|
return e;
|
|
17926
|
-
}, xo = /* @__PURE__ */ Ce(
|
|
17946
|
+
}, xo = /* @__PURE__ */ Ce(Z1, [["__scopeId", "data-v-a729d798"]]), Q1 = ["onClick"], J1 = ["title"], tM = {
|
|
17927
17947
|
key: 0,
|
|
17928
17948
|
class: "sub-label"
|
|
17929
|
-
},
|
|
17949
|
+
}, eM = /* @__PURE__ */ ne({
|
|
17930
17950
|
__name: "ChartLegend",
|
|
17931
17951
|
props: {
|
|
17932
17952
|
id: {
|
|
@@ -17944,27 +17964,27 @@ const Ce = (n, t) => {
|
|
|
17944
17964
|
}
|
|
17945
17965
|
},
|
|
17946
17966
|
setup(n) {
|
|
17947
|
-
const t = n, e = at(), i = at([]), r = at(!1), a = rr("showLegendValues", !0), s = rr("legendPosition", at(
|
|
17967
|
+
const t = n, e = at(), i = at([]), r = at(!1), a = rr("showLegendValues", !0), s = rr("legendPosition", at(Ct.Right)), o = at([]), l = () => {
|
|
17948
17968
|
const v = e.value;
|
|
17949
17969
|
if (!v || !i.value || v.children.length === 0)
|
|
17950
17970
|
return 0;
|
|
17951
|
-
let
|
|
17971
|
+
let p = 1, m = v.children[0].getBoundingClientRect().top;
|
|
17952
17972
|
for (const b of i.value) {
|
|
17953
|
-
const
|
|
17954
|
-
|
|
17973
|
+
const x = b.getBoundingClientRect().top;
|
|
17974
|
+
x !== m && (p++, m = x);
|
|
17955
17975
|
}
|
|
17956
|
-
return
|
|
17976
|
+
return p;
|
|
17957
17977
|
}, c = () => {
|
|
17958
|
-
e.value && s.value ===
|
|
17978
|
+
e.value && s.value === Ct.Bottom && (l() > 1 ? r.value = !0 : r.value = !1);
|
|
17959
17979
|
}, u = () => {
|
|
17960
|
-
if (e.value && s.value ===
|
|
17980
|
+
if (e.value && s.value === Ct.Bottom) {
|
|
17961
17981
|
let v = 0;
|
|
17962
|
-
i.value.forEach((
|
|
17963
|
-
const b = Array.from(
|
|
17982
|
+
i.value.forEach((m) => {
|
|
17983
|
+
const b = Array.from(m.children).reduce((x, y) => x + y.offsetWidth, 0);
|
|
17964
17984
|
b > v && (v = b);
|
|
17965
17985
|
});
|
|
17966
|
-
const
|
|
17967
|
-
e.value.style.gridTemplateColumns = `repeat(auto-fit, ${v +
|
|
17986
|
+
const p = parseInt($1, 10);
|
|
17987
|
+
e.value.style.gridTemplateColumns = `repeat(auto-fit, ${v + p}px)`;
|
|
17968
17988
|
}
|
|
17969
17989
|
}, d = () => {
|
|
17970
17990
|
if (t.items.length !== o.value.length)
|
|
@@ -17983,81 +18003,81 @@ const Ce = (n, t) => {
|
|
|
17983
18003
|
}), Tr(() => {
|
|
17984
18004
|
window.removeEventListener("resize", c);
|
|
17985
18005
|
});
|
|
17986
|
-
const h = (v = 0,
|
|
18006
|
+
const h = (v = 0, p) => {
|
|
17987
18007
|
if (t.chartInstance === null)
|
|
17988
18008
|
return;
|
|
17989
|
-
const
|
|
17990
|
-
f(v,
|
|
17991
|
-
}, f = (v = 0,
|
|
18009
|
+
const m = t.chartInstance instanceof ae ? t.chartInstance : t.chartInstance.chart;
|
|
18010
|
+
f(v, p) ? m.hide(v, p) : m.show(v, p), m.update();
|
|
18011
|
+
}, f = (v = 0, p) => {
|
|
17992
18012
|
if (t.chartInstance === null || t.chartInstance.chart === null)
|
|
17993
18013
|
return !0;
|
|
17994
|
-
const
|
|
17995
|
-
return b.dataset ||
|
|
18014
|
+
const m = t.chartInstance instanceof ae ? t.chartInstance : t.chartInstance.chart, b = m.getDatasetMeta(v);
|
|
18015
|
+
return b.dataset || p === void 0 ? m.isDatasetVisible(v) : !(b.data.length && b.data[p].hidden);
|
|
17996
18016
|
}, g = (v) => ({
|
|
17997
|
-
[
|
|
17998
|
-
[
|
|
17999
|
-
[
|
|
18017
|
+
[Ct.Right]: "vertical",
|
|
18018
|
+
[Ct.Bottom]: "horizontal",
|
|
18019
|
+
[Ct.Hidden]: "hidden"
|
|
18000
18020
|
})[v];
|
|
18001
|
-
return (v,
|
|
18021
|
+
return (v, p) => ut(s) !== ut(Ct).Hidden ? (H(), dt("ul", {
|
|
18002
18022
|
key: 0,
|
|
18003
18023
|
ref_key: "legendContainerRef",
|
|
18004
18024
|
ref: e,
|
|
18005
18025
|
class: nn(["legend-container", g(ut(s))]),
|
|
18006
18026
|
"data-testid": "legend"
|
|
18007
18027
|
}, [
|
|
18008
|
-
(H(!0), dt(ir, null, Es(n.items, ({ fillStyle:
|
|
18009
|
-
key:
|
|
18028
|
+
(H(!0), dt(ir, null, Es(n.items, ({ fillStyle: m, strokeStyle: b, text: x, datasetIndex: y, index: w, value: _ }) => (H(), dt("li", {
|
|
18029
|
+
key: x,
|
|
18010
18030
|
ref_for: !0,
|
|
18011
18031
|
ref_key: "legendItemsRef",
|
|
18012
18032
|
ref: i,
|
|
18013
|
-
onClick: (M) => h(
|
|
18033
|
+
onClick: (M) => h(y, w)
|
|
18014
18034
|
}, [
|
|
18015
18035
|
rt("div", {
|
|
18016
18036
|
class: "legend",
|
|
18017
|
-
style: oe({ background:
|
|
18037
|
+
style: oe({ background: m, "border-color": b })
|
|
18018
18038
|
}, null, 4),
|
|
18019
18039
|
rt("div", {
|
|
18020
|
-
class: nn(["label-container", { "strike-through": !f(
|
|
18040
|
+
class: nn(["label-container", { "strike-through": !f(y, w) }])
|
|
18021
18041
|
}, [
|
|
18022
18042
|
rt("div", {
|
|
18023
18043
|
class: nn(["label", { "truncate-label": r.value }]),
|
|
18024
|
-
title: ut(s) === ut(
|
|
18025
|
-
}, ft(
|
|
18026
|
-
_ && ut(a) ? (H(), dt("div",
|
|
18044
|
+
title: ut(s) === ut(Ct).Bottom && x
|
|
18045
|
+
}, ft(x), 11, J1),
|
|
18046
|
+
_ && ut(a) ? (H(), dt("div", tM, ft(_.formatted), 1)) : Ht("", !0)
|
|
18027
18047
|
], 2)
|
|
18028
|
-
], 8,
|
|
18048
|
+
], 8, Q1))), 128))
|
|
18029
18049
|
], 2)) : Ht("", !0);
|
|
18030
18050
|
}
|
|
18031
18051
|
});
|
|
18032
|
-
const wo = /* @__PURE__ */ Ce(
|
|
18052
|
+
const wo = /* @__PURE__ */ Ce(eM, [["__scopeId", "data-v-22ddf722"]]);
|
|
18033
18053
|
let Xi;
|
|
18034
|
-
const
|
|
18035
|
-
function
|
|
18054
|
+
const nM = new Uint8Array(16);
|
|
18055
|
+
function iM() {
|
|
18036
18056
|
if (!Xi && (Xi = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto), !Xi))
|
|
18037
18057
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
18038
|
-
return Xi(
|
|
18058
|
+
return Xi(nM);
|
|
18039
18059
|
}
|
|
18040
18060
|
const Nt = [];
|
|
18041
18061
|
for (let n = 0; n < 256; ++n)
|
|
18042
18062
|
Nt.push((n + 256).toString(16).slice(1));
|
|
18043
|
-
function
|
|
18063
|
+
function rM(n, t = 0) {
|
|
18044
18064
|
return Nt[n[t + 0]] + Nt[n[t + 1]] + Nt[n[t + 2]] + Nt[n[t + 3]] + "-" + Nt[n[t + 4]] + Nt[n[t + 5]] + "-" + Nt[n[t + 6]] + Nt[n[t + 7]] + "-" + Nt[n[t + 8]] + Nt[n[t + 9]] + "-" + Nt[n[t + 10]] + Nt[n[t + 11]] + Nt[n[t + 12]] + Nt[n[t + 13]] + Nt[n[t + 14]] + Nt[n[t + 15]];
|
|
18045
18065
|
}
|
|
18046
|
-
const
|
|
18047
|
-
randomUUID:
|
|
18066
|
+
const aM = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), jc = {
|
|
18067
|
+
randomUUID: aM
|
|
18048
18068
|
};
|
|
18049
18069
|
function $e(n, t, e) {
|
|
18050
18070
|
if (jc.randomUUID && !t && !n)
|
|
18051
18071
|
return jc.randomUUID();
|
|
18052
18072
|
n = n || {};
|
|
18053
|
-
const i = n.random || (n.rng ||
|
|
18073
|
+
const i = n.random || (n.rng || iM)();
|
|
18054
18074
|
if (i[6] = i[6] & 15 | 64, i[8] = i[8] & 63 | 128, t) {
|
|
18055
18075
|
e = e || 0;
|
|
18056
18076
|
for (let r = 0; r < 16; ++r)
|
|
18057
18077
|
t[e + r] = i[r];
|
|
18058
18078
|
return t;
|
|
18059
18079
|
}
|
|
18060
|
-
return
|
|
18080
|
+
return rM(i);
|
|
18061
18081
|
}
|
|
18062
18082
|
const Vc = (n, t) => {
|
|
18063
18083
|
const e = n.ctx, i = n.scales.y, r = n.scales.x, a = t[t.length - 1].element;
|
|
@@ -18079,7 +18099,7 @@ const Vc = (n, t) => {
|
|
|
18079
18099
|
beforeDestroy(n) {
|
|
18080
18100
|
delete this.clickedElements, n.options.hover = this.previousHoverOption || n.options.hover, this.clicked = !1;
|
|
18081
18101
|
}
|
|
18082
|
-
}, qc = 6,
|
|
18102
|
+
}, qc = 6, sM = 20, oM = "100%", ua = 30, lM = 40, cM = 0, uM = 10, dM = 10, hM = 1, fM = /* @__PURE__ */ ne({
|
|
18083
18103
|
__name: "StackedBarChart",
|
|
18084
18104
|
props: {
|
|
18085
18105
|
chartData: {
|
|
@@ -18143,7 +18163,7 @@ const Vc = (n, t) => {
|
|
|
18143
18163
|
},
|
|
18144
18164
|
emits: ["heightUpdate"],
|
|
18145
18165
|
setup(n, { emit: t }) {
|
|
18146
|
-
const e = n, { i18n: i } =
|
|
18166
|
+
const e = n, { i18n: i } = St.useI18n(), r = ({ chart: k }, L) => {
|
|
18147
18167
|
var V;
|
|
18148
18168
|
const F = k.data, B = (V = F.labels) == null ? void 0 : V.indexOf(L);
|
|
18149
18169
|
return F.datasets.reduce((q, yt, pt) => {
|
|
@@ -18176,13 +18196,13 @@ const Vc = (n, t) => {
|
|
|
18176
18196
|
[`${L}-value`]: yt,
|
|
18177
18197
|
[`${L}-percent`]: pt
|
|
18178
18198
|
};
|
|
18179
|
-
}, s = at(), o = at(), l = at($e()), c = $e(), u = $e(), d = at([]), h = at(rr("legendPosition",
|
|
18199
|
+
}, s = at(), o = at(), l = at($e()), c = $e(), u = $e(), d = at([]), h = at(rr("legendPosition", Ct.Right)), f = at({
|
|
18180
18200
|
show: !1,
|
|
18181
18201
|
top: "0px",
|
|
18182
18202
|
left: "0px",
|
|
18183
18203
|
text: "",
|
|
18184
18204
|
offset: 0
|
|
18185
|
-
}), g = xt(e, "metricUnit"), v = A(() => g.value && i.t(`chartUnits.${g.value}`)),
|
|
18205
|
+
}), g = xt(e, "metricUnit"), v = A(() => g.value && i.t(`chartUnits.${g.value}`)), p = A(() => xt(e, "orientation").value === "horizontal"), m = As({
|
|
18186
18206
|
showTooltip: !1,
|
|
18187
18207
|
tooltipContext: "",
|
|
18188
18208
|
tooltipSeries: [],
|
|
@@ -18193,14 +18213,14 @@ const Vc = (n, t) => {
|
|
|
18193
18213
|
width: 0,
|
|
18194
18214
|
height: 0,
|
|
18195
18215
|
locked: !1,
|
|
18196
|
-
chartType:
|
|
18197
|
-
}), b = at(0),
|
|
18216
|
+
chartType: p.value ? zt.HORIZONTAL_BAR : zt.VERTICAL_BAR
|
|
18217
|
+
}), b = at(0), x = () => {
|
|
18198
18218
|
var k;
|
|
18199
18219
|
return e.annotations && ((k = e.chartData.labels) == null ? void 0 : k.reduce(
|
|
18200
18220
|
(L, F) => Object.assign(L, a(e.chartData, F, g.value, e.orientation)),
|
|
18201
18221
|
{}
|
|
18202
18222
|
));
|
|
18203
|
-
},
|
|
18223
|
+
}, y = {
|
|
18204
18224
|
id: l.value,
|
|
18205
18225
|
afterUpdate(k) {
|
|
18206
18226
|
b.value += 1, d.value = k.options.plugins.legend.labels.generateLabels(k).map((L) => ({ ...L, value: e.legendValues && e.legendValues[L.text] })).sort((L, F) => L.value && F.value && F.value.raw - L.value.raw);
|
|
@@ -18208,10 +18228,10 @@ const Vc = (n, t) => {
|
|
|
18208
18228
|
}, w = {
|
|
18209
18229
|
id: c,
|
|
18210
18230
|
afterUpdate(k) {
|
|
18211
|
-
k.options.plugins.annotation.annotations = e.annotations ?
|
|
18231
|
+
k.options.plugins.annotation.annotations = e.annotations ? x() : {};
|
|
18212
18232
|
}
|
|
18213
18233
|
}, T = [
|
|
18214
|
-
|
|
18234
|
+
y,
|
|
18215
18235
|
{
|
|
18216
18236
|
id: "axisHover",
|
|
18217
18237
|
// args any because it is not typed by chartjs
|
|
@@ -18220,7 +18240,7 @@ const Vc = (n, t) => {
|
|
|
18220
18240
|
if (f.value.show = !1, L.event.type === "mousemove") {
|
|
18221
18241
|
const F = L.event, B = k.options.indexAxis, V = k.scales, q = k.scales[B].getLabelForValue(Number(k.scales[B].getValueForPixel(F[B])));
|
|
18222
18242
|
if (((pt) => pt === "x" ? F.y > V.x.top : F.x < V.y.right)(B))
|
|
18223
|
-
if (
|
|
18243
|
+
if (m.locked || (m.showTooltip = !1), q.length > ps) {
|
|
18224
18244
|
const it = k.canvas.getContext("2d").measureText(q).width, ht = Math.abs(Math.round(F.x - it * 0.5)), et = Math.round(F.x + it * 0.5);
|
|
18225
18245
|
f.value.left = B === "x" ? `${(ht > 0 ? ht : et) - f.value.offset}px` : `${F.x - it * 0.5 - f.value.offset}px`, f.value.top = `${F.y - 50}px`, f.value.show = !0, f.value.text = q;
|
|
18226
18246
|
} else
|
|
@@ -18233,17 +18253,17 @@ const Vc = (n, t) => {
|
|
|
18233
18253
|
{
|
|
18234
18254
|
id: u,
|
|
18235
18255
|
afterUpdate(k) {
|
|
18236
|
-
k.options.layout.padding.right =
|
|
18256
|
+
k.options.layout.padding.right = p.value ? Q.value : 0;
|
|
18237
18257
|
}
|
|
18238
18258
|
},
|
|
18239
18259
|
th,
|
|
18240
18260
|
...e.annotations ? [w] : []
|
|
18241
18261
|
], D = A(() => e.chartData.labels && e.chartData.labels.length || 0), O = A(() => {
|
|
18242
18262
|
var L, F;
|
|
18243
|
-
let k =
|
|
18244
|
-
if (s.value && (k = s.value.width, s.value && ((L = e.chartData) != null && L.labels) && ((F = e.chartData) == null ? void 0 : F.labels.length) > ua && !
|
|
18263
|
+
let k = oM;
|
|
18264
|
+
if (s.value && (k = s.value.width, s.value && ((L = e.chartData) != null && L.labels) && ((F = e.chartData) == null ? void 0 : F.labels.length) > ua && !p.value)) {
|
|
18245
18265
|
const B = e.chartData.labels.length;
|
|
18246
|
-
k = `${s.value.offsetWidth + (B - ua) *
|
|
18266
|
+
k = `${s.value.offsetWidth + (B - ua) * lM}px`;
|
|
18247
18267
|
}
|
|
18248
18268
|
return k;
|
|
18249
18269
|
});
|
|
@@ -18252,29 +18272,29 @@ const Vc = (n, t) => {
|
|
|
18252
18272
|
return (k = e.chartData.labels) == null ? void 0 : k.length;
|
|
18253
18273
|
}, (k) => {
|
|
18254
18274
|
let L = parseInt(e.height, 10);
|
|
18255
|
-
if (k &&
|
|
18256
|
-
const F = k *
|
|
18275
|
+
if (k && p.value) {
|
|
18276
|
+
const F = k * sM;
|
|
18257
18277
|
L = Math.max(F, L);
|
|
18258
18278
|
}
|
|
18259
18279
|
t("heightUpdate", L);
|
|
18260
|
-
}),
|
|
18280
|
+
}), St.useReportChartDataForSynthetics(xt(e, "chartData"), xt(e, "syntheticsDataKey")), Mr(() => {
|
|
18261
18281
|
e.annotations && ae.register(Bc);
|
|
18262
18282
|
});
|
|
18263
18283
|
const R = A(() => {
|
|
18264
|
-
const k =
|
|
18265
|
-
tooltipState:
|
|
18284
|
+
const k = St.useBarChartOptions({
|
|
18285
|
+
tooltipState: m,
|
|
18266
18286
|
legendID: l.value,
|
|
18267
18287
|
stacked: xt(e, "stacked"),
|
|
18268
18288
|
metricAxesTitle: xt(e, "metricAxesTitle"),
|
|
18269
18289
|
dimensionAxesTitle: xt(e, "dimensionAxesTitle"),
|
|
18270
|
-
indexAxis:
|
|
18290
|
+
indexAxis: p.value ? "y" : "x"
|
|
18271
18291
|
});
|
|
18272
18292
|
return {
|
|
18273
18293
|
...k.value,
|
|
18274
18294
|
plugins: {
|
|
18275
18295
|
...k.value.plugins,
|
|
18276
18296
|
annotation: {
|
|
18277
|
-
annotations:
|
|
18297
|
+
annotations: x(),
|
|
18278
18298
|
clip: !1
|
|
18279
18299
|
}
|
|
18280
18300
|
},
|
|
@@ -18287,7 +18307,7 @@ const Vc = (n, t) => {
|
|
|
18287
18307
|
}
|
|
18288
18308
|
}
|
|
18289
18309
|
};
|
|
18290
|
-
}), P =
|
|
18310
|
+
}), P = St.useChartJSCommon(
|
|
18291
18311
|
"bar",
|
|
18292
18312
|
s,
|
|
18293
18313
|
xt(e, "chartData"),
|
|
@@ -18302,11 +18322,11 @@ const Vc = (n, t) => {
|
|
|
18302
18322
|
ae.unregister(Bc);
|
|
18303
18323
|
});
|
|
18304
18324
|
const _t = {
|
|
18305
|
-
[
|
|
18306
|
-
[
|
|
18325
|
+
[Ct.Right]: "legend-row",
|
|
18326
|
+
[Ct.Bottom]: "column"
|
|
18307
18327
|
}, N = A(() => {
|
|
18308
18328
|
if (o.value && P.value) {
|
|
18309
|
-
const k = window.devicePixelRatio, L = P.value, F = L.scales.y.width * k +
|
|
18329
|
+
const k = window.devicePixelRatio, L = P.value, F = L.scales.y.width * k + hM, B = (L.scales.y.height + L.scales.y.top + L.scales.x.height) * k, V = o.value.getContext("2d");
|
|
18310
18330
|
return V.scale(k, k), V.canvas.width = F, V.canvas.height = B, V.canvas.style.width = `${F / k}px`, V.canvas.style.height = `${B / k}px`, {
|
|
18311
18331
|
scale: k,
|
|
18312
18332
|
width: F * k,
|
|
@@ -18318,10 +18338,10 @@ const Vc = (n, t) => {
|
|
|
18318
18338
|
}), z = (k) => {
|
|
18319
18339
|
if (N.value && P.value) {
|
|
18320
18340
|
const L = N.value.scale, F = N.value.targetCtx, B = N.value.width, V = N.value.height, q = P.value, yt = q.canvas, pt = k.target;
|
|
18321
|
-
F.fillStyle = "white", pt.scrollLeft >=
|
|
18341
|
+
F.fillStyle = "white", pt.scrollLeft >= cM && pt.scrollLeft <= uM ? (F.globalCompositeOperation = "source-over", F.clearRect(0, 0, B, V), F.drawImage(yt, 0, 0, B, V, 0, 0, B, V), F.globalCompositeOperation = "destination-over", F.fillRect(0, 0, B, V)) : (F.globalCompositeOperation = "source-over", F.fillRect(0, (q.scales.y.height + q.scales.y.top + dM) * L, B, q.scales.x.height * L)), m.offset = pt.scrollLeft, f.value.offset = pt.scrollLeft;
|
|
18322
18342
|
}
|
|
18323
18343
|
}, G = ({ width: k, height: L }) => {
|
|
18324
|
-
|
|
18344
|
+
m.width = k, m.height = L;
|
|
18325
18345
|
};
|
|
18326
18346
|
ee(() => e.orientation, () => {
|
|
18327
18347
|
var k;
|
|
@@ -18329,12 +18349,12 @@ const Vc = (n, t) => {
|
|
|
18329
18349
|
const L = N.value.width, F = N.value.height;
|
|
18330
18350
|
((k = o.value) == null ? void 0 : k.getContext("2d")).clearRect(0, 0, L, F);
|
|
18331
18351
|
}
|
|
18332
|
-
|
|
18352
|
+
m.showTooltip = !1, m.locked = !1;
|
|
18333
18353
|
}), ee(() => e.annotations, (k) => {
|
|
18334
|
-
P.value && (k ? P.value.options.plugins.annotation.annotations =
|
|
18354
|
+
P.value && (k ? P.value.options.plugins.annotation.annotations = x(e.chartData) : delete P.value.options.plugins.annotation.annotations);
|
|
18335
18355
|
});
|
|
18336
18356
|
const Lt = () => {
|
|
18337
|
-
|
|
18357
|
+
m.showTooltip && (m.locked = !m.locked);
|
|
18338
18358
|
};
|
|
18339
18359
|
return (k, L) => (H(), dt("div", {
|
|
18340
18360
|
class: nn(["chart-parent", _t[h.value]])
|
|
@@ -18368,13 +18388,13 @@ const Vc = (n, t) => {
|
|
|
18368
18388
|
style: oe({ top: f.value.top, left: f.value.left })
|
|
18369
18389
|
}, ft(f.value.text), 5)) : Ht("", !0),
|
|
18370
18390
|
Se(xo, {
|
|
18371
|
-
context:
|
|
18372
|
-
left:
|
|
18373
|
-
locked:
|
|
18374
|
-
series:
|
|
18375
|
-
"show-tooltip":
|
|
18391
|
+
context: m.tooltipContext,
|
|
18392
|
+
left: m.left,
|
|
18393
|
+
locked: m.locked,
|
|
18394
|
+
series: m.tooltipSeries,
|
|
18395
|
+
"show-tooltip": m.showTooltip,
|
|
18376
18396
|
"tooltip-title": n.tooltipTitle,
|
|
18377
|
-
top:
|
|
18397
|
+
top: m.top,
|
|
18378
18398
|
onDimensions: G
|
|
18379
18399
|
}, null, 8, ["context", "left", "locked", "series", "show-tooltip", "tooltip-title", "top"]),
|
|
18380
18400
|
Se(wo, {
|
|
@@ -18385,14 +18405,14 @@ const Vc = (n, t) => {
|
|
|
18385
18405
|
], 2));
|
|
18386
18406
|
}
|
|
18387
18407
|
});
|
|
18388
|
-
const
|
|
18408
|
+
const gM = /* @__PURE__ */ Ce(fM, [["__scopeId", "data-v-2d7e4a73"]]);
|
|
18389
18409
|
/*!
|
|
18390
18410
|
* chartjs-adapter-date-fns v3.0.0
|
|
18391
18411
|
* https://www.chartjs.org
|
|
18392
18412
|
* (c) 2022 chartjs-adapter-date-fns Contributors
|
|
18393
18413
|
* Released under the MIT license
|
|
18394
18414
|
*/
|
|
18395
|
-
const
|
|
18415
|
+
const pM = {
|
|
18396
18416
|
datetime: "MMM d, yyyy, h:mm:ss aaaa",
|
|
18397
18417
|
millisecond: "h:mm:ss.SSS aaaa",
|
|
18398
18418
|
second: "h:mm:ss aaaa",
|
|
@@ -18408,7 +18428,7 @@ Au._date.override({
|
|
|
18408
18428
|
_id: "date-fns",
|
|
18409
18429
|
// DEBUG
|
|
18410
18430
|
formats: function() {
|
|
18411
|
-
return
|
|
18431
|
+
return pM;
|
|
18412
18432
|
},
|
|
18413
18433
|
parse: function(n, t) {
|
|
18414
18434
|
if (n === null || typeof n > "u")
|
|
@@ -18535,23 +18555,23 @@ const eh = {
|
|
|
18535
18555
|
type: String,
|
|
18536
18556
|
default: void 0
|
|
18537
18557
|
}
|
|
18538
|
-
},
|
|
18558
|
+
}, mM = {
|
|
18539
18559
|
type: {
|
|
18540
18560
|
type: String,
|
|
18541
18561
|
required: !0
|
|
18542
18562
|
},
|
|
18543
18563
|
...eh
|
|
18544
|
-
},
|
|
18564
|
+
}, vM = oh[0] === "2" ? (n, t) => Object.assign(n, {
|
|
18545
18565
|
attrs: t
|
|
18546
18566
|
}) : (n, t) => Object.assign(n, t);
|
|
18547
18567
|
function mn(n) {
|
|
18548
18568
|
return eu(n) ? ha(n) : n;
|
|
18549
18569
|
}
|
|
18550
|
-
function
|
|
18570
|
+
function bM(n) {
|
|
18551
18571
|
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : n;
|
|
18552
18572
|
return eu(t) ? new Proxy(n, {}) : n;
|
|
18553
18573
|
}
|
|
18554
|
-
function
|
|
18574
|
+
function yM(n, t) {
|
|
18555
18575
|
const e = n.options;
|
|
18556
18576
|
e && t && Object.assign(e, t);
|
|
18557
18577
|
}
|
|
@@ -18567,15 +18587,15 @@ function ih(n, t, e) {
|
|
|
18567
18587
|
} : (i.push(a), Object.assign(a, r), a);
|
|
18568
18588
|
});
|
|
18569
18589
|
}
|
|
18570
|
-
function
|
|
18590
|
+
function xM(n, t) {
|
|
18571
18591
|
const e = {
|
|
18572
18592
|
labels: [],
|
|
18573
18593
|
datasets: []
|
|
18574
18594
|
};
|
|
18575
18595
|
return nh(e, n.labels), ih(e, n.datasets, t), e;
|
|
18576
18596
|
}
|
|
18577
|
-
const
|
|
18578
|
-
props:
|
|
18597
|
+
const wM = ne({
|
|
18598
|
+
props: mM,
|
|
18579
18599
|
setup(n, t) {
|
|
18580
18600
|
let { expose: e } = t;
|
|
18581
18601
|
const i = at(null), r = Ps(null);
|
|
@@ -18585,7 +18605,7 @@ const xM = ne({
|
|
|
18585
18605
|
const a = () => {
|
|
18586
18606
|
if (!i.value)
|
|
18587
18607
|
return;
|
|
18588
|
-
const { type: l, data: c, options: u, plugins: d, datasetIdKey: h } = n, f =
|
|
18608
|
+
const { type: l, data: c, options: u, plugins: d, datasetIdKey: h } = n, f = xM(c, h), g = bM(f, c);
|
|
18589
18609
|
r.value = new ae(i.value, {
|
|
18590
18610
|
type: l,
|
|
18591
18611
|
data: g,
|
|
@@ -18610,12 +18630,12 @@ const xM = ne({
|
|
|
18610
18630
|
return;
|
|
18611
18631
|
let v = !1;
|
|
18612
18632
|
if (u) {
|
|
18613
|
-
const
|
|
18614
|
-
|
|
18633
|
+
const p = mn(u), m = mn(h);
|
|
18634
|
+
p && p !== m && (yM(g, p), v = !0);
|
|
18615
18635
|
}
|
|
18616
18636
|
if (d) {
|
|
18617
|
-
const
|
|
18618
|
-
|
|
18637
|
+
const p = mn(d.labels), m = mn(f.labels), b = mn(d.datasets), x = mn(f.datasets);
|
|
18638
|
+
p !== m && (nh(g.config.data, p), v = !0), b && b !== x && (ih(g.config.data, b, n.datasetIdKey), v = !0);
|
|
18619
18639
|
}
|
|
18620
18640
|
v && o(g);
|
|
18621
18641
|
}, {
|
|
@@ -18635,7 +18655,7 @@ function _o(n, t) {
|
|
|
18635
18655
|
};
|
|
18636
18656
|
return r({
|
|
18637
18657
|
chart: a
|
|
18638
|
-
}), () => tu(
|
|
18658
|
+
}), () => tu(wM, vM({
|
|
18639
18659
|
ref: s
|
|
18640
18660
|
}, {
|
|
18641
18661
|
type: n,
|
|
@@ -18644,7 +18664,7 @@ function _o(n, t) {
|
|
|
18644
18664
|
}
|
|
18645
18665
|
});
|
|
18646
18666
|
}
|
|
18647
|
-
const
|
|
18667
|
+
const _M = /* @__PURE__ */ _o("bar", ni), rh = /* @__PURE__ */ _o("doughnut", Fe), MM = /* @__PURE__ */ _o("line", ii), TM = { class: "chart-container" }, DM = /* @__PURE__ */ ne({
|
|
18648
18668
|
__name: "DoughnutChart",
|
|
18649
18669
|
props: {
|
|
18650
18670
|
chartData: {
|
|
@@ -18669,7 +18689,7 @@ const wM = /* @__PURE__ */ _o("bar", ni), rh = /* @__PURE__ */ _o("doughnut", Fe
|
|
|
18669
18689
|
legendPosition: {
|
|
18670
18690
|
type: String,
|
|
18671
18691
|
required: !1,
|
|
18672
|
-
default:
|
|
18692
|
+
default: Ct.Right
|
|
18673
18693
|
},
|
|
18674
18694
|
legendValues: {
|
|
18675
18695
|
type: Object,
|
|
@@ -18688,7 +18708,7 @@ const wM = /* @__PURE__ */ _o("bar", ni), rh = /* @__PURE__ */ _o("doughnut", Fe
|
|
|
18688
18708
|
}
|
|
18689
18709
|
},
|
|
18690
18710
|
setup(n) {
|
|
18691
|
-
const t = n, { i18n: e } =
|
|
18711
|
+
const t = n, { i18n: e } = St.useI18n(), i = at($e()), r = at($e()), a = at([]), s = A(() => t.metricUnit && e.t(`chartUnits.${t.metricUnit}`)), o = As({
|
|
18692
18712
|
showTooltip: !1,
|
|
18693
18713
|
tooltipContext: "",
|
|
18694
18714
|
tooltipSeries: [],
|
|
@@ -18702,32 +18722,32 @@ const wM = /* @__PURE__ */ _o("bar", ni), rh = /* @__PURE__ */ _o("doughnut", Fe
|
|
|
18702
18722
|
}), l = {
|
|
18703
18723
|
id: i.value,
|
|
18704
18724
|
afterUpdate(v) {
|
|
18705
|
-
a.value = v.options.plugins.legend.labels.generateLabels(v).map((
|
|
18706
|
-
...
|
|
18707
|
-
value: t.legendValues && t.legendValues[
|
|
18725
|
+
a.value = v.options.plugins.legend.labels.generateLabels(v).map((p) => ({
|
|
18726
|
+
...p,
|
|
18727
|
+
value: t.legendValues && t.legendValues[p.text],
|
|
18708
18728
|
hidden: !1
|
|
18709
18729
|
}));
|
|
18710
18730
|
}
|
|
18711
|
-
}, c = A(() => [t.chartData.datasets.reduce((
|
|
18731
|
+
}, c = A(() => [t.chartData.datasets.reduce((p, m) => (p.labels.push(m.label), p.backgroundColor.push(m.backgroundColor), p.borderColor.push(yr(m.backgroundColor, 50)), p.data.push(m.data.reduce((b, x) => b + x, 0)), p), { labels: [], backgroundColor: [], borderColor: [], data: [] })]), u = A(() => ({
|
|
18712
18732
|
...t.chartData,
|
|
18713
18733
|
datasets: c.value
|
|
18714
18734
|
}));
|
|
18715
|
-
|
|
18716
|
-
const { options: d } =
|
|
18735
|
+
St.useReportChartDataForSynthetics(xt(t, "chartData"), xt(t, "syntheticsDataKey"));
|
|
18736
|
+
const { options: d } = St.useDoughnutChartOptions({
|
|
18717
18737
|
tooltipState: o,
|
|
18718
18738
|
legendID: i.value
|
|
18719
18739
|
}), h = at(), f = (v) => ({
|
|
18720
|
-
[
|
|
18721
|
-
[
|
|
18722
|
-
[
|
|
18723
|
-
})[v], g = ({ width: v, height:
|
|
18724
|
-
o.width = v, o.height =
|
|
18740
|
+
[Ct.Right]: "legend-row",
|
|
18741
|
+
[Ct.Bottom]: "column",
|
|
18742
|
+
[Ct.Hidden]: "hidden"
|
|
18743
|
+
})[v], g = ({ width: v, height: p }) => {
|
|
18744
|
+
o.width = v, o.height = p;
|
|
18725
18745
|
};
|
|
18726
|
-
return (v,
|
|
18746
|
+
return (v, p) => (H(), dt("div", {
|
|
18727
18747
|
class: nn(["chart-parent", f(n.legendPosition)]),
|
|
18728
18748
|
"data-testid": "doughnut-chart-parent"
|
|
18729
18749
|
}, [
|
|
18730
|
-
rt("div",
|
|
18750
|
+
rt("div", TM, [
|
|
18731
18751
|
Se(ut(rh), {
|
|
18732
18752
|
ref_key: "chartInstance",
|
|
18733
18753
|
ref: h,
|
|
@@ -18755,7 +18775,7 @@ const wM = /* @__PURE__ */ _o("bar", ni), rh = /* @__PURE__ */ _o("doughnut", Fe
|
|
|
18755
18775
|
], 2));
|
|
18756
18776
|
}
|
|
18757
18777
|
});
|
|
18758
|
-
const
|
|
18778
|
+
const SM = /* @__PURE__ */ Ce(DM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n, t, e, i) => {
|
|
18759
18779
|
n.save(), n.beginPath(), n.moveTo(t, e), n.lineTo(t, i), n.lineWidth = 1, n.strokeStyle = "#0275d8", n.stroke(), n.restore();
|
|
18760
18780
|
}, da = {
|
|
18761
18781
|
id: "linePlugin",
|
|
@@ -18772,7 +18792,7 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18772
18792
|
beforeDestroy() {
|
|
18773
18793
|
delete this.clickedSegment;
|
|
18774
18794
|
}
|
|
18775
|
-
},
|
|
18795
|
+
}, kM = /* @__PURE__ */ ne({
|
|
18776
18796
|
__name: "TimeSeriesChart",
|
|
18777
18797
|
props: {
|
|
18778
18798
|
chartData: {
|
|
@@ -18845,7 +18865,7 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18845
18865
|
}
|
|
18846
18866
|
},
|
|
18847
18867
|
setup(n) {
|
|
18848
|
-
const t = n, { i18n: e } =
|
|
18868
|
+
const t = n, { i18n: e } = St.useI18n(), i = at(), r = at($e()), a = at($e()), s = at([]), o = at(), l = at(rr("legendPosition", Ct.Right)), c = A(() => t.metricUnit && e.t(`chartUnits.${t.metricUnit}`)), u = As({
|
|
18849
18869
|
showTooltip: !1,
|
|
18850
18870
|
tooltipContext: "",
|
|
18851
18871
|
tooltipSeries: [],
|
|
@@ -18859,10 +18879,10 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18859
18879
|
locked: !1
|
|
18860
18880
|
}), d = {
|
|
18861
18881
|
id: r.value,
|
|
18862
|
-
afterUpdate(
|
|
18863
|
-
s.value =
|
|
18882
|
+
afterUpdate(x) {
|
|
18883
|
+
s.value = x.options.plugins.legend.labels.generateLabels(x).map((y) => ({ ...y, value: t.legendValues && t.legendValues[y.text] })).sort((y, w) => y.value && w.value && w.value.raw - y.value.raw);
|
|
18864
18884
|
}
|
|
18865
|
-
}, h = A(() => [d, th, ...t.type === zt.TIMESERIES_LINE ? [da] : []]), { options: f } =
|
|
18885
|
+
}, h = A(() => [d, th, ...t.type === zt.TIMESERIES_LINE ? [da] : []]), { options: f } = St.useLinechartOptions({
|
|
18866
18886
|
tooltipState: u,
|
|
18867
18887
|
timeRangeMs: xt(t, "timeRangeMs"),
|
|
18868
18888
|
timeRangeSec: xt(t, "timeRangeSec"),
|
|
@@ -18873,30 +18893,30 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18873
18893
|
dimensionAxesTitle: xt(t, "dimensionAxesTitle")
|
|
18874
18894
|
}), g = A(() => ({
|
|
18875
18895
|
...t.chartData,
|
|
18876
|
-
datasets: t.chartData.datasets.map((
|
|
18896
|
+
datasets: t.chartData.datasets.map((x, y) => (Array.isArray(t.datasetColors) ? (x.backgroundColor = t.datasetColors[y % t.datasetColors.length], x.borderColor = yr(x.backgroundColor, 50)) : x.rawDimension in t.datasetColors && (x.backgroundColor = t.datasetColors[x.rawDimension], x.borderColor = yr(x.backgroundColor, 50)), x.fill = t.fill, x))
|
|
18877
18897
|
}));
|
|
18878
|
-
|
|
18879
|
-
const v = (
|
|
18880
|
-
[
|
|
18881
|
-
[
|
|
18882
|
-
[
|
|
18883
|
-
})[
|
|
18884
|
-
u.width =
|
|
18898
|
+
St.useReportChartDataForSynthetics(xt(t, "chartData"), xt(t, "syntheticsDataKey"));
|
|
18899
|
+
const v = (x) => Zx(x, { short: [$.DAILY, $.WEEKLY].includes(t.granularity) }), p = (x) => ({
|
|
18900
|
+
[Ct.Right]: "legend-row",
|
|
18901
|
+
[Ct.Bottom]: "column",
|
|
18902
|
+
[Ct.Hidden]: "hidden"
|
|
18903
|
+
})[x], m = ({ width: x, height: y }) => {
|
|
18904
|
+
u.width = x, u.height = y;
|
|
18885
18905
|
}, b = () => {
|
|
18886
|
-
var
|
|
18887
|
-
u.locked = !u.locked, i.value && ((
|
|
18906
|
+
var x, y, w;
|
|
18907
|
+
u.locked = !u.locked, i.value && ((y = (x = i.value.chart.tooltip) == null ? void 0 : x.dataPoints) != null && y.length) && (da.clickedSegment = u.locked ? (w = i.value.chart.tooltip) == null ? void 0 : w.dataPoints[0] : void 0);
|
|
18888
18908
|
};
|
|
18889
18909
|
return ee(() => t.type, () => {
|
|
18890
18910
|
u.locked = !1, u.showTooltip = !1, delete da.clickedSegment;
|
|
18891
|
-
}), (
|
|
18892
|
-
class: nn(["chart-parent",
|
|
18911
|
+
}), (x, y) => (H(), dt("div", {
|
|
18912
|
+
class: nn(["chart-parent", p(l.value)]),
|
|
18893
18913
|
"data-testid": "line-chart-parent"
|
|
18894
18914
|
}, [
|
|
18895
18915
|
rt("div", {
|
|
18896
18916
|
class: "chart-container",
|
|
18897
|
-
onClick:
|
|
18917
|
+
onClick: y[0] || (y[0] = (w) => b())
|
|
18898
18918
|
}, [
|
|
18899
|
-
n.type === ut(zt).TIMESERIES_LINE ? (H(), Ut(ut(
|
|
18919
|
+
n.type === ut(zt).TIMESERIES_LINE ? (H(), Ut(ut(MM), {
|
|
18900
18920
|
key: 0,
|
|
18901
18921
|
ref_key: "chartInstance",
|
|
18902
18922
|
ref: i,
|
|
@@ -18905,7 +18925,7 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18905
18925
|
"data-testid": "time-series-line-chart",
|
|
18906
18926
|
options: ut(f),
|
|
18907
18927
|
plugins: h.value
|
|
18908
|
-
}, null, 8, ["chart-id", "data", "options", "plugins"])) : n.type === ut(zt).TIMESERIES_BAR ? (H(), Ut(ut(
|
|
18928
|
+
}, null, 8, ["chart-id", "data", "options", "plugins"])) : n.type === ut(zt).TIMESERIES_BAR ? (H(), Ut(ut(_M), {
|
|
18909
18929
|
key: 1,
|
|
18910
18930
|
ref_key: "chartInstance",
|
|
18911
18931
|
ref: i,
|
|
@@ -18928,9 +18948,9 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18928
18948
|
"tooltip-title": n.tooltipTitle,
|
|
18929
18949
|
top: u.top,
|
|
18930
18950
|
unit: n.metricUnit,
|
|
18931
|
-
onDimensions:
|
|
18932
|
-
onLeft:
|
|
18933
|
-
onTop:
|
|
18951
|
+
onDimensions: m,
|
|
18952
|
+
onLeft: y[1] || (y[1] = (w) => u.left = w),
|
|
18953
|
+
onTop: y[2] || (y[2] = (w) => u.top = w)
|
|
18934
18954
|
}, null, 8, ["context", "left", "locked", "series", "show-tooltip", "tooltip-title", "top", "unit"]),
|
|
18935
18955
|
Se(wo, {
|
|
18936
18956
|
id: r.value,
|
|
@@ -18941,13 +18961,13 @@ const DM = /* @__PURE__ */ Ce(TM, [["__scopeId", "data-v-89d6e4ca"]]), Xc = (n,
|
|
|
18941
18961
|
], 2));
|
|
18942
18962
|
}
|
|
18943
18963
|
});
|
|
18944
|
-
const
|
|
18964
|
+
const CM = /* @__PURE__ */ Ce(kM, [["__scopeId", "data-v-19da6e6a"]]), OM = { class: "chart-header" }, PM = {
|
|
18945
18965
|
key: 0,
|
|
18946
18966
|
class: "chart-title"
|
|
18947
|
-
},
|
|
18967
|
+
}, EM = { id: "result-truncated" }, AM = { class: "limit-icon-wrapper" }, RM = {
|
|
18948
18968
|
key: 1,
|
|
18949
18969
|
class: "analytics-chart-parent"
|
|
18950
|
-
},
|
|
18970
|
+
}, LM = /* @__PURE__ */ ne({
|
|
18951
18971
|
__name: "AnalyticsChart",
|
|
18952
18972
|
props: {
|
|
18953
18973
|
chartData: {
|
|
@@ -18979,7 +18999,7 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
18979
18999
|
legendPosition: {
|
|
18980
19000
|
type: String,
|
|
18981
19001
|
required: !1,
|
|
18982
|
-
default:
|
|
19002
|
+
default: Ct.Right
|
|
18983
19003
|
},
|
|
18984
19004
|
syntheticsDataKey: {
|
|
18985
19005
|
type: String,
|
|
@@ -19010,15 +19030,15 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19010
19030
|
}
|
|
19011
19031
|
},
|
|
19012
19032
|
setup(n) {
|
|
19013
|
-
const t = n, { i18n: e } =
|
|
19033
|
+
const t = n, { i18n: e } = St.useI18n(), i = at(t.height), r = (D) => {
|
|
19014
19034
|
i.value = `${D}px`;
|
|
19015
|
-
}, a = A(() => v.value ?
|
|
19035
|
+
}, a = A(() => v.value ? St.useExploreResultToTimeDataset(
|
|
19016
19036
|
{
|
|
19017
19037
|
fill: t.chartOptions.fill,
|
|
19018
19038
|
colorPalette: t.chartOptions.chartDatasetColors || ce
|
|
19019
19039
|
},
|
|
19020
19040
|
xt(t, "chartData")
|
|
19021
|
-
).value :
|
|
19041
|
+
).value : St.useExploreResultToDatasets(
|
|
19022
19042
|
{
|
|
19023
19043
|
fill: t.chartOptions.fill,
|
|
19024
19044
|
colorPalette: t.chartOptions.chartDatasetColors || ce
|
|
@@ -19033,7 +19053,7 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19033
19053
|
}), l = A(() => {
|
|
19034
19054
|
var D;
|
|
19035
19055
|
return (D = t.chartData.meta) != null && D.metricUnits ? Object.values(t.chartData.meta.metricUnits)[0] : "";
|
|
19036
|
-
}), c = A(() => t.showLegendValues && t.legendPosition !==
|
|
19056
|
+
}), c = A(() => t.showLegendValues && t.legendPosition !== Ct.Bottom), { legendValues: u } = St.useChartLegendValues(a, t.chartOptions.type, l), d = A(() => {
|
|
19037
19057
|
var D, O, R;
|
|
19038
19058
|
return ((R = (O = (D = t.chartData) == null ? void 0 : D.meta) == null ? void 0 : O.limit) == null ? void 0 : R.toString()) || null;
|
|
19039
19059
|
}), h = A(() => {
|
|
@@ -19042,18 +19062,18 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19042
19062
|
}), f = e.t("limitedResultsShown", { maxReturned: d.value }), g = A(() => [
|
|
19043
19063
|
zt.VERTICAL_BAR.toString(),
|
|
19044
19064
|
zt.HORIZONTAL_BAR.toString()
|
|
19045
|
-
].includes(t.chartOptions.type)), v = A(() => [zt.TIMESERIES_BAR, zt.TIMESERIES_LINE].some((D) => D === t.chartOptions.type)),
|
|
19065
|
+
].includes(t.chartOptions.type)), v = A(() => [zt.TIMESERIES_BAR, zt.TIMESERIES_LINE].some((D) => D === t.chartOptions.type)), p = A(() => t.chartOptions.type === zt.DOUGHNUT), m = A(() => t.chartOptions.type.includes("Vertical") ? "vertical" : "horizontal"), b = A(() => {
|
|
19046
19066
|
var R, P, Q;
|
|
19047
19067
|
if (!((R = t.chartData) != null && R.meta.metricNames) || !((P = t.chartData) != null && P.meta.metricUnits))
|
|
19048
19068
|
return;
|
|
19049
19069
|
const D = t.chartData.meta.metricNames[0], O = t.chartData.meta.metricUnits[D];
|
|
19050
19070
|
return ((Q = t.chartOptions) == null ? void 0 : Q.metricAxesTitle) || e.te(`metricAxisTitles.${D}`) && e.te(`chartUnits.${O}`) && // @ts-ignore - dynamic i18n key
|
|
19051
19071
|
e.t(`metricAxisTitles.${D}`, { unit: e.t(`chartUnits.${O}`) }) || void 0;
|
|
19052
|
-
}),
|
|
19072
|
+
}), x = A(() => {
|
|
19053
19073
|
const D = v.value ? "Time" : Object.keys(t.chartData.meta.dimensions || t.chartData.meta.metricNames)[0];
|
|
19054
19074
|
return t.chartOptions.dimensionAxesTitle || e.te(`chartLabels.${D}`) && // @ts-ignore - dynamic i18n key
|
|
19055
19075
|
e.t(`chartLabels.${D}`) || void 0;
|
|
19056
|
-
}),
|
|
19076
|
+
}), y = A(() => {
|
|
19057
19077
|
if (t.chartData.meta.granularity && typeof t.chartData.meta.granularity != "number" && "duration" in t.chartData.meta.granularity) {
|
|
19058
19078
|
const D = Hn(t.chartData.meta.granularity.duration);
|
|
19059
19079
|
return e.t(`granularityAxisTitles.${D}`);
|
|
@@ -19071,9 +19091,9 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19071
19091
|
class: "analytics-chart-shell",
|
|
19072
19092
|
style: oe({ height: i.value, width: n.width })
|
|
19073
19093
|
}, [
|
|
19074
|
-
rt("div",
|
|
19075
|
-
n.chartTitle ? (H(), dt("div",
|
|
19076
|
-
rt("div",
|
|
19094
|
+
rt("div", OM, [
|
|
19095
|
+
n.chartTitle ? (H(), dt("div", PM, ft(n.chartTitle), 1)) : Ht("", !0),
|
|
19096
|
+
rt("div", EM, [
|
|
19077
19097
|
M.value && h.value && d.value ? (H(), Ut(R, {
|
|
19078
19098
|
key: 0,
|
|
19079
19099
|
class: "tooltip",
|
|
@@ -19084,11 +19104,11 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19084
19104
|
Le(ft(ut(f)), 1)
|
|
19085
19105
|
]),
|
|
19086
19106
|
default: te(() => [
|
|
19087
|
-
rt("div",
|
|
19088
|
-
Se(ut(
|
|
19089
|
-
color: ut(
|
|
19107
|
+
rt("div", AM, [
|
|
19108
|
+
Se(ut(W1), {
|
|
19109
|
+
color: ut(z1),
|
|
19090
19110
|
decorative: "",
|
|
19091
|
-
size: ut(
|
|
19111
|
+
size: ut(H1)
|
|
19092
19112
|
}, null, 8, ["color", "size"])
|
|
19093
19113
|
])
|
|
19094
19114
|
]),
|
|
@@ -19096,12 +19116,12 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19096
19116
|
})) : Ht("", !0)
|
|
19097
19117
|
])
|
|
19098
19118
|
]),
|
|
19099
|
-
M.value ? (H(), dt("div",
|
|
19100
|
-
v.value ? (H(), Ut(
|
|
19119
|
+
M.value ? (H(), dt("div", RM, [
|
|
19120
|
+
v.value ? (H(), Ut(CM, {
|
|
19101
19121
|
key: 0,
|
|
19102
19122
|
"chart-data": a.value,
|
|
19103
19123
|
"dataset-colors": n.chartOptions.chartDatasetColors,
|
|
19104
|
-
"dimension-axes-title":
|
|
19124
|
+
"dimension-axes-title": y.value,
|
|
19105
19125
|
fill: n.chartOptions.fill,
|
|
19106
19126
|
granularity: T.value,
|
|
19107
19127
|
"legend-values": ut(u),
|
|
@@ -19113,21 +19133,21 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19113
19133
|
"time-range-sec": s.value,
|
|
19114
19134
|
"tooltip-title": n.tooltipTitle,
|
|
19115
19135
|
type: n.chartOptions.type
|
|
19116
|
-
}, null, 8, ["chart-data", "dataset-colors", "dimension-axes-title", "fill", "granularity", "legend-values", "metric-axes-title", "metric-unit", "stacked", "synthetics-data-key", "time-range-ms", "time-range-sec", "tooltip-title", "type"])) : g.value ? (H(), Ut(
|
|
19136
|
+
}, null, 8, ["chart-data", "dataset-colors", "dimension-axes-title", "fill", "granularity", "legend-values", "metric-axes-title", "metric-unit", "stacked", "synthetics-data-key", "time-range-ms", "time-range-sec", "tooltip-title", "type"])) : g.value ? (H(), Ut(gM, {
|
|
19117
19137
|
key: 1,
|
|
19118
19138
|
annotations: n.showAnnotations,
|
|
19119
19139
|
"chart-data": a.value,
|
|
19120
19140
|
"data-testid": "bar-chart-container",
|
|
19121
|
-
"dimension-axes-title":
|
|
19141
|
+
"dimension-axes-title": x.value,
|
|
19122
19142
|
"legend-values": ut(u),
|
|
19123
19143
|
"metric-axes-title": b.value,
|
|
19124
19144
|
"metric-unit": l.value,
|
|
19125
|
-
orientation:
|
|
19145
|
+
orientation: m.value,
|
|
19126
19146
|
stacked: n.chartOptions.stacked,
|
|
19127
19147
|
"synthetics-data-key": n.syntheticsDataKey,
|
|
19128
19148
|
"tooltip-title": n.tooltipTitle,
|
|
19129
19149
|
onHeightUpdate: r
|
|
19130
|
-
}, null, 8, ["annotations", "chart-data", "dimension-axes-title", "legend-values", "metric-axes-title", "metric-unit", "orientation", "stacked", "synthetics-data-key", "tooltip-title"])) :
|
|
19150
|
+
}, null, 8, ["annotations", "chart-data", "dimension-axes-title", "legend-values", "metric-axes-title", "metric-unit", "orientation", "stacked", "synthetics-data-key", "tooltip-title"])) : p.value ? (H(), Ut(SM, {
|
|
19131
19151
|
key: 2,
|
|
19132
19152
|
"chart-data": a.value,
|
|
19133
19153
|
"dataset-colors": n.chartOptions.chartDatasetColors,
|
|
@@ -19158,14 +19178,14 @@ const kM = /* @__PURE__ */ Ce(SM, [["__scopeId", "data-v-19da6e6a"]]), CM = { cl
|
|
|
19158
19178
|
};
|
|
19159
19179
|
}
|
|
19160
19180
|
});
|
|
19161
|
-
const
|
|
19181
|
+
const lT = /* @__PURE__ */ Ce(LM, [["__scopeId", "data-v-298f3707"]]), IM = {
|
|
19162
19182
|
class: "chart-parent",
|
|
19163
19183
|
"data-testid": "doughnut-chart-parent"
|
|
19164
|
-
},
|
|
19184
|
+
}, NM = { class: "chart-totals-flex" }, FM = {
|
|
19165
19185
|
key: 1,
|
|
19166
19186
|
class: "metric-small",
|
|
19167
19187
|
"data-testid": "doughnut-chart-total"
|
|
19168
|
-
},
|
|
19188
|
+
}, YM = /* @__PURE__ */ ne({
|
|
19169
19189
|
__name: "GaugeChart",
|
|
19170
19190
|
props: {
|
|
19171
19191
|
chartData: {
|
|
@@ -19207,11 +19227,11 @@ const oT = /* @__PURE__ */ Ce(RM, [["__scopeId", "data-v-298f3707"]]), LM = {
|
|
|
19207
19227
|
}
|
|
19208
19228
|
},
|
|
19209
19229
|
setup(n) {
|
|
19210
|
-
const t = n, { i18n: e } =
|
|
19230
|
+
const t = n, { i18n: e } = St.useI18n(), i = at($e()), r = A(() => [t.chartData.datasets.reduce((g, v) => (g.labels.push(v.label), g.borderColor.push(v.backgroundColor), g.backgroundColor.push(v.backgroundColor), g.data.push(v.data.reduce((p, m) => p + m, 0)), g), { labels: [], backgroundColor: [], borderColor: [], data: [] })]), a = A(() => ({
|
|
19211
19231
|
...t.chartData,
|
|
19212
19232
|
datasets: r.value
|
|
19213
19233
|
}));
|
|
19214
|
-
|
|
19234
|
+
St.useReportChartDataForSynthetics(xt(t, "chartData"), xt(t, "syntheticsDataKey"));
|
|
19215
19235
|
const s = {
|
|
19216
19236
|
responsive: !0,
|
|
19217
19237
|
maintainAspectRatio: !0,
|
|
@@ -19235,15 +19255,15 @@ const oT = /* @__PURE__ */ Ce(RM, [["__scopeId", "data-v-298f3707"]]), LM = {
|
|
|
19235
19255
|
var f;
|
|
19236
19256
|
return `color: ${(f = r == null ? void 0 : r.value[0]) == null ? void 0 : f.backgroundColor[t.numerator]}`;
|
|
19237
19257
|
}), d = A(() => [Kn.Full, Kn.SingleMetric].includes(t.metricDisplay)), h = A(() => t.metricDisplay === Kn.Full);
|
|
19238
|
-
return (f, g) => (H(), dt("div",
|
|
19239
|
-
rt("div",
|
|
19258
|
+
return (f, g) => (H(), dt("div", IM, [
|
|
19259
|
+
rt("div", NM, [
|
|
19240
19260
|
d.value ? (H(), dt("div", {
|
|
19241
19261
|
key: 0,
|
|
19242
19262
|
class: "metric-large",
|
|
19243
19263
|
"data-testid": "doughnut-chart-metric",
|
|
19244
19264
|
style: oe(u.value)
|
|
19245
19265
|
}, ft(l.value), 5)) : Ht("", !0),
|
|
19246
|
-
h.value ? (H(), dt("div",
|
|
19266
|
+
h.value ? (H(), dt("div", FM, ft(ut(e).t("total")) + ": " + ft(c.value), 1)) : Ht("", !0)
|
|
19247
19267
|
]),
|
|
19248
19268
|
rt("div", {
|
|
19249
19269
|
class: "chart-container",
|
|
@@ -19260,10 +19280,10 @@ const oT = /* @__PURE__ */ Ce(RM, [["__scopeId", "data-v-298f3707"]]), LM = {
|
|
|
19260
19280
|
]));
|
|
19261
19281
|
}
|
|
19262
19282
|
});
|
|
19263
|
-
const
|
|
19283
|
+
const WM = /* @__PURE__ */ Ce(YM, [["__scopeId", "data-v-5871cb7a"]]), UM = { class: "simple-chart-shell" }, zM = {
|
|
19264
19284
|
key: 1,
|
|
19265
19285
|
class: "analytics-chart-parent"
|
|
19266
|
-
},
|
|
19286
|
+
}, HM = /* @__PURE__ */ ne({
|
|
19267
19287
|
__name: "SimpleChart",
|
|
19268
19288
|
props: {
|
|
19269
19289
|
chartData: {
|
|
@@ -19298,9 +19318,9 @@ const YM = /* @__PURE__ */ Ce(FM, [["__scopeId", "data-v-5871cb7a"]]), WM = { cl
|
|
|
19298
19318
|
}
|
|
19299
19319
|
},
|
|
19300
19320
|
setup(n) {
|
|
19301
|
-
const t = n, { i18n: e } =
|
|
19321
|
+
const t = n, { i18n: e } = St.useI18n(), i = A(() => {
|
|
19302
19322
|
var c;
|
|
19303
|
-
const l =
|
|
19323
|
+
const l = St.useExploreResultToDatasets(
|
|
19304
19324
|
{
|
|
19305
19325
|
colorPalette: t.chartOptions.chartDatasetColors || ce
|
|
19306
19326
|
},
|
|
@@ -19313,9 +19333,9 @@ const YM = /* @__PURE__ */ Ce(FM, [["__scopeId", "data-v-5871cb7a"]]), WM = { cl
|
|
|
19313
19333
|
}), a = A(() => t.chartOptions.type === no.GAUGE), s = A(() => t.emptyStateTitle || e.t("noDataAvailableTitle")), o = A(() => t.chartData && t.chartData.meta && t.chartData.records.length);
|
|
19314
19334
|
return (l, c) => {
|
|
19315
19335
|
const u = bn("KEmptyState");
|
|
19316
|
-
return H(), dt("div",
|
|
19317
|
-
o.value ? (H(), dt("div",
|
|
19318
|
-
a.value ? (H(), Ut(
|
|
19336
|
+
return H(), dt("div", UM, [
|
|
19337
|
+
o.value ? (H(), dt("div", zM, [
|
|
19338
|
+
a.value ? (H(), Ut(WM, {
|
|
19319
19339
|
key: 0,
|
|
19320
19340
|
"chart-data": i.value,
|
|
19321
19341
|
"dataset-colors": n.chartOptions.chartDatasetColors,
|
|
@@ -19343,20 +19363,20 @@ const YM = /* @__PURE__ */ Ce(FM, [["__scopeId", "data-v-5871cb7a"]]), WM = { cl
|
|
|
19343
19363
|
};
|
|
19344
19364
|
}
|
|
19345
19365
|
});
|
|
19346
|
-
const
|
|
19366
|
+
const cT = /* @__PURE__ */ Ce(HM, [["__scopeId", "data-v-f014a616"]]), $M = {
|
|
19347
19367
|
class: "top-n-card-title",
|
|
19348
19368
|
"data-testid": "top-n-card-title"
|
|
19349
|
-
},
|
|
19369
|
+
}, BM = {
|
|
19350
19370
|
class: "top-n-card-description",
|
|
19351
19371
|
"data-testid": "top-n-card-description"
|
|
19352
|
-
},
|
|
19372
|
+
}, jM = {
|
|
19353
19373
|
key: 3,
|
|
19354
19374
|
class: "top-n-table",
|
|
19355
19375
|
"data-testid": "top-n-table"
|
|
19356
|
-
},
|
|
19376
|
+
}, VM = { class: "table-headings" }, qM = { class: "table-row" }, XM = { class: "column-1" }, GM = { class: "column-2" }, KM = {
|
|
19357
19377
|
class: "table-body",
|
|
19358
19378
|
"data-testid": "top-n-data"
|
|
19359
|
-
},
|
|
19379
|
+
}, ZM = ["data-testid"], QM = { class: "column-1" }, JM = { class: "column-2" }, tT = /* @__PURE__ */ ne({
|
|
19360
19380
|
__name: "TopNTable",
|
|
19361
19381
|
props: {
|
|
19362
19382
|
title: {
|
|
@@ -19381,7 +19401,7 @@ const lT = /* @__PURE__ */ Ce(zM, [["__scopeId", "data-v-f014a616"]]), HM = {
|
|
|
19381
19401
|
}
|
|
19382
19402
|
},
|
|
19383
19403
|
setup(n) {
|
|
19384
|
-
const t = n, { i18n: e } =
|
|
19404
|
+
const t = n, { i18n: e } = St.useI18n(), i = A(() => t.data.records), r = A(() => {
|
|
19385
19405
|
var g;
|
|
19386
19406
|
return !!((g = i.value) != null && g.length);
|
|
19387
19407
|
}), a = A(() => {
|
|
@@ -19406,22 +19426,22 @@ const lT = /* @__PURE__ */ Ce(zM, [["__scopeId", "data-v-f014a616"]]), HM = {
|
|
|
19406
19426
|
const v = g.event;
|
|
19407
19427
|
return String(v[a.value]);
|
|
19408
19428
|
}, d = (g) => {
|
|
19409
|
-
const v = u(g),
|
|
19410
|
-
return
|
|
19429
|
+
const v = u(g), p = s.value[v];
|
|
19430
|
+
return p ? p.name : "-";
|
|
19411
19431
|
}, h = (g) => {
|
|
19412
|
-
const v = u(g),
|
|
19413
|
-
return
|
|
19432
|
+
const v = u(g), p = s.value[v];
|
|
19433
|
+
return p ? p.deleted : !1;
|
|
19414
19434
|
}, f = (g) => {
|
|
19415
19435
|
if (!o.value)
|
|
19416
19436
|
return "–";
|
|
19417
|
-
const
|
|
19418
|
-
return
|
|
19437
|
+
const p = g.event[o.value];
|
|
19438
|
+
return p ? xn(p, { capital: !0, round: !0 }) : "–";
|
|
19419
19439
|
};
|
|
19420
19440
|
return (g, v) => {
|
|
19421
|
-
const
|
|
19441
|
+
const p = bn("KEmptyState"), m = bn("KSkeleton"), b = bn("KCard");
|
|
19422
19442
|
return H(), Ut(b, { class: "kong-ui-public-top-n-table" }, lh({
|
|
19423
19443
|
body: te(() => [
|
|
19424
|
-
c.value ? (H(), Ut(
|
|
19444
|
+
c.value ? (H(), Ut(p, {
|
|
19425
19445
|
key: 0,
|
|
19426
19446
|
"cta-is-hidden": "",
|
|
19427
19447
|
"data-testid": "top-n-error-state",
|
|
@@ -19434,39 +19454,39 @@ const lT = /* @__PURE__ */ Ce(zM, [["__scopeId", "data-v-f014a616"]]), HM = {
|
|
|
19434
19454
|
Le(ft(c.value), 1)
|
|
19435
19455
|
]),
|
|
19436
19456
|
_: 1
|
|
19437
|
-
})) : n.isLoading ? (H(), Ut(
|
|
19457
|
+
})) : n.isLoading ? (H(), Ut(m, {
|
|
19438
19458
|
key: 1,
|
|
19439
19459
|
"table-columns": 2,
|
|
19440
19460
|
type: "table"
|
|
19441
|
-
})) : r.value ? (H(), dt("div",
|
|
19442
|
-
rt("div",
|
|
19443
|
-
rt("div",
|
|
19444
|
-
rt("div",
|
|
19445
|
-
rt("div",
|
|
19461
|
+
})) : r.value ? (H(), dt("div", jM, [
|
|
19462
|
+
rt("div", VM, [
|
|
19463
|
+
rt("div", qM, [
|
|
19464
|
+
rt("div", XM, ft(ut(e).t("topNTable.nameLabel")), 1),
|
|
19465
|
+
rt("div", GM, ft(l.value), 1)
|
|
19446
19466
|
])
|
|
19447
19467
|
]),
|
|
19448
|
-
rt("div",
|
|
19449
|
-
(H(!0), dt(ir, null, Es(i.value, (
|
|
19450
|
-
key: `entry-${
|
|
19468
|
+
rt("div", KM, [
|
|
19469
|
+
(H(!0), dt(ir, null, Es(i.value, (x, y) => (H(), dt("div", {
|
|
19470
|
+
key: `entry-${y}`,
|
|
19451
19471
|
class: "table-row",
|
|
19452
|
-
"data-testid": `row-${u(
|
|
19472
|
+
"data-testid": `row-${u(x)}`
|
|
19453
19473
|
}, [
|
|
19454
|
-
rt("div",
|
|
19474
|
+
rt("div", QM, [
|
|
19455
19475
|
ch(g.$slots, "name", {
|
|
19456
19476
|
record: {
|
|
19457
|
-
id: u(
|
|
19458
|
-
name: d(
|
|
19459
|
-
deleted: h(
|
|
19477
|
+
id: u(x),
|
|
19478
|
+
name: d(x),
|
|
19479
|
+
deleted: h(x),
|
|
19460
19480
|
dimension: a.value
|
|
19461
19481
|
}
|
|
19462
19482
|
}, () => [
|
|
19463
|
-
Le(ft(d(
|
|
19483
|
+
Le(ft(d(x)), 1)
|
|
19464
19484
|
], !0)
|
|
19465
19485
|
]),
|
|
19466
|
-
rt("div",
|
|
19467
|
-
], 8,
|
|
19486
|
+
rt("div", JM, " " + ft(f(x)), 1)
|
|
19487
|
+
], 8, ZM))), 128))
|
|
19468
19488
|
])
|
|
19469
|
-
])) : (H(), Ut(
|
|
19489
|
+
])) : (H(), Ut(p, {
|
|
19470
19490
|
key: 2,
|
|
19471
19491
|
"cta-is-hidden": "",
|
|
19472
19492
|
"data-testid": "top-n-empty-state",
|
|
@@ -19484,14 +19504,14 @@ const lT = /* @__PURE__ */ Ce(zM, [["__scopeId", "data-v-f014a616"]]), HM = {
|
|
|
19484
19504
|
n.title ? {
|
|
19485
19505
|
name: "title",
|
|
19486
19506
|
fn: te(() => [
|
|
19487
|
-
rt("div",
|
|
19507
|
+
rt("div", $M, ft(n.title), 1)
|
|
19488
19508
|
]),
|
|
19489
19509
|
key: "0"
|
|
19490
19510
|
} : void 0,
|
|
19491
19511
|
n.description ? {
|
|
19492
19512
|
name: "actions",
|
|
19493
19513
|
fn: te(() => [
|
|
19494
|
-
rt("div",
|
|
19514
|
+
rt("div", BM, ft(n.description), 1)
|
|
19495
19515
|
]),
|
|
19496
19516
|
key: "1"
|
|
19497
19517
|
} : void 0
|
|
@@ -19499,7 +19519,7 @@ const lT = /* @__PURE__ */ Ce(zM, [["__scopeId", "data-v-f014a616"]]), HM = {
|
|
|
19499
19519
|
};
|
|
19500
19520
|
}
|
|
19501
19521
|
});
|
|
19502
|
-
const
|
|
19522
|
+
const uT = /* @__PURE__ */ Ce(tT, [["__scopeId", "data-v-f4324893"]]), Gc = "#e0e4ea", eT = {
|
|
19503
19523
|
100: ["#c8e2fd", "#80bfff", "#4da6ff", "#1a8cff", "#0072e5", "#0059b2"],
|
|
19504
19524
|
200: ["#ceedd2", "#9edca6", "#89d595", "#6fcc83", "#44c26b", "#0bb652", "#0ca84a", "#169643", "#196e33", "#1b572a"],
|
|
19505
19525
|
300: ["#fff4db", "#ffe9b8", "#ffe2a1", "#ffd982", "#ffd062", "#fdc53b", "#f4bb1e", "#e8b00b", "#d9a30f", "#c89407"],
|
|
@@ -19507,11 +19527,11 @@ const cT = /* @__PURE__ */ Ce(JM, [["__scopeId", "data-v-f4324893"]]), Gc = "#e0
|
|
|
19507
19527
|
500: ["#ffd5d5", "#ffb6b6", "#ff9d9d", "#ff8484", "#ff6a6a", "#ff4545", "#fb1f1f", "#e90b0b", "#d40202", "#be0202"]
|
|
19508
19528
|
}, $n = (n, t) => {
|
|
19509
19529
|
let e = 1;
|
|
19510
|
-
const i =
|
|
19530
|
+
const i = eT[n], r = /* @__PURE__ */ new Map();
|
|
19511
19531
|
for (const a of t)
|
|
19512
19532
|
r.set(a, i[e]), e = e % (i.length - 1) + 1;
|
|
19513
19533
|
return r.set(-1, i[0]), r;
|
|
19514
|
-
},
|
|
19534
|
+
}, nT = /* @__PURE__ */ new Map([
|
|
19515
19535
|
[100, $n("100", [100, 101, 102, 103])],
|
|
19516
19536
|
[200, $n("200", [200, 201, 202, 203, 204, 205, 206, 207, 208, 226])],
|
|
19517
19537
|
[300, $n("300", [300, 301, 302, 303, 304, 305, 307, 308])],
|
|
@@ -19547,27 +19567,27 @@ const cT = /* @__PURE__ */ Ce(JM, [["__scopeId", "data-v-f4324893"]]), Gc = "#e0
|
|
|
19547
19567
|
451
|
|
19548
19568
|
])],
|
|
19549
19569
|
[500, $n("500", [500, 501, 502, 503, 504, 505, 506, 507, 508, 510, 511])]
|
|
19550
|
-
]),
|
|
19551
|
-
const t = parseInt(n, 10), e = Math.floor(t / 100) * 100, i =
|
|
19570
|
+
]), iT = (n) => {
|
|
19571
|
+
const t = parseInt(n, 10), e = Math.floor(t / 100) * 100, i = nT.get(e);
|
|
19552
19572
|
return i === void 0 ? Gc : i.get(t) ?? i.get(-1) ?? Gc;
|
|
19553
|
-
},
|
|
19554
|
-
const t =
|
|
19573
|
+
}, dT = (n) => {
|
|
19574
|
+
const t = iT(n);
|
|
19555
19575
|
return { solid: t, light: t };
|
|
19556
19576
|
};
|
|
19557
19577
|
export {
|
|
19558
|
-
|
|
19559
|
-
|
|
19578
|
+
lT as AnalyticsChart,
|
|
19579
|
+
Ct as ChartLegendPosition,
|
|
19560
19580
|
Kn as ChartMetricDisplay,
|
|
19561
19581
|
zt as ChartTypes,
|
|
19562
19582
|
no as ChartTypesSimple,
|
|
19563
|
-
|
|
19564
|
-
|
|
19583
|
+
cT as SimpleChart,
|
|
19584
|
+
uT as TopNTable,
|
|
19565
19585
|
Qx as accessibleGrey,
|
|
19566
|
-
|
|
19586
|
+
nT as codesInSpec,
|
|
19567
19587
|
yr as darkenColor,
|
|
19568
19588
|
ce as datavisPalette,
|
|
19569
19589
|
Gc as lightGrey,
|
|
19570
19590
|
si as lookupDatavisColor,
|
|
19571
|
-
|
|
19572
|
-
|
|
19591
|
+
dT as lookupStatusCodeCategoryColor,
|
|
19592
|
+
iT as lookupStatusCodeColor
|
|
19573
19593
|
};
|