@adyen/lume 0.1.6 → 0.1.8
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/README.md +38 -16
- package/dist/common/{2c318357.js → 25ccdedf.js} +2 -2
- package/dist/common/25ccdedf.js.map +1 -0
- package/dist/common/{df7327e8.js → 55f09e14.js} +1077 -1042
- package/dist/common/55f09e14.js.map +1 -0
- package/dist/common/{b0835720.js → 6f5e659c.js} +2 -2
- package/dist/common/6f5e659c.js.map +1 -0
- package/dist/common/{797e4fbd.js → 97d72066.js} +2 -2
- package/dist/common/97d72066.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/plugin.js +1 -1
- package/dist/scss/components/lume-tooltip.scss +10 -1
- package/dist/scss/main.scss +2 -2
- package/dist/styles/main.css +1 -1
- package/package.json +9 -5
- package/dist/common/2c318357.js.map +0 -1
- package/dist/common/797e4fbd.js.map +0 -1
- package/dist/common/b0835720.js.map +0 -1
- package/dist/common/df7327e8.js.map +0 -1
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { sankeyLinkHorizontal as
|
|
3
|
-
import {
|
|
4
|
-
import { createPopper as
|
|
5
|
-
function
|
|
6
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
|
1
|
+
import D, { isRef as Bt, reactive as lt, computed as v, ref as $, watch as N, defineComponent as L, toRefs as w, onBeforeMount as oe, onMounted as V, onBeforeUnmount as gt, watchEffect as Mt, toRef as se, defineAsyncComponent as ht } from "vue";
|
|
2
|
+
import { sankeyLinkHorizontal as ie, sankey as le, sankeyJustify as ue } from "d3-sankey";
|
|
3
|
+
import { format as ce, ticks as de, scaleBand as J, scaleLinear as Q, line as fe, area as pe } from "d3";
|
|
4
|
+
import { createPopper as ve } from "@popperjs/core";
|
|
5
|
+
function ot(e) {
|
|
6
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? ot = function(t) {
|
|
7
7
|
return typeof t;
|
|
8
|
-
} :
|
|
8
|
+
} : ot = function(t) {
|
|
9
9
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
10
|
-
},
|
|
10
|
+
}, ot(e);
|
|
11
11
|
}
|
|
12
|
-
function
|
|
13
|
-
return
|
|
12
|
+
function he(e) {
|
|
13
|
+
return _e(e) || me(e) || ge();
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function _e(e) {
|
|
16
16
|
if (Array.isArray(e)) {
|
|
17
17
|
for (var t = 0, n = new Array(e.length); t < e.length; t++)
|
|
18
18
|
n[t] = e[t];
|
|
19
19
|
return n;
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
|
-
function
|
|
22
|
+
function me(e) {
|
|
23
23
|
if (Symbol.iterator in Object(e) || Object.prototype.toString.call(e) === "[object Arguments]")
|
|
24
24
|
return Array.from(e);
|
|
25
25
|
}
|
|
26
|
-
function
|
|
26
|
+
function ge() {
|
|
27
27
|
throw new TypeError("Invalid attempt to spread non-iterable instance");
|
|
28
28
|
}
|
|
29
|
-
var
|
|
30
|
-
function
|
|
31
|
-
return Array.isArray(e) ||
|
|
29
|
+
var at = typeof window < "u";
|
|
30
|
+
function ye(e) {
|
|
31
|
+
return Array.isArray(e) || ot(e) === "object" ? Object.freeze(e) : e;
|
|
32
32
|
}
|
|
33
|
-
function
|
|
33
|
+
function be(e) {
|
|
34
34
|
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
35
35
|
return e.reduce(function(n, r) {
|
|
36
36
|
var a = r.passengers[0], o = typeof a == "function" ? a(t) : r.passengers;
|
|
37
37
|
return n.concat(o);
|
|
38
38
|
}, []);
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function xe(e, t) {
|
|
41
41
|
return e.map(function(n, r) {
|
|
42
42
|
return [r, n];
|
|
43
43
|
}).sort(function(n, r) {
|
|
@@ -51,30 +51,30 @@ function St(e, t) {
|
|
|
51
51
|
return e.hasOwnProperty(r) && (n[r] = e[r]), n;
|
|
52
52
|
}, {});
|
|
53
53
|
}
|
|
54
|
-
var
|
|
54
|
+
var Ht = {}, Te = {}, Ae = {}, Oe = D.extend({
|
|
55
55
|
data: function() {
|
|
56
56
|
return {
|
|
57
|
-
transports:
|
|
58
|
-
targets:
|
|
59
|
-
sources:
|
|
60
|
-
trackInstances:
|
|
57
|
+
transports: Ht,
|
|
58
|
+
targets: Te,
|
|
59
|
+
sources: Ae,
|
|
60
|
+
trackInstances: at
|
|
61
61
|
};
|
|
62
62
|
},
|
|
63
63
|
methods: {
|
|
64
64
|
open: function(t) {
|
|
65
|
-
if (!!
|
|
66
|
-
var n = t.to, r = t.from, a = t.passengers, o = t.order,
|
|
65
|
+
if (!!at) {
|
|
66
|
+
var n = t.to, r = t.from, a = t.passengers, o = t.order, s = o === void 0 ? 1 / 0 : o;
|
|
67
67
|
if (!(!n || !r || !a)) {
|
|
68
|
-
var
|
|
68
|
+
var l = {
|
|
69
69
|
to: n,
|
|
70
70
|
from: r,
|
|
71
|
-
passengers:
|
|
72
|
-
order:
|
|
73
|
-
},
|
|
74
|
-
|
|
75
|
-
var
|
|
76
|
-
|
|
77
|
-
return
|
|
71
|
+
passengers: ye(a),
|
|
72
|
+
order: s
|
|
73
|
+
}, i = Object.keys(this.transports);
|
|
74
|
+
i.indexOf(n) === -1 && D.set(this.transports, n, []);
|
|
75
|
+
var u = this.$_getTransportIndex(l), h = this.transports[n].slice(0);
|
|
76
|
+
u === -1 ? h.push(l) : h[u] = l, this.transports[n] = xe(h, function(c, f) {
|
|
77
|
+
return c.order - f.order;
|
|
78
78
|
});
|
|
79
79
|
}
|
|
80
80
|
}
|
|
@@ -87,19 +87,19 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
87
87
|
else {
|
|
88
88
|
var o = this.$_getTransportIndex(t);
|
|
89
89
|
if (o >= 0) {
|
|
90
|
-
var
|
|
91
|
-
|
|
90
|
+
var s = this.transports[r].slice(0);
|
|
91
|
+
s.splice(o, 1), this.transports[r] = s;
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
},
|
|
95
95
|
registerTarget: function(t, n, r) {
|
|
96
|
-
!
|
|
96
|
+
!at || (this.trackInstances && !r && this.targets[t] && console.warn("[portal-vue]: Target ".concat(t, " already exists")), this.$set(this.targets, t, Object.freeze([n])));
|
|
97
97
|
},
|
|
98
98
|
unregisterTarget: function(t) {
|
|
99
99
|
this.$delete(this.targets, t);
|
|
100
100
|
},
|
|
101
101
|
registerSource: function(t, n, r) {
|
|
102
|
-
!
|
|
102
|
+
!at || (this.trackInstances && !r && this.sources[t] && console.warn("[portal-vue]: source ".concat(t, " already exists")), this.$set(this.sources, t, Object.freeze([n])));
|
|
103
103
|
},
|
|
104
104
|
unregisterSource: function(t) {
|
|
105
105
|
this.$delete(this.sources, t);
|
|
@@ -121,7 +121,7 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
121
121
|
return -1;
|
|
122
122
|
}
|
|
123
123
|
}
|
|
124
|
-
}), P = new
|
|
124
|
+
}), P = new Oe(Ht), $e = 1, yt = D.extend({
|
|
125
125
|
name: "portal",
|
|
126
126
|
props: {
|
|
127
127
|
disabled: {
|
|
@@ -130,7 +130,7 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
130
130
|
name: {
|
|
131
131
|
type: String,
|
|
132
132
|
default: function() {
|
|
133
|
-
return String(
|
|
133
|
+
return String($e++);
|
|
134
134
|
}
|
|
135
135
|
},
|
|
136
136
|
order: {
|
|
@@ -197,7 +197,7 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
197
197
|
var n = {
|
|
198
198
|
from: this.name,
|
|
199
199
|
to: this.to,
|
|
200
|
-
passengers:
|
|
200
|
+
passengers: he(t),
|
|
201
201
|
order: this.order
|
|
202
202
|
};
|
|
203
203
|
P.open(n);
|
|
@@ -217,7 +217,7 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
217
217
|
key: "v-portal-placeholder"
|
|
218
218
|
});
|
|
219
219
|
}
|
|
220
|
-
}),
|
|
220
|
+
}), bt = D.extend({
|
|
221
221
|
name: "portalTarget",
|
|
222
222
|
props: {
|
|
223
223
|
multiple: {
|
|
@@ -281,7 +281,7 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
281
281
|
return this.multiple ? t : t.length === 0 ? [] : [t[t.length - 1]];
|
|
282
282
|
},
|
|
283
283
|
passengers: function() {
|
|
284
|
-
return
|
|
284
|
+
return be(this.ownTransports, this.slotProps);
|
|
285
285
|
}
|
|
286
286
|
},
|
|
287
287
|
methods: {
|
|
@@ -304,8 +304,8 @@ var Bt = {}, be = {}, xe = {}, Ae = N.extend({
|
|
|
304
304
|
}
|
|
305
305
|
}, r);
|
|
306
306
|
}
|
|
307
|
-
}),
|
|
308
|
-
|
|
307
|
+
}), ke = 0, Le = ["disabled", "name", "order", "slim", "slotProps", "tag", "to"], Se = ["multiple", "transition"];
|
|
308
|
+
D.extend({
|
|
309
309
|
name: "MountingPortal",
|
|
310
310
|
inheritAttrs: !1,
|
|
311
311
|
props: {
|
|
@@ -325,7 +325,7 @@ N.extend({
|
|
|
325
325
|
name: {
|
|
326
326
|
type: String,
|
|
327
327
|
default: function() {
|
|
328
|
-
return "mounted_" + String(
|
|
328
|
+
return "mounted_" + String(ke++);
|
|
329
329
|
}
|
|
330
330
|
},
|
|
331
331
|
order: {
|
|
@@ -390,11 +390,11 @@ N.extend({
|
|
|
390
390
|
var a = typeof r == "string" ? r : "DIV", o = document.createElement(a);
|
|
391
391
|
t.appendChild(o), t = o;
|
|
392
392
|
}
|
|
393
|
-
var
|
|
394
|
-
|
|
393
|
+
var s = St(this.$props, Se);
|
|
394
|
+
s.slim = this.targetSlim, s.tag = this.targetTag, s.slotProps = this.targetSlotProps, s.name = this.to, this.portalTarget = new bt({
|
|
395
395
|
el: t,
|
|
396
396
|
parent: this.$parent || this,
|
|
397
|
-
propsData:
|
|
397
|
+
propsData: s
|
|
398
398
|
});
|
|
399
399
|
}
|
|
400
400
|
},
|
|
@@ -410,8 +410,8 @@ N.extend({
|
|
|
410
410
|
if (!this.portalTarget)
|
|
411
411
|
return console.warn("[portal-vue] Target wasn't mounted"), t();
|
|
412
412
|
if (!this.$scopedSlots.manual) {
|
|
413
|
-
var n = St(this.$props,
|
|
414
|
-
return t(
|
|
413
|
+
var n = St(this.$props, Le);
|
|
414
|
+
return t(yt, {
|
|
415
415
|
props: n,
|
|
416
416
|
attrs: this.$attrs,
|
|
417
417
|
on: this.$listeners,
|
|
@@ -424,11 +424,11 @@ N.extend({
|
|
|
424
424
|
return Array.isArray(r) && (r = r[0]), r || t();
|
|
425
425
|
}
|
|
426
426
|
});
|
|
427
|
-
var M = /* @__PURE__ */ ((e) => (e.Skyblue = "skyblue", e.Royalblue = "royalblue", e.Violet = "violet", e.Darkteal = "darkteal", e.Gold = "gold", e))(M || {}),
|
|
428
|
-
const
|
|
427
|
+
var M = /* @__PURE__ */ ((e) => (e.Skyblue = "skyblue", e.Royalblue = "royalblue", e.Violet = "violet", e.Darkteal = "darkteal", e.Gold = "gold", e))(M || {}), xt = /* @__PURE__ */ ((e) => (e.SkyTeal = "skyblue-darkteal", e.VioletRoyal = "violet-royalblue", e.VioletTeal = "violet-darkteal", e.GoldTeal = "gold-darkteal", e.GoldRoyal = "gold-royalblue", e))(xt || {}), Tt = /* @__PURE__ */ ((e) => (e["01"] = "01", e["02"] = "02", e["03"] = "03", e["04"] = "04", e["05"] = "05", e["06"] = "06", e["07"] = "07", e["08"] = "08", e["09"] = "09", e))(Tt || {});
|
|
428
|
+
const T = {
|
|
429
429
|
HORIZONTAL: "horizontal",
|
|
430
430
|
VERTICAL: "vertical"
|
|
431
|
-
},
|
|
431
|
+
}, we = {
|
|
432
432
|
SINGLE: "single",
|
|
433
433
|
GROUPED: "grouped",
|
|
434
434
|
STACKED: "stacked"
|
|
@@ -445,7 +445,7 @@ const A = {
|
|
|
445
445
|
bottom: 28,
|
|
446
446
|
left: 24
|
|
447
447
|
}
|
|
448
|
-
}, jt = "No data",
|
|
448
|
+
}, jt = "No data", Ce = 20, Ie = 0.33, Ne = 0.5, De = 1, At = [
|
|
449
449
|
"auto",
|
|
450
450
|
"auto-start",
|
|
451
451
|
"auto-end",
|
|
@@ -463,7 +463,7 @@ const A = {
|
|
|
463
463
|
"left-end"
|
|
464
464
|
];
|
|
465
465
|
var W = /* @__PURE__ */ ((e) => (e.Categorical = "categorical", e.Sequential = "sequential", e.Divergent = "divergent", e))(W || {});
|
|
466
|
-
function
|
|
466
|
+
function Re() {
|
|
467
467
|
return process.env.NODE_ENV === "production";
|
|
468
468
|
}
|
|
469
469
|
function Ft(e) {
|
|
@@ -471,28 +471,28 @@ function Ft(e) {
|
|
|
471
471
|
(t) => t.values.map((n) => n == null ? void 0 : n.value).flat()
|
|
472
472
|
).flat()) || [];
|
|
473
473
|
}
|
|
474
|
-
function
|
|
474
|
+
function ut(e) {
|
|
475
475
|
return e.length === 1;
|
|
476
476
|
}
|
|
477
477
|
function _t(e) {
|
|
478
478
|
return !!e && typeof e == "object" && !Array.isArray(e);
|
|
479
479
|
}
|
|
480
|
-
function
|
|
480
|
+
function Vt(e, t) {
|
|
481
481
|
const n = structuredClone(e);
|
|
482
482
|
return Object.entries(t).forEach(([r, a]) => {
|
|
483
|
-
n[r] = _t(e[r]) && _t(a) ?
|
|
483
|
+
n[r] = _t(e[r]) && _t(a) ? Vt(e[r], a) : a;
|
|
484
484
|
}), n;
|
|
485
485
|
}
|
|
486
|
-
function
|
|
486
|
+
function Pe(e) {
|
|
487
487
|
return e != null && _t(e) && "value" in e;
|
|
488
488
|
}
|
|
489
489
|
function U(e) {
|
|
490
490
|
return (e == null ? void 0 : e.bandwidth) !== void 0;
|
|
491
491
|
}
|
|
492
|
-
function
|
|
492
|
+
function Ot(e) {
|
|
493
493
|
return U(e) ? e.bandwidth() : Math.max(...e.range()) / Math.max(...e.domain());
|
|
494
494
|
}
|
|
495
|
-
const
|
|
495
|
+
const Ee = (e, t) => {
|
|
496
496
|
if (!e)
|
|
497
497
|
throw new Error("Data is not a valid array");
|
|
498
498
|
if (e.length === 0)
|
|
@@ -502,17 +502,17 @@ const De = (e, t) => {
|
|
|
502
502
|
throw new Error("Index exceeds length of at least one of the datasets");
|
|
503
503
|
});
|
|
504
504
|
};
|
|
505
|
-
function
|
|
505
|
+
function Gt(e, t) {
|
|
506
506
|
var n;
|
|
507
|
-
return
|
|
507
|
+
return Ee(e, t), ((n = e.reduce(
|
|
508
508
|
(r, a) => {
|
|
509
|
-
var o,
|
|
510
|
-
return ((
|
|
509
|
+
var o, s, l, i;
|
|
510
|
+
return ((s = (o = r.values[t]) == null ? void 0 : o.value) != null ? s : 0) > ((i = (l = a.values[t]) == null ? void 0 : l.value) != null ? i : 0) ? r : a;
|
|
511
511
|
}
|
|
512
512
|
).values[t]) == null ? void 0 : n.value) || 0;
|
|
513
513
|
}
|
|
514
|
-
function
|
|
515
|
-
const t =
|
|
514
|
+
function st(e) {
|
|
515
|
+
const t = Bt(e) ? e.value : e;
|
|
516
516
|
if (!t)
|
|
517
517
|
throw new Error("No empty array can be created from specified data value");
|
|
518
518
|
const n = Math.max(
|
|
@@ -521,20 +521,20 @@ function ot(e) {
|
|
|
521
521
|
);
|
|
522
522
|
return Array(n).fill(null);
|
|
523
523
|
}
|
|
524
|
-
function
|
|
524
|
+
function Be(e) {
|
|
525
525
|
return U(e) ? e.domain().length : Math.max(...e.domain());
|
|
526
526
|
}
|
|
527
|
-
function
|
|
527
|
+
function Me(e, t) {
|
|
528
528
|
return (n) => Math.round(e * (1 - n) + t * n);
|
|
529
529
|
}
|
|
530
|
-
function
|
|
530
|
+
function R(e) {
|
|
531
531
|
var t;
|
|
532
532
|
return typeof e == "string" || typeof e == "number" ? e : (t = e.id) != null ? t : e.label;
|
|
533
533
|
}
|
|
534
534
|
function zt(e, t) {
|
|
535
535
|
return t.length && t.indexOf(e) === -1;
|
|
536
536
|
}
|
|
537
|
-
function
|
|
537
|
+
function He(e, t, n) {
|
|
538
538
|
const r = n ? e.length - t : t, a = e.slice(0, r);
|
|
539
539
|
return e.slice(r).concat(a);
|
|
540
540
|
}
|
|
@@ -548,58 +548,58 @@ function q(e) {
|
|
|
548
548
|
}
|
|
549
549
|
return e;
|
|
550
550
|
}
|
|
551
|
-
const
|
|
551
|
+
const je = (e = 21) => crypto.getRandomValues(new Uint8Array(e)).reduce(
|
|
552
552
|
(t, n) => t += (n &= 63) < 36 ? n.toString(36) : n < 62 ? (n - 26).toString(36).toUpperCase() : n > 62 ? "-" : "_",
|
|
553
553
|
""
|
|
554
554
|
);
|
|
555
|
-
var
|
|
556
|
-
Learn more: https://lume.design/guidelines/datasets`, e.ColorLoop = "Colors will loop around after the 5th dataset. You can prevent this by setting specific colors for your datasets.", e.NotContainedInSvg = "This component is an `SVGElement`, thus it is required to be inside an `<svg>` container.", e))(
|
|
557
|
-
const
|
|
558
|
-
function
|
|
559
|
-
t &&
|
|
555
|
+
var tt = /* @__PURE__ */ ((e) => (e.DatasetLength = `Our guidelines highly recommend not having more than 5 datasets in one chart.
|
|
556
|
+
Learn more: https://lume.design/guidelines/datasets`, e.ColorLoop = "Colors will loop around after the 5th dataset. You can prevent this by setting specific colors for your datasets.", e.InvalidFormat = "The string provided to format is invalid. Please refer to https://github.com/d3/d3-format for valid arguments.", e.NotContainedInSvg = "This component is an `SVGElement`, thus it is required to be inside an `<svg>` container.", e))(tt || {});
|
|
557
|
+
const Fe = "[lume] ";
|
|
558
|
+
function ct(e, t = !0) {
|
|
559
|
+
t && Re() || console.warn(Fe + "Warning: " + e);
|
|
560
560
|
}
|
|
561
|
-
const
|
|
562
|
-
function
|
|
563
|
-
return e === W.Divergent ?
|
|
561
|
+
const Ve = W.Categorical, Ge = M.Skyblue, ze = xt.SkyTeal;
|
|
562
|
+
function We(e) {
|
|
563
|
+
return e === W.Divergent ? ze : Ge;
|
|
564
564
|
}
|
|
565
|
-
function
|
|
566
|
-
return Object.values(
|
|
565
|
+
function Ze(e) {
|
|
566
|
+
return Object.values(Tt).includes(e);
|
|
567
567
|
}
|
|
568
|
-
function
|
|
569
|
-
return t === W.Divergent ? Object.values(
|
|
568
|
+
function wt(e, t) {
|
|
569
|
+
return t === W.Divergent ? Object.values(xt).includes(e) : Object.values({ ...M, ...Tt }).includes(
|
|
570
570
|
e
|
|
571
571
|
);
|
|
572
572
|
}
|
|
573
|
-
function
|
|
573
|
+
function qe(e, t) {
|
|
574
574
|
const n = Object.values(M).indexOf(e);
|
|
575
|
-
return
|
|
575
|
+
return He(Object.values(M), n)[t];
|
|
576
576
|
}
|
|
577
|
-
function
|
|
577
|
+
function Xe(e, t) {
|
|
578
578
|
const n = 50 + t * 10;
|
|
579
579
|
return `${e}-${n}`;
|
|
580
580
|
}
|
|
581
|
-
function
|
|
581
|
+
function Ue(e, t) {
|
|
582
582
|
const n = (t + 1) * 10;
|
|
583
583
|
return `${e}-${n}`;
|
|
584
584
|
}
|
|
585
|
-
function
|
|
585
|
+
function Ct(e, t, n) {
|
|
586
586
|
switch (t) {
|
|
587
587
|
default:
|
|
588
588
|
case W.Categorical:
|
|
589
|
-
return
|
|
589
|
+
return Ze(e) ? e : qe(e, n);
|
|
590
590
|
case W.Sequential:
|
|
591
|
-
return
|
|
591
|
+
return Xe(e, n);
|
|
592
592
|
case W.Divergent:
|
|
593
|
-
return
|
|
593
|
+
return Ue(e, n);
|
|
594
594
|
}
|
|
595
595
|
}
|
|
596
|
-
function
|
|
597
|
-
return
|
|
596
|
+
function Ye(e, t, n = Ve, r) {
|
|
597
|
+
return wt(e, n) ? e : (r > 4 && (ct(tt.ColorLoop), r = r % 5), wt(t, n) ? Ct(t, n, r) : Ct(We(n), n, r));
|
|
598
598
|
}
|
|
599
|
-
function
|
|
600
|
-
return e.map((t) =>
|
|
599
|
+
function Ke(e) {
|
|
600
|
+
return e.map((t) => Pe(t) ? t : { value: t });
|
|
601
601
|
}
|
|
602
|
-
function
|
|
602
|
+
function Je(e) {
|
|
603
603
|
return e.__internal === !0;
|
|
604
604
|
}
|
|
605
605
|
const Wt = (e = null) => ({
|
|
@@ -617,118 +617,138 @@ const Wt = (e = null) => ({
|
|
|
617
617
|
default: M.Skyblue
|
|
618
618
|
}
|
|
619
619
|
});
|
|
620
|
-
function
|
|
621
|
-
const o =
|
|
620
|
+
function dt(e, t, n, r, a) {
|
|
621
|
+
const o = lt({
|
|
622
622
|
width: 0,
|
|
623
623
|
height: 0
|
|
624
|
-
}),
|
|
624
|
+
}), s = je(12), l = v(() => {
|
|
625
625
|
var h;
|
|
626
|
-
return e.value.length > 5 &&
|
|
627
|
-
(
|
|
628
|
-
if (
|
|
629
|
-
return
|
|
630
|
-
const p =
|
|
631
|
-
|
|
626
|
+
return e.value.length > 5 && ct(tt.DatasetLength), (h = e.value) == null ? void 0 : h.map(
|
|
627
|
+
(c, f) => {
|
|
628
|
+
if (Je(c))
|
|
629
|
+
return c;
|
|
630
|
+
const p = Ke(c.values), d = Ye(
|
|
631
|
+
c.color,
|
|
632
632
|
n == null ? void 0 : n.value,
|
|
633
633
|
r == null ? void 0 : r.value.colorPalette,
|
|
634
|
-
|
|
634
|
+
f
|
|
635
635
|
);
|
|
636
636
|
return {
|
|
637
|
-
...
|
|
637
|
+
...c,
|
|
638
638
|
values: p,
|
|
639
639
|
color: d,
|
|
640
640
|
__internal: !0
|
|
641
641
|
};
|
|
642
642
|
}
|
|
643
643
|
);
|
|
644
|
-
}),
|
|
645
|
-
function
|
|
646
|
-
const
|
|
647
|
-
|
|
644
|
+
}), i = v(() => Array.isArray(t.value) ? t.value : st(e.value).map((h, c) => c));
|
|
645
|
+
function u(h) {
|
|
646
|
+
const c = (a == null ? void 0 : a.value) === T.HORIZONTAL ? st(e).length * (Ce * 2) : h.height;
|
|
647
|
+
D.set(o, "width", h.width), D.set(o, "height", c);
|
|
648
648
|
}
|
|
649
649
|
return {
|
|
650
|
-
chartID:
|
|
651
|
-
computedLabels:
|
|
650
|
+
chartID: s,
|
|
651
|
+
computedLabels: i,
|
|
652
652
|
containerSize: o,
|
|
653
|
-
internalData:
|
|
654
|
-
updateSize:
|
|
653
|
+
internalData: l,
|
|
654
|
+
updateSize: u
|
|
655
655
|
};
|
|
656
656
|
}
|
|
657
|
-
const
|
|
657
|
+
const Zt = (e) => {
|
|
658
|
+
let t = null;
|
|
659
|
+
switch (typeof e) {
|
|
660
|
+
case "string":
|
|
661
|
+
try {
|
|
662
|
+
t = ce(e);
|
|
663
|
+
} catch {
|
|
664
|
+
ct(tt.InvalidFormat), t = null;
|
|
665
|
+
}
|
|
666
|
+
break;
|
|
667
|
+
case "function":
|
|
668
|
+
t = e;
|
|
669
|
+
break;
|
|
670
|
+
default:
|
|
671
|
+
t = null;
|
|
672
|
+
}
|
|
673
|
+
function n(r) {
|
|
674
|
+
return t ? t(r) : r;
|
|
675
|
+
}
|
|
676
|
+
return n;
|
|
677
|
+
}, ft = () => ({
|
|
658
678
|
options: {
|
|
659
679
|
type: Object,
|
|
660
680
|
default: () => ({})
|
|
661
681
|
}
|
|
662
682
|
});
|
|
663
683
|
function F(e, t) {
|
|
664
|
-
return { allOptions:
|
|
665
|
-
const r =
|
|
666
|
-
return r ?
|
|
684
|
+
return { allOptions: v(() => {
|
|
685
|
+
const r = Bt(t) ? t == null ? void 0 : t.value : t;
|
|
686
|
+
return r ? Vt(r, e.value) : e.value;
|
|
667
687
|
}) };
|
|
668
688
|
}
|
|
669
|
-
const
|
|
670
|
-
function
|
|
671
|
-
const r =
|
|
672
|
-
function
|
|
689
|
+
const Qe = 0.15;
|
|
690
|
+
function tn(e, t, n) {
|
|
691
|
+
const r = $(), a = v(() => Math.max(...e.value.range())), o = v(() => t.value.length);
|
|
692
|
+
function s() {
|
|
673
693
|
if (!t.value)
|
|
674
694
|
return;
|
|
675
|
-
const
|
|
676
|
-
(h,
|
|
695
|
+
const i = t.value.reduce(
|
|
696
|
+
(h, c) => h + c.getBoundingClientRect().width,
|
|
677
697
|
0
|
|
678
|
-
),
|
|
679
|
-
r.value =
|
|
698
|
+
), u = Math.ceil(i / o.value);
|
|
699
|
+
r.value = u + u * Qe;
|
|
680
700
|
}
|
|
681
|
-
function
|
|
701
|
+
function l(i) {
|
|
682
702
|
if (!t.value)
|
|
683
703
|
return !0;
|
|
684
|
-
const
|
|
685
|
-
if (
|
|
704
|
+
const u = t.value.length;
|
|
705
|
+
if (i === 0)
|
|
686
706
|
return !0;
|
|
687
|
-
const h = a.value /
|
|
688
|
-
return
|
|
707
|
+
const h = a.value / u, c = typeof n == "number" && n > 0 && n + 1 || Math.ceil(r.value / h);
|
|
708
|
+
return i % c === 0;
|
|
689
709
|
}
|
|
690
|
-
return
|
|
710
|
+
return N(t, s), { showTick: l };
|
|
691
711
|
}
|
|
692
|
-
function
|
|
693
|
-
e != null && e.closest("svg") ||
|
|
712
|
+
function pt(e) {
|
|
713
|
+
e != null && e.closest("svg") || ct(tt.NotContainedInSvg);
|
|
694
714
|
}
|
|
695
|
-
const
|
|
715
|
+
const qt = {
|
|
696
716
|
gridLines: !1,
|
|
697
717
|
withTitle: !0,
|
|
698
718
|
showTicks: !0,
|
|
699
719
|
tickCount: 10,
|
|
700
720
|
tickFormat: null,
|
|
701
721
|
tickPadding: 8
|
|
702
|
-
},
|
|
703
|
-
...
|
|
722
|
+
}, en = {
|
|
723
|
+
...qt,
|
|
704
724
|
withTitle: !1,
|
|
705
725
|
skip: !0
|
|
706
|
-
},
|
|
707
|
-
...
|
|
726
|
+
}, nn = {
|
|
727
|
+
...qt,
|
|
708
728
|
gridLines: !0
|
|
709
|
-
},
|
|
710
|
-
const r =
|
|
711
|
-
function a(
|
|
729
|
+
}, rn = 12, an = 8, on = function(e, t, n) {
|
|
730
|
+
const r = v(() => e.value.step() * e.value.paddingInner() / 2);
|
|
731
|
+
function a(i) {
|
|
712
732
|
return {
|
|
713
|
-
transform: `translate(${e.value(
|
|
733
|
+
transform: `translate(${e.value(i) - r.value}, 0)`
|
|
714
734
|
};
|
|
715
735
|
}
|
|
716
736
|
function o() {
|
|
717
737
|
return {
|
|
718
738
|
x: -8,
|
|
719
739
|
width: e.value.step() + 16,
|
|
720
|
-
height: n.value.tickPadding +
|
|
740
|
+
height: n.value.tickPadding + rn + an
|
|
721
741
|
};
|
|
722
742
|
}
|
|
723
|
-
function
|
|
724
|
-
const
|
|
743
|
+
function s() {
|
|
744
|
+
const i = e.value.step() / 2;
|
|
725
745
|
return {
|
|
726
|
-
x1:
|
|
727
|
-
x2:
|
|
746
|
+
x1: i,
|
|
747
|
+
x2: i,
|
|
728
748
|
y1: -t.value.height
|
|
729
749
|
};
|
|
730
750
|
}
|
|
731
|
-
function
|
|
751
|
+
function l() {
|
|
732
752
|
return {
|
|
733
753
|
x: e.value.step() / 2,
|
|
734
754
|
y: n.value.tickPadding,
|
|
@@ -737,16 +757,16 @@ const Zt = {
|
|
|
737
757
|
};
|
|
738
758
|
}
|
|
739
759
|
return {
|
|
740
|
-
getGridLinesAttributes:
|
|
760
|
+
getGridLinesAttributes: s,
|
|
741
761
|
getTickGhostAttributes: o,
|
|
742
762
|
getTickGroupAttributes: a,
|
|
743
|
-
getTickLabelAttributes:
|
|
763
|
+
getTickLabelAttributes: l
|
|
744
764
|
};
|
|
745
|
-
},
|
|
746
|
-
const r =
|
|
747
|
-
function a(
|
|
765
|
+
}, sn = function(e, t, n) {
|
|
766
|
+
const r = v(() => e.value.step() * e.value.paddingInner() / 2);
|
|
767
|
+
function a(i) {
|
|
748
768
|
return {
|
|
749
|
-
transform: `translate(0, ${e.value(
|
|
769
|
+
transform: `translate(0, ${e.value(i) - r.value})`
|
|
750
770
|
};
|
|
751
771
|
}
|
|
752
772
|
function o() {
|
|
@@ -756,15 +776,15 @@ const Zt = {
|
|
|
756
776
|
height: e.value.step()
|
|
757
777
|
};
|
|
758
778
|
}
|
|
759
|
-
function
|
|
760
|
-
const
|
|
779
|
+
function s() {
|
|
780
|
+
const i = e.value.step() / 2;
|
|
761
781
|
return {
|
|
762
|
-
y1:
|
|
763
|
-
y2:
|
|
782
|
+
y1: i,
|
|
783
|
+
y2: i,
|
|
764
784
|
x1: t.value.width
|
|
765
785
|
};
|
|
766
786
|
}
|
|
767
|
-
function
|
|
787
|
+
function l() {
|
|
768
788
|
return {
|
|
769
789
|
x: -n.value.tickPadding,
|
|
770
790
|
y: e.value.step() / 2,
|
|
@@ -773,15 +793,15 @@ const Zt = {
|
|
|
773
793
|
};
|
|
774
794
|
}
|
|
775
795
|
return {
|
|
776
|
-
getGridLinesAttributes:
|
|
796
|
+
getGridLinesAttributes: s,
|
|
777
797
|
getTickGhostAttributes: o,
|
|
778
798
|
getTickGroupAttributes: a,
|
|
779
|
-
getTickLabelAttributes:
|
|
799
|
+
getTickLabelAttributes: l
|
|
780
800
|
};
|
|
781
|
-
},
|
|
782
|
-
function r(
|
|
801
|
+
}, ln = function(e, t, n) {
|
|
802
|
+
function r(l) {
|
|
783
803
|
return {
|
|
784
|
-
transform: `translate(${e.value(
|
|
804
|
+
transform: `translate(${e.value(l)}, 0)`
|
|
785
805
|
};
|
|
786
806
|
}
|
|
787
807
|
function a() {
|
|
@@ -792,7 +812,7 @@ const Zt = {
|
|
|
792
812
|
y1: -t.value.height
|
|
793
813
|
};
|
|
794
814
|
}
|
|
795
|
-
function
|
|
815
|
+
function s() {
|
|
796
816
|
return {
|
|
797
817
|
y: n.value.tickPadding,
|
|
798
818
|
dy: "0.8em",
|
|
@@ -803,12 +823,12 @@ const Zt = {
|
|
|
803
823
|
getGridLinesAttributes: o,
|
|
804
824
|
getTickGhostAttributes: a,
|
|
805
825
|
getTickGroupAttributes: r,
|
|
806
|
-
getTickLabelAttributes:
|
|
826
|
+
getTickLabelAttributes: s
|
|
807
827
|
};
|
|
808
|
-
},
|
|
809
|
-
function r(
|
|
828
|
+
}, un = function(e, t, n) {
|
|
829
|
+
function r(l) {
|
|
810
830
|
return {
|
|
811
|
-
transform: `translate(0, ${e.value(
|
|
831
|
+
transform: `translate(0, ${e.value(l)})`
|
|
812
832
|
};
|
|
813
833
|
}
|
|
814
834
|
function a() {
|
|
@@ -819,7 +839,7 @@ const Zt = {
|
|
|
819
839
|
x1: t.value.width
|
|
820
840
|
};
|
|
821
841
|
}
|
|
822
|
-
function
|
|
842
|
+
function s() {
|
|
823
843
|
return {
|
|
824
844
|
x: -n.value.tickPadding,
|
|
825
845
|
dy: "0.4em",
|
|
@@ -830,21 +850,21 @@ const Zt = {
|
|
|
830
850
|
getGridLinesAttributes: o,
|
|
831
851
|
getTickGhostAttributes: a,
|
|
832
852
|
getTickGroupAttributes: r,
|
|
833
|
-
getTickLabelAttributes:
|
|
853
|
+
getTickLabelAttributes: s
|
|
834
854
|
};
|
|
835
|
-
},
|
|
836
|
-
"x-band-scale-axis":
|
|
837
|
-
"y-band-scale-axis":
|
|
838
|
-
"x-linear-scale-axis":
|
|
839
|
-
"y-linear-scale-axis":
|
|
840
|
-
},
|
|
855
|
+
}, cn = {
|
|
856
|
+
"x-band-scale-axis": on,
|
|
857
|
+
"y-band-scale-axis": sn,
|
|
858
|
+
"x-linear-scale-axis": ln,
|
|
859
|
+
"y-linear-scale-axis": un
|
|
860
|
+
}, dn = {
|
|
841
861
|
bandScale: "band-scale-axis",
|
|
842
862
|
linearScale: "linear-scale-axis"
|
|
843
|
-
},
|
|
863
|
+
}, fn = ["bottom", "left"], It = {
|
|
844
864
|
x: "bottom",
|
|
845
865
|
y: "left"
|
|
846
|
-
},
|
|
847
|
-
components: { VuePortal:
|
|
866
|
+
}, pn = L({
|
|
867
|
+
components: { VuePortal: yt, VuePortalTarget: bt },
|
|
848
868
|
props: {
|
|
849
869
|
scale: {
|
|
850
870
|
type: Function,
|
|
@@ -853,12 +873,12 @@ const Zt = {
|
|
|
853
873
|
type: {
|
|
854
874
|
type: String,
|
|
855
875
|
default: void 0,
|
|
856
|
-
validator: (e) => e in
|
|
876
|
+
validator: (e) => e in It
|
|
857
877
|
},
|
|
858
878
|
position: {
|
|
859
879
|
type: String,
|
|
860
880
|
default: void 0,
|
|
861
|
-
validator: (e) =>
|
|
881
|
+
validator: (e) => fn.includes(e)
|
|
862
882
|
},
|
|
863
883
|
containerSize: {
|
|
864
884
|
type: Object,
|
|
@@ -870,114 +890,106 @@ const Zt = {
|
|
|
870
890
|
},
|
|
871
891
|
orientation: {
|
|
872
892
|
type: String,
|
|
873
|
-
default:
|
|
893
|
+
default: T.VERTICAL
|
|
874
894
|
},
|
|
875
|
-
...
|
|
895
|
+
...ft()
|
|
876
896
|
},
|
|
877
897
|
setup(e, t) {
|
|
878
|
-
const { scale: n, containerSize: r, hoveredIndex: a, options: o, orientation:
|
|
879
|
-
() => e.type ?
|
|
880
|
-
), p =
|
|
881
|
-
() => e.type || (
|
|
882
|
-
), d =
|
|
883
|
-
() => p.value === "x" &&
|
|
898
|
+
const { scale: n, containerSize: r, hoveredIndex: a, options: o, orientation: s } = w(e), l = lt({}), i = $(null), u = $(!1), h = $(null), { chartID: c } = dt(), f = v(
|
|
899
|
+
() => e.type ? It[e.type] : e.position
|
|
900
|
+
), p = v(
|
|
901
|
+
() => e.type || (f.value === "left" ? "y" : "x")
|
|
902
|
+
), d = v(
|
|
903
|
+
() => p.value === "x" && s.value === T.VERTICAL || p.value === "y" && s.value === T.HORIZONTAL
|
|
884
904
|
), { allOptions: _ } = F(
|
|
885
905
|
o,
|
|
886
|
-
p.value === "x" ?
|
|
887
|
-
), { showTick:
|
|
906
|
+
p.value === "x" ? en : nn
|
|
907
|
+
), { showTick: y } = tn(n, i, _.value.skip), m = v(
|
|
888
908
|
() => {
|
|
889
|
-
var
|
|
890
|
-
return `translate(0, ${p.value === "x" ? (
|
|
909
|
+
var k;
|
|
910
|
+
return `translate(0, ${p.value === "x" ? (k = r.value) == null ? void 0 : k.height : 0})`;
|
|
891
911
|
}
|
|
892
|
-
), g =
|
|
912
|
+
), g = v(() => {
|
|
893
913
|
if (n.value.step)
|
|
894
914
|
return n.value.domain();
|
|
895
|
-
const { tickCount:
|
|
896
|
-
return
|
|
897
|
-
}),
|
|
898
|
-
const { tickFormat:
|
|
899
|
-
|
|
900
|
-
switch (typeof $) {
|
|
901
|
-
case "string":
|
|
902
|
-
return w = ue($), w;
|
|
903
|
-
case "function":
|
|
904
|
-
return $;
|
|
905
|
-
default:
|
|
906
|
-
return null;
|
|
907
|
-
}
|
|
915
|
+
const { tickCount: k } = _.value, [I, H] = n.value.domain();
|
|
916
|
+
return de(I, H, k);
|
|
917
|
+
}), b = v(() => {
|
|
918
|
+
const { tickFormat: k } = _.value;
|
|
919
|
+
return Zt(k);
|
|
908
920
|
});
|
|
909
|
-
function x(
|
|
910
|
-
const { showTicks:
|
|
911
|
-
return
|
|
921
|
+
function x(k) {
|
|
922
|
+
const { showTicks: I } = _.value;
|
|
923
|
+
return I === !1 ? "" : b.value(k);
|
|
912
924
|
}
|
|
913
|
-
function
|
|
914
|
-
d.value && t.emit("tick-mouseover",
|
|
925
|
+
function O(k) {
|
|
926
|
+
d.value && t.emit("tick-mouseover", k);
|
|
915
927
|
}
|
|
916
|
-
function
|
|
917
|
-
return _.value.withHover && d.value && a.value ===
|
|
928
|
+
function E(k) {
|
|
929
|
+
return _.value.withHover && d.value && a.value === k;
|
|
918
930
|
}
|
|
919
|
-
function B(
|
|
920
|
-
return `${
|
|
931
|
+
function B(k) {
|
|
932
|
+
return `${c}-${p.value}-tick--${k}`;
|
|
921
933
|
}
|
|
922
|
-
function
|
|
923
|
-
|
|
924
|
-
const
|
|
925
|
-
Object.entries(
|
|
934
|
+
function C() {
|
|
935
|
+
u.value = !0;
|
|
936
|
+
const k = n.value.step ? "bandScale" : "linearScale", I = cn[`${p.value}-${dn[k]}`];
|
|
937
|
+
Object.entries(I(n, r, _) || []).forEach(
|
|
926
938
|
([H, j]) => {
|
|
927
|
-
|
|
939
|
+
l[H] = j;
|
|
928
940
|
}
|
|
929
|
-
),
|
|
941
|
+
), u.value = !1;
|
|
930
942
|
}
|
|
931
|
-
return
|
|
932
|
-
|
|
933
|
-
}),
|
|
943
|
+
return oe(async () => {
|
|
944
|
+
C(), N(n, C, { flush: "sync" });
|
|
945
|
+
}), V(() => pt(h.value)), {
|
|
934
946
|
allOptions: _,
|
|
935
947
|
axisTransform: m,
|
|
936
|
-
chartID:
|
|
937
|
-
computedPosition:
|
|
948
|
+
chartID: c,
|
|
949
|
+
computedPosition: f,
|
|
938
950
|
computedType: p,
|
|
939
951
|
formatTick: x,
|
|
940
952
|
getTickId: B,
|
|
941
|
-
isHovering:
|
|
942
|
-
isLoading:
|
|
943
|
-
mixins:
|
|
944
|
-
onTickMouseover:
|
|
953
|
+
isHovering: E,
|
|
954
|
+
isLoading: u,
|
|
955
|
+
mixins: l,
|
|
956
|
+
onTickMouseover: O,
|
|
945
957
|
root: h,
|
|
946
958
|
shouldHover: d,
|
|
947
|
-
showTick:
|
|
948
|
-
tickRefs:
|
|
959
|
+
showTick: y,
|
|
960
|
+
tickRefs: i,
|
|
949
961
|
ticks: g
|
|
950
962
|
};
|
|
951
963
|
}
|
|
952
964
|
});
|
|
953
|
-
function
|
|
954
|
-
var
|
|
955
|
-
t && (
|
|
956
|
-
var
|
|
957
|
-
if (
|
|
958
|
-
|
|
959
|
-
},
|
|
965
|
+
function S(e, t, n, r, a, o, s, l) {
|
|
966
|
+
var i = typeof e == "function" ? e.options : e;
|
|
967
|
+
t && (i.render = t, i.staticRenderFns = n, i._compiled = !0), r && (i.functional = !0), o && (i._scopeId = "data-v-" + o);
|
|
968
|
+
var u;
|
|
969
|
+
if (s ? (u = function(f) {
|
|
970
|
+
f = f || this.$vnode && this.$vnode.ssrContext || this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !f && typeof __VUE_SSR_CONTEXT__ < "u" && (f = __VUE_SSR_CONTEXT__), a && a.call(this, f), f && f._registeredComponents && f._registeredComponents.add(s);
|
|
971
|
+
}, i._ssrRegister = u) : a && (u = l ? function() {
|
|
960
972
|
a.call(
|
|
961
973
|
this,
|
|
962
|
-
(
|
|
974
|
+
(i.functional ? this.parent : this).$root.$options.shadowRoot
|
|
963
975
|
);
|
|
964
|
-
} : a),
|
|
965
|
-
if (
|
|
966
|
-
|
|
967
|
-
var h =
|
|
968
|
-
|
|
969
|
-
return
|
|
976
|
+
} : a), u)
|
|
977
|
+
if (i.functional) {
|
|
978
|
+
i._injectStyles = u;
|
|
979
|
+
var h = i.render;
|
|
980
|
+
i.render = function(p, d) {
|
|
981
|
+
return u.call(d), h(p, d);
|
|
970
982
|
};
|
|
971
983
|
} else {
|
|
972
|
-
var
|
|
973
|
-
|
|
984
|
+
var c = i.beforeCreate;
|
|
985
|
+
i.beforeCreate = c ? [].concat(c, u) : [u];
|
|
974
986
|
}
|
|
975
987
|
return {
|
|
976
988
|
exports: e,
|
|
977
|
-
options:
|
|
989
|
+
options: i
|
|
978
990
|
};
|
|
979
991
|
}
|
|
980
|
-
var
|
|
992
|
+
var vn = function() {
|
|
981
993
|
var t = this, n = t._self._c;
|
|
982
994
|
return t._self._setupProxy, t.scale && !t.isLoading ? n("g", { ref: "root", staticClass: "axis", attrs: { transform: t.axisTransform, "data-j-axis": "" } }, [t.computedType === "x" ? n("defs", [n("linearGradient", { attrs: { id: "lume-tick-gradient" } }, [n("stop", { attrs: { offset: "0%", "stop-color": "rgba(255,255,255,0)" } }), n("stop", { attrs: { offset: "10%", "stop-color": "var(--lume-chart-background-color)" } }), n("stop", { attrs: { offset: "90%", "stop-color": "var(--lume-chart-background-color)" } }), n("stop", { attrs: { offset: "100%", "stop-color": "rgba(255,255,255,0)" } })], 1)], 1) : t._e(), t._l(t.ticks, function(r, a) {
|
|
983
995
|
return n("vue-portal", { key: r, attrs: { slim: "", disabled: !t.isHovering(a), to: `${t.chartID}-${t.computedType}-hovered-portal` } }, [n("g", t._b({ staticClass: "axis__tick", class: {
|
|
@@ -987,37 +999,37 @@ var fn = function() {
|
|
|
987
999
|
return t.onTickMouseover(a);
|
|
988
1000
|
} } }, [n("rect", t._b({ staticClass: "axis__ghost", attrs: { fill: "url(#lume-tick-gradient)" } }, "rect", t.mixins.getTickGhostAttributes(), !1)), n("text", t._b({ ref: "tickRefs", refInFor: !0, staticClass: "axis__label" }, "text", t.mixins.getTickLabelAttributes(), !1), [t._v(" " + t._s(t.formatTick(r)) + " ")])]), t.allOptions.gridLines ? n("line", t._b({ staticClass: "axis__grid-line" }, "line", t.mixins.getGridLinesAttributes(), !1)) : t._e()])]);
|
|
989
1001
|
}), n("vue-portal-target", { attrs: { name: `${t.chartID}-${t.computedType}-hovered-portal`, slim: "" } })], 2) : t._e();
|
|
990
|
-
},
|
|
991
|
-
dn,
|
|
992
|
-
fn,
|
|
1002
|
+
}, hn = [], _n = /* @__PURE__ */ S(
|
|
993
1003
|
pn,
|
|
1004
|
+
vn,
|
|
1005
|
+
hn,
|
|
994
1006
|
!1,
|
|
995
1007
|
null,
|
|
996
|
-
"
|
|
1008
|
+
"43f07b68",
|
|
997
1009
|
null,
|
|
998
1010
|
null
|
|
999
1011
|
);
|
|
1000
|
-
const
|
|
1001
|
-
function
|
|
1002
|
-
const e =
|
|
1012
|
+
const mn = _n.exports;
|
|
1013
|
+
function gn() {
|
|
1014
|
+
const e = $(), t = lt({
|
|
1003
1015
|
dimensions: {}
|
|
1004
1016
|
}), n = new ResizeObserver((r) => {
|
|
1005
1017
|
r.forEach((a) => {
|
|
1006
1018
|
t.dimensions = a.contentRect;
|
|
1007
1019
|
});
|
|
1008
1020
|
});
|
|
1009
|
-
return
|
|
1021
|
+
return V(() => {
|
|
1010
1022
|
n.observe(e.value);
|
|
1011
1023
|
}), gt(() => {
|
|
1012
1024
|
n.unobserve(e.value);
|
|
1013
1025
|
}), { resizeState: t, resizeRef: e };
|
|
1014
1026
|
}
|
|
1015
|
-
const
|
|
1027
|
+
const yn = {
|
|
1016
1028
|
left: 0,
|
|
1017
1029
|
right: 0,
|
|
1018
1030
|
top: 0,
|
|
1019
1031
|
bottom: 0
|
|
1020
|
-
},
|
|
1032
|
+
}, bn = L({
|
|
1021
1033
|
props: {
|
|
1022
1034
|
margins: {
|
|
1023
1035
|
type: Object,
|
|
@@ -1037,29 +1049,29 @@ const mn = {
|
|
|
1037
1049
|
}
|
|
1038
1050
|
},
|
|
1039
1051
|
setup(e, t) {
|
|
1040
|
-
const { margins: n, containerSize: r } =
|
|
1041
|
-
...
|
|
1052
|
+
const { margins: n, containerSize: r } = w(e), a = $(null), { resizeRef: o, resizeState: s } = gn(), l = v(() => ({
|
|
1053
|
+
...yn,
|
|
1042
1054
|
...n.value
|
|
1043
|
-
})),
|
|
1044
|
-
() => r.value.height +
|
|
1055
|
+
})), i = v(
|
|
1056
|
+
() => r.value.height + l.value.top + l.value.bottom
|
|
1045
1057
|
);
|
|
1046
|
-
return
|
|
1058
|
+
return Mt(() => {
|
|
1047
1059
|
if (!a.value)
|
|
1048
1060
|
return;
|
|
1049
|
-
const { width:
|
|
1050
|
-
if (!
|
|
1061
|
+
const { width: u } = s.dimensions, { height: h } = a.value.getBoundingClientRect();
|
|
1062
|
+
if (!u || !h)
|
|
1051
1063
|
return;
|
|
1052
|
-
const
|
|
1053
|
-
width:
|
|
1054
|
-
height:
|
|
1055
|
-
outerWidth:
|
|
1064
|
+
const c = u - l.value.left - l.value.right, f = h - l.value.top - l.value.bottom, p = {
|
|
1065
|
+
width: c > 0 ? c : 0,
|
|
1066
|
+
height: f > 0 ? f : 0,
|
|
1067
|
+
outerWidth: u,
|
|
1056
1068
|
outerHeight: h
|
|
1057
1069
|
};
|
|
1058
1070
|
t.emit("resize", p);
|
|
1059
|
-
}), { computedMargins:
|
|
1071
|
+
}), { computedMargins: l, resizeRef: o, root: a, svgHeight: i };
|
|
1060
1072
|
}
|
|
1061
1073
|
});
|
|
1062
|
-
var
|
|
1074
|
+
var xn = function() {
|
|
1063
1075
|
var t = this, n = t._self._c;
|
|
1064
1076
|
return t._self._setupProxy, n("div", { ref: "resizeRef", staticClass: "lume-chart-container", class: {
|
|
1065
1077
|
"lume-chart-container--minimum": !t.noMinSize
|
|
@@ -1068,17 +1080,17 @@ var yn = function() {
|
|
|
1068
1080
|
}, attrs: { height: t.svgHeight, "data-j-chart-container__root": "" }, on: { mouseleave: function(r) {
|
|
1069
1081
|
return t.$emit("mouseleave", r);
|
|
1070
1082
|
} } }, [n("g", { staticClass: "lume-chart-container__group", attrs: { transform: `translate(${t.computedMargins.left}, ${t.computedMargins.top})`, "data-j-chart-container__group": "" } }, [t._t("default")], 2)]), t._t("footer"), t._t("extra")], 2);
|
|
1071
|
-
},
|
|
1072
|
-
gn,
|
|
1073
|
-
yn,
|
|
1083
|
+
}, Tn = [], An = /* @__PURE__ */ S(
|
|
1074
1084
|
bn,
|
|
1085
|
+
xn,
|
|
1086
|
+
Tn,
|
|
1075
1087
|
!1,
|
|
1076
1088
|
null,
|
|
1077
1089
|
"7aa5be81",
|
|
1078
1090
|
null,
|
|
1079
1091
|
null
|
|
1080
1092
|
);
|
|
1081
|
-
const
|
|
1093
|
+
const On = An.exports, $n = L({
|
|
1082
1094
|
props: {
|
|
1083
1095
|
data: {
|
|
1084
1096
|
type: Array,
|
|
@@ -1087,24 +1099,24 @@ const An = xn.exports, On = S({
|
|
|
1087
1099
|
}
|
|
1088
1100
|
}
|
|
1089
1101
|
});
|
|
1090
|
-
var
|
|
1102
|
+
var kn = function() {
|
|
1091
1103
|
var t = this, n = t._self._c;
|
|
1092
1104
|
return t._self._setupProxy, n("div", { staticClass: "lume-chart-legend", attrs: { "data-j-chart-legend": "" } }, t._l(t.data, function(r, a) {
|
|
1093
1105
|
return n("div", { key: `legend-item-${a}`, staticClass: "lume-chart-legend__item lume-typography--body", attrs: { tabindex: "0", "data-j-chart-legend__symbol-wrapper": "" }, on: { click: function(o) {
|
|
1094
1106
|
return t.$emit("click", a);
|
|
1095
1107
|
} } }, [n("span", { staticClass: "lume-chart-legend__symbol", class: `lume-background-color--${r.color}`, attrs: { "data-j-chart-legend__symbol": "" } }), t._v(" " + t._s(r.label) + " ")]);
|
|
1096
1108
|
}), 0);
|
|
1097
|
-
},
|
|
1098
|
-
On,
|
|
1099
|
-
Tn,
|
|
1109
|
+
}, Ln = [], Sn = /* @__PURE__ */ S(
|
|
1100
1110
|
$n,
|
|
1111
|
+
kn,
|
|
1112
|
+
Ln,
|
|
1101
1113
|
!1,
|
|
1102
1114
|
null,
|
|
1103
1115
|
"22aa3668",
|
|
1104
1116
|
null,
|
|
1105
1117
|
null
|
|
1106
1118
|
);
|
|
1107
|
-
const
|
|
1119
|
+
const wn = Sn.exports, Cn = L({
|
|
1108
1120
|
props: {
|
|
1109
1121
|
targetElement: {
|
|
1110
1122
|
type: Element,
|
|
@@ -1117,7 +1129,7 @@ const Sn = kn.exports, Ln = S({
|
|
|
1117
1129
|
position: {
|
|
1118
1130
|
type: String,
|
|
1119
1131
|
default: "auto",
|
|
1120
|
-
validator: (e) =>
|
|
1132
|
+
validator: (e) => At.includes(e)
|
|
1121
1133
|
},
|
|
1122
1134
|
fixedPositioning: {
|
|
1123
1135
|
type: Boolean,
|
|
@@ -1131,17 +1143,21 @@ const Sn = kn.exports, Ln = S({
|
|
|
1131
1143
|
type: [String, Number],
|
|
1132
1144
|
default: null
|
|
1133
1145
|
},
|
|
1134
|
-
|
|
1146
|
+
summary: {
|
|
1147
|
+
type: String,
|
|
1148
|
+
default: null
|
|
1149
|
+
},
|
|
1150
|
+
...ft()
|
|
1135
1151
|
},
|
|
1136
1152
|
setup(e) {
|
|
1137
|
-
const t =
|
|
1153
|
+
const t = $(null), { items: n, options: r } = w(e), a = $(null), { allOptions: o } = F(r), s = v(
|
|
1138
1154
|
() => {
|
|
1139
|
-
var
|
|
1140
|
-
return (
|
|
1155
|
+
var _;
|
|
1156
|
+
return (_ = o.value.fixedPositioning) != null ? _ : e.fixedPositioning;
|
|
1141
1157
|
}
|
|
1142
|
-
),
|
|
1143
|
-
() =>
|
|
1144
|
-
),
|
|
1158
|
+
), l = v(
|
|
1159
|
+
() => s.value ? "fixed" : "absolute"
|
|
1160
|
+
), i = v(() => [
|
|
1145
1161
|
{
|
|
1146
1162
|
name: "computeStyles",
|
|
1147
1163
|
options: {
|
|
@@ -1150,65 +1166,84 @@ const Sn = kn.exports, Ln = S({
|
|
|
1150
1166
|
},
|
|
1151
1167
|
{
|
|
1152
1168
|
name: "offset",
|
|
1153
|
-
options: { offset: [0,
|
|
1169
|
+
options: { offset: [0, o.value.offset || 8] }
|
|
1154
1170
|
},
|
|
1155
1171
|
...e.modifiers || []
|
|
1156
|
-
]),
|
|
1157
|
-
() =>
|
|
1172
|
+
]), u = v(
|
|
1173
|
+
() => o.value.showTitle !== !1 && e.title != null
|
|
1174
|
+
), h = v(() => Zt(o.value.valueFormat)), c = v(
|
|
1175
|
+
() => {
|
|
1176
|
+
var _, y;
|
|
1177
|
+
return ((_ = n.value) == null ? void 0 : _.find((m) => m.isSummary)) || {
|
|
1178
|
+
label: (y = o.value.summary) != null ? y : e.summary
|
|
1179
|
+
};
|
|
1180
|
+
}
|
|
1158
1181
|
);
|
|
1159
|
-
function
|
|
1160
|
-
e.targetElement && t.value && (
|
|
1182
|
+
function f() {
|
|
1183
|
+
e.targetElement && t.value && (a.value = ve(e.targetElement, t.value, {
|
|
1161
1184
|
placement: e.position,
|
|
1162
|
-
strategy:
|
|
1163
|
-
modifiers:
|
|
1185
|
+
strategy: l.value,
|
|
1186
|
+
modifiers: i.value
|
|
1164
1187
|
}));
|
|
1165
1188
|
}
|
|
1166
|
-
function
|
|
1167
|
-
|
|
1189
|
+
function p() {
|
|
1190
|
+
a.value && a.value.destroy();
|
|
1168
1191
|
}
|
|
1169
|
-
function
|
|
1170
|
-
!
|
|
1171
|
-
|
|
1172
|
-
}() :
|
|
1192
|
+
function d() {
|
|
1193
|
+
!a.value || (t.value.classList.add("lume-tooltip--animated"), e.targetElement ? function() {
|
|
1194
|
+
a.value.state.elements.reference = e.targetElement, a.value.update();
|
|
1195
|
+
}() : p());
|
|
1173
1196
|
}
|
|
1174
|
-
return
|
|
1197
|
+
return N(() => e.targetElement, d), V(f), gt(p), {
|
|
1198
|
+
allModifiers: i,
|
|
1199
|
+
allOptions: o,
|
|
1200
|
+
summaryItem: c,
|
|
1201
|
+
formatValue: h,
|
|
1202
|
+
popper: a,
|
|
1203
|
+
root: t,
|
|
1204
|
+
showTitle: u,
|
|
1205
|
+
strategy: l
|
|
1206
|
+
};
|
|
1175
1207
|
}
|
|
1176
1208
|
});
|
|
1177
|
-
var
|
|
1209
|
+
var In = function() {
|
|
1178
1210
|
var t = this, n = t._self._c;
|
|
1179
1211
|
return t._self._setupProxy, n("div", { ref: "root", staticClass: "lume-tooltip lume-typography--caption", attrs: { "data-j-tooltip": "" } }, [t._t("default", function() {
|
|
1180
|
-
return [t.showTitle ? n("div", { staticClass: "lume-tooltip__title", attrs: { "data-j-tooltip__title": "" } }, [t._v(" " + t._s(t.title) + " ")]) : t._e(), n("ul", { staticClass: "lume-tooltip__items" }, t._l(t.items, function(r) {
|
|
1181
|
-
return n("li", { key: r.label, staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__item": "" } }, [n("span", { staticClass: "lume-tooltip__symbol", class: [`lume-background-color--${r.color}`], attrs: { "data-j-tooltip__item__symbol": "" } }), n("span", { attrs: { "data-j-tooltip__item__label": "" } }, [t._v(" " + t._s(r.label) + " ")]), n("strong", { staticClass: "lume-tooltip__value", attrs: { "data-j-tooltip__item__value": "" } }, [t._v(" " + t._s(r.value) + " ")])]);
|
|
1182
|
-
}),
|
|
1212
|
+
return [t.showTitle ? n("div", { staticClass: "lume-tooltip__title", attrs: { "data-j-tooltip__title": "" } }, [t._v(" " + t._s(t.title) + " ")]) : t._e(), n("ul", { staticClass: "lume-tooltip__items" }, [t.summaryItem.label ? [n("li", { staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__summary-item": "" } }, [n("span", [t._v(" " + t._s(t.summaryItem.label) + " ")]), t.summaryItem.value ? n("strong", { staticClass: "lume-tooltip__value" }, [t._v(" " + t._s(t.formatValue(t.summaryItem.value)) + " ")]) : t._e()]), t._m(0)] : t._e(), t._l(t.items, function(r) {
|
|
1213
|
+
return n("li", { key: r.label, staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__item": "" } }, [n("span", { staticClass: "lume-tooltip__symbol", class: [`lume-background-color--${r.color}`], attrs: { "data-j-tooltip__item__symbol": "" } }), n("span", { attrs: { "data-j-tooltip__item__label": "" } }, [t._v(" " + t._s(r.label) + " ")]), n("strong", { staticClass: "lume-tooltip__value", attrs: { "data-j-tooltip__item__value": "" } }, [t._v(" " + t._s(t.formatValue(r.value)) + " ")])]);
|
|
1214
|
+
})], 2)];
|
|
1183
1215
|
})], 2);
|
|
1184
|
-
},
|
|
1185
|
-
|
|
1186
|
-
|
|
1216
|
+
}, Nn = [function() {
|
|
1217
|
+
var e = this, t = e._self._c;
|
|
1218
|
+
return e._self._setupProxy, t("li", { staticClass: "lume-tooltip__break" }, [t("hr")]);
|
|
1219
|
+
}], Dn = /* @__PURE__ */ S(
|
|
1187
1220
|
Cn,
|
|
1221
|
+
In,
|
|
1222
|
+
Nn,
|
|
1188
1223
|
!1,
|
|
1189
1224
|
null,
|
|
1190
|
-
"
|
|
1225
|
+
"e6deede1",
|
|
1191
1226
|
null,
|
|
1192
1227
|
null
|
|
1193
1228
|
);
|
|
1194
|
-
const
|
|
1195
|
-
function
|
|
1196
|
-
const a =
|
|
1229
|
+
const Rn = Dn.exports;
|
|
1230
|
+
function Pn(e, t, n, r) {
|
|
1231
|
+
const a = v(() => n.value > 0 && n.value < 1), o = v(
|
|
1197
1232
|
() => r.value > 0 && r.value < 1
|
|
1198
|
-
),
|
|
1233
|
+
), s = v(
|
|
1199
1234
|
() => a.value ? e.value - 0.5 : e.value
|
|
1200
|
-
),
|
|
1235
|
+
), l = v(
|
|
1201
1236
|
() => o.value ? t.value - 0.5 : t.value
|
|
1202
1237
|
);
|
|
1203
|
-
return { computedX:
|
|
1238
|
+
return { computedX: s, computedY: l, shouldHaveMinWidth: a, shouldHaveMinHeight: o };
|
|
1204
1239
|
}
|
|
1205
|
-
function
|
|
1206
|
-
const a =
|
|
1207
|
-
return
|
|
1240
|
+
function En(e, t, n, r) {
|
|
1241
|
+
const a = $(0), o = $(0), s = v(() => `${e.value + n.value / 2}px ${t.value + r.value / 2}px`);
|
|
1242
|
+
return V(() => {
|
|
1208
1243
|
a.value = n.value, o.value = r.value;
|
|
1209
|
-
}),
|
|
1244
|
+
}), N(n, (l) => a.value = l), N(r, (l) => o.value = l), { computedWidth: a, computedHeight: o, transformOrigin: s };
|
|
1210
1245
|
}
|
|
1211
|
-
const
|
|
1246
|
+
const Bn = L({
|
|
1212
1247
|
props: {
|
|
1213
1248
|
x: {
|
|
1214
1249
|
type: Number,
|
|
@@ -1244,25 +1279,25 @@ const En = S({
|
|
|
1244
1279
|
}
|
|
1245
1280
|
},
|
|
1246
1281
|
setup(e) {
|
|
1247
|
-
const { x: t, y: n, width: r, height: a, transition: o, classList:
|
|
1248
|
-
() => typeof
|
|
1249
|
-
),
|
|
1282
|
+
const { x: t, y: n, width: r, height: a, transition: o, classList: s } = w(e), l = $(null), i = v(
|
|
1283
|
+
() => typeof s.value == "string" ? [s.value] : s.value
|
|
1284
|
+
), u = v(() => o.value === "width"), h = v(
|
|
1250
1285
|
() => o.value === "height"
|
|
1251
|
-
),
|
|
1252
|
-
return
|
|
1253
|
-
computedClasses:
|
|
1254
|
-
computedWidth:
|
|
1286
|
+
), c = En(t, n, r, a), { computedX: f, computedY: p, shouldHaveMinWidth: d, shouldHaveMinHeight: _ } = Pn(t, n, r, a), y = v(() => d.value ? 1 : (u.value ? c.computedWidth : r).value), m = v(() => _.value ? 1 : (h.value ? c.computedHeight : a).value), g = u.value || h.value ? c.transformOrigin : null;
|
|
1287
|
+
return V(() => pt(l.value)), {
|
|
1288
|
+
computedClasses: i,
|
|
1289
|
+
computedWidth: y,
|
|
1255
1290
|
computedHeight: m,
|
|
1256
|
-
computedX:
|
|
1291
|
+
computedX: f,
|
|
1257
1292
|
computedY: p,
|
|
1258
|
-
root:
|
|
1259
|
-
shouldTransitionWidth:
|
|
1293
|
+
root: l,
|
|
1294
|
+
shouldTransitionWidth: u,
|
|
1260
1295
|
shouldTransitionHeight: h,
|
|
1261
1296
|
transformOrigin: g
|
|
1262
1297
|
};
|
|
1263
1298
|
}
|
|
1264
1299
|
});
|
|
1265
|
-
var
|
|
1300
|
+
var Mn = function() {
|
|
1266
1301
|
var t = this, n = t._self._c;
|
|
1267
1302
|
return t._self._setupProxy, n("rect", { ref: "root", staticClass: "lume-bar", class: [
|
|
1268
1303
|
{
|
|
@@ -1273,18 +1308,22 @@ var Pn = function() {
|
|
|
1273
1308
|
},
|
|
1274
1309
|
...t.computedClasses
|
|
1275
1310
|
], style: { transformOrigin: t.transformOrigin }, attrs: { x: t.computedX, y: t.computedY, width: t.computedWidth, height: t.computedHeight, "data-j-bar": "" } });
|
|
1276
|
-
},
|
|
1277
|
-
En,
|
|
1278
|
-
Pn,
|
|
1311
|
+
}, Hn = [], jn = /* @__PURE__ */ S(
|
|
1279
1312
|
Bn,
|
|
1313
|
+
Mn,
|
|
1314
|
+
Hn,
|
|
1280
1315
|
!1,
|
|
1281
1316
|
null,
|
|
1282
1317
|
"43471964",
|
|
1283
1318
|
null,
|
|
1284
1319
|
null
|
|
1285
1320
|
);
|
|
1286
|
-
const
|
|
1321
|
+
const $t = jn.exports, Fn = 1, Vn = 2, Gn = L({
|
|
1287
1322
|
props: {
|
|
1323
|
+
pathDefinition: {
|
|
1324
|
+
type: String,
|
|
1325
|
+
required: !0
|
|
1326
|
+
},
|
|
1288
1327
|
color: {
|
|
1289
1328
|
type: String,
|
|
1290
1329
|
default: M.Skyblue
|
|
@@ -1295,11 +1334,7 @@ const Tt = Mn.exports, Hn = 1, jn = 2, Fn = S({
|
|
|
1295
1334
|
},
|
|
1296
1335
|
width: {
|
|
1297
1336
|
type: Number,
|
|
1298
|
-
default:
|
|
1299
|
-
},
|
|
1300
|
-
values: {
|
|
1301
|
-
type: Array,
|
|
1302
|
-
required: !0
|
|
1337
|
+
default: Vn
|
|
1303
1338
|
},
|
|
1304
1339
|
dashed: {
|
|
1305
1340
|
type: Boolean,
|
|
@@ -1309,39 +1344,23 @@ const Tt = Mn.exports, Hn = 1, jn = 2, Fn = S({
|
|
|
1309
1344
|
type: Function,
|
|
1310
1345
|
required: !0
|
|
1311
1346
|
},
|
|
1312
|
-
yScale: {
|
|
1313
|
-
type: Function,
|
|
1314
|
-
required: !0
|
|
1315
|
-
},
|
|
1316
1347
|
transition: {
|
|
1317
1348
|
type: Boolean,
|
|
1318
1349
|
default: !0
|
|
1319
1350
|
}
|
|
1320
1351
|
},
|
|
1321
1352
|
setup(e) {
|
|
1322
|
-
const t =
|
|
1323
|
-
() =>
|
|
1324
|
-
), r =
|
|
1325
|
-
|
|
1326
|
-
return e.xScale(
|
|
1327
|
-
e.index + (c - 1)
|
|
1328
|
-
);
|
|
1329
|
-
}
|
|
1330
|
-
function i(s, c) {
|
|
1331
|
-
return e.xScale(
|
|
1332
|
-
e.xScale.domain()[e.index + (c - 1)]
|
|
1333
|
-
) + a.value;
|
|
1334
|
-
}
|
|
1335
|
-
const u = f(() => ce().x(U(e.xScale) ? i : o).y((c) => e.yScale(c))(e.values));
|
|
1336
|
-
return G(() => ft(t.value)), {
|
|
1353
|
+
const t = $(null), n = v(
|
|
1354
|
+
() => Fn / (Be(e.xScale) - 1)
|
|
1355
|
+
), r = v(() => e.index < 2 ? 0 : e.transition && (e.index - 1) * n.value);
|
|
1356
|
+
return V(() => pt(t.value)), {
|
|
1337
1357
|
animationDelay: r,
|
|
1338
1358
|
animationDuration: n,
|
|
1339
|
-
pathDefinition: u,
|
|
1340
1359
|
root: t
|
|
1341
1360
|
};
|
|
1342
1361
|
}
|
|
1343
1362
|
});
|
|
1344
|
-
var
|
|
1363
|
+
var zn = function() {
|
|
1345
1364
|
var t = this, n = t._self._c;
|
|
1346
1365
|
return t._self._setupProxy, n("path", { ref: "root", staticClass: "lume-line", class: {
|
|
1347
1366
|
[`lume-stroke--${t.color}`]: !0,
|
|
@@ -1351,17 +1370,17 @@ var Gn = function() {
|
|
|
1351
1370
|
animationDelay: t.transition && t.animationDelay + "s",
|
|
1352
1371
|
animationDuration: t.transition && t.animationDuration + "s"
|
|
1353
1372
|
}, attrs: { d: t.pathDefinition, "stroke-width": t.width, "data-j-line": "" } });
|
|
1354
|
-
},
|
|
1355
|
-
Fn,
|
|
1373
|
+
}, Wn = [], Zn = /* @__PURE__ */ S(
|
|
1356
1374
|
Gn,
|
|
1357
|
-
|
|
1375
|
+
zn,
|
|
1376
|
+
Wn,
|
|
1358
1377
|
!1,
|
|
1359
1378
|
null,
|
|
1360
|
-
"
|
|
1379
|
+
"a9d50090",
|
|
1361
1380
|
null,
|
|
1362
1381
|
null
|
|
1363
1382
|
);
|
|
1364
|
-
const
|
|
1383
|
+
const qn = Zn.exports, Xn = 4, Un = L({
|
|
1365
1384
|
props: {
|
|
1366
1385
|
color: {
|
|
1367
1386
|
type: String,
|
|
@@ -1369,7 +1388,7 @@ const Wn = zn.exports, Zn = 4, qn = S({
|
|
|
1369
1388
|
},
|
|
1370
1389
|
radius: {
|
|
1371
1390
|
type: Number,
|
|
1372
|
-
default:
|
|
1391
|
+
default: Xn
|
|
1373
1392
|
},
|
|
1374
1393
|
value: {
|
|
1375
1394
|
type: Number,
|
|
@@ -1393,26 +1412,26 @@ const Wn = zn.exports, Zn = 4, qn = S({
|
|
|
1393
1412
|
}
|
|
1394
1413
|
},
|
|
1395
1414
|
setup(e) {
|
|
1396
|
-
const t =
|
|
1415
|
+
const t = $(null), n = v(() => Ot(e.xScale) / 2), r = v(() => e.xScale.domain()), a = v(
|
|
1397
1416
|
() => U(e.xScale) ? e.xScale(r.value[e.index]) + n.value : e.xScale(e.index)
|
|
1398
|
-
), o =
|
|
1399
|
-
return
|
|
1417
|
+
), o = v(() => e.yScale(e.value)), s = v(() => e.radius / 2);
|
|
1418
|
+
return V(() => pt(t.value)), { cx: a, cy: o, root: t, strokeWidth: s };
|
|
1400
1419
|
}
|
|
1401
1420
|
});
|
|
1402
|
-
var
|
|
1421
|
+
var Yn = function() {
|
|
1403
1422
|
var t = this, n = t._self._c;
|
|
1404
1423
|
return t._self._setupProxy, n("circle", { ref: "root", staticClass: "lume-point", class: `lume-stroke--${t.color}`, attrs: { cx: t.cx, cy: t.cy, r: t.active ? t.radius : 0, "stroke-width": t.strokeWidth, "data-j-point": "" } });
|
|
1405
|
-
},
|
|
1406
|
-
qn,
|
|
1407
|
-
Xn,
|
|
1424
|
+
}, Kn = [], Jn = /* @__PURE__ */ S(
|
|
1408
1425
|
Un,
|
|
1426
|
+
Yn,
|
|
1427
|
+
Kn,
|
|
1409
1428
|
!1,
|
|
1410
1429
|
null,
|
|
1411
1430
|
"d65961d4",
|
|
1412
1431
|
null,
|
|
1413
1432
|
null
|
|
1414
1433
|
);
|
|
1415
|
-
const
|
|
1434
|
+
const Qn = Jn.exports, kt = () => ({
|
|
1416
1435
|
data: {
|
|
1417
1436
|
type: Array,
|
|
1418
1437
|
required: !0
|
|
@@ -1437,53 +1456,53 @@ const Kn = Yn.exports, $t = () => ({
|
|
|
1437
1456
|
type: Object,
|
|
1438
1457
|
default: () => ({})
|
|
1439
1458
|
}
|
|
1440
|
-
}),
|
|
1441
|
-
components: { LumeBar:
|
|
1459
|
+
}), tr = L({
|
|
1460
|
+
components: { LumeBar: $t },
|
|
1442
1461
|
props: {
|
|
1443
|
-
|
|
1462
|
+
...kt(),
|
|
1444
1463
|
orientation: {
|
|
1445
1464
|
type: String,
|
|
1446
|
-
default:
|
|
1465
|
+
default: T.VERTICAL
|
|
1447
1466
|
}
|
|
1448
1467
|
},
|
|
1449
1468
|
setup(e, t) {
|
|
1450
|
-
const { data: n, orientation: r, xScale: a, yScale: o } =
|
|
1451
|
-
function u
|
|
1452
|
-
const h = r.value ===
|
|
1453
|
-
return r.value ===
|
|
1469
|
+
const { data: n, orientation: r, xScale: a, yScale: o } = w(e), s = v(() => st(n));
|
|
1470
|
+
function l(u) {
|
|
1471
|
+
const h = r.value === T.HORIZONTAL ? o.value : a.value, c = h.domain(), f = Ot(h), p = U(h) ? h(c[u]) : h(u) - f / 2;
|
|
1472
|
+
return r.value === T.HORIZONTAL ? {
|
|
1454
1473
|
width: Math.max(...a.value.range()),
|
|
1455
|
-
height:
|
|
1474
|
+
height: f,
|
|
1456
1475
|
transform: `translate(0, ${p})`
|
|
1457
1476
|
} : {
|
|
1458
|
-
width:
|
|
1477
|
+
width: f,
|
|
1459
1478
|
height: Math.max(...o.value.range()),
|
|
1460
1479
|
transform: `translate(${p}, 0)`
|
|
1461
1480
|
};
|
|
1462
1481
|
}
|
|
1463
|
-
function
|
|
1464
|
-
t.emit("mouseover",
|
|
1482
|
+
function i(u) {
|
|
1483
|
+
t.emit("mouseover", u);
|
|
1465
1484
|
}
|
|
1466
|
-
return { getOverlayBarAttributes:
|
|
1485
|
+
return { getOverlayBarAttributes: l, handleMouseover: i, overlayData: s };
|
|
1467
1486
|
}
|
|
1468
1487
|
});
|
|
1469
|
-
var
|
|
1488
|
+
var er = function() {
|
|
1470
1489
|
var t = this, n = t._self._c;
|
|
1471
1490
|
return t._self._setupProxy, n("g", { staticClass: "lume-overlay-group" }, t._l(t.overlayData, function(r, a) {
|
|
1472
1491
|
return n("lume-bar", t._b({ key: `overlay-${a}`, attrs: { "data-j-lume-overlay-group": a, transition: !1, "class-list": "lume-fill--transparent" }, nativeOn: { mouseover: function(o) {
|
|
1473
1492
|
return t.handleMouseover(a);
|
|
1474
1493
|
} } }, "lume-bar", t.getOverlayBarAttributes(a), !1));
|
|
1475
1494
|
}), 1);
|
|
1476
|
-
},
|
|
1477
|
-
Jn,
|
|
1478
|
-
Qn,
|
|
1495
|
+
}, nr = [], rr = /* @__PURE__ */ S(
|
|
1479
1496
|
tr,
|
|
1497
|
+
er,
|
|
1498
|
+
nr,
|
|
1480
1499
|
!1,
|
|
1481
1500
|
null,
|
|
1482
1501
|
null,
|
|
1483
1502
|
null,
|
|
1484
1503
|
null
|
|
1485
1504
|
);
|
|
1486
|
-
const
|
|
1505
|
+
const ar = rr.exports, or = () => ({
|
|
1487
1506
|
xScale: {
|
|
1488
1507
|
type: Function,
|
|
1489
1508
|
default: null
|
|
@@ -1493,56 +1512,56 @@ const nr = er.exports, rr = () => ({
|
|
|
1493
1512
|
default: null
|
|
1494
1513
|
}
|
|
1495
1514
|
});
|
|
1496
|
-
function
|
|
1497
|
-
const o =
|
|
1498
|
-
function
|
|
1499
|
-
const { width:
|
|
1500
|
-
!
|
|
1515
|
+
function sr(e, t, n, r, a) {
|
|
1516
|
+
const o = $(null), s = $(null);
|
|
1517
|
+
function l() {
|
|
1518
|
+
const { width: i, height: u } = n;
|
|
1519
|
+
!i && !u || !t.value || !e.value || (r.value === T.HORIZONTAL ? (o.value = Dt(
|
|
1501
1520
|
e.value,
|
|
1502
|
-
|
|
1521
|
+
i,
|
|
1503
1522
|
r.value,
|
|
1504
1523
|
a.value.startOnZero
|
|
1505
|
-
),
|
|
1524
|
+
), s.value = Nt(t.value, u)) : (o.value = Nt(t.value, i), s.value = Dt(
|
|
1506
1525
|
e.value,
|
|
1507
|
-
|
|
1526
|
+
u,
|
|
1508
1527
|
r.value,
|
|
1509
1528
|
a.value.startOnZero
|
|
1510
1529
|
)));
|
|
1511
1530
|
}
|
|
1512
|
-
return
|
|
1531
|
+
return Mt(l), { xScale: o, yScale: s };
|
|
1513
1532
|
}
|
|
1514
|
-
function
|
|
1533
|
+
function Nt(e, t) {
|
|
1515
1534
|
const n = [0, t];
|
|
1516
1535
|
return J().range(n).domain(e);
|
|
1517
1536
|
}
|
|
1518
|
-
function
|
|
1537
|
+
function Dt(e, t, n, r) {
|
|
1519
1538
|
const a = Ft(e).filter((h) => h != null), o = [0, t];
|
|
1520
1539
|
if (a.length === 0)
|
|
1521
1540
|
return Q().range(o).domain([0, 0]).nice();
|
|
1522
|
-
const
|
|
1523
|
-
return Q().range(o).domain(
|
|
1541
|
+
const s = Math.min(...a), l = r && s > 0 ? 0 : s, i = Math.max(...a), u = n === T.HORIZONTAL ? [l, i] : [i, l];
|
|
1542
|
+
return Q().range(o).domain(u).nice();
|
|
1524
1543
|
}
|
|
1525
|
-
function
|
|
1544
|
+
function Rt(e) {
|
|
1526
1545
|
return (e == null ? void 0 : e.range) !== void 0 || (e == null ? void 0 : e.copy) !== void 0;
|
|
1527
1546
|
}
|
|
1528
1547
|
function mt(e, t) {
|
|
1529
1548
|
return U(e) ? e.bandwidth() / 2 + e(e.domain()[t]) : e(t);
|
|
1530
1549
|
}
|
|
1531
|
-
function
|
|
1550
|
+
function it(e, t, {
|
|
1532
1551
|
padding: n,
|
|
1533
1552
|
paddingInner: r,
|
|
1534
1553
|
paddingOuter: a
|
|
1535
1554
|
} = {}) {
|
|
1536
|
-
const o = n != null ? n : t ===
|
|
1555
|
+
const o = n != null ? n : t === T.HORIZONTAL ? Ne : Ie;
|
|
1537
1556
|
return e.copy().paddingInner(r != null ? r : o).paddingOuter(a != null ? a : o / 2);
|
|
1538
1557
|
}
|
|
1539
|
-
function
|
|
1540
|
-
return Object.values(
|
|
1558
|
+
function ir(e) {
|
|
1559
|
+
return Object.values(T).includes(e);
|
|
1541
1560
|
}
|
|
1542
|
-
const
|
|
1561
|
+
const G = (e, t = !0, n = !0) => ({
|
|
1543
1562
|
...Wt(e),
|
|
1544
|
-
...n ?
|
|
1545
|
-
...
|
|
1563
|
+
...n ? or() : {},
|
|
1564
|
+
...ft(),
|
|
1546
1565
|
title: {
|
|
1547
1566
|
type: String,
|
|
1548
1567
|
default: null
|
|
@@ -1550,8 +1569,8 @@ const V = (e, t = !0, n = !0) => ({
|
|
|
1550
1569
|
...t ? {
|
|
1551
1570
|
orientation: {
|
|
1552
1571
|
type: String,
|
|
1553
|
-
default:
|
|
1554
|
-
validator:
|
|
1572
|
+
default: T.VERTICAL,
|
|
1573
|
+
validator: ir
|
|
1555
1574
|
}
|
|
1556
1575
|
} : {},
|
|
1557
1576
|
classList: {
|
|
@@ -1559,212 +1578,207 @@ const V = (e, t = !0, n = !0) => ({
|
|
|
1559
1578
|
default: () => []
|
|
1560
1579
|
}
|
|
1561
1580
|
});
|
|
1562
|
-
function
|
|
1563
|
-
return { hasNegativeValues:
|
|
1581
|
+
function lr(e) {
|
|
1582
|
+
return { hasNegativeValues: v(
|
|
1564
1583
|
() => Ft(e.value).some((n) => n < 0)
|
|
1565
1584
|
) };
|
|
1566
1585
|
}
|
|
1567
|
-
function
|
|
1568
|
-
const a =
|
|
1569
|
-
() => r.value ===
|
|
1570
|
-
), o =
|
|
1586
|
+
function ur(e, t, n, r) {
|
|
1587
|
+
const a = v(
|
|
1588
|
+
() => r.value === T.HORIZONTAL
|
|
1589
|
+
), o = v(
|
|
1571
1590
|
() => {
|
|
1572
|
-
var
|
|
1573
|
-
return e.height - (a != null && a.value ? 0 : ((
|
|
1591
|
+
var u;
|
|
1592
|
+
return e.height - (a != null && a.value ? 0 : ((u = n.value) == null ? void 0 : u.call(n, 0)) || 0);
|
|
1574
1593
|
}
|
|
1575
|
-
),
|
|
1594
|
+
), s = v(
|
|
1576
1595
|
() => {
|
|
1577
|
-
var
|
|
1578
|
-
return a != null && a.value ? ((
|
|
1596
|
+
var u;
|
|
1597
|
+
return a != null && a.value ? ((u = t.value) == null ? void 0 : u.call(t, 0)) || 0 : e.width;
|
|
1579
1598
|
}
|
|
1580
|
-
),
|
|
1599
|
+
), l = v(
|
|
1581
1600
|
() => {
|
|
1582
|
-
var
|
|
1583
|
-
return a != null && a.value ? "translate(0, 0)" : `translate(0, ${((
|
|
1601
|
+
var u;
|
|
1602
|
+
return a != null && a.value ? "translate(0, 0)" : `translate(0, ${((u = n.value) == null ? void 0 : u.call(n, 0)) || 0})`;
|
|
1584
1603
|
}
|
|
1585
1604
|
);
|
|
1586
|
-
return { negativeBarAttributes:
|
|
1587
|
-
width:
|
|
1605
|
+
return { negativeBarAttributes: v(() => ({
|
|
1606
|
+
width: s.value,
|
|
1588
1607
|
height: o.value,
|
|
1589
|
-
transform:
|
|
1608
|
+
transform: l.value
|
|
1590
1609
|
})) };
|
|
1591
1610
|
}
|
|
1592
|
-
function
|
|
1611
|
+
function cr(e, t) {
|
|
1593
1612
|
return e.reduce((n, r) => {
|
|
1594
1613
|
var o;
|
|
1595
1614
|
const a = (o = r.values[t]) == null ? void 0 : o.value;
|
|
1596
1615
|
return a > 0 && (n += a), n;
|
|
1597
1616
|
}, 0);
|
|
1598
1617
|
}
|
|
1599
|
-
const
|
|
1600
|
-
"stacked-bar":
|
|
1618
|
+
const Pt = {
|
|
1619
|
+
"stacked-bar": cr
|
|
1601
1620
|
};
|
|
1602
|
-
function
|
|
1603
|
-
const o =
|
|
1604
|
-
var
|
|
1605
|
-
let
|
|
1606
|
-
((
|
|
1607
|
-
const
|
|
1621
|
+
function dr(e, t, n, r, a) {
|
|
1622
|
+
const o = v(() => (l) => {
|
|
1623
|
+
var c;
|
|
1624
|
+
let i = a.value && Pt[a.value] ? Pt[a.value](e.value, l) : Gt(e.value, l);
|
|
1625
|
+
((c = a == null ? void 0 : a.value) == null ? void 0 : c.includes("bar")) && i < 0 && (i = 0);
|
|
1626
|
+
const u = r.value === T.HORIZONTAL ? t.value(i) : mt(t.value, l), h = r.value === T.HORIZONTAL ? mt(n.value, l) : n.value(i);
|
|
1608
1627
|
return {
|
|
1609
|
-
cx:
|
|
1628
|
+
cx: u,
|
|
1610
1629
|
cy: h
|
|
1611
1630
|
};
|
|
1612
1631
|
});
|
|
1613
|
-
function
|
|
1614
|
-
return e.value.map(({ color:
|
|
1615
|
-
var
|
|
1632
|
+
function s(l) {
|
|
1633
|
+
return e.value.map(({ color: i, label: u, values: h }) => {
|
|
1634
|
+
var c, f, p, d, _;
|
|
1616
1635
|
return {
|
|
1617
|
-
color: ((
|
|
1618
|
-
label:
|
|
1619
|
-
value: (_ = (d = (
|
|
1636
|
+
color: ((c = h[l]) == null ? void 0 : c.color) || i,
|
|
1637
|
+
label: u,
|
|
1638
|
+
value: (_ = (d = (f = h[l]) == null ? void 0 : f.label) != null ? d : (p = h[l]) == null ? void 0 : p.value) != null ? _ : jt
|
|
1620
1639
|
};
|
|
1621
1640
|
});
|
|
1622
1641
|
}
|
|
1623
|
-
return { getTooltipAnchorAttributes: o, getTooltipItems:
|
|
1642
|
+
return { getTooltipAnchorAttributes: o, getTooltipItems: s };
|
|
1624
1643
|
}
|
|
1625
|
-
function
|
|
1626
|
-
const e =
|
|
1644
|
+
function fr() {
|
|
1645
|
+
const e = lt({
|
|
1627
1646
|
opened: !1,
|
|
1628
1647
|
targetElement: null
|
|
1629
1648
|
});
|
|
1630
1649
|
return { tooltipConfig: e, showTooltip: (r) => {
|
|
1631
|
-
|
|
1650
|
+
D.set(e, "opened", !0), D.set(e, "targetElement", r);
|
|
1632
1651
|
}, hideTooltip: () => {
|
|
1633
|
-
|
|
1652
|
+
D.set(e, "opened", !1), D.set(e, "targetElement", null);
|
|
1634
1653
|
} };
|
|
1635
1654
|
}
|
|
1636
|
-
const
|
|
1655
|
+
const pr = L({
|
|
1637
1656
|
components: {
|
|
1638
|
-
LumeAxis:
|
|
1639
|
-
LumeBar:
|
|
1640
|
-
LumeChartContainer:
|
|
1641
|
-
LumeChartLegend:
|
|
1642
|
-
LumeOverlayGroup:
|
|
1643
|
-
LumeTooltip:
|
|
1657
|
+
LumeAxis: mn,
|
|
1658
|
+
LumeBar: $t,
|
|
1659
|
+
LumeChartContainer: On,
|
|
1660
|
+
LumeChartLegend: wn,
|
|
1661
|
+
LumeOverlayGroup: ar,
|
|
1662
|
+
LumeTooltip: Rn,
|
|
1663
|
+
VuePortal: yt,
|
|
1664
|
+
VuePortalTarget: bt
|
|
1644
1665
|
},
|
|
1645
1666
|
props: {
|
|
1646
|
-
...
|
|
1667
|
+
...G(),
|
|
1647
1668
|
chartType: {
|
|
1648
1669
|
type: String,
|
|
1649
1670
|
default: null
|
|
1650
1671
|
}
|
|
1651
1672
|
},
|
|
1652
1673
|
setup(e, t) {
|
|
1653
|
-
const { data: n, labels: r, color: a, options: o, orientation:
|
|
1654
|
-
|
|
1655
|
-
r,
|
|
1656
|
-
a,
|
|
1657
|
-
l,
|
|
1658
|
-
i
|
|
1659
|
-
), { xScale: b, yScale: m } = ar(
|
|
1660
|
-
v,
|
|
1674
|
+
const { data: n, labels: r, color: a, options: o, orientation: s, chartType: l } = w(e), i = $(-1), u = $(null), h = $(null), { allOptions: c } = F(o), { internalData: f, computedLabels: p, containerSize: d, updateSize: _, chartID: y } = dt(n, r, a, c, s), { xScale: m, yScale: g } = sr(
|
|
1675
|
+
f,
|
|
1661
1676
|
p,
|
|
1662
1677
|
d,
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
),
|
|
1666
|
-
var
|
|
1667
|
-
return e.xScale ?
|
|
1668
|
-
}),
|
|
1669
|
-
var
|
|
1670
|
-
return e.yScale ?
|
|
1671
|
-
}),
|
|
1672
|
-
...
|
|
1673
|
-
withHover:
|
|
1674
|
-
})),
|
|
1675
|
-
...
|
|
1676
|
-
withHover:
|
|
1677
|
-
})),
|
|
1678
|
-
var
|
|
1679
|
-
return (
|
|
1680
|
-
}),
|
|
1681
|
-
var
|
|
1682
|
-
return (
|
|
1683
|
-
}),
|
|
1684
|
-
var
|
|
1685
|
-
return ((
|
|
1686
|
-
}),
|
|
1687
|
-
var
|
|
1688
|
-
return ((
|
|
1689
|
-
}),
|
|
1678
|
+
s,
|
|
1679
|
+
c
|
|
1680
|
+
), b = v(() => {
|
|
1681
|
+
var A;
|
|
1682
|
+
return e.xScale ? Rt(e.xScale) ? e.xScale : (A = e.xScale) == null ? void 0 : A.call(e, f.value, r.value, d) : m.value;
|
|
1683
|
+
}), x = v(() => {
|
|
1684
|
+
var A;
|
|
1685
|
+
return e.yScale ? Rt(e.yScale) ? e.yScale : (A = e.yScale) == null ? void 0 : A.call(e, f.value, r.value, d) : g.value;
|
|
1686
|
+
}), O = v(() => ({
|
|
1687
|
+
...c.value.xAxisOptions,
|
|
1688
|
+
withHover: s.value === T.VERTICAL
|
|
1689
|
+
})), E = v(() => ({
|
|
1690
|
+
...c.value.yAxisOptions,
|
|
1691
|
+
withHover: s.value === T.HORIZONTAL
|
|
1692
|
+
})), B = v(() => {
|
|
1693
|
+
var A;
|
|
1694
|
+
return (A = c.value.xAxisOptions) == null ? void 0 : A.title;
|
|
1695
|
+
}), C = v(() => {
|
|
1696
|
+
var A;
|
|
1697
|
+
return (A = c.value.yAxisOptions) == null ? void 0 : A.title;
|
|
1698
|
+
}), k = v(() => {
|
|
1699
|
+
var A;
|
|
1700
|
+
return ((A = c.value.xAxisOptions) == null ? void 0 : A.withTitle) !== !1 && B.value;
|
|
1701
|
+
}), I = v(() => {
|
|
1702
|
+
var A;
|
|
1703
|
+
return ((A = c.value.yAxisOptions) == null ? void 0 : A.withTitle) !== !1 && C.value;
|
|
1704
|
+
}), H = v(
|
|
1690
1705
|
() => {
|
|
1691
|
-
var
|
|
1692
|
-
return
|
|
1706
|
+
var A;
|
|
1707
|
+
return c.value.withTooltip !== !1 && !((A = c.value.tooltipOptions) != null && A.targetElement);
|
|
1693
1708
|
}
|
|
1694
|
-
),
|
|
1695
|
-
const
|
|
1696
|
-
return X ||
|
|
1697
|
-
}), { hasNegativeValues:
|
|
1709
|
+
), j = v(() => {
|
|
1710
|
+
const A = [], { noBaseScales: X } = c.value;
|
|
1711
|
+
return X || A.push(() => !!(b.value && x.value)), A.every((rt) => rt() === !0);
|
|
1712
|
+
}), { hasNegativeValues: et } = lr(f), { negativeBarAttributes: nt } = ur(
|
|
1698
1713
|
d,
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
), { tooltipConfig:
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
),
|
|
1714
|
+
b,
|
|
1715
|
+
x,
|
|
1716
|
+
s
|
|
1717
|
+
), { tooltipConfig: z, showTooltip: vt, hideTooltip: Qt } = fr(), { getTooltipAnchorAttributes: te, getTooltipItems: ee } = dr(
|
|
1718
|
+
f,
|
|
1719
|
+
b,
|
|
1720
|
+
x,
|
|
1721
|
+
s,
|
|
1722
|
+
l
|
|
1723
|
+
), ne = v(
|
|
1709
1724
|
() => {
|
|
1710
|
-
var
|
|
1711
|
-
return ((
|
|
1725
|
+
var A;
|
|
1726
|
+
return ((A = c.value.tooltipOptions) == null ? void 0 : A.position) || "top";
|
|
1712
1727
|
}
|
|
1713
1728
|
);
|
|
1714
|
-
function
|
|
1715
|
-
var
|
|
1716
|
-
|
|
1717
|
-
const X = (
|
|
1718
|
-
|
|
1729
|
+
function re(A) {
|
|
1730
|
+
var rt;
|
|
1731
|
+
c.value.withHover !== !1 && (i.value = A);
|
|
1732
|
+
const X = (rt = c.value.tooltipOptions) != null && rt.targetElement ? c.value.tooltipOptions.targetElement === "self" ? h.value.$el : c.value.tooltipOptions.targetElement : u.value[A];
|
|
1733
|
+
c.value.withTooltip !== !1 && vt(X);
|
|
1719
1734
|
}
|
|
1720
|
-
function
|
|
1721
|
-
|
|
1735
|
+
function ae() {
|
|
1736
|
+
Qt(), i.value = -1;
|
|
1722
1737
|
}
|
|
1723
|
-
return
|
|
1724
|
-
var
|
|
1725
|
-
(X = (
|
|
1738
|
+
return V(() => {
|
|
1739
|
+
var A, X;
|
|
1740
|
+
(X = (A = t.slots).groups) != null && X.call(A) || console.error('"groups" `<slot>` must have content.');
|
|
1726
1741
|
}), {
|
|
1727
|
-
allOptions:
|
|
1728
|
-
internalData:
|
|
1742
|
+
allOptions: c,
|
|
1743
|
+
internalData: f,
|
|
1729
1744
|
chartContainer: h,
|
|
1730
1745
|
computedLabels: p,
|
|
1731
|
-
computedXAxisOptions:
|
|
1732
|
-
computedXScale:
|
|
1733
|
-
computedYAxisOptions:
|
|
1734
|
-
computedYScale:
|
|
1746
|
+
computedXAxisOptions: O,
|
|
1747
|
+
computedXScale: b,
|
|
1748
|
+
computedYAxisOptions: E,
|
|
1749
|
+
computedYScale: x,
|
|
1735
1750
|
containerSize: d,
|
|
1736
|
-
getEmptyArrayFromData:
|
|
1737
|
-
getTooltipAnchorAttributes:
|
|
1738
|
-
getTooltipItems:
|
|
1739
|
-
handleMouseleave:
|
|
1740
|
-
hasNegativeValues:
|
|
1741
|
-
hoveredIndex:
|
|
1742
|
-
isReady:
|
|
1743
|
-
mouseOverHandler:
|
|
1744
|
-
negativeBarAttributes:
|
|
1745
|
-
shouldGenerateTooltipAnchors:
|
|
1746
|
-
showXAxisTitle:
|
|
1747
|
-
showYAxisTitle:
|
|
1748
|
-
tooltipAnchor:
|
|
1749
|
-
tooltipAnchorRadius:
|
|
1750
|
-
tooltipConfig:
|
|
1751
|
-
tooltipPosition:
|
|
1751
|
+
getEmptyArrayFromData: st,
|
|
1752
|
+
getTooltipAnchorAttributes: te,
|
|
1753
|
+
getTooltipItems: ee,
|
|
1754
|
+
handleMouseleave: ae,
|
|
1755
|
+
hasNegativeValues: et,
|
|
1756
|
+
hoveredIndex: i,
|
|
1757
|
+
isReady: j,
|
|
1758
|
+
mouseOverHandler: re,
|
|
1759
|
+
negativeBarAttributes: nt,
|
|
1760
|
+
shouldGenerateTooltipAnchors: H,
|
|
1761
|
+
showXAxisTitle: k,
|
|
1762
|
+
showYAxisTitle: I,
|
|
1763
|
+
tooltipAnchor: u,
|
|
1764
|
+
tooltipAnchorRadius: De,
|
|
1765
|
+
tooltipConfig: z,
|
|
1766
|
+
tooltipPosition: ne,
|
|
1752
1767
|
updateSize: _,
|
|
1753
|
-
xAxisTitle:
|
|
1754
|
-
yAxisTitle:
|
|
1768
|
+
xAxisTitle: B,
|
|
1769
|
+
yAxisTitle: C,
|
|
1770
|
+
chartID: y
|
|
1755
1771
|
};
|
|
1756
1772
|
}
|
|
1757
1773
|
});
|
|
1758
|
-
var
|
|
1774
|
+
var vr = function() {
|
|
1759
1775
|
var t = this, n = t._self._c;
|
|
1760
1776
|
return t._self._setupProxy, n("lume-chart-container", { ref: "chartContainer", attrs: { margins: t.allOptions.margins, "container-size": t.containerSize, "no-min-size": t.allOptions.noMinSize, "transparent-background": t.allOptions.transparentBackground, "data-j-lume-chart": "" }, on: { resize: t.updateSize, mouseleave: t.handleMouseleave }, scopedSlots: t._u([{ key: "header", fn: function() {
|
|
1761
|
-
return [n("div", { staticClass: "lume-chart__header" }, [n("div", { staticClass: "lume-chart__header-section" }, [t.title ? n("h1", { staticClass: "lume-chart__title lume-chart-title lume-typography--display" }, [t._v(" " + t._s(t.title) + " ")]) : t._e(), n("div", { staticClass: "lume-chart__controls" }, [t._t("controls")], 2)]), n("div", { staticClass: "lume-chart__header-section" }, [t.showYAxisTitle ? n("h3", { staticClass: "lume-chart__axis-title lume-axis-title lume-typography--body" }, [t._v(" " + t._s(t.yAxisTitle) + " ")]) : t._e(), t.allOptions.withLegend !== !1
|
|
1777
|
+
return [n("div", { staticClass: "lume-chart__header" }, [n("div", { staticClass: "lume-chart__header-section" }, [t.title ? n("h1", { staticClass: "lume-chart__title lume-chart-title lume-typography--display" }, [t._v(" " + t._s(t.title) + " ")]) : t._e(), n("div", { staticClass: "lume-chart__controls" }, [t._t("controls")], 2)]), n("div", { staticClass: "lume-chart__header-section" }, [t.showYAxisTitle ? n("h3", { staticClass: "lume-chart__axis-title lume-axis-title lume-typography--body" }, [t._v(" " + t._s(t.yAxisTitle) + " ")]) : t._e(), t.allOptions.withLegend !== !1 ? n("vue-portal", { attrs: { disabled: t.allOptions.legendPosition !== "bottom", to: `legend-bottom-${t.chartID}`, slim: "" } }, [n("lume-chart-legend", { staticClass: "lume-chart__legend", attrs: { data: t.internalData, "data-j-lume-chart__legend": "" }, on: { click: function(r) {
|
|
1762
1778
|
return t.$emit("click", r);
|
|
1763
|
-
} } }) : t._e()], 1)])];
|
|
1779
|
+
} } })], 1) : t._e()], 1)])];
|
|
1764
1780
|
}, proxy: !0 }, { key: "footer", fn: function() {
|
|
1765
|
-
return [t.showXAxisTitle ? n("h3", { staticClass: "lume-chart__axis-title lume-chart__axis-title--centered lume-axis-title" }, [t._v(" " + t._s(t.xAxisTitle) + " ")]) : t._e(),
|
|
1766
|
-
return t.$emit("click", r);
|
|
1767
|
-
} } }) : t._e()];
|
|
1781
|
+
return [t.showXAxisTitle ? n("h3", { staticClass: "lume-chart__axis-title lume-chart__axis-title--centered lume-axis-title" }, [t._v(" " + t._s(t.xAxisTitle) + " ")]) : t._e(), n("vue-portal-target", { attrs: { name: `legend-bottom-${t.chartID}`, slim: "" } })];
|
|
1768
1782
|
}, proxy: !0 }, { key: "extra", fn: function() {
|
|
1769
1783
|
return [t._t("tooltip", function() {
|
|
1770
1784
|
return [t.allOptions.withTooltip !== !1 && t.tooltipConfig.opened ? n("lume-tooltip", t._b({ attrs: { position: t.tooltipPosition, title: t.computedLabels[t.hoveredIndex], items: t.getTooltipItems(t.hoveredIndex), options: t.allOptions.tooltipOptions, "data-j-lume-chart__tooltip": "" } }, "lume-tooltip", t.tooltipConfig, !1), [t._t("tooltip-content", null, { data: t.internalData, labels: t.computedLabels, hoveredIndex: t.hoveredIndex })], 2) : t._e()];
|
|
@@ -1778,17 +1792,17 @@ var fr = function() {
|
|
|
1778
1792
|
}, { xScale: t.computedXScale, yScale: t.computedYScale, containerSize: t.containerSize, options: t.allOptions, hoveredIndex: t.hoveredIndex }) : t._e(), t._t("groups", null, { data: t.internalData, labels: t.computedLabels, options: t.allOptions, orientation: t.orientation, xScale: t.computedXScale, yScale: t.computedYScale, hoveredIndex: t.hoveredIndex, containerSize: t.containerSize, transition: t.allOptions.withTransition !== !1, classList: t.classList }), t.allOptions.withHover !== !1 ? n("lume-overlay-group", { attrs: { data: t.internalData, orientation: t.orientation, "x-scale": t.computedXScale, "y-scale": t.computedYScale, "data-j-lume-chart__overlay-group": "" }, on: { mouseover: t.mouseOverHandler } }) : t._e(), t.shouldGenerateTooltipAnchors ? n("g", t._l(t.getEmptyArrayFromData(t.internalData), function(r, a) {
|
|
1779
1793
|
return n("circle", t._b({ key: `anchor-${a}`, ref: "tooltipAnchor", refInFor: !0, staticClass: "lume-fill--transparent", attrs: { r: t.tooltipAnchorRadius } }, "circle", t.getTooltipAnchorAttributes(a), !1));
|
|
1780
1794
|
}), 0) : t._e()] : t._e()], 2);
|
|
1781
|
-
},
|
|
1782
|
-
dr,
|
|
1783
|
-
fr,
|
|
1795
|
+
}, hr = [], _r = /* @__PURE__ */ S(
|
|
1784
1796
|
pr,
|
|
1797
|
+
vr,
|
|
1798
|
+
hr,
|
|
1785
1799
|
!1,
|
|
1786
1800
|
null,
|
|
1787
|
-
"
|
|
1801
|
+
"5119f57e",
|
|
1788
1802
|
null,
|
|
1789
1803
|
null
|
|
1790
1804
|
);
|
|
1791
|
-
const Y =
|
|
1805
|
+
const Y = _r.exports, mr = 8, gr = L({
|
|
1792
1806
|
props: {
|
|
1793
1807
|
linkPaths: {
|
|
1794
1808
|
type: Array,
|
|
@@ -1808,8 +1822,8 @@ const Y = vr.exports, hr = 8, _r = S({
|
|
|
1808
1822
|
}
|
|
1809
1823
|
},
|
|
1810
1824
|
setup(e) {
|
|
1811
|
-
const { highlightedLinkIds: t, isGhost: n } =
|
|
1812
|
-
() => n.value ?
|
|
1825
|
+
const { highlightedLinkIds: t, isGhost: n } = w(e), r = v(
|
|
1826
|
+
() => n.value ? mr : 0
|
|
1813
1827
|
);
|
|
1814
1828
|
function a(o) {
|
|
1815
1829
|
return {
|
|
@@ -1825,7 +1839,7 @@ const Y = vr.exports, hr = 8, _r = S({
|
|
|
1825
1839
|
return { getClasses: a, ghostStrokeWidthOffset: r };
|
|
1826
1840
|
}
|
|
1827
1841
|
});
|
|
1828
|
-
var
|
|
1842
|
+
var yr = function() {
|
|
1829
1843
|
var t = this, n = t._self._c;
|
|
1830
1844
|
return t._self._setupProxy, n("g", { staticClass: "lume-alluvial-path-group" }, t._l(t.linkPaths, function(r) {
|
|
1831
1845
|
return n("path", { key: `link_${r.id}`, staticClass: "lume-alluvial-path-group__link", class: t.getClasses(r), attrs: { id: t.isGhost ? `${r.id}__ghost` : r.id, d: r.d, "stroke-dasharray": t.containerWidth, "stroke-dashoffset": t.containerWidth, "stroke-width": r.strokeWidth + t.ghostStrokeWidthOffset, "data-j-alluvial-path__path": "" }, on: { mouseover: function(a) {
|
|
@@ -1834,23 +1848,23 @@ var mr = function() {
|
|
|
1834
1848
|
return t.$emit("mouseout");
|
|
1835
1849
|
} } });
|
|
1836
1850
|
}), 0);
|
|
1837
|
-
},
|
|
1838
|
-
_r,
|
|
1839
|
-
mr,
|
|
1851
|
+
}, br = [], xr = /* @__PURE__ */ S(
|
|
1840
1852
|
gr,
|
|
1853
|
+
yr,
|
|
1854
|
+
br,
|
|
1841
1855
|
!1,
|
|
1842
1856
|
null,
|
|
1843
1857
|
"ce6a9b03",
|
|
1844
1858
|
null,
|
|
1845
1859
|
null
|
|
1846
1860
|
);
|
|
1847
|
-
const
|
|
1848
|
-
function
|
|
1861
|
+
const Tr = xr.exports, Xt = "03", K = 8, Ar = 200;
|
|
1862
|
+
function Or(e, t, n) {
|
|
1849
1863
|
let r = !1;
|
|
1850
1864
|
gt(() => {
|
|
1851
1865
|
r = !0;
|
|
1852
1866
|
});
|
|
1853
|
-
const a =
|
|
1867
|
+
const a = v(() => Math.max(...n.value.nodes.map(({ depth: p }) => p))), o = v(() => {
|
|
1854
1868
|
if (e.value.highlightedLink === null && e.value.highlightedNode === null)
|
|
1855
1869
|
return {};
|
|
1856
1870
|
if (t.value.getHighlightedElements)
|
|
@@ -1867,7 +1881,7 @@ function Ar(e, t, n) {
|
|
|
1867
1881
|
return {
|
|
1868
1882
|
links: p,
|
|
1869
1883
|
nodes: new Map(
|
|
1870
|
-
p.reduce((d, { source: _, target:
|
|
1884
|
+
p.reduce((d, { source: _, target: y, value: m }) => _ === e.value.highlightedNode ? [...d, [R(y), m]] : [...d, [R(_), m]], [])
|
|
1871
1885
|
)
|
|
1872
1886
|
};
|
|
1873
1887
|
}
|
|
@@ -1875,67 +1889,67 @@ function Ar(e, t, n) {
|
|
|
1875
1889
|
links: [e.value.highlightedLink],
|
|
1876
1890
|
nodes: /* @__PURE__ */ new Map([
|
|
1877
1891
|
[
|
|
1878
|
-
|
|
1892
|
+
R(e.value.highlightedLink.target),
|
|
1879
1893
|
e.value.highlightedLink.value
|
|
1880
1894
|
]
|
|
1881
1895
|
])
|
|
1882
1896
|
};
|
|
1883
1897
|
});
|
|
1884
|
-
function
|
|
1898
|
+
function s(p) {
|
|
1885
1899
|
return typeof p == "string" || typeof p == "number" ? p : p == null ? void 0 : p.id;
|
|
1886
1900
|
}
|
|
1887
|
-
function
|
|
1901
|
+
function l(p = n.value.links) {
|
|
1888
1902
|
const d = p.map(
|
|
1889
|
-
(
|
|
1903
|
+
(y) => `link_${s(y.source)}:${s(y.target)}`
|
|
1890
1904
|
);
|
|
1891
1905
|
return { nodeIds: p.reduce(
|
|
1892
|
-
(
|
|
1893
|
-
...
|
|
1894
|
-
`node-block-${
|
|
1895
|
-
`node-block-${
|
|
1906
|
+
(y, { source: m, target: g }) => [
|
|
1907
|
+
...y,
|
|
1908
|
+
`node-block-${s(m)}`,
|
|
1909
|
+
`node-block-${s(g)}`
|
|
1896
1910
|
],
|
|
1897
1911
|
[]
|
|
1898
1912
|
), linkIds: d };
|
|
1899
1913
|
}
|
|
1900
|
-
function
|
|
1901
|
-
const
|
|
1914
|
+
function i(p, d, _) {
|
|
1915
|
+
const y = Date.now(), m = e.value.nodeBlocks.find(
|
|
1902
1916
|
(x) => x.id === `node-block-${p}`
|
|
1903
|
-
), g =
|
|
1917
|
+
), g = Me(d, _), b = () => {
|
|
1904
1918
|
if (r)
|
|
1905
1919
|
return;
|
|
1906
|
-
let
|
|
1907
|
-
|
|
1920
|
+
let O = (Date.now() - y) / Ar;
|
|
1921
|
+
O > 1 && (O = 1), D.set(m.node, "transitionValue", g(O)), O < 1 && requestAnimationFrame(b);
|
|
1908
1922
|
};
|
|
1909
|
-
requestAnimationFrame(
|
|
1910
|
-
}
|
|
1911
|
-
function
|
|
1912
|
-
const
|
|
1913
|
-
n.value.nodes.filter((
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
m(
|
|
1917
|
-
g(
|
|
1923
|
+
requestAnimationFrame(b);
|
|
1924
|
+
}
|
|
1925
|
+
function u({ values: p, updatingNodes: d = [], isEntering: _ = !1 }) {
|
|
1926
|
+
const y = new Set(d), m = (b) => _ ? b.value : p.get(R(b)), g = (b) => _ ? p.get(R(b)) : b.value;
|
|
1927
|
+
n.value.nodes.filter((b) => y.has(b)).forEach((b) => {
|
|
1928
|
+
i(
|
|
1929
|
+
R(b),
|
|
1930
|
+
m(b),
|
|
1931
|
+
g(b)
|
|
1918
1932
|
);
|
|
1919
1933
|
});
|
|
1920
1934
|
}
|
|
1921
1935
|
function h(p) {
|
|
1922
|
-
const d =
|
|
1936
|
+
const d = ie();
|
|
1923
1937
|
return p.map((_) => {
|
|
1924
|
-
var
|
|
1938
|
+
var y;
|
|
1925
1939
|
return {
|
|
1926
|
-
id: `link_${
|
|
1940
|
+
id: `link_${R(_.source)}:${R(
|
|
1927
1941
|
_.target
|
|
1928
1942
|
)}`,
|
|
1929
1943
|
d: d(_),
|
|
1930
|
-
color: _.color || ((
|
|
1944
|
+
color: _.color || ((y = _.source) == null ? void 0 : y.color) || Xt,
|
|
1931
1945
|
strokeWidth: Math.max(1, _.width),
|
|
1932
1946
|
link: _
|
|
1933
1947
|
};
|
|
1934
1948
|
});
|
|
1935
1949
|
}
|
|
1936
|
-
function
|
|
1950
|
+
function c(p) {
|
|
1937
1951
|
return p.map((d) => ({
|
|
1938
|
-
id: `node-block-${
|
|
1952
|
+
id: `node-block-${R(d)}`,
|
|
1939
1953
|
rect: {
|
|
1940
1954
|
width: d.x1 - d.x0,
|
|
1941
1955
|
height: d.y1 - d.y0
|
|
@@ -1947,73 +1961,73 @@ function Ar(e, t, n) {
|
|
|
1947
1961
|
node: d
|
|
1948
1962
|
}));
|
|
1949
1963
|
}
|
|
1950
|
-
function
|
|
1951
|
-
p == null || d == null || (e.value.nodeBlocks =
|
|
1964
|
+
function f({ nodes: p, links: d }) {
|
|
1965
|
+
p == null || d == null || (e.value.nodeBlocks = c(p), e.value.linkPaths = h(d));
|
|
1952
1966
|
}
|
|
1953
1967
|
return {
|
|
1954
1968
|
highlightedElements: o,
|
|
1955
|
-
highlightLinks:
|
|
1956
|
-
updateNodes:
|
|
1957
|
-
renderChart:
|
|
1969
|
+
highlightLinks: l,
|
|
1970
|
+
updateNodes: u,
|
|
1971
|
+
renderChart: f,
|
|
1958
1972
|
maxDepth: a
|
|
1959
1973
|
};
|
|
1960
1974
|
}
|
|
1961
|
-
function
|
|
1962
|
-
function r(
|
|
1963
|
-
var
|
|
1964
|
-
return (p = (
|
|
1965
|
-
(d, _) => Math.max(d, _[
|
|
1975
|
+
function $r(e, t, n) {
|
|
1976
|
+
function r(c) {
|
|
1977
|
+
var f, p;
|
|
1978
|
+
return (p = (f = t.value) == null ? void 0 : f.nodes) == null ? void 0 : p.reduce(
|
|
1979
|
+
(d, _) => Math.max(d, _[c]),
|
|
1966
1980
|
-1 / 0
|
|
1967
1981
|
);
|
|
1968
1982
|
}
|
|
1969
|
-
function a(
|
|
1970
|
-
return
|
|
1983
|
+
function a(c, f) {
|
|
1984
|
+
return s(f) - s(c);
|
|
1971
1985
|
}
|
|
1972
|
-
function o(
|
|
1973
|
-
var
|
|
1974
|
-
return (p = (
|
|
1986
|
+
function o(c) {
|
|
1987
|
+
var f, p;
|
|
1988
|
+
return (p = (f = n.value) == null ? void 0 : f.find((d) => d.id === `node-text-${c.id}`)) == null ? void 0 : p.getBBox();
|
|
1975
1989
|
}
|
|
1976
|
-
function
|
|
1990
|
+
function s({ label: c, value: f }) {
|
|
1977
1991
|
var p;
|
|
1978
1992
|
return Math.max(
|
|
1979
|
-
|
|
1980
|
-
((p = e.value.valueFormatter(
|
|
1993
|
+
c.length,
|
|
1994
|
+
((p = e.value.valueFormatter(f)) == null ? void 0 : p.length) || 0
|
|
1981
1995
|
);
|
|
1982
1996
|
}
|
|
1983
|
-
const
|
|
1984
|
-
var p, d, _,
|
|
1985
|
-
const
|
|
1986
|
-
return
|
|
1987
|
-
}),
|
|
1988
|
-
var p, d, _,
|
|
1989
|
-
const
|
|
1990
|
-
(
|
|
1997
|
+
const l = v(() => {
|
|
1998
|
+
var p, d, _, y;
|
|
1999
|
+
const c = r("x1"), f = (d = (p = t.value.nodes) == null ? void 0 : p.filter(({ x1: m }) => m === c).sort(a)) == null ? void 0 : d[0];
|
|
2000
|
+
return f == null ? 0 : (y = (_ = o(f)) == null ? void 0 : _.width) != null ? y : 0;
|
|
2001
|
+
}), i = v(() => {
|
|
2002
|
+
var p, d, _, y, m, g;
|
|
2003
|
+
const c = (d = (p = t.value) == null ? void 0 : p.nodes) == null ? void 0 : d.reduce(
|
|
2004
|
+
(b, { y0: x }) => Math.min(b, x),
|
|
1991
2005
|
1 / 0
|
|
1992
|
-
),
|
|
1993
|
-
return
|
|
1994
|
-
}),
|
|
1995
|
-
var p, d, _,
|
|
1996
|
-
const
|
|
1997
|
-
return
|
|
2006
|
+
), f = (y = (_ = t.value) == null ? void 0 : _.nodes) == null ? void 0 : y.find(({ y0: b }) => b === c);
|
|
2007
|
+
return f == null ? 0 : Math.abs((g = (m = o(f)) == null ? void 0 : m.y) != null ? g : 0);
|
|
2008
|
+
}), u = v(() => {
|
|
2009
|
+
var p, d, _, y;
|
|
2010
|
+
const c = r("y1"), f = (d = (p = t.value) == null ? void 0 : p.nodes) == null ? void 0 : d.find(({ y1: m }) => m === c);
|
|
2011
|
+
return f == null ? 0 : Math.abs((y = (_ = o(f)) == null ? void 0 : _.y) != null ? y : 0);
|
|
1998
2012
|
});
|
|
1999
2013
|
return {
|
|
2000
|
-
leftMostNodeLabelWidth:
|
|
2001
|
-
var
|
|
2002
|
-
const
|
|
2003
|
-
return
|
|
2014
|
+
leftMostNodeLabelWidth: v(() => {
|
|
2015
|
+
var f, p, d, _;
|
|
2016
|
+
const c = (p = (f = t.value.nodes) == null ? void 0 : f.filter(({ depth: y }) => y === 0).sort(a)) == null ? void 0 : p[0];
|
|
2017
|
+
return c == null ? 0 : (_ = (d = o(c)) == null ? void 0 : d.width) != null ? _ : 0;
|
|
2004
2018
|
}),
|
|
2005
|
-
rightMostNodeLabelWidth:
|
|
2006
|
-
topMostNodeLabelExtraHeight:
|
|
2007
|
-
bottomMostNodeLabelExtraHeight:
|
|
2019
|
+
rightMostNodeLabelWidth: l,
|
|
2020
|
+
topMostNodeLabelExtraHeight: i,
|
|
2021
|
+
bottomMostNodeLabelExtraHeight: u
|
|
2008
2022
|
};
|
|
2009
2023
|
}
|
|
2010
|
-
const
|
|
2024
|
+
const kr = {
|
|
2011
2025
|
values: [],
|
|
2012
2026
|
nodePadding: 16,
|
|
2013
2027
|
nodeWidth: 16,
|
|
2014
|
-
nodeAlign:
|
|
2028
|
+
nodeAlign: ue,
|
|
2015
2029
|
valueFormatter: (e) => String(e)
|
|
2016
|
-
},
|
|
2030
|
+
}, Lr = {
|
|
2017
2031
|
highlightedLink: null,
|
|
2018
2032
|
highlightedNode: null,
|
|
2019
2033
|
leftExtent: 0,
|
|
@@ -2023,107 +2037,107 @@ const Tr = {
|
|
|
2023
2037
|
nodeBlocks: [],
|
|
2024
2038
|
linkPaths: []
|
|
2025
2039
|
};
|
|
2026
|
-
function
|
|
2027
|
-
const n =
|
|
2028
|
-
label:
|
|
2029
|
-
color:
|
|
2030
|
-
id:
|
|
2031
|
-
}))), a =
|
|
2032
|
-
(
|
|
2033
|
-
var
|
|
2034
|
-
return (
|
|
2035
|
-
var
|
|
2040
|
+
function Sr(e, t) {
|
|
2041
|
+
const n = $({ ...Lr, containerSize: t }), r = v(() => e.value.values.map(({ label: l, color: i, value: u }) => ({
|
|
2042
|
+
label: l,
|
|
2043
|
+
color: i,
|
|
2044
|
+
id: u
|
|
2045
|
+
}))), a = v(() => e.value.values.map(
|
|
2046
|
+
(l) => {
|
|
2047
|
+
var i;
|
|
2048
|
+
return (i = l.targets) == null ? void 0 : i.map(({ node: u, value: h, color: c }) => {
|
|
2049
|
+
var f;
|
|
2036
2050
|
return {
|
|
2037
|
-
source: (
|
|
2038
|
-
color:
|
|
2039
|
-
target:
|
|
2051
|
+
source: (f = l.value) != null ? f : l.label,
|
|
2052
|
+
color: c,
|
|
2053
|
+
target: u,
|
|
2040
2054
|
value: h
|
|
2041
2055
|
};
|
|
2042
2056
|
});
|
|
2043
2057
|
}
|
|
2044
|
-
).filter(Boolean).reduce((
|
|
2045
|
-
const { leftExtent:
|
|
2046
|
-
return
|
|
2047
|
-
[
|
|
2048
|
-
[
|
|
2058
|
+
).filter(Boolean).reduce((l, i) => [...l, ...i], [])), o = v(() => {
|
|
2059
|
+
const { leftExtent: l, rightExtent: i, topExtent: u, bottomExtent: h, containerSize: c } = n.value;
|
|
2060
|
+
return le().nodeId(R).nodeWidth(e.value.nodeWidth).nodeSort(e.value.nodeSort).nodePadding(20).nodeAlign(e.value.nodeAlign).extent([
|
|
2061
|
+
[l, u],
|
|
2062
|
+
[i, c.height - h]
|
|
2049
2063
|
]);
|
|
2050
|
-
}),
|
|
2051
|
-
nodes: r.value.map((
|
|
2052
|
-
links: a.value.map((
|
|
2064
|
+
}), s = v(() => o.value({
|
|
2065
|
+
nodes: r.value.map((l) => ({ ...l })),
|
|
2066
|
+
links: a.value.map((l) => ({ ...l }))
|
|
2053
2067
|
}));
|
|
2054
2068
|
return {
|
|
2055
2069
|
nodes: r,
|
|
2056
2070
|
links: a,
|
|
2057
|
-
graph:
|
|
2071
|
+
graph: s,
|
|
2058
2072
|
alluvialInstance: n
|
|
2059
2073
|
};
|
|
2060
2074
|
}
|
|
2061
|
-
function
|
|
2075
|
+
function wr(e) {
|
|
2062
2076
|
var n;
|
|
2063
2077
|
const t = (n = e.value) == null ? void 0 : n[0];
|
|
2064
2078
|
if (!!t)
|
|
2065
|
-
return
|
|
2066
|
-
...
|
|
2079
|
+
return $({
|
|
2080
|
+
...kr,
|
|
2067
2081
|
...t
|
|
2068
2082
|
});
|
|
2069
2083
|
}
|
|
2070
|
-
const
|
|
2071
|
-
components: { LumeAlluvialPathGroup:
|
|
2084
|
+
const Cr = L({
|
|
2085
|
+
components: { LumeAlluvialPathGroup: Tr },
|
|
2072
2086
|
props: {
|
|
2073
|
-
...
|
|
2087
|
+
...G(ut)
|
|
2074
2088
|
},
|
|
2075
2089
|
setup(e, t) {
|
|
2076
|
-
const n =
|
|
2077
|
-
|
|
2090
|
+
const n = se(e, "data"), r = $([]), a = $([]), o = $(null), s = wr(n), { graph: l, alluvialInstance: i } = Sr(
|
|
2091
|
+
s,
|
|
2078
2092
|
t.attrs.containerSize
|
|
2079
2093
|
), {
|
|
2080
|
-
leftMostNodeLabelWidth:
|
|
2094
|
+
leftMostNodeLabelWidth: u,
|
|
2081
2095
|
rightMostNodeLabelWidth: h,
|
|
2082
|
-
topMostNodeLabelExtraHeight:
|
|
2083
|
-
bottomMostNodeLabelExtraHeight:
|
|
2084
|
-
} =
|
|
2096
|
+
topMostNodeLabelExtraHeight: c,
|
|
2097
|
+
bottomMostNodeLabelExtraHeight: f
|
|
2098
|
+
} = $r(s, l, o), {
|
|
2085
2099
|
highlightedElements: p,
|
|
2086
2100
|
highlightLinks: d,
|
|
2087
2101
|
updateNodes: _,
|
|
2088
|
-
renderChart:
|
|
2102
|
+
renderChart: y,
|
|
2089
2103
|
maxDepth: m
|
|
2090
|
-
} =
|
|
2091
|
-
return
|
|
2092
|
-
var
|
|
2093
|
-
const x = g.nodes != null && g.links != null,
|
|
2094
|
-
(j = (H =
|
|
2104
|
+
} = Or(i, s, l);
|
|
2105
|
+
return N(p, function(g, b) {
|
|
2106
|
+
var I, H, j, et, nt;
|
|
2107
|
+
const x = g.nodes != null && g.links != null, O = new Set((I = g.links) != null ? I : []), { nodes: E = /* @__PURE__ */ new Map() } = (x ? g : b) || {}, { nodeIds: B, linkIds: C } = d(
|
|
2108
|
+
(j = (H = l.value) == null ? void 0 : H.links) == null ? void 0 : j.filter((z) => O.has(z))
|
|
2095
2109
|
);
|
|
2096
|
-
((z = [],
|
|
2097
|
-
a.value = z, r.value =
|
|
2098
|
-
})(B,
|
|
2110
|
+
((z = [], vt = []) => {
|
|
2111
|
+
a.value = z, r.value = vt;
|
|
2112
|
+
})(B, C), _({
|
|
2099
2113
|
isEntering: x,
|
|
2100
|
-
values:
|
|
2101
|
-
updatingNodes: (
|
|
2102
|
-
(z) =>
|
|
2114
|
+
values: E,
|
|
2115
|
+
updatingNodes: (nt = (et = l.value) == null ? void 0 : et.nodes) == null ? void 0 : nt.filter(
|
|
2116
|
+
(z) => E.has(R(z))
|
|
2103
2117
|
)
|
|
2104
2118
|
});
|
|
2105
|
-
}),
|
|
2119
|
+
}), N(
|
|
2120
|
+
l,
|
|
2121
|
+
(g) => y({ nodes: g.nodes, links: g.links })
|
|
2122
|
+
), N(
|
|
2106
2123
|
u,
|
|
2107
|
-
(g) =>
|
|
2108
|
-
),
|
|
2109
|
-
c,
|
|
2110
|
-
(g) => s.value.leftExtent = g + K
|
|
2111
|
-
), I(
|
|
2124
|
+
(g) => i.value.leftExtent = g + K
|
|
2125
|
+
), N(
|
|
2112
2126
|
h,
|
|
2113
|
-
(g) =>
|
|
2114
|
-
),
|
|
2115
|
-
|
|
2116
|
-
(g) =>
|
|
2117
|
-
),
|
|
2118
|
-
|
|
2119
|
-
(g) =>
|
|
2120
|
-
),
|
|
2121
|
-
|
|
2122
|
-
(g) =>
|
|
2127
|
+
(g) => i.value.rightExtent = i.value.containerSize.width - (g + K)
|
|
2128
|
+
), N(
|
|
2129
|
+
f,
|
|
2130
|
+
(g) => i.value.bottomExtent = g
|
|
2131
|
+
), N(
|
|
2132
|
+
c,
|
|
2133
|
+
(g) => i.value.topExtent = g
|
|
2134
|
+
), N(
|
|
2135
|
+
i.value.containerSize,
|
|
2136
|
+
(g) => i.value.rightExtent = g.width - (h.value + K)
|
|
2123
2137
|
), {
|
|
2124
|
-
alluvialInstance:
|
|
2125
|
-
computedData:
|
|
2126
|
-
defaultColor:
|
|
2138
|
+
alluvialInstance: i,
|
|
2139
|
+
computedData: s,
|
|
2140
|
+
defaultColor: Xt,
|
|
2127
2141
|
highlightedLinkIds: r,
|
|
2128
2142
|
highlightedNodeIds: a,
|
|
2129
2143
|
isNodeOrLinkFaded: zt,
|
|
@@ -2132,7 +2146,7 @@ const Lr = S({
|
|
|
2132
2146
|
};
|
|
2133
2147
|
}
|
|
2134
2148
|
});
|
|
2135
|
-
var
|
|
2149
|
+
var Ir = function() {
|
|
2136
2150
|
var t = this, n = t._self._c;
|
|
2137
2151
|
return t._self._setupProxy, t.alluvialInstance ? n("g", { staticClass: "lume-alluvial-group", attrs: { "data-j-alluvial-group": "" } }, [t._l(t.alluvialInstance.nodeBlocks, function(r, a) {
|
|
2138
2152
|
return n("g", { key: `node-block_${a}`, staticClass: "lume-alluvial-group__node", class: {
|
|
@@ -2161,17 +2175,17 @@ var wr = function() {
|
|
|
2161
2175
|
}, mouseout: function(r) {
|
|
2162
2176
|
t.alluvialInstance.highlightedLink = null;
|
|
2163
2177
|
} } })], 2) : t._e();
|
|
2164
|
-
},
|
|
2165
|
-
Lr,
|
|
2166
|
-
wr,
|
|
2178
|
+
}, Nr = [], Dr = /* @__PURE__ */ S(
|
|
2167
2179
|
Cr,
|
|
2180
|
+
Ir,
|
|
2181
|
+
Nr,
|
|
2168
2182
|
!1,
|
|
2169
2183
|
null,
|
|
2170
2184
|
"9b0ccc03",
|
|
2171
2185
|
null,
|
|
2172
2186
|
null
|
|
2173
2187
|
);
|
|
2174
|
-
const
|
|
2188
|
+
const Rr = Dr.exports, Pr = {
|
|
2175
2189
|
margins: {
|
|
2176
2190
|
top: 0,
|
|
2177
2191
|
right: 0,
|
|
@@ -2182,13 +2196,13 @@ const Nr = Ir.exports, Rr = {
|
|
|
2182
2196
|
withTooltip: !1,
|
|
2183
2197
|
withHover: !1,
|
|
2184
2198
|
withLegend: !1
|
|
2185
|
-
},
|
|
2186
|
-
components: { LumeChart: Y, LumeAlluvialGroup:
|
|
2199
|
+
}, Er = L({
|
|
2200
|
+
components: { LumeChart: Y, LumeAlluvialGroup: Rr },
|
|
2187
2201
|
props: {
|
|
2188
|
-
...
|
|
2202
|
+
...G(ut, !1, !1)
|
|
2189
2203
|
},
|
|
2190
2204
|
setup(e, t) {
|
|
2191
|
-
const { options: n } =
|
|
2205
|
+
const { options: n } = w(e), { allOptions: r } = F(n, Pr);
|
|
2192
2206
|
function a(o) {
|
|
2193
2207
|
return {
|
|
2194
2208
|
...o,
|
|
@@ -2202,7 +2216,7 @@ const Nr = Ir.exports, Rr = {
|
|
|
2202
2216
|
};
|
|
2203
2217
|
}
|
|
2204
2218
|
});
|
|
2205
|
-
var
|
|
2219
|
+
var Br = function() {
|
|
2206
2220
|
var t = this, n = t._self._c;
|
|
2207
2221
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { options: t.getAlluvialDiagramOptions(t.allOptions), "data-j-alluvial-diagram": "" }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2208
2222
|
return [n("lume-alluvial-group", t._b({}, "lume-alluvial-group", r, !1))];
|
|
@@ -2211,40 +2225,40 @@ var Er = function() {
|
|
|
2211
2225
|
return [t._t(a, null, null, o || {})];
|
|
2212
2226
|
} };
|
|
2213
2227
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2214
|
-
},
|
|
2215
|
-
Dr,
|
|
2228
|
+
}, Mr = [], Hr = /* @__PURE__ */ S(
|
|
2216
2229
|
Er,
|
|
2217
|
-
|
|
2230
|
+
Br,
|
|
2231
|
+
Mr,
|
|
2218
2232
|
!1,
|
|
2219
2233
|
null,
|
|
2220
2234
|
null,
|
|
2221
2235
|
null,
|
|
2222
2236
|
null
|
|
2223
2237
|
);
|
|
2224
|
-
const
|
|
2225
|
-
var
|
|
2226
|
-
const
|
|
2238
|
+
const Va = Hr.exports;
|
|
2239
|
+
var Ut = /* @__PURE__ */ ((e) => (e.grouped = "grouped", e.stacked = "stacked", e))(Ut || {});
|
|
2240
|
+
const Et = {
|
|
2227
2241
|
single: "lume-single-bar-chart",
|
|
2228
2242
|
grouped: "lume-grouped-bar-chart",
|
|
2229
2243
|
stacked: "lume-stacked-bar-chart"
|
|
2230
|
-
},
|
|
2244
|
+
}, jr = L({
|
|
2231
2245
|
components: {
|
|
2232
|
-
LumeSingleBarChart:
|
|
2233
|
-
() => import("./
|
|
2246
|
+
LumeSingleBarChart: ht(
|
|
2247
|
+
() => import("./25ccdedf.js")
|
|
2234
2248
|
),
|
|
2235
|
-
LumeGroupedBarChart:
|
|
2236
|
-
() => import("./
|
|
2249
|
+
LumeGroupedBarChart: ht(
|
|
2250
|
+
() => import("./6f5e659c.js")
|
|
2237
2251
|
),
|
|
2238
|
-
LumeStackedBarChart:
|
|
2239
|
-
() => import("./
|
|
2252
|
+
LumeStackedBarChart: ht(
|
|
2253
|
+
() => import("./97d72066.js")
|
|
2240
2254
|
)
|
|
2241
2255
|
},
|
|
2242
2256
|
props: {
|
|
2243
|
-
...
|
|
2257
|
+
...G(),
|
|
2244
2258
|
type: {
|
|
2245
2259
|
type: String,
|
|
2246
2260
|
default: null,
|
|
2247
|
-
validator: (e) => e in
|
|
2261
|
+
validator: (e) => e in Ut || e == null
|
|
2248
2262
|
}
|
|
2249
2263
|
},
|
|
2250
2264
|
setup(e, t) {
|
|
@@ -2254,20 +2268,20 @@ const Dt = {
|
|
|
2254
2268
|
startOnZero: !0,
|
|
2255
2269
|
tooltipOptions: {
|
|
2256
2270
|
...(a == null ? void 0 : a.tooltipOptions) || {},
|
|
2257
|
-
position: e.orientation ===
|
|
2271
|
+
position: e.orientation === T.HORIZONTAL && "right"
|
|
2258
2272
|
}
|
|
2259
2273
|
};
|
|
2260
2274
|
}
|
|
2261
2275
|
return {
|
|
2262
|
-
component:
|
|
2276
|
+
component: v(() => {
|
|
2263
2277
|
if (!!e.data) {
|
|
2264
|
-
if (
|
|
2265
|
-
return
|
|
2278
|
+
if (ut(e.data))
|
|
2279
|
+
return Et.single;
|
|
2266
2280
|
if (!e.type)
|
|
2267
2281
|
throw new Error(
|
|
2268
2282
|
"Bar chart needs a type when there's multiple datasets."
|
|
2269
2283
|
);
|
|
2270
|
-
return
|
|
2284
|
+
return Et[e.type];
|
|
2271
2285
|
}
|
|
2272
2286
|
}),
|
|
2273
2287
|
getBarChartOptions: n,
|
|
@@ -2275,109 +2289,109 @@ const Dt = {
|
|
|
2275
2289
|
};
|
|
2276
2290
|
}
|
|
2277
2291
|
});
|
|
2278
|
-
var
|
|
2292
|
+
var Fr = function() {
|
|
2279
2293
|
var t = this, n = t._self._c;
|
|
2280
2294
|
return t._self._setupProxy, n(t.component, t._g(t._b({ tag: "component", attrs: { options: t.getBarChartOptions(t.options) }, scopedSlots: t._u([t._l(t.slots, function(r, a) {
|
|
2281
2295
|
return { key: a, fn: function(o) {
|
|
2282
2296
|
return [t._t(a, null, null, o || {})];
|
|
2283
2297
|
} };
|
|
2284
2298
|
})], null, !0) }, "component", t.$props, !1), t.$listeners));
|
|
2285
|
-
},
|
|
2286
|
-
Mr,
|
|
2287
|
-
Hr,
|
|
2299
|
+
}, Vr = [], Gr = /* @__PURE__ */ S(
|
|
2288
2300
|
jr,
|
|
2301
|
+
Fr,
|
|
2302
|
+
Vr,
|
|
2289
2303
|
!1,
|
|
2290
2304
|
null,
|
|
2291
2305
|
null,
|
|
2292
2306
|
null,
|
|
2293
2307
|
null
|
|
2294
2308
|
);
|
|
2295
|
-
const
|
|
2296
|
-
function
|
|
2297
|
-
return Object.values(
|
|
2309
|
+
const Ga = Gr.exports;
|
|
2310
|
+
function zr(e) {
|
|
2311
|
+
return Object.values(we).includes(e) || e == null;
|
|
2298
2312
|
}
|
|
2299
|
-
function
|
|
2300
|
-
return Object.values(
|
|
2313
|
+
function Wr(e) {
|
|
2314
|
+
return Object.values(T).includes(e);
|
|
2301
2315
|
}
|
|
2302
|
-
const
|
|
2316
|
+
const Zr = (e = !1) => ({
|
|
2303
2317
|
type: {
|
|
2304
2318
|
type: String,
|
|
2305
2319
|
default: null,
|
|
2306
|
-
validator:
|
|
2320
|
+
validator: zr
|
|
2307
2321
|
},
|
|
2308
2322
|
...e ? {
|
|
2309
2323
|
orientation: {
|
|
2310
2324
|
type: String,
|
|
2311
|
-
default:
|
|
2312
|
-
validator:
|
|
2325
|
+
default: T.VERTICAL,
|
|
2326
|
+
validator: Wr
|
|
2313
2327
|
}
|
|
2314
2328
|
} : {}
|
|
2315
2329
|
});
|
|
2316
|
-
function
|
|
2317
|
-
const t =
|
|
2330
|
+
function Yt(e) {
|
|
2331
|
+
const t = v(() => e.value.map((r) => ({
|
|
2318
2332
|
...r,
|
|
2319
2333
|
values: r.values.map((a) => ({
|
|
2320
2334
|
...a,
|
|
2321
2335
|
value: (a == null ? void 0 : a.value) || 0
|
|
2322
2336
|
}))
|
|
2323
|
-
}))), n =
|
|
2337
|
+
}))), n = v(() => {
|
|
2324
2338
|
var r;
|
|
2325
|
-
return (r = t.value) == null ? void 0 : r.reduce((a, o) => (o.values.forEach((
|
|
2326
|
-
a[
|
|
2339
|
+
return (r = t.value) == null ? void 0 : r.reduce((a, o) => (o.values.forEach((s, l) => {
|
|
2340
|
+
a[l] ? a[l].push(s) : a[l] = [s];
|
|
2327
2341
|
}), a), []);
|
|
2328
2342
|
});
|
|
2329
2343
|
return { multiBarData: t, groupedData: n };
|
|
2330
2344
|
}
|
|
2331
|
-
function
|
|
2345
|
+
function qr(e, t) {
|
|
2332
2346
|
return e.value.length === 1 ? "single" : t.value;
|
|
2333
2347
|
}
|
|
2334
|
-
function
|
|
2335
|
-
const a =
|
|
2336
|
-
() => r.value ===
|
|
2348
|
+
function Xr(e, t, n, r) {
|
|
2349
|
+
const a = v(
|
|
2350
|
+
() => r.value === T.HORIZONTAL
|
|
2337
2351
|
);
|
|
2338
|
-
function o(
|
|
2339
|
-
Math.min(...
|
|
2352
|
+
function o(i) {
|
|
2353
|
+
Math.min(...i.domain()) > 0 && console.error("Bar linear scale domain cannot start above 0!");
|
|
2340
2354
|
}
|
|
2341
|
-
const
|
|
2342
|
-
const { padding:
|
|
2343
|
-
return a.value ? (() => (o(e.value), e.value))() :
|
|
2355
|
+
const s = v(() => {
|
|
2356
|
+
const { padding: i, paddingInner: u, paddingOuter: h } = n.value;
|
|
2357
|
+
return a.value ? (() => (o(e.value), e.value))() : it(
|
|
2344
2358
|
e.value,
|
|
2345
2359
|
r.value,
|
|
2346
|
-
{ padding:
|
|
2360
|
+
{ padding: i, paddingInner: u, paddingOuter: h }
|
|
2347
2361
|
);
|
|
2348
|
-
}),
|
|
2349
|
-
const { padding:
|
|
2350
|
-
return a.value ?
|
|
2362
|
+
}), l = v(() => {
|
|
2363
|
+
const { padding: i, paddingInner: u, paddingOuter: h } = n.value;
|
|
2364
|
+
return a.value ? it(
|
|
2351
2365
|
t.value,
|
|
2352
2366
|
r.value,
|
|
2353
|
-
{ padding:
|
|
2367
|
+
{ padding: i, paddingInner: u, paddingOuter: h }
|
|
2354
2368
|
) : (() => (o(t.value), t.value))();
|
|
2355
2369
|
});
|
|
2356
|
-
return { barXScale:
|
|
2370
|
+
return { barXScale: s, barYScale: l };
|
|
2357
2371
|
}
|
|
2358
|
-
const
|
|
2359
|
-
function
|
|
2360
|
-
const
|
|
2361
|
-
() => r.value ===
|
|
2372
|
+
const Ur = "skyblue";
|
|
2373
|
+
function Yr(e, t, n, r, a, o) {
|
|
2374
|
+
const s = v(
|
|
2375
|
+
() => r.value === T.HORIZONTAL
|
|
2362
2376
|
);
|
|
2363
|
-
function
|
|
2377
|
+
function l(c, f) {
|
|
2364
2378
|
let p, d;
|
|
2365
|
-
return
|
|
2379
|
+
return s.value ? (p = c >= 0 ? t.value(0) : t.value(c), d = n.value(n.value.domain()[f])) : (p = t.value(t.value.domain()[f]), d = c < 0 ? n.value(0) : n.value(c)), { x: p, y: d };
|
|
2366
2380
|
}
|
|
2367
|
-
function
|
|
2368
|
-
return
|
|
2381
|
+
function i(c) {
|
|
2382
|
+
return s.value ? c < 0 ? t.value(0) - t.value(c) : t.value(c) - t.value(0) : t.value.bandwidth();
|
|
2369
2383
|
}
|
|
2370
|
-
function c
|
|
2371
|
-
return
|
|
2384
|
+
function u(c) {
|
|
2385
|
+
return s.value ? n.value.bandwidth() : c < 0 ? n.value(c) - n.value(0) : n.value(0) - n.value(c);
|
|
2372
2386
|
}
|
|
2373
|
-
function h(
|
|
2374
|
-
var
|
|
2375
|
-
const { value: d, color: _ } =
|
|
2387
|
+
function h(c, f, p) {
|
|
2388
|
+
var O;
|
|
2389
|
+
const { value: d, color: _ } = c, y = (O = _ != null ? _ : e.value[f].color) != null ? O : Ur, { x: m, y: g } = l(d, p), b = i(d), x = u(d);
|
|
2376
2390
|
return {
|
|
2377
|
-
classList: [`lume-fill--${
|
|
2391
|
+
classList: [`lume-fill--${y}`, ...o],
|
|
2378
2392
|
x: m,
|
|
2379
2393
|
y: g,
|
|
2380
|
-
width:
|
|
2394
|
+
width: b,
|
|
2381
2395
|
height: x,
|
|
2382
2396
|
isFaded: a.value !== -1 && a.value !== p,
|
|
2383
2397
|
isNegative: d < 0
|
|
@@ -2385,131 +2399,131 @@ function Xr(e, t, n, r, a, o) {
|
|
|
2385
2399
|
}
|
|
2386
2400
|
return { barAttributeGenerator: h };
|
|
2387
2401
|
}
|
|
2388
|
-
function
|
|
2389
|
-
const
|
|
2390
|
-
() => r.value ===
|
|
2391
|
-
),
|
|
2392
|
-
function
|
|
2393
|
-
if (
|
|
2402
|
+
function Kr(e, t, n, r, a, o) {
|
|
2403
|
+
const s = v(
|
|
2404
|
+
() => r.value === T.HORIZONTAL
|
|
2405
|
+
), l = v(() => J().domain(e.value.map((d, _) => _)).range([0, t.value.bandwidth()]).padding(0)), i = v(() => J().domain(e.value.map((d, _) => _)).range([0, n.value.bandwidth()]).padding(0));
|
|
2406
|
+
function u(d, _, y) {
|
|
2407
|
+
if (s.value)
|
|
2394
2408
|
return d >= 0 ? t.value(0) : t.value(d);
|
|
2395
2409
|
const m = t.value.domain();
|
|
2396
|
-
return t.value(m[_]) +
|
|
2410
|
+
return t.value(m[_]) + l.value(y);
|
|
2397
2411
|
}
|
|
2398
|
-
function h(d, _,
|
|
2399
|
-
if (
|
|
2412
|
+
function h(d, _, y) {
|
|
2413
|
+
if (s.value) {
|
|
2400
2414
|
const m = n.value.domain();
|
|
2401
|
-
return n.value(m[_]) +
|
|
2415
|
+
return n.value(m[_]) + i.value(y);
|
|
2402
2416
|
}
|
|
2403
2417
|
return d < 0 ? n.value(0) : n.value(d);
|
|
2404
2418
|
}
|
|
2405
|
-
function
|
|
2406
|
-
return
|
|
2419
|
+
function c(d) {
|
|
2420
|
+
return s.value ? d < 0 ? t.value(0) - t.value(d) : t.value(d) - t.value(0) : l.value.bandwidth();
|
|
2407
2421
|
}
|
|
2408
|
-
function
|
|
2409
|
-
return
|
|
2422
|
+
function f(d) {
|
|
2423
|
+
return s.value ? i.value.bandwidth() : d < 0 ? n.value(d) - n.value(0) : n.value(0) - n.value(d);
|
|
2410
2424
|
}
|
|
2411
|
-
function p(d, _,
|
|
2412
|
-
var
|
|
2413
|
-
const { value: m, color: g } = d,
|
|
2425
|
+
function p(d, _, y) {
|
|
2426
|
+
var C;
|
|
2427
|
+
const { value: m, color: g } = d, b = (C = g != null ? g : e.value[_].color) != null ? C : Object.values(M)[_], x = u(m, y, _), O = h(m, y, _), E = c(m), B = f(m);
|
|
2414
2428
|
return {
|
|
2415
|
-
classList: [`lume-fill--${
|
|
2429
|
+
classList: [`lume-fill--${b}`, ...o],
|
|
2416
2430
|
x,
|
|
2417
|
-
y:
|
|
2418
|
-
width:
|
|
2431
|
+
y: O,
|
|
2432
|
+
width: E,
|
|
2419
2433
|
height: B,
|
|
2420
|
-
isFaded: a.value !== -1 && a.value !==
|
|
2434
|
+
isFaded: a.value !== -1 && a.value !== y,
|
|
2421
2435
|
isNegative: m < 0
|
|
2422
2436
|
};
|
|
2423
2437
|
}
|
|
2424
2438
|
return { barAttributeGenerator: p };
|
|
2425
2439
|
}
|
|
2426
|
-
function
|
|
2427
|
-
const n =
|
|
2428
|
-
() => t.value ===
|
|
2429
|
-
), r =
|
|
2430
|
-
const
|
|
2431
|
-
(
|
|
2440
|
+
function Jr(e, t) {
|
|
2441
|
+
const n = v(
|
|
2442
|
+
() => t.value === T.HORIZONTAL
|
|
2443
|
+
), r = v(() => {
|
|
2444
|
+
const l = e.value.map(
|
|
2445
|
+
(i) => i.filter((u) => u.value < 0).reduce((u, h) => u + h.value, 0)
|
|
2432
2446
|
);
|
|
2433
|
-
return Math.min(...
|
|
2434
|
-
}), a =
|
|
2435
|
-
const
|
|
2436
|
-
(
|
|
2437
|
-
(
|
|
2447
|
+
return Math.min(...l);
|
|
2448
|
+
}), a = v(() => {
|
|
2449
|
+
const l = e.value.map(
|
|
2450
|
+
(i) => i.reduce(
|
|
2451
|
+
(u, h) => h.value >= 0 ? u + h.value : u,
|
|
2438
2452
|
0
|
|
2439
2453
|
)
|
|
2440
2454
|
);
|
|
2441
|
-
return Math.max(...
|
|
2455
|
+
return Math.max(...l);
|
|
2442
2456
|
});
|
|
2443
|
-
function o(
|
|
2444
|
-
return n.value ? Q().domain([r.value, a.value]).range([0,
|
|
2445
|
-
J().domain(
|
|
2457
|
+
function o(l, i, u) {
|
|
2458
|
+
return n.value ? Q().domain([r.value, a.value]).range([0, u.width]) : it(
|
|
2459
|
+
J().domain(i == null ? void 0 : i.map((h) => h)).range([0, u.width])
|
|
2446
2460
|
);
|
|
2447
2461
|
}
|
|
2448
|
-
function
|
|
2449
|
-
return n.value ?
|
|
2450
|
-
J().domain(
|
|
2451
|
-
) : Q().domain([a.value, r.value]).range([0,
|
|
2462
|
+
function s(l, i, u) {
|
|
2463
|
+
return n.value ? it(
|
|
2464
|
+
J().domain(i == null ? void 0 : i.map((h) => h)).range([0, u.height])
|
|
2465
|
+
) : Q().domain([a.value, r.value]).range([0, u.height]);
|
|
2452
2466
|
}
|
|
2453
|
-
return { stackedXScaleGenerator: o, stackedYScaleGenerator:
|
|
2467
|
+
return { stackedXScaleGenerator: o, stackedYScaleGenerator: s };
|
|
2454
2468
|
}
|
|
2455
|
-
function
|
|
2456
|
-
const
|
|
2457
|
-
() => r.value ===
|
|
2458
|
-
),
|
|
2459
|
-
() =>
|
|
2460
|
-
),
|
|
2469
|
+
function Qr(e, t, n, r, a, o) {
|
|
2470
|
+
const s = v(
|
|
2471
|
+
() => r.value === T.HORIZONTAL
|
|
2472
|
+
), l = v(
|
|
2473
|
+
() => s.value ? n.value.domain() : t.value.domain()
|
|
2474
|
+
), i = v(
|
|
2461
2475
|
() => e.value.map((m) => m.values.map((g) => g == null ? void 0 : g.value))
|
|
2462
2476
|
);
|
|
2463
|
-
function
|
|
2464
|
-
let x,
|
|
2465
|
-
return
|
|
2477
|
+
function u(m, g, b) {
|
|
2478
|
+
let x, O;
|
|
2479
|
+
return s.value ? (x = t.value(m >= 0 ? 0 + b : m + b), O = n.value(l.value[g])) : (x = t.value(l.value[g]), O = n.value(m >= 0 ? m + b : 0 + b)), { x, y: O };
|
|
2466
2480
|
}
|
|
2467
2481
|
function h(m) {
|
|
2468
|
-
return
|
|
2482
|
+
return s.value ? t.value(m) - t.value(0) : t.value.bandwidth();
|
|
2469
2483
|
}
|
|
2470
|
-
function
|
|
2471
|
-
return
|
|
2484
|
+
function c(m) {
|
|
2485
|
+
return s.value ? t.value(0) - t.value(m) : t.value.bandwidth();
|
|
2472
2486
|
}
|
|
2473
|
-
function
|
|
2474
|
-
return
|
|
2487
|
+
function f(m) {
|
|
2488
|
+
return s.value ? n.value.bandwidth() : n.value(0) - n.value(m);
|
|
2475
2489
|
}
|
|
2476
2490
|
function p(m) {
|
|
2477
|
-
return
|
|
2491
|
+
return s.value ? n.value.bandwidth() : n.value(m) - n.value(0);
|
|
2478
2492
|
}
|
|
2479
2493
|
function d(m, g) {
|
|
2480
|
-
return m ?
|
|
2494
|
+
return m ? i.value.reduce((b, x, O) => (O < m && x[g] >= 0 && (b += x[g]), b), 0) : 0;
|
|
2481
2495
|
}
|
|
2482
2496
|
function _(m, g) {
|
|
2483
|
-
return m ?
|
|
2497
|
+
return m ? i.value.reduce((b, x, O) => (O < m && x[g] < 0 && (b += x[g]), b), 0) : 0;
|
|
2484
2498
|
}
|
|
2485
|
-
function
|
|
2499
|
+
function y(m, g, b) {
|
|
2486
2500
|
var j;
|
|
2487
|
-
const { value: x, color:
|
|
2501
|
+
const { value: x, color: O } = m, E = x >= 0 ? h(x) : c(x), B = x >= 0 ? f(x) : p(x), C = x >= 0 ? d(g, b) : _(g, b), { x: k, y: I } = u(x, b, C);
|
|
2488
2502
|
return {
|
|
2489
|
-
classList: [`lume-fill--${(j =
|
|
2490
|
-
width:
|
|
2503
|
+
classList: [`lume-fill--${(j = O != null ? O : e.value[g].color) != null ? j : Object.values(M)[g]}`, ...o],
|
|
2504
|
+
width: E,
|
|
2491
2505
|
height: B,
|
|
2492
|
-
x:
|
|
2493
|
-
y:
|
|
2494
|
-
isFaded: a.value !== -1 && a.value !==
|
|
2506
|
+
x: k,
|
|
2507
|
+
y: I,
|
|
2508
|
+
isFaded: a.value !== -1 && a.value !== b,
|
|
2495
2509
|
isNegative: x < 0
|
|
2496
2510
|
};
|
|
2497
2511
|
}
|
|
2498
|
-
return { barAttributeGenerator:
|
|
2512
|
+
return { barAttributeGenerator: y };
|
|
2499
2513
|
}
|
|
2500
|
-
const
|
|
2501
|
-
single:
|
|
2502
|
-
grouped:
|
|
2503
|
-
stacked:
|
|
2504
|
-
},
|
|
2505
|
-
components: { LumeBar:
|
|
2514
|
+
const ta = {
|
|
2515
|
+
single: Yr,
|
|
2516
|
+
grouped: Kr,
|
|
2517
|
+
stacked: Qr
|
|
2518
|
+
}, ea = L({
|
|
2519
|
+
components: { LumeBar: $t },
|
|
2506
2520
|
props: {
|
|
2507
|
-
|
|
2521
|
+
...kt(),
|
|
2508
2522
|
classList: {
|
|
2509
2523
|
type: [String, Array],
|
|
2510
2524
|
default: () => []
|
|
2511
2525
|
},
|
|
2512
|
-
...
|
|
2526
|
+
...Zr(!0),
|
|
2513
2527
|
transition: {
|
|
2514
2528
|
type: Boolean,
|
|
2515
2529
|
default: !0
|
|
@@ -2522,81 +2536,81 @@ const Jr = {
|
|
|
2522
2536
|
options: r,
|
|
2523
2537
|
orientation: a,
|
|
2524
2538
|
transition: o,
|
|
2525
|
-
type:
|
|
2526
|
-
xScale:
|
|
2527
|
-
yScale:
|
|
2528
|
-
classList:
|
|
2529
|
-
} =
|
|
2530
|
-
|
|
2531
|
-
|
|
2539
|
+
type: s,
|
|
2540
|
+
xScale: l,
|
|
2541
|
+
yScale: i,
|
|
2542
|
+
classList: u
|
|
2543
|
+
} = w(e), { groupedData: h } = Yt(t), { barXScale: c, barYScale: f } = Xr(
|
|
2544
|
+
l,
|
|
2545
|
+
i,
|
|
2532
2546
|
r,
|
|
2533
2547
|
a
|
|
2534
|
-
), p =
|
|
2535
|
-
const
|
|
2548
|
+
), p = v(() => typeof u.value == "string" ? [u.value] : u.value), d = v(() => {
|
|
2549
|
+
const y = qr(t, s), { barAttributeGenerator: m } = ta[y](
|
|
2536
2550
|
t,
|
|
2537
|
-
|
|
2538
|
-
|
|
2551
|
+
c,
|
|
2552
|
+
f,
|
|
2539
2553
|
a,
|
|
2540
2554
|
n,
|
|
2541
2555
|
p.value
|
|
2542
2556
|
);
|
|
2543
2557
|
return m;
|
|
2544
|
-
}), _ =
|
|
2558
|
+
}), _ = v(() => {
|
|
2545
2559
|
if (!!o.value)
|
|
2546
|
-
return a.value ===
|
|
2560
|
+
return a.value === T.HORIZONTAL ? "width" : "height";
|
|
2547
2561
|
});
|
|
2548
2562
|
return {
|
|
2549
|
-
barXScale:
|
|
2550
|
-
barYScale:
|
|
2563
|
+
barXScale: c,
|
|
2564
|
+
barYScale: f,
|
|
2551
2565
|
computedTransition: _,
|
|
2552
2566
|
getBarAttributes: d,
|
|
2553
2567
|
groupedData: h
|
|
2554
2568
|
};
|
|
2555
2569
|
}
|
|
2556
2570
|
});
|
|
2557
|
-
var
|
|
2571
|
+
var na = function() {
|
|
2558
2572
|
var t = this, n = t._self._c;
|
|
2559
2573
|
return t._self._setupProxy, n("g", { staticClass: "lume-bar-group", attrs: { "data-j-bars-group": "" } }, t._l(t.groupedData, function(r, a) {
|
|
2560
|
-
return n("g", { key: a }, t._l(r, function(o,
|
|
2561
|
-
return n("lume-bar", t._b({ key: `bar-${
|
|
2574
|
+
return n("g", { key: a }, t._l(r, function(o, s) {
|
|
2575
|
+
return n("lume-bar", t._b({ key: `bar-${s}`, attrs: { transition: t.computedTransition, "data-j-lume-bar": "" } }, "lume-bar", t.getBarAttributes(o, s, a, r), !1));
|
|
2562
2576
|
}), 1);
|
|
2563
2577
|
}), 0);
|
|
2564
|
-
},
|
|
2565
|
-
Qr,
|
|
2566
|
-
ta,
|
|
2578
|
+
}, ra = [], aa = /* @__PURE__ */ S(
|
|
2567
2579
|
ea,
|
|
2580
|
+
na,
|
|
2581
|
+
ra,
|
|
2568
2582
|
!1,
|
|
2569
2583
|
null,
|
|
2570
2584
|
null,
|
|
2571
2585
|
null,
|
|
2572
2586
|
null
|
|
2573
2587
|
);
|
|
2574
|
-
const
|
|
2575
|
-
[
|
|
2588
|
+
const Lt = aa.exports, oa = {
|
|
2589
|
+
[T.VERTICAL]: {
|
|
2576
2590
|
withTooltip: !0,
|
|
2577
2591
|
xAxisOptions: {},
|
|
2578
2592
|
yAxisOptions: { gridLines: !0 },
|
|
2579
2593
|
margins: Z.VERTICAL
|
|
2580
2594
|
},
|
|
2581
|
-
[
|
|
2595
|
+
[T.HORIZONTAL]: {
|
|
2582
2596
|
withTooltip: !0,
|
|
2583
2597
|
xAxisOptions: { gridLines: !0 },
|
|
2584
2598
|
yAxisOptions: { gridLines: !1 },
|
|
2585
2599
|
margins: Z.HORIZONTAL
|
|
2586
2600
|
}
|
|
2587
|
-
},
|
|
2588
|
-
components: { LumeChart: Y, LumeBarGroup:
|
|
2601
|
+
}, sa = L({
|
|
2602
|
+
components: { LumeChart: Y, LumeBarGroup: Lt },
|
|
2589
2603
|
props: {
|
|
2590
|
-
...
|
|
2604
|
+
...G(ut)
|
|
2591
2605
|
},
|
|
2592
2606
|
setup(e, t) {
|
|
2593
|
-
const { orientation: n, options: r } =
|
|
2594
|
-
() =>
|
|
2607
|
+
const { orientation: n, options: r } = w(e), a = v(
|
|
2608
|
+
() => oa[n.value || T.VERTICAL]
|
|
2595
2609
|
), { allOptions: o } = F(r, a);
|
|
2596
2610
|
return { allOptions: o, slots: q(t.slots) };
|
|
2597
2611
|
}
|
|
2598
2612
|
});
|
|
2599
|
-
var
|
|
2613
|
+
var ia = function() {
|
|
2600
2614
|
var t = this, n = t._self._c;
|
|
2601
2615
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { "chart-type": "single-bar", options: t.allOptions, "data-j-single-bar-chart": "" }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2602
2616
|
return [n("lume-bar-group", t._b({ attrs: { orientation: t.orientation } }, "lume-bar-group", r, !1))];
|
|
@@ -2605,43 +2619,43 @@ var oa = function() {
|
|
|
2605
2619
|
return [t._t(a, null, null, o || {})];
|
|
2606
2620
|
} };
|
|
2607
2621
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2608
|
-
},
|
|
2609
|
-
aa,
|
|
2610
|
-
oa,
|
|
2622
|
+
}, la = [], ua = /* @__PURE__ */ S(
|
|
2611
2623
|
sa,
|
|
2624
|
+
ia,
|
|
2625
|
+
la,
|
|
2612
2626
|
!1,
|
|
2613
2627
|
null,
|
|
2614
2628
|
null,
|
|
2615
2629
|
null,
|
|
2616
2630
|
null
|
|
2617
2631
|
);
|
|
2618
|
-
const
|
|
2619
|
-
[
|
|
2632
|
+
const za = ua.exports, ca = {
|
|
2633
|
+
[T.VERTICAL]: {
|
|
2620
2634
|
withTooltip: !0,
|
|
2621
2635
|
xAxisOptions: {},
|
|
2622
2636
|
yAxisOptions: { gridLines: !0 },
|
|
2623
2637
|
margins: Z.VERTICAL
|
|
2624
2638
|
},
|
|
2625
|
-
[
|
|
2639
|
+
[T.HORIZONTAL]: {
|
|
2626
2640
|
withTooltip: !0,
|
|
2627
2641
|
xAxisOptions: { gridLines: !0 },
|
|
2628
2642
|
yAxisOptions: { gridLines: !1 },
|
|
2629
2643
|
margins: Z.HORIZONTAL,
|
|
2630
|
-
tooltipOptions: { position:
|
|
2644
|
+
tooltipOptions: { position: At[6] }
|
|
2631
2645
|
}
|
|
2632
|
-
},
|
|
2633
|
-
components: { LumeChart: Y, LumeBarGroup:
|
|
2646
|
+
}, da = L({
|
|
2647
|
+
components: { LumeChart: Y, LumeBarGroup: Lt },
|
|
2634
2648
|
props: {
|
|
2635
|
-
...
|
|
2649
|
+
...G()
|
|
2636
2650
|
},
|
|
2637
2651
|
setup(e, t) {
|
|
2638
|
-
const { orientation: n, options: r } =
|
|
2639
|
-
() =>
|
|
2652
|
+
const { orientation: n, options: r } = w(e), a = v(
|
|
2653
|
+
() => ca[n.value || T.VERTICAL]
|
|
2640
2654
|
), { allOptions: o } = F(r, a);
|
|
2641
2655
|
return { allOptions: o, slots: q(t.slots) };
|
|
2642
2656
|
}
|
|
2643
2657
|
});
|
|
2644
|
-
var
|
|
2658
|
+
var fa = function() {
|
|
2645
2659
|
var t = this, n = t._self._c;
|
|
2646
2660
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { "chart-type": "grouped-bar", options: t.allOptions, "data-j-grouped-bar-chart": "" }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2647
2661
|
return [n("lume-bar-group", t._b({ attrs: { type: "grouped" } }, "lume-bar-group", r, !1))];
|
|
@@ -2650,51 +2664,51 @@ var ca = function() {
|
|
|
2650
2664
|
return [t._t(a, null, null, o || {})];
|
|
2651
2665
|
} };
|
|
2652
2666
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2653
|
-
},
|
|
2654
|
-
ua,
|
|
2655
|
-
ca,
|
|
2667
|
+
}, pa = [], va = /* @__PURE__ */ S(
|
|
2656
2668
|
da,
|
|
2669
|
+
fa,
|
|
2670
|
+
pa,
|
|
2657
2671
|
!1,
|
|
2658
2672
|
null,
|
|
2659
2673
|
null,
|
|
2660
2674
|
null,
|
|
2661
2675
|
null
|
|
2662
2676
|
);
|
|
2663
|
-
const
|
|
2664
|
-
[
|
|
2677
|
+
const Wa = va.exports, ha = {
|
|
2678
|
+
[T.VERTICAL]: {
|
|
2665
2679
|
withTooltip: !0,
|
|
2666
2680
|
xAxisOptions: {},
|
|
2667
2681
|
yAxisOptions: { gridLines: !0 },
|
|
2668
2682
|
margins: Z.VERTICAL
|
|
2669
2683
|
},
|
|
2670
|
-
[
|
|
2684
|
+
[T.HORIZONTAL]: {
|
|
2671
2685
|
withTooltip: !0,
|
|
2672
2686
|
xAxisOptions: { gridLines: !0 },
|
|
2673
2687
|
yAxisOptions: { gridLines: !1 },
|
|
2674
2688
|
margins: Z.HORIZONTAL,
|
|
2675
|
-
tooltipOptions: { position:
|
|
2689
|
+
tooltipOptions: { position: At[6] }
|
|
2676
2690
|
}
|
|
2677
|
-
},
|
|
2678
|
-
components: { LumeChart: Y, LumeBarGroup:
|
|
2691
|
+
}, _a = L({
|
|
2692
|
+
components: { LumeChart: Y, LumeBarGroup: Lt },
|
|
2679
2693
|
props: {
|
|
2680
|
-
...
|
|
2694
|
+
...G()
|
|
2681
2695
|
},
|
|
2682
2696
|
setup(e, t) {
|
|
2683
|
-
const { data: n, orientation: r, options: a } =
|
|
2684
|
-
() =>
|
|
2685
|
-
), { allOptions:
|
|
2686
|
-
|
|
2697
|
+
const { data: n, orientation: r, options: a } = w(e), o = v(
|
|
2698
|
+
() => ha[r.value || T.VERTICAL]
|
|
2699
|
+
), { allOptions: s } = F(a, o), { internalData: l } = dt(n), { groupedData: i } = Yt(l), { stackedXScaleGenerator: u, stackedYScaleGenerator: h } = Jr(
|
|
2700
|
+
i,
|
|
2687
2701
|
r
|
|
2688
2702
|
);
|
|
2689
2703
|
return {
|
|
2690
|
-
allOptions:
|
|
2691
|
-
stackedXScaleGenerator:
|
|
2704
|
+
allOptions: s,
|
|
2705
|
+
stackedXScaleGenerator: u,
|
|
2692
2706
|
stackedYScaleGenerator: h,
|
|
2693
2707
|
slots: q(t.slots)
|
|
2694
2708
|
};
|
|
2695
2709
|
}
|
|
2696
2710
|
});
|
|
2697
|
-
var
|
|
2711
|
+
var ma = function() {
|
|
2698
2712
|
var t = this, n = t._self._c;
|
|
2699
2713
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { "chart-type": "stacked-bar", options: t.allOptions, "x-scale": t.stackedXScaleGenerator, "y-scale": t.stackedYScaleGenerator, "data-j-stacked-bar-chart": "" }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2700
2714
|
return [n("lume-bar-group", t._b({ attrs: { type: "stacked" } }, "lume-bar-group", r, !1))];
|
|
@@ -2703,65 +2717,77 @@ var ha = function() {
|
|
|
2703
2717
|
return [t._t(a, null, null, o || {})];
|
|
2704
2718
|
} };
|
|
2705
2719
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2706
|
-
},
|
|
2707
|
-
va,
|
|
2708
|
-
ha,
|
|
2720
|
+
}, ga = [], ya = /* @__PURE__ */ S(
|
|
2709
2721
|
_a,
|
|
2722
|
+
ma,
|
|
2723
|
+
ga,
|
|
2710
2724
|
!1,
|
|
2711
2725
|
null,
|
|
2712
2726
|
null,
|
|
2713
2727
|
null,
|
|
2714
2728
|
null
|
|
2715
2729
|
);
|
|
2716
|
-
const
|
|
2717
|
-
function
|
|
2730
|
+
const Za = ya.exports;
|
|
2731
|
+
function Kt(e) {
|
|
2718
2732
|
function t(o) {
|
|
2719
|
-
let
|
|
2720
|
-
return o == null ? void 0 : o.reduce((
|
|
2733
|
+
let s = null;
|
|
2734
|
+
return o == null ? void 0 : o.reduce((l, i, u) => (i == null || i.value == null ? (s ? s.push(u) : s = [u], u === (o == null ? void 0 : o.length) - 1 && l.push(s)) : s && (l.push(s), s = null), l), []);
|
|
2721
2735
|
}
|
|
2722
|
-
function n(o,
|
|
2723
|
-
const
|
|
2724
|
-
return o >
|
|
2736
|
+
function n(o, s, l, i) {
|
|
2737
|
+
const c = Math.abs(o - s) / (l + 1) * (i + 1);
|
|
2738
|
+
return o > s ? o - c : o + c;
|
|
2725
2739
|
}
|
|
2726
2740
|
function r(o) {
|
|
2727
|
-
return function(
|
|
2741
|
+
return function(l) {
|
|
2728
2742
|
return !!o.find(
|
|
2729
|
-
(
|
|
2743
|
+
(i) => i.includes(l) || i.includes(l - 1)
|
|
2730
2744
|
);
|
|
2731
2745
|
};
|
|
2732
2746
|
}
|
|
2733
|
-
return { computedLineData:
|
|
2734
|
-
const
|
|
2747
|
+
return { computedLineData: v(() => e.value.map((o) => {
|
|
2748
|
+
const s = t(o.values);
|
|
2735
2749
|
return {
|
|
2736
2750
|
...o,
|
|
2737
|
-
isDashed: r(
|
|
2738
|
-
values: o.values.map((
|
|
2739
|
-
var h,
|
|
2740
|
-
const
|
|
2741
|
-
(
|
|
2751
|
+
isDashed: r(s),
|
|
2752
|
+
values: o.values.map((l, i) => {
|
|
2753
|
+
var h, c;
|
|
2754
|
+
const u = s.find(
|
|
2755
|
+
(f) => f.includes(i)
|
|
2742
2756
|
);
|
|
2743
|
-
if (
|
|
2744
|
-
const
|
|
2745
|
-
let d = (h = o.values[
|
|
2757
|
+
if (u) {
|
|
2758
|
+
const f = u[0] - 1, p = u[u.length - 1] + 1;
|
|
2759
|
+
let d = (h = o.values[f]) == null ? void 0 : h.value, _ = (c = o.values[p]) == null ? void 0 : c.value;
|
|
2746
2760
|
return d == null && (d = _), _ == null && (_ = d), {
|
|
2747
2761
|
value: n(
|
|
2748
2762
|
d,
|
|
2749
2763
|
_,
|
|
2750
|
-
|
|
2751
|
-
|
|
2764
|
+
u.length,
|
|
2765
|
+
u.indexOf(i)
|
|
2752
2766
|
),
|
|
2753
2767
|
label: jt
|
|
2754
2768
|
};
|
|
2755
2769
|
}
|
|
2756
|
-
return
|
|
2770
|
+
return l;
|
|
2757
2771
|
})
|
|
2758
2772
|
};
|
|
2759
2773
|
})) };
|
|
2760
2774
|
}
|
|
2761
|
-
|
|
2762
|
-
|
|
2775
|
+
function ba(e, t) {
|
|
2776
|
+
const n = Ot(e) / 2;
|
|
2777
|
+
return (r, a) => e(e.domain()[t + (a - 1)]) + n;
|
|
2778
|
+
}
|
|
2779
|
+
function xa(e, t) {
|
|
2780
|
+
return (n, r) => e(t + (r - 1));
|
|
2781
|
+
}
|
|
2782
|
+
function Ta(e, t, n, r) {
|
|
2783
|
+
return fe().x(
|
|
2784
|
+
U(n) ? ba(n, e) : xa(n, e)
|
|
2785
|
+
).y((o) => r(o))(t);
|
|
2786
|
+
}
|
|
2787
|
+
const Aa = L({
|
|
2788
|
+
components: { LumeLine: qn, LumePoint: Qn },
|
|
2763
2789
|
props: {
|
|
2764
|
-
|
|
2790
|
+
...kt(),
|
|
2765
2791
|
withPoints: {
|
|
2766
2792
|
type: Boolean,
|
|
2767
2793
|
default: !0
|
|
@@ -2772,85 +2798,94 @@ const ga = S({
|
|
|
2772
2798
|
}
|
|
2773
2799
|
},
|
|
2774
2800
|
setup(e) {
|
|
2775
|
-
const { data: t, options: n, xScale: r, yScale: a } =
|
|
2776
|
-
if (t.value.every((
|
|
2801
|
+
const { data: t, options: n, xScale: r, yScale: a } = w(e), o = v(() => {
|
|
2802
|
+
if (t.value.every((p) => p.isDashed))
|
|
2777
2803
|
return t.value;
|
|
2778
|
-
const { computedLineData:
|
|
2779
|
-
return
|
|
2780
|
-
}),
|
|
2804
|
+
const { computedLineData: f } = Kt(t);
|
|
2805
|
+
return f.value;
|
|
2806
|
+
}), s = v(() => {
|
|
2781
2807
|
if (e.hoveredIndex === -1)
|
|
2782
2808
|
return;
|
|
2783
|
-
const
|
|
2809
|
+
const f = Gt(t.value, e.hoveredIndex);
|
|
2784
2810
|
return {
|
|
2785
2811
|
d: `M ${mt(r.value, e.hoveredIndex)},${a.value.range()[1]}
|
|
2786
|
-
V ${a.value(
|
|
2812
|
+
V ${a.value(f)}`
|
|
2787
2813
|
};
|
|
2788
|
-
}),
|
|
2814
|
+
}), l = v(
|
|
2789
2815
|
() => {
|
|
2790
|
-
var
|
|
2791
|
-
return ((
|
|
2816
|
+
var f;
|
|
2817
|
+
return ((f = n.value) == null ? void 0 : f.lineWidth) * 2 || void 0;
|
|
2792
2818
|
}
|
|
2793
2819
|
);
|
|
2794
|
-
function
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2820
|
+
function i(f) {
|
|
2821
|
+
return o.value[f].values;
|
|
2822
|
+
}
|
|
2823
|
+
function u(f, p) {
|
|
2824
|
+
var _, y;
|
|
2825
|
+
const d = f === 0 ? [] : [
|
|
2826
|
+
(_ = i(p)[f - 1]) == null ? void 0 : _.value,
|
|
2827
|
+
(y = i(p)[f]) == null ? void 0 : y.value
|
|
2799
2828
|
];
|
|
2829
|
+
return Ta(
|
|
2830
|
+
f,
|
|
2831
|
+
d,
|
|
2832
|
+
r.value,
|
|
2833
|
+
a.value
|
|
2834
|
+
) || "";
|
|
2800
2835
|
}
|
|
2801
|
-
function
|
|
2802
|
-
var
|
|
2803
|
-
return (
|
|
2836
|
+
function h(f, p) {
|
|
2837
|
+
var d;
|
|
2838
|
+
return (d = i(p)[f]) == null ? void 0 : d.value;
|
|
2804
2839
|
}
|
|
2805
|
-
function
|
|
2806
|
-
return e.hoveredIndex ===
|
|
2840
|
+
function c(f) {
|
|
2841
|
+
return e.hoveredIndex === f;
|
|
2807
2842
|
}
|
|
2808
2843
|
return {
|
|
2809
2844
|
computedGroupData: o,
|
|
2810
|
-
|
|
2811
|
-
getPointValue:
|
|
2812
|
-
isPointActive:
|
|
2813
|
-
overlayLineAttributes:
|
|
2814
|
-
pointRadius:
|
|
2845
|
+
getPathDefinition: u,
|
|
2846
|
+
getPointValue: h,
|
|
2847
|
+
isPointActive: c,
|
|
2848
|
+
overlayLineAttributes: s,
|
|
2849
|
+
pointRadius: l
|
|
2815
2850
|
};
|
|
2816
2851
|
}
|
|
2817
2852
|
});
|
|
2818
|
-
var
|
|
2853
|
+
var Oa = function() {
|
|
2819
2854
|
var t = this, n = t._self._c;
|
|
2820
|
-
return t._self._setupProxy, n("g", { staticClass: "lume-line-group", attrs: { "data-j-lume-line-group": "" } }, [n("path", t._b({ staticClass: "lume-line-group__overlay-line", attrs: { "data-j-lume-line-group__overlay-line": "" } }, "path", t.overlayLineAttributes, !1)), t._l(t.computedGroupData, function(r) {
|
|
2821
|
-
return n("g", { key: r.label, staticClass: "lume-line-group__group" }, [n("g", { staticClass: "lume-line-group__lines" }, t._l(r.values, function(
|
|
2822
|
-
return n("lume-line", { key: `line-${
|
|
2823
|
-
}), 1), t.withPoints ? n("g", { staticClass: "lume-line-group__points", attrs: { "data-j-lume-line-group__points": "" } }, t._l(r.values, function(
|
|
2824
|
-
return n("lume-point", { key: `point-${
|
|
2855
|
+
return t._self._setupProxy, n("g", { staticClass: "lume-line-group", attrs: { "data-j-lume-line-group": "" } }, [n("path", t._b({ staticClass: "lume-line-group__overlay-line", attrs: { "data-j-lume-line-group__overlay-line": "" } }, "path", t.overlayLineAttributes, !1)), t._l(t.computedGroupData, function(r, a) {
|
|
2856
|
+
return n("g", { key: r.label, staticClass: "lume-line-group__group" }, [n("g", { staticClass: "lume-line-group__lines" }, t._l(r.values, function(o, s) {
|
|
2857
|
+
return n("lume-line", { key: `line-${s}`, attrs: { "path-definition": t.getPathDefinition(s, a), color: r.color, dashed: r.isDashed(s), index: s, transition: t.transition, width: t.options.lineWidth, "x-scale": t.xScale } });
|
|
2858
|
+
}), 1), t.withPoints ? n("g", { staticClass: "lume-line-group__points", attrs: { "data-j-lume-line-group__points": "" } }, t._l(r.values, function(o, s) {
|
|
2859
|
+
return n("lume-point", { key: `point-${s}`, attrs: { active: t.isPointActive(s), color: r.color, index: s, radius: t.pointRadius, value: t.getPointValue(s, a), "x-scale": t.xScale, "y-scale": t.yScale } });
|
|
2825
2860
|
}), 1) : t._e()]);
|
|
2826
2861
|
})], 2);
|
|
2827
|
-
},
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2862
|
+
}, $a = [], ka = /* @__PURE__ */ S(
|
|
2863
|
+
Aa,
|
|
2864
|
+
Oa,
|
|
2865
|
+
$a,
|
|
2831
2866
|
!1,
|
|
2832
2867
|
null,
|
|
2833
|
-
"
|
|
2868
|
+
"10fed727",
|
|
2834
2869
|
null,
|
|
2835
2870
|
null
|
|
2836
2871
|
);
|
|
2837
|
-
const
|
|
2872
|
+
const Jt = ka.exports, La = {
|
|
2838
2873
|
margins: Z.VERTICAL,
|
|
2839
2874
|
startOnZero: !0,
|
|
2840
2875
|
withTooltip: !0,
|
|
2841
2876
|
xAxisOptions: {},
|
|
2842
2877
|
yAxisOptions: { gridLines: !0 }
|
|
2843
|
-
},
|
|
2844
|
-
components: { LumeChart: Y, LumeLineGroup:
|
|
2878
|
+
}, Sa = L({
|
|
2879
|
+
components: { LumeChart: Y, LumeLineGroup: Jt },
|
|
2845
2880
|
props: {
|
|
2846
|
-
...
|
|
2881
|
+
...G(null, !1)
|
|
2847
2882
|
},
|
|
2848
2883
|
setup(e, t) {
|
|
2849
|
-
const { options: n } =
|
|
2884
|
+
const { options: n } = w(e), { allOptions: r } = F(n, La);
|
|
2850
2885
|
return { allOptions: r, slots: q(t.slots) };
|
|
2851
2886
|
}
|
|
2852
2887
|
});
|
|
2853
|
-
var
|
|
2888
|
+
var wa = function() {
|
|
2854
2889
|
var t = this, n = t._self._c;
|
|
2855
2890
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { "chart-type": "line", options: t.allOptions, "data-j-lume-line-chart": "" }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2856
2891
|
return [n("lume-line-group", t._b({}, "lume-line-group", r, !1))];
|
|
@@ -2859,28 +2894,28 @@ var Ta = function() {
|
|
|
2859
2894
|
return [t._t(a, null, null, o || {})];
|
|
2860
2895
|
} };
|
|
2861
2896
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2862
|
-
},
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2897
|
+
}, Ca = [], Ia = /* @__PURE__ */ S(
|
|
2898
|
+
Sa,
|
|
2899
|
+
wa,
|
|
2900
|
+
Ca,
|
|
2866
2901
|
!1,
|
|
2867
2902
|
null,
|
|
2868
2903
|
null,
|
|
2869
2904
|
null,
|
|
2870
2905
|
null
|
|
2871
2906
|
);
|
|
2872
|
-
const
|
|
2873
|
-
function
|
|
2874
|
-
return { areaPathDefinition:
|
|
2907
|
+
const qa = Ia.exports;
|
|
2908
|
+
function Na(e) {
|
|
2909
|
+
return { areaPathDefinition: v(
|
|
2875
2910
|
() => function(n, r) {
|
|
2876
2911
|
if (!n || !r)
|
|
2877
2912
|
return;
|
|
2878
2913
|
const a = e.value[0].values;
|
|
2879
|
-
return
|
|
2914
|
+
return pe().x((o, s) => n(s)).y0(r(Math.min(...r.domain()))).y1((o) => r(o.value))(a);
|
|
2880
2915
|
}
|
|
2881
2916
|
) };
|
|
2882
2917
|
}
|
|
2883
|
-
const
|
|
2918
|
+
const Da = {
|
|
2884
2919
|
margins: {
|
|
2885
2920
|
top: 0,
|
|
2886
2921
|
right: 0,
|
|
@@ -2894,37 +2929,37 @@ const La = {
|
|
|
2894
2929
|
tooltipOptions: {
|
|
2895
2930
|
showTitle: !1
|
|
2896
2931
|
}
|
|
2897
|
-
},
|
|
2898
|
-
components: { LumeChart: Y, LumeLineGroup:
|
|
2932
|
+
}, Ra = L({
|
|
2933
|
+
components: { LumeChart: Y, LumeLineGroup: Jt },
|
|
2899
2934
|
props: {
|
|
2900
2935
|
...Wt(null),
|
|
2901
|
-
...
|
|
2936
|
+
...ft()
|
|
2902
2937
|
},
|
|
2903
2938
|
setup(e, t) {
|
|
2904
|
-
const { data: n, options: r } =
|
|
2905
|
-
() => n.value[0].areaColor ||
|
|
2939
|
+
const { data: n, options: r } = w(e), { internalData: a } = dt(n), { allOptions: o } = F(r, Da), { computedLineData: s } = Kt(a), { areaPathDefinition: l } = Na(s), i = v(() => a.value[0].color), u = v(
|
|
2940
|
+
() => n.value[0].areaColor || i.value
|
|
2906
2941
|
);
|
|
2907
|
-
function h(
|
|
2942
|
+
function h(f) {
|
|
2908
2943
|
return {
|
|
2909
|
-
...
|
|
2944
|
+
...f,
|
|
2910
2945
|
noMinSize: !0
|
|
2911
2946
|
};
|
|
2912
2947
|
}
|
|
2913
|
-
function
|
|
2914
|
-
return Q().range([0, d.width]).domain([0,
|
|
2948
|
+
function c(f, p, d) {
|
|
2949
|
+
return Q().range([0, d.width]).domain([0, f[0].values.length - 1]);
|
|
2915
2950
|
}
|
|
2916
2951
|
return {
|
|
2917
2952
|
allOptions: o,
|
|
2918
|
-
areaColor:
|
|
2919
|
-
areaPathDefinition:
|
|
2920
|
-
computedColor:
|
|
2953
|
+
areaColor: u,
|
|
2954
|
+
areaPathDefinition: l,
|
|
2955
|
+
computedColor: i,
|
|
2921
2956
|
getSparklineOptions: h,
|
|
2922
|
-
xScaleGenerator:
|
|
2957
|
+
xScaleGenerator: c,
|
|
2923
2958
|
slots: q(t.slots)
|
|
2924
2959
|
};
|
|
2925
2960
|
}
|
|
2926
2961
|
});
|
|
2927
|
-
var
|
|
2962
|
+
var Pa = function() {
|
|
2928
2963
|
var t = this, n = t._self._c;
|
|
2929
2964
|
return t._self._setupProxy, n("lume-chart", t._b({ attrs: { "chart-type": "line", options: t.getSparklineOptions(t.allOptions), "x-scale": t.xScaleGenerator }, scopedSlots: t._u([{ key: "groups", fn: function(r) {
|
|
2930
2965
|
return [t.allOptions.showArea ? n("path", { class: [
|
|
@@ -2937,36 +2972,36 @@ var Ca = function() {
|
|
|
2937
2972
|
return [t._t(a, null, null, o || {})];
|
|
2938
2973
|
} };
|
|
2939
2974
|
})], null, !0) }, "lume-chart", t.$props, !1));
|
|
2940
|
-
},
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2975
|
+
}, Ea = [], Ba = /* @__PURE__ */ S(
|
|
2976
|
+
Ra,
|
|
2977
|
+
Pa,
|
|
2978
|
+
Ea,
|
|
2944
2979
|
!1,
|
|
2945
2980
|
null,
|
|
2946
2981
|
"76a94ce0",
|
|
2947
2982
|
null,
|
|
2948
2983
|
null
|
|
2949
2984
|
);
|
|
2950
|
-
const
|
|
2985
|
+
const Xa = Ba.exports;
|
|
2951
2986
|
export {
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2987
|
+
mn as L,
|
|
2988
|
+
Ga as a,
|
|
2989
|
+
za as b,
|
|
2990
|
+
Wa as c,
|
|
2991
|
+
Za as d,
|
|
2992
|
+
qa as e,
|
|
2993
|
+
Xa as f,
|
|
2959
2994
|
Y as g,
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
2967
|
-
|
|
2968
|
-
|
|
2969
|
-
|
|
2970
|
-
|
|
2995
|
+
On as h,
|
|
2996
|
+
wn as i,
|
|
2997
|
+
Rn as j,
|
|
2998
|
+
$t as k,
|
|
2999
|
+
Va as l,
|
|
3000
|
+
qn as m,
|
|
3001
|
+
Qn as n,
|
|
3002
|
+
Rr as o,
|
|
3003
|
+
Lt as p,
|
|
3004
|
+
Jt as q,
|
|
3005
|
+
ar as r
|
|
2971
3006
|
};
|
|
2972
|
-
//# sourceMappingURL=
|
|
3007
|
+
//# sourceMappingURL=55f09e14.js.map
|