@adyen/lume 0.3.3 → 0.4.0

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.
@@ -0,0 +1,2632 @@
1
+ import { defineComponent as $, ref as L, isRef as We, computed as c, watch as C, toRefs as R, reactive as re, onMounted as B, onBeforeUnmount as Ze, watchEffect as Xe, useSlots as j, provide as Re, defineAsyncComponent as ce, inject as kt } from "vue";
2
+ import { sankeyLinkHorizontal as At, sankey as Ot, sankeyJustify as Tt } from "d3-sankey";
3
+ import { format as Lt, ticks as xt, scaleBand as J, scaleLinear as Q, line as $t, area as wt } from "d3";
4
+ import { createPopper as It } from "@popperjs/core";
5
+ const Dt = /* @__PURE__ */ $({
6
+ __name: "lume-tick",
7
+ props: {
8
+ value: {
9
+ type: [String, Number],
10
+ required: !0
11
+ },
12
+ group: {
13
+ type: Object,
14
+ required: !0
15
+ },
16
+ ghost: {
17
+ type: Object,
18
+ required: !0
19
+ },
20
+ label: {
21
+ type: Object,
22
+ required: !0
23
+ },
24
+ gridline: {
25
+ type: Object,
26
+ required: !0
27
+ },
28
+ isHovered: {
29
+ type: Boolean,
30
+ default: !1
31
+ },
32
+ isHidden: {
33
+ type: Boolean,
34
+ default: !1
35
+ },
36
+ withGridlines: {
37
+ type: Boolean,
38
+ default: !0
39
+ }
40
+ },
41
+ emits: ["click", "mouseenter"],
42
+ setup(t, { expose: e, emit: r }) {
43
+ const n = L(null);
44
+ return e({ ref: n }), { __sfc: !0, emit: r, labelRef: n };
45
+ }
46
+ });
47
+ function w(t, e, r, n, a, o, u, i) {
48
+ var l = typeof t == "function" ? t.options : t;
49
+ e && (l.render = e, l.staticRenderFns = r, l._compiled = !0), n && (l.functional = !0), o && (l._scopeId = "data-v-" + o);
50
+ var s;
51
+ if (u ? (s = function(f) {
52
+ f = f || // cached call
53
+ this.$vnode && this.$vnode.ssrContext || // stateful
54
+ 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(u);
55
+ }, l._ssrRegister = s) : a && (s = i ? function() {
56
+ a.call(
57
+ this,
58
+ (l.functional ? this.parent : this).$root.$options.shadowRoot
59
+ );
60
+ } : a), s)
61
+ if (l.functional) {
62
+ l._injectStyles = s;
63
+ var v = l.render;
64
+ l.render = function(g, _) {
65
+ return s.call(_), v(g, _);
66
+ };
67
+ } else {
68
+ var d = l.beforeCreate;
69
+ l.beforeCreate = d ? [].concat(d, s) : [s];
70
+ }
71
+ return {
72
+ exports: t,
73
+ options: l
74
+ };
75
+ }
76
+ var Rt = function() {
77
+ var e = this, r = e._self._c, n = e._self._setupProxy;
78
+ return r("g", e._b({ staticClass: "axis__tick", class: {
79
+ "axis__tick--hovered": e.isHovered,
80
+ "axis__tick--hidden": e.isHidden
81
+ }, attrs: { "data-j-axis__tick": "" }, on: { mouseenter: function(a) {
82
+ return n.emit("mouseenter", a);
83
+ }, click: function(a) {
84
+ return n.emit("click", a);
85
+ } } }, "g", e.group, !1), [r("g", { staticClass: "axis__tick-label lume-typography--axis", attrs: { "pointer-events": "all", "data-j-axis__tick-label": "" } }, [r("rect", e._b({ staticClass: "axis__ghost", attrs: { fill: "url(#lume-tick-gradient)" } }, "rect", e.ghost, !1)), r("text", e._b({ ref: "labelRef", staticClass: "axis__label" }, "text", e.label, !1), [e._v(" " + e._s(e.value) + " ")])]), e.withGridlines ? r("line", e._b({ staticClass: "axis__grid-line" }, "line", e.gridline, !1)) : e._e()]);
86
+ }, Ct = [], Et = /* @__PURE__ */ w(
87
+ Dt,
88
+ Rt,
89
+ Ct,
90
+ !1,
91
+ null,
92
+ "59ddc0a6",
93
+ null,
94
+ null
95
+ );
96
+ const Nt = Et.exports;
97
+ function Ye() {
98
+ return process.env.NODE_ENV === "production";
99
+ }
100
+ function Ue(t) {
101
+ return (t == null ? void 0 : t.map(
102
+ (e) => e.values.map((r) => r == null ? void 0 : r.value).flat()
103
+ ).flat()) || [];
104
+ }
105
+ function ye(t) {
106
+ return t.length === 1;
107
+ }
108
+ function Pt(t) {
109
+ return !!t && t.every(
110
+ (e) => "color" in e
111
+ );
112
+ }
113
+ function de(t) {
114
+ return !!t && typeof t == "object" && !Array.isArray(t);
115
+ }
116
+ function Ke(t, e) {
117
+ const r = { ...t };
118
+ return Object.entries(e).forEach(([n, a]) => {
119
+ r[n] = de(t[n]) && de(a) ? Ke(t[n], a) : a;
120
+ }), r;
121
+ }
122
+ function Gt(t) {
123
+ return t != null && de(t) && "value" in t;
124
+ }
125
+ function W(t) {
126
+ return (t == null ? void 0 : t.bandwidth) !== void 0;
127
+ }
128
+ function be(t) {
129
+ return W(t) ? t.bandwidth() : Math.max(...t.range()) / Math.max(...t.domain());
130
+ }
131
+ const St = (t, e) => {
132
+ if (!t)
133
+ throw new Error("Data is not a valid array");
134
+ if (t.length === 0)
135
+ throw new Error("Cannot get highest value from empty array");
136
+ t.forEach(({ values: r }) => {
137
+ if (r.length - 1 < e)
138
+ throw new Error("Index exceeds length of at least one of the datasets");
139
+ });
140
+ };
141
+ function Ht(t, e) {
142
+ var r;
143
+ return St(t, e), ((r = t.reduce(
144
+ (n, a) => {
145
+ var o, u;
146
+ return (((o = n.values[e]) == null ? void 0 : o.value) ?? 0) > (((u = a.values[e]) == null ? void 0 : u.value) ?? 0) ? n : a;
147
+ }
148
+ ).values[e]) == null ? void 0 : r.value) || 0;
149
+ }
150
+ function ve(t) {
151
+ const e = We(t) ? t.value : t;
152
+ if (!e)
153
+ throw new Error("No empty array can be created from specified data value");
154
+ const r = Math.max(
155
+ ...e.map((n) => n.values.length),
156
+ 0
157
+ );
158
+ return Array(r).fill(null);
159
+ }
160
+ function Bt(t) {
161
+ return W(t) ? t.domain().length : Math.max(...t.domain());
162
+ }
163
+ function jt(t, e) {
164
+ return (r) => Math.round(t * (1 - r) + e * r);
165
+ }
166
+ function Vt(t, e, r) {
167
+ const n = r ? t.length - e : e, a = t.slice(0, n);
168
+ return t.slice(n).concat(a);
169
+ }
170
+ function Z(t) {
171
+ if (t.groups) {
172
+ const e = Object.keys(t);
173
+ return Object.assign(
174
+ {},
175
+ ...e.map((r) => r !== "groups" ? { [r]: t[r] } : {})
176
+ );
177
+ }
178
+ return t;
179
+ }
180
+ const Ft = (t = 21) => crypto.getRandomValues(new Uint8Array(t)).reduce(
181
+ (e, r) => e += (r &= 63) < 36 ? r.toString(36) : r < 62 ? (r - 26).toString(36).toUpperCase() : r > 62 ? "-" : "_",
182
+ ""
183
+ );
184
+ var q = /* @__PURE__ */ ((t) => (t.DatasetLength = `Our guidelines highly recommend not having more than 5 datasets in one chart.
185
+ Learn more: https://lume.design/guidelines/datasets`, t.ColorLoop = "Colors will loop around after the 5th dataset. You can prevent this by setting specific colors for your datasets.", t.InvalidFormat = "The string provided to format is invalid. Please refer to https://github.com/d3/d3-format for valid arguments.", t.NotContainedInSvg = "This component is an `SVGElement`, thus it is required to be inside an `<svg>` container.", t))(q || {});
186
+ const Mt = "[lume] ";
187
+ function ae(t, e = !0) {
188
+ e && Ye() || console.warn(Mt + "Warning: " + t);
189
+ }
190
+ const ke = (t) => {
191
+ let e = null;
192
+ switch (typeof t) {
193
+ case "string":
194
+ try {
195
+ e = Lt(t);
196
+ } catch {
197
+ ae(q.InvalidFormat), e = null;
198
+ }
199
+ break;
200
+ case "function":
201
+ e = t;
202
+ break;
203
+ default:
204
+ e = null;
205
+ }
206
+ function r(n) {
207
+ return e ? e(n) : n;
208
+ }
209
+ return r;
210
+ }, oe = () => ({
211
+ options: {
212
+ type: Object,
213
+ default: () => ({})
214
+ }
215
+ });
216
+ function H(t, e) {
217
+ return { allOptions: c(() => {
218
+ const n = We(e) ? e == null ? void 0 : e.value : e;
219
+ return n ? Ke(n, t.value) : t.value;
220
+ }) };
221
+ }
222
+ const zt = 0.15;
223
+ function Wt(t, e, r) {
224
+ const n = L(), a = c(() => Math.max(...t.value.range())), o = c(() => e.value.length);
225
+ function u() {
226
+ if (!e.value)
227
+ return;
228
+ const l = e.value.reduce(
229
+ (v, d) => v + d.ref.getBoundingClientRect().width,
230
+ 0
231
+ ), s = Math.ceil(l / o.value);
232
+ n.value = s + s * zt;
233
+ }
234
+ function i(l) {
235
+ if (!e.value)
236
+ return !0;
237
+ const s = e.value.length;
238
+ if (l === 0)
239
+ return !0;
240
+ const v = a.value / s, d = typeof r == "number" && r > 0 && r + 1 || Math.ceil(n.value / v);
241
+ return l % d === 0;
242
+ }
243
+ return C(e, u), { showTick: i };
244
+ }
245
+ var G = /* @__PURE__ */ ((t) => (t.Skyblue = "skyblue", t.Royalblue = "royalblue", t.Violet = "violet", t.Darkteal = "darkteal", t.Gold = "gold", t))(G || {}), Je = /* @__PURE__ */ ((t) => (t.Skyblue10 = "skyblue-10", t.Skyblue20 = "skyblue-20", t.Skyblue30 = "skyblue-30", t.Skyblue40 = "skyblue-40", t.Skyblue50 = "skyblue-50", t.Skyblue60 = "skyblue-60", t.Skyblue70 = "skyblue-70", t.Skyblue80 = "skyblue-80", t.Skyblue90 = "skyblue-90", t.Skyblue100 = "skyblue-100", t.Royalblue10 = "royalblue-10", t.Royalblue20 = "royalblue-20", t.Royalblue30 = "royalblue-30", t.Royalblue40 = "royalblue-40", t.Royalblue50 = "royalblue-50", t.Royalblue60 = "royalblue-60", t.Royalblue70 = "royalblue-70", t.Royalblue80 = "royalblue-80", t.Royalblue90 = "royalblue-90", t.Royalblue100 = "royalblue-100", t.Violet10 = "violet-10", t.Violet20 = "violet-20", t.Violet30 = "violet-30", t.Violet40 = "violet-40", t.Violet50 = "violet-50", t.Violet60 = "violet-60", t.Violet70 = "violet-70", t.Violet80 = "violet-80", t.Violet90 = "violet-90", t.Violet100 = "violet-100", t.Darkteal10 = "darkteal-10", t.Darkteal20 = "darkteal-20", t.Darkteal30 = "darkteal-30", t.Darkteal40 = "darkteal-40", t.Darkteal50 = "darkteal-50", t.Darkteal60 = "darkteal-60", t.Darkteal70 = "darkteal-70", t.Darkteal80 = "darkteal-80", t.Darkteal90 = "darkteal-90", t.Darkteal100 = "darkteal-100", t.Gold10 = "gold-10", t.Gold20 = "gold-20", t.Gold30 = "gold-30", t.Gold40 = "gold-40", t.Gold50 = "gold-50", t.Gold60 = "gold-60", t.Gold70 = "gold-70", t.Gold80 = "gold-80", t.Gold90 = "gold-90", t.Gold100 = "gold-100", t))(Je || {}), Ae = /* @__PURE__ */ ((t) => (t.SkyTeal = "skyblue-darkteal", t.VioletRoyal = "violet-royalblue", t.VioletTeal = "violet-darkteal", t.GoldTeal = "gold-darkteal", t.GoldRoyal = "gold-royalblue", t))(Ae || {}), Qe = /* @__PURE__ */ ((t) => (t.Grey = "grey", t.Green = "green", t.Orange = "orange", t.Red = "red", t))(Qe || {}), Oe = /* @__PURE__ */ ((t) => (t["01"] = "01", t["02"] = "02", t["03"] = "03", t["04"] = "04", t["05"] = "05", t["06"] = "06", t["07"] = "07", t["08"] = "08", t["09"] = "09", t))(Oe || {});
246
+ const A = {
247
+ HORIZONTAL: "horizontal",
248
+ VERTICAL: "vertical"
249
+ }, Zt = {
250
+ SINGLE: "single",
251
+ GROUPED: "grouped",
252
+ STACKED: "stacked"
253
+ }, z = {
254
+ VERTICAL: {
255
+ top: 16,
256
+ right: 0,
257
+ bottom: 28,
258
+ left: 24
259
+ },
260
+ HORIZONTAL: {
261
+ top: 16,
262
+ right: 0,
263
+ bottom: 28,
264
+ left: 24
265
+ }
266
+ }, qe = "No data", Xt = 20, Yt = 0.33, Ut = 0.5, et = 12, tt = 8, Kt = 1, Jt = [
267
+ "auto",
268
+ "auto-start",
269
+ "auto-end",
270
+ "top",
271
+ "top-start",
272
+ "top-end",
273
+ "right",
274
+ "right-start",
275
+ "right-end",
276
+ "bottom",
277
+ "bottom-start",
278
+ "bottom-end",
279
+ "left",
280
+ "left-start",
281
+ "left-end"
282
+ ];
283
+ function ue(t) {
284
+ t != null && t.closest("svg") || ae(q.NotContainedInSvg);
285
+ }
286
+ const nt = {
287
+ /** Displays a line for each tick. */
288
+ gridLines: !1,
289
+ /** Displays the axis title. */
290
+ withTitle: !0,
291
+ //
292
+ //// Tick settings
293
+ //
294
+ /** Controls if the tick labels should be displayed. */
295
+ showTicks: !0,
296
+ /** Amount of ticks to display in the axis. */
297
+ tickCount: 10,
298
+ /** Formatting string/function for the tick label. */
299
+ tickFormat: null,
300
+ /** Space between the tick label and the axis line. */
301
+ tickPadding: 8
302
+ }, Qt = {
303
+ ...nt,
304
+ withTitle: !1,
305
+ skip: !0
306
+ }, qt = {
307
+ ...nt,
308
+ gridLines: !0
309
+ }, en = function(t, e, r) {
310
+ const n = c(() => t.value.step() * t.value.paddingInner() / 2);
311
+ function a(l, s) {
312
+ return {
313
+ transform: `translate(${(t.value(s) ?? t.value(l)) - n.value}, 0)`
314
+ };
315
+ }
316
+ function o(l) {
317
+ var v;
318
+ const s = Math.max(
319
+ t.value.step(),
320
+ (l ? (v = l.getComputedTextLength) == null ? void 0 : v.call(l) : t.value.step()) + 20
321
+ );
322
+ return {
323
+ x: -(s - t.value.step()) / 2,
324
+ width: s,
325
+ height: r.value.tickPadding + et + tt
326
+ };
327
+ }
328
+ function u() {
329
+ const l = t.value.step() / 2;
330
+ return {
331
+ x1: l,
332
+ x2: l,
333
+ y1: -e.value.height
334
+ // Negative height means it goes from bottom to top
335
+ };
336
+ }
337
+ function i() {
338
+ return {
339
+ x: t.value.step() / 2,
340
+ y: r.value.tickPadding,
341
+ dy: "0.8em",
342
+ "text-anchor": "middle"
343
+ };
344
+ }
345
+ return {
346
+ getGridLinesAttributes: u,
347
+ getTickGhostAttributes: o,
348
+ getTickGroupAttributes: a,
349
+ getTickLabelAttributes: i
350
+ };
351
+ }, tn = function(t, e, r) {
352
+ const n = c(() => t.value.step() * t.value.paddingInner() / 2);
353
+ function a(l, s) {
354
+ return {
355
+ transform: `translate(0, ${(t.value(s) ?? t.value(l)) - n.value})`
356
+ };
357
+ }
358
+ function o(l) {
359
+ var v;
360
+ const s = (l ? (v = l.getComputedTextLength) == null ? void 0 : v.call(l) : 42) + r.value.tickPadding * 2;
361
+ return {
362
+ x: -s,
363
+ width: s,
364
+ height: t.value.step()
365
+ };
366
+ }
367
+ function u() {
368
+ const l = t.value.step() / 2;
369
+ return {
370
+ y1: l,
371
+ y2: l,
372
+ x1: e.value.width
373
+ };
374
+ }
375
+ function i() {
376
+ return {
377
+ x: -r.value.tickPadding,
378
+ y: t.value.step() / 2,
379
+ "text-anchor": "end",
380
+ "alignment-baseline": "middle"
381
+ };
382
+ }
383
+ return {
384
+ getGridLinesAttributes: u,
385
+ getTickGhostAttributes: o,
386
+ getTickGroupAttributes: a,
387
+ getTickLabelAttributes: i
388
+ };
389
+ }, nn = function(t, e, r) {
390
+ const n = c(() => {
391
+ const l = t.value.ticks();
392
+ return t.value(l[1]) - t.value(l[0]);
393
+ });
394
+ function a(l) {
395
+ return {
396
+ transform: `translate(${t.value(l)}, 0)`
397
+ };
398
+ }
399
+ function o() {
400
+ return {
401
+ height: r.value.tickPadding + et + tt,
402
+ width: n.value,
403
+ x: -(n.value / 2)
404
+ };
405
+ }
406
+ function u() {
407
+ return {
408
+ y1: -e.value.height
409
+ };
410
+ }
411
+ function i() {
412
+ return {
413
+ y: r.value.tickPadding,
414
+ dy: "0.8em",
415
+ "text-anchor": "middle"
416
+ };
417
+ }
418
+ return {
419
+ getGridLinesAttributes: u,
420
+ getTickGhostAttributes: o,
421
+ getTickGroupAttributes: a,
422
+ getTickLabelAttributes: i
423
+ };
424
+ }, rn = function(t, e, r) {
425
+ const n = c(() => {
426
+ const l = t.value.ticks();
427
+ return t.value(l[1]) - t.value(l[0]);
428
+ });
429
+ function a(l) {
430
+ return {
431
+ transform: `translate(0, ${t.value(l)})`
432
+ };
433
+ }
434
+ function o(l) {
435
+ var v;
436
+ const s = (((v = l == null ? void 0 : l.getComputedTextLength) == null ? void 0 : v.call(l)) || 0) + r.value.tickPadding * 2;
437
+ return {
438
+ width: s,
439
+ height: n.value,
440
+ x: -s,
441
+ y: -(n.value / 2)
442
+ };
443
+ }
444
+ function u() {
445
+ return {
446
+ x1: e.value.width
447
+ };
448
+ }
449
+ function i() {
450
+ return {
451
+ x: -r.value.tickPadding,
452
+ dy: "0.4em",
453
+ "text-anchor": "end"
454
+ };
455
+ }
456
+ return {
457
+ getGridLinesAttributes: u,
458
+ getTickGhostAttributes: o,
459
+ getTickGroupAttributes: a,
460
+ getTickLabelAttributes: i
461
+ };
462
+ }, an = {
463
+ "x-band-scale-axis": en,
464
+ "y-band-scale-axis": tn,
465
+ "x-linear-scale-axis": nn,
466
+ "y-linear-scale-axis": rn
467
+ };
468
+ var _e = /* @__PURE__ */ ((t) => (t.bandScale = "band-scale-axis", t.linearScale = "linear-scale-axis", t))(_e || {}), pe = /* @__PURE__ */ ((t) => (t.left = "left", t.bottom = "bottom", t))(pe || {}), ee = /* @__PURE__ */ ((t) => (t.x = "bottom", t.y = "left", t))(ee || {});
469
+ const on = /* @__PURE__ */ $({
470
+ __name: "lume-axis",
471
+ props: {
472
+ scale: {
473
+ type: Function,
474
+ required: !0
475
+ },
476
+ type: {
477
+ type: String,
478
+ default: void 0,
479
+ validator: (t) => t in ee
480
+ },
481
+ position: {
482
+ type: String,
483
+ default: void 0,
484
+ validator: (t) => t in pe
485
+ },
486
+ containerSize: {
487
+ type: Object,
488
+ default: () => ({ width: 0, height: 0 })
489
+ },
490
+ hoveredIndex: {
491
+ type: Number,
492
+ default: -1
493
+ },
494
+ orientation: {
495
+ type: String,
496
+ default: A.VERTICAL
497
+ },
498
+ ...oe()
499
+ },
500
+ emits: ["mouseenter", "click", "mouseleave"],
501
+ setup(t, { emit: e }) {
502
+ const r = t, { scale: n, containerSize: a, hoveredIndex: o, options: u, orientation: i } = R(r), l = re({}), s = L(null), v = L(null), d = L(null), f = c(
503
+ () => r.type ? ee[r.type] : r.position
504
+ ), g = c(
505
+ () => r.type || (f.value === "left" ? "y" : "x")
506
+ ), _ = c(
507
+ () => g.value === "x" && i.value === A.VERTICAL || g.value === "y" && i.value === A.HORIZONTAL
508
+ ), { allOptions: p } = H(
509
+ u,
510
+ g.value === "x" ? Qt : qt
511
+ ), { showTick: O } = Wt(n, s, p.value.skip), h = c(
512
+ () => {
513
+ var x;
514
+ return `translate(0, ${g.value === "x" ? (x = a.value) == null ? void 0 : x.height : 0})`;
515
+ }
516
+ ), b = c(() => {
517
+ if (W(n.value))
518
+ return n.value.labels || n.value.domain();
519
+ const { tickCount: x } = p.value, [D, S] = n.value.domain();
520
+ return xt(D, S, x);
521
+ }), y = c(() => {
522
+ const { tickFormat: x } = p.value;
523
+ return ke(x);
524
+ }), m = c(
525
+ () => p.value.withHover && _.value && o.value > -1
526
+ );
527
+ function T(x) {
528
+ const { showTicks: D } = p.value;
529
+ return D === !1 ? "" : y.value(x);
530
+ }
531
+ function E(x, D, S) {
532
+ e("mouseenter", { index: _.value ? x : null, value: D, event: S });
533
+ }
534
+ function I(x, D, S) {
535
+ e("click", { index: x, value: D, event: S });
536
+ }
537
+ function N(x) {
538
+ if (!(!s.value || !s.value.length))
539
+ return s.value[x].ref;
540
+ }
541
+ function V() {
542
+ d.value = b.value.map(
543
+ (x, D) => ({
544
+ value: T(x),
545
+ group: l.getTickGroupAttributes(x, D),
546
+ ghost: l.getTickGhostAttributes(N(D)),
547
+ label: l.getTickLabelAttributes(),
548
+ gridline: l.getGridLinesAttributes()
549
+ })
550
+ );
551
+ }
552
+ function Y() {
553
+ const x = n.value.step ? "bandScale" : "linearScale", D = an[`${g.value}-${_e[x]}`];
554
+ Object.entries(D(n, a, p) || []).forEach(
555
+ ([S, se]) => {
556
+ l[S] = se;
557
+ }
558
+ );
559
+ }
560
+ return C(n, Y, { flush: "sync", immediate: !0 }), C(n, V, { immediate: !0 }), C(s, V), B(() => ue(v.value)), { __sfc: !0, SCALE_MIXIN_MAP: _e, POSITIONS: pe, TYPES: ee, props: r, emit: e, scale: n, containerSize: a, hoveredIndex: o, options: u, orientation: i, mixins: l, tickRefs: s, root: v, ticksWithAttributes: d, computedPosition: f, computedType: g, shouldHover: _, allOptions: p, showTick: O, axisTransform: h, ticks: b, tickFormatter: y, isHovering: m, formatTick: T, handleTickMouseenter: E, handleTickClick: I, getTextNode: N, setTicks: V, init: Y, LumeTick: Nt };
561
+ }
562
+ });
563
+ var un = function() {
564
+ var e = this, r = e._self._c, n = e._self._setupProxy;
565
+ return n.scale ? r("g", { ref: "root", staticClass: "axis", attrs: { transform: n.axisTransform, "data-j-axis": "" }, on: { mouseleave: function(a) {
566
+ return n.emit("mouseleave", a);
567
+ } } }, [n.computedType === "x" ? r("defs", [r("linearGradient", { attrs: { id: "lume-tick-gradient" } }, [r("stop", { attrs: { offset: "0%", "stop-color": "rgba(255,255,255,0)" } }), r("stop", { attrs: { offset: "10%", "stop-color": "var(--lume-chart-background-color)" } }), r("stop", { attrs: { offset: "90%", "stop-color": "var(--lume-chart-background-color)" } }), r("stop", { attrs: { offset: "100%", "stop-color": "rgba(255,255,255,0)" } })], 1)], 1) : e._e(), e._l(n.ticksWithAttributes, function(a, o) {
568
+ return r(n.LumeTick, e._b({ key: `${a.value}_${o}`, ref: "tickRefs", refInFor: !0, attrs: { "is-hidden": n.allOptions.skip && !n.showTick(o), "with-gridlines": n.allOptions.gridLines }, on: { mouseenter: function(u) {
569
+ return n.handleTickMouseenter(o, a.value, u);
570
+ }, click: function(u) {
571
+ return n.handleTickClick(o, a.value, u);
572
+ } } }, "lume-tick", a, !1));
573
+ }), n.isHovering ? r(n.LumeTick, e._b({ attrs: { "with-gridlines": !1, "is-hovered": "" }, on: { click: function(a) {
574
+ return n.handleTickClick(
575
+ n.hoveredIndex,
576
+ n.ticksWithAttributes[n.hoveredIndex].value,
577
+ a
578
+ );
579
+ } } }, "lume-tick", n.ticksWithAttributes[n.hoveredIndex], !1)) : e._e()], 2) : e._e();
580
+ }, ln = [], sn = /* @__PURE__ */ w(
581
+ on,
582
+ un,
583
+ ln,
584
+ !1,
585
+ null,
586
+ null,
587
+ null,
588
+ null
589
+ );
590
+ const cn = sn.exports;
591
+ function dn(t, e, r, n) {
592
+ const a = c(() => r.value > 0 && r.value < 1), o = c(
593
+ () => n.value > 0 && n.value < 1
594
+ ), u = c(
595
+ () => a.value ? t.value - 0.5 : t.value
596
+ // draws the 1px bar closer to the axis
597
+ ), i = c(
598
+ () => o.value ? e.value - 0.5 : e.value
599
+ // draws the 1px bar closer to the axis
600
+ );
601
+ return { computedX: u, computedY: i, shouldHaveMinWidth: a, shouldHaveMinHeight: o };
602
+ }
603
+ function vn(t, e, r, n) {
604
+ const a = L(0), o = L(0), u = c(() => `${t.value + r.value / 2}px ${e.value + n.value / 2}px`);
605
+ return B(() => {
606
+ a.value = r.value, o.value = n.value;
607
+ }), C(r, (i) => a.value = i), C(n, (i) => o.value = i), { computedWidth: a, computedHeight: o, transformOrigin: u };
608
+ }
609
+ const _n = /* @__PURE__ */ $({
610
+ __name: "lume-bar",
611
+ props: {
612
+ x: {
613
+ type: Number,
614
+ default: 0
615
+ },
616
+ y: {
617
+ type: Number,
618
+ default: 0
619
+ },
620
+ width: {
621
+ type: Number,
622
+ required: !0
623
+ },
624
+ height: {
625
+ type: Number,
626
+ required: !0
627
+ },
628
+ classList: {
629
+ type: [String, Array],
630
+ default: ""
631
+ },
632
+ isFaded: {
633
+ type: Boolean,
634
+ default: !1
635
+ },
636
+ isNegative: {
637
+ type: Boolean,
638
+ default: !1
639
+ },
640
+ transition: {
641
+ type: [String, Boolean],
642
+ default: !1
643
+ }
644
+ },
645
+ emits: ["click", "mouseover", "mouseleave"],
646
+ setup(t, { emit: e }) {
647
+ const r = t, { x: n, y: a, width: o, height: u, transition: i, classList: l } = R(r), s = L(null), v = c(
648
+ () => typeof l.value == "string" ? [l.value] : l.value
649
+ ), d = c(() => i.value === "width"), f = c(() => i.value === "height"), g = vn(n, a, o, u), { computedX: _, computedY: p, shouldHaveMinWidth: O, shouldHaveMinHeight: h } = dn(n, a, o, u), b = c(() => O.value ? 1 : (d.value ? g.computedWidth : o).value), y = c(() => h.value ? 1 : (f.value ? g.computedHeight : u).value), m = d.value || f.value ? g.transformOrigin : null;
650
+ return B(() => ue(s.value)), { __sfc: !0, props: r, emit: e, x: n, y: a, width: o, height: u, transition: i, classList: l, root: s, computedClasses: v, shouldTransitionWidth: d, shouldTransitionHeight: f, transitionProps: g, computedX: _, computedY: p, shouldHaveMinWidth: O, shouldHaveMinHeight: h, computedWidth: b, computedHeight: y, transformOrigin: m };
651
+ }
652
+ });
653
+ var pn = function() {
654
+ var e = this, r = e._self._c, n = e._self._setupProxy;
655
+ return r("rect", { ref: "root", staticClass: "lume-bar", class: [
656
+ {
657
+ "lume-fill--faded": e.isFaded,
658
+ "lume-bar--negative": e.isNegative,
659
+ "lume-bar--transition-width": n.shouldTransitionWidth,
660
+ "lume-bar--transition-height": n.shouldTransitionHeight
661
+ },
662
+ ...n.computedClasses
663
+ ], style: { transformOrigin: n.transformOrigin }, attrs: { x: n.computedX, y: n.computedY, width: n.computedWidth, height: n.computedHeight, "data-j-bar": "" }, on: { click: function(a) {
664
+ return n.emit("click", a);
665
+ }, mouseover: function(a) {
666
+ return n.emit("mouseover", a);
667
+ }, mouseleave: function(a) {
668
+ return n.emit("mouseleave", a);
669
+ } } });
670
+ }, fn = [], mn = /* @__PURE__ */ w(
671
+ _n,
672
+ pn,
673
+ fn,
674
+ !1,
675
+ null,
676
+ "8e8f732a",
677
+ null,
678
+ null
679
+ );
680
+ const Te = mn.exports;
681
+ function hn() {
682
+ const t = L(), e = re({
683
+ dimensions: {}
684
+ }), r = new ResizeObserver((n) => {
685
+ n.forEach((a) => {
686
+ e.dimensions = a.contentRect;
687
+ });
688
+ });
689
+ return B(() => {
690
+ r.observe(t.value);
691
+ }), Ze(() => {
692
+ r.unobserve(t.value);
693
+ }), { resizeState: e, resizeRef: t };
694
+ }
695
+ const gn = /* @__PURE__ */ $({
696
+ __name: "lume-chart-container",
697
+ props: {
698
+ margins: {
699
+ type: Object,
700
+ default: () => ({})
701
+ },
702
+ containerSize: {
703
+ type: Object,
704
+ default: () => ({ width: 0, height: 0 })
705
+ },
706
+ transparentBackground: {
707
+ type: Boolean,
708
+ default: !1
709
+ },
710
+ noMinSize: {
711
+ type: Boolean,
712
+ default: !1
713
+ }
714
+ },
715
+ emits: ["click", "mouseenter", "mouseleave", "resize"],
716
+ setup(t, { emit: e }) {
717
+ const r = t, n = {
718
+ left: 0,
719
+ right: 0,
720
+ top: 0,
721
+ bottom: 0
722
+ }, { margins: a, containerSize: o } = R(r), u = L(null), { resizeRef: i, resizeState: l } = hn(), s = c(() => ({
723
+ ...n,
724
+ // Default values
725
+ ...a.value
726
+ // Prop overrides
727
+ })), v = c(
728
+ () => o.value.height + s.value.top + s.value.bottom
729
+ );
730
+ return Xe(() => {
731
+ if (!u.value)
732
+ return;
733
+ const { width: d } = l.dimensions, { height: f } = u.value.getBoundingClientRect();
734
+ if (!d || !f)
735
+ return;
736
+ const g = d - s.value.left - s.value.right, _ = f - s.value.top - s.value.bottom, p = {
737
+ width: g > 0 ? g : 0,
738
+ height: _ > 0 ? _ : 0,
739
+ outerWidth: d,
740
+ outerHeight: f
741
+ };
742
+ e("resize", p);
743
+ }), { __sfc: !0, BASE_MARGINS: n, props: r, emit: e, margins: a, containerSize: o, root: u, resizeRef: i, resizeState: l, computedMargins: s, svgHeight: v };
744
+ }
745
+ });
746
+ var yn = function() {
747
+ var e = this, r = e._self._c, n = e._self._setupProxy;
748
+ return r("div", { ref: "resizeRef", staticClass: "lume-chart-container", class: {
749
+ "lume-chart-container--minimum": !e.noMinSize
750
+ }, attrs: { "data-j-chart-container": "" } }, [e._t("header"), r("svg", { ref: "root", staticClass: "lume-chart-container__svg", class: {
751
+ "lume-chart-container__svg--transparent": e.transparentBackground
752
+ }, attrs: { height: n.svgHeight, "data-j-chart-container__root": "" }, on: { click: function(a) {
753
+ return n.emit("click", a);
754
+ }, mouseenter: function(a) {
755
+ return n.emit("mouseenter", a);
756
+ }, mouseleave: function(a) {
757
+ return n.emit("mouseleave", a);
758
+ } } }, [r("g", { staticClass: "lume-chart-container__group", attrs: { transform: `translate(${n.computedMargins.left}, ${n.computedMargins.top})`, "data-j-chart-container__group": "" } }, [e._t("default")], 2)]), e._t("footer"), e._t("extra")], 2);
759
+ }, bn = [], kn = /* @__PURE__ */ w(
760
+ gn,
761
+ yn,
762
+ bn,
763
+ !1,
764
+ null,
765
+ "d53fd184",
766
+ null,
767
+ null
768
+ );
769
+ const An = kn.exports, On = /* @__PURE__ */ $({
770
+ __name: "lume-chart-legend",
771
+ props: {
772
+ data: {
773
+ type: Array,
774
+ validator: Pt,
775
+ required: !0
776
+ }
777
+ },
778
+ emits: ["click", "mouseenter", "mouseleave"],
779
+ setup(t, { emit: e }) {
780
+ return { __sfc: !0, emit: e };
781
+ }
782
+ });
783
+ var Tn = function() {
784
+ var e = this, r = e._self._c, n = e._self._setupProxy;
785
+ return r("div", { staticClass: "lume-chart-legend", attrs: { "data-j-chart-legend": "" }, on: { mouseleave: function(a) {
786
+ return n.emit("mouseleave");
787
+ } } }, e._l(e.data, function(a, o) {
788
+ return r("div", { key: `legend-item-${o}`, staticClass: "lume-chart-legend__item lume-typography--body", attrs: { tabindex: "0", "data-j-chart-legend__symbol-wrapper": "" }, on: { click: function(u) {
789
+ return n.emit("click", { index: o, dataset: a, event: u });
790
+ }, mouseenter: function(u) {
791
+ return n.emit("mouseenter", { index: o, dataset: a, event: u });
792
+ } } }, [r("span", { staticClass: "lume-chart-legend__symbol", class: `lume-background-color--${a.color}`, attrs: { "data-j-chart-legend__symbol": "" } }), e._v(" " + e._s(a.label || o) + " ")]);
793
+ }), 0);
794
+ }, Ln = [], xn = /* @__PURE__ */ w(
795
+ On,
796
+ Tn,
797
+ Ln,
798
+ !1,
799
+ null,
800
+ "f8ebd3b9",
801
+ null,
802
+ null
803
+ );
804
+ const $n = xn.exports, wn = /* @__PURE__ */ $({
805
+ __name: "lume-tooltip",
806
+ props: {
807
+ targetElement: {
808
+ type: Element,
809
+ default: null
810
+ },
811
+ items: {
812
+ type: Array,
813
+ required: !0
814
+ },
815
+ position: {
816
+ type: String,
817
+ default: "auto",
818
+ validator: (t) => Jt.includes(t)
819
+ },
820
+ fixedPositioning: {
821
+ type: Boolean,
822
+ default: !1
823
+ },
824
+ modifiers: {
825
+ type: Array,
826
+ default: null
827
+ },
828
+ title: {
829
+ type: [String, Number],
830
+ default: null
831
+ },
832
+ summary: {
833
+ type: String,
834
+ default: null
835
+ },
836
+ ...oe()
837
+ },
838
+ emits: ["opened", "moved", "closed"],
839
+ setup(t, { emit: e }) {
840
+ const r = t, n = L(null), { items: a, options: o } = R(r), u = L(null), { allOptions: i } = H(o), l = c(
841
+ () => i.value.fixedPositioning ?? r.fixedPositioning
842
+ ), s = c(
843
+ () => l.value ? "fixed" : "absolute"
844
+ ), v = c(() => [
845
+ {
846
+ name: "computeStyles",
847
+ options: {
848
+ adaptive: !1
849
+ // so that we can have smooth transitions
850
+ }
851
+ },
852
+ {
853
+ name: "offset",
854
+ options: { offset: [0, i.value.offset || 8] }
855
+ },
856
+ ...r.modifiers || []
857
+ ]), d = c(
858
+ () => i.value.showTitle !== !1 && r.title != null
859
+ ), f = c(() => ke(i.value.valueFormat)), g = c(
860
+ () => {
861
+ var h;
862
+ return ((h = a.value) == null ? void 0 : h.find((b) => b.isSummary)) || {
863
+ label: i.value.summary ?? r.summary
864
+ };
865
+ }
866
+ );
867
+ function _() {
868
+ r.targetElement && n.value && (u.value = It(r.targetElement, n.value, {
869
+ placement: r.position,
870
+ strategy: s.value,
871
+ modifiers: v.value
872
+ }), e("opened", r.targetElement));
873
+ }
874
+ function p() {
875
+ u.value && (u.value.destroy(), e("closed"));
876
+ }
877
+ function O() {
878
+ u.value && (n.value.classList.add("lume-tooltip--animated"), r.targetElement ? function() {
879
+ u.value.state.elements.reference = r.targetElement, u.value.update(), e("moved", r.targetElement);
880
+ }() : p());
881
+ }
882
+ return C(
883
+ () => r.targetElement,
884
+ (h, b) => {
885
+ !b && h ? _() : O();
886
+ }
887
+ ), B(_), Ze(p), { __sfc: !0, props: r, emit: e, root: n, items: a, options: o, popper: u, allOptions: i, computedFixedPositioning: l, strategy: s, allModifiers: v, showTitle: d, formatValue: f, summaryItem: g, initPopper: _, destroyPopper: p, updatePopper: O };
888
+ }
889
+ });
890
+ var In = function() {
891
+ var e = this, r = e._self._c, n = e._self._setupProxy;
892
+ return r("div", { directives: [{ name: "show", rawName: "v-show", value: e.targetElement, expression: "targetElement" }], ref: "root", staticClass: "lume-tooltip lume-typography--caption", attrs: { "data-j-tooltip": "" } }, [e._t("default", function() {
893
+ return [n.showTitle ? r("div", { staticClass: "lume-tooltip__title", attrs: { "data-j-tooltip__title": "" } }, [e._v(" " + e._s(e.title) + " ")]) : e._e(), r("ul", { staticClass: "lume-tooltip__items" }, [n.summaryItem.label ? [r("li", { staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__summary-item": "" } }, [r("span", [e._v(" " + e._s(n.summaryItem.label) + " ")]), n.summaryItem.value ? r("strong", { staticClass: "lume-tooltip__value" }, [e._v(" " + e._s(n.formatValue(n.summaryItem.value)) + " ")]) : e._e()]), e._m(0)] : e._e(), e._l(n.items, function(a) {
894
+ return r("li", { key: a.label, staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__item": "" } }, [r("span", { staticClass: "lume-tooltip__symbol", class: [`lume-background-color--${a.color}`], attrs: { "data-j-tooltip__item__symbol": "" } }), r("span", { attrs: { "data-j-tooltip__item__label": "" } }, [e._v(" " + e._s(a.label) + " ")]), r("strong", { staticClass: "lume-tooltip__value", attrs: { "data-j-tooltip__item__value": "" } }, [e._v(" " + e._s(n.formatValue(a.value)) + " ")])]);
895
+ })], 2)];
896
+ })], 2);
897
+ }, Dn = [function() {
898
+ var t = this, e = t._self._c;
899
+ return t._self._setupProxy, e("li", { staticClass: "lume-tooltip__break" }, [e("hr")]);
900
+ }], Rn = /* @__PURE__ */ w(
901
+ wn,
902
+ In,
903
+ Dn,
904
+ !1,
905
+ null,
906
+ "2c5936cf",
907
+ null,
908
+ null
909
+ );
910
+ const Cn = Rn.exports;
911
+ var M = /* @__PURE__ */ ((t) => (t.Categorical = "categorical", t.Sequential = "sequential", t.Divergent = "divergent", t))(M || {});
912
+ const En = M.Categorical, le = G.Skyblue, Nn = Ae.SkyTeal;
913
+ function Pn(t) {
914
+ return t === M.Divergent ? Nn : le;
915
+ }
916
+ function Gn(t) {
917
+ return Object.values(Oe).includes(t);
918
+ }
919
+ function Ce(t, e) {
920
+ return e === M.Divergent ? Object.values(Ae).includes(t) : Object.values({
921
+ ...G,
922
+ ...Je,
923
+ ...Qe,
924
+ ...Oe
925
+ }).includes(t);
926
+ }
927
+ function Sn(t, e) {
928
+ const r = Object.values(G).indexOf(t);
929
+ return Vt(Object.values(G), r > -1 ? r : 0)[e];
930
+ }
931
+ function Hn(t, e) {
932
+ const r = 50 + e * 10;
933
+ return `${t}-${r}`;
934
+ }
935
+ function Bn(t, e) {
936
+ const r = (e + 1) * 10;
937
+ return `${t}-${r}`;
938
+ }
939
+ function Ee(t, e, r) {
940
+ switch (e) {
941
+ default:
942
+ case M.Categorical:
943
+ return Gn(t) ? t : Sn(t, r);
944
+ case M.Sequential:
945
+ return Hn(t, r);
946
+ case M.Divergent:
947
+ return Bn(t, r);
948
+ }
949
+ }
950
+ function jn(t, e, r = En, n) {
951
+ return Ce(t, r) ? t : (n > 4 && (ae(q.ColorLoop), n = n % 5), Ce(e, r) ? Ee(e, r, n) : Ee(Pn(r), r, n));
952
+ }
953
+ function Vn(t) {
954
+ return t.map((e) => Gt(e) ? e : { value: e });
955
+ }
956
+ function Fn(t) {
957
+ return t.__internal === !0;
958
+ }
959
+ const rt = (t = null) => ({
960
+ data: {
961
+ type: Array,
962
+ required: !0,
963
+ validator: t || void 0
964
+ },
965
+ labels: {
966
+ type: Array,
967
+ default: void 0
968
+ },
969
+ color: {
970
+ type: String,
971
+ default: G.Skyblue
972
+ }
973
+ });
974
+ function Le(t, e, r, n, a) {
975
+ const o = re({
976
+ width: 0,
977
+ height: 0
978
+ }), u = Ft(12), i = c(() => {
979
+ var v;
980
+ return t.value.length > 5 && ae(q.DatasetLength), (v = t.value) == null ? void 0 : v.map(
981
+ (d, f) => {
982
+ if (Fn(d))
983
+ return d;
984
+ const g = Vn(d.values), _ = jn(
985
+ d.color,
986
+ r == null ? void 0 : r.value,
987
+ n == null ? void 0 : n.value.colorPalette,
988
+ f
989
+ );
990
+ return {
991
+ ...d,
992
+ values: g,
993
+ color: _,
994
+ __internal: !0
995
+ };
996
+ }
997
+ );
998
+ }), l = c(() => Array.isArray(e.value) ? e.value : ve(t.value).map((v, d) => d));
999
+ function s(v) {
1000
+ const d = (a == null ? void 0 : a.value) === A.HORIZONTAL ? ve(t).length * (Xt * 2) : v.height;
1001
+ o.width = v.width, o.height = d;
1002
+ }
1003
+ return {
1004
+ chartID: u,
1005
+ computedLabels: l,
1006
+ containerSize: o,
1007
+ internalData: i,
1008
+ updateSize: s
1009
+ };
1010
+ }
1011
+ const Mn = () => ({
1012
+ xScale: {
1013
+ type: Function,
1014
+ default: null
1015
+ },
1016
+ yScale: {
1017
+ type: Function,
1018
+ default: null
1019
+ }
1020
+ });
1021
+ function zn(t, e, r, n, a) {
1022
+ const o = L(null), u = L(null);
1023
+ function i() {
1024
+ const { width: l, height: s } = r;
1025
+ !l && !s || !e.value || !t.value || (n.value === A.HORIZONTAL ? (o.value = Pe(
1026
+ t.value,
1027
+ l,
1028
+ n.value,
1029
+ a.value.startOnZero
1030
+ ), u.value = Ne(e.value, s)) : (o.value = Ne(e.value, l), u.value = Pe(
1031
+ t.value,
1032
+ s,
1033
+ n.value,
1034
+ a.value.startOnZero
1035
+ )));
1036
+ }
1037
+ return Xe(i), { xScale: o, yScale: u };
1038
+ }
1039
+ function Ne(t, e) {
1040
+ const r = [0, e];
1041
+ return Object.assign(
1042
+ J().range(r).domain(t.map((n, a) => a)),
1043
+ { labels: t }
1044
+ );
1045
+ }
1046
+ function Pe(t, e, r, n) {
1047
+ const a = Ue(t).filter((v) => v != null), o = [0, e];
1048
+ if (a.length === 0)
1049
+ return Q().range(o).domain([0, 0]).nice();
1050
+ const u = Math.min(...a), i = n && u > 0 ? 0 : u, l = Math.max(...a), s = r === A.HORIZONTAL ? [i, l] : [l, i];
1051
+ return Q().range(o).domain(s).nice();
1052
+ }
1053
+ function Ge(t) {
1054
+ return (t == null ? void 0 : t.range) !== void 0 || (t == null ? void 0 : t.copy) !== void 0;
1055
+ }
1056
+ function fe(t, e) {
1057
+ return W(t) ? t.bandwidth() / 2 + t(t.domain()[e]) : t(e);
1058
+ }
1059
+ function te(t, e, {
1060
+ padding: r,
1061
+ paddingInner: n,
1062
+ paddingOuter: a
1063
+ } = {}) {
1064
+ const o = r ?? (e === A.HORIZONTAL ? Ut : Yt);
1065
+ return t.copy().paddingInner(n ?? o).paddingOuter(a ?? o / 2);
1066
+ }
1067
+ function at(t) {
1068
+ return Object.values(A).includes(t);
1069
+ }
1070
+ const X = (t, e = !0, r = !0) => ({
1071
+ ...rt(t),
1072
+ ...r ? Mn() : {},
1073
+ ...oe(),
1074
+ title: {
1075
+ type: String,
1076
+ default: null
1077
+ },
1078
+ ...e ? {
1079
+ orientation: {
1080
+ type: String,
1081
+ default: A.VERTICAL,
1082
+ validator: at
1083
+ }
1084
+ } : {},
1085
+ classList: {
1086
+ type: [String, Array],
1087
+ default: () => []
1088
+ }
1089
+ }), ie = () => ({
1090
+ data: {
1091
+ type: Array,
1092
+ required: !0
1093
+ },
1094
+ labels: {
1095
+ type: Array,
1096
+ default: () => []
1097
+ },
1098
+ options: {
1099
+ type: Object,
1100
+ default: () => ({})
1101
+ },
1102
+ orientation: {
1103
+ type: String,
1104
+ default: A.VERTICAL,
1105
+ validator: at
1106
+ },
1107
+ xScale: {
1108
+ type: Function,
1109
+ default: () => null
1110
+ },
1111
+ yScale: {
1112
+ type: Function,
1113
+ default: () => null
1114
+ },
1115
+ hoveredIndex: {
1116
+ type: Number,
1117
+ default: -1
1118
+ },
1119
+ containerSize: {
1120
+ type: Object,
1121
+ default: () => ({ width: 0, height: 0 })
1122
+ },
1123
+ transition: {
1124
+ type: Boolean,
1125
+ default: !0
1126
+ },
1127
+ classList: {
1128
+ type: [String, Array],
1129
+ default: () => []
1130
+ }
1131
+ }), Wn = /* @__PURE__ */ $({
1132
+ __name: "lume-overlay-group",
1133
+ props: {
1134
+ ...ie(),
1135
+ orientation: {
1136
+ type: String,
1137
+ default: A.VERTICAL
1138
+ }
1139
+ },
1140
+ emits: ["click", "lume__internal--hover", "mouseover"],
1141
+ setup(t, { emit: e }) {
1142
+ const r = t, { data: n, orientation: a, xScale: o, yScale: u } = R(r), i = c(() => ve(n));
1143
+ function l(s) {
1144
+ const v = a.value === A.HORIZONTAL ? u.value : o.value, d = v.domain(), f = be(v), g = W(v) ? v(d[s]) : v(s) - f / 2;
1145
+ return a.value === A.HORIZONTAL ? {
1146
+ width: Math.max(...o.value.range()),
1147
+ height: f,
1148
+ transform: `translate(0, ${g})`
1149
+ } : {
1150
+ width: f,
1151
+ height: Math.max(...u.value.range()),
1152
+ transform: `translate(${g}, 0)`
1153
+ };
1154
+ }
1155
+ return { __sfc: !0, props: r, emit: e, data: n, orientation: a, xScale: o, yScale: u, overlayData: i, getOverlayBarAttributes: l, LumeBar: Te };
1156
+ }
1157
+ });
1158
+ var Zn = function() {
1159
+ var e = this, r = e._self._c, n = e._self._setupProxy;
1160
+ return r("g", { staticClass: "lume-overlay-group" }, e._l(n.overlayData, function(a, o) {
1161
+ return r(n.LumeBar, e._b({ key: `overlay-${o}`, attrs: { "data-j-lume-overlay-group": o, transition: !1, "class-list": "lume-fill--transparent" }, on: { mouseenter: function(u) {
1162
+ return n.emit("lume__internal--hover", o);
1163
+ }, click: function(u) {
1164
+ return n.emit("click", { index: o, event: u });
1165
+ } } }, "lume-bar", n.getOverlayBarAttributes(o), !1));
1166
+ }), 1);
1167
+ }, Xn = [], Yn = /* @__PURE__ */ w(
1168
+ Wn,
1169
+ Zn,
1170
+ Xn,
1171
+ !1,
1172
+ null,
1173
+ null,
1174
+ null,
1175
+ null
1176
+ );
1177
+ const Un = Yn.exports;
1178
+ function Kn(t) {
1179
+ return { hasNegativeValues: c(
1180
+ () => Ue(t.value).some((r) => r < 0)
1181
+ ) };
1182
+ }
1183
+ function Jn(t, e, r, n) {
1184
+ const a = c(
1185
+ () => n.value === A.HORIZONTAL
1186
+ ), o = c(
1187
+ () => {
1188
+ var s;
1189
+ return t.height - (a != null && a.value ? 0 : ((s = r.value) == null ? void 0 : s.call(r, 0)) || 0);
1190
+ }
1191
+ ), u = c(
1192
+ () => {
1193
+ var s;
1194
+ return a != null && a.value ? ((s = e.value) == null ? void 0 : s.call(e, 0)) || 0 : t.width;
1195
+ }
1196
+ ), i = c(
1197
+ () => {
1198
+ var s;
1199
+ return a != null && a.value ? "translate(0, 0)" : `translate(0, ${((s = r.value) == null ? void 0 : s.call(r, 0)) || 0})`;
1200
+ }
1201
+ );
1202
+ return { negativeBarAttributes: c(() => ({
1203
+ width: u.value,
1204
+ height: o.value,
1205
+ transform: i.value
1206
+ })) };
1207
+ }
1208
+ function Qn(t) {
1209
+ return t.reduce((e, r) => r.values.map((n, a) => e[a] ? n.value > e[a] ? n.value : e[a] : n.value ?? 0), []);
1210
+ }
1211
+ function qn(t) {
1212
+ return t.reduce((e, r) => r.values.map((n, a) => e[a] ? n.value + e[a] : n.value ?? 0), []);
1213
+ }
1214
+ const Se = {
1215
+ "stacked-bar": qn
1216
+ };
1217
+ function ot(t, e, r, n, a, o, u) {
1218
+ const i = c(
1219
+ () => {
1220
+ var s;
1221
+ return e.value.withTooltip !== !1 && !((s = e.value.tooltipOptions) != null && s.targetElement);
1222
+ }
1223
+ );
1224
+ function l(s) {
1225
+ const v = u != null && u.value && Se[u.value] ? Se[u.value](s) : Qn(s);
1226
+ t.value = v.map((d, f) => ({
1227
+ cx: (a == null ? void 0 : a.value) === A.HORIZONTAL ? r.value(d) : fe(r.value, f),
1228
+ cy: (a == null ? void 0 : a.value) === A.HORIZONTAL ? fe(n.value, f) : n.value(d)
1229
+ }));
1230
+ }
1231
+ return C(
1232
+ [r, n],
1233
+ () => {
1234
+ r.value && n.value && (o != null && o.value) && i.value && l(o.value);
1235
+ },
1236
+ { immediate: !0 }
1237
+ ), { shouldGenerateTooltipAnchors: i, updateTooltipAnchorAttributes: l };
1238
+ }
1239
+ function er() {
1240
+ const t = re({
1241
+ opened: !1,
1242
+ targetElement: null
1243
+ });
1244
+ return { tooltipConfig: t, showTooltip: (n) => {
1245
+ t.opened = !0, t.targetElement = n;
1246
+ }, hideTooltip: () => {
1247
+ t.opened = !1, t.targetElement = null;
1248
+ } };
1249
+ }
1250
+ function tr(t) {
1251
+ return { getTooltipItems: c(
1252
+ () => (r) => t.value.map(({ color: n, label: a, values: o }) => {
1253
+ var u, i, l;
1254
+ return {
1255
+ color: ((u = o[r]) == null ? void 0 : u.color) || n,
1256
+ label: a,
1257
+ value: ((i = o[r]) == null ? void 0 : i.label) ?? ((l = o[r]) == null ? void 0 : l.value) ?? qe
1258
+ };
1259
+ })
1260
+ ) };
1261
+ }
1262
+ const nr = /* @__PURE__ */ $({
1263
+ __name: "lume-chart",
1264
+ props: {
1265
+ ...X(),
1266
+ chartType: {
1267
+ type: String,
1268
+ default: null
1269
+ }
1270
+ },
1271
+ setup(t, { emit: e }) {
1272
+ const r = t, n = j(), a = Kt, { data: o, labels: u, color: i, options: l, orientation: s, chartType: v } = R(r), d = L(-1), f = L(null), g = L(null), _ = L([]), { allOptions: p } = H(l), { internalData: O, computedLabels: h, containerSize: b, updateSize: y, chartID: m } = Le(o, u, i, p, s), { xScale: T, yScale: E } = zn(
1273
+ O,
1274
+ h,
1275
+ b,
1276
+ s,
1277
+ p
1278
+ ), I = c(() => {
1279
+ var k;
1280
+ return r.xScale ? Ge(r.xScale) ? r.xScale : (k = r.xScale) == null ? void 0 : k.call(r, O.value, u.value, b) : T.value;
1281
+ }), N = c(() => {
1282
+ var k;
1283
+ return r.yScale ? Ge(r.yScale) ? r.yScale : (k = r.yScale) == null ? void 0 : k.call(r, O.value, u.value, b) : E.value;
1284
+ }), V = c(() => ({
1285
+ ...p.value.xAxisOptions,
1286
+ withHover: s.value === A.VERTICAL
1287
+ })), Y = c(() => ({
1288
+ ...p.value.yAxisOptions,
1289
+ withHover: s.value === A.HORIZONTAL
1290
+ })), x = c(() => {
1291
+ var k;
1292
+ return (k = p.value.xAxisOptions) == null ? void 0 : k.title;
1293
+ }), D = c(() => {
1294
+ var k;
1295
+ return (k = p.value.yAxisOptions) == null ? void 0 : k.title;
1296
+ }), S = c(() => {
1297
+ var k;
1298
+ return ((k = p.value.xAxisOptions) == null ? void 0 : k.withTitle) !== !1 && x.value;
1299
+ }), se = c(() => {
1300
+ var k;
1301
+ return ((k = p.value.yAxisOptions) == null ? void 0 : k.withTitle) !== !1 && D.value;
1302
+ }), dt = c(() => {
1303
+ const k = [], { noBaseScales: P } = p.value;
1304
+ return P || k.push(() => !!(I.value && N.value)), k.every((F) => F() === !0);
1305
+ }), { hasNegativeValues: vt } = Kn(O), { negativeBarAttributes: _t } = Jn(
1306
+ b,
1307
+ I,
1308
+ N,
1309
+ s
1310
+ ), { shouldGenerateTooltipAnchors: pt } = ot(
1311
+ _,
1312
+ p,
1313
+ I,
1314
+ N,
1315
+ s,
1316
+ O,
1317
+ v
1318
+ ), { tooltipConfig: $e, showTooltip: we, hideTooltip: Ie } = er(), { getTooltipItems: ft } = tr(O), mt = c(
1319
+ () => p.value.withTooltip !== !1 && $e.opened
1320
+ ), ht = c(
1321
+ () => {
1322
+ var k;
1323
+ return ((k = p.value.tooltipOptions) == null ? void 0 : k.position) || "top";
1324
+ }
1325
+ );
1326
+ function De(k) {
1327
+ var P;
1328
+ if (k !== d.value && (p.value.withHover !== !1 && (d.value = k), p.value.withTooltip !== !1)) {
1329
+ const F = (P = p.value.tooltipOptions) != null && P.targetElement ? p.value.tooltipOptions.targetElement === "self" ? g.value.$el : p.value.tooltipOptions.targetElement : f.value[k];
1330
+ we(F);
1331
+ }
1332
+ }
1333
+ function gt() {
1334
+ Ie(), d.value = -1, e("chart-mouseleave");
1335
+ }
1336
+ function yt({ index: k, value: P, event: F }) {
1337
+ k !== null && De(k), e("axis-mouseenter", { index: k, value: P, event: F });
1338
+ }
1339
+ function bt({ index: k, value: P, event: F }) {
1340
+ e("axis-click", { index: k, value: P, event: F });
1341
+ }
1342
+ return C(
1343
+ o,
1344
+ (k, P) => e("data-changed", { newValue: k, oldValue: P })
1345
+ ), C(
1346
+ u,
1347
+ (k, P) => e("labels-changed", { newValue: k, oldValue: P })
1348
+ ), B(() => {
1349
+ e("rendered"), n.groups || console.error('"groups" `<slot>` must have content.');
1350
+ }), Re("chartID", m), Re("tooltipAnchorAttributes", _), { __sfc: !0, props: r, slots: n, emit: e, tooltipAnchorRadius: a, data: o, labels: u, color: i, options: l, orientation: s, chartType: v, hoveredIndex: d, tooltipAnchor: f, chartContainer: g, tooltipAnchorAttributes: _, allOptions: p, internalData: O, computedLabels: h, containerSize: b, updateSize: y, chartID: m, xScale: T, yScale: E, computedXScale: I, computedYScale: N, computedXAxisOptions: V, computedYAxisOptions: Y, xAxisTitle: x, yAxisTitle: D, showXAxisTitle: S, showYAxisTitle: se, isReady: dt, hasNegativeValues: vt, negativeBarAttributes: _t, shouldGenerateTooltipAnchors: pt, tooltipConfig: $e, showTooltip: we, hideTooltip: Ie, getTooltipItems: ft, isTooltipOpened: mt, tooltipPosition: ht, handleInternalHover: De, handleMouseleave: gt, handleAxisMouseenter: yt, handleAxisClick: bt, LumeAxis: cn, LumeBar: Te, LumeChartContainer: An, LumeChartLegend: $n, LumeTooltip: Cn, LumeOverlayGroup: Un };
1351
+ }
1352
+ });
1353
+ var rr = function() {
1354
+ var e = this, r = e._self._c, n = e._self._setupProxy;
1355
+ return r(n.LumeChartContainer, { ref: "chartContainer", attrs: { id: `lume-chart_${n.chartID}`, margins: n.allOptions.margins, "container-size": n.containerSize, "no-min-size": n.allOptions.noMinSize, "transparent-background": n.allOptions.transparentBackground, "data-j-lume-chart": "" }, on: { resize: n.updateSize, click: function(a) {
1356
+ return n.emit("chart-click", a);
1357
+ }, mouseenter: function(a) {
1358
+ return n.emit("chart-mouseenter", a);
1359
+ }, mouseleave: n.handleMouseleave }, scopedSlots: e._u([{ key: "header", fn: function() {
1360
+ return [r("div", { staticClass: "lume-chart__header" }, [r("div", { staticClass: "lume-chart__header-section" }, [e.title ? r("h1", { staticClass: "lume-chart__title lume-chart-title lume-typography--display" }, [e._v(" " + e._s(e.title) + " ")]) : e._e(), r("div", { staticClass: "lume-chart__controls" }, [e._t("controls")], 2)]), r("div", { staticClass: "lume-chart__header-section" }, [n.showYAxisTitle ? r("h3", { staticClass: "lume-chart__axis-title lume-axis-title lume-typography--body" }, [e._v(" " + e._s(n.yAxisTitle) + " ")]) : e._e(), e._t("legend", function() {
1361
+ return [n.allOptions.withLegend !== !1 && n.allOptions.legendPosition !== "bottom" ? r(n.LumeChartLegend, { staticClass: "lume-chart__legend", attrs: { data: n.internalData, "data-j-lume-chart__legend": "" }, on: { click: function(a) {
1362
+ return n.emit("legend-click", a);
1363
+ }, mouseenter: function(a) {
1364
+ return n.emit("legend-mouseenter", a);
1365
+ }, mouseleave: function(a) {
1366
+ return n.emit("legend-mouseleave");
1367
+ } } }) : e._e()];
1368
+ }, { data: n.internalData })], 2)])];
1369
+ }, proxy: !0 }, { key: "footer", fn: function() {
1370
+ return [n.showXAxisTitle ? r("h3", { staticClass: "lume-chart__axis-title lume-chart__axis-title--centered lume-axis-title" }, [e._v(" " + e._s(n.xAxisTitle) + " ")]) : e._e(), n.allOptions.withLegend !== !1 && n.allOptions.legendPosition == "bottom" ? r(n.LumeChartLegend, { staticClass: "lume-chart__legend lume-chart__legend--bottom", attrs: { data: n.internalData, "data-j-lume-chart__legend": "" }, on: { click: function(a) {
1371
+ return n.emit("legend-click", a);
1372
+ }, mouseenter: function(a) {
1373
+ return n.emit("legend-mouseenter", a);
1374
+ }, mouseleave: function(a) {
1375
+ return n.emit("legend-mouseleave");
1376
+ } } }) : e._e()];
1377
+ }, proxy: !0 }, { key: "extra", fn: function() {
1378
+ return [e._t("tooltip", function() {
1379
+ return [n.isTooltipOpened ? r(n.LumeTooltip, e._b({ attrs: { position: n.tooltipPosition, title: n.computedLabels[n.hoveredIndex], items: n.getTooltipItems(n.hoveredIndex), options: n.allOptions.tooltipOptions, "data-j-lume-chart__tooltip": "" }, on: { opened: function(a) {
1380
+ return n.emit("tooltip-opened", {
1381
+ index: n.hoveredIndex,
1382
+ targetElement: a
1383
+ });
1384
+ }, moved: function(a) {
1385
+ return n.emit("tooltip-moved", {
1386
+ index: n.hoveredIndex,
1387
+ targetElement: a
1388
+ });
1389
+ }, closed: function(a) {
1390
+ return n.emit("tooltip-closed");
1391
+ } } }, "lume-tooltip", n.tooltipConfig, !1), [e._t("tooltip-content", null, { data: n.internalData, labels: n.computedLabels, hoveredIndex: n.hoveredIndex })], 2) : e._e()];
1392
+ }, { data: n.internalData, labels: n.computedLabels, withTooltip: n.allOptions.withTooltip !== !1, hoveredIndex: n.hoveredIndex, options: n.allOptions.tooltipOptions }, n.tooltipConfig)];
1393
+ }, proxy: !0 }], null, !0) }, [n.isReady ? [n.hasNegativeValues ? r(n.LumeBar, e._b({ attrs: { "class-list": "lume-fill--negative", transition: !1, "data-j-lume-chart__negative-values": "" } }, "lume-bar", n.negativeBarAttributes, !1)) : e._e(), n.allOptions.withAxes !== !1 ? e._t("axes", function() {
1394
+ return [r(n.LumeAxis, { attrs: { type: "x", scale: n.computedXScale, "container-size": n.containerSize, options: n.computedXAxisOptions, "hovered-index": n.hoveredIndex, orientation: n.orientation, "data-j-lume-chart__x-axis": "" }, on: { click: n.handleAxisClick, mouseenter: n.handleAxisMouseenter, mouseleave: function(a) {
1395
+ return n.emit("axis-mouseleave");
1396
+ } } }), r(n.LumeAxis, { attrs: { type: "y", scale: n.computedYScale, "container-size": n.containerSize, options: n.computedYAxisOptions, "hovered-index": n.hoveredIndex, orientation: n.orientation, "data-j-lume-chart__y-axis": "" }, on: { click: n.handleAxisClick, mouseenter: n.handleAxisMouseenter, mouseleave: function(a) {
1397
+ return n.emit("axis-mouseleave");
1398
+ } } })];
1399
+ }, { xScale: n.computedXScale, yScale: n.computedYScale, containerSize: n.containerSize, options: n.allOptions, hoveredIndex: n.hoveredIndex }) : e._e(), n.allOptions.withHover !== !1 ? r(n.LumeOverlayGroup, { attrs: { data: n.internalData, orientation: n.orientation, "x-scale": n.computedXScale, "y-scale": n.computedYScale, "data-j-lume-chart__overlay-group": "" }, on: { "lume__internal--hover": n.handleInternalHover } }) : e._e(), n.shouldGenerateTooltipAnchors ? r("g", e._l(n.tooltipAnchorAttributes, function(a, o) {
1400
+ return r("circle", e._b({ key: `anchor_${o}`, ref: "tooltipAnchor", refInFor: !0, staticClass: "lume-fill--transparent", attrs: { r: n.tooltipAnchorRadius } }, "circle", a, !1));
1401
+ }), 0) : e._e(), e._t("groups", null, { data: n.internalData, labels: n.computedLabels, options: n.allOptions, orientation: n.orientation, xScale: n.computedXScale, yScale: n.computedYScale, hoveredIndex: n.hoveredIndex, containerSize: n.containerSize, transition: n.allOptions.withTransition !== !1, classList: e.classList })] : e._e()], 2);
1402
+ }, ar = [], or = /* @__PURE__ */ w(
1403
+ nr,
1404
+ rr,
1405
+ ar,
1406
+ !1,
1407
+ null,
1408
+ "9c6832ae",
1409
+ null,
1410
+ null
1411
+ );
1412
+ const K = or.exports;
1413
+ function He(t, e) {
1414
+ return {
1415
+ x0: 0 + (e ? e.left : 0),
1416
+ y0: 0 + (e ? e.top : 0),
1417
+ x1: t.width - (e ? e.right : 0),
1418
+ y1: t.height - (e ? e.bottom : 0)
1419
+ };
1420
+ }
1421
+ function ur(t) {
1422
+ const e = L(He(t));
1423
+ function r(n) {
1424
+ e.value = He(t, n);
1425
+ }
1426
+ return { extents: e, updateExtents: r };
1427
+ }
1428
+ var ut = /* @__PURE__ */ ((t) => (t.GraphProblem = "There was an issue generating your alluvial graph.", t))(ut || {});
1429
+ const lr = "[lume] ";
1430
+ function ir(t, e, r = !0) {
1431
+ r && Ye() || console.error(lr + "Error: " + t, e);
1432
+ }
1433
+ const Be = 8, sr = 8, cr = 200;
1434
+ function U(t) {
1435
+ return typeof t == "string" || typeof t == "number" ? t : t.id ?? t.label;
1436
+ }
1437
+ function ne(t) {
1438
+ return t.source.id + ":" + t.target.id;
1439
+ }
1440
+ function lt(t) {
1441
+ return !!(t.sourceLinks && t.targetLinks);
1442
+ }
1443
+ function dr(t, e) {
1444
+ if (!e)
1445
+ return;
1446
+ const r = t.nodes.filter((u) => u.targetLinks.length === 0).map((u) => `${u.id}`), n = t.nodes.filter((u) => u.sourceLinks.length === 0).map((u) => `${u.id}`), a = e.filter((u) => r.includes(u.dataset.id)).reduce(
1447
+ (u, i) => Math.max(u, i.getBBox().width),
1448
+ -1 / 0
1449
+ ), o = e.filter((u) => n.includes(u.dataset.id)).reduce(
1450
+ (u, i) => Math.max(u, i.getBBox().width),
1451
+ -1 / 0
1452
+ );
1453
+ return {
1454
+ left: a,
1455
+ top: 0,
1456
+ right: o,
1457
+ bottom: 0
1458
+ };
1459
+ }
1460
+ function vr(t) {
1461
+ return t.map((e) => ({
1462
+ x: e.x0,
1463
+ y: e.y0,
1464
+ width: e.x1 - e.x0,
1465
+ height: e.y1 - e.y0,
1466
+ textTransform: {
1467
+ x: e.depth > 0 ? e.x1 + Be : e.x0 - Be,
1468
+ y: (e.y1 + e.y0) / 2
1469
+ },
1470
+ node: e
1471
+ }));
1472
+ }
1473
+ function _r(t) {
1474
+ const e = At();
1475
+ return t.map((r) => {
1476
+ var n;
1477
+ return {
1478
+ id: ne(r),
1479
+ color: r.color || ((n = r.source) == null ? void 0 : n.color) || le,
1480
+ d: e(r),
1481
+ strokeWidth: Math.max(1, r.width),
1482
+ link: r
1483
+ };
1484
+ });
1485
+ }
1486
+ function je(t, e, r) {
1487
+ const n = Date.now(), a = jt(e, r), o = () => {
1488
+ let i = (Date.now() - n) / cr;
1489
+ i > 1 && (i = 1), t.node = {
1490
+ ...t.node,
1491
+ transitionValue: a(i)
1492
+ }, i < 1 && requestAnimationFrame(o);
1493
+ };
1494
+ requestAnimationFrame(o);
1495
+ }
1496
+ const pr = {
1497
+ nodes: [],
1498
+ links: []
1499
+ };
1500
+ function fr(t, e, r) {
1501
+ const n = L(null), a = c(() => {
1502
+ var i;
1503
+ return (i = t.value) == null ? void 0 : i[0].values.map(({ label: l, color: s, value: v }) => ({
1504
+ label: l || v.toString(),
1505
+ color: s,
1506
+ id: v
1507
+ }));
1508
+ }), o = c(() => {
1509
+ var i;
1510
+ return (i = t.value) == null ? void 0 : i[0].values.map(
1511
+ (l) => {
1512
+ var s;
1513
+ return (s = l.targets) == null ? void 0 : s.map(({ node: v, value: d, color: f }) => ({
1514
+ color: f,
1515
+ source: l.value ?? l.label,
1516
+ target: v,
1517
+ value: d
1518
+ }));
1519
+ }
1520
+ ).filter(Boolean).flat();
1521
+ }), u = c(() => Ot().nodeId(U).nodeAlign(e.value.nodeAlign).nodePadding(e.value.nodePadding).nodeSort(e.value.nodeSort).nodeWidth(e.value.nodeWidth));
1522
+ return C([u, r], () => {
1523
+ try {
1524
+ const { x0: i, y0: l, x1: s, y1: v } = r.value;
1525
+ n.value = u.value.extent([
1526
+ [i, l],
1527
+ [s, v]
1528
+ ])({ nodes: a.value, links: o.value });
1529
+ } catch (i) {
1530
+ ir(ut.GraphProblem, i), n.value = pr;
1531
+ }
1532
+ }), { graph: n };
1533
+ }
1534
+ function me(t, e) {
1535
+ return e || (e = {}), t.targetLinks && t.targetLinks.forEach(({ source: r, value: n }) => {
1536
+ e[r.id] = n, me(r, e);
1537
+ }), e;
1538
+ }
1539
+ function he(t, e) {
1540
+ return e || (e = {}), t.sourceLinks && t.sourceLinks.forEach(({ target: r, value: n }) => {
1541
+ e[r.id] = n, he(r, e);
1542
+ }), e;
1543
+ }
1544
+ function mr(t, e) {
1545
+ return e.links.reduce((r, n) => (n.source.id in t && n.target.id in t && r.push(ne(n)), r), []);
1546
+ }
1547
+ const hr = (t, e) => {
1548
+ let r;
1549
+ lt(t) ? r = {
1550
+ [t.id]: t.value,
1551
+ ...me(t),
1552
+ ...he(t)
1553
+ } : r = {
1554
+ [t.source.id]: t.source.value,
1555
+ [t.target.id]: t.target.value,
1556
+ ...me(t.source),
1557
+ ...he(t.target)
1558
+ };
1559
+ const n = mr(r, e);
1560
+ return { nodes: r, links: n };
1561
+ }, gr = (t) => {
1562
+ if (lt(t)) {
1563
+ const e = [...t.sourceLinks, ...t.targetLinks];
1564
+ return {
1565
+ nodes: e.reduce(
1566
+ (r, { source: n, target: a, value: o }) => n === t ? { ...r, [U(a)]: o } : { ...r, [U(n)]: o },
1567
+ { [U(t)]: t.value }
1568
+ ),
1569
+ links: e.map((r) => ne(r))
1570
+ };
1571
+ }
1572
+ return {
1573
+ nodes: {
1574
+ [U(t.target)]: t.value,
1575
+ [U(t.source)]: t.source.value
1576
+ },
1577
+ links: [ne(t)]
1578
+ };
1579
+ };
1580
+ function yr(t, e, r) {
1581
+ const n = L(null), a = c(() => n.value ? typeof e.value.highlightedElements == "function" ? e.value.highlightedElements(
1582
+ n.value,
1583
+ r.value
1584
+ ) : e.value.highlightedElements === "closest" ? gr(n.value, r.value) : hr(n.value, r.value) : { nodes: {}, links: [] });
1585
+ return C(a, (o, u) => {
1586
+ if (o.links.length === 0 && Object.keys(o.nodes).length === 0) {
1587
+ t.value.forEach((i) => {
1588
+ i.node.id in u.nodes && je(
1589
+ i,
1590
+ u.nodes[i.node.id],
1591
+ i.node.value
1592
+ );
1593
+ });
1594
+ return;
1595
+ }
1596
+ t.value.forEach((i) => {
1597
+ i.node.id in o.nodes && je(
1598
+ i,
1599
+ i.node.value,
1600
+ o.nodes[i.node.id]
1601
+ );
1602
+ });
1603
+ }), { highlightedElements: a, hoveredElement: n };
1604
+ }
1605
+ const br = /* @__PURE__ */ $({
1606
+ __name: "lume-alluvial-group",
1607
+ props: {
1608
+ ...ie()
1609
+ },
1610
+ emits: ["node-click", "node-mouseenter", "node-mouseleave", "link-click", "link-mouseenter", "link-mouseleave"],
1611
+ setup(t, { emit: e }) {
1612
+ const r = t, { data: n, options: a } = R(r), o = L([]), u = L([]), i = L(null), { extents: l, updateExtents: s } = ur(r.containerSize), { graph: v } = fr(n, a, l), { hoveredElement: d, highlightedElements: f } = yr(
1613
+ o,
1614
+ a,
1615
+ v
1616
+ ), g = c(() => ke(a.value.valueFormat)), _ = c(
1617
+ () => Object.keys(f.value.nodes)
1618
+ );
1619
+ function p(y) {
1620
+ return _.value.length > 0 && !_.value.includes(y.toString());
1621
+ }
1622
+ function O(y) {
1623
+ return f.value.links.length > 0 && !f.value.links.includes(y);
1624
+ }
1625
+ function h(y, m) {
1626
+ y !== d.value && (d.value = y, e("link-mouseenter", { link: y, event: m }));
1627
+ }
1628
+ function b(y) {
1629
+ const m = d.value;
1630
+ d.value = null, e("link-mouseleave", { link: m, event: y });
1631
+ }
1632
+ return C(v, (y) => {
1633
+ o.value = vr(y.nodes), u.value = _r(y.links);
1634
+ }), C([r.containerSize, i], () => {
1635
+ if (r.containerSize.width && r.containerSize.height) {
1636
+ const y = dr(v.value, i.value);
1637
+ s(y);
1638
+ }
1639
+ }), { __sfc: !0, props: r, emit: e, data: n, options: a, nodeBlocks: o, linkPaths: u, nodeTextRefs: i, extents: l, updateExtents: s, graph: v, hoveredElement: d, highlightedElements: f, formatValue: g, hoveredNodeIds: _, isNodeFaded: p, isLinkFaded: O, handleLinkMouseover: h, handleLinkMouseleave: b, GHOST_STROKE_WIDTH_OFFSET: sr, DEFAULT_COLOR: le };
1640
+ }
1641
+ });
1642
+ var kr = function() {
1643
+ var e = this, r = e._self._c, n = e._self._setupProxy;
1644
+ return r("g", { staticClass: "lume-alluvial-group", attrs: { "data-j-alluvial-group": "" } }, [e._l(n.nodeBlocks, function(a, o) {
1645
+ return r("g", { key: `node-block_${o}`, staticClass: "lume-alluvial-group__node", class: {
1646
+ "lume-alluvial-group__node--faded": n.isNodeFaded(a.node.id)
1647
+ }, attrs: { "data-j-alluvial-group__node-block": "" } }, [r("g", { on: { click: function(u) {
1648
+ return n.emit("node-click", { node: a.node, event: u });
1649
+ }, mouseenter: function(u) {
1650
+ return n.emit("node-mouseenter", { node: a.node, event: u });
1651
+ }, mouseleave: function(u) {
1652
+ return n.emit("node-mouseleave", { node: a.node, event: u });
1653
+ }, mouseover: function(u) {
1654
+ n.hoveredElement = a.node;
1655
+ }, mouseout: function(u) {
1656
+ n.hoveredElement = null;
1657
+ } } }, [r("rect", { class: `lume-alluvial-group__node-block--${a.node.color || n.DEFAULT_COLOR}`, attrs: { x: a.x, y: a.y, height: a.height, width: a.width } }), r("text", { ref: "nodeTextRefs", refInFor: !0, staticClass: "lume-alluvial-group__node-text lume-typography--caption", class: {
1658
+ "lume-alluvial-group__node-text--right": a.node.depth === 0
1659
+ }, attrs: { transform: `translate(${a.textTransform.x},${a.textTransform.y})`, "data-id": a.node.id } }, [r("tspan", { staticClass: "lume-alluvial-group__node-title", domProps: { textContent: e._s(a.node.label) } }), r("tspan", { staticClass: "lume-alluvial-group__node-value", attrs: { x: "0", dy: "1.2em" }, domProps: { textContent: e._s(
1660
+ n.formatValue(
1661
+ a.node.transitionValue || a.node.value
1662
+ )
1663
+ ) } })])])]);
1664
+ }), r("g", { staticClass: "lume-alluvial-link-group", on: { mouseleave: n.handleLinkMouseleave } }, [e._l(n.linkPaths, function(a) {
1665
+ return r("path", { key: `link-ghost_${a.id}`, staticClass: "lume-alluvial-group__link", class: [
1666
+ "lume-stroke--transparent",
1667
+ "lume-alluvial-group__link--ghost"
1668
+ ], attrs: { d: a.d, "stroke-width": a.strokeWidth + n.GHOST_STROKE_WIDTH_OFFSET, "data-j-alluvial-ghost": "" }, on: { click: function(o) {
1669
+ return n.emit("link-click", { link: a.link, event: o });
1670
+ }, mouseover: function(o) {
1671
+ return n.handleLinkMouseover(a.link, o);
1672
+ } } });
1673
+ }), e._l(n.linkPaths, function(a) {
1674
+ return r("path", { key: `link_${a.id}`, staticClass: "lume-alluvial-group__link", class: {
1675
+ [`lume-stroke--${a.color}`]: a.color,
1676
+ "lume-alluvial-group__link--faded": n.isLinkFaded(a.id)
1677
+ }, attrs: { d: a.d, "stroke-dasharray": e.containerSize.width, "stroke-dashoffset": e.containerSize.width, "stroke-width": a.strokeWidth, "data-j-alluvial-path": "" }, on: { click: function(o) {
1678
+ return n.emit("link-click", { link: a.link, event: o });
1679
+ }, mouseover: function(o) {
1680
+ return n.handleLinkMouseover(a.link, o);
1681
+ } } });
1682
+ })], 2)], 2);
1683
+ }, Ar = [], Or = /* @__PURE__ */ w(
1684
+ br,
1685
+ kr,
1686
+ Ar,
1687
+ !1,
1688
+ null,
1689
+ "88bf1bc5",
1690
+ null,
1691
+ null
1692
+ );
1693
+ const Tr = Or.exports, Lr = {
1694
+ margins: {
1695
+ top: 0,
1696
+ right: 0,
1697
+ bottom: 0,
1698
+ left: 0
1699
+ },
1700
+ withAxes: !1,
1701
+ withTooltip: !1,
1702
+ withHover: !1,
1703
+ withLegend: !1,
1704
+ // Alluvial options
1705
+ highlightedElements: "full",
1706
+ nodePadding: 16,
1707
+ nodeWidth: 16,
1708
+ nodeAlign: Tt,
1709
+ valueFormat: (t) => String(t)
1710
+ }, xr = /* @__PURE__ */ $({
1711
+ __name: "lume-alluvial-diagram",
1712
+ props: {
1713
+ ...X(
1714
+ ye,
1715
+ !1,
1716
+ !1
1717
+ )
1718
+ },
1719
+ setup(t) {
1720
+ const e = t, r = Z(j()), { options: n } = R(e), { allOptions: a } = H(n, Lr);
1721
+ function o(u) {
1722
+ return {
1723
+ ...u,
1724
+ noBaseScales: !0
1725
+ // Alluvial chart never uses base scales
1726
+ };
1727
+ }
1728
+ return { __sfc: !0, props: e, slots: r, options: n, allOptions: a, getAlluvialDiagramOptions: o, LumeChart: K, LumeAlluvialGroup: Tr };
1729
+ }
1730
+ });
1731
+ var $r = function() {
1732
+ var e = this, r = e._self._c, n = e._self._setupProxy;
1733
+ return r(n.LumeChart, e._b({ attrs: { options: n.getAlluvialDiagramOptions(n.allOptions), "data-j-alluvial-diagram": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
1734
+ return [r(n.LumeAlluvialGroup, e._b({}, "lume-alluvial-group", a, !1))];
1735
+ } }, e._l(n.slots, function(a, o) {
1736
+ return { key: o, fn: function(u) {
1737
+ return [e._t(o, null, null, u || {})];
1738
+ } };
1739
+ })], null, !0) }, "lume-chart", n.props, !1));
1740
+ }, wr = [], Ir = /* @__PURE__ */ w(
1741
+ xr,
1742
+ $r,
1743
+ wr,
1744
+ !1,
1745
+ null,
1746
+ null,
1747
+ null,
1748
+ null
1749
+ );
1750
+ const ja = Ir.exports;
1751
+ var ge = /* @__PURE__ */ ((t) => (t.grouped = "grouped", t.stacked = "stacked", t))(ge || {});
1752
+ const Dr = /* @__PURE__ */ $({
1753
+ __name: "lume-bar-chart",
1754
+ props: {
1755
+ ...X(),
1756
+ type: {
1757
+ type: String,
1758
+ default: null,
1759
+ validator: (t) => t in ge || t == null
1760
+ }
1761
+ },
1762
+ setup(t) {
1763
+ const e = t, r = ce(
1764
+ () => import("./3c746d4c.js")
1765
+ ), n = ce(
1766
+ () => import("./05b956a3.js")
1767
+ ), a = ce(
1768
+ () => import("./eb9d7694.js")
1769
+ ), o = /* @__PURE__ */ new Map([
1770
+ ["single", r],
1771
+ ["grouped", n],
1772
+ ["stacked", a]
1773
+ ]), u = Z(j());
1774
+ function i(s) {
1775
+ return {
1776
+ ...s,
1777
+ startOnZero: !0,
1778
+ // Bar chart always starts on zero,
1779
+ tooltipOptions: {
1780
+ ...(s == null ? void 0 : s.tooltipOptions) || {},
1781
+ position: e.orientation === A.HORIZONTAL && "right"
1782
+ }
1783
+ };
1784
+ }
1785
+ const l = c(() => {
1786
+ if (e.data) {
1787
+ if (ye(e.data))
1788
+ return o.get("single");
1789
+ if (!e.type)
1790
+ throw new Error("Bar chart needs a type when there's multiple datasets.");
1791
+ return o.get(e.type);
1792
+ }
1793
+ });
1794
+ return { __sfc: !0, TYPES: ge, LumeSingleBarChart: r, LumeGroupedBarChart: n, LumeStackedBarChart: a, COMPONENT_MAP: o, props: e, slots: u, getBarChartOptions: i, component: l };
1795
+ }
1796
+ });
1797
+ var Rr = function() {
1798
+ var e = this, r = e._self._c, n = e._self._setupProxy;
1799
+ return r(n.component, e._b({ tag: "component", attrs: { options: n.getBarChartOptions(e.options) }, scopedSlots: e._u([e._l(n.slots, function(a, o) {
1800
+ return { key: o, fn: function(u) {
1801
+ return [e._t(o, null, null, u || {})];
1802
+ } };
1803
+ })], null, !0) }, "component", { ...n.props, ...e.$attrs }, !1));
1804
+ }, Cr = [], Er = /* @__PURE__ */ w(
1805
+ Dr,
1806
+ Rr,
1807
+ Cr,
1808
+ !1,
1809
+ null,
1810
+ null,
1811
+ null,
1812
+ null
1813
+ );
1814
+ const Va = Er.exports;
1815
+ function Nr(t) {
1816
+ return Object.values(Zt).includes(t) || t == null;
1817
+ }
1818
+ function Pr(t) {
1819
+ return Object.values(A).includes(t);
1820
+ }
1821
+ const Gr = (t = !1) => ({
1822
+ type: {
1823
+ type: String,
1824
+ default: null,
1825
+ validator: Nr
1826
+ },
1827
+ ...t ? {
1828
+ orientation: {
1829
+ type: String,
1830
+ default: A.VERTICAL,
1831
+ validator: Pr
1832
+ }
1833
+ } : {}
1834
+ });
1835
+ function it(t) {
1836
+ const e = c(() => t.value.map((n) => ({
1837
+ ...n,
1838
+ values: n.values.map((a) => ({
1839
+ ...a,
1840
+ value: (a == null ? void 0 : a.value) || 0
1841
+ }))
1842
+ }))), r = c(() => {
1843
+ var n;
1844
+ return (n = e.value) == null ? void 0 : n.reduce((a, o) => (o.values.forEach((u, i) => {
1845
+ a[i] ? a[i].push(u) : a[i] = [u];
1846
+ }), a), []);
1847
+ });
1848
+ return { multiBarData: e, groupedData: r };
1849
+ }
1850
+ function Sr(t, e) {
1851
+ return t.value.length === 1 ? "single" : e.value;
1852
+ }
1853
+ function Hr(t, e, r, n) {
1854
+ const a = c(
1855
+ () => n.value === A.HORIZONTAL
1856
+ );
1857
+ function o(l) {
1858
+ Math.min(...l.domain()) > 0 && console.error("Bar linear scale domain cannot start above 0!");
1859
+ }
1860
+ const u = c(() => {
1861
+ const { padding: l, paddingInner: s, paddingOuter: v } = r.value;
1862
+ return a.value ? (() => (o(t.value), t.value))() : te(
1863
+ t.value,
1864
+ n.value,
1865
+ { padding: l, paddingInner: s, paddingOuter: v }
1866
+ );
1867
+ }), i = c(() => {
1868
+ const { padding: l, paddingInner: s, paddingOuter: v } = r.value;
1869
+ return a.value ? te(
1870
+ e.value,
1871
+ n.value,
1872
+ { padding: l, paddingInner: s, paddingOuter: v }
1873
+ ) : (() => (o(e.value), e.value))();
1874
+ });
1875
+ return { barXScale: u, barYScale: i };
1876
+ }
1877
+ function Br(t, e, r, n, a, o) {
1878
+ const u = c(
1879
+ () => n.value === A.HORIZONTAL
1880
+ );
1881
+ function i(d, f) {
1882
+ let g, _;
1883
+ return u.value ? (g = d >= 0 ? e.value(0) : e.value(d), _ = r.value(r.value.domain()[f])) : (g = e.value(e.value.domain()[f]), _ = d < 0 ? r.value(0) : r.value(d)), { x: g, y: _ };
1884
+ }
1885
+ function l(d) {
1886
+ return u.value ? d < 0 ? e.value(0) - e.value(d) : e.value(d) - e.value(0) : e.value.bandwidth();
1887
+ }
1888
+ function s(d) {
1889
+ return u.value ? r.value.bandwidth() : d < 0 ? r.value(d) - r.value(0) : r.value(0) - r.value(d);
1890
+ }
1891
+ function v(d, f, g) {
1892
+ const { value: _, color: p } = d, O = p ?? t.value[f].color ?? le, { x: h, y: b } = i(_, g), y = l(_), m = s(_);
1893
+ return {
1894
+ classList: [`lume-fill--${O}`, ...o],
1895
+ x: h,
1896
+ y: b,
1897
+ width: y,
1898
+ height: m,
1899
+ isFaded: a.value !== -1 && a.value !== g,
1900
+ isNegative: _ < 0
1901
+ };
1902
+ }
1903
+ return { barAttributeGenerator: v };
1904
+ }
1905
+ function jr(t, e, r, n, a, o) {
1906
+ const u = c(
1907
+ () => n.value === A.HORIZONTAL
1908
+ ), i = c(() => J().domain(t.value.map((_, p) => p)).range([0, e.value.bandwidth()]).padding(0)), l = c(() => J().domain(t.value.map((_, p) => p)).range([0, r.value.bandwidth()]).padding(0));
1909
+ function s(_, p, O) {
1910
+ if (u.value)
1911
+ return _ >= 0 ? e.value(0) : e.value(_);
1912
+ const h = e.value.domain();
1913
+ return e.value(h[p]) + i.value(O);
1914
+ }
1915
+ function v(_, p, O) {
1916
+ if (u.value) {
1917
+ const h = r.value.domain();
1918
+ return r.value(h[p]) + l.value(O);
1919
+ }
1920
+ return _ < 0 ? r.value(0) : r.value(_);
1921
+ }
1922
+ function d(_) {
1923
+ return u.value ? _ < 0 ? e.value(0) - e.value(_) : e.value(_) - e.value(0) : i.value.bandwidth();
1924
+ }
1925
+ function f(_) {
1926
+ return u.value ? l.value.bandwidth() : _ < 0 ? r.value(_) - r.value(0) : r.value(0) - r.value(_);
1927
+ }
1928
+ function g(_, p, O) {
1929
+ const { value: h, color: b } = _, y = b ?? t.value[p].color ?? Object.values(G)[p], m = s(h, O, p), T = v(h, O, p), E = d(h), I = f(h);
1930
+ return {
1931
+ classList: [`lume-fill--${y}`, ...o],
1932
+ x: m,
1933
+ y: T,
1934
+ width: E,
1935
+ height: I,
1936
+ isFaded: a.value !== -1 && a.value !== O,
1937
+ isNegative: h < 0
1938
+ };
1939
+ }
1940
+ return { barAttributeGenerator: g };
1941
+ }
1942
+ function Vr(t, e) {
1943
+ const r = c(
1944
+ () => e.value === A.HORIZONTAL
1945
+ ), n = c(() => {
1946
+ const i = t.value.map(
1947
+ (l) => l.filter((s) => s.value < 0).reduce((s, v) => s + v.value, 0)
1948
+ );
1949
+ return Math.min(...i);
1950
+ }), a = c(() => {
1951
+ const i = t.value.map(
1952
+ (l) => l.reduce(
1953
+ (s, v) => v.value >= 0 ? s + v.value : s,
1954
+ 0
1955
+ )
1956
+ );
1957
+ return Math.max(...i);
1958
+ });
1959
+ function o(i, l, s) {
1960
+ return r.value ? Q().domain([n.value, a.value]).range([0, s.width]) : Object.assign(
1961
+ te(
1962
+ J().domain(l.map((v, d) => d)).range([0, s.width])
1963
+ ),
1964
+ { labels: l }
1965
+ );
1966
+ }
1967
+ function u(i, l, s) {
1968
+ return r.value ? Object.assign(
1969
+ te(
1970
+ J().domain(l.map((v, d) => d)).range([0, s.height])
1971
+ ),
1972
+ { labels: l }
1973
+ ) : Q().domain([a.value, n.value]).range([0, s.height]);
1974
+ }
1975
+ return { stackedXScaleGenerator: o, stackedYScaleGenerator: u };
1976
+ }
1977
+ function Fr(t, e, r, n, a, o) {
1978
+ const u = c(
1979
+ () => n.value === A.HORIZONTAL
1980
+ ), i = c(
1981
+ () => u.value ? r.value.domain() : e.value.domain()
1982
+ ), l = c(
1983
+ () => t.value.map((h) => h.values.map((b) => b == null ? void 0 : b.value))
1984
+ );
1985
+ function s(h, b, y) {
1986
+ let m, T;
1987
+ return u.value ? (m = e.value(h >= 0 ? 0 + y : h + y), T = r.value(i.value[b])) : (m = e.value(i.value[b]), T = r.value(h >= 0 ? h + y : 0 + y)), { x: m, y: T };
1988
+ }
1989
+ function v(h) {
1990
+ return u.value ? e.value(h) - e.value(0) : e.value.bandwidth();
1991
+ }
1992
+ function d(h) {
1993
+ return u.value ? e.value(0) - e.value(h) : e.value.bandwidth();
1994
+ }
1995
+ function f(h) {
1996
+ return u.value ? r.value.bandwidth() : r.value(0) - r.value(h);
1997
+ }
1998
+ function g(h) {
1999
+ return u.value ? r.value.bandwidth() : r.value(h) - r.value(0);
2000
+ }
2001
+ function _(h, b) {
2002
+ return h ? l.value.reduce((y, m, T) => (T < h && m[b] >= 0 && (y += m[b]), y), 0) : 0;
2003
+ }
2004
+ function p(h, b) {
2005
+ return h ? l.value.reduce((y, m, T) => (T < h && m[b] < 0 && (y += m[b]), y), 0) : 0;
2006
+ }
2007
+ function O(h, b, y) {
2008
+ const { value: m, color: T } = h, E = m >= 0 ? v(m) : d(m), I = m >= 0 ? f(m) : g(m), N = m >= 0 ? _(b, y) : p(b, y), { x: V, y: Y } = s(m, y, N);
2009
+ return {
2010
+ classList: [`lume-fill--${T ?? t.value[b].color ?? Object.values(G)[b]}`, ...o],
2011
+ width: E,
2012
+ height: I,
2013
+ x: V,
2014
+ y: Y,
2015
+ isFaded: a.value !== -1 && a.value !== y,
2016
+ isNegative: m < 0
2017
+ };
2018
+ }
2019
+ return { barAttributeGenerator: O };
2020
+ }
2021
+ const Ve = {
2022
+ single: Br,
2023
+ grouped: jr,
2024
+ stacked: Fr
2025
+ }, Mr = /* @__PURE__ */ $({
2026
+ __name: "lume-bar-group",
2027
+ props: {
2028
+ ...ie(),
2029
+ classList: {
2030
+ type: [String, Array],
2031
+ default: () => []
2032
+ },
2033
+ ...Gr(!0),
2034
+ transition: {
2035
+ type: Boolean,
2036
+ default: !0
2037
+ }
2038
+ },
2039
+ emits: ["bar-click", "lume__internal--hover"],
2040
+ setup(t, { emit: e }) {
2041
+ const r = t, {
2042
+ data: n,
2043
+ hoveredIndex: a,
2044
+ options: o,
2045
+ orientation: u,
2046
+ transition: i,
2047
+ type: l,
2048
+ xScale: s,
2049
+ yScale: v,
2050
+ classList: d
2051
+ } = R(r), { groupedData: f } = it(n), { barXScale: g, barYScale: _ } = Hr(
2052
+ s,
2053
+ v,
2054
+ o,
2055
+ u
2056
+ ), p = c(() => typeof d.value == "string" ? [d.value] : d.value), O = c(() => {
2057
+ const b = Sr(n, l), { barAttributeGenerator: y } = Ve[b](
2058
+ n,
2059
+ g,
2060
+ _,
2061
+ u,
2062
+ a,
2063
+ p.value
2064
+ );
2065
+ return y;
2066
+ }), h = c(() => {
2067
+ if (i.value)
2068
+ return u.value === A.HORIZONTAL ? "width" : "height";
2069
+ });
2070
+ return { __sfc: !0, MIXIN_MAP: Ve, props: r, emit: e, data: n, hoveredIndex: a, options: o, orientation: u, transition: i, type: l, xScale: s, yScale: v, classList: d, groupedData: f, barXScale: g, barYScale: _, computedClasses: p, getBarAttributes: O, computedTransition: h, LumeBar: Te };
2071
+ }
2072
+ });
2073
+ var zr = function() {
2074
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2075
+ return r("g", { staticClass: "lume-bar-group", attrs: { "data-j-bars-group": "" } }, e._l(n.groupedData, function(a, o) {
2076
+ return r("g", { key: o, on: { mouseenter: function(u) {
2077
+ return n.emit("lume__internal--hover", o);
2078
+ } } }, e._l(a, function(u, i) {
2079
+ return r(n.LumeBar, e._b({ key: `bar-${i}`, attrs: { transition: n.computedTransition, "data-j-lume-bar": "" }, on: { click: function(l) {
2080
+ return n.emit("bar-click", {
2081
+ index: o,
2082
+ datasetIndex: i,
2083
+ event: l
2084
+ });
2085
+ } } }, "lume-bar", n.getBarAttributes(u, i, o, a), !1));
2086
+ }), 1);
2087
+ }), 0);
2088
+ }, Wr = [], Zr = /* @__PURE__ */ w(
2089
+ Mr,
2090
+ zr,
2091
+ Wr,
2092
+ !1,
2093
+ null,
2094
+ null,
2095
+ null,
2096
+ null
2097
+ );
2098
+ const xe = Zr.exports, Xr = {
2099
+ [A.VERTICAL]: {
2100
+ withTooltip: !0,
2101
+ xAxisOptions: {},
2102
+ yAxisOptions: { gridLines: !0 },
2103
+ margins: z.VERTICAL
2104
+ },
2105
+ [A.HORIZONTAL]: {
2106
+ withTooltip: !0,
2107
+ xAxisOptions: { gridLines: !0 },
2108
+ yAxisOptions: { gridLines: !1 },
2109
+ margins: z.HORIZONTAL
2110
+ }
2111
+ }, Yr = /* @__PURE__ */ $({
2112
+ __name: "lume-single-bar-chart",
2113
+ props: {
2114
+ ...X(ye)
2115
+ },
2116
+ setup(t) {
2117
+ const e = t, r = Z(j()), { orientation: n, options: a } = R(e), o = c(
2118
+ () => Xr[n.value || A.VERTICAL]
2119
+ // needs to be computed so that default options are reactive
2120
+ ), { allOptions: u } = H(a, o);
2121
+ return { __sfc: !0, props: e, slots: r, orientation: n, options: a, baseOptions: o, allOptions: u, LumeChart: K, LumeBarGroup: xe };
2122
+ }
2123
+ });
2124
+ var Ur = function() {
2125
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2126
+ return r(n.LumeChart, e._b({ attrs: { "chart-type": "single-bar", options: n.allOptions, "data-j-single-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2127
+ return [r(n.LumeBarGroup, e._b({ attrs: { orientation: n.orientation } }, "lume-bar-group", a, !1))];
2128
+ } }, e._l(n.slots, function(a, o) {
2129
+ return { key: o, fn: function(u) {
2130
+ return [e._t(o, null, null, u || {})];
2131
+ } };
2132
+ })], null, !0) }, "lume-chart", n.props, !1));
2133
+ }, Kr = [], Jr = /* @__PURE__ */ w(
2134
+ Yr,
2135
+ Ur,
2136
+ Kr,
2137
+ !1,
2138
+ null,
2139
+ null,
2140
+ null,
2141
+ null
2142
+ );
2143
+ const Fa = Jr.exports, Qr = {
2144
+ [A.VERTICAL]: {
2145
+ withTooltip: !0,
2146
+ xAxisOptions: {},
2147
+ yAxisOptions: { gridLines: !0 },
2148
+ margins: z.VERTICAL
2149
+ },
2150
+ [A.HORIZONTAL]: {
2151
+ withTooltip: !0,
2152
+ xAxisOptions: { gridLines: !0 },
2153
+ yAxisOptions: { gridLines: !1 },
2154
+ margins: z.HORIZONTAL,
2155
+ tooltipOptions: { position: "right" }
2156
+ }
2157
+ }, qr = /* @__PURE__ */ $({
2158
+ __name: "lume-grouped-bar-chart",
2159
+ props: {
2160
+ ...X()
2161
+ },
2162
+ setup(t) {
2163
+ const e = t, r = Z(j()), { orientation: n, options: a } = R(e), o = c(
2164
+ () => Qr[n.value || A.VERTICAL]
2165
+ // needs to be computed so that default options are reactive
2166
+ ), { allOptions: u } = H(a, o);
2167
+ return { __sfc: !0, props: e, slots: r, orientation: n, options: a, baseOptions: o, allOptions: u, LumeChart: K, LumeBarGroup: xe };
2168
+ }
2169
+ });
2170
+ var ea = function() {
2171
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2172
+ return r(n.LumeChart, e._b({ attrs: { "chart-type": "grouped-bar", options: n.allOptions, "data-j-grouped-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2173
+ return [r(n.LumeBarGroup, e._b({ attrs: { type: "grouped" } }, "lume-bar-group", a, !1))];
2174
+ } }, e._l(n.slots, function(a, o) {
2175
+ return { key: o, fn: function(u) {
2176
+ return [e._t(o, null, null, u || {})];
2177
+ } };
2178
+ })], null, !0) }, "lume-chart", n.props, !1));
2179
+ }, ta = [], na = /* @__PURE__ */ w(
2180
+ qr,
2181
+ ea,
2182
+ ta,
2183
+ !1,
2184
+ null,
2185
+ null,
2186
+ null,
2187
+ null
2188
+ );
2189
+ const Ma = na.exports, ra = {
2190
+ [A.VERTICAL]: {
2191
+ withTooltip: !0,
2192
+ xAxisOptions: {},
2193
+ yAxisOptions: { gridLines: !0 },
2194
+ margins: z.VERTICAL
2195
+ },
2196
+ [A.HORIZONTAL]: {
2197
+ withTooltip: !0,
2198
+ xAxisOptions: { gridLines: !0 },
2199
+ yAxisOptions: { gridLines: !1 },
2200
+ margins: z.HORIZONTAL,
2201
+ tooltipOptions: { position: "right" }
2202
+ }
2203
+ }, aa = /* @__PURE__ */ $({
2204
+ __name: "lume-stacked-bar-chart",
2205
+ props: {
2206
+ ...X()
2207
+ },
2208
+ setup(t) {
2209
+ const e = t, r = Z(j()), { data: n, orientation: a, options: o } = R(e), u = c(
2210
+ () => ra[a.value || A.VERTICAL]
2211
+ // needs to be computed so that default options are reactive
2212
+ ), { allOptions: i } = H(o, u), { internalData: l } = Le(n), { groupedData: s } = it(l), { stackedXScaleGenerator: v, stackedYScaleGenerator: d } = Vr(
2213
+ s,
2214
+ a
2215
+ );
2216
+ return { __sfc: !0, props: e, slots: r, data: n, orientation: a, options: o, baseOptions: u, allOptions: i, internalData: l, groupedData: s, stackedXScaleGenerator: v, stackedYScaleGenerator: d, LumeChart: K, LumeBarGroup: xe };
2217
+ }
2218
+ });
2219
+ var oa = function() {
2220
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2221
+ return r(n.LumeChart, e._b({ attrs: { "chart-type": "stacked-bar", options: n.allOptions, "x-scale": n.stackedXScaleGenerator, "y-scale": n.stackedYScaleGenerator, "data-j-stacked-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2222
+ return [r(n.LumeBarGroup, e._b({ attrs: { type: "stacked" } }, "lume-bar-group", a, !1))];
2223
+ } }, e._l(n.slots, function(a, o) {
2224
+ return { key: o, fn: function(u) {
2225
+ return [e._t(o, null, null, u || {})];
2226
+ } };
2227
+ })], null, !0) }, "lume-chart", n.props, !1));
2228
+ }, ua = [], la = /* @__PURE__ */ w(
2229
+ aa,
2230
+ oa,
2231
+ ua,
2232
+ !1,
2233
+ null,
2234
+ null,
2235
+ null,
2236
+ null
2237
+ );
2238
+ const za = la.exports, Fe = 2, ia = /* @__PURE__ */ $({
2239
+ __name: "lume-line",
2240
+ props: {
2241
+ pathDefinition: {
2242
+ type: String,
2243
+ required: !0
2244
+ },
2245
+ width: {
2246
+ type: Number,
2247
+ default: Fe
2248
+ },
2249
+ color: {
2250
+ type: String,
2251
+ default: G.Skyblue
2252
+ },
2253
+ dashed: {
2254
+ type: Boolean,
2255
+ default: !1
2256
+ },
2257
+ transition: {
2258
+ type: Boolean,
2259
+ default: !0
2260
+ },
2261
+ animationDelay: {
2262
+ type: Number,
2263
+ default: 0
2264
+ },
2265
+ animationDuration: {
2266
+ type: Number,
2267
+ default: 0.2
2268
+ }
2269
+ },
2270
+ emits: ["click"],
2271
+ setup(t, { emit: e }) {
2272
+ const r = L(null);
2273
+ return B(() => ue(r.value)), { __sfc: !0, DEFAULT_LINE_WIDTH: Fe, emit: e, root: r };
2274
+ }
2275
+ });
2276
+ var sa = function() {
2277
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2278
+ return r("path", { ref: "root", staticClass: "lume-line", class: {
2279
+ [`lume-stroke--${e.color}`]: !0,
2280
+ "lume-line--dashed": e.dashed,
2281
+ "lume-line--transition": e.transition
2282
+ }, style: {
2283
+ animationDelay: e.transition && e.animationDelay + "s",
2284
+ animationDuration: e.transition && e.animationDuration + "s"
2285
+ }, attrs: { d: e.pathDefinition, "stroke-width": e.width, "data-j-line": "" }, on: { click: function(a) {
2286
+ return n.emit("click", a);
2287
+ } } });
2288
+ }, ca = [], da = /* @__PURE__ */ w(
2289
+ ia,
2290
+ sa,
2291
+ ca,
2292
+ !1,
2293
+ null,
2294
+ "08896455",
2295
+ null,
2296
+ null
2297
+ );
2298
+ const va = da.exports, Me = 4, _a = /* @__PURE__ */ $({
2299
+ __name: "lume-point",
2300
+ props: {
2301
+ x: { type: Number, required: !0 },
2302
+ y: { type: Number, required: !0 },
2303
+ color: {
2304
+ type: String,
2305
+ default: G.Skyblue
2306
+ },
2307
+ radius: {
2308
+ type: Number,
2309
+ default: Me
2310
+ },
2311
+ active: {
2312
+ type: Boolean,
2313
+ default: !1
2314
+ }
2315
+ },
2316
+ emits: ["click"],
2317
+ setup(t, { emit: e }) {
2318
+ const r = t, n = L(null), a = c(() => r.radius / 2);
2319
+ return B(() => ue(n.value)), { __sfc: !0, DEFAULT_RADIUS: Me, props: r, emit: e, root: n, strokeWidth: a };
2320
+ }
2321
+ });
2322
+ var pa = function() {
2323
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2324
+ return r("circle", { ref: "root", staticClass: "lume-point", class: `lume-stroke--${e.color}`, attrs: { cx: e.x, cy: e.y, r: e.active ? e.radius : 0, "stroke-width": n.strokeWidth, "data-j-point": "" }, on: { click: function(a) {
2325
+ return n.emit("click", a);
2326
+ } } });
2327
+ }, fa = [], ma = /* @__PURE__ */ w(
2328
+ _a,
2329
+ pa,
2330
+ fa,
2331
+ !1,
2332
+ null,
2333
+ "9bacbd7d",
2334
+ null,
2335
+ null
2336
+ );
2337
+ const ha = ma.exports;
2338
+ function st(t) {
2339
+ function e(o) {
2340
+ let u = null;
2341
+ return o == null ? void 0 : o.reduce((i, l, s) => (l == null || l.value == null ? (u ? u.push(s) : u = [s], s === (o == null ? void 0 : o.length) - 1 && i.push(u)) : u && (i.push(u), u = null), i), []);
2342
+ }
2343
+ function r(o, u, i, l) {
2344
+ const d = Math.abs(o - u) / (i + 1) * (l + 1);
2345
+ return o > u ? o - d : o + d;
2346
+ }
2347
+ function n(o) {
2348
+ return function(i) {
2349
+ return !!o.find(
2350
+ (l) => l.includes(i) || l.includes(i - 1)
2351
+ );
2352
+ };
2353
+ }
2354
+ return { computedLineData: c(() => t.value.map((o) => {
2355
+ const u = e(o.values);
2356
+ return {
2357
+ ...o,
2358
+ isDashed: n(u),
2359
+ values: o.values.map((i, l) => {
2360
+ var v, d;
2361
+ const s = u.find(
2362
+ (f) => f.includes(l)
2363
+ );
2364
+ if (s) {
2365
+ const f = s[0] - 1, g = s[s.length - 1] + 1;
2366
+ let _ = (v = o.values[f]) == null ? void 0 : v.value, p = (d = o.values[g]) == null ? void 0 : d.value;
2367
+ return _ == null && (_ = p), p == null && (p = _), {
2368
+ value: r(
2369
+ _,
2370
+ p,
2371
+ s.length,
2372
+ s.indexOf(l)
2373
+ ),
2374
+ label: qe
2375
+ };
2376
+ }
2377
+ return i;
2378
+ })
2379
+ };
2380
+ })) };
2381
+ }
2382
+ function ga(t, e) {
2383
+ const r = be(t) / 2;
2384
+ return (n, a) => t(t.domain()[e + (a - 1)]) + r;
2385
+ }
2386
+ function ya(t, e) {
2387
+ return (r, n) => t(e + (n - 1));
2388
+ }
2389
+ function ba(t, e, r, n) {
2390
+ return $t().x(
2391
+ W(r) ? ga(r, t) : ya(r, t)
2392
+ ).y((o) => n(o))(e);
2393
+ }
2394
+ const ze = 1, ka = /* @__PURE__ */ $({
2395
+ __name: "lume-line-group",
2396
+ props: {
2397
+ ...ie(),
2398
+ withPoints: {
2399
+ type: Boolean,
2400
+ default: !0
2401
+ },
2402
+ transition: {
2403
+ type: Boolean,
2404
+ default: !0
2405
+ }
2406
+ },
2407
+ emits: ["line-click", "point-click", "lume__internal--hover"],
2408
+ setup(t, { emit: e }) {
2409
+ const r = t, { data: n, options: a, xScale: o, yScale: u } = R(r), i = kt(
2410
+ "tooltipAnchorAttributes",
2411
+ null
2412
+ ), { updateTooltipAnchorAttributes: l } = ot(
2413
+ i,
2414
+ a,
2415
+ o,
2416
+ u
2417
+ ), s = c(() => {
2418
+ if (n.value.every((T) => T.isDashed))
2419
+ return n.value;
2420
+ const { computedLineData: m } = st(n);
2421
+ return a.value.withTooltip !== !1 && (i != null && i.value) && l(m.value), m.value;
2422
+ }), v = c(() => {
2423
+ if (r.hoveredIndex === -1)
2424
+ return;
2425
+ const m = Ht(
2426
+ s.value,
2427
+ r.hoveredIndex
2428
+ );
2429
+ return {
2430
+ d: `M ${fe(o.value, r.hoveredIndex)},${u.value.range()[1]}
2431
+ V ${u.value(m)}`
2432
+ // Move to X index, Vertical line to the highest point
2433
+ };
2434
+ }), d = c(
2435
+ () => o.value && ze / (Bt(o.value) - 1)
2436
+ // Subtracting the first line (read below)
2437
+ ), f = c(
2438
+ () => {
2439
+ var m;
2440
+ return ((m = a.value) == null ? void 0 : m.lineWidth) * 2 || void 0;
2441
+ }
2442
+ // If no `lineWidth`, returns NaN which needs to be undefined
2443
+ ), g = c(() => be(o.value) / 2), _ = c(() => o.value.domain());
2444
+ function p(m) {
2445
+ return s.value[m].values;
2446
+ }
2447
+ function O(m, T) {
2448
+ var I, N;
2449
+ const E = m === 0 ? [] : [
2450
+ (I = p(T)[m - 1]) == null ? void 0 : I.value,
2451
+ (N = p(T)[m]) == null ? void 0 : N.value
2452
+ ];
2453
+ return ba(
2454
+ m,
2455
+ E,
2456
+ o.value,
2457
+ u.value
2458
+ ) || "";
2459
+ }
2460
+ function h(m) {
2461
+ return {
2462
+ animationDelay: m < 2 ? 0 : (m - 1) * d.value,
2463
+ animationDuration: d.value
2464
+ };
2465
+ }
2466
+ function b(m, T) {
2467
+ var I;
2468
+ const E = (I = p(T)[m]) == null ? void 0 : I.value;
2469
+ return {
2470
+ x: W(o.value) ? r.xScale(_.value[m]) + g.value : r.xScale(m),
2471
+ y: u.value(E)
2472
+ };
2473
+ }
2474
+ function y(m) {
2475
+ return r.hoveredIndex === m;
2476
+ }
2477
+ return { __sfc: !0, LUME_TRANSITION_TIME_FULL: ze, props: r, emit: e, data: n, options: a, xScale: o, yScale: u, tooltipAnchorAttributes: i, updateTooltipAnchorAttributes: l, computedGroupData: s, overlayLineAttributes: v, animationDuration: d, pointRadius: f, xAxisOffset: g, domain: _, getValuesFromDataset: p, getPathDefinition: O, getLineTransitionParams: h, getPointPosition: b, isPointActive: y, LumeLine: va, LumePoint: ha };
2478
+ }
2479
+ });
2480
+ var Aa = function() {
2481
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2482
+ return r("g", { staticClass: "lume-line-group", attrs: { "data-j-lume-line-group": "" } }, [r("path", e._b({ staticClass: "lume-line-group__overlay-line", attrs: { "data-j-lume-line-group__overlay-line": "" } }, "path", n.overlayLineAttributes, !1)), e._l(n.computedGroupData, function(a, o) {
2483
+ return r("g", { key: a.label, staticClass: "lume-line-group__group" }, [r("g", { staticClass: "lume-line-group__lines" }, e._l(a.values, function(u, i) {
2484
+ return r(n.LumeLine, e._b({ key: `line-${i}`, attrs: { color: a.color, dashed: a.isDashed(i), "path-definition": n.getPathDefinition(i, o), transition: e.transition, width: n.options.lineWidth }, on: { click: function(l) {
2485
+ return n.emit("line-click", { index: i, datasetIndex: o, event: l });
2486
+ } } }, "lume-line", n.getLineTransitionParams(i), !1));
2487
+ }), 1), e.withPoints ? r("g", { staticClass: "lume-line-group__points", attrs: { "data-j-lume-line-group__points": "" } }, e._l(a.values, function(u, i) {
2488
+ return r(n.LumePoint, e._b({ key: `point-${i}`, attrs: { active: n.isPointActive(i), color: a.color, index: i, radius: n.pointRadius }, on: { click: function(l) {
2489
+ return n.emit("point-click", { index: i, datasetIndex: o, event: l });
2490
+ } } }, "lume-point", n.getPointPosition(i, o), !1));
2491
+ }), 1) : e._e()]);
2492
+ })], 2);
2493
+ }, Oa = [], Ta = /* @__PURE__ */ w(
2494
+ ka,
2495
+ Aa,
2496
+ Oa,
2497
+ !1,
2498
+ null,
2499
+ "62f6f279",
2500
+ null,
2501
+ null
2502
+ );
2503
+ const ct = Ta.exports, La = {
2504
+ margins: z.VERTICAL,
2505
+ startOnZero: !0,
2506
+ withTooltip: !0,
2507
+ xAxisOptions: {},
2508
+ yAxisOptions: { gridLines: !0 }
2509
+ }, xa = /* @__PURE__ */ $({
2510
+ __name: "lume-line-chart",
2511
+ props: {
2512
+ ...X(null, !1)
2513
+ },
2514
+ setup(t) {
2515
+ const e = t, r = Z(j()), { options: n } = R(e), { allOptions: a } = H(n, La);
2516
+ return { __sfc: !0, props: e, slots: r, options: n, allOptions: a, LumeChart: K, LumeLineGroup: ct };
2517
+ }
2518
+ });
2519
+ var $a = function() {
2520
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2521
+ return r(n.LumeChart, e._b({ attrs: { "chart-type": "line", options: n.allOptions, "data-j-lume-line-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2522
+ return [r(n.LumeLineGroup, e._b({}, "lume-line-group", a, !1))];
2523
+ } }, e._l(n.slots, function(a, o) {
2524
+ return { key: o, fn: function(u) {
2525
+ return [e._t(o, null, null, u || {})];
2526
+ } };
2527
+ })], null, !0) }, "lume-chart", n.props, !1));
2528
+ }, wa = [], Ia = /* @__PURE__ */ w(
2529
+ xa,
2530
+ $a,
2531
+ wa,
2532
+ !1,
2533
+ null,
2534
+ null,
2535
+ null,
2536
+ null
2537
+ );
2538
+ const Wa = Ia.exports;
2539
+ function Da(t) {
2540
+ return { areaPathDefinition: c(
2541
+ () => function(r, n) {
2542
+ if (!r || !n)
2543
+ return;
2544
+ const a = t.value[0].values;
2545
+ return wt().x((o, u) => r(u)).y0(n(Math.min(...n.domain()))).y1((o) => n(o.value))(a);
2546
+ }
2547
+ ) };
2548
+ }
2549
+ const Ra = {
2550
+ margins: {
2551
+ top: 0,
2552
+ right: 0,
2553
+ bottom: 0,
2554
+ left: 0
2555
+ },
2556
+ withAxes: !1,
2557
+ showArea: !0,
2558
+ startOnZero: !0,
2559
+ withLegend: !1,
2560
+ tooltipOptions: {
2561
+ showTitle: !1
2562
+ }
2563
+ }, Ca = /* @__PURE__ */ $({
2564
+ __name: "lume-sparkline-chart",
2565
+ props: {
2566
+ ...rt(null),
2567
+ ...oe()
2568
+ },
2569
+ setup(t, { expose: e }) {
2570
+ const r = t, n = Z(j()), { data: a, options: o } = R(r), { internalData: u } = Le(a), { allOptions: i } = H(o, Ra), { computedLineData: l } = st(u), { areaPathDefinition: s } = Da(l), v = c(() => u.value[0].color), d = c(
2571
+ () => a.value[0].areaColor || v.value
2572
+ );
2573
+ function f(_) {
2574
+ return {
2575
+ ..._,
2576
+ noMinSize: !0
2577
+ };
2578
+ }
2579
+ function g(_, p, O) {
2580
+ return Q().range([0, O.width]).domain([0, _[0].values.length - 1]);
2581
+ }
2582
+ return e({
2583
+ areaPathDefinition: s
2584
+ }), { __sfc: !0, props: r, slots: n, data: a, options: o, internalData: u, allOptions: i, computedLineData: l, areaPathDefinition: s, computedColor: v, areaColor: d, getSparklineOptions: f, xScaleGenerator: g, LumeChart: K, LumeLineGroup: ct };
2585
+ }
2586
+ });
2587
+ var Ea = function() {
2588
+ var e = this, r = e._self._c, n = e._self._setupProxy;
2589
+ return r(n.LumeChart, e._b({ attrs: { "chart-type": "line", options: n.getSparklineOptions(n.allOptions), "x-scale": n.xScaleGenerator }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2590
+ return [n.allOptions.showArea ? r("path", { class: [
2591
+ "sparkline-chart__area",
2592
+ `lume-fill--${n.areaColor || n.computedColor}`,
2593
+ "lume-fill--faded"
2594
+ ], attrs: { d: n.areaPathDefinition(a.xScale, a.yScale), "data-j-sparkline__area": "" } }) : e._e(), r(n.LumeLineGroup, e._b({ attrs: { "with-points": !1 } }, "lume-line-group", a, !1))];
2595
+ } }, e._l(n.slots, function(a, o) {
2596
+ return { key: o, fn: function(u) {
2597
+ return [e._t(o, null, null, u || {})];
2598
+ } };
2599
+ })], null, !0) }, "lume-chart", n.props, !1));
2600
+ }, Na = [], Pa = /* @__PURE__ */ w(
2601
+ Ca,
2602
+ Ea,
2603
+ Na,
2604
+ !1,
2605
+ null,
2606
+ "60a59b77",
2607
+ null,
2608
+ null
2609
+ );
2610
+ const Za = Pa.exports;
2611
+ export {
2612
+ cn as L,
2613
+ Va as a,
2614
+ Fa as b,
2615
+ Ma as c,
2616
+ za as d,
2617
+ Wa as e,
2618
+ Za as f,
2619
+ K as g,
2620
+ An as h,
2621
+ $n as i,
2622
+ Cn as j,
2623
+ Te as k,
2624
+ ja as l,
2625
+ va as m,
2626
+ ha as n,
2627
+ Tr as o,
2628
+ xe as p,
2629
+ ct as q,
2630
+ Un as r
2631
+ };
2632
+ //# sourceMappingURL=9373652f.js.map