mhz-ui 1.1.32 → 1.1.34
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/UiChart/UiChart.js +336 -329
- package/dist/UiEditor/UiEditor.js +320 -306
- package/package.json +20 -20
package/dist/UiChart/UiChart.js
CHANGED
|
@@ -429,7 +429,7 @@ class Qt {
|
|
|
429
429
|
}
|
|
430
430
|
}
|
|
431
431
|
/*!
|
|
432
|
-
* Chart.js v4.4.
|
|
432
|
+
* Chart.js v4.4.9
|
|
433
433
|
* https://www.chartjs.org
|
|
434
434
|
* (c) 2025 Chart.js Contributors
|
|
435
435
|
* Released under the MIT License
|
|
@@ -1979,13 +1979,37 @@ function jr(i, t) {
|
|
|
1979
1979
|
};
|
|
1980
1980
|
return JSON.stringify(i, s) !== JSON.stringify(t, s);
|
|
1981
1981
|
}
|
|
1982
|
+
function be(i, t, e) {
|
|
1983
|
+
return i.options.clip ? i[e] : t[e];
|
|
1984
|
+
}
|
|
1985
|
+
function $r(i, t) {
|
|
1986
|
+
const { xScale: e, yScale: s } = i;
|
|
1987
|
+
return e && s ? {
|
|
1988
|
+
left: be(e, t, "left"),
|
|
1989
|
+
right: be(e, t, "right"),
|
|
1990
|
+
top: be(s, t, "top"),
|
|
1991
|
+
bottom: be(s, t, "bottom")
|
|
1992
|
+
} : t;
|
|
1993
|
+
}
|
|
1994
|
+
function Yr(i, t) {
|
|
1995
|
+
const e = t._clip;
|
|
1996
|
+
if (e.disabled)
|
|
1997
|
+
return !1;
|
|
1998
|
+
const s = $r(t, i.chartArea);
|
|
1999
|
+
return {
|
|
2000
|
+
left: e.left === !1 ? 0 : s.left - (e.left === !0 ? 0 : e.left),
|
|
2001
|
+
right: e.right === !1 ? i.width : s.right + (e.right === !0 ? 0 : e.right),
|
|
2002
|
+
top: e.top === !1 ? 0 : s.top - (e.top === !0 ? 0 : e.top),
|
|
2003
|
+
bottom: e.bottom === !1 ? i.height : s.bottom + (e.bottom === !0 ? 0 : e.bottom)
|
|
2004
|
+
};
|
|
2005
|
+
}
|
|
1982
2006
|
/*!
|
|
1983
|
-
* Chart.js v4.4.
|
|
2007
|
+
* Chart.js v4.4.9
|
|
1984
2008
|
* https://www.chartjs.org
|
|
1985
2009
|
* (c) 2025 Chart.js Contributors
|
|
1986
2010
|
* Released under the MIT License
|
|
1987
2011
|
*/
|
|
1988
|
-
class
|
|
2012
|
+
class Xr {
|
|
1989
2013
|
constructor() {
|
|
1990
2014
|
this._request = null, this._charts = /* @__PURE__ */ new Map(), this._running = !1, this._lastDate = void 0;
|
|
1991
2015
|
}
|
|
@@ -2061,8 +2085,8 @@ class $r {
|
|
|
2061
2085
|
return this._charts.delete(t);
|
|
2062
2086
|
}
|
|
2063
2087
|
}
|
|
2064
|
-
var at = /* @__PURE__ */ new
|
|
2065
|
-
const Zi = "transparent",
|
|
2088
|
+
var at = /* @__PURE__ */ new Xr();
|
|
2089
|
+
const Zi = "transparent", Ur = {
|
|
2066
2090
|
boolean(i, t, e) {
|
|
2067
2091
|
return e > 0.5 ? t : i;
|
|
2068
2092
|
},
|
|
@@ -2074,7 +2098,7 @@ const Zi = "transparent", Yr = {
|
|
|
2074
2098
|
return i + (t - i) * e;
|
|
2075
2099
|
}
|
|
2076
2100
|
};
|
|
2077
|
-
class
|
|
2101
|
+
class Kr {
|
|
2078
2102
|
constructor(t, e, s, n) {
|
|
2079
2103
|
const o = e[s];
|
|
2080
2104
|
n = ge([
|
|
@@ -2088,7 +2112,7 @@ class Xr {
|
|
|
2088
2112
|
o,
|
|
2089
2113
|
n
|
|
2090
2114
|
]);
|
|
2091
|
-
this._active = !0, this._fn = t.fn ||
|
|
2115
|
+
this._active = !0, this._fn = t.fn || Ur[t.type || typeof r], this._easing = Zt[t.easing] || Zt.linear, this._start = Math.floor(Date.now() + (t.delay || 0)), this._duration = this._total = Math.floor(t.duration), this._loop = !!t.loop, this._target = e, this._prop = s, this._from = r, this._to = n, this._promises = void 0;
|
|
2092
2116
|
}
|
|
2093
2117
|
active() {
|
|
2094
2118
|
return this._active;
|
|
@@ -2163,11 +2187,11 @@ class pn {
|
|
|
2163
2187
|
});
|
|
2164
2188
|
}
|
|
2165
2189
|
_animateOptions(t, e) {
|
|
2166
|
-
const s = e.options, n =
|
|
2190
|
+
const s = e.options, n = Gr(t, s);
|
|
2167
2191
|
if (!n)
|
|
2168
2192
|
return [];
|
|
2169
2193
|
const o = this._createAnimations(n, s);
|
|
2170
|
-
return s.$shared &&
|
|
2194
|
+
return s.$shared && qr(t.options.$animations, s).then(() => {
|
|
2171
2195
|
t.options = s;
|
|
2172
2196
|
}, () => {
|
|
2173
2197
|
}), o;
|
|
@@ -2196,7 +2220,7 @@ class pn {
|
|
|
2196
2220
|
t[c] = h;
|
|
2197
2221
|
continue;
|
|
2198
2222
|
}
|
|
2199
|
-
o[c] = d = new
|
|
2223
|
+
o[c] = d = new Kr(u, t, c, h), n.push(d);
|
|
2200
2224
|
}
|
|
2201
2225
|
return n;
|
|
2202
2226
|
}
|
|
@@ -2210,7 +2234,7 @@ class pn {
|
|
|
2210
2234
|
return at.add(this._chart, s), !0;
|
|
2211
2235
|
}
|
|
2212
2236
|
}
|
|
2213
|
-
function
|
|
2237
|
+
function qr(i, t) {
|
|
2214
2238
|
const e = [], s = Object.keys(t);
|
|
2215
2239
|
for (let n = 0; n < s.length; n++) {
|
|
2216
2240
|
const o = i[s[n]];
|
|
@@ -2218,7 +2242,7 @@ function Ur(i, t) {
|
|
|
2218
2242
|
}
|
|
2219
2243
|
return Promise.all(e);
|
|
2220
2244
|
}
|
|
2221
|
-
function
|
|
2245
|
+
function Gr(i, t) {
|
|
2222
2246
|
if (!t)
|
|
2223
2247
|
return;
|
|
2224
2248
|
let e = i.options;
|
|
@@ -2238,7 +2262,7 @@ function Ji(i, t) {
|
|
|
2238
2262
|
end: s ? n : o
|
|
2239
2263
|
};
|
|
2240
2264
|
}
|
|
2241
|
-
function
|
|
2265
|
+
function Zr(i, t, e) {
|
|
2242
2266
|
if (e === !1)
|
|
2243
2267
|
return !1;
|
|
2244
2268
|
const s = Ji(i, e), n = Ji(t, e);
|
|
@@ -2249,7 +2273,7 @@ function qr(i, t, e) {
|
|
|
2249
2273
|
left: s.start
|
|
2250
2274
|
};
|
|
2251
2275
|
}
|
|
2252
|
-
function
|
|
2276
|
+
function Jr(i) {
|
|
2253
2277
|
let t, e, s, n;
|
|
2254
2278
|
return A(i) ? (t = i.top, e = i.right, s = i.bottom, n = i.left) : t = e = s = n = i, {
|
|
2255
2279
|
top: t,
|
|
@@ -2282,7 +2306,7 @@ function Qi(i, t, e, s = {}) {
|
|
|
2282
2306
|
}
|
|
2283
2307
|
return !h && !s.all ? 0 : t;
|
|
2284
2308
|
}
|
|
2285
|
-
function
|
|
2309
|
+
function Qr(i, t) {
|
|
2286
2310
|
const { iScale: e, vScale: s } = t, n = e.axis === "x" ? "x" : "y", o = s.axis === "x" ? "x" : "y", r = Object.keys(i), a = new Array(r.length);
|
|
2287
2311
|
let l, c, h;
|
|
2288
2312
|
for (l = 0, c = r.length; l < c; ++l)
|
|
@@ -2296,17 +2320,17 @@ function je(i, t) {
|
|
|
2296
2320
|
const e = i && i.options.stacked;
|
|
2297
2321
|
return e || e === void 0 && t.stack !== void 0;
|
|
2298
2322
|
}
|
|
2299
|
-
function
|
|
2323
|
+
function ta(i, t, e) {
|
|
2300
2324
|
return `${i.id}.${t.id}.${e.stack || e.type}`;
|
|
2301
2325
|
}
|
|
2302
|
-
function
|
|
2326
|
+
function ea(i) {
|
|
2303
2327
|
const { min: t, max: e, minDefined: s, maxDefined: n } = i.getUserBounds();
|
|
2304
2328
|
return {
|
|
2305
2329
|
min: s ? t : Number.NEGATIVE_INFINITY,
|
|
2306
2330
|
max: n ? e : Number.POSITIVE_INFINITY
|
|
2307
2331
|
};
|
|
2308
2332
|
}
|
|
2309
|
-
function
|
|
2333
|
+
function ia(i, t, e) {
|
|
2310
2334
|
const s = i[t] || (i[t] = {});
|
|
2311
2335
|
return s[e] || (s[e] = {});
|
|
2312
2336
|
}
|
|
@@ -2319,11 +2343,11 @@ function ts(i, t, e, s) {
|
|
|
2319
2343
|
return null;
|
|
2320
2344
|
}
|
|
2321
2345
|
function es(i, t) {
|
|
2322
|
-
const { chart: e, _cachedMeta: s } = i, n = e._stacks || (e._stacks = {}), { iScale: o, vScale: r, index: a } = s, l = o.axis, c = r.axis, h =
|
|
2346
|
+
const { chart: e, _cachedMeta: s } = i, n = e._stacks || (e._stacks = {}), { iScale: o, vScale: r, index: a } = s, l = o.axis, c = r.axis, h = ta(o, r, s), d = t.length;
|
|
2323
2347
|
let u;
|
|
2324
2348
|
for (let f = 0; f < d; ++f) {
|
|
2325
2349
|
const g = t[f], { [l]: p, [c]: m } = g, b = g._stacks || (g._stacks = {});
|
|
2326
|
-
u = b[c] =
|
|
2350
|
+
u = b[c] = ia(n, h, p), u[a] = m, u._top = ts(u, r, !0, s.type), u._bottom = ts(u, r, !1, s.type);
|
|
2327
2351
|
const _ = u._visualValues || (u._visualValues = {});
|
|
2328
2352
|
_[a] = m;
|
|
2329
2353
|
}
|
|
@@ -2332,7 +2356,7 @@ function $e(i, t) {
|
|
|
2332
2356
|
const e = i.scales;
|
|
2333
2357
|
return Object.keys(e).filter((s) => e[s].axis === t).shift();
|
|
2334
2358
|
}
|
|
2335
|
-
function
|
|
2359
|
+
function sa(i, t) {
|
|
2336
2360
|
return Dt(i, {
|
|
2337
2361
|
active: !1,
|
|
2338
2362
|
dataset: void 0,
|
|
@@ -2342,7 +2366,7 @@ function ea(i, t) {
|
|
|
2342
2366
|
type: "dataset"
|
|
2343
2367
|
});
|
|
2344
2368
|
}
|
|
2345
|
-
function
|
|
2369
|
+
function na(i, t, e) {
|
|
2346
2370
|
return Dt(i, {
|
|
2347
2371
|
active: !1,
|
|
2348
2372
|
dataIndex: t,
|
|
@@ -2366,7 +2390,7 @@ function Vt(i, t) {
|
|
|
2366
2390
|
}
|
|
2367
2391
|
}
|
|
2368
2392
|
}
|
|
2369
|
-
const Ye = (i) => i === "reset" || i === "none", is = (i, t) => t ? i : Object.assign({}, i),
|
|
2393
|
+
const Ye = (i) => i === "reset" || i === "none", is = (i, t) => t ? i : Object.assign({}, i), oa = (i, t, e) => i && !t.hidden && t._stacked && {
|
|
2370
2394
|
keys: mn(e, !0),
|
|
2371
2395
|
values: null
|
|
2372
2396
|
};
|
|
@@ -2412,7 +2436,7 @@ class le {
|
|
|
2412
2436
|
const t = this.getDataset(), e = t.data || (t.data = []), s = this._data;
|
|
2413
2437
|
if (A(e)) {
|
|
2414
2438
|
const n = this._cachedMeta;
|
|
2415
|
-
this._data =
|
|
2439
|
+
this._data = Qr(e, n);
|
|
2416
2440
|
} else if (s !== e) {
|
|
2417
2441
|
if (s) {
|
|
2418
2442
|
zi(s, this);
|
|
@@ -2503,10 +2527,10 @@ class le {
|
|
|
2503
2527
|
n && a && (n.values = a, r = Qi(n, o, this._cachedMeta.index)), t.min = Math.min(t.min, r), t.max = Math.max(t.max, r);
|
|
2504
2528
|
}
|
|
2505
2529
|
getMinMax(t, e) {
|
|
2506
|
-
const s = this._cachedMeta, n = s._parsed, o = s._sorted && t === s.iScale, r = n.length, a = this._getOtherScale(t), l =
|
|
2530
|
+
const s = this._cachedMeta, n = s._parsed, o = s._sorted && t === s.iScale, r = n.length, a = this._getOtherScale(t), l = oa(e, s, this.chart), c = {
|
|
2507
2531
|
min: Number.POSITIVE_INFINITY,
|
|
2508
2532
|
max: Number.NEGATIVE_INFINITY
|
|
2509
|
-
}, { min: h, max: d } =
|
|
2533
|
+
}, { min: h, max: d } = ea(a);
|
|
2510
2534
|
let u, f;
|
|
2511
2535
|
function g() {
|
|
2512
2536
|
f = n[u];
|
|
@@ -2543,7 +2567,7 @@ class le {
|
|
|
2543
2567
|
}
|
|
2544
2568
|
_update(t) {
|
|
2545
2569
|
const e = this._cachedMeta;
|
|
2546
|
-
this.update(t || "default"), e._clip =
|
|
2570
|
+
this.update(t || "default"), e._clip = Jr(D(this.options.clip, Zr(e.xScale, e.yScale, this.getMaxOverflow())));
|
|
2547
2571
|
}
|
|
2548
2572
|
update(t) {
|
|
2549
2573
|
}
|
|
@@ -2566,9 +2590,9 @@ class le {
|
|
|
2566
2590
|
let o;
|
|
2567
2591
|
if (t >= 0 && t < this._cachedMeta.data.length) {
|
|
2568
2592
|
const r = this._cachedMeta.data[t];
|
|
2569
|
-
o = r.$context || (r.$context =
|
|
2593
|
+
o = r.$context || (r.$context = na(this.getContext(), t, r)), o.parsed = this.getParsed(t), o.raw = n.data[t], o.index = o.dataIndex = t;
|
|
2570
2594
|
} else
|
|
2571
|
-
o = this.$context || (this.$context =
|
|
2595
|
+
o = this.$context || (this.$context = sa(this.chart.getContext(), this.index)), o.dataset = n, o.index = o.datasetIndex = this.index;
|
|
2572
2596
|
return o.active = !!e, o.mode = s, o;
|
|
2573
2597
|
}
|
|
2574
2598
|
resolveDatasetElementOptions(t) {
|
|
@@ -2729,7 +2753,7 @@ class le {
|
|
|
2729
2753
|
]);
|
|
2730
2754
|
}
|
|
2731
2755
|
}
|
|
2732
|
-
function
|
|
2756
|
+
function ra(i, t) {
|
|
2733
2757
|
if (!i._cache.$bar) {
|
|
2734
2758
|
const e = i.getMatchingVisibleMetas(t);
|
|
2735
2759
|
let s = [];
|
|
@@ -2739,8 +2763,8 @@ function na(i, t) {
|
|
|
2739
2763
|
}
|
|
2740
2764
|
return i._cache.$bar;
|
|
2741
2765
|
}
|
|
2742
|
-
function
|
|
2743
|
-
const t = i.iScale, e =
|
|
2766
|
+
function aa(i) {
|
|
2767
|
+
const t = i.iScale, e = ra(t, i.type);
|
|
2744
2768
|
let s = t._length, n, o, r, a;
|
|
2745
2769
|
const l = () => {
|
|
2746
2770
|
r === 32767 || r === -32768 || (ee(a) && (s = Math.min(s, Math.abs(r - a) || s)), a = r);
|
|
@@ -2751,7 +2775,7 @@ function oa(i) {
|
|
|
2751
2775
|
r = t.getPixelForTick(n), l();
|
|
2752
2776
|
return s;
|
|
2753
2777
|
}
|
|
2754
|
-
function
|
|
2778
|
+
function la(i, t, e, s) {
|
|
2755
2779
|
const n = e.barThickness;
|
|
2756
2780
|
let o, r;
|
|
2757
2781
|
return T(n) ? (o = t.min * e.categoryPercentage, r = e.barPercentage) : (o = n * s, r = 1), {
|
|
@@ -2760,7 +2784,7 @@ function ra(i, t, e, s) {
|
|
|
2760
2784
|
start: t.pixels[i] - o / 2
|
|
2761
2785
|
};
|
|
2762
2786
|
}
|
|
2763
|
-
function
|
|
2787
|
+
function ca(i, t, e, s) {
|
|
2764
2788
|
const n = t.pixels, o = n[i];
|
|
2765
2789
|
let r = i > 0 ? n[i - 1] : null, a = i < n.length - 1 ? n[i + 1] : null;
|
|
2766
2790
|
const l = e.categoryPercentage;
|
|
@@ -2772,7 +2796,7 @@ function aa(i, t, e, s) {
|
|
|
2772
2796
|
start: c
|
|
2773
2797
|
};
|
|
2774
2798
|
}
|
|
2775
|
-
function
|
|
2799
|
+
function ha(i, t, e, s) {
|
|
2776
2800
|
const n = e.parse(i[0], s), o = e.parse(i[1], s), r = Math.min(n, o), a = Math.max(n, o);
|
|
2777
2801
|
let l = r, c = a;
|
|
2778
2802
|
Math.abs(r) > Math.abs(a) && (l = a, c = r), t[e.axis] = c, t._custom = {
|
|
@@ -2785,7 +2809,7 @@ function la(i, t, e, s) {
|
|
|
2785
2809
|
};
|
|
2786
2810
|
}
|
|
2787
2811
|
function bn(i, t, e, s) {
|
|
2788
|
-
return H(i) ?
|
|
2812
|
+
return H(i) ? ha(i, t, e, s) : t[e.axis] = e.parse(i, s), t;
|
|
2789
2813
|
}
|
|
2790
2814
|
function ss(i, t, e, s) {
|
|
2791
2815
|
const n = i.iScale, o = i.vScale, r = n.getLabels(), a = n === o, l = [];
|
|
@@ -2797,10 +2821,10 @@ function ss(i, t, e, s) {
|
|
|
2797
2821
|
function Xe(i) {
|
|
2798
2822
|
return i && i.barStart !== void 0 && i.barEnd !== void 0;
|
|
2799
2823
|
}
|
|
2800
|
-
function
|
|
2824
|
+
function da(i, t, e) {
|
|
2801
2825
|
return i !== 0 ? ot(i) : (t.isHorizontal() ? 1 : -1) * (t.min >= e ? 1 : -1);
|
|
2802
2826
|
}
|
|
2803
|
-
function
|
|
2827
|
+
function ua(i) {
|
|
2804
2828
|
let t, e, s, n, o;
|
|
2805
2829
|
return i.horizontal ? (t = i.base > i.x, e = "left", s = "right") : (t = i.base < i.y, e = "bottom", s = "top"), t ? (n = "end", o = "start") : (n = "start", o = "end"), {
|
|
2806
2830
|
start: e,
|
|
@@ -2810,7 +2834,7 @@ function ha(i) {
|
|
|
2810
2834
|
bottom: o
|
|
2811
2835
|
};
|
|
2812
2836
|
}
|
|
2813
|
-
function
|
|
2837
|
+
function fa(i, t, e, s) {
|
|
2814
2838
|
let n = t.borderSkipped;
|
|
2815
2839
|
const o = {};
|
|
2816
2840
|
if (!n) {
|
|
@@ -2826,22 +2850,22 @@ function da(i, t, e, s) {
|
|
|
2826
2850
|
};
|
|
2827
2851
|
return;
|
|
2828
2852
|
}
|
|
2829
|
-
const { start: r, end: a, reverse: l, top: c, bottom: h } =
|
|
2853
|
+
const { start: r, end: a, reverse: l, top: c, bottom: h } = ua(i);
|
|
2830
2854
|
n === "middle" && e && (i.enableBorderRadius = !0, (e._top || 0) === s ? n = c : (e._bottom || 0) === s ? n = h : (o[ns(h, r, a, l)] = !0, n = c)), o[ns(n, r, a, l)] = !0, i.borderSkipped = o;
|
|
2831
2855
|
}
|
|
2832
2856
|
function ns(i, t, e, s) {
|
|
2833
|
-
return s ? (i =
|
|
2857
|
+
return s ? (i = ga(i, t, e), i = os(i, e, t)) : i = os(i, t, e), i;
|
|
2834
2858
|
}
|
|
2835
|
-
function
|
|
2859
|
+
function ga(i, t, e) {
|
|
2836
2860
|
return i === t ? e : i === e ? t : i;
|
|
2837
2861
|
}
|
|
2838
2862
|
function os(i, t, e) {
|
|
2839
2863
|
return i === "start" ? t : i === "end" ? e : i;
|
|
2840
2864
|
}
|
|
2841
|
-
function
|
|
2865
|
+
function pa(i, { inflateAmount: t }, e) {
|
|
2842
2866
|
i.inflateAmount = t === "auto" ? e === 1 ? 0.33 : 0 : t;
|
|
2843
2867
|
}
|
|
2844
|
-
class
|
|
2868
|
+
class ma extends le {
|
|
2845
2869
|
static id = "bar";
|
|
2846
2870
|
static defaults = {
|
|
2847
2871
|
datasetElementType: !1,
|
|
@@ -2931,7 +2955,7 @@ class ga extends le {
|
|
|
2931
2955
|
};
|
|
2932
2956
|
u && (_.options = d || this.resolveDataElementOptions(f, t[f].active ? "active" : n));
|
|
2933
2957
|
const y = _.options || t[f].options;
|
|
2934
|
-
|
|
2958
|
+
fa(_, y, b, r), pa(_, y, h.ratio), this.updateElement(t[f], f, _, n);
|
|
2935
2959
|
}
|
|
2936
2960
|
}
|
|
2937
2961
|
_getStacks(t, e) {
|
|
@@ -2959,7 +2983,7 @@ class ga extends le {
|
|
|
2959
2983
|
n.push(s.getPixelForValue(this.getParsed(o)[s.axis], o));
|
|
2960
2984
|
const a = t.barThickness;
|
|
2961
2985
|
return {
|
|
2962
|
-
min: a ||
|
|
2986
|
+
min: a || aa(e),
|
|
2963
2987
|
pixels: n,
|
|
2964
2988
|
start: s._startPixel,
|
|
2965
2989
|
end: s._endPixel,
|
|
@@ -2976,7 +3000,7 @@ class ga extends le {
|
|
|
2976
3000
|
const m = !T(o) && !h ? o : u;
|
|
2977
3001
|
let b = e.getPixelForValue(m);
|
|
2978
3002
|
if (this.chart.getDataVisibility(t) ? g = e.getPixelForValue(u + f) : g = b, p = g - b, Math.abs(p) < r) {
|
|
2979
|
-
p =
|
|
3003
|
+
p = da(p, e, a) * r, d === a && (b -= p / 2);
|
|
2980
3004
|
const _ = e.getPixelForDecimal(0), y = e.getPixelForDecimal(1), v = Math.min(_, y), x = Math.max(_, y);
|
|
2981
3005
|
b = Math.max(Math.min(b, x), v), g = b + p, s && !h && (l._stacks[e.axis]._visualValues[n] = e.getValueForPixel(g) - e.getValueForPixel(b));
|
|
2982
3006
|
}
|
|
@@ -2995,7 +3019,7 @@ class ga extends le {
|
|
|
2995
3019
|
const s = e.scale, n = this.options, o = n.skipNull, r = D(n.maxBarThickness, 1 / 0);
|
|
2996
3020
|
let a, l;
|
|
2997
3021
|
if (e.grouped) {
|
|
2998
|
-
const c = o ? this._getStackCount(t) : e.stackCount, h = n.barThickness === "flex" ?
|
|
3022
|
+
const c = o ? this._getStackCount(t) : e.stackCount, h = n.barThickness === "flex" ? ca(t, e, n, c) : la(t, e, n, c), d = this._getStackIndex(this.index, this._cachedMeta.stack, o ? t : void 0);
|
|
2999
3023
|
a = h.start + h.chunk * d + h.chunk / 2, l = Math.min(r, h.chunk * h.ratio);
|
|
3000
3024
|
} else
|
|
3001
3025
|
a = s.getPixelForValue(this.getParsed(t)[s.axis], t), l = Math.min(r, e.min * e.ratio);
|
|
@@ -3013,7 +3037,7 @@ class ga extends le {
|
|
|
3013
3037
|
this.getParsed(o)[e.axis] !== null && !s[o].hidden && s[o].draw(this._ctx);
|
|
3014
3038
|
}
|
|
3015
3039
|
}
|
|
3016
|
-
function
|
|
3040
|
+
function ba(i, t, e) {
|
|
3017
3041
|
let s = 1, n = 1, o = 0, r = 0;
|
|
3018
3042
|
if (t < B) {
|
|
3019
3043
|
const a = i, l = a + t, c = Math.cos(a), h = Math.sin(a), d = Math.cos(l), u = Math.sin(l), f = (y, v, x) => se(y, a, l, !0) ? 1 : Math.max(v, v * e, x, x * e), g = (y, v, x) => se(y, a, l, !0) ? -1 : Math.min(v, v * e, x, x * e), p = f(0, c, d), m = f(V, h, u), b = g(z, c, d), _ = g(z + V, h, u);
|
|
@@ -3134,7 +3158,7 @@ class _n extends le {
|
|
|
3134
3158
|
};
|
|
3135
3159
|
}
|
|
3136
3160
|
update(t) {
|
|
3137
|
-
const e = this.chart, { chartArea: s } = e, n = this._cachedMeta, o = n.data, r = this.getMaxBorderWidth() + this.getMaxOffset(o) + this.options.spacing, a = Math.max((Math.min(s.width, s.height) - r) / 2, 0), l = Math.min(yo(this.options.cutout, a), 1), c = this._getRingWeight(this.index), { circumference: h, rotation: d } = this._getRotationExtents(), { ratioX: u, ratioY: f, offsetX: g, offsetY: p } =
|
|
3161
|
+
const e = this.chart, { chartArea: s } = e, n = this._cachedMeta, o = n.data, r = this.getMaxBorderWidth() + this.getMaxOffset(o) + this.options.spacing, a = Math.max((Math.min(s.width, s.height) - r) / 2, 0), l = Math.min(yo(this.options.cutout, a), 1), c = this._getRingWeight(this.index), { circumference: h, rotation: d } = this._getRotationExtents(), { ratioX: u, ratioY: f, offsetX: g, offsetY: p } = ba(d, h, l), m = (s.width - r) / u, b = (s.height - r) / f, _ = Math.max(Math.min(m, b) / 2, 0), y = qs(this.options.radius, _), v = Math.max(y * l, 0), x = (y - v) / this._getVisibleDatasetWeightTotal();
|
|
3138
3162
|
this.offsetX = g * y, this.offsetY = p * y, n.total = this.calculateTotal(), this.outerRadius = y - x * this._getRingWeightOffset(this.index), this.innerRadius = Math.max(this.outerRadius - x * c, 0), this.updateElements(o, 0, o.length, t);
|
|
3139
3163
|
}
|
|
3140
3164
|
_circumference(t, e) {
|
|
@@ -3217,7 +3241,7 @@ class _n extends le {
|
|
|
3217
3241
|
return this._getRingWeightOffset(this.chart.data.datasets.length) || 1;
|
|
3218
3242
|
}
|
|
3219
3243
|
}
|
|
3220
|
-
class
|
|
3244
|
+
class _a extends le {
|
|
3221
3245
|
static id = "line";
|
|
3222
3246
|
static defaults = {
|
|
3223
3247
|
datasetElementType: "line",
|
|
@@ -3273,7 +3297,7 @@ class ma extends le {
|
|
|
3273
3297
|
t.dataset.updateControlPoints(this.chart.chartArea, t.iScale.axis), super.draw();
|
|
3274
3298
|
}
|
|
3275
3299
|
}
|
|
3276
|
-
class
|
|
3300
|
+
class xa extends le {
|
|
3277
3301
|
static id = "polarArea";
|
|
3278
3302
|
static defaults = {
|
|
3279
3303
|
dataElementType: "arc",
|
|
@@ -3409,7 +3433,7 @@ class ba extends le {
|
|
|
3409
3433
|
return this.chart.getDataVisibility(t) ? nt(this.resolveDataElementOptions(t, e).angle || s) : 0;
|
|
3410
3434
|
}
|
|
3411
3435
|
}
|
|
3412
|
-
class
|
|
3436
|
+
class ya extends _n {
|
|
3413
3437
|
static id = "pie";
|
|
3414
3438
|
static defaults = {
|
|
3415
3439
|
cutout: 0,
|
|
@@ -3464,10 +3488,10 @@ class Si {
|
|
|
3464
3488
|
return Mt();
|
|
3465
3489
|
}
|
|
3466
3490
|
}
|
|
3467
|
-
var
|
|
3491
|
+
var va = {
|
|
3468
3492
|
_date: Si
|
|
3469
3493
|
};
|
|
3470
|
-
function
|
|
3494
|
+
function Ma(i, t, e, s) {
|
|
3471
3495
|
const { controller: n, data: o, _sorted: r } = i, a = n._cachedMeta.iScale, l = i.dataset && i.dataset.options ? i.dataset.options.spanGaps : null;
|
|
3472
3496
|
if (a && t === a.axis && t !== "r" && r && o.length) {
|
|
3473
3497
|
const c = a._reversePixels ? Io : wt;
|
|
@@ -3501,14 +3525,14 @@ function ya(i, t, e, s) {
|
|
|
3501
3525
|
function Ie(i, t, e, s, n) {
|
|
3502
3526
|
const o = i.getSortedVisibleDatasetMetas(), r = e[t];
|
|
3503
3527
|
for (let a = 0, l = o.length; a < l; ++a) {
|
|
3504
|
-
const { index: c, data: h } = o[a], { lo: d, hi: u } =
|
|
3528
|
+
const { index: c, data: h } = o[a], { lo: d, hi: u } = Ma(o[a], t, r, n);
|
|
3505
3529
|
for (let f = d; f <= u; ++f) {
|
|
3506
3530
|
const g = h[f];
|
|
3507
3531
|
g.skip || s(g, c, f);
|
|
3508
3532
|
}
|
|
3509
3533
|
}
|
|
3510
3534
|
}
|
|
3511
|
-
function
|
|
3535
|
+
function ka(i) {
|
|
3512
3536
|
const t = i.indexOf("x") !== -1, e = i.indexOf("y") !== -1;
|
|
3513
3537
|
return function(s, n) {
|
|
3514
3538
|
const o = t ? Math.abs(s.x - n.x) : 0, r = e ? Math.abs(s.y - n.y) : 0;
|
|
@@ -3525,7 +3549,7 @@ function Ue(i, t, e, s, n) {
|
|
|
3525
3549
|
});
|
|
3526
3550
|
}, !0), o;
|
|
3527
3551
|
}
|
|
3528
|
-
function
|
|
3552
|
+
function Sa(i, t, e, s) {
|
|
3529
3553
|
let n = [];
|
|
3530
3554
|
function o(r, a, l) {
|
|
3531
3555
|
const { startAngle: c, endAngle: h } = r.getProps([
|
|
@@ -3543,9 +3567,9 @@ function Ma(i, t, e, s) {
|
|
|
3543
3567
|
}
|
|
3544
3568
|
return Ie(i, e, t, o), n;
|
|
3545
3569
|
}
|
|
3546
|
-
function
|
|
3570
|
+
function wa(i, t, e, s, n, o) {
|
|
3547
3571
|
let r = [];
|
|
3548
|
-
const a =
|
|
3572
|
+
const a = ka(e);
|
|
3549
3573
|
let l = Number.POSITIVE_INFINITY;
|
|
3550
3574
|
function c(h, d, u) {
|
|
3551
3575
|
const f = h.inRange(t.x, t.y, n);
|
|
@@ -3570,7 +3594,7 @@ function ka(i, t, e, s, n, o) {
|
|
|
3570
3594
|
return Ie(i, e, t, c), r;
|
|
3571
3595
|
}
|
|
3572
3596
|
function Ke(i, t, e, s, n, o) {
|
|
3573
|
-
return !o && !i.isPointInArea(t) ? [] : e === "r" && !s ?
|
|
3597
|
+
return !o && !i.isPointInArea(t) ? [] : e === "r" && !s ? Sa(i, t, e, n) : wa(i, t, e, s, n, o);
|
|
3574
3598
|
}
|
|
3575
3599
|
function rs(i, t, e, s, n) {
|
|
3576
3600
|
const o = [], r = e === "x" ? "inXRange" : "inYRange";
|
|
@@ -3583,7 +3607,7 @@ function rs(i, t, e, s, n) {
|
|
|
3583
3607
|
}), a = a || l.inRange(t.x, t.y, n));
|
|
3584
3608
|
}), s && !a ? [] : o;
|
|
3585
3609
|
}
|
|
3586
|
-
var
|
|
3610
|
+
var Ca = {
|
|
3587
3611
|
modes: {
|
|
3588
3612
|
index(i, t, e, s) {
|
|
3589
3613
|
const n = kt(t, i), o = e.axis || "x", r = e.includeInvisible || !1, a = e.intersect ? Ue(i, n, o, s, r) : Ke(i, n, o, !1, s, r), l = [];
|
|
@@ -3647,7 +3671,7 @@ function jt(i, t) {
|
|
|
3647
3671
|
return n.weight === o.weight ? n.index - o.index : n.weight - o.weight;
|
|
3648
3672
|
});
|
|
3649
3673
|
}
|
|
3650
|
-
function
|
|
3674
|
+
function Pa(i) {
|
|
3651
3675
|
const t = [];
|
|
3652
3676
|
let e, s, n, o, r, a;
|
|
3653
3677
|
for (e = 0, s = (i || []).length; e < s; ++e)
|
|
@@ -3662,7 +3686,7 @@ function wa(i) {
|
|
|
3662
3686
|
});
|
|
3663
3687
|
return t;
|
|
3664
3688
|
}
|
|
3665
|
-
function
|
|
3689
|
+
function Da(i) {
|
|
3666
3690
|
const t = {};
|
|
3667
3691
|
for (const e of i) {
|
|
3668
3692
|
const { stack: s, pos: n, stackWeight: o } = e;
|
|
@@ -3678,8 +3702,8 @@ function Ca(i) {
|
|
|
3678
3702
|
}
|
|
3679
3703
|
return t;
|
|
3680
3704
|
}
|
|
3681
|
-
function
|
|
3682
|
-
const e =
|
|
3705
|
+
function Oa(i, t) {
|
|
3706
|
+
const e = Da(i), { vBoxMaxWidth: s, hBoxMaxHeight: n } = t;
|
|
3683
3707
|
let o, r, a;
|
|
3684
3708
|
for (o = 0, r = i.length; o < r; ++o) {
|
|
3685
3709
|
a = i[o];
|
|
@@ -3688,8 +3712,8 @@ function Pa(i, t) {
|
|
|
3688
3712
|
}
|
|
3689
3713
|
return e;
|
|
3690
3714
|
}
|
|
3691
|
-
function
|
|
3692
|
-
const t =
|
|
3715
|
+
function Aa(i) {
|
|
3716
|
+
const t = Pa(i), e = jt(t.filter((c) => c.box.fullSize), !0), s = jt(Nt(t, "left"), !0), n = jt(Nt(t, "right")), o = jt(Nt(t, "top"), !0), r = jt(Nt(t, "bottom")), a = as(t, "x"), l = as(t, "y");
|
|
3693
3717
|
return {
|
|
3694
3718
|
fullSize: e,
|
|
3695
3719
|
leftAndTop: s.concat(o),
|
|
@@ -3705,7 +3729,7 @@ function ls(i, t, e, s) {
|
|
|
3705
3729
|
function yn(i, t) {
|
|
3706
3730
|
i.top = Math.max(i.top, t.top), i.left = Math.max(i.left, t.left), i.bottom = Math.max(i.bottom, t.bottom), i.right = Math.max(i.right, t.right);
|
|
3707
3731
|
}
|
|
3708
|
-
function
|
|
3732
|
+
function Ta(i, t, e, s) {
|
|
3709
3733
|
const { pos: n, box: o } = e, r = i.maxPadding;
|
|
3710
3734
|
if (!A(n)) {
|
|
3711
3735
|
e.size && (i[n] -= e.size);
|
|
@@ -3725,7 +3749,7 @@ function Oa(i, t, e, s) {
|
|
|
3725
3749
|
other: c
|
|
3726
3750
|
};
|
|
3727
3751
|
}
|
|
3728
|
-
function
|
|
3752
|
+
function Ra(i) {
|
|
3729
3753
|
const t = i.maxPadding;
|
|
3730
3754
|
function e(s) {
|
|
3731
3755
|
const n = Math.max(t[s] - i[s], 0);
|
|
@@ -3733,7 +3757,7 @@ function Aa(i) {
|
|
|
3733
3757
|
}
|
|
3734
3758
|
i.y += e("top"), i.x += e("left"), e("right"), e("bottom");
|
|
3735
3759
|
}
|
|
3736
|
-
function
|
|
3760
|
+
function La(i, t) {
|
|
3737
3761
|
const e = t.maxPadding;
|
|
3738
3762
|
function s(n) {
|
|
3739
3763
|
const o = {
|
|
@@ -3758,13 +3782,13 @@ function Ut(i, t, e, s) {
|
|
|
3758
3782
|
const n = [];
|
|
3759
3783
|
let o, r, a, l, c, h;
|
|
3760
3784
|
for (o = 0, r = i.length, c = 0; o < r; ++o) {
|
|
3761
|
-
a = i[o], l = a.box, l.update(a.width || t.w, a.height || t.h,
|
|
3762
|
-
const { same: d, other: u } =
|
|
3785
|
+
a = i[o], l = a.box, l.update(a.width || t.w, a.height || t.h, La(a.horizontal, t));
|
|
3786
|
+
const { same: d, other: u } = Ta(t, e, a, s);
|
|
3763
3787
|
c |= d && n.length, h = h || u, l.fullSize || n.push(a);
|
|
3764
3788
|
}
|
|
3765
3789
|
return c && Ut(n, t, e, s) || h;
|
|
3766
3790
|
}
|
|
3767
|
-
function
|
|
3791
|
+
function _e(i, t, e, s, n) {
|
|
3768
3792
|
i.top = e, i.left = t, i.right = t + s, i.bottom = e + n, i.width = s, i.height = n;
|
|
3769
3793
|
}
|
|
3770
3794
|
function cs(i, t, e, s) {
|
|
@@ -3777,10 +3801,10 @@ function cs(i, t, e, s) {
|
|
|
3777
3801
|
}, h = a.stackWeight / c.weight || 1;
|
|
3778
3802
|
if (a.horizontal) {
|
|
3779
3803
|
const d = t.w * h, u = c.size || l.height;
|
|
3780
|
-
ee(c.start) && (r = c.start), l.fullSize ?
|
|
3804
|
+
ee(c.start) && (r = c.start), l.fullSize ? _e(l, n.left, r, e.outerWidth - n.right - n.left, u) : _e(l, t.left + c.placed, r, d, u), c.start = r, c.placed += d, r = l.bottom;
|
|
3781
3805
|
} else {
|
|
3782
3806
|
const d = t.h * h, u = c.size || l.width;
|
|
3783
|
-
ee(c.start) && (o = c.start), l.fullSize ?
|
|
3807
|
+
ee(c.start) && (o = c.start), l.fullSize ? _e(l, o, n.top, u, e.outerHeight - n.bottom - n.top) : _e(l, o, t.top + c.placed, u, d), c.start = o, c.placed += d, o = l.right;
|
|
3784
3808
|
}
|
|
3785
3809
|
}
|
|
3786
3810
|
t.x = o, t.y = r;
|
|
@@ -3808,7 +3832,7 @@ var Z = {
|
|
|
3808
3832
|
update(i, t, e, s) {
|
|
3809
3833
|
if (!i)
|
|
3810
3834
|
return;
|
|
3811
|
-
const n = Q(i.options.layout.padding), o = Math.max(t - n.width, 0), r = Math.max(e - n.height, 0), a =
|
|
3835
|
+
const n = Q(i.options.layout.padding), o = Math.max(t - n.width, 0), r = Math.max(e - n.height, 0), a = Aa(i.boxes), l = a.vertical, c = a.horizontal;
|
|
3812
3836
|
R(i.boxes, (p) => {
|
|
3813
3837
|
typeof p.beforeLayout == "function" && p.beforeLayout();
|
|
3814
3838
|
});
|
|
@@ -3828,8 +3852,8 @@ var Z = {
|
|
|
3828
3852
|
h: r,
|
|
3829
3853
|
x: n.left,
|
|
3830
3854
|
y: n.top
|
|
3831
|
-
}, n), g =
|
|
3832
|
-
Ut(a.fullSize, f, d, g), Ut(l, f, d, g), Ut(c, f, d, g) && Ut(l, f, d, g),
|
|
3855
|
+
}, n), g = Oa(l.concat(c), d);
|
|
3856
|
+
Ut(a.fullSize, f, d, g), Ut(l, f, d, g), Ut(c, f, d, g) && Ut(l, f, d, g), Ra(f), cs(a.leftAndTop, f, d, g), f.x += f.w, f.y += f.h, cs(a.rightAndBottom, f, d, g), i.chartArea = {
|
|
3833
3857
|
left: f.left,
|
|
3834
3858
|
top: f.top,
|
|
3835
3859
|
right: f.left + f.w,
|
|
@@ -3872,7 +3896,7 @@ class vn {
|
|
|
3872
3896
|
updateConfig(t) {
|
|
3873
3897
|
}
|
|
3874
3898
|
}
|
|
3875
|
-
class
|
|
3899
|
+
class Ea extends vn {
|
|
3876
3900
|
acquireContext(t) {
|
|
3877
3901
|
return t && t.getContext && t.getContext("2d") || null;
|
|
3878
3902
|
}
|
|
@@ -3880,7 +3904,7 @@ class Ra extends vn {
|
|
|
3880
3904
|
t.options.animation = !1;
|
|
3881
3905
|
}
|
|
3882
3906
|
}
|
|
3883
|
-
const Se = "$chartjs",
|
|
3907
|
+
const Se = "$chartjs", Ia = {
|
|
3884
3908
|
touchstart: "mousedown",
|
|
3885
3909
|
touchmove: "mousemove",
|
|
3886
3910
|
touchend: "mouseup",
|
|
@@ -3891,7 +3915,7 @@ const Se = "$chartjs", La = {
|
|
|
3891
3915
|
pointerleave: "mouseout",
|
|
3892
3916
|
pointerout: "mouseout"
|
|
3893
3917
|
}, hs = (i) => i === null || i === "";
|
|
3894
|
-
function
|
|
3918
|
+
function Fa(i, t) {
|
|
3895
3919
|
const e = i.style, s = i.getAttribute("height"), n = i.getAttribute("width");
|
|
3896
3920
|
if (i[Se] = {
|
|
3897
3921
|
initial: {
|
|
@@ -3919,14 +3943,14 @@ function Ea(i, t) {
|
|
|
3919
3943
|
const Mn = Tr ? {
|
|
3920
3944
|
passive: !0
|
|
3921
3945
|
} : !1;
|
|
3922
|
-
function
|
|
3946
|
+
function za(i, t, e) {
|
|
3923
3947
|
i && i.addEventListener(t, e, Mn);
|
|
3924
3948
|
}
|
|
3925
|
-
function
|
|
3949
|
+
function Ba(i, t, e) {
|
|
3926
3950
|
i && i.canvas && i.canvas.removeEventListener(t, e, Mn);
|
|
3927
3951
|
}
|
|
3928
|
-
function
|
|
3929
|
-
const e =
|
|
3952
|
+
function Wa(i, t) {
|
|
3953
|
+
const e = Ia[i.type] || i.type, { x: s, y: n } = kt(i, t);
|
|
3930
3954
|
return {
|
|
3931
3955
|
type: e,
|
|
3932
3956
|
chart: t,
|
|
@@ -3940,7 +3964,7 @@ function Te(i, t) {
|
|
|
3940
3964
|
if (e === t || e.contains(t))
|
|
3941
3965
|
return !0;
|
|
3942
3966
|
}
|
|
3943
|
-
function
|
|
3967
|
+
function Ha(i, t, e) {
|
|
3944
3968
|
const s = i.canvas, n = new MutationObserver((o) => {
|
|
3945
3969
|
let r = !1;
|
|
3946
3970
|
for (const a of o)
|
|
@@ -3952,7 +3976,7 @@ function Ba(i, t, e) {
|
|
|
3952
3976
|
subtree: !0
|
|
3953
3977
|
}), n;
|
|
3954
3978
|
}
|
|
3955
|
-
function
|
|
3979
|
+
function Va(i, t, e) {
|
|
3956
3980
|
const s = i.canvas, n = new MutationObserver((o) => {
|
|
3957
3981
|
let r = !1;
|
|
3958
3982
|
for (const a of o)
|
|
@@ -3972,13 +3996,13 @@ function kn() {
|
|
|
3972
3996
|
e.currentDevicePixelRatio !== i && t();
|
|
3973
3997
|
}));
|
|
3974
3998
|
}
|
|
3975
|
-
function
|
|
3999
|
+
function Na(i, t) {
|
|
3976
4000
|
re.size || window.addEventListener("resize", kn), re.set(i, t);
|
|
3977
4001
|
}
|
|
3978
|
-
function
|
|
4002
|
+
function ja(i) {
|
|
3979
4003
|
re.delete(i), re.size || window.removeEventListener("resize", kn);
|
|
3980
4004
|
}
|
|
3981
|
-
function
|
|
4005
|
+
function $a(i, t, e) {
|
|
3982
4006
|
const s = i.canvas, n = s && ki(s);
|
|
3983
4007
|
if (!n)
|
|
3984
4008
|
return;
|
|
@@ -3989,21 +4013,21 @@ function Na(i, t, e) {
|
|
|
3989
4013
|
const l = a[0], c = l.contentRect.width, h = l.contentRect.height;
|
|
3990
4014
|
c === 0 && h === 0 || o(c, h);
|
|
3991
4015
|
});
|
|
3992
|
-
return r.observe(n),
|
|
4016
|
+
return r.observe(n), Na(i, o), r;
|
|
3993
4017
|
}
|
|
3994
4018
|
function qe(i, t, e) {
|
|
3995
|
-
e && e.disconnect(), t === "resize" &&
|
|
4019
|
+
e && e.disconnect(), t === "resize" && ja(i);
|
|
3996
4020
|
}
|
|
3997
|
-
function
|
|
4021
|
+
function Ya(i, t, e) {
|
|
3998
4022
|
const s = i.canvas, n = sn((o) => {
|
|
3999
|
-
i.ctx !== null && e(
|
|
4023
|
+
i.ctx !== null && e(Wa(o, i));
|
|
4000
4024
|
}, i);
|
|
4001
|
-
return
|
|
4025
|
+
return za(s, t, n), n;
|
|
4002
4026
|
}
|
|
4003
|
-
class
|
|
4027
|
+
class Xa extends vn {
|
|
4004
4028
|
acquireContext(t, e) {
|
|
4005
4029
|
const s = t && t.getContext && t.getContext("2d");
|
|
4006
|
-
return s && s.canvas === t ? (
|
|
4030
|
+
return s && s.canvas === t ? (Fa(t, e), s) : null;
|
|
4007
4031
|
}
|
|
4008
4032
|
releaseContext(t) {
|
|
4009
4033
|
const e = t.canvas;
|
|
@@ -4025,10 +4049,10 @@ class $a extends vn {
|
|
|
4025
4049
|
addEventListener(t, e, s) {
|
|
4026
4050
|
this.removeEventListener(t, e);
|
|
4027
4051
|
const n = t.$proxies || (t.$proxies = {}), r = {
|
|
4028
|
-
attach:
|
|
4029
|
-
detach:
|
|
4030
|
-
resize:
|
|
4031
|
-
}[e] ||
|
|
4052
|
+
attach: Ha,
|
|
4053
|
+
detach: Va,
|
|
4054
|
+
resize: $a
|
|
4055
|
+
}[e] || Ya;
|
|
4032
4056
|
n[e] = r(t, e, s);
|
|
4033
4057
|
}
|
|
4034
4058
|
removeEventListener(t, e) {
|
|
@@ -4039,7 +4063,7 @@ class $a extends vn {
|
|
|
4039
4063
|
attach: qe,
|
|
4040
4064
|
detach: qe,
|
|
4041
4065
|
resize: qe
|
|
4042
|
-
}[e] ||
|
|
4066
|
+
}[e] || Ba)(t, e, n), s[e] = void 0;
|
|
4043
4067
|
}
|
|
4044
4068
|
getDevicePixelRatio() {
|
|
4045
4069
|
return window.devicePixelRatio;
|
|
@@ -4052,8 +4076,8 @@ class $a extends vn {
|
|
|
4052
4076
|
return !!(e && e.isConnected);
|
|
4053
4077
|
}
|
|
4054
4078
|
}
|
|
4055
|
-
function
|
|
4056
|
-
return !Mi() || typeof OffscreenCanvas < "u" && i instanceof OffscreenCanvas ?
|
|
4079
|
+
function Ua(i) {
|
|
4080
|
+
return !Mi() || typeof OffscreenCanvas < "u" && i instanceof OffscreenCanvas ? Ea : Xa;
|
|
4057
4081
|
}
|
|
4058
4082
|
class ht {
|
|
4059
4083
|
static defaults = {};
|
|
@@ -4086,26 +4110,26 @@ class ht {
|
|
|
4086
4110
|
}), n;
|
|
4087
4111
|
}
|
|
4088
4112
|
}
|
|
4089
|
-
function
|
|
4090
|
-
const e = i.options.ticks, s =
|
|
4113
|
+
function Ka(i, t) {
|
|
4114
|
+
const e = i.options.ticks, s = qa(i), n = Math.min(e.maxTicksLimit || s, s), o = e.major.enabled ? Za(t) : [], r = o.length, a = o[0], l = o[r - 1], c = [];
|
|
4091
4115
|
if (r > n)
|
|
4092
|
-
return
|
|
4093
|
-
const h =
|
|
4116
|
+
return Ja(t, c, o, r / n), c;
|
|
4117
|
+
const h = Ga(o, t, n);
|
|
4094
4118
|
if (r > 0) {
|
|
4095
4119
|
let d, u;
|
|
4096
4120
|
const f = r > 1 ? Math.round((l - a) / (r - 1)) : null;
|
|
4097
|
-
for (
|
|
4098
|
-
|
|
4099
|
-
return
|
|
4121
|
+
for (xe(t, c, h, T(f) ? 0 : a - f, a), d = 0, u = r - 1; d < u; d++)
|
|
4122
|
+
xe(t, c, h, o[d], o[d + 1]);
|
|
4123
|
+
return xe(t, c, h, l, T(f) ? t.length : l + f), c;
|
|
4100
4124
|
}
|
|
4101
|
-
return
|
|
4125
|
+
return xe(t, c, h), c;
|
|
4102
4126
|
}
|
|
4103
|
-
function
|
|
4127
|
+
function qa(i) {
|
|
4104
4128
|
const t = i.options.offset, e = i._tickSize(), s = i._length / e + (t ? 0 : 1), n = i._maxLength / e;
|
|
4105
4129
|
return Math.floor(Math.min(s, n));
|
|
4106
4130
|
}
|
|
4107
|
-
function
|
|
4108
|
-
const s =
|
|
4131
|
+
function Ga(i, t, e) {
|
|
4132
|
+
const s = Qa(i), n = t.length / e;
|
|
4109
4133
|
if (!s)
|
|
4110
4134
|
return Math.max(n, 1);
|
|
4111
4135
|
const o = Do(s);
|
|
@@ -4116,19 +4140,19 @@ function Ka(i, t, e) {
|
|
|
4116
4140
|
}
|
|
4117
4141
|
return Math.max(n, 1);
|
|
4118
4142
|
}
|
|
4119
|
-
function
|
|
4143
|
+
function Za(i) {
|
|
4120
4144
|
const t = [];
|
|
4121
4145
|
let e, s;
|
|
4122
4146
|
for (e = 0, s = i.length; e < s; e++)
|
|
4123
4147
|
i[e].major && t.push(e);
|
|
4124
4148
|
return t;
|
|
4125
4149
|
}
|
|
4126
|
-
function
|
|
4150
|
+
function Ja(i, t, e, s) {
|
|
4127
4151
|
let n = 0, o = e[0], r;
|
|
4128
4152
|
for (s = Math.ceil(s), r = 0; r < i.length; r++)
|
|
4129
4153
|
r === o && (t.push(i[r]), n++, o = e[n * s]);
|
|
4130
4154
|
}
|
|
4131
|
-
function
|
|
4155
|
+
function xe(i, t, e, s, n) {
|
|
4132
4156
|
const o = D(s, 0), r = Math.min(D(n, i.length), i.length);
|
|
4133
4157
|
let a = 0, l, c, h;
|
|
4134
4158
|
for (e = Math.ceil(e), n && (l = n - s, e = l / Math.floor(l / e)), h = o; h < 0; )
|
|
@@ -4136,7 +4160,7 @@ function _e(i, t, e, s, n) {
|
|
|
4136
4160
|
for (c = Math.max(o, 0); c < r; c++)
|
|
4137
4161
|
c === h && (t.push(i[c]), a++, h = Math.round(o + a * e));
|
|
4138
4162
|
}
|
|
4139
|
-
function
|
|
4163
|
+
function Qa(i) {
|
|
4140
4164
|
const t = i.length;
|
|
4141
4165
|
let e, s;
|
|
4142
4166
|
if (t < 2)
|
|
@@ -4146,7 +4170,7 @@ function Za(i) {
|
|
|
4146
4170
|
return !1;
|
|
4147
4171
|
return s;
|
|
4148
4172
|
}
|
|
4149
|
-
const
|
|
4173
|
+
const tl = (i) => i === "left" ? "right" : i === "right" ? "left" : i, us = (i, t, e) => t === "top" || t === "left" ? i[t] + e : i[t] - e, fs = (i, t) => Math.min(t || i, i);
|
|
4150
4174
|
function gs(i, t) {
|
|
4151
4175
|
const e = [], s = i.length / t, n = i.length;
|
|
4152
4176
|
let o = 0;
|
|
@@ -4154,13 +4178,13 @@ function gs(i, t) {
|
|
|
4154
4178
|
e.push(i[Math.floor(o)]);
|
|
4155
4179
|
return e;
|
|
4156
4180
|
}
|
|
4157
|
-
function
|
|
4181
|
+
function el(i, t, e) {
|
|
4158
4182
|
const s = i.ticks.length, n = Math.min(t, s - 1), o = i._startPixel, r = i._endPixel, a = 1e-6;
|
|
4159
4183
|
let l = i.getPixelForTick(n), c;
|
|
4160
4184
|
if (!(e && (s === 1 ? c = Math.max(l - o, r - l) : t === 0 ? c = (i.getPixelForTick(1) - l) / 2 : c = (l - i.getPixelForTick(n - 1)) / 2, l += n < t ? c : -c, l < o - a || l > r + a)))
|
|
4161
4185
|
return l;
|
|
4162
4186
|
}
|
|
4163
|
-
function
|
|
4187
|
+
function il(i, t) {
|
|
4164
4188
|
R(i, (e) => {
|
|
4165
4189
|
const s = e.gc, n = s.length / 2;
|
|
4166
4190
|
let o;
|
|
@@ -4180,24 +4204,24 @@ function ps(i, t) {
|
|
|
4180
4204
|
const e = X(i.font, t), s = Q(i.padding);
|
|
4181
4205
|
return (H(i.text) ? i.text.length : 1) * e.lineHeight + s.height;
|
|
4182
4206
|
}
|
|
4183
|
-
function
|
|
4207
|
+
function sl(i, t) {
|
|
4184
4208
|
return Dt(i, {
|
|
4185
4209
|
scale: t,
|
|
4186
4210
|
type: "scale"
|
|
4187
4211
|
});
|
|
4188
4212
|
}
|
|
4189
|
-
function
|
|
4213
|
+
function nl(i, t, e) {
|
|
4190
4214
|
return Dt(i, {
|
|
4191
4215
|
tick: e,
|
|
4192
4216
|
index: t,
|
|
4193
4217
|
type: "tick"
|
|
4194
4218
|
});
|
|
4195
4219
|
}
|
|
4196
|
-
function
|
|
4220
|
+
function ol(i, t, e) {
|
|
4197
4221
|
let s = gi(i);
|
|
4198
|
-
return (e && t !== "right" || !e && t === "right") && (s =
|
|
4222
|
+
return (e && t !== "right" || !e && t === "right") && (s = tl(s)), s;
|
|
4199
4223
|
}
|
|
4200
|
-
function
|
|
4224
|
+
function rl(i, t, e, s) {
|
|
4201
4225
|
const { top: n, left: o, bottom: r, right: a, chart: l } = i, { chartArea: c, scales: h } = l;
|
|
4202
4226
|
let d = 0, u, f, g;
|
|
4203
4227
|
const p = r - n, m = a - o;
|
|
@@ -4295,7 +4319,7 @@ class Bt extends ht {
|
|
|
4295
4319
|
bottom: 0
|
|
4296
4320
|
}, s), this.ticks = null, this._labelSizes = null, this._gridLineItems = null, this._labelItems = null, this.beforeSetDimensions(), this.setDimensions(), this.afterSetDimensions(), this._maxLength = this.isHorizontal() ? this.width + s.left + s.right : this.height + s.top + s.bottom, this._dataLimitsCached || (this.beforeDataLimits(), this.determineDataLimits(), this.afterDataLimits(), this._range = ar(this, o, n), this._dataLimitsCached = !0), this.beforeBuildTicks(), this.ticks = this.buildTicks() || [], this.afterBuildTicks();
|
|
4297
4321
|
const l = a < this.ticks.length;
|
|
4298
|
-
this._convertTicksToLabels(l ? gs(this.ticks, a) : this.ticks), this.configure(), this.beforeCalculateLabelRotation(), this.calculateLabelRotation(), this.afterCalculateLabelRotation(), r.display && (r.autoSkip || r.source === "auto") && (this.ticks =
|
|
4322
|
+
this._convertTicksToLabels(l ? gs(this.ticks, a) : this.ticks), this.configure(), this.beforeCalculateLabelRotation(), this.calculateLabelRotation(), this.afterCalculateLabelRotation(), r.display && (r.autoSkip || r.source === "auto") && (this.ticks = Ka(this, this.ticks), this._labelSizes = null, this.afterAutoSkip()), l && this._convertTicksToLabels(this.ticks), this.beforeFit(), this.fit(), this.afterFit(), this.afterUpdate();
|
|
4299
4323
|
}
|
|
4300
4324
|
configure() {
|
|
4301
4325
|
let t = this.options.reverse, e, s;
|
|
@@ -4465,7 +4489,7 @@ class Bt extends ht {
|
|
|
4465
4489
|
x = g[u], !T(x) && !H(x) && (y = Ni(n, b.data, b.gc, y, x), v += _);
|
|
4466
4490
|
r.push(y), a.push(v), c = Math.max(y, c), h = Math.max(v, h);
|
|
4467
4491
|
}
|
|
4468
|
-
|
|
4492
|
+
il(o, e);
|
|
4469
4493
|
const k = r.indexOf(c), S = a.indexOf(h), M = (w) => ({
|
|
4470
4494
|
width: r[w] || 0,
|
|
4471
4495
|
height: a[w] || 0
|
|
@@ -4511,9 +4535,9 @@ class Bt extends ht {
|
|
|
4511
4535
|
const e = this.ticks || [];
|
|
4512
4536
|
if (t >= 0 && t < e.length) {
|
|
4513
4537
|
const s = e[t];
|
|
4514
|
-
return s.$context || (s.$context =
|
|
4538
|
+
return s.$context || (s.$context = nl(this.getContext(), t, s));
|
|
4515
4539
|
}
|
|
4516
|
-
return this.$context || (this.$context =
|
|
4540
|
+
return this.$context || (this.$context = sl(this.chart.getContext(), this));
|
|
4517
4541
|
}
|
|
4518
4542
|
_tickSize() {
|
|
4519
4543
|
const t = this.options.ticks, e = nt(this.labelRotation), s = Math.abs(Math.cos(e)), n = Math.abs(Math.sin(e)), o = this._getLabelSizes(), r = t.autoSkipPadding || 0, a = o ? o.widest.width + r : 0, l = o ? o.highest.height + r : 0;
|
|
@@ -4556,7 +4580,7 @@ class Bt extends ht {
|
|
|
4556
4580
|
const q = D(n.ticks.maxTicksLimit, d), L = Math.max(1, Math.ceil(d / q));
|
|
4557
4581
|
for (y = 0; y < d; y += L) {
|
|
4558
4582
|
const I = this.getContext(y), W = o.setContext(I), tt = a.setContext(I), j = W.lineWidth, Ot = W.color, ce = tt.dash || [], At = tt.dashOffset, Wt = W.tickWidth, _t = W.tickColor, Ht = W.tickBorderDash || [], xt = W.tickBorderDashOffset;
|
|
4559
|
-
v =
|
|
4583
|
+
v = el(this, y, l), v !== void 0 && (x = vt(s, v, j), c ? k = M = P = O = x : S = w = C = N = x, f.push({
|
|
4560
4584
|
tx1: k,
|
|
4561
4585
|
ty1: S,
|
|
4562
4586
|
tx2: M,
|
|
@@ -4769,12 +4793,12 @@ class Bt extends ht {
|
|
|
4769
4793
|
const o = X(s.font), r = Q(s.padding), a = s.align;
|
|
4770
4794
|
let l = o.lineHeight / 2;
|
|
4771
4795
|
e === "bottom" || e === "center" || A(e) ? (l += r.bottom, H(s.text) && (l += o.lineHeight * (s.text.length - 1))) : l += r.top;
|
|
4772
|
-
const { titleX: c, titleY: h, maxWidth: d, rotation: u } =
|
|
4796
|
+
const { titleX: c, titleY: h, maxWidth: d, rotation: u } = rl(this, l, e, a);
|
|
4773
4797
|
oe(t, s.text, 0, 0, o, {
|
|
4774
4798
|
color: s.color,
|
|
4775
4799
|
maxWidth: d,
|
|
4776
4800
|
rotation: u,
|
|
4777
|
-
textAlign:
|
|
4801
|
+
textAlign: ol(a, e, n),
|
|
4778
4802
|
textBaseline: "middle",
|
|
4779
4803
|
translation: [
|
|
4780
4804
|
c,
|
|
@@ -4833,7 +4857,7 @@ class Bt extends ht {
|
|
|
4833
4857
|
return (this.isHorizontal() ? this.width : this.height) / t;
|
|
4834
4858
|
}
|
|
4835
4859
|
}
|
|
4836
|
-
class
|
|
4860
|
+
class ye {
|
|
4837
4861
|
constructor(t, e, s) {
|
|
4838
4862
|
this.type = t, this.scope = e, this.override = s, this.items = /* @__PURE__ */ Object.create(null);
|
|
4839
4863
|
}
|
|
@@ -4843,11 +4867,11 @@ class xe {
|
|
|
4843
4867
|
register(t) {
|
|
4844
4868
|
const e = Object.getPrototypeOf(t);
|
|
4845
4869
|
let s;
|
|
4846
|
-
|
|
4870
|
+
cl(e) && (s = this.register(e));
|
|
4847
4871
|
const n = this.items, o = t.id, r = this.scope + "." + o;
|
|
4848
4872
|
if (!o)
|
|
4849
4873
|
throw new Error("class does not have id: " + t);
|
|
4850
|
-
return o in n || (n[o] = t,
|
|
4874
|
+
return o in n || (n[o] = t, al(t, r, s), this.override && F.override(t.id, t.overrides)), r;
|
|
4851
4875
|
}
|
|
4852
4876
|
get(t) {
|
|
4853
4877
|
return this.items[t];
|
|
@@ -4857,15 +4881,15 @@ class xe {
|
|
|
4857
4881
|
s in e && delete e[s], n && s in F[n] && (delete F[n][s], this.override && delete Pt[s]);
|
|
4858
4882
|
}
|
|
4859
4883
|
}
|
|
4860
|
-
function
|
|
4884
|
+
function al(i, t, e) {
|
|
4861
4885
|
const s = te(/* @__PURE__ */ Object.create(null), [
|
|
4862
4886
|
e ? F.get(e) : {},
|
|
4863
4887
|
F.get(t),
|
|
4864
4888
|
i.defaults
|
|
4865
4889
|
]);
|
|
4866
|
-
F.set(t, s), i.defaultRoutes &&
|
|
4890
|
+
F.set(t, s), i.defaultRoutes && ll(t, i.defaultRoutes), i.descriptors && F.describe(t, i.descriptors);
|
|
4867
4891
|
}
|
|
4868
|
-
function
|
|
4892
|
+
function ll(i, t) {
|
|
4869
4893
|
Object.keys(t).forEach((e) => {
|
|
4870
4894
|
const s = e.split("."), n = s.pop(), o = [
|
|
4871
4895
|
i
|
|
@@ -4873,12 +4897,12 @@ function rl(i, t) {
|
|
|
4873
4897
|
F.route(o, n, l, a);
|
|
4874
4898
|
});
|
|
4875
4899
|
}
|
|
4876
|
-
function
|
|
4900
|
+
function cl(i) {
|
|
4877
4901
|
return "id" in i && "defaults" in i;
|
|
4878
4902
|
}
|
|
4879
|
-
class
|
|
4903
|
+
class hl {
|
|
4880
4904
|
constructor() {
|
|
4881
|
-
this.controllers = new
|
|
4905
|
+
this.controllers = new ye(le, "datasets", !0), this.elements = new ye(ht, "elements"), this.plugins = new ye(Object, "plugins"), this.scales = new ye(Bt, "scales"), this._typedRegistries = [
|
|
4882
4906
|
this.controllers,
|
|
4883
4907
|
this.scales,
|
|
4884
4908
|
this.elements
|
|
@@ -4956,8 +4980,8 @@ class ll {
|
|
|
4956
4980
|
return n;
|
|
4957
4981
|
}
|
|
4958
4982
|
}
|
|
4959
|
-
var st = /* @__PURE__ */ new
|
|
4960
|
-
class
|
|
4983
|
+
var st = /* @__PURE__ */ new hl();
|
|
4984
|
+
class dl {
|
|
4961
4985
|
constructor() {
|
|
4962
4986
|
this._init = [];
|
|
4963
4987
|
}
|
|
@@ -4989,15 +5013,15 @@ class cl {
|
|
|
4989
5013
|
return this._notifyStateChanges(t), e;
|
|
4990
5014
|
}
|
|
4991
5015
|
_createDescriptors(t, e) {
|
|
4992
|
-
const s = t && t.config, n = D(s.options && s.options.plugins, {}), o =
|
|
4993
|
-
return n === !1 && !e ? [] :
|
|
5016
|
+
const s = t && t.config, n = D(s.options && s.options.plugins, {}), o = ul(s);
|
|
5017
|
+
return n === !1 && !e ? [] : gl(t, o, n, e);
|
|
4994
5018
|
}
|
|
4995
5019
|
_notifyStateChanges(t) {
|
|
4996
5020
|
const e = this._oldCache || [], s = this._cache, n = (o, r) => o.filter((a) => !r.some((l) => a.plugin.id === l.plugin.id));
|
|
4997
5021
|
this._notify(n(e, s), t, "stop"), this._notify(n(s, e), t, "start");
|
|
4998
5022
|
}
|
|
4999
5023
|
}
|
|
5000
|
-
function
|
|
5024
|
+
function ul(i) {
|
|
5001
5025
|
const t = {}, e = [], s = Object.keys(st.plugins.items);
|
|
5002
5026
|
for (let o = 0; o < s.length; o++)
|
|
5003
5027
|
e.push(st.getPlugin(s[o]));
|
|
@@ -5011,16 +5035,16 @@ function hl(i) {
|
|
|
5011
5035
|
localIds: t
|
|
5012
5036
|
};
|
|
5013
5037
|
}
|
|
5014
|
-
function
|
|
5038
|
+
function fl(i, t) {
|
|
5015
5039
|
return !t && i === !1 ? null : i === !0 ? {} : i;
|
|
5016
5040
|
}
|
|
5017
|
-
function
|
|
5041
|
+
function gl(i, { plugins: t, localIds: e }, s, n) {
|
|
5018
5042
|
const o = [], r = i.getContext();
|
|
5019
5043
|
for (const a of t) {
|
|
5020
|
-
const l = a.id, c =
|
|
5044
|
+
const l = a.id, c = fl(s[l], n);
|
|
5021
5045
|
c !== null && o.push({
|
|
5022
5046
|
plugin: a,
|
|
5023
|
-
options:
|
|
5047
|
+
options: pl(i.config, {
|
|
5024
5048
|
plugin: a,
|
|
5025
5049
|
local: e[l]
|
|
5026
5050
|
}, c, r)
|
|
@@ -5028,7 +5052,7 @@ function ul(i, { plugins: t, localIds: e }, s, n) {
|
|
|
5028
5052
|
}
|
|
5029
5053
|
return o;
|
|
5030
5054
|
}
|
|
5031
|
-
function
|
|
5055
|
+
function pl(i, { plugin: t, local: e }, s, n) {
|
|
5032
5056
|
const o = i.pluginScopeKeys(t), r = i.getOptionScopes(s, o);
|
|
5033
5057
|
return e && t.defaults && r.push(t.defaults), i.createResolver(r, n, [
|
|
5034
5058
|
""
|
|
@@ -5042,18 +5066,18 @@ function ni(i, t) {
|
|
|
5042
5066
|
const e = F.datasets[i] || {};
|
|
5043
5067
|
return ((t.datasets || {})[i] || {}).indexAxis || t.indexAxis || e.indexAxis || "x";
|
|
5044
5068
|
}
|
|
5045
|
-
function
|
|
5069
|
+
function ml(i, t) {
|
|
5046
5070
|
let e = i;
|
|
5047
5071
|
return i === "_index_" ? e = t : i === "_value_" && (e = t === "x" ? "y" : "x"), e;
|
|
5048
5072
|
}
|
|
5049
|
-
function
|
|
5073
|
+
function bl(i, t) {
|
|
5050
5074
|
return i === t ? "_index_" : "_value_";
|
|
5051
5075
|
}
|
|
5052
5076
|
function ms(i) {
|
|
5053
5077
|
if (i === "x" || i === "y" || i === "r")
|
|
5054
5078
|
return i;
|
|
5055
5079
|
}
|
|
5056
|
-
function
|
|
5080
|
+
function _l(i) {
|
|
5057
5081
|
if (i === "top" || i === "bottom")
|
|
5058
5082
|
return "x";
|
|
5059
5083
|
if (i === "left" || i === "right")
|
|
@@ -5063,7 +5087,7 @@ function oi(i, ...t) {
|
|
|
5063
5087
|
if (ms(i))
|
|
5064
5088
|
return i;
|
|
5065
5089
|
for (const e of t) {
|
|
5066
|
-
const s = e.axis ||
|
|
5090
|
+
const s = e.axis || _l(e.position) || i.length > 1 && ms(i[0].toLowerCase());
|
|
5067
5091
|
if (s)
|
|
5068
5092
|
return s;
|
|
5069
5093
|
}
|
|
@@ -5075,7 +5099,7 @@ function bs(i, t, e) {
|
|
|
5075
5099
|
axis: t
|
|
5076
5100
|
};
|
|
5077
5101
|
}
|
|
5078
|
-
function
|
|
5102
|
+
function xl(i, t) {
|
|
5079
5103
|
if (t.data && t.data.datasets) {
|
|
5080
5104
|
const e = t.data.datasets.filter((s) => s.xAxisID === i || s.yAxisID === i);
|
|
5081
5105
|
if (e.length)
|
|
@@ -5083,7 +5107,7 @@ function bl(i, t) {
|
|
|
5083
5107
|
}
|
|
5084
5108
|
return {};
|
|
5085
5109
|
}
|
|
5086
|
-
function
|
|
5110
|
+
function yl(i, t) {
|
|
5087
5111
|
const e = Pt[i.type] || {
|
|
5088
5112
|
scales: {}
|
|
5089
5113
|
}, s = t.scales || {}, n = ni(i.type, t), o = /* @__PURE__ */ Object.create(null);
|
|
@@ -5093,7 +5117,7 @@ function _l(i, t) {
|
|
|
5093
5117
|
return console.error(`Invalid scale configuration for scale: ${r}`);
|
|
5094
5118
|
if (a._proxy)
|
|
5095
5119
|
return console.warn(`Ignoring resolver passed as options for scale: ${r}`);
|
|
5096
|
-
const l = oi(r, a,
|
|
5120
|
+
const l = oi(r, a, xl(r, i), F.scales[a.type]), c = bl(l, n), h = e.scales || {};
|
|
5097
5121
|
o[r] = qt(/* @__PURE__ */ Object.create(null), [
|
|
5098
5122
|
{
|
|
5099
5123
|
axis: l
|
|
@@ -5105,7 +5129,7 @@ function _l(i, t) {
|
|
|
5105
5129
|
}), i.data.datasets.forEach((r) => {
|
|
5106
5130
|
const a = r.type || i.type, l = r.indexAxis || ni(a, t), h = (Pt[a] || {}).scales || {};
|
|
5107
5131
|
Object.keys(h).forEach((d) => {
|
|
5108
|
-
const u =
|
|
5132
|
+
const u = ml(d, l), f = r[u + "AxisID"] || u;
|
|
5109
5133
|
o[f] = o[f] || /* @__PURE__ */ Object.create(null), qt(o[f], [
|
|
5110
5134
|
{
|
|
5111
5135
|
axis: u
|
|
@@ -5124,16 +5148,16 @@ function _l(i, t) {
|
|
|
5124
5148
|
}
|
|
5125
5149
|
function Sn(i) {
|
|
5126
5150
|
const t = i.options || (i.options = {});
|
|
5127
|
-
t.plugins = D(t.plugins, {}), t.scales =
|
|
5151
|
+
t.plugins = D(t.plugins, {}), t.scales = yl(i, t);
|
|
5128
5152
|
}
|
|
5129
5153
|
function wn(i) {
|
|
5130
5154
|
return i = i || {}, i.datasets = i.datasets || [], i.labels = i.labels || [], i;
|
|
5131
5155
|
}
|
|
5132
|
-
function
|
|
5156
|
+
function vl(i) {
|
|
5133
5157
|
return i = i || {}, i.data = wn(i.data), Sn(i), i;
|
|
5134
5158
|
}
|
|
5135
5159
|
const _s = /* @__PURE__ */ new Map(), Cn = /* @__PURE__ */ new Set();
|
|
5136
|
-
function
|
|
5160
|
+
function ve(i, t) {
|
|
5137
5161
|
let e = _s.get(i);
|
|
5138
5162
|
return e || (e = t(), _s.set(i, e), Cn.add(e)), e;
|
|
5139
5163
|
}
|
|
@@ -5141,9 +5165,9 @@ const Yt = (i, t, e) => {
|
|
|
5141
5165
|
const s = mt(t, e);
|
|
5142
5166
|
s !== void 0 && i.add(s);
|
|
5143
5167
|
};
|
|
5144
|
-
class
|
|
5168
|
+
class Ml {
|
|
5145
5169
|
constructor(t) {
|
|
5146
|
-
this._config =
|
|
5170
|
+
this._config = vl(t), this._scopeCache = /* @__PURE__ */ new Map(), this._resolverCache = /* @__PURE__ */ new Map();
|
|
5147
5171
|
}
|
|
5148
5172
|
get platform() {
|
|
5149
5173
|
return this._config.platform;
|
|
@@ -5177,7 +5201,7 @@ class yl {
|
|
|
5177
5201
|
this._scopeCache.clear(), this._resolverCache.clear();
|
|
5178
5202
|
}
|
|
5179
5203
|
datasetScopeKeys(t) {
|
|
5180
|
-
return
|
|
5204
|
+
return ve(t, () => [
|
|
5181
5205
|
[
|
|
5182
5206
|
`datasets.${t}`,
|
|
5183
5207
|
""
|
|
@@ -5185,7 +5209,7 @@ class yl {
|
|
|
5185
5209
|
]);
|
|
5186
5210
|
}
|
|
5187
5211
|
datasetAnimationScopeKeys(t, e) {
|
|
5188
|
-
return
|
|
5212
|
+
return ve(`${t}.transition.${e}`, () => [
|
|
5189
5213
|
[
|
|
5190
5214
|
`datasets.${t}.transitions.${e}`,
|
|
5191
5215
|
`transitions.${e}`
|
|
@@ -5197,7 +5221,7 @@ class yl {
|
|
|
5197
5221
|
]);
|
|
5198
5222
|
}
|
|
5199
5223
|
datasetElementScopeKeys(t, e) {
|
|
5200
|
-
return
|
|
5224
|
+
return ve(`${t}-${e}`, () => [
|
|
5201
5225
|
[
|
|
5202
5226
|
`datasets.${t}.elements.${e}`,
|
|
5203
5227
|
`datasets.${t}`,
|
|
@@ -5208,7 +5232,7 @@ class yl {
|
|
|
5208
5232
|
}
|
|
5209
5233
|
pluginScopeKeys(t) {
|
|
5210
5234
|
const e = t.id, s = this.type;
|
|
5211
|
-
return
|
|
5235
|
+
return ve(`${s}-plugin-${e}`, () => [
|
|
5212
5236
|
[
|
|
5213
5237
|
`plugins.${e}`,
|
|
5214
5238
|
...t.additionalOptionScopes || []
|
|
@@ -5251,7 +5275,7 @@ class yl {
|
|
|
5251
5275
|
$shared: !0
|
|
5252
5276
|
}, { resolver: r, subPrefixes: a } = xs(this._resolverCache, t, n);
|
|
5253
5277
|
let l = r;
|
|
5254
|
-
if (
|
|
5278
|
+
if (Sl(r, e)) {
|
|
5255
5279
|
o.$shared = !1, s = bt(s) ? s() : s;
|
|
5256
5280
|
const c = this.createResolver(t, s, a);
|
|
5257
5281
|
l = Ft(r, s, c);
|
|
@@ -5277,18 +5301,18 @@ function xs(i, t, e) {
|
|
|
5277
5301
|
subPrefixes: e.filter((a) => !a.toLowerCase().includes("hover"))
|
|
5278
5302
|
}, s.set(n, o)), o;
|
|
5279
5303
|
}
|
|
5280
|
-
const
|
|
5281
|
-
function
|
|
5304
|
+
const kl = (i) => A(i) && Object.getOwnPropertyNames(i).some((t) => bt(i[t]));
|
|
5305
|
+
function Sl(i, t) {
|
|
5282
5306
|
const { isScriptable: e, isIndexable: s } = an(i);
|
|
5283
5307
|
for (const n of t) {
|
|
5284
5308
|
const o = e(n), r = s(n), a = (r || o) && i[n];
|
|
5285
|
-
if (o && (bt(a) ||
|
|
5309
|
+
if (o && (bt(a) || kl(a)) || r && H(a))
|
|
5286
5310
|
return !0;
|
|
5287
5311
|
}
|
|
5288
5312
|
return !1;
|
|
5289
5313
|
}
|
|
5290
|
-
var
|
|
5291
|
-
const
|
|
5314
|
+
var wl = "4.4.9";
|
|
5315
|
+
const Cl = [
|
|
5292
5316
|
"top",
|
|
5293
5317
|
"bottom",
|
|
5294
5318
|
"left",
|
|
@@ -5296,7 +5320,7 @@ const Sl = [
|
|
|
5296
5320
|
"chartArea"
|
|
5297
5321
|
];
|
|
5298
5322
|
function ys(i, t) {
|
|
5299
|
-
return i === "top" || i === "bottom" ||
|
|
5323
|
+
return i === "top" || i === "bottom" || Cl.indexOf(i) === -1 && t === "x";
|
|
5300
5324
|
}
|
|
5301
5325
|
function vs(i, t) {
|
|
5302
5326
|
return function(e, s) {
|
|
@@ -5309,7 +5333,7 @@ function Ms(i) {
|
|
|
5309
5333
|
i
|
|
5310
5334
|
], t);
|
|
5311
5335
|
}
|
|
5312
|
-
function
|
|
5336
|
+
function Pl(i) {
|
|
5313
5337
|
const t = i.chart, e = t.options.animation;
|
|
5314
5338
|
E(e && e.onProgress, [
|
|
5315
5339
|
i
|
|
@@ -5322,7 +5346,7 @@ const we = {}, ks = (i) => {
|
|
|
5322
5346
|
const t = Pn(i);
|
|
5323
5347
|
return Object.values(we).filter((e) => e.canvas === t).pop();
|
|
5324
5348
|
};
|
|
5325
|
-
function
|
|
5349
|
+
function Dl(i, t, e) {
|
|
5326
5350
|
const s = Object.keys(i);
|
|
5327
5351
|
for (const n of s) {
|
|
5328
5352
|
const o = +n;
|
|
@@ -5332,27 +5356,15 @@ function Cl(i, t, e) {
|
|
|
5332
5356
|
}
|
|
5333
5357
|
}
|
|
5334
5358
|
}
|
|
5335
|
-
function
|
|
5359
|
+
function Ol(i, t, e, s) {
|
|
5336
5360
|
return !e || i.type === "mouseout" ? null : s ? t : i;
|
|
5337
5361
|
}
|
|
5338
|
-
function ve(i, t, e) {
|
|
5339
|
-
return i.options.clip ? i[e] : t[e];
|
|
5340
|
-
}
|
|
5341
|
-
function Dl(i, t) {
|
|
5342
|
-
const { xScale: e, yScale: s } = i;
|
|
5343
|
-
return e && s ? {
|
|
5344
|
-
left: ve(e, t, "left"),
|
|
5345
|
-
right: ve(e, t, "right"),
|
|
5346
|
-
top: ve(s, t, "top"),
|
|
5347
|
-
bottom: ve(s, t, "bottom")
|
|
5348
|
-
} : t;
|
|
5349
|
-
}
|
|
5350
5362
|
let Fe = class {
|
|
5351
5363
|
static defaults = F;
|
|
5352
5364
|
static instances = we;
|
|
5353
5365
|
static overrides = Pt;
|
|
5354
5366
|
static registry = st;
|
|
5355
|
-
static version =
|
|
5367
|
+
static version = wl;
|
|
5356
5368
|
static getChart = ks;
|
|
5357
5369
|
static register(...t) {
|
|
5358
5370
|
st.add(...t), Ss();
|
|
@@ -5361,17 +5373,17 @@ let Fe = class {
|
|
|
5361
5373
|
st.remove(...t), Ss();
|
|
5362
5374
|
}
|
|
5363
5375
|
constructor(t, e) {
|
|
5364
|
-
const s = this.config = new
|
|
5376
|
+
const s = this.config = new Ml(e), n = Pn(t), o = ks(n);
|
|
5365
5377
|
if (o)
|
|
5366
5378
|
throw new Error("Canvas is already in use. Chart with ID '" + o.id + "' must be destroyed before the canvas with ID '" + o.canvas.id + "' can be reused.");
|
|
5367
5379
|
const r = s.createResolver(s.chartOptionScopes(), this.getContext());
|
|
5368
|
-
this.platform = new (s.platform ||
|
|
5380
|
+
this.platform = new (s.platform || Ua(n))(), this.platform.updateConfig(s);
|
|
5369
5381
|
const a = this.platform.acquireContext(n, r.aspectRatio), l = a && a.canvas, c = l && l.height, h = l && l.width;
|
|
5370
|
-
if (this.id = xo(), this.ctx = a, this.canvas = l, this.width = h, this.height = c, this._options = r, this._aspectRatio = this.aspectRatio, this._layers = [], this._metasets = [], this._stacks = void 0, this.boxes = [], this.currentDevicePixelRatio = void 0, this.chartArea = void 0, this._active = [], this._lastEvent = void 0, this._listeners = {}, this._responsiveListeners = void 0, this._sortedMetasets = [], this.scales = {}, this._plugins = new
|
|
5382
|
+
if (this.id = xo(), this.ctx = a, this.canvas = l, this.width = h, this.height = c, this._options = r, this._aspectRatio = this.aspectRatio, this._layers = [], this._metasets = [], this._stacks = void 0, this.boxes = [], this.currentDevicePixelRatio = void 0, this.chartArea = void 0, this._active = [], this._lastEvent = void 0, this._listeners = {}, this._responsiveListeners = void 0, this._sortedMetasets = [], this.scales = {}, this._plugins = new dl(), this.$proxies = {}, this._hiddenIndices = {}, this.attached = !1, this._animationsDisabled = void 0, this.$context = void 0, this._doResize = Bo((d) => this.update(d), r.resizeDelay || 0), this._dataChanges = [], we[this.id] = this, !a || !l) {
|
|
5371
5383
|
console.error("Failed to create chart: can't acquire context from the given item");
|
|
5372
5384
|
return;
|
|
5373
5385
|
}
|
|
5374
|
-
at.listen(this, "complete", Ms), at.listen(this, "progress",
|
|
5386
|
+
at.listen(this, "complete", Ms), at.listen(this, "progress", Pl), this._initialize(), this.attached && this.update();
|
|
5375
5387
|
}
|
|
5376
5388
|
get aspectRatio() {
|
|
5377
5389
|
const { options: { aspectRatio: t, maintainAspectRatio: e }, width: s, height: n, _aspectRatio: o } = this;
|
|
@@ -5533,7 +5545,7 @@ let Fe = class {
|
|
|
5533
5545
|
const { _hiddenIndices: t } = this, e = this._getUniformDataChanges() || [];
|
|
5534
5546
|
for (const { method: s, start: n, count: o } of e) {
|
|
5535
5547
|
const r = s === "_removeElements" ? -o : o;
|
|
5536
|
-
|
|
5548
|
+
Dl(t, n, r);
|
|
5537
5549
|
}
|
|
5538
5550
|
}
|
|
5539
5551
|
_getUniformDataChanges() {
|
|
@@ -5636,23 +5648,18 @@ let Fe = class {
|
|
|
5636
5648
|
this.notifyPlugins("afterDatasetsDraw");
|
|
5637
5649
|
}
|
|
5638
5650
|
_drawDataset(t) {
|
|
5639
|
-
const e = this.ctx, s =
|
|
5651
|
+
const e = this.ctx, s = {
|
|
5640
5652
|
meta: t,
|
|
5641
5653
|
index: t.index,
|
|
5642
5654
|
cancelable: !0
|
|
5643
|
-
};
|
|
5644
|
-
this.notifyPlugins("beforeDatasetDraw",
|
|
5645
|
-
left: s.left === !1 ? 0 : o.left - s.left,
|
|
5646
|
-
right: s.right === !1 ? this.width : o.right + s.right,
|
|
5647
|
-
top: s.top === !1 ? 0 : o.top - s.top,
|
|
5648
|
-
bottom: s.bottom === !1 ? this.height : o.bottom + s.bottom
|
|
5649
|
-
}), t.controller.draw(), n && bi(e), r.cancelable = !1, this.notifyPlugins("afterDatasetDraw", r));
|
|
5655
|
+
}, n = Yr(this, t);
|
|
5656
|
+
this.notifyPlugins("beforeDatasetDraw", s) !== !1 && (n && mi(e, n), t.controller.draw(), n && bi(e), s.cancelable = !1, this.notifyPlugins("afterDatasetDraw", s));
|
|
5650
5657
|
}
|
|
5651
5658
|
isPointInArea(t) {
|
|
5652
5659
|
return ne(t, this.chartArea, this._minPadding);
|
|
5653
5660
|
}
|
|
5654
5661
|
getElementsAtEventForMode(t, e, s, n) {
|
|
5655
|
-
const o =
|
|
5662
|
+
const o = Ca.modes[e];
|
|
5656
5663
|
return typeof o == "function" ? o(this, t, s, n) : [];
|
|
5657
5664
|
}
|
|
5658
5665
|
getDatasetMeta(t) {
|
|
@@ -5811,7 +5818,7 @@ let Fe = class {
|
|
|
5811
5818
|
return s.cancelable = !1, this.notifyPlugins("afterEvent", s, n), (o || s.changed) && this.render(), this;
|
|
5812
5819
|
}
|
|
5813
5820
|
_handleEvent(t, e, s) {
|
|
5814
|
-
const { _active: n = [], options: o } = this, r = e, a = this._getActiveElements(t, n, s, r), l = wo(t), c =
|
|
5821
|
+
const { _active: n = [], options: o } = this, r = e, a = this._getActiveElements(t, n, s, r), l = wo(t), c = Ol(t, this._lastEvent, s, l);
|
|
5815
5822
|
s && (this._lastEvent = null, E(o.onHover, [
|
|
5816
5823
|
t,
|
|
5817
5824
|
a,
|
|
@@ -5836,12 +5843,12 @@ let Fe = class {
|
|
|
5836
5843
|
function Ss() {
|
|
5837
5844
|
return R(Fe.instances, (i) => i._plugins.invalidate());
|
|
5838
5845
|
}
|
|
5839
|
-
function
|
|
5846
|
+
function Al(i, t, e) {
|
|
5840
5847
|
const { startAngle: s, pixelMargin: n, x: o, y: r, outerRadius: a, innerRadius: l } = t;
|
|
5841
5848
|
let c = n / a;
|
|
5842
5849
|
i.beginPath(), i.arc(o, r, a, s - c, e + c), l > n ? (c = n / l, i.arc(o, r, l, e + c, s - c, !0)) : i.arc(o, r, n, e + V, s - V), i.closePath(), i.clip();
|
|
5843
5850
|
}
|
|
5844
|
-
function
|
|
5851
|
+
function Tl(i) {
|
|
5845
5852
|
return _i(i, [
|
|
5846
5853
|
"outerStart",
|
|
5847
5854
|
"outerEnd",
|
|
@@ -5849,8 +5856,8 @@ function Al(i) {
|
|
|
5849
5856
|
"innerEnd"
|
|
5850
5857
|
]);
|
|
5851
5858
|
}
|
|
5852
|
-
function
|
|
5853
|
-
const n =
|
|
5859
|
+
function Rl(i, t, e, s) {
|
|
5860
|
+
const n = Tl(i.options.borderRadius), o = (e - t) / 2, r = Math.min(o, s * t / 2), a = (l) => {
|
|
5854
5861
|
const c = (e - Math.min(o, l)) * s / 2;
|
|
5855
5862
|
return Y(l, 0, Math.min(o, c));
|
|
5856
5863
|
};
|
|
@@ -5875,7 +5882,7 @@ function Re(i, t, e, s, n, o) {
|
|
|
5875
5882
|
const L = h > 0 ? h - s : 0, I = d > 0 ? d - s : 0, W = (L + I) / 2, tt = W !== 0 ? g * W / (W + s) : g;
|
|
5876
5883
|
f = (g - tt) / 2;
|
|
5877
5884
|
}
|
|
5878
|
-
const p = Math.max(1e-3, g * d - e / z) / d, m = (g - p) / 2, b = l + m + f, _ = n - m - f, { outerStart: y, outerEnd: v, innerStart: x, innerEnd: k } =
|
|
5885
|
+
const p = Math.max(1e-3, g * d - e / z) / d, m = (g - p) / 2, b = l + m + f, _ = n - m - f, { outerStart: y, outerEnd: v, innerStart: x, innerEnd: k } = Rl(t, u, d, _ - b), S = d - y, M = d - v, w = b + y / S, P = _ - v / M, C = u + x, O = u + k, N = b + x / C, q = _ - k / O;
|
|
5879
5886
|
if (i.beginPath(), o) {
|
|
5880
5887
|
const L = (w + P) / 2;
|
|
5881
5888
|
if (i.arc(r, a, d, w, L), i.arc(r, a, d, L, P), v > 0) {
|
|
@@ -5906,7 +5913,7 @@ function Re(i, t, e, s, n, o) {
|
|
|
5906
5913
|
}
|
|
5907
5914
|
i.closePath();
|
|
5908
5915
|
}
|
|
5909
|
-
function
|
|
5916
|
+
function Ll(i, t, e, s, n) {
|
|
5910
5917
|
const { fullCircles: o, startAngle: r, circumference: a } = t;
|
|
5911
5918
|
let l = t.endAngle;
|
|
5912
5919
|
if (o) {
|
|
@@ -5917,7 +5924,7 @@ function Rl(i, t, e, s, n) {
|
|
|
5917
5924
|
}
|
|
5918
5925
|
return Re(i, t, e, s, l, n), i.fill(), l;
|
|
5919
5926
|
}
|
|
5920
|
-
function
|
|
5927
|
+
function El(i, t, e, s, n) {
|
|
5921
5928
|
const { fullCircles: o, startAngle: r, circumference: a, options: l } = t, { borderWidth: c, borderJoinStyle: h, borderDash: d, borderDashOffset: u } = l, f = l.borderAlign === "inner";
|
|
5922
5929
|
if (!c)
|
|
5923
5930
|
return;
|
|
@@ -5929,9 +5936,9 @@ function Ll(i, t, e, s, n) {
|
|
|
5929
5936
|
i.stroke();
|
|
5930
5937
|
isNaN(a) || (g = r + (a % B || B));
|
|
5931
5938
|
}
|
|
5932
|
-
f &&
|
|
5939
|
+
f && Al(i, t, g), o || (Re(i, t, e, s, g, n), i.stroke());
|
|
5933
5940
|
}
|
|
5934
|
-
class
|
|
5941
|
+
class Il extends ht {
|
|
5935
5942
|
static id = "arc";
|
|
5936
5943
|
static defaults = {
|
|
5937
5944
|
borderAlign: "center",
|
|
@@ -6004,17 +6011,17 @@ class El extends ht {
|
|
|
6004
6011
|
const a = (this.startAngle + this.endAngle) / 2;
|
|
6005
6012
|
t.translate(Math.cos(a) * n, Math.sin(a) * n);
|
|
6006
6013
|
const l = 1 - Math.sin(Math.min(z, s || 0)), c = n * l;
|
|
6007
|
-
t.fillStyle = e.backgroundColor, t.strokeStyle = e.borderColor,
|
|
6014
|
+
t.fillStyle = e.backgroundColor, t.strokeStyle = e.borderColor, Ll(t, this, c, o, r), El(t, this, c, o, r), t.restore();
|
|
6008
6015
|
}
|
|
6009
6016
|
}
|
|
6010
6017
|
function Dn(i, t, e = t) {
|
|
6011
6018
|
i.lineCap = D(e.borderCapStyle, t.borderCapStyle), i.setLineDash(D(e.borderDash, t.borderDash)), i.lineDashOffset = D(e.borderDashOffset, t.borderDashOffset), i.lineJoin = D(e.borderJoinStyle, t.borderJoinStyle), i.lineWidth = D(e.borderWidth, t.borderWidth), i.strokeStyle = D(e.borderColor, t.borderColor);
|
|
6012
6019
|
}
|
|
6013
|
-
function
|
|
6020
|
+
function Fl(i, t, e) {
|
|
6014
6021
|
i.lineTo(e.x, e.y);
|
|
6015
6022
|
}
|
|
6016
|
-
function
|
|
6017
|
-
return i.stepped ? Jo : i.tension || i.cubicInterpolationMode === "monotone" ? Qo :
|
|
6023
|
+
function zl(i) {
|
|
6024
|
+
return i.stepped ? Jo : i.tension || i.cubicInterpolationMode === "monotone" ? Qo : Fl;
|
|
6018
6025
|
}
|
|
6019
6026
|
function On(i, t, e = {}) {
|
|
6020
6027
|
const s = i.length, { start: n = 0, end: o = s - 1 } = e, { start: r, end: a } = t, l = Math.max(n, r), c = Math.min(o, a), h = n < r && o < r || n > a && o > a;
|
|
@@ -6025,14 +6032,14 @@ function On(i, t, e = {}) {
|
|
|
6025
6032
|
ilen: c < l && !h ? s + c - l : c - l
|
|
6026
6033
|
};
|
|
6027
6034
|
}
|
|
6028
|
-
function
|
|
6029
|
-
const { points: n, options: o } = t, { count: r, start: a, loop: l, ilen: c } = On(n, e, s), h =
|
|
6035
|
+
function Bl(i, t, e, s) {
|
|
6036
|
+
const { points: n, options: o } = t, { count: r, start: a, loop: l, ilen: c } = On(n, e, s), h = zl(o);
|
|
6030
6037
|
let { move: d = !0, reverse: u } = s || {}, f, g, p;
|
|
6031
6038
|
for (f = 0; f <= c; ++f)
|
|
6032
6039
|
g = n[(a + (u ? c - f : f)) % r], !g.skip && (d ? (i.moveTo(g.x, g.y), d = !1) : h(i, p, g, u, o.stepped), p = g);
|
|
6033
6040
|
return l && (g = n[(a + (u ? c : 0)) % r], h(i, p, g, u, o.stepped)), !!l;
|
|
6034
6041
|
}
|
|
6035
|
-
function
|
|
6042
|
+
function Wl(i, t, e, s) {
|
|
6036
6043
|
const n = t.points, { count: o, start: r, ilen: a } = On(n, e, s), { move: l = !0, reverse: c } = s || {};
|
|
6037
6044
|
let h = 0, d = 0, u, f, g, p, m, b;
|
|
6038
6045
|
const _ = (v) => (r + (c ? a - v : v)) % o, y = () => {
|
|
@@ -6048,16 +6055,16 @@ function Bl(i, t, e, s) {
|
|
|
6048
6055
|
}
|
|
6049
6056
|
function ri(i) {
|
|
6050
6057
|
const t = i.options, e = t.borderDash && t.borderDash.length;
|
|
6051
|
-
return !i._decimated && !i._loop && !t.tension && t.cubicInterpolationMode !== "monotone" && !t.stepped && !e ?
|
|
6058
|
+
return !i._decimated && !i._loop && !t.tension && t.cubicInterpolationMode !== "monotone" && !t.stepped && !e ? Wl : Bl;
|
|
6052
6059
|
}
|
|
6053
|
-
function
|
|
6060
|
+
function Hl(i) {
|
|
6054
6061
|
return i.stepped ? Rr : i.tension || i.cubicInterpolationMode === "monotone" ? Lr : St;
|
|
6055
6062
|
}
|
|
6056
|
-
function
|
|
6063
|
+
function Vl(i, t, e, s) {
|
|
6057
6064
|
let n = t._path;
|
|
6058
6065
|
n || (n = t._path = new Path2D(), t.path(n, e, s) && n.closePath()), Dn(i, t.options), i.stroke(n);
|
|
6059
6066
|
}
|
|
6060
|
-
function
|
|
6067
|
+
function Nl(i, t, e, s) {
|
|
6061
6068
|
const { segments: n, options: o } = t, r = ri(t);
|
|
6062
6069
|
for (const a of n)
|
|
6063
6070
|
Dn(i, o, a.style), i.beginPath(), r(i, t, a, {
|
|
@@ -6065,11 +6072,11 @@ function Vl(i, t, e, s) {
|
|
|
6065
6072
|
end: e + s - 1
|
|
6066
6073
|
}) && i.closePath(), i.stroke();
|
|
6067
6074
|
}
|
|
6068
|
-
const
|
|
6069
|
-
function
|
|
6070
|
-
|
|
6075
|
+
const jl = typeof Path2D == "function";
|
|
6076
|
+
function $l(i, t, e, s) {
|
|
6077
|
+
jl && !t.options.segment ? Vl(i, t, e, s) : Nl(i, t, e, s);
|
|
6071
6078
|
}
|
|
6072
|
-
class
|
|
6079
|
+
class Yl extends ht {
|
|
6073
6080
|
static id = "line";
|
|
6074
6081
|
static defaults = {
|
|
6075
6082
|
borderCapStyle: "butt",
|
|
@@ -6127,7 +6134,7 @@ class $l extends ht {
|
|
|
6127
6134
|
});
|
|
6128
6135
|
if (!r.length)
|
|
6129
6136
|
return;
|
|
6130
|
-
const a = [], l =
|
|
6137
|
+
const a = [], l = Hl(s);
|
|
6131
6138
|
let c, h;
|
|
6132
6139
|
for (c = 0, h = r.length; c < h; ++c) {
|
|
6133
6140
|
const { start: d, end: u } = r[c], f = o[d], g = o[u];
|
|
@@ -6156,7 +6163,7 @@ class $l extends ht {
|
|
|
6156
6163
|
}
|
|
6157
6164
|
draw(t, e, s, n) {
|
|
6158
6165
|
const o = this.options || {};
|
|
6159
|
-
(this.points || []).length && o.borderWidth && (t.save(),
|
|
6166
|
+
(this.points || []).length && o.borderWidth && (t.save(), $l(t, this, s, n), t.restore()), this.animated && (this._pointsUpdated = !1, this._path = void 0);
|
|
6160
6167
|
}
|
|
6161
6168
|
}
|
|
6162
6169
|
function ws(i, t, e, s) {
|
|
@@ -6165,7 +6172,7 @@ function ws(i, t, e, s) {
|
|
|
6165
6172
|
], s);
|
|
6166
6173
|
return Math.abs(t - o) < n.radius + n.hitRadius;
|
|
6167
6174
|
}
|
|
6168
|
-
class
|
|
6175
|
+
class Xl extends ht {
|
|
6169
6176
|
static id = "point";
|
|
6170
6177
|
parsed;
|
|
6171
6178
|
skip;
|
|
@@ -6250,7 +6257,7 @@ function An(i, t) {
|
|
|
6250
6257
|
function gt(i, t, e, s) {
|
|
6251
6258
|
return i ? 0 : Y(t, e, s);
|
|
6252
6259
|
}
|
|
6253
|
-
function
|
|
6260
|
+
function Ul(i, t, e) {
|
|
6254
6261
|
const s = i.options.borderWidth, n = i.borderSkipped, o = rn(s);
|
|
6255
6262
|
return {
|
|
6256
6263
|
t: gt(n.top, o.top, 0, e),
|
|
@@ -6259,7 +6266,7 @@ function Xl(i, t, e) {
|
|
|
6259
6266
|
l: gt(n.left, o.left, 0, t)
|
|
6260
6267
|
};
|
|
6261
6268
|
}
|
|
6262
|
-
function
|
|
6269
|
+
function Kl(i, t, e) {
|
|
6263
6270
|
const { enableBorderRadius: s } = i.getProps([
|
|
6264
6271
|
"enableBorderRadius"
|
|
6265
6272
|
]), n = i.options.borderRadius, o = Et(n), r = Math.min(t, e), a = i.borderSkipped, l = s || A(n);
|
|
@@ -6270,8 +6277,8 @@ function Ul(i, t, e) {
|
|
|
6270
6277
|
bottomRight: gt(!l || a.bottom || a.right, o.bottomRight, 0, r)
|
|
6271
6278
|
};
|
|
6272
6279
|
}
|
|
6273
|
-
function
|
|
6274
|
-
const t = An(i), e = t.right - t.left, s = t.bottom - t.top, n =
|
|
6280
|
+
function ql(i) {
|
|
6281
|
+
const t = An(i), e = t.right - t.left, s = t.bottom - t.top, n = Ul(i, e / 2, s / 2), o = Kl(i, e / 2, s / 2);
|
|
6275
6282
|
return {
|
|
6276
6283
|
outer: {
|
|
6277
6284
|
x: t.left,
|
|
@@ -6298,10 +6305,10 @@ function Ge(i, t, e, s) {
|
|
|
6298
6305
|
const n = t === null, o = e === null, a = i && !(n && o) && An(i, s);
|
|
6299
6306
|
return a && (n || ft(t, a.left, a.right)) && (o || ft(e, a.top, a.bottom));
|
|
6300
6307
|
}
|
|
6301
|
-
function
|
|
6308
|
+
function Gl(i) {
|
|
6302
6309
|
return i.topLeft || i.topRight || i.bottomLeft || i.bottomRight;
|
|
6303
6310
|
}
|
|
6304
|
-
function
|
|
6311
|
+
function Zl(i, t) {
|
|
6305
6312
|
i.rect(t.x, t.y, t.w, t.h);
|
|
6306
6313
|
}
|
|
6307
6314
|
function Ze(i, t, e = {}) {
|
|
@@ -6314,7 +6321,7 @@ function Ze(i, t, e = {}) {
|
|
|
6314
6321
|
radius: i.radius
|
|
6315
6322
|
};
|
|
6316
6323
|
}
|
|
6317
|
-
class
|
|
6324
|
+
class Jl extends ht {
|
|
6318
6325
|
static id = "bar";
|
|
6319
6326
|
static defaults = {
|
|
6320
6327
|
borderSkipped: "start",
|
|
@@ -6331,7 +6338,7 @@ class Zl extends ht {
|
|
|
6331
6338
|
super(), this.options = void 0, this.horizontal = void 0, this.base = void 0, this.width = void 0, this.height = void 0, this.inflateAmount = void 0, t && Object.assign(this, t);
|
|
6332
6339
|
}
|
|
6333
6340
|
draw(t) {
|
|
6334
|
-
const { inflateAmount: e, options: { borderColor: s, backgroundColor: n } } = this, { inner: o, outer: r } =
|
|
6341
|
+
const { inflateAmount: e, options: { borderColor: s, backgroundColor: n } } = this, { inner: o, outer: r } = ql(this), a = Gl(r.radius) ? Oe : Zl;
|
|
6335
6342
|
t.save(), (r.w !== o.w || r.h !== o.h) && (t.beginPath(), a(t, Ze(r, e, o)), t.clip(), a(t, Ze(o, -e, r)), t.fillStyle = s, t.fill("evenodd")), t.beginPath(), a(t, Ze(o, e)), t.fillStyle = n, t.fill(), t.restore();
|
|
6336
6343
|
}
|
|
6337
6344
|
inRange(t, e, s) {
|
|
@@ -6375,20 +6382,20 @@ function Tn(i) {
|
|
|
6375
6382
|
function Rn(i) {
|
|
6376
6383
|
return Cs[i % Cs.length];
|
|
6377
6384
|
}
|
|
6378
|
-
function
|
|
6385
|
+
function Ql(i, t) {
|
|
6379
6386
|
return i.borderColor = Tn(t), i.backgroundColor = Rn(t), ++t;
|
|
6380
6387
|
}
|
|
6381
|
-
function
|
|
6388
|
+
function tc(i, t) {
|
|
6382
6389
|
return i.backgroundColor = i.data.map(() => Tn(t++)), t;
|
|
6383
6390
|
}
|
|
6384
|
-
function
|
|
6391
|
+
function ec(i, t) {
|
|
6385
6392
|
return i.backgroundColor = i.data.map(() => Rn(t++)), t;
|
|
6386
6393
|
}
|
|
6387
|
-
function
|
|
6394
|
+
function ic(i) {
|
|
6388
6395
|
let t = 0;
|
|
6389
6396
|
return (e, s) => {
|
|
6390
6397
|
const n = i.getDatasetMeta(s).controller;
|
|
6391
|
-
n instanceof _n ? t =
|
|
6398
|
+
n instanceof _n ? t = tc(e, t) : n instanceof xa ? t = ec(e, t) : n && (t = Ql(e, t));
|
|
6392
6399
|
};
|
|
6393
6400
|
}
|
|
6394
6401
|
function Ps(i) {
|
|
@@ -6398,13 +6405,13 @@ function Ps(i) {
|
|
|
6398
6405
|
return !0;
|
|
6399
6406
|
return !1;
|
|
6400
6407
|
}
|
|
6401
|
-
function
|
|
6408
|
+
function sc(i) {
|
|
6402
6409
|
return i && (i.borderColor || i.backgroundColor);
|
|
6403
6410
|
}
|
|
6404
|
-
function
|
|
6411
|
+
function nc() {
|
|
6405
6412
|
return F.borderColor !== "rgba(0,0,0,0.1)" || F.backgroundColor !== "rgba(0,0,0,0.1)";
|
|
6406
6413
|
}
|
|
6407
|
-
var
|
|
6414
|
+
var oc = {
|
|
6408
6415
|
id: "colors",
|
|
6409
6416
|
defaults: {
|
|
6410
6417
|
enabled: !0,
|
|
@@ -6413,10 +6420,10 @@ var nc = {
|
|
|
6413
6420
|
beforeLayout(i, t, e) {
|
|
6414
6421
|
if (!e.enabled)
|
|
6415
6422
|
return;
|
|
6416
|
-
const { data: { datasets: s }, options: n } = i.config, { elements: o } = n, r = Ps(s) ||
|
|
6423
|
+
const { data: { datasets: s }, options: n } = i.config, { elements: o } = n, r = Ps(s) || sc(n) || o && Ps(o) || nc();
|
|
6417
6424
|
if (!e.forceOverride && r)
|
|
6418
6425
|
return;
|
|
6419
|
-
const a =
|
|
6426
|
+
const a = ic(i);
|
|
6420
6427
|
s.forEach(a);
|
|
6421
6428
|
}
|
|
6422
6429
|
};
|
|
@@ -6427,7 +6434,7 @@ const Ds = (i, t) => {
|
|
|
6427
6434
|
boxHeight: e,
|
|
6428
6435
|
itemHeight: Math.max(t, e)
|
|
6429
6436
|
};
|
|
6430
|
-
},
|
|
6437
|
+
}, rc = (i, t) => i !== null && t !== null && i.datasetIndex === t.datasetIndex && i.index === t.index;
|
|
6431
6438
|
class Os extends ht {
|
|
6432
6439
|
constructor(t) {
|
|
6433
6440
|
super(), this._added = !1, this.legendHitBoxes = [], this._hoveredItem = null, this.doughnutMode = !1, this.chart = t.chart, this.options = t.options, this.ctx = t.ctx, this.legendItems = void 0, this.columnSizes = void 0, this.lineWidths = void 0, this.maxHeight = void 0, this.maxWidth = void 0, this.top = void 0, this.bottom = void 0, this.left = void 0, this.right = void 0, this.height = void 0, this.width = void 0, this._margins = void 0, this.position = void 0, this.weight = void 0, this.fullSize = void 0;
|
|
@@ -6477,7 +6484,7 @@ class Os extends ht {
|
|
|
6477
6484
|
const { ctx: o, maxHeight: r, options: { labels: { padding: a } } } = this, l = this.legendHitBoxes = [], c = this.columnSizes = [], h = r - t;
|
|
6478
6485
|
let d = a, u = 0, f = 0, g = 0, p = 0;
|
|
6479
6486
|
return this.legendItems.forEach((m, b) => {
|
|
6480
|
-
const { itemWidth: _, itemHeight: y } =
|
|
6487
|
+
const { itemWidth: _, itemHeight: y } = ac(s, e, o, m, n);
|
|
6481
6488
|
b > 0 && f + y + 2 * a > h && (d += u + a, c.push({
|
|
6482
6489
|
width: u,
|
|
6483
6490
|
height: f
|
|
@@ -6605,11 +6612,11 @@ class Os extends ht {
|
|
|
6605
6612
|
}
|
|
6606
6613
|
handleEvent(t) {
|
|
6607
6614
|
const e = this.options;
|
|
6608
|
-
if (!
|
|
6615
|
+
if (!hc(t.type, e))
|
|
6609
6616
|
return;
|
|
6610
6617
|
const s = this._getLegendItemAt(t.x, t.y);
|
|
6611
6618
|
if (t.type === "mousemove" || t.type === "mouseout") {
|
|
6612
|
-
const n = this._hoveredItem, o =
|
|
6619
|
+
const n = this._hoveredItem, o = rc(n, s);
|
|
6613
6620
|
n && !o && E(e.onLeave, [
|
|
6614
6621
|
t,
|
|
6615
6622
|
n,
|
|
@@ -6626,18 +6633,18 @@ class Os extends ht {
|
|
|
6626
6633
|
], this);
|
|
6627
6634
|
}
|
|
6628
6635
|
}
|
|
6629
|
-
function
|
|
6630
|
-
const o =
|
|
6636
|
+
function ac(i, t, e, s, n) {
|
|
6637
|
+
const o = lc(s, i, t, e), r = cc(n, s, t.lineHeight);
|
|
6631
6638
|
return {
|
|
6632
6639
|
itemWidth: o,
|
|
6633
6640
|
itemHeight: r
|
|
6634
6641
|
};
|
|
6635
6642
|
}
|
|
6636
|
-
function
|
|
6643
|
+
function lc(i, t, e, s) {
|
|
6637
6644
|
let n = i.text;
|
|
6638
6645
|
return n && typeof n != "string" && (n = n.reduce((o, r) => o.length > r.length ? o : r)), t + e.size / 2 + s.measureText(n).width;
|
|
6639
6646
|
}
|
|
6640
|
-
function
|
|
6647
|
+
function cc(i, t, e) {
|
|
6641
6648
|
let s = i;
|
|
6642
6649
|
return typeof t.text != "string" && (s = Ln(t, e)), s;
|
|
6643
6650
|
}
|
|
@@ -6645,10 +6652,10 @@ function Ln(i, t) {
|
|
|
6645
6652
|
const e = i.text ? i.text.length : 0;
|
|
6646
6653
|
return t * e;
|
|
6647
6654
|
}
|
|
6648
|
-
function
|
|
6655
|
+
function hc(i, t) {
|
|
6649
6656
|
return !!((i === "mousemove" || i === "mouseout") && (t.onHover || t.onLeave) || t.onClick && (i === "click" || i === "mouseup"));
|
|
6650
6657
|
}
|
|
6651
|
-
var
|
|
6658
|
+
var dc = {
|
|
6652
6659
|
id: "legend",
|
|
6653
6660
|
_element: Os,
|
|
6654
6661
|
start(i, t, e) {
|
|
@@ -6780,7 +6787,7 @@ class En extends ht {
|
|
|
6780
6787
|
});
|
|
6781
6788
|
}
|
|
6782
6789
|
}
|
|
6783
|
-
function
|
|
6790
|
+
function uc(i, t) {
|
|
6784
6791
|
const e = new En({
|
|
6785
6792
|
ctx: i.ctx,
|
|
6786
6793
|
options: t,
|
|
@@ -6788,11 +6795,11 @@ function dc(i, t) {
|
|
|
6788
6795
|
});
|
|
6789
6796
|
Z.configure(i, e, t), Z.addBox(i, e), i.titleBlock = e;
|
|
6790
6797
|
}
|
|
6791
|
-
var
|
|
6798
|
+
var fc = {
|
|
6792
6799
|
id: "title",
|
|
6793
6800
|
_element: En,
|
|
6794
6801
|
start(i, t, e) {
|
|
6795
|
-
|
|
6802
|
+
uc(i, e);
|
|
6796
6803
|
},
|
|
6797
6804
|
stop(i) {
|
|
6798
6805
|
const t = i.titleBlock;
|
|
@@ -6870,7 +6877,7 @@ function lt(i) {
|
|
|
6870
6877
|
`) > -1 ? i.split(`
|
|
6871
6878
|
`) : i;
|
|
6872
6879
|
}
|
|
6873
|
-
function
|
|
6880
|
+
function gc(i, t) {
|
|
6874
6881
|
const { element: e, datasetIndex: s, index: n } = t, o = i.getDatasetMeta(s).controller, { label: r, value: a } = o.getLabelAndValue(n);
|
|
6875
6882
|
return {
|
|
6876
6883
|
chart: i,
|
|
@@ -6903,39 +6910,39 @@ function As(i, t) {
|
|
|
6903
6910
|
height: p
|
|
6904
6911
|
};
|
|
6905
6912
|
}
|
|
6906
|
-
function
|
|
6913
|
+
function pc(i, t) {
|
|
6907
6914
|
const { y: e, height: s } = t;
|
|
6908
6915
|
return e < s / 2 ? "top" : e > i.height - s / 2 ? "bottom" : "center";
|
|
6909
6916
|
}
|
|
6910
|
-
function
|
|
6917
|
+
function mc(i, t, e, s) {
|
|
6911
6918
|
const { x: n, width: o } = s, r = e.caretSize + e.caretPadding;
|
|
6912
6919
|
if (i === "left" && n + o + r > t.width || i === "right" && n - o - r < 0)
|
|
6913
6920
|
return !0;
|
|
6914
6921
|
}
|
|
6915
|
-
function
|
|
6922
|
+
function bc(i, t, e, s) {
|
|
6916
6923
|
const { x: n, width: o } = e, { width: r, chartArea: { left: a, right: l } } = i;
|
|
6917
6924
|
let c = "center";
|
|
6918
|
-
return s === "center" ? c = n <= (a + l) / 2 ? "left" : "right" : n <= o / 2 ? c = "left" : n >= r - o / 2 && (c = "right"),
|
|
6925
|
+
return s === "center" ? c = n <= (a + l) / 2 ? "left" : "right" : n <= o / 2 ? c = "left" : n >= r - o / 2 && (c = "right"), mc(c, i, t, e) && (c = "center"), c;
|
|
6919
6926
|
}
|
|
6920
6927
|
function Ts(i, t, e) {
|
|
6921
|
-
const s = e.yAlign || t.yAlign ||
|
|
6928
|
+
const s = e.yAlign || t.yAlign || pc(i, e);
|
|
6922
6929
|
return {
|
|
6923
|
-
xAlign: e.xAlign || t.xAlign ||
|
|
6930
|
+
xAlign: e.xAlign || t.xAlign || bc(i, t, e, s),
|
|
6924
6931
|
yAlign: s
|
|
6925
6932
|
};
|
|
6926
6933
|
}
|
|
6927
|
-
function
|
|
6934
|
+
function _c(i, t) {
|
|
6928
6935
|
let { x: e, width: s } = i;
|
|
6929
6936
|
return t === "right" ? e -= s : t === "center" && (e -= s / 2), e;
|
|
6930
6937
|
}
|
|
6931
|
-
function
|
|
6938
|
+
function xc(i, t, e) {
|
|
6932
6939
|
let { y: s, height: n } = i;
|
|
6933
6940
|
return t === "top" ? s += e : t === "bottom" ? s -= n + e : s -= n / 2, s;
|
|
6934
6941
|
}
|
|
6935
6942
|
function Rs(i, t, e, s) {
|
|
6936
6943
|
const { caretSize: n, caretPadding: o, cornerRadius: r } = i, { xAlign: a, yAlign: l } = e, c = n + o, { topLeft: h, topRight: d, bottomLeft: u, bottomRight: f } = Et(r);
|
|
6937
|
-
let g =
|
|
6938
|
-
const p =
|
|
6944
|
+
let g = _c(t, a);
|
|
6945
|
+
const p = xc(t, l, c);
|
|
6939
6946
|
return l === "center" ? a === "left" ? g += c : a === "right" && (g -= c) : a === "left" ? g -= Math.max(h, u) + n : a === "right" && (g += Math.max(d, f) + n), {
|
|
6940
6947
|
x: Y(g, 0, s.width - t.width),
|
|
6941
6948
|
y: Y(p, 0, s.height - t.height)
|
|
@@ -6948,7 +6955,7 @@ function Me(i, t, e) {
|
|
|
6948
6955
|
function Ls(i) {
|
|
6949
6956
|
return it([], lt(i));
|
|
6950
6957
|
}
|
|
6951
|
-
function
|
|
6958
|
+
function yc(i, t, e) {
|
|
6952
6959
|
return Dt(i, {
|
|
6953
6960
|
tooltip: t,
|
|
6954
6961
|
tooltipItems: e,
|
|
@@ -7031,7 +7038,7 @@ class Is extends ht {
|
|
|
7031
7038
|
return n._cacheable && (this._cachedAnimations = Object.freeze(o)), o;
|
|
7032
7039
|
}
|
|
7033
7040
|
getContext() {
|
|
7034
|
-
return this.$context || (this.$context =
|
|
7041
|
+
return this.$context || (this.$context = yc(this.chart.getContext(), this, this._tooltipItems));
|
|
7035
7042
|
}
|
|
7036
7043
|
getTitle(t, e) {
|
|
7037
7044
|
const { callbacks: s } = e, n = U(s, "beforeTitle", this, t), o = U(s, "title", this, t), r = U(s, "afterTitle", this, t);
|
|
@@ -7064,7 +7071,7 @@ class Is extends ht {
|
|
|
7064
7071
|
const e = this._active, s = this.chart.data, n = [], o = [], r = [];
|
|
7065
7072
|
let a = [], l, c;
|
|
7066
7073
|
for (l = 0, c = e.length; l < c; ++l)
|
|
7067
|
-
a.push(
|
|
7074
|
+
a.push(gc(this.chart, e[l]));
|
|
7068
7075
|
return t.filter && (a = a.filter((h, d, u) => t.filter(h, d, u, s))), t.itemSort && (a = a.sort((h, d) => t.itemSort(h, d, s))), R(a, (h) => {
|
|
7069
7076
|
const d = Es(t.callbacks, h);
|
|
7070
7077
|
n.push(U(d, "labelColor", this, h)), o.push(U(d, "labelPointStyle", this, h)), r.push(U(d, "labelTextColor", this, h));
|
|
@@ -7248,7 +7255,7 @@ class Is extends ht {
|
|
|
7248
7255
|
return r !== !1 && (s !== r.x || n !== r.y);
|
|
7249
7256
|
}
|
|
7250
7257
|
}
|
|
7251
|
-
var
|
|
7258
|
+
var vc = {
|
|
7252
7259
|
id: "tooltip",
|
|
7253
7260
|
_element: Is,
|
|
7254
7261
|
positioners: Kt,
|
|
@@ -7364,23 +7371,23 @@ var yc = {
|
|
|
7364
7371
|
"interaction"
|
|
7365
7372
|
]
|
|
7366
7373
|
};
|
|
7367
|
-
const
|
|
7374
|
+
const Mc = (i, t, e, s) => (typeof t == "string" ? (e = i.push(t) - 1, s.unshift({
|
|
7368
7375
|
index: e,
|
|
7369
7376
|
label: t
|
|
7370
7377
|
})) : isNaN(t) && (e = null), e);
|
|
7371
|
-
function
|
|
7378
|
+
function kc(i, t, e, s) {
|
|
7372
7379
|
const n = i.indexOf(t);
|
|
7373
7380
|
if (n === -1)
|
|
7374
|
-
return
|
|
7381
|
+
return Mc(i, t, e, s);
|
|
7375
7382
|
const o = i.lastIndexOf(t);
|
|
7376
7383
|
return n !== o ? e : n;
|
|
7377
7384
|
}
|
|
7378
|
-
const
|
|
7385
|
+
const Sc = (i, t) => i === null ? null : Y(Math.round(i), 0, t);
|
|
7379
7386
|
function Fs(i) {
|
|
7380
7387
|
const t = this.getLabels();
|
|
7381
7388
|
return i >= 0 && i < t.length ? t[i] : i;
|
|
7382
7389
|
}
|
|
7383
|
-
class
|
|
7390
|
+
class wc extends Bt {
|
|
7384
7391
|
static id = "category";
|
|
7385
7392
|
static defaults = {
|
|
7386
7393
|
ticks: {
|
|
@@ -7404,7 +7411,7 @@ class Sc extends Bt {
|
|
|
7404
7411
|
if (T(t))
|
|
7405
7412
|
return null;
|
|
7406
7413
|
const s = this.getLabels();
|
|
7407
|
-
return e = isFinite(e) && s[e] === t ? e :
|
|
7414
|
+
return e = isFinite(e) && s[e] === t ? e : kc(s, t, D(e, t), this._addedLabels), Sc(e, s.length - 1);
|
|
7408
7415
|
}
|
|
7409
7416
|
determineDataLimits() {
|
|
7410
7417
|
const { minDefined: t, maxDefined: e } = this.getUserBounds();
|
|
@@ -7441,7 +7448,7 @@ class Sc extends Bt {
|
|
|
7441
7448
|
return this.bottom;
|
|
7442
7449
|
}
|
|
7443
7450
|
}
|
|
7444
|
-
function
|
|
7451
|
+
function Cc(i, t) {
|
|
7445
7452
|
const e = [], { bounds: n, step: o, min: r, max: a, precision: l, count: c, maxTicks: h, maxDigits: d, includeBounds: u } = i, f = o || 1, g = h - 1, { min: p, max: m } = t, b = !T(r), _ = !T(a), y = !T(c), v = (m - p) / (d + 1);
|
|
7446
7453
|
let x = Ii((m - p) / g / f) * f, k, S, M, w;
|
|
7447
7454
|
if (x < 1e-14 && !b && !_)
|
|
@@ -7477,7 +7484,7 @@ function zs(i, t, { horizontal: e, minRotation: s }) {
|
|
|
7477
7484
|
const n = nt(s), o = (e ? Math.sin(n) : Math.cos(n)) || 1e-3, r = 0.75 * t * ("" + i).length;
|
|
7478
7485
|
return Math.min(t / o, r);
|
|
7479
7486
|
}
|
|
7480
|
-
class
|
|
7487
|
+
class Pc extends Bt {
|
|
7481
7488
|
constructor(t) {
|
|
7482
7489
|
super(t), this.start = void 0, this.end = void 0, this._startValue = void 0, this._endValue = void 0, this._valueRange = 0;
|
|
7483
7490
|
}
|
|
@@ -7522,7 +7529,7 @@ class Cc extends Bt {
|
|
|
7522
7529
|
horizontal: this.isHorizontal(),
|
|
7523
7530
|
minRotation: e.minRotation || 0,
|
|
7524
7531
|
includeBounds: e.includeBounds !== !1
|
|
7525
|
-
}, o = this._range || this, r =
|
|
7532
|
+
}, o = this._range || this, r = Cc(n, o);
|
|
7526
7533
|
return t.bounds === "ticks" && To(r, this, "value"), t.reverse ? (r.reverse(), this.start = this.max, this.end = this.min) : (this.start = this.min, this.end = this.max), r;
|
|
7527
7534
|
}
|
|
7528
7535
|
configure() {
|
|
@@ -7538,7 +7545,7 @@ class Cc extends Bt {
|
|
|
7538
7545
|
return Le(t, this.chart.options.locale, this.options.ticks.format);
|
|
7539
7546
|
}
|
|
7540
7547
|
}
|
|
7541
|
-
class
|
|
7548
|
+
class Dc extends Pc {
|
|
7542
7549
|
static id = "linear";
|
|
7543
7550
|
static defaults = {
|
|
7544
7551
|
ticks: {
|
|
@@ -7625,7 +7632,7 @@ function Hs(i, t, e, s) {
|
|
|
7625
7632
|
}
|
|
7626
7633
|
return K[n - 1];
|
|
7627
7634
|
}
|
|
7628
|
-
function
|
|
7635
|
+
function Oc(i, t, e, s, n) {
|
|
7629
7636
|
for (let o = K.length - 1; o >= K.indexOf(e); o--) {
|
|
7630
7637
|
const r = K[o];
|
|
7631
7638
|
if (ze[r].common && i._adapter.diff(n, s, r) >= t - 1)
|
|
@@ -7633,7 +7640,7 @@ function Dc(i, t, e, s, n) {
|
|
|
7633
7640
|
}
|
|
7634
7641
|
return K[e ? K.indexOf(e) : 0];
|
|
7635
7642
|
}
|
|
7636
|
-
function
|
|
7643
|
+
function Ac(i) {
|
|
7637
7644
|
for (let t = K.indexOf(i) + 1, e = K.length; t < e; ++t)
|
|
7638
7645
|
if (ze[K[t]].common)
|
|
7639
7646
|
return K[t];
|
|
@@ -7646,7 +7653,7 @@ function Vs(i, t, e) {
|
|
|
7646
7653
|
i[o] = !0;
|
|
7647
7654
|
}
|
|
7648
7655
|
}
|
|
7649
|
-
function
|
|
7656
|
+
function Tc(i, t, e, s) {
|
|
7650
7657
|
const n = i._adapter, o = +n.startOf(t[0].value, s), r = t[t.length - 1].value;
|
|
7651
7658
|
let a, l;
|
|
7652
7659
|
for (a = o; a <= r; a = +n.add(a, 1, s))
|
|
@@ -7661,7 +7668,7 @@ function Ns(i, t, e) {
|
|
|
7661
7668
|
value: a,
|
|
7662
7669
|
major: !1
|
|
7663
7670
|
});
|
|
7664
|
-
return o === 0 || !e ? s :
|
|
7671
|
+
return o === 0 || !e ? s : Tc(i, s, n, e);
|
|
7665
7672
|
}
|
|
7666
7673
|
class js extends Bt {
|
|
7667
7674
|
static id = "time";
|
|
@@ -7692,7 +7699,7 @@ class js extends Bt {
|
|
|
7692
7699
|
}, this._unit = "day", this._majorUnit = void 0, this._offsets = {}, this._normalized = !1, this._parseOpts = void 0;
|
|
7693
7700
|
}
|
|
7694
7701
|
init(t, e = {}) {
|
|
7695
|
-
const s = t.time || (t.time = {}), n = this._adapter = new
|
|
7702
|
+
const s = t.time || (t.time = {}), n = this._adapter = new va._date(t.adapters.date);
|
|
7696
7703
|
n.init(e), qt(s.displayFormats, n.formats()), this._parseOpts = {
|
|
7697
7704
|
parser: s.parser,
|
|
7698
7705
|
round: s.round,
|
|
@@ -7729,7 +7736,7 @@ class js extends Bt {
|
|
|
7729
7736
|
const t = this.options, e = t.time, s = t.ticks, n = s.source === "labels" ? this.getLabelTimestamps() : this._generate();
|
|
7730
7737
|
t.bounds === "ticks" && n.length && (this.min = this._userMin || n[0], this.max = this._userMax || n[n.length - 1]);
|
|
7731
7738
|
const o = this.min, r = this.max, a = Fo(n, o, r);
|
|
7732
|
-
return this._unit = e.unit || (s.autoSkip ? Hs(e.minUnit, this.min, this.max, this._getLabelCapacity(o)) :
|
|
7739
|
+
return this._unit = e.unit || (s.autoSkip ? Hs(e.minUnit, this.min, this.max, this._getLabelCapacity(o)) : Oc(this, a.length, e.minUnit, this.min, this.max)), this._majorUnit = !s.major.enabled || this._unit === "year" ? void 0 : Ac(this._unit), this.initOffsets(n), t.reverse && a.reverse(), Ns(this, a, this._majorUnit);
|
|
7733
7740
|
}
|
|
7734
7741
|
afterAutoSkip() {
|
|
7735
7742
|
this.options.offsetAfterAutoskip && this.initOffsets(this.ticks.map((t) => +t.value));
|
|
@@ -7833,7 +7840,7 @@ function ke(i, t, e) {
|
|
|
7833
7840
|
const c = r - o;
|
|
7834
7841
|
return c ? a + (l - a) * (t - o) / c : a;
|
|
7835
7842
|
}
|
|
7836
|
-
class
|
|
7843
|
+
class Gc extends js {
|
|
7837
7844
|
static id = "timeseries";
|
|
7838
7845
|
static defaults = js.defaults;
|
|
7839
7846
|
constructor(t) {
|
|
@@ -7907,14 +7914,14 @@ const Fn = {
|
|
|
7907
7914
|
type: String,
|
|
7908
7915
|
default: void 0
|
|
7909
7916
|
}
|
|
7910
|
-
},
|
|
7917
|
+
}, Rc = {
|
|
7911
7918
|
ariaLabel: {
|
|
7912
7919
|
type: String
|
|
7913
7920
|
},
|
|
7914
7921
|
ariaDescribedby: {
|
|
7915
7922
|
type: String
|
|
7916
7923
|
}
|
|
7917
|
-
},
|
|
7924
|
+
}, Lc = {
|
|
7918
7925
|
type: {
|
|
7919
7926
|
type: String,
|
|
7920
7927
|
required: !0
|
|
@@ -7925,18 +7932,18 @@ const Fn = {
|
|
|
7925
7932
|
// No delay by default
|
|
7926
7933
|
},
|
|
7927
7934
|
...Fn,
|
|
7928
|
-
...
|
|
7929
|
-
},
|
|
7935
|
+
...Rc
|
|
7936
|
+
}, Ec = $n[0] === "2" ? (i, t) => Object.assign(i, {
|
|
7930
7937
|
attrs: t
|
|
7931
7938
|
}) : (i, t) => Object.assign(i, t);
|
|
7932
7939
|
function Lt(i) {
|
|
7933
7940
|
return Ys(i) ? Qe(i) : i;
|
|
7934
7941
|
}
|
|
7935
|
-
function
|
|
7942
|
+
function Ic(i) {
|
|
7936
7943
|
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : i;
|
|
7937
7944
|
return Ys(t) ? new Proxy(i, {}) : i;
|
|
7938
7945
|
}
|
|
7939
|
-
function
|
|
7946
|
+
function Fc(i, t) {
|
|
7940
7947
|
const e = i.options;
|
|
7941
7948
|
e && t && Object.assign(e, t);
|
|
7942
7949
|
}
|
|
@@ -7952,15 +7959,15 @@ function Bn(i, t, e) {
|
|
|
7952
7959
|
} : (s.push(o), Object.assign(o, n), o);
|
|
7953
7960
|
});
|
|
7954
7961
|
}
|
|
7955
|
-
function
|
|
7962
|
+
function zc(i, t) {
|
|
7956
7963
|
const e = {
|
|
7957
7964
|
labels: [],
|
|
7958
7965
|
datasets: []
|
|
7959
7966
|
};
|
|
7960
7967
|
return zn(e, i.labels), Bn(e, i.datasets, t), e;
|
|
7961
7968
|
}
|
|
7962
|
-
const
|
|
7963
|
-
props:
|
|
7969
|
+
const Bc = li({
|
|
7970
|
+
props: Lc,
|
|
7964
7971
|
setup(i, t) {
|
|
7965
7972
|
let { expose: e, slots: s } = t;
|
|
7966
7973
|
const n = Wn(null), o = $s(null);
|
|
@@ -7969,7 +7976,7 @@ const zc = li({
|
|
|
7969
7976
|
});
|
|
7970
7977
|
const r = () => {
|
|
7971
7978
|
if (!n.value) return;
|
|
7972
|
-
const { type: c, data: h, options: d, plugins: u, datasetIdKey: f } = i, g =
|
|
7979
|
+
const { type: c, data: h, options: d, plugins: u, datasetIdKey: f } = i, g = zc(h, f), p = Ic(g, h);
|
|
7973
7980
|
o.value = new Fe(n.value, {
|
|
7974
7981
|
type: c,
|
|
7975
7982
|
data: p,
|
|
@@ -7997,7 +8004,7 @@ const zc = li({
|
|
|
7997
8004
|
let m = !1;
|
|
7998
8005
|
if (d) {
|
|
7999
8006
|
const b = Lt(d), _ = Lt(f);
|
|
8000
|
-
b && b !== _ && (
|
|
8007
|
+
b && b !== _ && (Fc(p, b), m = !0);
|
|
8001
8008
|
}
|
|
8002
8009
|
if (u) {
|
|
8003
8010
|
const b = Lt(u.labels), _ = Lt(g.labels), y = Lt(u.datasets), v = Lt(g.datasets);
|
|
@@ -8030,7 +8037,7 @@ function wi(i, t) {
|
|
|
8030
8037
|
};
|
|
8031
8038
|
return n({
|
|
8032
8039
|
chart: o
|
|
8033
|
-
}), () => Je(
|
|
8040
|
+
}), () => Je(Bc, Ec({
|
|
8034
8041
|
ref: r
|
|
8035
8042
|
}, {
|
|
8036
8043
|
type: i,
|
|
@@ -8039,7 +8046,7 @@ function wi(i, t) {
|
|
|
8039
8046
|
}
|
|
8040
8047
|
});
|
|
8041
8048
|
}
|
|
8042
|
-
const
|
|
8049
|
+
const Wc = /* @__PURE__ */ wi("bar", ma), Hc = /* @__PURE__ */ wi("line", _a), Vc = /* @__PURE__ */ wi("pie", ya), Nc = /* @__PURE__ */ li({
|
|
8043
8050
|
__name: "UiChart",
|
|
8044
8051
|
props: {
|
|
8045
8052
|
labels: {},
|
|
@@ -8049,18 +8056,18 @@ const Bc = /* @__PURE__ */ wi("bar", ga), Wc = /* @__PURE__ */ wi("line", ma), H
|
|
|
8049
8056
|
isShowLegend: { type: Boolean }
|
|
8050
8057
|
},
|
|
8051
8058
|
setup(i) {
|
|
8052
|
-
const t = i, e = Be(() => t.type === "Pie" ?
|
|
8059
|
+
const t = i, e = Be(() => t.type === "Pie" ? Vc : t.type === "Line" ? Hc : Wc), s = Be(() => t.isShowLegend), n = Be(() => t.type === "Line" ? "inner" : "center");
|
|
8053
8060
|
Fe.register(
|
|
8054
|
-
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
|
|
8059
|
-
|
|
8060
|
-
|
|
8061
|
-
$l,
|
|
8061
|
+
fc,
|
|
8062
|
+
vc,
|
|
8063
|
+
Jl,
|
|
8064
|
+
wc,
|
|
8065
|
+
Dc,
|
|
8066
|
+
oc,
|
|
8067
|
+
Il,
|
|
8062
8068
|
Yl,
|
|
8063
|
-
|
|
8069
|
+
Xl,
|
|
8070
|
+
dc
|
|
8064
8071
|
);
|
|
8065
8072
|
const o = {
|
|
8066
8073
|
labels: [...t.labels],
|
|
@@ -8091,12 +8098,12 @@ const Bc = /* @__PURE__ */ wi("bar", ga), Wc = /* @__PURE__ */ wi("line", ma), H
|
|
|
8091
8098
|
}, null, 8, ["data-type"]))
|
|
8092
8099
|
], 2));
|
|
8093
8100
|
}
|
|
8094
|
-
}),
|
|
8095
|
-
chart:
|
|
8096
|
-
title:
|
|
8097
|
-
},
|
|
8098
|
-
$style:
|
|
8099
|
-
},
|
|
8101
|
+
}), jc = "_chart_1dagb_1", $c = "_title_1dagb_8", Yc = {
|
|
8102
|
+
chart: jc,
|
|
8103
|
+
title: $c
|
|
8104
|
+
}, Xc = {
|
|
8105
|
+
$style: Yc
|
|
8106
|
+
}, Zc = /* @__PURE__ */ qn(Nc, [["__cssModules", Xc]]);
|
|
8100
8107
|
export {
|
|
8101
|
-
|
|
8108
|
+
Zc as default
|
|
8102
8109
|
};
|