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