@adyen/lume 1.13.0 → 1.15.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.
Files changed (32) hide show
  1. package/dist/@types/components/charts/lume-alluvial-diagram/defaults.d.ts.map +1 -1
  2. package/dist/@types/components/groups/lume-alluvial-group/components/lume-alluvial-node-header/lume-alluvial-node-header.vue.d.ts +13 -1
  3. package/dist/@types/components/groups/lume-alluvial-group/components/lume-alluvial-node-header/lume-alluvial-node-header.vue.d.ts.map +1 -1
  4. package/dist/@types/components/groups/lume-alluvial-group/helpers.d.ts +20 -2
  5. package/dist/@types/components/groups/lume-alluvial-group/helpers.d.ts.map +1 -1
  6. package/dist/@types/components/groups/lume-alluvial-group/lume-alluvial-group.vue.d.ts +2 -1
  7. package/dist/@types/components/groups/lume-alluvial-group/lume-alluvial-group.vue.d.ts.map +1 -1
  8. package/dist/@types/types/alluvial.d.ts +3 -0
  9. package/dist/@types/types/alluvial.d.ts.map +1 -1
  10. package/dist/@types/types/options.d.ts +4 -1
  11. package/dist/@types/types/options.d.ts.map +1 -1
  12. package/dist/common/BSSy21i7.js +5 -0
  13. package/dist/common/BSSy21i7.js.map +1 -0
  14. package/dist/common/asrcm8__.js +5 -0
  15. package/dist/common/asrcm8__.js.map +1 -0
  16. package/dist/common/es6xM4zX.js +5 -0
  17. package/dist/common/es6xM4zX.js.map +1 -0
  18. package/dist/common/{vDk1lu85.js → h4DBladZ.js} +1416 -1352
  19. package/dist/common/h4DBladZ.js.map +1 -0
  20. package/dist/index.js +1 -1
  21. package/dist/plugin.js +1 -1
  22. package/dist/scss/components/lume-alluvial-group.scss +23 -0
  23. package/dist/scss/main.scss +4 -4
  24. package/dist/styles/main.css +1 -1
  25. package/package.json +1 -1
  26. package/dist/common/Aka2OjK8.js +0 -5
  27. package/dist/common/Aka2OjK8.js.map +0 -1
  28. package/dist/common/BAc0dIxQ.js +0 -5
  29. package/dist/common/BAc0dIxQ.js.map +0 -1
  30. package/dist/common/BkCJnqDA.js +0 -5
  31. package/dist/common/BkCJnqDA.js.map +0 -1
  32. package/dist/common/vDk1lu85.js.map +0 -1
@@ -1,8 +1,8 @@
1
- import { defineComponent as R, ref as I, isRef as Lt, computed as f, watch as H, toRefs as F, inject as Ee, reactive as $e, onMounted as ae, watchEffect as Tt, onBeforeUnmount as Ot, useSlots as X, nextTick as Pe, provide as De, defineAsyncComponent as He } from "vue";
2
- import { sankeyLinkHorizontal as Zt, sankey as Xt, sankeyJustify as Yt } from "d3-sankey";
3
- import { format as Kt, ticks as Jt, scaleLinear as ge, scaleBand as ye, link as Qt, line as qt, area as en } from "d3";
4
- import { createPopper as tn } from "@popperjs/core";
5
- const nn = /* @__PURE__ */ R({
1
+ import { defineComponent as R, ref as I, isRef as Nt, computed as v, watch as H, toRefs as V, inject as Oe, reactive as Ie, onMounted as re, watchEffect as Et, onBeforeUnmount as $t, useSlots as X, nextTick as Be, provide as Pe, defineAsyncComponent as Re } from "vue";
2
+ import { sankeyLinkHorizontal as Jt, sankey as Qt, sankeyJustify as qt } from "d3-sankey";
3
+ import { format as en, ticks as tn, scaleLinear as ge, scaleBand as he, link as nn, line as rn, area as an } from "d3";
4
+ import { createPopper as on } from "@popperjs/core";
5
+ const ln = /* @__PURE__ */ R({
6
6
  __name: "lume-tick",
7
7
  props: {
8
8
  value: {
@@ -44,14 +44,14 @@ const nn = /* @__PURE__ */ R({
44
44
  return e({ ref: n }), { __sfc: !0, emit: r, labelRef: n };
45
45
  }
46
46
  });
47
- function D(t, e, r, n, a, u, o, i) {
48
- var l = typeof t == "function" ? t.options : t;
49
- return e && (l.render = e, l.staticRenderFns = r, l._compiled = !0), u && (l._scopeId = "data-v-" + u), {
47
+ function S(t, e, r, n, a, o, l, i) {
48
+ var u = typeof t == "function" ? t.options : t;
49
+ return e && (u.render = e, u.staticRenderFns = r, u._compiled = !0), o && (u._scopeId = "data-v-" + o), {
50
50
  exports: t,
51
- options: l
51
+ options: u
52
52
  };
53
53
  }
54
- var rn = function() {
54
+ var un = function() {
55
55
  var e = this, r = e._self._c, n = e._self._setupProxy;
56
56
  return r("g", e._b({ staticClass: "axis__tick", class: {
57
57
  "axis__tick--hovered": e.isHovered,
@@ -61,15 +61,15 @@ var rn = function() {
61
61
  }, click: function(a) {
62
62
  return n.emit("click", a);
63
63
  } } }, "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()]);
64
- }, an = [], on = /* @__PURE__ */ D(
65
- nn,
66
- rn,
67
- an,
64
+ }, sn = [], cn = /* @__PURE__ */ S(
65
+ ln,
66
+ un,
67
+ sn,
68
68
  !1,
69
69
  null,
70
70
  "59ddc0a6"
71
71
  );
72
- const un = on.exports, ln = [
72
+ const dn = cn.exports, vn = [
73
73
  "controls",
74
74
  "legend",
75
75
  "axes",
@@ -77,64 +77,64 @@ const un = on.exports, ln = [
77
77
  "tooltip",
78
78
  "tooltip-content"
79
79
  ];
80
- function It() {
80
+ function wt() {
81
81
  return process.env.NODE_ENV === "production";
82
82
  }
83
- function Et(t) {
83
+ function Dt(t) {
84
84
  return (t == null ? void 0 : t.map(
85
85
  (e) => e.values.map((r) => r == null ? void 0 : r.value).flat()
86
86
  ).flat()) || [];
87
87
  }
88
- function Ze(t) {
88
+ function Ke(t) {
89
89
  return t.length === 1;
90
90
  }
91
- function sn(t) {
91
+ function fn(t) {
92
92
  return !!t && t.every(
93
93
  (e) => "color" in e
94
94
  );
95
95
  }
96
- function Re(t) {
96
+ function Ce(t) {
97
97
  return !!t && typeof t == "object" && !Array.isArray(t);
98
98
  }
99
- function $t(t, e) {
99
+ function Ht(t, e) {
100
100
  const r = { ...t };
101
101
  return Object.entries(e).forEach(([n, a]) => {
102
- r[n] = Re(t[n]) && Re(a) ? $t(t[n], a) : a;
102
+ r[n] = Ce(t[n]) && Ce(a) ? Ht(t[n], a) : a;
103
103
  }), r;
104
104
  }
105
- function cn(t) {
106
- return t != null && Re(t) && "value" in t;
105
+ function pn(t) {
106
+ return t != null && Ce(t) && "value" in t;
107
107
  }
108
108
  function K(t) {
109
109
  return (t == null ? void 0 : t.bandwidth) !== void 0;
110
110
  }
111
- function dn(t) {
111
+ function mn(t) {
112
112
  return K(t) ? t.step() : Math.max(...t.range()) / Math.max(...t.domain());
113
113
  }
114
- function vn(t) {
114
+ function _n(t) {
115
115
  const [e, r] = t.domain();
116
116
  return e == null || r == null || e === 0 && r === 0;
117
117
  }
118
- const fn = (t, e) => {
118
+ const gn = (t, e) => {
119
119
  if (!t)
120
120
  throw new Error("Data is not a valid array");
121
121
  if (t.length === 0)
122
122
  throw new Error("Cannot get highest value from empty array");
123
123
  t.some(
124
124
  ({ values: n }) => n.length - 1 >= e
125
- ) || re(J.IndexExceedsLengthOfDataSets);
125
+ ) || ne(J.IndexExceedsLengthOfDataSets);
126
126
  };
127
- function pn(t, e) {
127
+ function hn(t, e) {
128
128
  var r;
129
- return fn(t, e), ((r = t.reduce(
129
+ return gn(t, e), ((r = t.reduce(
130
130
  (n, a) => {
131
- var u, o;
132
- return (((u = n.values[e]) == null ? void 0 : u.value) ?? 0) > (((o = a.values[e]) == null ? void 0 : o.value) ?? 0) ? n : a;
131
+ var o, l;
132
+ return (((o = n.values[e]) == null ? void 0 : o.value) ?? 0) > (((l = a.values[e]) == null ? void 0 : l.value) ?? 0) ? n : a;
133
133
  }
134
134
  ).values[e]) == null ? void 0 : r.value) || 0;
135
135
  }
136
- function Nt(t) {
137
- const e = Lt(t) ? t.value : t;
136
+ function St(t) {
137
+ const e = Nt(t) ? t.value : t;
138
138
  if (!e)
139
139
  throw new Error("No empty array can be created from specified data value");
140
140
  const r = Math.max(
@@ -143,17 +143,17 @@ function Nt(t) {
143
143
  );
144
144
  return Array(r).fill(null);
145
145
  }
146
- function mn(t) {
146
+ function yn(t) {
147
147
  return K(t) ? t.domain().length : Math.max(...t.domain());
148
148
  }
149
- function _n(t, e) {
149
+ function bn(t, e) {
150
150
  return (r) => Math.round(t * (1 - r) + e * r);
151
151
  }
152
- function hn(t, e, r) {
152
+ function kn(t, e, r) {
153
153
  const n = e, a = t.slice(0, n);
154
154
  return t.slice(n).concat(a);
155
155
  }
156
- function ce(t) {
156
+ function se(t) {
157
157
  if (t.groups) {
158
158
  const e = Object.keys(t);
159
159
  return Object.assign(
@@ -163,32 +163,32 @@ function ce(t) {
163
163
  }
164
164
  return t;
165
165
  }
166
- function gn(t) {
166
+ function xn(t) {
167
167
  return Object.assign(
168
168
  {},
169
169
  ...Object.keys(t).map(
170
- (e) => ln.includes(e) ? {} : { [e]: t[e] }
170
+ (e) => vn.includes(e) ? {} : { [e]: t[e] }
171
171
  )
172
172
  );
173
173
  }
174
- function Xe(t, e) {
174
+ function Je(t, e) {
175
175
  const r = e - t.length;
176
176
  return r > 0 ? [...t, ...Array(r).fill({ value: null })] : t;
177
177
  }
178
178
  var J = /* @__PURE__ */ ((t) => (t.DatasetLength = `Our guidelines highly recommend not having more than 5 datasets in one chart.
179
179
  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.Empty = "The dataset(s) provided are empty.", 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.InvalidHoveredIndex = "The provided hovered index is not valid for the data of this chart.", t.InvalidHoveredElement = "The provided hovered element is not valid for the data of this diagram.", t.IndexExceedsLengthOfDataSets = "Index exceeds length of all of the datasets", t))(J || {});
180
- const yn = "[lume] ";
181
- function re(t, e = !0) {
182
- e && It() || console.warn(yn + "Warning: " + t);
180
+ const Ln = "[lume] ";
181
+ function ne(t, e = !0) {
182
+ e && wt() || console.warn(Ln + "Warning: " + t);
183
183
  }
184
- const Oe = (t) => {
184
+ const Te = (t) => {
185
185
  let e = null;
186
186
  switch (typeof t) {
187
187
  case "string":
188
188
  try {
189
- e = Kt(t);
189
+ e = en(t);
190
190
  } catch {
191
- re(J.InvalidFormat), e = null;
191
+ ne(J.InvalidFormat), e = null;
192
192
  }
193
193
  break;
194
194
  case "function":
@@ -201,46 +201,46 @@ const Oe = (t) => {
201
201
  return e ? e(...n) : n[0];
202
202
  }
203
203
  return r;
204
- }, be = () => ({
204
+ }, ye = () => ({
205
205
  options: {
206
206
  type: Object,
207
207
  default: () => ({})
208
208
  }
209
209
  });
210
210
  function Q(t, e) {
211
- return { allOptions: f(() => {
212
- const n = Lt(e) ? e == null ? void 0 : e.value : e;
213
- return n ? $t(n, t.value) : t.value;
211
+ return { allOptions: v(() => {
212
+ const n = Nt(e) ? e == null ? void 0 : e.value : e;
213
+ return n ? Ht(n, t.value) : t.value;
214
214
  }) };
215
215
  }
216
- const bn = 0.2;
217
- function kn(t, e, r) {
218
- const n = I(), a = f(() => Math.max(...t.value.range())), u = f(() => e.value.length);
219
- function o() {
216
+ const Tn = 0.2;
217
+ function An(t, e, r) {
218
+ const n = I(), a = v(() => Math.max(...t.value.range())), o = v(() => e.value.length);
219
+ function l() {
220
220
  if (!e.value) return;
221
- const l = e.value.reduce(
222
- (s, v) => s + v.ref.getBoundingClientRect().width,
221
+ const u = e.value.reduce(
222
+ (s, f) => s + f.ref.getBoundingClientRect().width,
223
223
  0
224
- ), c = Math.ceil(l / u.value);
225
- n.value = c + c * bn;
224
+ ), c = Math.ceil(u / o.value);
225
+ n.value = c + c * Tn;
226
226
  }
227
- function i(l) {
227
+ function i(u) {
228
228
  if (!e.value) return !0;
229
229
  const c = r.value.skip, s = e.value.length;
230
- if (l === 0) return !0;
231
- const v = a.value / s, m = typeof c == "number" && c > 0 && c + 1 || Math.ceil(n.value / v);
232
- return l % m === 0;
230
+ if (u === 0) return !0;
231
+ const f = a.value / s, m = typeof c == "number" && c > 0 && c + 1 || Math.ceil(n.value / f);
232
+ return u % m === 0;
233
233
  }
234
- return H(e, o), { showTick: i };
234
+ return H(e, l), { showTick: i };
235
235
  }
236
236
  const O = {
237
237
  HORIZONTAL: "horizontal",
238
238
  VERTICAL: "vertical"
239
- }, xn = {
239
+ }, On = {
240
240
  SINGLE: "single",
241
241
  GROUPED: "grouped",
242
242
  STACKED: "stacked"
243
- }, wt = "No data", ot = 20, Dt = 0.33, Ht = 0.5, Pt = 12, ke = 8, An = 1, Ln = [
243
+ }, Pt = "No data", st = 20, Rt = 0.33, Bt = 0.5, Ct = 12, be = 8, In = 1, Nn = [
244
244
  "auto",
245
245
  "auto-start",
246
246
  "auto-end",
@@ -258,9 +258,9 @@ const O = {
258
258
  "left-end"
259
259
  ];
260
260
  function Ne(t) {
261
- t != null && t.closest("svg") || re(J.NotContainedInSvg);
261
+ t != null && t.closest("svg") || ne(J.NotContainedInSvg);
262
262
  }
263
- const Rt = {
263
+ const Ft = {
264
264
  /** Displays a line for each tick. */
265
265
  gridLines: !1,
266
266
  /** Displays the axis title. */
@@ -276,37 +276,37 @@ const Rt = {
276
276
  tickFormat: null,
277
277
  /** Space between the tick label and the axis line. */
278
278
  tickPadding: 12
279
- }, Tn = {
280
- ...Rt,
279
+ }, En = {
280
+ ...Ft,
281
281
  withTitle: !1,
282
282
  skip: !0
283
- }, On = {
284
- ...Rt,
283
+ }, $n = {
284
+ ...Ft,
285
285
  gridLines: !0
286
- }, In = function(t, e, r) {
287
- const n = f(() => t.value.step() * t.value.paddingInner() / 2);
288
- function a(l, c) {
286
+ }, wn = function(t, e, r) {
287
+ const n = v(() => t.value.step() * t.value.paddingInner() / 2);
288
+ function a(u, c) {
289
289
  return {
290
- transform: `translate(${(t.value(c) ?? t.value(l)) - n.value}, 0)`
290
+ transform: `translate(${(t.value(c) ?? t.value(u)) - n.value}, 0)`
291
291
  };
292
292
  }
293
- function u(l) {
293
+ function o(u) {
294
294
  var s;
295
295
  const c = Math.max(
296
296
  t.value.step(),
297
- (l ? (s = l.getComputedTextLength) == null ? void 0 : s.call(l) : t.value.step()) + 20
297
+ (u ? (s = u.getComputedTextLength) == null ? void 0 : s.call(u) : t.value.step()) + 20
298
298
  );
299
299
  return {
300
300
  x: -(c - t.value.step()) / 2,
301
301
  width: c,
302
- height: r.value.tickPadding + Pt + ke
302
+ height: r.value.tickPadding + Ct + be
303
303
  };
304
304
  }
305
- function o() {
306
- const l = t.value.step() / 2;
305
+ function l() {
306
+ const u = t.value.step() / 2;
307
307
  return {
308
- x1: l,
309
- x2: l,
308
+ x1: u,
309
+ x2: u,
310
310
  y1: -e.value.height
311
311
  // Negative height means it goes from bottom to top
312
312
  };
@@ -320,32 +320,32 @@ const Rt = {
320
320
  };
321
321
  }
322
322
  return {
323
- getGridLinesAttributes: o,
324
- getTickGhostAttributes: u,
323
+ getGridLinesAttributes: l,
324
+ getTickGhostAttributes: o,
325
325
  getTickGroupAttributes: a,
326
326
  getTickLabelAttributes: i
327
327
  };
328
- }, En = function(t, e, r) {
329
- const n = f(() => t.value.step() * t.value.paddingInner() / 2);
330
- function a(l, c) {
328
+ }, Dn = function(t, e, r) {
329
+ const n = v(() => t.value.step() * t.value.paddingInner() / 2);
330
+ function a(u, c) {
331
331
  return {
332
- transform: `translate(0, ${(t.value(c) ?? t.value(l)) - n.value})`
332
+ transform: `translate(0, ${(t.value(c) ?? t.value(u)) - n.value})`
333
333
  };
334
334
  }
335
- function u(l) {
335
+ function o(u) {
336
336
  var s;
337
- const c = (l ? (s = l.getComputedTextLength) == null ? void 0 : s.call(l) : 42) + r.value.tickPadding + ke;
337
+ const c = (u ? (s = u.getComputedTextLength) == null ? void 0 : s.call(u) : 42) + r.value.tickPadding + be;
338
338
  return {
339
339
  x: -c,
340
340
  width: c,
341
341
  height: t.value.step()
342
342
  };
343
343
  }
344
- function o() {
345
- const l = t.value.step() / 2;
344
+ function l() {
345
+ const u = t.value.step() / 2;
346
346
  return {
347
- y1: l,
348
- y2: l,
347
+ y1: u,
348
+ y2: u,
349
349
  x1: e.value.width
350
350
  };
351
351
  }
@@ -358,29 +358,29 @@ const Rt = {
358
358
  };
359
359
  }
360
360
  return {
361
- getGridLinesAttributes: o,
362
- getTickGhostAttributes: u,
361
+ getGridLinesAttributes: l,
362
+ getTickGhostAttributes: o,
363
363
  getTickGroupAttributes: a,
364
364
  getTickLabelAttributes: i
365
365
  };
366
- }, $n = function(t, e, r) {
367
- const n = f(() => {
368
- const l = t.value.ticks();
369
- return l.length > 1 ? t.value(l[1]) - t.value(l[0]) : 0;
366
+ }, Hn = function(t, e, r) {
367
+ const n = v(() => {
368
+ const u = t.value.ticks();
369
+ return u.length > 1 ? t.value(u[1]) - t.value(u[0]) : 0;
370
370
  });
371
- function a(l) {
371
+ function a(u) {
372
372
  return {
373
- transform: `translate(${t.value(l)}, 0)`
373
+ transform: `translate(${t.value(u)}, 0)`
374
374
  };
375
375
  }
376
- function u() {
376
+ function o() {
377
377
  return {
378
- height: r.value.tickPadding + Pt + ke,
378
+ height: r.value.tickPadding + Ct + be,
379
379
  width: n.value,
380
380
  x: -(n.value / 2)
381
381
  };
382
382
  }
383
- function o() {
383
+ function l() {
384
384
  return {
385
385
  y1: -e.value.height
386
386
  };
@@ -393,24 +393,24 @@ const Rt = {
393
393
  };
394
394
  }
395
395
  return {
396
- getGridLinesAttributes: o,
397
- getTickGhostAttributes: u,
396
+ getGridLinesAttributes: l,
397
+ getTickGhostAttributes: o,
398
398
  getTickGroupAttributes: a,
399
399
  getTickLabelAttributes: i
400
400
  };
401
- }, Nn = function(t, e, r) {
402
- const n = f(() => {
403
- const l = t.value.ticks();
404
- return l.length > 1 ? t.value(l[1]) - t.value(l[0]) : 0;
401
+ }, Sn = function(t, e, r) {
402
+ const n = v(() => {
403
+ const u = t.value.ticks();
404
+ return u.length > 1 ? t.value(u[1]) - t.value(u[0]) : 0;
405
405
  });
406
- function a(l) {
406
+ function a(u) {
407
407
  return {
408
- transform: `translate(0, ${t.value(l)})`
408
+ transform: `translate(0, ${t.value(u)})`
409
409
  };
410
410
  }
411
- function u(l) {
411
+ function o(u) {
412
412
  var s;
413
- const c = (((s = l == null ? void 0 : l.getComputedTextLength) == null ? void 0 : s.call(l)) || 0) + r.value.tickPadding + ke;
413
+ const c = (((s = u == null ? void 0 : u.getComputedTextLength) == null ? void 0 : s.call(u)) || 0) + r.value.tickPadding + be;
414
414
  return {
415
415
  width: c,
416
416
  height: n.value,
@@ -418,7 +418,7 @@ const Rt = {
418
418
  y: -(n.value / 2)
419
419
  };
420
420
  }
421
- function o() {
421
+ function l() {
422
422
  return {
423
423
  x1: e.value.width
424
424
  };
@@ -431,19 +431,19 @@ const Rt = {
431
431
  };
432
432
  }
433
433
  return {
434
- getGridLinesAttributes: o,
435
- getTickGhostAttributes: u,
434
+ getGridLinesAttributes: l,
435
+ getTickGhostAttributes: o,
436
436
  getTickGroupAttributes: a,
437
437
  getTickLabelAttributes: i
438
438
  };
439
- }, wn = {
440
- "x-band-scale-axis": In,
441
- "y-band-scale-axis": En,
442
- "x-linear-scale-axis": $n,
443
- "y-linear-scale-axis": Nn
439
+ }, Pn = {
440
+ "x-band-scale-axis": wn,
441
+ "y-band-scale-axis": Dn,
442
+ "x-linear-scale-axis": Hn,
443
+ "y-linear-scale-axis": Sn
444
444
  };
445
- var Se = /* @__PURE__ */ ((t) => (t.bandScale = "band-scale-axis", t.linearScale = "linear-scale-axis", t))(Se || {}), Ce = /* @__PURE__ */ ((t) => (t.left = "left", t.bottom = "bottom", t))(Ce || {}), Te = /* @__PURE__ */ ((t) => (t.x = "bottom", t.y = "left", t))(Te || {});
446
- const Dn = /* @__PURE__ */ R({
445
+ var Fe = /* @__PURE__ */ ((t) => (t.bandScale = "band-scale-axis", t.linearScale = "linear-scale-axis", t))(Fe || {}), Ge = /* @__PURE__ */ ((t) => (t.left = "left", t.bottom = "bottom", t))(Ge || {}), Le = /* @__PURE__ */ ((t) => (t.x = "bottom", t.y = "left", t))(Le || {});
446
+ const Rn = /* @__PURE__ */ R({
447
447
  __name: "lume-axis",
448
448
  props: {
449
449
  scale: {
@@ -453,12 +453,12 @@ const Dn = /* @__PURE__ */ R({
453
453
  type: {
454
454
  type: String,
455
455
  default: void 0,
456
- validator: (t) => t in Te
456
+ validator: (t) => t in Le
457
457
  },
458
458
  position: {
459
459
  type: String,
460
460
  default: void 0,
461
- validator: (t) => t in Ce
461
+ validator: (t) => t in Ge
462
462
  },
463
463
  containerSize: {
464
464
  type: Object,
@@ -472,108 +472,108 @@ const Dn = /* @__PURE__ */ R({
472
472
  type: String,
473
473
  default: O.VERTICAL
474
474
  },
475
- ...be()
475
+ ...ye()
476
476
  },
477
477
  emits: ["mouseenter", "click", "mouseleave", "lume__internal--axis-size"],
478
478
  setup(t, { emit: e }) {
479
- const r = t, n = 16, { scale: a, containerSize: u, hoveredIndex: o, options: i, orientation: l } = F(r), c = Ee("isEmpty", I(!1)), s = $e({}), v = I(null), m = I(null), g = I(null), h = f(
480
- () => r.type ? Te[r.type] : r.position
481
- ), _ = f(
482
- () => r.type || (h.value === "left" ? "y" : "x")
483
- ), x = f(
484
- () => _.value === "x" && l.value === O.VERTICAL || _.value === "y" && l.value === O.HORIZONTAL
479
+ const r = t, n = 16, { scale: a, containerSize: o, hoveredIndex: l, options: i, orientation: u } = V(r), c = Oe("isEmpty", I(!1)), s = Ie({}), f = I(null), m = I(null), h = I(null), g = v(
480
+ () => r.type ? Le[r.type] : r.position
481
+ ), _ = v(
482
+ () => r.type || (g.value === "left" ? "y" : "x")
483
+ ), x = v(
484
+ () => _.value === "x" && u.value === O.VERTICAL || _.value === "y" && u.value === O.HORIZONTAL
485
485
  ), { allOptions: d } = Q(
486
486
  i,
487
- _.value === "x" ? Tn : On
488
- ), { showTick: p } = kn(a, v, d), y = f(
489
- () => c.value || !a.value || vn(a.value)
490
- ), b = f(() => {
491
- var E, w, P, ne;
492
- return _.value === "y" && y.value ? `translate(0, ${((E = u.value) == null ? void 0 : E.height) / 2})` : _.value === "x" && y.value ? `translate(-${((w = u.value) == null ? void 0 : w.width) / 2}, ${(P = u.value) == null ? void 0 : P.height})` : `translate(0, ${_.value === "x" ? (ne = u.value) == null ? void 0 : ne.height : 0})`;
493
- }), A = f(() => {
487
+ _.value === "x" ? En : $n
488
+ ), { showTick: p } = An(a, f, d), y = v(
489
+ () => c.value || !a.value || _n(a.value)
490
+ ), k = v(() => {
491
+ var E, w, P, te;
492
+ return _.value === "y" && y.value ? `translate(0, ${((E = o.value) == null ? void 0 : E.height) / 2})` : _.value === "x" && y.value ? `translate(-${((w = o.value) == null ? void 0 : w.width) / 2}, ${(P = o.value) == null ? void 0 : P.height})` : `translate(0, ${_.value === "x" ? (te = o.value) == null ? void 0 : te.height : 0})`;
493
+ }), T = v(() => {
494
494
  if (!a.value) return [];
495
495
  if (K(a.value))
496
496
  return a.value.labels || a.value.domain();
497
497
  const { tickCount: E } = d.value, [w, P] = a.value.domain();
498
- return Jt(w, P, E);
499
- }), $ = f(() => {
498
+ return tn(w, P, E);
499
+ }), N = v(() => {
500
500
  const { tickFormat: E } = d.value;
501
- return Oe(E);
502
- }), T = f(
503
- () => d.value.withHover && x.value && o.value > -1
504
- ), N = f(
505
- () => d.value.tickPadding + ke || n
506
- ), S = f(() => _.value === "x" ? (
501
+ return Te(E);
502
+ }), A = v(
503
+ () => d.value.withHover && x.value && l.value > -1
504
+ ), D = v(
505
+ () => d.value.tickPadding + be || n
506
+ ), C = v(() => _.value === "x" ? (
507
507
  // If x axis, get the tick height
508
508
  Math.max(
509
- ...(v.value || []).map(
509
+ ...(f.value || []).map(
510
510
  (E) => {
511
511
  var w, P;
512
- return ((P = (w = E.ref).getBBox) == null ? void 0 : P.call(w).height) + N.value;
512
+ return ((P = (w = E.ref).getBBox) == null ? void 0 : P.call(w).height) + D.value;
513
513
  }
514
514
  )
515
515
  )
516
516
  ) : (
517
517
  // If y axis, get the tick width
518
518
  Math.max(
519
- ...(v.value || []).map(
519
+ ...(f.value || []).map(
520
520
  (E) => {
521
521
  var w, P;
522
- return ((P = (w = E.ref).getBBox) == null ? void 0 : P.call(w).width) + N.value;
522
+ return ((P = (w = E.ref).getBBox) == null ? void 0 : P.call(w).width) + D.value;
523
523
  }
524
524
  )
525
525
  )
526
526
  ));
527
- function j(E) {
527
+ function M(E) {
528
528
  const { showTicks: w } = d.value;
529
- return w === !1 ? "" : $.value(E);
529
+ return w === !1 ? "" : N.value(E);
530
530
  }
531
- function V(E, w, P) {
531
+ function z(E, w, P) {
532
532
  e("mouseenter", { index: x.value ? E : null, value: w, event: P });
533
533
  }
534
534
  function ee(E, w, P) {
535
535
  e("click", { index: E, value: w, event: P });
536
536
  }
537
- function de(E) {
537
+ function ce(E) {
538
538
  var w;
539
- if (!(!v.value || !v.value.length))
540
- return (w = v.value[E]) == null ? void 0 : w.ref;
539
+ if (!(!f.value || !f.value.length))
540
+ return (w = f.value[E]) == null ? void 0 : w.ref;
541
541
  }
542
- function oe() {
543
- g.value = A.value.map(
542
+ function ae() {
543
+ h.value = T.value.map(
544
544
  (E, w) => ({
545
- value: j(E),
545
+ value: M(E),
546
546
  group: s.getTickGroupAttributes(E, w),
547
- ghost: s.getTickGhostAttributes(de(w)),
547
+ ghost: s.getTickGhostAttributes(ce(w)),
548
548
  label: s.getTickLabelAttributes(),
549
549
  gridline: s.getGridLinesAttributes()
550
550
  })
551
551
  );
552
552
  }
553
- function te() {
554
- g.value && g.value.map((E) => (E.gridline = s.getGridLinesAttributes(), E));
553
+ function oe() {
554
+ h.value && h.value.map((E) => (E.gridline = s.getGridLinesAttributes(), E));
555
555
  }
556
- function ue() {
556
+ function le() {
557
557
  if (!a.value) return;
558
- const E = a.value.step ? "bandScale" : "linearScale", w = wn[`${_.value}-${Se[E]}`];
559
- Object.entries(w(a, u, d) || []).forEach(
560
- ([P, ne]) => {
561
- s[P] = ne;
558
+ const E = a.value.step ? "bandScale" : "linearScale", w = Pn[`${_.value}-${Fe[E]}`];
559
+ Object.entries(w(a, o, d) || []).forEach(
560
+ ([P, te]) => {
561
+ s[P] = te;
562
562
  }
563
563
  );
564
564
  }
565
- return H(a, ue, { flush: "sync", immediate: !0 }), H(a, oe, { immediate: !0 }), H(v, oe), H(S, (E) => e("lume__internal--axis-size", E)), H(r.containerSize, te), ae(() => Ne(m.value)), { __sfc: !0, SCALE_MIXIN_MAP: Se, POSITIONS: Ce, TYPES: Te, AXIS_LABEL_OFFSET: n, props: r, emit: e, scale: a, containerSize: u, hoveredIndex: o, options: i, orientation: l, isEmpty: c, mixins: s, tickRefs: v, root: m, ticksWithAttributes: g, computedPosition: h, computedType: _, shouldHover: x, allOptions: d, showTick: p, alignAxisBaseline: y, axisTransform: b, ticks: A, tickFormatter: $, isHovering: T, axisLabelOffset: N, axisSize: S, formatTick: j, handleTickMouseenter: V, handleTickClick: ee, getTextNode: de, setTicks: oe, updateGridlines: te, init: ue, LumeTick: un };
565
+ return H(a, le, { flush: "sync", immediate: !0 }), H(a, ae, { immediate: !0 }), H(f, ae), H(C, (E) => e("lume__internal--axis-size", E)), H(r.containerSize, oe), re(() => Ne(m.value)), { __sfc: !0, SCALE_MIXIN_MAP: Fe, POSITIONS: Ge, TYPES: Le, AXIS_LABEL_OFFSET: n, props: r, emit: e, scale: a, containerSize: o, hoveredIndex: l, options: i, orientation: u, isEmpty: c, mixins: s, tickRefs: f, root: m, ticksWithAttributes: h, computedPosition: g, computedType: _, shouldHover: x, allOptions: d, showTick: p, alignAxisBaseline: y, axisTransform: k, ticks: T, tickFormatter: N, isHovering: A, axisLabelOffset: D, axisSize: C, formatTick: M, handleTickMouseenter: z, handleTickClick: ee, getTextNode: ce, setTicks: ae, updateGridlines: oe, init: le, LumeTick: dn };
566
566
  }
567
567
  });
568
- var Hn = function() {
568
+ var Bn = function() {
569
569
  var e = this, r = e._self._c, n = e._self._setupProxy;
570
570
  return n.scale ? r("g", { ref: "root", staticClass: "axis", attrs: { transform: n.axisTransform, "data-j-axis": "" }, on: { mouseleave: function(a) {
571
571
  return n.emit("mouseleave", a);
572
- } } }, [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, u) {
573
- return r(n.LumeTick, e._b({ key: `${a.value}_${u}`, ref: "tickRefs", refInFor: !0, attrs: { "is-hidden": n.allOptions.skip && !n.showTick(u), "with-gridlines": n.allOptions.gridLines }, on: { mouseenter: function(o) {
574
- return n.handleTickMouseenter(u, a.value, o);
575
- }, click: function(o) {
576
- return n.handleTickClick(u, a.value, o);
572
+ } } }, [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) {
573
+ 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(l) {
574
+ return n.handleTickMouseenter(o, a.value, l);
575
+ }, click: function(l) {
576
+ return n.handleTickClick(o, a.value, l);
577
577
  } } }, "lume-tick", a, !1));
578
578
  }), n.isHovering ? r(n.LumeTick, e._b({ attrs: { "with-gridlines": !1, "is-hovered": "" }, on: { click: function(a) {
579
579
  return n.handleTickClick(
@@ -582,34 +582,34 @@ var Hn = function() {
582
582
  a
583
583
  );
584
584
  } } }, "lume-tick", n.ticksWithAttributes[n.hoveredIndex], !1)) : e._e()], 2) : e._e();
585
- }, Pn = [], Rn = /* @__PURE__ */ D(
586
- Dn,
587
- Hn,
588
- Pn,
585
+ }, Cn = [], Fn = /* @__PURE__ */ S(
586
+ Rn,
587
+ Bn,
588
+ Cn,
589
589
  !1,
590
590
  null,
591
591
  null
592
592
  );
593
- const Sn = Rn.exports;
594
- function Cn(t, e, r, n) {
595
- const a = f(() => r.value > 0 && r.value < 1), u = f(
593
+ const Gn = Fn.exports;
594
+ function jn(t, e, r, n) {
595
+ const a = v(() => r.value > 0 && r.value < 1), o = v(
596
596
  () => n.value > 0 && n.value < 1
597
- ), o = f(
597
+ ), l = v(
598
598
  () => a.value ? t.value - 0.5 : t.value
599
599
  // draws the 1px bar closer to the axis
600
- ), i = f(
601
- () => u.value ? e.value - 0.5 : e.value
600
+ ), i = v(
601
+ () => o.value ? e.value - 0.5 : e.value
602
602
  // draws the 1px bar closer to the axis
603
603
  );
604
- return { computedX: o, computedY: i, shouldHaveMinWidth: a, shouldHaveMinHeight: u };
604
+ return { computedX: l, computedY: i, shouldHaveMinWidth: a, shouldHaveMinHeight: o };
605
605
  }
606
- function Bn(t, e, r, n) {
607
- const a = I(0), u = I(0), o = f(() => `${t.value + r.value / 2}px ${e.value + n.value / 2}px`);
608
- return ae(() => {
609
- a.value = r.value, u.value = n.value;
610
- }), H(r, (i) => a.value = i), H(n, (i) => u.value = i), { computedWidth: a, computedHeight: u, transformOrigin: o };
606
+ function Vn(t, e, r, n) {
607
+ const a = I(0), o = I(0), l = v(() => `${t.value + r.value / 2}px ${e.value + n.value / 2}px`);
608
+ return re(() => {
609
+ a.value = r.value, o.value = n.value;
610
+ }), H(r, (i) => a.value = i), H(n, (i) => o.value = i), { computedWidth: a, computedHeight: o, transformOrigin: l };
611
611
  }
612
- const Gn = /* @__PURE__ */ R({
612
+ const Mn = /* @__PURE__ */ R({
613
613
  __name: "lume-bar",
614
614
  props: {
615
615
  x: {
@@ -647,13 +647,13 @@ const Gn = /* @__PURE__ */ R({
647
647
  },
648
648
  emits: ["click", "mouseover", "mouseleave"],
649
649
  setup(t, { emit: e }) {
650
- const r = t, { x: n, y: a, width: u, height: o, transition: i, classList: l } = F(r), c = I(null), s = f(
651
- () => typeof l.value == "string" ? [l.value] : l.value
652
- ), v = f(() => i.value === "width"), m = f(() => i.value === "height"), g = Bn(n, a, u, o), { computedX: h, computedY: _, shouldHaveMinWidth: x, shouldHaveMinHeight: d } = Cn(n, a, u, o), p = f(() => x.value ? 1 : (v.value ? g.computedWidth : u).value), y = f(() => d.value ? 1 : (m.value ? g.computedHeight : o).value), b = v.value || m.value ? g.transformOrigin : null;
653
- return ae(() => Ne(c.value)), { __sfc: !0, props: r, emit: e, x: n, y: a, width: u, height: o, transition: i, classList: l, root: c, computedClasses: s, shouldTransitionWidth: v, shouldTransitionHeight: m, transitionProps: g, computedX: h, computedY: _, shouldHaveMinWidth: x, shouldHaveMinHeight: d, computedWidth: p, computedHeight: y, transformOrigin: b };
650
+ const r = t, { x: n, y: a, width: o, height: l, transition: i, classList: u } = V(r), c = I(null), s = v(
651
+ () => typeof u.value == "string" ? [u.value] : u.value
652
+ ), f = v(() => i.value === "width"), m = v(() => i.value === "height"), h = Vn(n, a, o, l), { computedX: g, computedY: _, shouldHaveMinWidth: x, shouldHaveMinHeight: d } = jn(n, a, o, l), p = v(() => x.value ? 1 : (f.value ? h.computedWidth : o).value), y = v(() => d.value ? 1 : (m.value ? h.computedHeight : l).value), k = f.value || m.value ? h.transformOrigin : null;
653
+ return re(() => Ne(c.value)), { __sfc: !0, props: r, emit: e, x: n, y: a, width: o, height: l, transition: i, classList: u, root: c, computedClasses: s, shouldTransitionWidth: f, shouldTransitionHeight: m, transitionProps: h, computedX: g, computedY: _, shouldHaveMinWidth: x, shouldHaveMinHeight: d, computedWidth: p, computedHeight: y, transformOrigin: k };
654
654
  }
655
655
  });
656
- var Fn = function() {
656
+ var zn = function() {
657
657
  var e = this, r = e._self._c, n = e._self._setupProxy;
658
658
  return r("rect", { ref: "root", staticClass: "lume-bar", class: [
659
659
  {
@@ -670,64 +670,64 @@ var Fn = function() {
670
670
  }, mouseleave: function(a) {
671
671
  return n.emit("mouseleave", a);
672
672
  } } });
673
- }, jn = [], Vn = /* @__PURE__ */ D(
674
- Gn,
675
- Fn,
676
- jn,
673
+ }, Wn = [], Un = /* @__PURE__ */ S(
674
+ Mn,
675
+ zn,
676
+ Wn,
677
677
  !1,
678
678
  null,
679
679
  "8e8f732a"
680
680
  );
681
- const Ye = Vn.exports;
682
- var ie = /* @__PURE__ */ ((t) => (t.Categorical = "categorical", t.Sequential = "sequential", t.Divergent = "divergent", t))(ie || {}), Y = /* @__PURE__ */ ((t) => (t.Skyblue = "skyblue", t.Royalblue = "royalblue", t.Violet = "violet", t.Darkteal = "darkteal", t.Gold = "gold", t))(Y || {}), St = /* @__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))(St || {}), Ke = /* @__PURE__ */ ((t) => (t.SkyTeal = "skyblue-darkteal", t.VioletRoyal = "violet-royalblue", t.VioletTeal = "violet-darkteal", t.GoldTeal = "gold-darkteal", t.GoldRoyal = "gold-royalblue", t))(Ke || {}), Je = /* @__PURE__ */ ((t) => (t.White = "white", t.Black = "black", t.Green = "green", t.Orange = "orange", t.Red = "red", t.Grey = "grey", t.Grey10 = "grey-10", t.Grey20 = "grey-20", t.Grey30 = "grey-30", t.Grey40 = "grey-40", t.Grey50 = "grey-50", t.Grey60 = "grey-60", t.Grey70 = "grey-70", t.Grey80 = "grey-80", t.Grey90 = "grey-90", t.Grey100 = "grey-100", t))(Je || {}), Qe = /* @__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))(Qe || {});
683
- const Mn = ie.Categorical, xe = Y.Skyblue, zn = Ke.SkyTeal;
684
- function Wn(t) {
685
- return t === ie.Divergent ? zn : xe;
681
+ const Qe = Un.exports;
682
+ var ue = /* @__PURE__ */ ((t) => (t.Categorical = "categorical", t.Sequential = "sequential", t.Divergent = "divergent", t))(ue || {}), Y = /* @__PURE__ */ ((t) => (t.Skyblue = "skyblue", t.Royalblue = "royalblue", t.Violet = "violet", t.Darkteal = "darkteal", t.Gold = "gold", t))(Y || {}), Gt = /* @__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))(Gt || {}), qe = /* @__PURE__ */ ((t) => (t.SkyTeal = "skyblue-darkteal", t.VioletRoyal = "violet-royalblue", t.VioletTeal = "violet-darkteal", t.GoldTeal = "gold-darkteal", t.GoldRoyal = "gold-royalblue", t))(qe || {}), et = /* @__PURE__ */ ((t) => (t.White = "white", t.Black = "black", t.Green = "green", t.Orange = "orange", t.Red = "red", t.Grey = "grey", t.Grey10 = "grey-10", t.Grey20 = "grey-20", t.Grey30 = "grey-30", t.Grey40 = "grey-40", t.Grey50 = "grey-50", t.Grey60 = "grey-60", t.Grey70 = "grey-70", t.Grey80 = "grey-80", t.Grey90 = "grey-90", t.Grey100 = "grey-100", t))(et || {}), tt = /* @__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))(tt || {});
683
+ const Zn = ue.Categorical, ke = Y.Skyblue, Xn = qe.SkyTeal;
684
+ function Yn(t) {
685
+ return t === ue.Divergent ? Xn : ke;
686
686
  }
687
- function Un(t) {
688
- return Object.values(Qe).includes(t);
687
+ function Kn(t) {
688
+ return Object.values(tt).includes(t);
689
689
  }
690
- function ut(t, e) {
691
- return e === ie.Divergent ? Object.values(Ke).includes(t) : Object.values({
690
+ function ct(t, e) {
691
+ return e === ue.Divergent ? Object.values(qe).includes(t) : Object.values({
692
692
  ...Y,
693
- ...St,
694
- ...Je,
695
- ...Qe
693
+ ...Gt,
694
+ ...et,
695
+ ...tt
696
696
  }).includes(t);
697
697
  }
698
- function Zn(t, e) {
698
+ function Jn(t, e) {
699
699
  const r = Object.values(Y).indexOf(t);
700
- return hn(Object.values(Y), r > -1 ? r : 0)[e];
700
+ return kn(Object.values(Y), r > -1 ? r : 0)[e];
701
701
  }
702
- function Xn(t, e) {
702
+ function Qn(t, e) {
703
703
  const r = 50 + e * 10;
704
704
  return `${t}-${r}`;
705
705
  }
706
- function Yn(t, e) {
706
+ function qn(t, e) {
707
707
  const r = (e + 1) * 10;
708
708
  return `${t}-${r}`;
709
709
  }
710
- function lt(t, e, r) {
710
+ function dt(t, e, r) {
711
711
  switch (e) {
712
712
  default:
713
- case ie.Categorical:
714
- return Un(t) ? t : Zn(t, r);
715
- case ie.Sequential:
716
- return Xn(t, r);
717
- case ie.Divergent:
718
- return Yn(t, r);
713
+ case ue.Categorical:
714
+ return Kn(t) ? t : Jn(t, r);
715
+ case ue.Sequential:
716
+ return Qn(t, r);
717
+ case ue.Divergent:
718
+ return qn(t, r);
719
719
  }
720
720
  }
721
- function Kn(t, e, r = Mn, n) {
722
- return ut(t, r) ? t : (n > 4 && (re(J.ColorLoop), n = n % 5), ut(e, r) ? lt(e, r, n) : lt(Wn(r), r, n));
721
+ function er(t, e, r = Zn, n) {
722
+ return ct(t, r) ? t : (n > 4 && (ne(J.ColorLoop), n = n % 5), ct(e, r) ? dt(e, r, n) : dt(Yn(r), r, n));
723
723
  }
724
- function Jn(t) {
725
- return t.map((e) => cn(e) ? e : { value: e });
724
+ function tr(t) {
725
+ return t.map((e) => pn(e) ? e : { value: e });
726
726
  }
727
- function Qn(t) {
727
+ function nr(t) {
728
728
  return t.__internal === !0;
729
729
  }
730
- const qe = (t = null) => ({
730
+ const nt = (t = null) => ({
731
731
  data: {
732
732
  type: Array,
733
733
  required: !0,
@@ -746,43 +746,43 @@ const qe = (t = null) => ({
746
746
  default: null
747
747
  }
748
748
  });
749
- function et(t, e, r, n, a) {
750
- const u = $e({
749
+ function rt(t, e, r, n, a) {
750
+ const o = Ie({
751
751
  width: 0,
752
752
  height: 0
753
- }), o = crypto.randomUUID(), i = f(() => {
753
+ }), l = crypto.randomUUID(), i = v(() => {
754
754
  var s;
755
- return t.value.length > 5 && re(J.DatasetLength), (s = t.value) == null ? void 0 : s.map(
756
- (v, m) => {
757
- if (Qn(v)) return v;
758
- const g = Jn(v.values), h = Kn(
759
- v.color,
755
+ return t.value.length > 5 && ne(J.DatasetLength), (s = t.value) == null ? void 0 : s.map(
756
+ (f, m) => {
757
+ if (nr(f)) return f;
758
+ const h = tr(f.values), g = er(
759
+ f.color,
760
760
  r == null ? void 0 : r.value,
761
761
  n == null ? void 0 : n.value.colorPalette,
762
762
  m
763
763
  );
764
764
  return {
765
- ...v,
766
- values: g,
767
- color: h,
765
+ ...f,
766
+ values: h,
767
+ color: g,
768
768
  __internal: !0
769
769
  };
770
770
  }
771
771
  );
772
- }), l = f(() => Array.isArray(e.value) ? e.value : Nt(t.value).map((s, v) => v));
772
+ }), u = v(() => Array.isArray(e.value) ? e.value : St(t.value).map((s, f) => f));
773
773
  function c(s) {
774
- const v = (a == null ? void 0 : a.value) === O.HORIZONTAL && l.value.length * (((n == null ? void 0 : n.value.barHeight) || ot) * 2) + ((n == null ? void 0 : n.value.barHeight) || ot) || s.height;
775
- u.width = s.width, u.height = v;
774
+ const f = (a == null ? void 0 : a.value) === O.HORIZONTAL && u.value.length * (((n == null ? void 0 : n.value.barHeight) || st) * 2) + ((n == null ? void 0 : n.value.barHeight) || st) || s.height;
775
+ o.width = s.width, o.height = f;
776
776
  }
777
777
  return {
778
- chartID: o,
779
- computedLabels: l,
780
- containerSize: u,
778
+ chartID: l,
779
+ computedLabels: u,
780
+ containerSize: o,
781
781
  internalData: i,
782
782
  updateSize: c
783
783
  };
784
784
  }
785
- const qn = () => ({
785
+ const rr = () => ({
786
786
  xScale: {
787
787
  type: Function,
788
788
  default: null
@@ -792,73 +792,73 @@ const qn = () => ({
792
792
  default: null
793
793
  }
794
794
  });
795
- function er(t, e, r, n, a) {
796
- const u = I(null), o = I(null);
795
+ function ar(t, e, r, n, a) {
796
+ const o = I(null), l = I(null);
797
797
  function i() {
798
- var s, v, m, g;
799
- const { width: l, height: c } = r;
800
- !l && !c || (n.value === O.HORIZONTAL ? (u.value = (s = t.value) != null && s.length ? st(
798
+ var s, f, m, h;
799
+ const { width: u, height: c } = r;
800
+ !u && !c || (n.value === O.HORIZONTAL ? (o.value = (s = t.value) != null && s.length ? ft(
801
801
  t.value,
802
- l,
802
+ u,
803
803
  n.value,
804
804
  a.value.startOnZero
805
- ) : null, o.value = (v = e.value) != null && v.length ? it(
805
+ ) : null, l.value = (f = e.value) != null && f.length ? vt(
806
806
  e.value,
807
807
  c,
808
808
  n.value,
809
809
  a.value
810
- ) : null) : (u.value = (m = e.value) != null && m.length ? it(
810
+ ) : null) : (o.value = (m = e.value) != null && m.length ? vt(
811
811
  e.value,
812
- l,
812
+ u,
813
813
  n.value,
814
814
  a.value
815
- ) : null, o.value = (g = t.value) != null && g.length ? st(
815
+ ) : null, l.value = (h = t.value) != null && h.length ? ft(
816
816
  t.value,
817
817
  c,
818
818
  n.value,
819
819
  a.value.startOnZero
820
820
  ) : null));
821
821
  }
822
- return Tt(i), { xScale: u, yScale: o };
822
+ return Et(i), { xScale: o, yScale: l };
823
823
  }
824
- function it(t, e, r, n) {
825
- const a = [0, e], { padding: u, paddingInner: o, paddingOuter: i } = n, l = u ?? (r === O.HORIZONTAL ? Ht : Dt);
824
+ function vt(t, e, r, n) {
825
+ const a = [0, e], { padding: o, paddingInner: l, paddingOuter: i } = n, u = o ?? (r === O.HORIZONTAL ? Bt : Rt);
826
826
  return Object.assign(
827
- ye().range(a).paddingInner(o ?? l).paddingOuter(i ?? l).domain(t.map((c, s) => s)),
827
+ he().range(a).paddingInner(l ?? u).paddingOuter(i ?? u).domain(t.map((c, s) => s)),
828
828
  { labels: t }
829
829
  );
830
830
  }
831
- function st(t, e, r, n) {
832
- const a = Et(t).filter((s) => s != null), u = [0, e];
831
+ function ft(t, e, r, n) {
832
+ const a = Dt(t).filter((s) => s != null), o = [0, e];
833
833
  if (a.length === 0)
834
- return ge().range(u).domain([0, 0]).nice();
835
- const o = Math.min(...a), i = n && o > 0 ? 0 : o;
836
- let l = Math.max(...a);
837
- n && l < 0 && (l = 0);
838
- const c = r === O.HORIZONTAL ? [i, l] : [l, i];
839
- return ge().range(u).domain(c).nice();
840
- }
841
- function ct(t) {
834
+ return ge().range(o).domain([0, 0]).nice();
835
+ const l = Math.min(...a), i = n && l > 0 ? 0 : l;
836
+ let u = Math.max(...a);
837
+ n && u < 0 && (u = 0);
838
+ const c = r === O.HORIZONTAL ? [i, u] : [u, i];
839
+ return ge().range(o).domain(c).nice();
840
+ }
841
+ function pt(t) {
842
842
  return (t == null ? void 0 : t.range) !== void 0 || (t == null ? void 0 : t.copy) !== void 0;
843
843
  }
844
- function Be(t, e) {
844
+ function je(t, e) {
845
845
  return K(t) ? t.bandwidth() / 2 + t(t.domain()[e]) : t(e);
846
846
  }
847
- function dt(t, e, {
847
+ function mt(t, e, {
848
848
  padding: r,
849
849
  paddingInner: n,
850
850
  paddingOuter: a
851
851
  } = {}) {
852
- const u = r ?? (e === O.HORIZONTAL ? Ht : Dt);
853
- return t.copy().paddingInner(n ?? u).paddingOuter(a ?? u);
852
+ const o = r ?? (e === O.HORIZONTAL ? Bt : Rt);
853
+ return t.copy().paddingInner(n ?? o).paddingOuter(a ?? o);
854
854
  }
855
- function tt(t) {
855
+ function at(t) {
856
856
  return Object.values(O).includes(t);
857
857
  }
858
- const me = (t, e = !0) => ({
859
- ...qe(t),
860
- ...qn(),
861
- ...be(),
858
+ const ve = (t, e = !0) => ({
859
+ ...nt(t),
860
+ ...rr(),
861
+ ...ye(),
862
862
  classList: {
863
863
  type: [String, Array],
864
864
  default: () => []
@@ -871,32 +871,32 @@ const me = (t, e = !0) => ({
871
871
  orientation: {
872
872
  type: String,
873
873
  default: O.VERTICAL,
874
- validator: tt
874
+ validator: at
875
875
  }
876
876
  } : {}
877
- }), tr = (t) => ({
878
- ...qe(t),
879
- ...be(),
877
+ }), or = (t) => ({
878
+ ...nt(t),
879
+ ...ye(),
880
880
  hoveredElement: {
881
881
  type: [Number, String],
882
882
  default: null
883
883
  }
884
884
  });
885
- function nr() {
886
- const t = I(), e = $e({
885
+ function lr() {
886
+ const t = I(), e = Ie({
887
887
  dimensions: {}
888
888
  }), r = new ResizeObserver((n) => {
889
889
  n.forEach((a) => {
890
890
  e.dimensions = a.contentRect;
891
891
  });
892
892
  });
893
- return ae(() => {
893
+ return re(() => {
894
894
  r.observe(t.value);
895
- }), Ot(() => {
895
+ }), $t(() => {
896
896
  r.unobserve(t.value);
897
897
  }), { resizeState: e, resizeRef: t };
898
898
  }
899
- const rr = /* @__PURE__ */ R({
899
+ const ur = /* @__PURE__ */ R({
900
900
  __name: "lume-chart-container",
901
901
  props: {
902
902
  margins: {
@@ -918,30 +918,30 @@ const rr = /* @__PURE__ */ R({
918
918
  orientation: {
919
919
  type: String,
920
920
  default: O.VERTICAL,
921
- validator: tt
921
+ validator: at
922
922
  }
923
923
  },
924
924
  emits: ["click", "mouseenter", "mouseleave", "resize"],
925
925
  setup(t, { emit: e }) {
926
- const r = t, { margins: n, containerSize: a } = F(r), u = I(null), { resizeRef: o, resizeState: i } = nr(), l = f(
926
+ const r = t, { margins: n, containerSize: a } = V(r), o = I(null), { resizeRef: l, resizeState: i } = lr(), u = v(
927
927
  () => a.value.height + n.value.top + n.value.bottom
928
928
  );
929
- return Tt(() => {
930
- if (!u.value) return;
931
- const { width: c } = i.dimensions, { height: s } = u.value.getBoundingClientRect();
929
+ return Et(() => {
930
+ if (!o.value) return;
931
+ const { width: c } = i.dimensions, { height: s } = o.value.getBoundingClientRect();
932
932
  if (!c || r.orientation === O.VERTICAL && !s)
933
933
  return;
934
- const v = c - n.value.left - n.value.right, m = s - n.value.top - n.value.bottom, g = {
935
- width: v > 0 ? v : 0,
934
+ const f = c - n.value.left - n.value.right, m = s - n.value.top - n.value.bottom, h = {
935
+ width: f > 0 ? f : 0,
936
936
  height: m > 0 ? m : 0,
937
937
  outerWidth: c,
938
938
  outerHeight: s
939
939
  };
940
- e("resize", g);
941
- }), { __sfc: !0, props: r, emit: e, margins: n, containerSize: a, root: u, resizeRef: o, resizeState: i, svgHeight: l };
940
+ e("resize", h);
941
+ }), { __sfc: !0, props: r, emit: e, margins: n, containerSize: a, root: o, resizeRef: l, resizeState: i, svgHeight: u };
942
942
  }
943
943
  });
944
- var ar = function() {
944
+ var ir = function() {
945
945
  var e = this, r = e._self._c, n = e._self._setupProxy;
946
946
  return r("div", { ref: "resizeRef", staticClass: "lume-chart-container", class: {
947
947
  "lume-chart-container--minimum": !e.noMinSize
@@ -954,20 +954,20 @@ var ar = function() {
954
954
  }, mouseleave: function(a) {
955
955
  return n.emit("mouseleave", a);
956
956
  } } }, [r("g", { staticClass: "lume-chart-container__group", attrs: { transform: `translate(${n.margins.left}, ${n.margins.top})`, "data-j-chart-container__group": "" } }, [e._t("default")], 2)]), e._t("footer"), e._t("extra")], 2);
957
- }, or = [], ur = /* @__PURE__ */ D(
958
- rr,
959
- ar,
960
- or,
957
+ }, sr = [], cr = /* @__PURE__ */ S(
958
+ ur,
959
+ ir,
960
+ sr,
961
961
  !1,
962
962
  null,
963
963
  "d53cdc3e"
964
964
  );
965
- const lr = ur.exports, ir = /* @__PURE__ */ R({
965
+ const dr = cr.exports, vr = /* @__PURE__ */ R({
966
966
  __name: "lume-chart-legend",
967
967
  props: {
968
968
  data: {
969
969
  type: Array,
970
- validator: sn,
970
+ validator: fn,
971
971
  required: !0
972
972
  }
973
973
  },
@@ -976,50 +976,50 @@ const lr = ur.exports, ir = /* @__PURE__ */ R({
976
976
  return { __sfc: !0, emit: e };
977
977
  }
978
978
  });
979
- var sr = function() {
979
+ var fr = function() {
980
980
  var e = this, r = e._self._c, n = e._self._setupProxy;
981
981
  return r("div", { staticClass: "lume-chart-legend", attrs: { "data-j-chart-legend": "" }, on: { mouseleave: function(a) {
982
982
  return n.emit("mouseleave");
983
- } } }, e._l(e.data, function(a, u) {
984
- return r("div", { key: `legend-item-${u}`, staticClass: "lume-chart-legend__item lume-typography--caption", attrs: { tabindex: "0", "data-j-chart-legend__symbol-wrapper": "" }, on: { click: function(o) {
985
- return n.emit("click", { index: u, dataset: a, event: o });
986
- }, mouseenter: function(o) {
987
- return n.emit("mouseenter", { index: u, dataset: a, event: o });
988
- } } }, [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 || u) + " ")]);
983
+ } } }, e._l(e.data, function(a, o) {
984
+ return r("div", { key: `legend-item-${o}`, staticClass: "lume-chart-legend__item lume-typography--caption", attrs: { tabindex: "0", "data-j-chart-legend__symbol-wrapper": "" }, on: { click: function(l) {
985
+ return n.emit("click", { index: o, dataset: a, event: l });
986
+ }, mouseenter: function(l) {
987
+ return n.emit("mouseenter", { index: o, dataset: a, event: l });
988
+ } } }, [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) + " ")]);
989
989
  }), 0);
990
- }, cr = [], dr = /* @__PURE__ */ D(
991
- ir,
992
- sr,
993
- cr,
990
+ }, pr = [], mr = /* @__PURE__ */ S(
991
+ vr,
992
+ fr,
993
+ pr,
994
994
  !1,
995
995
  null,
996
996
  "6f1d1c44"
997
997
  );
998
- const vr = dr.exports, fr = {};
999
- var pr = function() {
998
+ const _r = mr.exports, gr = {};
999
+ var hr = function() {
1000
1000
  var e = this, r = e._self._c;
1001
1001
  return r("div", { staticClass: "lume-tooltip__title", attrs: { "data-j-tooltip__title": "" } }, [e._t("default")], 2);
1002
- }, mr = [], _r = /* @__PURE__ */ D(
1003
- fr,
1004
- pr,
1005
- mr,
1002
+ }, yr = [], br = /* @__PURE__ */ S(
1003
+ gr,
1004
+ hr,
1005
+ yr,
1006
1006
  !1,
1007
1007
  null,
1008
1008
  "8af3fac6"
1009
1009
  );
1010
- const hr = _r.exports, gr = {};
1011
- var yr = function() {
1010
+ const kr = br.exports, xr = {};
1011
+ var Lr = function() {
1012
1012
  var e = this, r = e._self._c;
1013
1013
  return r("li", { staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__summary-item": "" } }, [r("span", [e._t("default")], 2), r("strong", { staticClass: "lume-tooltip__value" }, [e._t("value")], 2)]);
1014
- }, br = [], kr = /* @__PURE__ */ D(
1015
- gr,
1016
- yr,
1017
- br,
1014
+ }, Tr = [], Ar = /* @__PURE__ */ S(
1015
+ xr,
1016
+ Lr,
1017
+ Tr,
1018
1018
  !1,
1019
1019
  null,
1020
1020
  "4ed7ec1b"
1021
1021
  );
1022
- const xr = kr.exports, Ar = /* @__PURE__ */ R({
1022
+ const Or = Ar.exports, Ir = /* @__PURE__ */ R({
1023
1023
  __name: "lume-tooltip-item",
1024
1024
  props: {
1025
1025
  color: {
@@ -1031,18 +1031,18 @@ const xr = kr.exports, Ar = /* @__PURE__ */ R({
1031
1031
  return { __sfc: !0 };
1032
1032
  }
1033
1033
  });
1034
- var Lr = function() {
1034
+ var Nr = function() {
1035
1035
  var e = this, r = e._self._c;
1036
1036
  return e._self._setupProxy, r("li", { staticClass: "lume-tooltip__item", attrs: { "data-j-tooltip__item": "" } }, [e.color ? r("span", { staticClass: "lume-tooltip__symbol", class: [`lume-background-color--${e.color}`], attrs: { "data-j-tooltip__item__symbol": "" } }) : e._e(), r("span", { attrs: { "data-j-tooltip__item__label": "" } }, [e._t("label")], 2), r("strong", { staticClass: "lume-tooltip__value", attrs: { "data-j-tooltip__item__value": "" } }, [e._t("value")], 2)]);
1037
- }, Tr = [], Or = /* @__PURE__ */ D(
1038
- Ar,
1039
- Lr,
1040
- Tr,
1037
+ }, Er = [], $r = /* @__PURE__ */ S(
1038
+ Ir,
1039
+ Nr,
1040
+ Er,
1041
1041
  !1,
1042
1042
  null,
1043
1043
  "4f995c3c"
1044
1044
  );
1045
- const Ir = Or.exports, Er = /* @__PURE__ */ R({
1045
+ const wr = $r.exports, Dr = /* @__PURE__ */ R({
1046
1046
  __name: "lume-tooltip",
1047
1047
  props: {
1048
1048
  opened: {
@@ -1060,7 +1060,7 @@ const Ir = Or.exports, Er = /* @__PURE__ */ R({
1060
1060
  position: {
1061
1061
  type: String,
1062
1062
  default: "auto",
1063
- validator: (t) => Ln.includes(t)
1063
+ validator: (t) => Nn.includes(t)
1064
1064
  },
1065
1065
  fixedPositioning: {
1066
1066
  type: Boolean,
@@ -1082,15 +1082,15 @@ const Ir = Or.exports, Er = /* @__PURE__ */ R({
1082
1082
  type: String,
1083
1083
  default: null
1084
1084
  },
1085
- ...be()
1085
+ ...ye()
1086
1086
  },
1087
1087
  emits: ["opened", "moved", "closed", "tooltip-mouseenter", "tooltip-mouseleave"],
1088
1088
  setup(t, { emit: e }) {
1089
- const r = t, n = I(null), { items: a, options: u } = F(r), o = X(), i = I(null), { allOptions: l } = Q(u), c = f(
1090
- () => l.value.fixedPositioning ?? r.fixedPositioning
1091
- ), s = f(
1089
+ const r = t, n = I(null), { items: a, options: o } = V(r), l = X(), i = I(null), { allOptions: u } = Q(o), c = v(
1090
+ () => u.value.fixedPositioning ?? r.fixedPositioning
1091
+ ), s = v(
1092
1092
  () => c.value ? "fixed" : "absolute"
1093
- ), v = f(() => [
1093
+ ), f = v(() => [
1094
1094
  {
1095
1095
  name: "computeStyles",
1096
1096
  options: {
@@ -1100,43 +1100,43 @@ const Ir = Or.exports, Er = /* @__PURE__ */ R({
1100
1100
  },
1101
1101
  {
1102
1102
  name: "offset",
1103
- options: { offset: [0, l.value.offset || 8] }
1103
+ options: { offset: [0, u.value.offset || 8] }
1104
1104
  },
1105
1105
  ...r.modifiers || []
1106
- ]), m = f(
1107
- () => l.value.showTitle !== !1 && r.title != null
1108
- ), g = f(() => Oe(l.value.valueFormat)), h = f(() => Oe(l.value.titleFormat)), _ = f(
1106
+ ]), m = v(
1107
+ () => u.value.showTitle !== !1 && r.title != null
1108
+ ), h = v(() => Te(u.value.valueFormat)), g = v(() => Te(u.value.titleFormat)), _ = v(
1109
1109
  () => {
1110
- var A;
1111
- return ((A = a.value) == null ? void 0 : A.find(($) => $.isSummary)) || {
1112
- label: l.value.summary ?? r.summary
1110
+ var T;
1111
+ return ((T = a.value) == null ? void 0 : T.find((N) => N.isSummary)) || {
1112
+ label: u.value.summary ?? r.summary
1113
1113
  };
1114
1114
  }
1115
- ), x = f(() => o.summary || _.value.label), d = f(() => r.inverse || l.value.inverse ? [...a.value].reverse() : a.value);
1115
+ ), x = v(() => l.summary || _.value.label), d = v(() => r.inverse || u.value.inverse ? [...a.value].reverse() : a.value);
1116
1116
  function p() {
1117
- r.targetElement && n.value && (i.value = tn(r.targetElement, n.value, {
1117
+ r.targetElement && n.value && (i.value = on(r.targetElement, n.value, {
1118
1118
  placement: r.position,
1119
1119
  strategy: s.value,
1120
- modifiers: v.value
1120
+ modifiers: f.value
1121
1121
  }), e("opened", r.targetElement));
1122
1122
  }
1123
1123
  function y() {
1124
1124
  i.value && (i.value.destroy(), e("closed"), n.value && n.value.classList.remove("lume-tooltip--animated"));
1125
1125
  }
1126
- function b() {
1127
- i.value && (l.value.withAnimation !== !1 && n.value && n.value.classList.add("lume-tooltip--animated"), r.targetElement ? (function() {
1126
+ function k() {
1127
+ i.value && (u.value.withAnimation !== !1 && n.value && n.value.classList.add("lume-tooltip--animated"), r.targetElement ? (function() {
1128
1128
  i.value.state.elements.reference = r.targetElement, i.value.update(), e("moved", r.targetElement);
1129
1129
  })() : y());
1130
1130
  }
1131
1131
  return H(
1132
1132
  () => r.targetElement,
1133
- async (A, $) => {
1134
- !$ && A ? (await Pe(), p()) : b();
1133
+ async (T, N) => {
1134
+ !N && T ? (await Be(), p()) : k();
1135
1135
  }
1136
- ), ae(p), Ot(y), { __sfc: !0, props: r, emit: e, root: n, items: a, options: u, slots: o, popper: i, allOptions: l, computedFixedPositioning: c, strategy: s, allModifiers: v, showTitle: m, formatValue: g, formatTitle: h, summaryItem: _, hasSummary: x, computedItems: d, initPopper: p, destroyPopper: y, updatePopper: b, LumeTooltipTitle: hr, LumeTooltipSummary: xr, LumeTooltipItem: Ir };
1136
+ ), re(p), $t(y), { __sfc: !0, props: r, emit: e, root: n, items: a, options: o, slots: l, popper: i, allOptions: u, computedFixedPositioning: c, strategy: s, allModifiers: f, showTitle: m, formatValue: h, formatTitle: g, summaryItem: _, hasSummary: x, computedItems: d, initPopper: p, destroyPopper: y, updatePopper: k, LumeTooltipTitle: kr, LumeTooltipSummary: Or, LumeTooltipItem: wr };
1137
1137
  }
1138
1138
  });
1139
- var $r = function() {
1139
+ var Hr = function() {
1140
1140
  var e = this, r = e._self._c, n = e._self._setupProxy;
1141
1141
  return e.opened && e.targetElement ? r("div", { ref: "root", staticClass: "lume-tooltip lume-typography--caption", class: {
1142
1142
  "lume-tooltip--pointer-events": n.options.withPointerEvents
@@ -1161,15 +1161,15 @@ var $r = function() {
1161
1161
  });
1162
1162
  })], 2)];
1163
1163
  })], 2) : e._e();
1164
- }, Nr = [], wr = /* @__PURE__ */ D(
1165
- Er,
1166
- $r,
1167
- Nr,
1164
+ }, Sr = [], Pr = /* @__PURE__ */ S(
1165
+ Dr,
1166
+ Hr,
1167
+ Sr,
1168
1168
  !1,
1169
1169
  null,
1170
1170
  "6f13599d"
1171
1171
  );
1172
- const Dr = wr.exports, we = () => ({
1172
+ const Rr = Pr.exports, Ee = () => ({
1173
1173
  data: {
1174
1174
  type: Array,
1175
1175
  required: !0
@@ -1185,7 +1185,7 @@ const Dr = wr.exports, we = () => ({
1185
1185
  orientation: {
1186
1186
  type: String,
1187
1187
  default: O.VERTICAL,
1188
- validator: tt
1188
+ validator: at
1189
1189
  },
1190
1190
  xScale: {
1191
1191
  type: Function,
@@ -1211,10 +1211,10 @@ const Dr = wr.exports, we = () => ({
1211
1211
  type: [String, Array],
1212
1212
  default: () => []
1213
1213
  }
1214
- }), Hr = /* @__PURE__ */ R({
1214
+ }), Br = /* @__PURE__ */ R({
1215
1215
  __name: "lume-overlay-group",
1216
1216
  props: {
1217
- ...we(),
1217
+ ...Ee(),
1218
1218
  orientation: {
1219
1219
  type: String,
1220
1220
  default: O.VERTICAL
@@ -1222,41 +1222,41 @@ const Dr = wr.exports, we = () => ({
1222
1222
  },
1223
1223
  emits: ["click", "lume__internal--hover", "mouseover"],
1224
1224
  setup(t, { emit: e }) {
1225
- const r = t, { data: n, orientation: a, xScale: u, yScale: o } = F(r), i = f(() => Nt(n));
1226
- function l(c) {
1225
+ const r = t, { data: n, orientation: a, xScale: o, yScale: l } = V(r), i = v(() => St(n));
1226
+ function u(c) {
1227
1227
  var x;
1228
- const s = a.value === O.HORIZONTAL ? o.value : u.value, v = s.domain(), m = dn(s), g = ((x = s.paddingInner) == null ? void 0 : x.call(s)) ?? 0, h = m * g, _ = K(s) ? s(v[c]) - h / 2 : s(c) - m / 2;
1228
+ const s = a.value === O.HORIZONTAL ? l.value : o.value, f = s.domain(), m = mn(s), h = ((x = s.paddingInner) == null ? void 0 : x.call(s)) ?? 0, g = m * h, _ = K(s) ? s(f[c]) - g / 2 : s(c) - m / 2;
1229
1229
  return a.value === O.HORIZONTAL ? {
1230
- width: Math.max(...u.value.range()),
1230
+ width: Math.max(...o.value.range()),
1231
1231
  height: m,
1232
1232
  transform: `translate(0, ${_})`
1233
1233
  } : {
1234
1234
  width: m,
1235
- height: Math.max(...o.value.range()),
1235
+ height: Math.max(...l.value.range()),
1236
1236
  transform: `translate(${_}, 0)`
1237
1237
  };
1238
1238
  }
1239
- return { __sfc: !0, props: r, emit: e, data: n, orientation: a, xScale: u, yScale: o, overlayData: i, getOverlayBarAttributes: l, LumeBar: Ye };
1239
+ return { __sfc: !0, props: r, emit: e, data: n, orientation: a, xScale: o, yScale: l, overlayData: i, getOverlayBarAttributes: u, LumeBar: Qe };
1240
1240
  }
1241
1241
  });
1242
- var Pr = function() {
1242
+ var Cr = function() {
1243
1243
  var e = this, r = e._self._c, n = e._self._setupProxy;
1244
- return r("g", { staticClass: "lume-overlay-group" }, e._l(n.overlayData, function(a, u) {
1245
- return r(n.LumeBar, e._b({ key: `overlay-${u}`, attrs: { "data-j-lume-overlay-group": u, transition: !1, "class-list": "lume-fill--transparent" }, on: { mouseover: function(o) {
1246
- return n.emit("lume__internal--hover", u);
1247
- }, click: function(o) {
1248
- return n.emit("click", { index: u, event: o });
1249
- } } }, "lume-bar", n.getOverlayBarAttributes(u), !1));
1244
+ return r("g", { staticClass: "lume-overlay-group" }, e._l(n.overlayData, function(a, o) {
1245
+ return r(n.LumeBar, e._b({ key: `overlay-${o}`, attrs: { "data-j-lume-overlay-group": o, transition: !1, "class-list": "lume-fill--transparent" }, on: { mouseover: function(l) {
1246
+ return n.emit("lume__internal--hover", o);
1247
+ }, click: function(l) {
1248
+ return n.emit("click", { index: o, event: l });
1249
+ } } }, "lume-bar", n.getOverlayBarAttributes(o), !1));
1250
1250
  }), 1);
1251
- }, Rr = [], Sr = /* @__PURE__ */ D(
1252
- Hr,
1253
- Pr,
1254
- Rr,
1251
+ }, Fr = [], Gr = /* @__PURE__ */ S(
1252
+ Br,
1253
+ Cr,
1254
+ Fr,
1255
1255
  !1,
1256
1256
  null,
1257
1257
  null
1258
1258
  );
1259
- const Cr = Sr.exports, Br = [
1259
+ const jr = Gr.exports, Vr = [
1260
1260
  "axis-click",
1261
1261
  "axis-mouseenter",
1262
1262
  "axis-mouseleave",
@@ -1285,95 +1285,95 @@ const Cr = Sr.exports, Br = [
1285
1285
  "hovered-index-changed",
1286
1286
  "update:hoveredIndex"
1287
1287
  ], q = (t, e) => {
1288
- function r(u, ...o) {
1288
+ function r(o, ...l) {
1289
1289
  document.dispatchEvent(
1290
- new CustomEvent(`${e}_${u}`, {
1291
- detail: [...o]
1290
+ new CustomEvent(`${e}_${o}`, {
1291
+ detail: [...l]
1292
1292
  })
1293
1293
  );
1294
1294
  }
1295
- function n(u, o) {
1295
+ function n(o, l) {
1296
1296
  document.addEventListener(
1297
- `${e}_${u}`,
1298
- (i) => o(...i.detail)
1297
+ `${e}_${o}`,
1298
+ (i) => l(...i.detail)
1299
1299
  );
1300
1300
  }
1301
- return { componentEventPropagator: Br.reduce((u, o) => (u[o] = (i) => t(o, i), u), {}), emitInternalEvent: r, listenInternalEvent: n };
1301
+ return { componentEventPropagator: Vr.reduce((o, l) => (o[l] = (i) => t(l, i), o), {}), emitInternalEvent: r, listenInternalEvent: n };
1302
1302
  };
1303
- function Gr(t) {
1304
- return { hasNegativeValues: f(
1305
- () => Et(t.value).some((r) => r < 0)
1303
+ function Mr(t) {
1304
+ return { hasNegativeValues: v(
1305
+ () => Dt(t.value).some((r) => r < 0)
1306
1306
  ) };
1307
1307
  }
1308
- function Fr(t, e, r, n) {
1309
- const a = f(
1308
+ function zr(t, e, r, n) {
1309
+ const a = v(
1310
1310
  () => n.value === O.HORIZONTAL
1311
- ), u = f(
1311
+ ), o = v(
1312
1312
  () => {
1313
1313
  var c;
1314
1314
  return t.height - (a != null && a.value ? 0 : ((c = r.value) == null ? void 0 : c.call(r, 0)) || 0);
1315
1315
  }
1316
- ), o = f(
1316
+ ), l = v(
1317
1317
  () => {
1318
1318
  var c;
1319
1319
  return a != null && a.value ? ((c = e.value) == null ? void 0 : c.call(e, 0)) || 0 : t.width;
1320
1320
  }
1321
- ), i = f(
1321
+ ), i = v(
1322
1322
  () => {
1323
1323
  var c;
1324
1324
  return a != null && a.value ? "translate(0, 0)" : `translate(0, ${((c = r.value) == null ? void 0 : c.call(r, 0)) || 0})`;
1325
1325
  }
1326
1326
  );
1327
- return { negativeBarAttributes: f(() => ({
1328
- width: o.value,
1329
- height: u.value,
1327
+ return { negativeBarAttributes: v(() => ({
1328
+ width: l.value,
1329
+ height: o.value,
1330
1330
  transform: i.value
1331
1331
  })) };
1332
1332
  }
1333
- function jr(t, e) {
1334
- return t.reduce((r, n) => Xe(n.values, e).map(
1335
- (a, u) => r[u] ? a.value > r[u] ? a.value : r[u] : a.value ?? 0
1333
+ function Wr(t, e) {
1334
+ return t.reduce((r, n) => Je(n.values, e).map(
1335
+ (a, o) => r[o] ? a.value > r[o] ? a.value : r[o] : a.value ?? 0
1336
1336
  ), []);
1337
1337
  }
1338
- function Vr(t, e) {
1339
- return t.reduce((r, n) => Xe(n.values, e).map(
1340
- (a, u) => {
1341
- const o = a.value == null || a.value < 0 ? 0 : a.value;
1342
- return r[u] ? r[u] + o : o;
1338
+ function Ur(t, e) {
1339
+ return t.reduce((r, n) => Je(n.values, e).map(
1340
+ (a, o) => {
1341
+ const l = a.value == null || a.value < 0 ? 0 : a.value;
1342
+ return r[o] ? r[o] + l : l;
1343
1343
  }
1344
1344
  ), []);
1345
1345
  }
1346
- const vt = {
1347
- "stacked-bar": Vr
1346
+ const _t = {
1347
+ "stacked-bar": Ur
1348
1348
  };
1349
- function Ct(t, e, r, n, a, u, o, i) {
1350
- const l = f(
1349
+ function jt(t, e, r, n, a, o, l, i) {
1350
+ const u = v(
1351
1351
  () => {
1352
1352
  var s;
1353
1353
  return e.value.withTooltip !== !1 && !((s = e.value.tooltipOptions) != null && s.targetElement);
1354
1354
  }
1355
1355
  );
1356
1356
  function c(s) {
1357
- var g;
1358
- const v = ((g = a == null ? void 0 : a.value) == null ? void 0 : g.length) ?? 0, m = i != null && i.value && vt[i.value] ? vt[i.value](
1357
+ var h;
1358
+ const f = ((h = a == null ? void 0 : a.value) == null ? void 0 : h.length) ?? 0, m = i != null && i.value && _t[i.value] ? _t[i.value](
1359
1359
  s,
1360
- v
1361
- ) : jr(s, v);
1362
- t.value = m.map((h, _) => ({
1363
- cx: (u == null ? void 0 : u.value) === O.HORIZONTAL ? r.value(h) : Be(r.value, _),
1364
- cy: (u == null ? void 0 : u.value) === O.HORIZONTAL ? Be(n.value, _) : n.value(h)
1360
+ f
1361
+ ) : Wr(s, f);
1362
+ t.value = m.map((g, _) => ({
1363
+ cx: (o == null ? void 0 : o.value) === O.HORIZONTAL ? r.value(g) : je(r.value, _),
1364
+ cy: (o == null ? void 0 : o.value) === O.HORIZONTAL ? je(n.value, _) : n.value(g)
1365
1365
  }));
1366
1366
  }
1367
1367
  return H(
1368
1368
  [r, n],
1369
1369
  () => {
1370
- r.value && n.value && (o != null && o.value) && l.value && c(o.value);
1370
+ r.value && n.value && (l != null && l.value) && u.value && c(l.value);
1371
1371
  },
1372
1372
  { immediate: !0 }
1373
- ), { shouldGenerateTooltipAnchors: l, updateTooltipAnchorAttributes: c };
1373
+ ), { shouldGenerateTooltipAnchors: u, updateTooltipAnchorAttributes: c };
1374
1374
  }
1375
- function Mr() {
1376
- const t = $e({
1375
+ function Zr() {
1376
+ const t = Ie({
1377
1377
  opened: !1,
1378
1378
  targetElement: null
1379
1379
  });
@@ -1383,174 +1383,174 @@ function Mr() {
1383
1383
  t.opened = !1, t.targetElement = null;
1384
1384
  } };
1385
1385
  }
1386
- function zr(t) {
1387
- return { getTooltipItems: f(
1388
- () => (r) => t.value.map(({ color: n, label: a, values: u }) => {
1389
- var o, i, l;
1386
+ function Xr(t) {
1387
+ return { getTooltipItems: v(
1388
+ () => (r) => t.value.map(({ color: n, label: a, values: o }) => {
1389
+ var l, i, u;
1390
1390
  return {
1391
- color: ((o = u[r]) == null ? void 0 : o.color) || n,
1391
+ color: ((l = o[r]) == null ? void 0 : l.color) || n,
1392
1392
  label: a,
1393
- value: ((i = u[r]) == null ? void 0 : i.label) ?? ((l = u[r]) == null ? void 0 : l.value) ?? wt
1393
+ value: ((i = o[r]) == null ? void 0 : i.label) ?? ((u = o[r]) == null ? void 0 : u.value) ?? Pt
1394
1394
  };
1395
1395
  })
1396
1396
  ) };
1397
1397
  }
1398
- const Ge = 16, Fe = 8, je = 28, Ve = 24, se = {
1398
+ const Ve = 16, Me = 8, ze = 28, We = 24, ie = {
1399
1399
  VERTICAL: {
1400
- top: Ge,
1401
- right: Fe,
1402
- bottom: je,
1403
- left: Ve
1400
+ top: Ve,
1401
+ right: Me,
1402
+ bottom: ze,
1403
+ left: We
1404
1404
  },
1405
1405
  HORIZONTAL: {
1406
- top: Ge,
1407
- right: Fe,
1408
- bottom: je,
1409
- left: Ve
1406
+ top: Ve,
1407
+ right: Me,
1408
+ bottom: ze,
1409
+ left: We
1410
1410
  }
1411
1411
  };
1412
- function Wr(t) {
1413
- return !t || t === "auto" || t.top == null || t.top === "auto" ? Ge : t.top;
1412
+ function Yr(t) {
1413
+ return !t || t === "auto" || t.top == null || t.top === "auto" ? Ve : t.top;
1414
1414
  }
1415
- function Ur(t) {
1416
- return !t || t === "auto" || t.right == null || t.right === "auto" ? Fe : t.right;
1415
+ function Kr(t) {
1416
+ return !t || t === "auto" || t.right == null || t.right === "auto" ? Me : t.right;
1417
1417
  }
1418
- function Zr(t, e) {
1419
- return !t || t === "auto" || t.bottom == null || t.bottom === "auto" ? e || je : t.bottom;
1418
+ function Jr(t, e) {
1419
+ return !t || t === "auto" || t.bottom == null || t.bottom === "auto" ? e || ze : t.bottom;
1420
1420
  }
1421
- function Xr(t, e) {
1422
- return !t || t === "auto" || t.left == null || t.left === "auto" ? e || Ve : t.left;
1421
+ function Qr(t, e) {
1422
+ return !t || t === "auto" || t.left == null || t.left === "auto" ? e || We : t.left;
1423
1423
  }
1424
- const Yr = /* @__PURE__ */ R({
1424
+ const qr = /* @__PURE__ */ R({
1425
1425
  __name: "lume-chart",
1426
1426
  props: {
1427
- ...me(),
1427
+ ...ve(),
1428
1428
  chartType: {
1429
1429
  type: String,
1430
1430
  default: null
1431
1431
  }
1432
1432
  },
1433
1433
  setup(t, { emit: e }) {
1434
- const r = t, n = X(), { data: a, labels: u, color: o, options: i, orientation: l, chartType: c } = F(r), s = I(-1), v = I(null), m = I(null), g = I([]), h = I(null), _ = I(0), x = I(0), { allOptions: d } = Q(i), { internalData: p, computedLabels: y, containerSize: b, updateSize: A, chartID: $ } = et(a, u, o, d, l), { listenInternalEvent: T } = q(e, $), { xScale: N, yScale: S } = er(
1434
+ const r = t, n = X(), { data: a, labels: o, color: l, options: i, orientation: u, chartType: c } = V(r), s = I(-1), f = I(null), m = I(null), h = I([]), g = I(null), _ = I(0), x = I(0), { allOptions: d } = Q(i), { internalData: p, computedLabels: y, containerSize: k, updateSize: T, chartID: N } = rt(a, o, l, d, u), { listenInternalEvent: A } = q(e, N), { xScale: D, yScale: C } = ar(
1435
1435
  p,
1436
1436
  y,
1437
- b,
1438
- l,
1437
+ k,
1438
+ u,
1439
1439
  d
1440
- ), j = f(() => ({
1441
- top: Wr(d.value.margins),
1442
- right: Ur(d.value.margins),
1443
- bottom: Zr(d.value.margins, _.value),
1444
- left: Xr(d.value.margins, x.value)
1445
- })), V = f(() => {
1446
- var k;
1447
- return r.xScale ? ct(r.xScale) ? r.xScale : (k = r.xScale) == null ? void 0 : k.call(r, p.value, u.value, b) : N.value;
1448
- }), ee = f(() => {
1449
- var k;
1450
- return r.yScale ? ct(r.yScale) ? r.yScale : (k = r.yScale) == null ? void 0 : k.call(r, p.value, u.value, b) : S.value;
1451
- }), de = f(() => ({
1440
+ ), M = v(() => ({
1441
+ top: Yr(d.value.margins),
1442
+ right: Kr(d.value.margins),
1443
+ bottom: Jr(d.value.margins, _.value),
1444
+ left: Qr(d.value.margins, x.value)
1445
+ })), z = v(() => {
1446
+ var b;
1447
+ return r.xScale ? pt(r.xScale) ? r.xScale : (b = r.xScale) == null ? void 0 : b.call(r, p.value, o.value, k) : D.value;
1448
+ }), ee = v(() => {
1449
+ var b;
1450
+ return r.yScale ? pt(r.yScale) ? r.yScale : (b = r.yScale) == null ? void 0 : b.call(r, p.value, o.value, k) : C.value;
1451
+ }), ce = v(() => ({
1452
1452
  ...d.value.xAxisOptions,
1453
- withHover: l.value === O.VERTICAL
1454
- })), oe = f(() => ({
1453
+ withHover: u.value === O.VERTICAL
1454
+ })), ae = v(() => ({
1455
1455
  ...d.value.yAxisOptions,
1456
- withHover: l.value === O.HORIZONTAL
1457
- })), te = f(() => {
1458
- var k;
1459
- return (k = d.value.xAxisOptions) == null ? void 0 : k.title;
1460
- }), ue = f(() => {
1461
- var k;
1462
- return (k = d.value.yAxisOptions) == null ? void 0 : k.title;
1463
- }), E = f(() => {
1464
- var k;
1465
- return ((k = d.value.xAxisOptions) == null ? void 0 : k.withTitle) !== !1 && te.value;
1466
- }), w = f(() => {
1467
- var k;
1468
- return ((k = d.value.yAxisOptions) == null ? void 0 : k.withTitle) !== !1 && ue.value;
1469
- }), P = f(
1470
- () => a.value.every((k) => !k.values.length) || a.value.every((k) => k.values.every((G) => G === null))
1471
- ), ne = f(() => {
1472
- const k = [], { noBaseScales: G } = d.value;
1473
- return G || k.push(() => !!(V.value && ee.value)), k.every((Z) => Z() === !0);
1474
- }), { hasNegativeValues: Ae } = Gr(p), { negativeBarAttributes: L } = Fr(
1475
- b,
1476
- V,
1456
+ withHover: u.value === O.HORIZONTAL
1457
+ })), oe = v(() => {
1458
+ var b;
1459
+ return (b = d.value.xAxisOptions) == null ? void 0 : b.title;
1460
+ }), le = v(() => {
1461
+ var b;
1462
+ return (b = d.value.yAxisOptions) == null ? void 0 : b.title;
1463
+ }), E = v(() => {
1464
+ var b;
1465
+ return ((b = d.value.xAxisOptions) == null ? void 0 : b.withTitle) !== !1 && oe.value;
1466
+ }), w = v(() => {
1467
+ var b;
1468
+ return ((b = d.value.yAxisOptions) == null ? void 0 : b.withTitle) !== !1 && le.value;
1469
+ }), P = v(
1470
+ () => a.value.every((b) => !b.values.length) || a.value.every((b) => b.values.every((F) => F === null))
1471
+ ), te = v(() => {
1472
+ const b = [], { noBaseScales: F } = d.value;
1473
+ return F || b.push(() => !!(z.value && ee.value)), b.every((j) => j() === !0);
1474
+ }), { hasNegativeValues: $e } = Mr(p), { negativeBarAttributes: we } = zr(
1475
+ k,
1476
+ z,
1477
1477
  ee,
1478
- l
1479
- ), { shouldGenerateTooltipAnchors: C } = Ct(
1480
- g,
1478
+ u
1479
+ ), { shouldGenerateTooltipAnchors: De } = jt(
1480
+ h,
1481
1481
  d,
1482
- V,
1482
+ z,
1483
1483
  ee,
1484
+ o,
1484
1485
  u,
1485
- l,
1486
1486
  p,
1487
1487
  c
1488
- ), { tooltipConfig: B, showTooltip: W, hideTooltip: U } = Mr(), { getTooltipItems: z } = zr(p), at = f(
1488
+ ), { tooltipConfig: pe, showTooltip: de, hideTooltip: xe } = Zr(), { getTooltipItems: me } = Xr(p), L = v(
1489
1489
  () => {
1490
- var k;
1491
- return ((k = d.value.tooltipOptions) == null ? void 0 : k.position) || "top";
1490
+ var b;
1491
+ return ((b = d.value.tooltipOptions) == null ? void 0 : b.position) || "top";
1492
1492
  }
1493
- ), Le = f(() => {
1494
- var G;
1495
- const k = (G = d.value.tooltipOptions) == null ? void 0 : G.withPointerEvents;
1496
- return B.opened && (!k || k && h.value === !1);
1493
+ ), $ = v(() => {
1494
+ var F;
1495
+ const b = (F = d.value.tooltipOptions) == null ? void 0 : F.withPointerEvents;
1496
+ return pe.opened && (!b || b && g.value === !1);
1497
1497
  });
1498
- function ve(k) {
1499
- var Z;
1500
- if (d.value.withHover === !1 || k === s.value) return;
1501
- const G = s.value;
1502
- if (s.value = k, d.value.withTooltip !== !1) {
1503
- const Ut = (Z = d.value.tooltipOptions) != null && Z.targetElement ? d.value.tooltipOptions.targetElement === "self" ? m.value.$el : d.value.tooltipOptions.targetElement : v.value[k];
1504
- W(Ut);
1498
+ function B(b) {
1499
+ var j;
1500
+ if (d.value.withHover === !1 || b === s.value) return;
1501
+ const F = s.value;
1502
+ if (s.value = b, d.value.withTooltip !== !1) {
1503
+ const Kt = (j = d.value.tooltipOptions) != null && j.targetElement ? d.value.tooltipOptions.targetElement === "self" ? m.value.$el : d.value.tooltipOptions.targetElement : f.value[b];
1504
+ de(Kt);
1505
1505
  }
1506
- e("hovered-index-changed", { newIndex: k, oldIndex: G }), e("update:hoveredIndex", k);
1506
+ e("hovered-index-changed", { newIndex: b, oldIndex: F }), e("update:hoveredIndex", b);
1507
1507
  }
1508
- function le() {
1509
- U(), s.value = -1, e("update:hoveredIndex", -1);
1508
+ function G() {
1509
+ xe(), s.value = -1, e("update:hoveredIndex", -1);
1510
1510
  }
1511
- function fe(k) {
1511
+ function U(b) {
1512
1512
  if (!a.value.some(
1513
- ({ values: Z }) => k <= Z.length - 1
1513
+ ({ values: j }) => b <= j.length - 1
1514
1514
  )) {
1515
- re(J.InvalidHoveredIndex);
1515
+ ne(J.InvalidHoveredIndex);
1516
1516
  return;
1517
1517
  }
1518
- k == null || k === -1 ? le() : ve(k);
1518
+ b == null || b === -1 ? G() : B(b);
1519
1519
  }
1520
- function pe() {
1520
+ function Z() {
1521
1521
  setTimeout(() => {
1522
- Le.value && le(), e("chart-mouseleave");
1522
+ $.value && G(), e("chart-mouseleave");
1523
1523
  }, 0);
1524
1524
  }
1525
- function Mt(k) {
1526
- A(k), e("resize", k);
1525
+ function it(b) {
1526
+ T(b), e("resize", b);
1527
1527
  }
1528
- function zt({ index: k, value: G, event: Z }) {
1529
- k !== null && ve(k), e("axis-mouseenter", { index: k, value: G, event: Z });
1528
+ function He({ index: b, value: F, event: j }) {
1529
+ b !== null && B(b), e("axis-mouseenter", { index: b, value: F, event: j });
1530
1530
  }
1531
- function Wt({ index: k, value: G, event: Z }) {
1532
- e("axis-click", { index: k, value: G, event: Z });
1531
+ function Se({ index: b, value: F, event: j }) {
1532
+ e("axis-click", { index: b, value: F, event: j });
1533
1533
  }
1534
1534
  return H(
1535
1535
  a,
1536
- (k, G) => e("data-changed", { newValue: k, oldValue: G })
1536
+ (b, F) => e("data-changed", { newValue: b, oldValue: F })
1537
1537
  ), H(
1538
- u,
1539
- (k, G) => e("labels-changed", { newValue: k, oldValue: G })
1540
- ), H(P, (k) => k && re(J.Empty), { immediate: !0 }), H(() => r.hoveredIndex, fe), H(
1541
- g,
1542
- (k) => {
1543
- k && r.hoveredIndex != null && s.value === -1 && fe(r.hoveredIndex);
1538
+ o,
1539
+ (b, F) => e("labels-changed", { newValue: b, oldValue: F })
1540
+ ), H(P, (b) => b && ne(J.Empty), { immediate: !0 }), H(() => r.hoveredIndex, U), H(
1541
+ h,
1542
+ (b) => {
1543
+ b && r.hoveredIndex != null && s.value === -1 && U(r.hoveredIndex);
1544
1544
  },
1545
1545
  { flush: "post" }
1546
- ), H(h, (k) => {
1547
- k === !1 && B.opened && le();
1548
- }), ae(async () => {
1549
- e("rendered"), n.groups || console.error('"groups" `<slot>` must have content.'), T("lume__internal--hover", ve);
1550
- }), De("chartID", $), De("isEmpty", P), De("tooltipAnchorAttributes", g), { __sfc: !0, props: r, slots: n, emit: e, data: a, labels: u, color: o, options: i, orientation: l, chartType: c, internalHoveredIndex: s, tooltipAnchor: v, chartContainer: m, tooltipAnchorAttributes: g, isHoveringTooltip: h, xAxisHeight: _, yAxisWidth: x, allOptions: d, internalData: p, computedLabels: y, containerSize: b, updateSize: A, chartID: $, listenInternalEvent: T, xScale: N, yScale: S, computedMargins: j, computedXScale: V, computedYScale: ee, computedXAxisOptions: de, computedYAxisOptions: oe, xAxisTitle: te, yAxisTitle: ue, showXAxisTitle: E, showYAxisTitle: w, isEmpty: P, isReady: ne, hasNegativeValues: Ae, negativeBarAttributes: L, shouldGenerateTooltipAnchors: C, tooltipConfig: B, showTooltip: W, hideTooltip: U, getTooltipItems: z, tooltipPosition: at, shouldHideTooltip: Le, handleInternalHover: ve, handleHideTooltip: le, handleExternalHover: fe, handleMouseleave: pe, handleResize: Mt, handleAxisMouseenter: zt, handleAxisClick: Wt, LumeAxis: Sn, LumeBar: Ye, LumeChartContainer: lr, LumeChartLegend: vr, LumeTooltip: Dr, LumeOverlayGroup: Cr, TOOLTIP_ANCHOR_RADIUS: An };
1546
+ ), H(g, (b) => {
1547
+ b === !1 && pe.opened && G();
1548
+ }), re(async () => {
1549
+ e("rendered"), n.groups || console.error('"groups" `<slot>` must have content.'), A("lume__internal--hover", B);
1550
+ }), Pe("chartID", N), Pe("isEmpty", P), Pe("tooltipAnchorAttributes", h), { __sfc: !0, props: r, slots: n, emit: e, data: a, labels: o, color: l, options: i, orientation: u, chartType: c, internalHoveredIndex: s, tooltipAnchor: f, chartContainer: m, tooltipAnchorAttributes: h, isHoveringTooltip: g, xAxisHeight: _, yAxisWidth: x, allOptions: d, internalData: p, computedLabels: y, containerSize: k, updateSize: T, chartID: N, listenInternalEvent: A, xScale: D, yScale: C, computedMargins: M, computedXScale: z, computedYScale: ee, computedXAxisOptions: ce, computedYAxisOptions: ae, xAxisTitle: oe, yAxisTitle: le, showXAxisTitle: E, showYAxisTitle: w, isEmpty: P, isReady: te, hasNegativeValues: $e, negativeBarAttributes: we, shouldGenerateTooltipAnchors: De, tooltipConfig: pe, showTooltip: de, hideTooltip: xe, getTooltipItems: me, tooltipPosition: L, shouldHideTooltip: $, handleInternalHover: B, handleHideTooltip: G, handleExternalHover: U, handleMouseleave: Z, handleResize: it, handleAxisMouseenter: He, handleAxisClick: Se, LumeAxis: Gn, LumeBar: Qe, LumeChartContainer: dr, LumeChartLegend: _r, LumeTooltip: Rr, LumeOverlayGroup: jr, TOOLTIP_ANCHOR_RADIUS: In };
1551
1551
  }
1552
1552
  });
1553
- var Kr = function() {
1553
+ var ea = function() {
1554
1554
  var e = this, r = e._self._c, n = e._self._setupProxy;
1555
1555
  return r(n.LumeChartContainer, { ref: "chartContainer", attrs: { id: `lume-chart_${n.chartID}`, margins: n.computedMargins, "container-size": n.containerSize, "no-min-size": n.allOptions.noMinSize, "transparent-background": n.allOptions.transparentBackground, orientation: n.orientation, "data-j-lume-chart": "" }, on: { resize: n.handleResize, click: function(a) {
1556
1556
  return n.emit("chart-click", a);
@@ -1604,18 +1604,18 @@ var Kr = function() {
1604
1604
  }, "lume__internal--axis-size": function(a) {
1605
1605
  n.yAxisWidth = a;
1606
1606
  } } })];
1607
- }, { xScale: n.computedXScale, yScale: n.computedYScale, containerSize: n.containerSize, options: n.allOptions, hoveredIndex: n.internalHoveredIndex }) : 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, u) {
1608
- return r("circle", e._b({ key: `anchor_${u}`, ref: "tooltipAnchor", refInFor: !0, staticClass: "lume-fill--transparent", attrs: { r: n.TOOLTIP_ANCHOR_RADIUS } }, "circle", a, !1));
1607
+ }, { xScale: n.computedXScale, yScale: n.computedYScale, containerSize: n.containerSize, options: n.allOptions, hoveredIndex: n.internalHoveredIndex }) : 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) {
1608
+ return r("circle", e._b({ key: `anchor_${o}`, ref: "tooltipAnchor", refInFor: !0, staticClass: "lume-fill--transparent", attrs: { r: n.TOOLTIP_ANCHOR_RADIUS } }, "circle", a, !1));
1609
1609
  }), 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.internalHoveredIndex, containerSize: n.containerSize, transition: n.allOptions.withTransition !== !1, classList: e.classList })] : e._e()], 2);
1610
- }, Jr = [], Qr = /* @__PURE__ */ D(
1611
- Yr,
1612
- Kr,
1613
- Jr,
1610
+ }, ta = [], na = /* @__PURE__ */ S(
1611
+ qr,
1612
+ ea,
1613
+ ta,
1614
1614
  !1,
1615
1615
  null,
1616
1616
  "17c48844"
1617
1617
  );
1618
- const _e = Qr.exports, ft = 8, qr = 8, ea = 20, he = 2, ta = 3, na = 4, pt = 2, ra = /* @__PURE__ */ R({
1618
+ const fe = na.exports, gt = 8, ra = 8, aa = 20, _e = 2, oa = 3, la = 4, ht = 2, ua = /* @__PURE__ */ R({
1619
1619
  __name: "lume-alluvial-node-label",
1620
1620
  props: {
1621
1621
  bottom: { type: Boolean, default: !1 },
@@ -1624,34 +1624,34 @@ const _e = Qr.exports, ft = 8, qr = 8, ea = 20, he = 2, ta = 3, na = 4, pt = 2,
1624
1624
  },
1625
1625
  emits: ["lume__internal--node-resize"],
1626
1626
  setup(t, { emit: e }) {
1627
- const r = t, n = I(null), a = I(r.maxWidth), u = I(1);
1627
+ const r = t, n = I(null), a = I(r.maxWidth), o = I(1);
1628
1628
  return H(
1629
1629
  [n, () => r.maxWidth],
1630
- async ([o, i]) => {
1631
- if (o && i) {
1632
- a.value = i, await Pe();
1633
- const { width: l, height: c } = o.getBoundingClientRect();
1634
- a.value = l + pt > i ? i : l + pt, u.value = Math.ceil(c);
1630
+ async ([l, i]) => {
1631
+ if (l && i) {
1632
+ a.value = i, await Be();
1633
+ const { width: u, height: c } = l.getBoundingClientRect();
1634
+ a.value = u + ht > i ? i : u + ht, o.value = Math.ceil(c);
1635
1635
  }
1636
1636
  },
1637
1637
  { immediate: !0 }
1638
- ), H(a, async (o) => {
1639
- o !== r.maxWidth && (await Pe(), e("lume__internal--node-resize"));
1640
- }), { __sfc: !0, props: r, emit: e, text: n, foreignObjectWidth: a, foreignObjectHeight: u };
1638
+ ), H(a, async (l) => {
1639
+ l !== r.maxWidth && (await Be(), e("lume__internal--node-resize"));
1640
+ }), { __sfc: !0, props: r, emit: e, text: n, foreignObjectWidth: a, foreignObjectHeight: o };
1641
1641
  }
1642
1642
  });
1643
- var aa = function() {
1643
+ var ia = function() {
1644
1644
  var e = this, r = e._self._c, n = e._self._setupProxy;
1645
1645
  return e.maxWidth ? r("foreignObject", { staticClass: "lume-alluvial-group__node-foreign", attrs: { y: e.bottom ? "0.1em" : -n.foreignObjectHeight + 1, x: e.left ? -n.foreignObjectWidth : 0, width: n.foreignObjectWidth, height: n.foreignObjectHeight } }, [r("div", { staticClass: "lume-alluvial-group__label-wrapper" }, [r("span", { ref: "text", staticClass: "lume-alluvial-group__node-label" }, [e._t("default")], 2)])]) : r("text", { staticClass: "lume-alluvial-group__node-label", attrs: { dy: e.bottom ? ".2em" : "-.2em", "dominant-baseline": e.bottom ? "hanging" : "auto" } }, [e._t("default")], 2);
1646
- }, oa = [], ua = /* @__PURE__ */ D(
1647
- ra,
1648
- aa,
1649
- oa,
1646
+ }, sa = [], ca = /* @__PURE__ */ S(
1647
+ ua,
1648
+ ia,
1649
+ sa,
1650
1650
  !1,
1651
1651
  null,
1652
1652
  "7126dfdb"
1653
1653
  );
1654
- const la = ua.exports, ia = /* @__PURE__ */ R({
1654
+ const da = ca.exports, va = /* @__PURE__ */ R({
1655
1655
  __name: "lume-alluvial-node-value",
1656
1656
  props: {
1657
1657
  bottom: { type: Boolean, default: !0 }
@@ -1660,45 +1660,54 @@ const la = ua.exports, ia = /* @__PURE__ */ R({
1660
1660
  return { __sfc: !0 };
1661
1661
  }
1662
1662
  });
1663
- var sa = function() {
1663
+ var fa = function() {
1664
1664
  var e = this, r = e._self._c;
1665
1665
  return e._self._setupProxy, r("text", { staticClass: "lume-alluvial-group__node-value", attrs: { y: e.bottom ? ".2em" : "-.2em", "dominant-baseline": e.bottom ? "hanging" : "auto" } }, [e._t("default")], 2);
1666
- }, ca = [], da = /* @__PURE__ */ D(
1667
- ia,
1668
- sa,
1669
- ca,
1666
+ }, pa = [], ma = /* @__PURE__ */ S(
1667
+ va,
1668
+ fa,
1669
+ pa,
1670
1670
  !1,
1671
1671
  null,
1672
1672
  "b4fc758b"
1673
1673
  );
1674
- const va = da.exports, fa = /* @__PURE__ */ R({
1674
+ const _a = ma.exports, ga = /* @__PURE__ */ R({
1675
1675
  __name: "lume-alluvial-node-header",
1676
1676
  props: {
1677
+ align: {
1678
+ type: String,
1679
+ default: "center"
1680
+ },
1677
1681
  x: { type: Number, required: !0 },
1678
1682
  y: { type: Number, required: !0 }
1679
1683
  },
1680
1684
  setup(t) {
1681
- const e = I(null), r = f(
1682
- () => e.value && `translate(${-e.value.getBBox().width / 2}, 0)`
1683
- ), n = f(
1684
- () => e.value && `translate(${e.value.getBBox().width / 2}, 0)`
1685
+ const e = t, r = I(null), n = v(() => {
1686
+ var i;
1687
+ return ((i = r.value) == null ? void 0 : i.getBBox().width) ?? 0;
1688
+ }), a = v(() => e.align === "left" ? 0 : e.align === "right" ? -n.value : -n.value / 2), o = v(
1689
+ () => r.value && `translate(${a.value}, 0)`
1690
+ ), l = v(
1691
+ () => r.value && `translate(${a.value + n.value}, 0)`
1685
1692
  );
1686
- return { __sfc: !0, textRef: e, beforeTransform: r, afterTransform: n };
1693
+ return { __sfc: !0, props: e, textRef: r, textWidth: n, textStart: a, beforeTransform: o, afterTransform: l };
1687
1694
  }
1688
1695
  });
1689
- var pa = function() {
1696
+ var ha = function() {
1690
1697
  var e = this, r = e._self._c, n = e._self._setupProxy;
1691
- return r("g", { attrs: { transform: `translate(${e.x}, ${e.y})` } }, [r("g", { attrs: { transform: n.beforeTransform } }, [e._t("before")], 2), r("text", { ref: "textRef", staticClass: "lume-alluvial-group__node-header lume-typography--caption" }, [e._t("default")], 2), r("g", { attrs: { transform: n.afterTransform } }, [e._t("after")], 2)]);
1692
- }, ma = [], _a = /* @__PURE__ */ D(
1693
- fa,
1694
- pa,
1695
- ma,
1698
+ return r("g", { attrs: { transform: `translate(${e.x}, ${e.y})` } }, [r("g", { attrs: { transform: n.beforeTransform } }, [e._t("before")], 2), r("text", { ref: "textRef", staticClass: "lume-alluvial-group__node-header lume-typography--caption", class: {
1699
+ [`lume-alluvial-group__node-header--${e.align}`]: e.align !== "center"
1700
+ } }, [e._t("default")], 2), r("g", { attrs: { transform: n.afterTransform } }, [e._t("after")], 2)]);
1701
+ }, ya = [], ba = /* @__PURE__ */ S(
1702
+ ga,
1703
+ ha,
1704
+ ya,
1696
1705
  !1,
1697
1706
  null,
1698
- "0e483453"
1707
+ "ee436a8d"
1699
1708
  );
1700
- const ha = _a.exports;
1701
- function mt(t, e) {
1709
+ const ka = ba.exports;
1710
+ function yt(t, e) {
1702
1711
  return {
1703
1712
  x0: 0 + (e ? e.left : 0),
1704
1713
  y0: 0 + (e ? e.top : 0),
@@ -1706,86 +1715,101 @@ function mt(t, e) {
1706
1715
  y1: t.height - (e ? e.bottom : 0)
1707
1716
  };
1708
1717
  }
1709
- function ga(t) {
1710
- const e = I(mt(t));
1718
+ function xa(t) {
1719
+ const e = I(yt(t));
1711
1720
  function r(n) {
1712
- e.value = mt(t, n);
1721
+ e.value = yt(t, n);
1713
1722
  }
1714
1723
  return { extents: e, updateExtents: r };
1715
1724
  }
1716
- var Ie = /* @__PURE__ */ ((t) => (t.GraphProblem = "There was an issue generating your alluvial graph.", t.BarScaleDomainAbove0 = "Bar linear scale domain cannot start above 0!", t.BarScaleNull = "Bar linear scale cannot be `null`", t))(Ie || {});
1717
- const ya = "[lume] ";
1718
- function Me(t, e, r = !0) {
1719
- r && It() || console.error(ya + "Error: " + t, e);
1725
+ var Ae = /* @__PURE__ */ ((t) => (t.GraphProblem = "There was an issue generating your alluvial graph.", t.BarScaleDomainAbove0 = "Bar linear scale domain cannot start above 0!", t.BarScaleNull = "Bar linear scale cannot be `null`", t))(Ae || {});
1726
+ const La = "[lume] ";
1727
+ function Ue(t, e, r = !0) {
1728
+ r && wt() || console.error(La + "Error: " + t, e);
1720
1729
  }
1721
- const ba = 200;
1722
- function M(t) {
1730
+ const Ta = 200;
1731
+ function W(t) {
1723
1732
  return typeof t == "string" || typeof t == "number" ? t : t.id ?? t.label;
1724
1733
  }
1725
- function ka(t, e) {
1734
+ function Aa(t, e) {
1726
1735
  return e.nodes.find((r) => r.id === t);
1727
1736
  }
1728
- function xa(t, e) {
1737
+ function Oa(t, e) {
1729
1738
  return e.links.find((r) => r.id === t);
1730
1739
  }
1731
- function Bt(t) {
1740
+ function Vt(t) {
1732
1741
  return !!(t.sourceLinks && t.targetLinks);
1733
1742
  }
1734
- function Aa(t, e) {
1743
+ function ot(t) {
1744
+ return Math.max(
1745
+ ...t.filter((e) => e.parentNodeId == null).map(({ layer: e }) => e)
1746
+ );
1747
+ }
1748
+ function Mt(t) {
1749
+ return t.layer === 0;
1750
+ }
1751
+ function zt(t, e) {
1752
+ return t.parentNodeId == null && t.layer === e;
1753
+ }
1754
+ function Wt(t, e, r) {
1755
+ return Mt(t) ? e.alignFirstNodeLabels !== "right" : zt(t, r) ? e.alignLastNodeLabels === "left" : !1;
1756
+ }
1757
+ function Ia(t, e, r) {
1735
1758
  if (!e) return;
1736
- const r = t.nodes.filter((o) => o.targetLinks.length === 0).map((o) => `${o.id}`), n = t.nodes.filter((o) => o.sourceLinks.length === 0).map((o) => `${o.id}`), a = e.filter((o) => r.includes(o.dataset.id)).reduce(
1737
- (o, i) => Math.max(o, i.getBBox().width),
1759
+ const n = ot(t.nodes), a = t.nodes.filter((u) => Mt(u)).map((u) => `${u.id}`), o = t.nodes.filter((u) => zt(u, n)).map((u) => `${u.id}`), l = e.filter((u) => a.includes(u.dataset.id)).reduce(
1760
+ (u, c) => Math.max(u, c.getBBox().width),
1738
1761
  -1 / 0
1739
- ), u = e.filter((o) => n.includes(o.dataset.id)).reduce(
1740
- (o, i) => Math.max(o, i.getBBox().width),
1762
+ ), i = e.filter((u) => o.includes(u.dataset.id)).reduce(
1763
+ (u, c) => Math.max(u, c.getBBox().width),
1741
1764
  -1 / 0
1742
1765
  );
1743
1766
  return {
1744
- left: a,
1767
+ left: r.alignFirstNodeLabels === "right" ? 0 : l,
1745
1768
  top: 0,
1746
- right: u,
1769
+ right: r.alignLastNodeLabels === "left" ? 0 : i,
1747
1770
  bottom: 0
1748
1771
  };
1749
1772
  }
1750
- function La(t) {
1751
- return t.map((e) => {
1752
- const r = e.y1 - e.y0 < he;
1773
+ function Na(t, e) {
1774
+ const r = ot(t);
1775
+ return t.map((n) => {
1776
+ const a = n.y1 - n.y0 < _e;
1753
1777
  return {
1754
- x: e.x0,
1755
- y: e.y0 - (r ? he / 2 : 0),
1778
+ x: n.x0,
1779
+ y: n.y0 - (a ? _e / 2 : 0),
1756
1780
  // Negative offset to account for the min. height
1757
- width: e.x1 - e.x0,
1758
- height: r ? he : e.y1 - e.y0,
1781
+ width: n.x1 - n.x0,
1782
+ height: a ? _e : n.y1 - n.y0,
1759
1783
  textTransform: {
1760
- x: e.depth > 0 ? e.x1 + ft : e.x0 - ft,
1761
- y: (e.y1 + e.y0) / 2
1784
+ x: Wt(n, e, r) ? n.x0 - gt : n.x1 + gt,
1785
+ y: (n.y1 + n.y0) / 2
1762
1786
  },
1763
- node: e
1787
+ node: n
1764
1788
  };
1765
1789
  });
1766
1790
  }
1767
- function Ta(t) {
1791
+ function Ea(t) {
1768
1792
  return [t.source.x1, t.y0];
1769
1793
  }
1770
- function Oa(t) {
1794
+ function $a(t) {
1771
1795
  return [t.target.x0, t.y1];
1772
1796
  }
1773
- function Ia(t) {
1774
- return t.curveFunction ? Qt(t.curveFunction).source(Ta).target(Oa) : Zt();
1797
+ function wa(t) {
1798
+ return t.curveFunction ? nn(t.curveFunction).source(Ea).target($a) : Jt();
1775
1799
  }
1776
- function Ea(t) {
1800
+ function Da(t) {
1777
1801
  return t.map((e) => {
1778
1802
  var r;
1779
1803
  return {
1780
1804
  id: e.id,
1781
- color: e.color || ((r = e.source) == null ? void 0 : r.color) || xe,
1782
- d: Ia(e)(e),
1805
+ color: e.color || ((r = e.source) == null ? void 0 : r.color) || ke,
1806
+ d: wa(e)(e),
1783
1807
  strokeWidth: Math.max(1, e.width),
1784
1808
  link: e
1785
1809
  };
1786
1810
  });
1787
1811
  }
1788
- function _t(t, e, r, n, a) {
1812
+ function bt(t, e, r, n, a) {
1789
1813
  if (n === !1) {
1790
1814
  t.node = {
1791
1815
  ...t.node,
@@ -1793,140 +1817,140 @@ function _t(t, e, r, n, a) {
1793
1817
  };
1794
1818
  return;
1795
1819
  }
1796
- const u = Date.now(), o = _n(e, r), i = () => {
1797
- let c = (Date.now() - u) / ba;
1820
+ const o = Date.now(), l = bn(e, r), i = () => {
1821
+ let c = (Date.now() - o) / Ta;
1798
1822
  c > 1 && (c = 1), t.node = {
1799
1823
  ...t.node,
1800
- transitionValue: a && c === 1 ? void 0 : o(c)
1824
+ transitionValue: a && c === 1 ? void 0 : l(c)
1801
1825
  }, c < 1 && requestAnimationFrame(i);
1802
1826
  };
1803
1827
  requestAnimationFrame(i);
1804
1828
  }
1805
- const $a = ":aggregated";
1806
- function Na(t) {
1807
- const e = I([]), r = f(() => {
1829
+ const Ha = ":aggregated";
1830
+ function Sa(t) {
1831
+ const e = I([]), r = v(() => {
1808
1832
  var c, s;
1809
- const l = /* @__PURE__ */ new Map();
1810
- return (s = (c = t.value) == null ? void 0 : c[0]) == null || s.values.forEach(({ value: v, expandableNodes: m }) => {
1811
- m != null && m.length && l.set(v, [...m]);
1812
- }), l;
1813
- }), n = f(
1833
+ const u = /* @__PURE__ */ new Map();
1834
+ return (s = (c = t.value) == null ? void 0 : c[0]) == null || s.values.forEach(({ value: f, expandableNodes: m }) => {
1835
+ m != null && m.length && u.set(f, [...m]);
1836
+ }), u;
1837
+ }), n = v(
1814
1838
  () => {
1815
- const l = /* @__PURE__ */ new Map();
1839
+ const u = /* @__PURE__ */ new Map();
1816
1840
  return r.value.forEach((c, s) => {
1817
- c.forEach((v) => l.set(v, s));
1818
- }), l;
1841
+ c.forEach((f) => u.set(f, s));
1842
+ }), u;
1819
1843
  }
1820
1844
  );
1821
- function a(l) {
1822
- return r.value.has(l);
1845
+ function a(u) {
1846
+ return r.value.has(u);
1823
1847
  }
1824
- function u(l) {
1825
- return n.value.has(l);
1848
+ function o(u) {
1849
+ return n.value.has(u);
1826
1850
  }
1827
- function o(l) {
1828
- return e.value.includes(l);
1851
+ function l(u) {
1852
+ return e.value.includes(u);
1829
1853
  }
1830
- function i(l) {
1831
- a(l) && (e.value = o(l) ? e.value.filter((c) => c !== l) : [...e.value, l]);
1854
+ function i(u) {
1855
+ a(u) && (e.value = l(u) ? e.value.filter((c) => c !== u) : [...e.value, u]);
1832
1856
  }
1833
1857
  return H(t, () => e.value = []), {
1834
1858
  childIdsByParentId: r,
1835
1859
  expandedNodeIds: e,
1836
1860
  isExpandableNode: a,
1837
- isExpandedNode: o,
1838
- isSubNode: u,
1861
+ isExpandedNode: l,
1862
+ isSubNode: o,
1839
1863
  parentIdByChildId: n,
1840
1864
  toggleNodeExpansion: i
1841
1865
  };
1842
1866
  }
1843
- function wa(t, e, r, n) {
1867
+ function Pa(t, e, r, n) {
1844
1868
  if (!t || !e || n.size === 0)
1845
1869
  return { nodes: t, links: e };
1846
1870
  const a = e.filter(
1847
- (o) => !n.has(M(o.source)) && !n.has(M(o.target))
1848
- ), u = new Set(a.map(({ id: o }) => o));
1849
- return r.forEach((o, i) => {
1850
- const l = /* @__PURE__ */ new Map();
1851
- o.forEach((c) => {
1852
- Gt(e, c).forEach((s) => {
1853
- const v = M(s.target), m = l.get(v);
1871
+ (l) => !n.has(W(l.source)) && !n.has(W(l.target))
1872
+ ), o = new Set(a.map(({ id: l }) => l));
1873
+ return r.forEach((l, i) => {
1874
+ const u = /* @__PURE__ */ new Map();
1875
+ l.forEach((c) => {
1876
+ Ut(e, c).forEach((s) => {
1877
+ const f = W(s.target), m = u.get(f);
1854
1878
  if (m) {
1855
1879
  m.value += s.value;
1856
1880
  return;
1857
1881
  }
1858
- const g = `${i}:${v}`;
1859
- l.set(v, {
1860
- id: u.has(g) ? `${g}${$a}` : g,
1882
+ const h = `${i}:${f}`;
1883
+ u.set(f, {
1884
+ id: o.has(h) ? `${h}${Ha}` : h,
1861
1885
  aggregatedFrom: i,
1862
1886
  color: s.color,
1863
1887
  curveFunction: s.curveFunction,
1864
1888
  source: i,
1865
- target: v,
1889
+ target: f,
1866
1890
  value: s.value
1867
1891
  });
1868
1892
  });
1869
- }), a.push(...l.values());
1893
+ }), a.push(...u.values());
1870
1894
  }), {
1871
- nodes: t.filter((o) => !n.has(o.id)),
1895
+ nodes: t.filter((l) => !n.has(l.id)),
1872
1896
  links: a
1873
1897
  };
1874
1898
  }
1875
- function Da({
1899
+ function Ra({
1876
1900
  graph: t,
1877
1901
  nodes: e,
1878
1902
  linkDefinitions: r,
1879
1903
  expandedNodeIds: n,
1880
1904
  childIdsByParentId: a,
1881
- options: u,
1882
- extents: o
1905
+ options: o,
1906
+ extents: l
1883
1907
  }) {
1884
1908
  var i;
1885
- (i = t == null ? void 0 : t.nodes) != null && i.length && n.forEach((l) => {
1886
- const c = t.nodes.find((v) => v.id === l), s = (a.get(l) ?? []).map((v) => e.find((m) => m.id === v)).filter(Boolean);
1887
- !c || !s.length || Ha({ graph: t, parent: c, children: s, linkDefinitions: r, options: u, extents: o });
1909
+ (i = t == null ? void 0 : t.nodes) != null && i.length && n.forEach((u) => {
1910
+ const c = t.nodes.find((f) => f.id === u), s = (a.get(u) ?? []).map((f) => e.find((m) => m.id === f)).filter(Boolean);
1911
+ !c || !s.length || Ba({ graph: t, parent: c, children: s, linkDefinitions: r, options: o, extents: l });
1888
1912
  });
1889
1913
  }
1890
- function Ha({
1914
+ function Ba({
1891
1915
  graph: t,
1892
1916
  parent: e,
1893
1917
  children: r,
1894
1918
  linkDefinitions: n,
1895
1919
  options: a,
1896
- extents: u
1920
+ extents: o
1897
1921
  }) {
1898
- const o = r.map(
1899
- (s) => Fa(n, e, s)
1900
- ), i = o.reduce((s, v) => s + v, 0);
1922
+ const l = r.map(
1923
+ (s) => za(n, e, s)
1924
+ ), i = l.reduce((s, f) => s + f, 0);
1901
1925
  if (!i) return;
1902
- const l = (e.y1 - e.y0) / i;
1903
- Pa({
1926
+ const u = (e.y1 - e.y0) / i;
1927
+ Ca({
1904
1928
  parent: e,
1905
1929
  children: r,
1906
- childValues: o,
1907
- scale: l,
1930
+ childValues: l,
1931
+ scale: u,
1908
1932
  graph: t,
1909
1933
  options: a,
1910
- extents: u
1934
+ extents: o
1911
1935
  });
1912
- const c = Ca({
1936
+ const c = ja({
1913
1937
  parent: e,
1914
1938
  children: r,
1915
- childValues: o,
1916
- scale: l,
1939
+ childValues: l,
1940
+ scale: u,
1917
1941
  linkDefinitions: n
1918
1942
  });
1919
- Ga(t, e).forEach((s) => {
1920
- const v = Ba({
1943
+ Ma(t, e).forEach((s) => {
1944
+ const f = Va({
1921
1945
  children: r,
1922
1946
  aggregatedLink: s,
1923
- scale: l,
1947
+ scale: u,
1924
1948
  linkDefinitions: n
1925
1949
  });
1926
- ht(t.links, s, v), ht(
1950
+ kt(t.links, s, f), kt(
1927
1951
  s.target.targetLinks,
1928
1952
  s,
1929
- v
1953
+ f
1930
1954
  );
1931
1955
  }), e.sourceLinks = [
1932
1956
  ...e.sourceLinks.filter(
@@ -1935,120 +1959,120 @@ function Ha({
1935
1959
  ...c
1936
1960
  ], t.links.push(...c), t.nodes.push(...r);
1937
1961
  }
1938
- function Pa({
1962
+ function Ca({
1939
1963
  parent: t,
1940
1964
  children: e,
1941
1965
  childValues: r,
1942
1966
  scale: n,
1943
1967
  graph: a,
1944
- options: u,
1945
- extents: o
1968
+ options: o,
1969
+ extents: l
1946
1970
  }) {
1947
- const i = t.x1 - t.x0, l = t.x1, c = ja(a, t) ?? o.x1, s = Math.max(l, l + (c - l - i) / 2), v = r.map((_) => _ * n), m = Ra(e, u.nodePadding ?? 0), g = [...v, ...m].reduce(
1971
+ const i = t.x1 - t.x0, u = t.x1, c = Wa(a, t) ?? l.x1, s = Math.max(u, u + (c - u - i) / 2), f = r.map((_) => _ * n), m = Fa(e, o.nodePadding ?? 0), h = [...f, ...m].reduce(
1948
1972
  (_, x) => _ + x,
1949
1973
  0
1950
1974
  );
1951
- let h = Sa({ parent: t, children: e, totalHeight: g, extents: o });
1975
+ let g = Ga({ parent: t, children: e, totalHeight: h, extents: l });
1952
1976
  e.forEach((_, x) => {
1953
- h += m[x], _.x0 = s, _.x1 = s + i, _.y0 = h, _.y1 = h + v[x], _.depth = t.depth + 0.5, _.layer = t.layer + 0.5, _.parentNodeId = t.id, _.value = r[x], _.sourceLinks = [], _.targetLinks = [], h = _.y1;
1977
+ g += m[x], _.x0 = s, _.x1 = s + i, _.y0 = g, _.y1 = g + f[x], _.depth = t.depth + 0.5, _.layer = t.layer + 0.5, _.parentNodeId = t.id, _.value = r[x], _.sourceLinks = [], _.targetLinks = [], g = _.y1;
1954
1978
  });
1955
1979
  }
1956
- function Ra(t, e) {
1980
+ function Fa(t, e) {
1957
1981
  return t.map(({ offset: r }, n) => n === 0 ? 0 : typeof r == "number" ? r : e);
1958
1982
  }
1959
- function Sa({
1983
+ function Ga({
1960
1984
  parent: t,
1961
1985
  children: e,
1962
1986
  totalHeight: r,
1963
1987
  extents: n
1964
1988
  }) {
1965
1989
  const { offset: a } = e[0];
1966
- return typeof a == "number" ? t.y0 + a : Va(
1990
+ return typeof a == "number" ? t.y0 + a : Ua(
1967
1991
  (t.y0 + t.y1) / 2 - r / 2,
1968
1992
  n.y0,
1969
1993
  Math.max(n.y0, n.y1 - r)
1970
1994
  );
1971
1995
  }
1972
- function Ca({
1996
+ function ja({
1973
1997
  parent: t,
1974
1998
  children: e,
1975
1999
  childValues: r,
1976
2000
  scale: n,
1977
2001
  linkDefinitions: a
1978
2002
  }) {
1979
- let u = t.y0;
1980
- return e.map((o, i) => {
1981
- const l = nt(a, t.id, o.id), c = r[i] * n, s = {
1982
- id: (l == null ? void 0 : l.id) ?? `${t.id}:${o.id}`,
1983
- color: l == null ? void 0 : l.color,
1984
- curveFunction: l == null ? void 0 : l.curveFunction,
2003
+ let o = t.y0;
2004
+ return e.map((l, i) => {
2005
+ const u = lt(a, t.id, l.id), c = r[i] * n, s = {
2006
+ id: (u == null ? void 0 : u.id) ?? `${t.id}:${l.id}`,
2007
+ color: u == null ? void 0 : u.color,
2008
+ curveFunction: u == null ? void 0 : u.curveFunction,
1985
2009
  source: t,
1986
- target: o,
2010
+ target: l,
1987
2011
  value: r[i],
1988
2012
  width: c,
1989
- y0: u + c / 2,
1990
- y1: (o.y0 + o.y1) / 2
2013
+ y0: o + c / 2,
2014
+ y1: (l.y0 + l.y1) / 2
1991
2015
  };
1992
- return u += c, o.targetLinks.push(s), s;
2016
+ return o += c, l.targetLinks.push(s), s;
1993
2017
  });
1994
2018
  }
1995
- function Ba({
2019
+ function Va({
1996
2020
  children: t,
1997
2021
  aggregatedLink: e,
1998
2022
  scale: r,
1999
2023
  linkDefinitions: n
2000
2024
  }) {
2001
2025
  const a = e.target;
2002
- let u = e.y1 - e.width / 2;
2003
- return t.reduce((o, i) => {
2004
- const l = nt(n, i.id, a.id);
2005
- if (!l) return o;
2006
- const c = l.value * r, s = i.sourceLinks.reduce(
2007
- (m, { width: g }) => m + g,
2026
+ let o = e.y1 - e.width / 2;
2027
+ return t.reduce((l, i) => {
2028
+ const u = lt(n, i.id, a.id);
2029
+ if (!u) return l;
2030
+ const c = u.value * r, s = i.sourceLinks.reduce(
2031
+ (m, { width: h }) => m + h,
2008
2032
  i.y0
2009
- ), v = {
2010
- id: l.id,
2011
- color: l.color,
2012
- curveFunction: l.curveFunction,
2033
+ ), f = {
2034
+ id: u.id,
2035
+ color: u.color,
2036
+ curveFunction: u.curveFunction,
2013
2037
  source: i,
2014
2038
  target: a,
2015
- value: l.value,
2039
+ value: u.value,
2016
2040
  width: c,
2017
2041
  y0: s + c / 2,
2018
- y1: u + c / 2
2042
+ y1: o + c / 2
2019
2043
  };
2020
- return u += c, i.sourceLinks.push(v), o.push(v), o;
2044
+ return o += c, i.sourceLinks.push(f), l.push(f), l;
2021
2045
  }, []);
2022
2046
  }
2023
- function Ga(t, e) {
2047
+ function Ma(t, e) {
2024
2048
  return t.links.filter(
2025
2049
  (r) => r.aggregatedFrom === e.id
2026
2050
  );
2027
2051
  }
2028
- function Gt(t, e) {
2052
+ function Ut(t, e) {
2029
2053
  return t.filter(
2030
- (r) => M(r.source) === e
2054
+ (r) => W(r.source) === e
2031
2055
  );
2032
2056
  }
2033
- function nt(t, e, r) {
2057
+ function lt(t, e, r) {
2034
2058
  return t.find(
2035
- (n) => M(n.source) === e && M(n.target) === r
2059
+ (n) => W(n.source) === e && W(n.target) === r
2036
2060
  );
2037
2061
  }
2038
- function Fa(t, e, r) {
2039
- const n = nt(t, e.id, r.id);
2040
- return n ? n.value : Gt(t, r.id).reduce(
2041
- (a, { value: u }) => a + u,
2062
+ function za(t, e, r) {
2063
+ const n = lt(t, e.id, r.id);
2064
+ return n ? n.value : Ut(t, r.id).reduce(
2065
+ (a, { value: o }) => a + o,
2042
2066
  0
2043
2067
  );
2044
2068
  }
2045
- function ja(t, e) {
2069
+ function Wa(t, e) {
2046
2070
  const r = t.nodes.filter(
2047
2071
  (n) => n.layer === e.layer + 1
2048
2072
  );
2049
2073
  return r.length ? Math.min(...r.map(({ x0: n }) => n)) : null;
2050
2074
  }
2051
- function ht(t, e, r) {
2075
+ function kt(t, e, r) {
2052
2076
  const n = t.indexOf(e);
2053
2077
  if (n === -1) {
2054
2078
  t.push(...r);
@@ -2056,180 +2080,180 @@ function ht(t, e, r) {
2056
2080
  }
2057
2081
  t.splice(n, 1, ...r);
2058
2082
  }
2059
- function Va(t, e, r) {
2083
+ function Ua(t, e, r) {
2060
2084
  return Math.max(e, Math.min(t, r));
2061
2085
  }
2062
- const Ma = {
2086
+ const Za = {
2063
2087
  nodes: [],
2064
2088
  links: []
2065
2089
  };
2066
- function gt(t, e) {
2090
+ function xt(t, e) {
2067
2091
  return e.find((r) => r.every((n) => n.layer === t.layer));
2068
2092
  }
2069
- function za(t, e, r) {
2093
+ function Xa(t, e, r) {
2070
2094
  const n = I(null), {
2071
2095
  childIdsByParentId: a,
2072
- expandedNodeIds: u,
2073
- isExpandableNode: o,
2096
+ expandedNodeIds: o,
2097
+ isExpandableNode: l,
2074
2098
  isSubNode: i,
2075
- parentIdByChildId: l,
2099
+ parentIdByChildId: u,
2076
2100
  toggleNodeExpansion: c
2077
- } = Na(t), s = f(() => {
2101
+ } = Sa(t), s = v(() => {
2078
2102
  var d, p;
2079
2103
  return (p = (d = t.value) == null ? void 0 : d[0]) == null ? void 0 : p.values.map(
2080
2104
  ({
2081
2105
  label: y,
2082
- color: b,
2083
- value: A,
2084
- deriveColorFromIncomingLinks: $,
2085
- expandableNodes: T,
2086
- offset: N
2106
+ color: k,
2107
+ value: T,
2108
+ deriveColorFromIncomingLinks: N,
2109
+ expandableNodes: A,
2110
+ offset: D
2087
2111
  }) => ({
2088
- label: y || A.toString(),
2089
- color: b,
2090
- fallbackColor: b || xe,
2091
- id: A,
2092
- deriveColorFromIncomingLinks: $,
2093
- expandableNodes: T,
2094
- offset: N
2112
+ label: y || T.toString(),
2113
+ color: k,
2114
+ fallbackColor: k || ke,
2115
+ id: T,
2116
+ deriveColorFromIncomingLinks: N,
2117
+ expandableNodes: A,
2118
+ offset: D
2095
2119
  })
2096
2120
  );
2097
- }), v = f(
2121
+ }), f = v(
2098
2122
  () => {
2099
2123
  var d, p;
2100
2124
  return (p = (d = t.value) == null ? void 0 : d[0]) == null ? void 0 : p.values.map(
2101
2125
  (y) => {
2102
- var b;
2103
- return (b = y.targets) == null ? void 0 : b.map(
2104
- ({ node: A, value: $, color: T, curveFunction: N }) => ({
2105
- id: `${y.value}:${A}`,
2106
- color: T,
2107
- curveFunction: N,
2126
+ var k;
2127
+ return (k = y.targets) == null ? void 0 : k.map(
2128
+ ({ node: T, value: N, color: A, curveFunction: D }) => ({
2129
+ id: `${y.value}:${T}`,
2130
+ color: A,
2131
+ curveFunction: D,
2108
2132
  source: y.value ?? y.label,
2109
- target: A,
2110
- value: $
2133
+ target: T,
2134
+ value: N
2111
2135
  })
2112
2136
  );
2113
2137
  }
2114
2138
  ).filter(Boolean).flat();
2115
2139
  }
2116
- ), m = f(() => Xt().nodeId(M).nodeAlign(e.value.nodeAlign).nodePadding(e.value.nodePadding).nodeSort(e.value.nodeSort).nodeWidth(e.value.nodeWidth).linkSort(e.value.linkSort).iterations(e.value.iterations)), g = f(() => {
2140
+ ), m = v(() => Qt().nodeId(W).nodeAlign(e.value.nodeAlign).nodePadding(e.value.nodePadding).nodeSort(e.value.nodeSort).nodeWidth(e.value.nodeWidth).linkSort(e.value.linkSort).iterations(e.value.iterations)), h = v(() => {
2117
2141
  var d;
2118
2142
  return (d = n.value) == null ? void 0 : d.nodes.filter((p) => p.parentNodeId == null).reduce((p, y) => {
2119
- const b = gt(y, p);
2120
- return b ? (b.push(y), b.sort((A, $) => (A._y0 || A.y0) - ($._y0 || $.y0))) : p.push([y]), p;
2143
+ const k = xt(y, p);
2144
+ return k ? (k.push(y), k.sort((T, N) => (T._y0 || T.y0) - (N._y0 || N.y0))) : p.push([y]), p;
2121
2145
  }, []).sort((p, y) => p[0].layer - y[0].layer);
2122
2146
  });
2123
- function h(d) {
2124
- const { offset: p } = d, y = gt(d, g.value);
2147
+ function g(d) {
2148
+ const { offset: p } = d, y = xt(d, h.value);
2125
2149
  if (!y) return;
2126
- const b = y[y.findIndex(($) => $.id === d.id) - 1], A = b && y.length !== 1 ? b.y1 + p : p;
2127
- d._y0 = d.y0, d._y1 = d.y1, d.y0 = A, d.y1 = d.y0 + (d._y1 - d._y0);
2150
+ const k = y[y.findIndex((N) => N.id === d.id) - 1], T = k && y.length !== 1 ? k.y1 + p : p;
2151
+ d._y0 = d.y0, d._y1 = d.y1, d.y0 = T, d.y1 = d.y0 + (d._y1 - d._y0);
2128
2152
  }
2129
2153
  function _(d, p) {
2130
- const { id: y, _y0: b, y0: A } = d, $ = p.links.filter(
2131
- (S) => S.source.id === y
2132
- ), T = p.links.filter(
2133
- (S) => S.target.id === y
2134
- ), N = A - b;
2135
- $.forEach((S) => S.y0 += N), T.forEach((S) => S.y1 += N);
2136
- }
2137
- const x = f(() => {
2154
+ const { id: y, _y0: k, y0: T } = d, N = p.links.filter(
2155
+ (C) => C.source.id === y
2156
+ ), A = p.links.filter(
2157
+ (C) => C.target.id === y
2158
+ ), D = T - k;
2159
+ N.forEach((C) => C.y0 += D), A.forEach((C) => C.y1 += D);
2160
+ }
2161
+ const x = v(() => {
2138
2162
  var d;
2139
2163
  return n.value && ((d = s.value) == null || d.forEach((p) => {
2140
- p.value === 0 && (p.fallbackColor = Je.Grey), typeof p.offset == "number" && !i(p.id) && (h(p), _(p, n.value));
2164
+ p.value === 0 && (p.fallbackColor = et.Grey), typeof p.offset == "number" && !i(p.id) && (g(p), _(p, n.value));
2141
2165
  })), n.value;
2142
2166
  });
2143
- return H([m, r, u], () => {
2167
+ return H([m, r, o], () => {
2144
2168
  try {
2145
- const { x0: d, y0: p, x1: y, y1: b } = r.value, A = m.value.extent([
2169
+ const { x0: d, y0: p, x1: y, y1: k } = r.value, T = m.value.extent([
2146
2170
  [d, p],
2147
- [y, b]
2171
+ [y, k]
2148
2172
  ])(
2149
- wa(
2173
+ Pa(
2150
2174
  s.value,
2151
- v.value,
2175
+ f.value,
2152
2176
  a.value,
2153
- l.value
2177
+ u.value
2154
2178
  )
2155
2179
  );
2156
- Da({
2157
- graph: A,
2180
+ Ra({
2181
+ graph: T,
2158
2182
  nodes: s.value,
2159
- linkDefinitions: v.value,
2160
- expandedNodeIds: u.value,
2183
+ linkDefinitions: f.value,
2184
+ expandedNodeIds: o.value,
2161
2185
  childIdsByParentId: a.value,
2162
2186
  options: e.value,
2163
2187
  extents: r.value
2164
- }), n.value = A;
2188
+ }), n.value = T;
2165
2189
  } catch (d) {
2166
- Me(Ie.GraphProblem, d), n.value = Ma;
2190
+ Ue(Ae.GraphProblem, d), n.value = Za;
2167
2191
  }
2168
- }), { columns: g, graph: x, isExpandableNode: o, toggleNodeExpansion: c };
2192
+ }), { columns: h, graph: x, isExpandableNode: l, toggleNodeExpansion: c };
2169
2193
  }
2170
- function ze(t, e) {
2194
+ function Ze(t, e) {
2171
2195
  return e || (e = {}), t.targetLinks && t.targetLinks.forEach(({ source: r, value: n }) => {
2172
- e[r.id] = n, ze(
2196
+ e[r.id] = n, Ze(
2173
2197
  r,
2174
2198
  e
2175
2199
  );
2176
2200
  }), e;
2177
2201
  }
2178
- function We(t, e) {
2202
+ function Xe(t, e) {
2179
2203
  return e || (e = {}), t.sourceLinks && t.sourceLinks.forEach(({ target: r, value: n }) => {
2180
- e[r.id] = n, We(
2204
+ e[r.id] = n, Xe(
2181
2205
  r,
2182
2206
  e
2183
2207
  );
2184
2208
  }), e;
2185
2209
  }
2186
- function Wa(t, e) {
2210
+ function Ya(t, e) {
2187
2211
  return e.links.reduce((r, n) => (n.source.id in t && n.target.id in t && r.push(n.id), r), []);
2188
2212
  }
2189
- const Ua = (t, e) => {
2213
+ const Ka = (t, e) => {
2190
2214
  let r;
2191
- Bt(t) ? r = {
2215
+ Vt(t) ? r = {
2192
2216
  [t.id]: t.value,
2193
- ...ze(t),
2194
- ...We(t)
2217
+ ...Ze(t),
2218
+ ...Xe(t)
2195
2219
  } : r = {
2196
2220
  [t.source.id]: t.source.value,
2197
2221
  [t.target.id]: t.target.value,
2198
- ...ze(t.source),
2199
- ...We(t.target)
2222
+ ...Ze(t.source),
2223
+ ...Xe(t.target)
2200
2224
  };
2201
- const n = Wa(r, e);
2225
+ const n = Ya(r, e);
2202
2226
  return { nodes: r, links: n };
2203
- }, Za = (t) => {
2204
- if (Bt(t)) {
2227
+ }, Ja = (t) => {
2228
+ if (Vt(t)) {
2205
2229
  const e = [...t.sourceLinks, ...t.targetLinks];
2206
2230
  return {
2207
2231
  nodes: e.reduce(
2208
- (r, { source: n, target: a, value: u }) => n === t ? { ...r, [M(a)]: u } : { ...r, [M(n)]: u },
2209
- { [M(t)]: t.value }
2232
+ (r, { source: n, target: a, value: o }) => n === t ? { ...r, [W(a)]: o } : { ...r, [W(n)]: o },
2233
+ { [W(t)]: t.value }
2210
2234
  ),
2211
2235
  links: e.map(({ id: r }) => r)
2212
2236
  };
2213
2237
  }
2214
2238
  return {
2215
2239
  nodes: {
2216
- [M(t.target)]: t.value,
2217
- [M(t.source)]: t.source.value
2240
+ [W(t.target)]: t.value,
2241
+ [W(t.source)]: t.source.value
2218
2242
  },
2219
2243
  links: [t.id]
2220
2244
  };
2221
2245
  };
2222
- function Xa(t, e, r) {
2223
- const n = I(null), a = f(() => n.value ? typeof e.value.highlightedElements == "function" ? e.value.highlightedElements(
2246
+ function Qa(t, e, r) {
2247
+ const n = I(null), a = v(() => n.value ? typeof e.value.highlightedElements == "function" ? e.value.highlightedElements(
2224
2248
  n.value,
2225
2249
  r.value
2226
- ) : e.value.highlightedElements === "closest" ? Za(n.value, r.value) : Ua(n.value, r.value) : { nodes: {}, links: [] });
2227
- return H(a, (u, o) => {
2228
- if (u.links.length === 0 && Object.keys(u.nodes).length === 0) {
2250
+ ) : e.value.highlightedElements === "closest" ? Ja(n.value, r.value) : Ka(n.value, r.value) : { nodes: {}, links: [] });
2251
+ return H(a, (o, l) => {
2252
+ if (o.links.length === 0 && Object.keys(o.nodes).length === 0) {
2229
2253
  t.value.forEach((i) => {
2230
- i.node.id in o.nodes && _t(
2254
+ i.node.id in l.nodes && bt(
2231
2255
  i,
2232
- o.nodes[i.node.id],
2256
+ l.nodes[i.node.id],
2233
2257
  i.node.value,
2234
2258
  e.value.withTransition,
2235
2259
  !0
@@ -2238,19 +2262,19 @@ function Xa(t, e, r) {
2238
2262
  return;
2239
2263
  }
2240
2264
  t.value.forEach((i) => {
2241
- i.node.id in u.nodes && _t(
2265
+ i.node.id in o.nodes && bt(
2242
2266
  i,
2243
2267
  i.node.value,
2244
- u.nodes[i.node.id],
2268
+ o.nodes[i.node.id],
2245
2269
  e.value.withTransition
2246
2270
  );
2247
2271
  });
2248
2272
  }), { highlightedElements: a, hoveredElement: n };
2249
2273
  }
2250
- const Ya = /* @__PURE__ */ R({
2274
+ const qa = /* @__PURE__ */ R({
2251
2275
  __name: "lume-alluvial-group",
2252
2276
  props: {
2253
- ...we(),
2277
+ ...Ee(),
2254
2278
  hoveredElementId: {
2255
2279
  type: [Number, String],
2256
2280
  default: null
@@ -2258,187 +2282,224 @@ const Ya = /* @__PURE__ */ R({
2258
2282
  },
2259
2283
  emits: ["node-click", "node-mouseenter", "node-mouseleave", "link-click", "link-mouseenter", "link-mouseleave"],
2260
2284
  setup(t, { emit: e }) {
2261
- const r = t, n = Ee("chartID"), { data: a, options: u } = F(r), o = I([]), i = I([]), l = I(null), c = I(null), s = I(null), { extents: v, updateExtents: m } = ga(r.containerSize), { columns: g, graph: h, isExpandableNode: _, toggleNodeExpansion: x } = za(a, u, v), { hoveredElement: d, highlightedElements: p } = Xa(
2285
+ const r = t, n = Oe("chartID"), { data: a, options: o } = V(r), l = I([]), i = I([]), u = I(null), c = I(null), s = I(null), { extents: f, updateExtents: m } = xa(r.containerSize), { columns: h, graph: g, isExpandableNode: _, toggleNodeExpansion: x } = Xa(a, o, f), { hoveredElement: d, highlightedElements: p } = Qa(
2286
+ l,
2262
2287
  o,
2263
- u,
2264
- h
2265
- ), y = f(() => Oe(u.value.valueFormat)), b = f(
2288
+ g
2289
+ ), y = v(() => Te(o.value.valueFormat)), k = v(
2290
+ () => o.value.nodeExpansionTrigger === "block"
2291
+ ), T = v(
2266
2292
  () => Object.keys(p.value.nodes)
2267
- ), A = f(() => g.value ? g.value.map(
2268
- (L) => L[0].x0 + u.value.nodeWidth / 2
2269
- ) : []), $ = f(() => {
2270
- if (!(!u.value.nodeHeaders || !u.value.nodeHeaders.length))
2271
- return u.value.nodeHeaders.slice(0, A.value.length).map((L, C) => ({
2293
+ ), N = v(
2294
+ () => {
2295
+ var L, $;
2296
+ return ($ = (L = g.value) == null ? void 0 : L.nodes) != null && $.length ? ot(g.value.nodes) : 0;
2297
+ }
2298
+ ), A = v(() => {
2299
+ if (!h.value) return [];
2300
+ const L = h.value.length - 1;
2301
+ return h.value.map(([{ x0: $, x1: B }], G) => G === 0 && o.value.alignFirstNodeLabels === "right" ? { x: $, align: "left" } : G === L && o.value.alignLastNodeLabels === "left" ? { x: B, align: "right" } : { x: ($ + B) / 2, align: "center" });
2302
+ }), D = v(() => {
2303
+ if (!(!o.value.nodeHeaders || !o.value.nodeHeaders.length))
2304
+ return o.value.nodeHeaders.slice(0, A.value.length).map((L, $) => ({
2272
2305
  label: L,
2273
- x: A.value[C]
2306
+ ...A.value[$]
2274
2307
  }));
2275
- }), T = f(
2276
- () => u.value.nodeHeaderPadding ?? ea
2277
- ), N = f(() => {
2278
- if (!(!u.value.gradient || !h.value))
2279
- return h.value.links.reduce((L, C) => {
2280
- const { source: B, target: W } = C, U = B.color || B.fallbackColor, z = W.deriveColorFromIncomingLinks ? U : W.color || W.fallbackColor;
2281
- return L[C.id] = {
2308
+ }), C = v(
2309
+ () => o.value.nodeHeaderPadding ?? aa
2310
+ ), M = v(() => {
2311
+ if (!(!o.value.gradient || !g.value))
2312
+ return g.value.links.reduce((L, $) => {
2313
+ const { source: B, target: G } = $, U = B.color || B.fallbackColor, Z = G.deriveColorFromIncomingLinks ? U : G.color || G.fallbackColor;
2314
+ return L[$.id] = {
2282
2315
  source: U,
2283
- target: z,
2316
+ target: Z,
2284
2317
  x1: B.x1,
2285
- x2: W.x0
2318
+ x2: G.x0
2286
2319
  }, L;
2287
2320
  }, {});
2288
- }), S = f(() => {
2289
- const L = o.value.filter(
2290
- (B) => te(B)
2291
- ), C = [];
2321
+ }), z = v(() => {
2322
+ const L = l.value.filter(
2323
+ (B) => w(B)
2324
+ ), $ = [];
2292
2325
  return L.forEach((B) => {
2293
- const W = [];
2294
- i.value.filter(({ link: U }) => U.target.id === B.node.id).reverse().reduce((U, z, at, Le) => {
2295
- const ve = z.link.target.y1 - z.link.target.y0 > he;
2296
- let le, fe, pe;
2297
- return ve ? (le = z.link.target.y1 - z.link.target.y0, fe = z.link.value / B.node.value, pe = fe * le) : pe = he / Le.length, W.push({
2326
+ const G = [];
2327
+ i.value.filter(({ link: U }) => U.target.id === B.node.id).reverse().reduce((U, Z, it, He) => {
2328
+ const Se = Z.link.target.y1 - Z.link.target.y0 > _e;
2329
+ let b, F, j;
2330
+ return Se ? (b = Z.link.target.y1 - Z.link.target.y0, F = Z.link.value / B.node.value, j = F * b) : j = _e / He.length, G.push({
2298
2331
  x: B.x,
2299
2332
  y: B.y + U,
2300
- height: pe,
2333
+ height: j,
2301
2334
  width: B.width,
2302
- key: `node-block-${B.node.id}-source-link-${z.link.source.id}`,
2303
- class: `lume-alluvial-group__node-block lume-fill--${z.link.source.color || xe}`
2304
- }), U + pe;
2305
- }, 0), C.push({
2335
+ key: `node-block-${B.node.id}-source-link-${Z.link.source.id}`,
2336
+ class: `lume-alluvial-group__node-block lume-fill--${Z.link.source.color || ke}`
2337
+ }), U + j;
2338
+ }, 0), $.push({
2306
2339
  id: B.node.id,
2307
- subNodes: W
2340
+ subNodes: G
2308
2341
  });
2309
- }), C;
2342
+ }), $;
2310
2343
  });
2311
- function j(L) {
2312
- return u.value.gradient && `url('#${n}_${L.id}')`;
2344
+ function ee(L) {
2345
+ return o.value.gradient && `url('#${n}_${L.id}')`;
2313
2346
  }
2314
- function V(L) {
2315
- return b.value.length > 0 && !b.value.includes(L.toString());
2347
+ function ce(L) {
2348
+ return T.value.length > 0 && !T.value.includes(L.toString());
2316
2349
  }
2317
- function ee(L) {
2318
- return b.value.length > 0 && b.value.includes(L.toString());
2350
+ function ae(L) {
2351
+ return T.value.length > 0 && T.value.includes(L.toString());
2319
2352
  }
2320
- function de(L) {
2353
+ function oe(L) {
2321
2354
  return p.value.links.length > 0 && !p.value.links.includes(L);
2322
2355
  }
2323
- function oe(L) {
2356
+ function le(L) {
2324
2357
  return p.value.links.length > 0 && p.value.links.includes(L);
2325
2358
  }
2326
- function te(L) {
2359
+ function E(L) {
2360
+ return Wt(L, o.value, N.value);
2361
+ }
2362
+ function w(L) {
2327
2363
  return !L.node.color && L.node.deriveColorFromIncomingLinks;
2328
2364
  }
2329
- function ue(L, C) {
2330
- _(L.id) && x(L.id), e("node-click", { node: L, event: C });
2365
+ function P(L) {
2366
+ _(L.id) && x(L.id);
2331
2367
  }
2332
- function E(L, C) {
2333
- L !== d.value && (d.value = L, e("link-mouseenter", { link: L, event: C }));
2368
+ function te(L, $) {
2369
+ k.value || P(L), e("node-click", { node: L, event: $ });
2334
2370
  }
2335
- function w(L) {
2336
- const C = d.value;
2337
- d.value = null, e("link-mouseleave", { link: C, event: L });
2371
+ function $e(L, $) {
2372
+ P(L), e("node-click", { node: L, event: $ });
2338
2373
  }
2339
- function P(L) {
2374
+ function we(L) {
2375
+ k.value && P(L);
2376
+ }
2377
+ function De(L, $) {
2378
+ L !== d.value && (d.value = L, e("link-mouseenter", { link: L, event: $ }));
2379
+ }
2380
+ function pe(L) {
2381
+ const $ = d.value;
2382
+ d.value = null, e("link-mouseleave", { link: $, event: L });
2383
+ }
2384
+ function de(L) {
2340
2385
  if (L == null) {
2341
2386
  d.value = null;
2342
2387
  return;
2343
2388
  }
2344
- const C = ka(L, h.value) || xa(L, h.value);
2345
- if (!C) {
2346
- re(J.InvalidHoveredElement);
2389
+ const $ = Aa(L, g.value) || Oa(L, g.value);
2390
+ if (!$) {
2391
+ ne(J.InvalidHoveredElement);
2347
2392
  return;
2348
2393
  }
2349
- d.value = C;
2394
+ d.value = $;
2350
2395
  }
2351
- function ne(L) {
2352
- var C;
2353
- return ((C = S.value.find(({ id: B }) => L === B)) == null ? void 0 : C.subNodes) ?? [];
2396
+ function xe(L) {
2397
+ var $;
2398
+ return (($ = z.value.find(({ id: B }) => L === B)) == null ? void 0 : $.subNodes) ?? [];
2354
2399
  }
2355
- function Ae() {
2356
- const L = Aa(h.value, l.value);
2400
+ function me() {
2401
+ const L = Ia(
2402
+ g.value,
2403
+ u.value,
2404
+ o.value
2405
+ );
2357
2406
  m(L);
2358
2407
  }
2359
- return H(h, (L) => {
2360
- o.value = La(L.nodes), i.value = Ea(L.links).reverse(), d.value == null && r.hoveredElementId != null && P(r.hoveredElementId);
2408
+ return H(g, (L) => {
2409
+ l.value = Na(L.nodes, o.value), i.value = Da(L.links).reverse(), d.value == null && r.hoveredElementId != null && de(r.hoveredElementId);
2361
2410
  }), H([c, s], () => {
2362
2411
  d.value = c.value ?? s.value;
2363
- }), H([r.containerSize, l], () => {
2364
- r.containerSize.width && r.containerSize.height && Ae();
2365
- }), H(() => r.hoveredElementId, P), { __sfc: !0, props: r, emit: e, chartID: n, data: a, options: u, nodeBlocks: o, linkPaths: i, nodeTextRefs: l, pointedNode: c, focusedNode: s, extents: v, updateExtents: m, columns: g, graph: h, isExpandableNode: _, toggleNodeExpansion: x, hoveredElement: d, highlightedElements: p, formatValue: y, hoveredNodeIds: b, nodeColumnPositions: A, nodeHeaders: $, computedNodeHeaderPadding: T, gradients: N, nodesDerivingColorFromIncomingLinks: S, getLinkStroke: j, isNodeFaded: V, isNodeFocused: ee, isLinkFaded: de, isLinkFocused: oe, shouldDeriveNodeColorFromIncomingLinks: te, handleNodeClick: ue, handleLinkMouseover: E, handleLinkMouseleave: w, handleExternalHover: P, getSubNodesDerivingColorFromIncomingLinks: ne, updateMargins: Ae, LumeAlluvialNodeLabel: la, LumeAlluvialNodeValue: va, LumeAlluvialNodeHeader: ha, GHOST_STROKE_WIDTH_OFFSET: qr, NODE_OUTLINE_PADDING: ta, NODE_OUTLINE_RADIUS: na };
2412
+ }), H([r.containerSize, u], () => {
2413
+ r.containerSize.width && r.containerSize.height && me();
2414
+ }), H(
2415
+ () => [o.value.alignFirstNodeLabels, o.value.alignLastNodeLabels],
2416
+ me
2417
+ ), H(() => r.hoveredElementId, de), { __sfc: !0, props: r, emit: e, chartID: n, data: a, options: o, nodeBlocks: l, linkPaths: i, nodeTextRefs: u, pointedNode: c, focusedNode: s, extents: f, updateExtents: m, columns: h, graph: g, isExpandableNode: _, toggleNodeExpansion: x, hoveredElement: d, highlightedElements: p, formatValue: y, isBlockExpansionTrigger: k, hoveredNodeIds: T, lastNodeLayer: N, nodeColumnPositions: A, nodeHeaders: D, computedNodeHeaderPadding: C, gradients: M, nodesDerivingColorFromIncomingLinks: z, getLinkStroke: ee, isNodeFaded: ce, isNodeFocused: ae, isLinkFaded: oe, isLinkFocused: le, isLabelBeforeNode: E, shouldDeriveNodeColorFromIncomingLinks: w, toggleExpansion: P, handleNodeClick: te, handleNodeKeydown: $e, handleNodeBlockClick: we, handleLinkMouseover: De, handleLinkMouseleave: pe, handleExternalHover: de, getSubNodesDerivingColorFromIncomingLinks: xe, updateMargins: me, LumeAlluvialNodeLabel: da, LumeAlluvialNodeValue: _a, LumeAlluvialNodeHeader: ka, GHOST_STROKE_WIDTH_OFFSET: ra, NODE_OUTLINE_PADDING: oa, NODE_OUTLINE_RADIUS: la };
2366
2418
  }
2367
2419
  });
2368
- var Ka = function() {
2420
+ var eo = function() {
2369
2421
  var e = this, r = e._self._c, n = e._self._setupProxy;
2370
- return r("g", { staticClass: "lume-alluvial-group", attrs: { "data-j-alluvial-group": "" } }, [n.nodeHeaders ? r("g", [e._l(n.nodeHeaders, function(a, u) {
2371
- return [e._t(`node-header-${u}`, function() {
2372
- return [r(n.LumeAlluvialNodeHeader, { key: `header_${a.x}`, attrs: { x: a.x, y: -n.computedNodeHeaderPadding } }, [e._v(" " + e._s(a.label) + " ")])];
2373
- }, { x: a.x, y: -n.computedNodeHeaderPadding })];
2374
- })], 2) : e._e(), r("g", { staticClass: "lume-alluvial-link-group", on: { mouseleave: n.handleLinkMouseleave } }, [n.options.gradient ? r("defs", e._l(n.gradients, function(a, u) {
2375
- return r("linearGradient", { key: u, attrs: { id: `${n.chartID}_${u}`, gradientUnits: "userSpaceOnUse", x1: a.x1, x2: a.x2 } }, [r("stop", { attrs: { offset: "0%", "stop-color": `var(--lume-color--${a.source})` } }), r("stop", { attrs: { offset: "100%", "stop-color": `var(--lume-color--${a.target})` } })], 1);
2422
+ return r("g", { staticClass: "lume-alluvial-group", attrs: { "data-j-alluvial-group": "" } }, [n.nodeHeaders ? r("g", [e._l(n.nodeHeaders, function(a, o) {
2423
+ return [e._t(`node-header-${o}`, function() {
2424
+ return [r(n.LumeAlluvialNodeHeader, { key: `header_${a.x}`, attrs: { align: a.align, x: a.x, y: -n.computedNodeHeaderPadding } }, [e._v(" " + e._s(a.label) + " ")])];
2425
+ }, { align: a.align, x: a.x, y: -n.computedNodeHeaderPadding })];
2426
+ })], 2) : e._e(), r("g", { staticClass: "lume-alluvial-link-group", on: { mouseleave: n.handleLinkMouseleave } }, [n.options.gradient ? r("defs", e._l(n.gradients, function(a, o) {
2427
+ return r("linearGradient", { key: o, attrs: { id: `${n.chartID}_${o}`, gradientUnits: "userSpaceOnUse", x1: a.x1, x2: a.x2 } }, [r("stop", { attrs: { offset: "0%", "stop-color": `var(--lume-color--${a.source})` } }), r("stop", { attrs: { offset: "100%", "stop-color": `var(--lume-color--${a.target})` } })], 1);
2376
2428
  }), 1) : e._e(), e._l(n.linkPaths, function(a) {
2377
2429
  return r("path", { key: `link-ghost_${a.id}`, staticClass: "lume-alluvial-group__link", class: [
2378
2430
  "lume-stroke--transparent",
2379
2431
  "lume-alluvial-group__link--ghost"
2380
- ], attrs: { d: a.d, "stroke-width": a.strokeWidth + n.GHOST_STROKE_WIDTH_OFFSET, "data-j-alluvial-ghost": "" }, on: { click: function(u) {
2381
- return n.emit("link-click", { link: a.link, event: u });
2382
- }, mouseover: function(u) {
2383
- return n.handleLinkMouseover(a.link, u);
2432
+ ], attrs: { d: a.d, "stroke-width": a.strokeWidth + n.GHOST_STROKE_WIDTH_OFFSET, "data-j-alluvial-ghost": "" }, on: { click: function(o) {
2433
+ return n.emit("link-click", { link: a.link, event: o });
2434
+ }, mouseover: function(o) {
2435
+ return n.handleLinkMouseover(a.link, o);
2384
2436
  } } });
2385
2437
  }), e._l(n.linkPaths, function(a) {
2386
2438
  return r("path", { key: `link_${a.id}`, staticClass: "lume-alluvial-group__link", class: {
2387
2439
  [`lume-stroke--${a.color}`]: !n.options.gradient && a.color,
2388
2440
  "lume-alluvial-group__link--faded": n.isLinkFaded(a.id),
2389
2441
  "lume-alluvial-group__link--focused": n.isLinkFocused(a.id)
2390
- }, attrs: { d: a.d, stroke: n.getLinkStroke(a.link), "stroke-dasharray": e.containerSize.width, "stroke-dashoffset": e.containerSize.width, "stroke-width": a.strokeWidth, "data-j-alluvial-path": "", "data-id": a.id }, on: { click: function(u) {
2391
- return n.emit("link-click", { link: a.link, event: u });
2392
- }, mouseover: function(u) {
2393
- return n.handleLinkMouseover(a.link, u);
2442
+ }, attrs: { d: a.d, stroke: n.getLinkStroke(a.link), "stroke-dasharray": e.containerSize.width, "stroke-dashoffset": e.containerSize.width, "stroke-width": a.strokeWidth, "data-j-alluvial-path": "", "data-id": a.id }, on: { click: function(o) {
2443
+ return n.emit("link-click", { link: a.link, event: o });
2444
+ }, mouseover: function(o) {
2445
+ return n.handleLinkMouseover(a.link, o);
2394
2446
  } } });
2395
- })], 2), e._l(n.nodeBlocks, function(a, u) {
2396
- return r("g", { key: `node-block_${u}`, staticClass: "lume-alluvial-group__node", class: {
2447
+ })], 2), e._l(n.nodeBlocks, function(a, o) {
2448
+ return r("g", { key: `node-block_${o}`, staticClass: "lume-alluvial-group__node", class: {
2397
2449
  "lume-alluvial-group__node--expandable": n.isExpandableNode(
2398
2450
  a.node.id
2399
2451
  ),
2452
+ "lume-alluvial-group__node--expandable-block": n.isExpandableNode(a.node.id) && n.isBlockExpansionTrigger,
2400
2453
  "lume-alluvial-group__node--faded": n.isNodeFaded(a.node.id),
2401
2454
  "lume-alluvial-group__node--focused": n.isNodeFocused(a.node.id)
2402
- }, attrs: { "data-j-alluvial-group__node-block": "" } }, [r("g", { attrs: { tabindex: n.isExpandableNode(a.node.id) ? "0" : null }, on: { click: function(o) {
2403
- return n.handleNodeClick(a.node, o);
2404
- }, keydown: [function(o) {
2405
- return !o.type.indexOf("key") && e._k(o.keyCode, "enter", 13, o.key, "Enter") ? null : (o.preventDefault(), n.handleNodeClick(a.node, o));
2406
- }, function(o) {
2407
- return !o.type.indexOf("key") && e._k(o.keyCode, "space", 32, o.key, [" ", "Spacebar"]) ? null : (o.preventDefault(), n.handleNodeClick(a.node, o));
2408
- }], mouseenter: function(o) {
2409
- return n.emit("node-mouseenter", { node: a.node, event: o });
2410
- }, mouseleave: function(o) {
2411
- return n.emit("node-mouseleave", { node: a.node, event: o });
2412
- }, mouseover: function(o) {
2455
+ }, attrs: { "data-j-alluvial-group__node-block": "" } }, [r("g", { attrs: { tabindex: n.isExpandableNode(a.node.id) ? "0" : null }, on: { click: function(l) {
2456
+ return n.handleNodeClick(a.node, l);
2457
+ }, keydown: [function(l) {
2458
+ return !l.type.indexOf("key") && e._k(l.keyCode, "enter", 13, l.key, "Enter") ? null : (l.preventDefault(), n.handleNodeKeydown(a.node, l));
2459
+ }, function(l) {
2460
+ return !l.type.indexOf("key") && e._k(l.keyCode, "space", 32, l.key, [" ", "Spacebar"]) ? null : (l.preventDefault(), n.handleNodeKeydown(a.node, l));
2461
+ }], mouseenter: function(l) {
2462
+ return n.emit("node-mouseenter", { node: a.node, event: l });
2463
+ }, mouseleave: function(l) {
2464
+ return n.emit("node-mouseleave", { node: a.node, event: l });
2465
+ }, mouseover: function(l) {
2413
2466
  n.pointedNode = a.node;
2414
- }, mouseout: function(o) {
2467
+ }, mouseout: function(l) {
2415
2468
  n.pointedNode = null;
2416
- }, focus: function(o) {
2469
+ }, focus: function(l) {
2417
2470
  n.focusedNode = a.node;
2418
- }, blur: function(o) {
2471
+ }, blur: function(l) {
2419
2472
  n.focusedNode = null;
2420
2473
  } } }, [n.shouldDeriveNodeColorFromIncomingLinks(a) ? e._l(n.getSubNodesDerivingColorFromIncomingLinks(
2421
2474
  a.node.id
2422
- ), function(o) {
2423
- return r("rect", e._b({ key: o.key, attrs: { "data-j-alluvial-sub-nodes": "" } }, "rect", o, !1));
2424
- }) : r("rect", { staticClass: "lume-alluvial-group__node-block", class: `lume-fill--${a.node.color || a.node.fallbackColor}`, attrs: { x: a.x, y: a.y, height: a.height, width: a.width } }), n.isExpandableNode(a.node.id) ? r("rect", { staticClass: "lume-alluvial-group__node-outline", class: `lume-stroke--${a.node.color || a.node.fallbackColor}`, attrs: { x: a.x - n.NODE_OUTLINE_PADDING, y: a.y - n.NODE_OUTLINE_PADDING, height: a.height + n.NODE_OUTLINE_PADDING * 2, width: a.width + n.NODE_OUTLINE_PADDING * 2, rx: n.NODE_OUTLINE_RADIUS, "data-j-alluvial-node-outline": "" } }) : e._e(), r("g", { ref: "nodeTextRefs", refInFor: !0, staticClass: "lume-alluvial-group__node-text lume-typography--caption", class: {
2425
- "lume-alluvial-group__node-text--left": a.node.depth === 0
2475
+ ), function(l) {
2476
+ return r("rect", e._b({ key: l.key, attrs: { "data-j-alluvial-sub-nodes": "" }, on: { click: function(i) {
2477
+ return n.handleNodeBlockClick(a.node);
2478
+ } } }, "rect", l, !1));
2479
+ }) : r("rect", { staticClass: "lume-alluvial-group__node-block", class: `lume-fill--${a.node.color || a.node.fallbackColor}`, attrs: { x: a.x, y: a.y, height: a.height, width: a.width }, on: { click: function(l) {
2480
+ return n.handleNodeBlockClick(a.node);
2481
+ } } }), n.isExpandableNode(a.node.id) ? r("rect", { staticClass: "lume-alluvial-group__node-outline", class: `lume-stroke--${a.node.color || a.node.fallbackColor}`, attrs: { x: a.x - n.NODE_OUTLINE_PADDING, y: a.y - n.NODE_OUTLINE_PADDING, height: a.height + n.NODE_OUTLINE_PADDING * 2, width: a.width + n.NODE_OUTLINE_PADDING * 2, rx: n.NODE_OUTLINE_RADIUS, "data-j-alluvial-node-outline": "" }, on: { click: function(l) {
2482
+ return n.handleNodeBlockClick(a.node);
2483
+ } } }) : e._e(), r("g", { ref: "nodeTextRefs", refInFor: !0, staticClass: "lume-alluvial-group__node-text lume-typography--caption", class: {
2484
+ "lume-alluvial-group__node-text--left": n.isLabelBeforeNode(
2485
+ a.node
2486
+ )
2426
2487
  }, attrs: { transform: `translate(${a.textTransform.x},${a.textTransform.y})`, "data-id": a.node.id, width: n.options.nodeLabelMaxWidth } }, [e._t(`node-text-${a.node.id}`, function() {
2427
- return [r(n.LumeAlluvialNodeLabel, { attrs: { bottom: n.options.switchText, left: a.node.depth === 0, "max-width": n.options.nodeLabelMaxWidth }, on: { "lume__internal--node-resize": n.updateMargins } }, [e._v(" " + e._s(a.node.label) + " ")]), r(n.LumeAlluvialNodeValue, { attrs: { bottom: !n.options.switchText } }, [e._v(" " + e._s(n.formatValue(a.node.transitionValue || a.node.value, a.node.value)) + " ")])];
2488
+ return [r(n.LumeAlluvialNodeLabel, { attrs: { bottom: n.options.switchText, left: n.isLabelBeforeNode(a.node), "max-width": n.options.nodeLabelMaxWidth }, on: { "lume__internal--node-resize": n.updateMargins } }, [e._v(" " + e._s(a.node.label) + " ")]), r(n.LumeAlluvialNodeValue, { attrs: { bottom: !n.options.switchText } }, [e._v(" " + e._s(n.formatValue(a.node.transitionValue || a.node.value, a.node.value)) + " ")])];
2428
2489
  }, { node: a.node, value: n.formatValue(
2429
2490
  a.node.transitionValue || a.node.value,
2430
2491
  a.node.value
2431
2492
  ) })], 2)], 2)]);
2432
2493
  })], 2);
2433
- }, Ja = [], Qa = /* @__PURE__ */ D(
2434
- Ya,
2435
- Ka,
2436
- Ja,
2494
+ }, to = [], no = /* @__PURE__ */ S(
2495
+ qa,
2496
+ eo,
2497
+ to,
2437
2498
  !1,
2438
2499
  null,
2439
- "a9818a4f"
2500
+ "0f56c6f5"
2440
2501
  );
2441
- const qa = Qa.exports, eo = {
2502
+ const ro = no.exports, ao = {
2442
2503
  margins: {
2443
2504
  top: 0,
2444
2505
  right: 0,
@@ -2450,340 +2511,343 @@ const qa = Qa.exports, eo = {
2450
2511
  withHover: !1,
2451
2512
  withLegend: !1,
2452
2513
  // Alluvial options
2514
+ alignFirstNodeLabels: "left",
2515
+ alignLastNodeLabels: "right",
2453
2516
  gradient: !1,
2454
2517
  highlightedElements: "closest",
2455
2518
  nodePadding: 16,
2456
2519
  nodeWidth: 16,
2457
- nodeAlign: Yt,
2520
+ nodeAlign: qt,
2521
+ nodeExpansionTrigger: "node",
2458
2522
  valueFormat: (t) => String(t),
2459
2523
  iterations: 6
2460
- }, to = /* @__PURE__ */ R({
2524
+ }, oo = /* @__PURE__ */ R({
2461
2525
  __name: "lume-alluvial-diagram",
2462
2526
  props: {
2463
- ...tr(Ze)
2527
+ ...or(Ke)
2464
2528
  },
2465
2529
  setup(t, { emit: e }) {
2466
- const r = t, { componentEventPropagator: n } = q(e), a = ce(X()), u = gn(X()), { options: o } = F(r), { allOptions: i } = Q(o, eo);
2467
- function l(c) {
2530
+ const r = t, { componentEventPropagator: n } = q(e), a = se(X()), o = xn(X()), { options: l } = V(r), { allOptions: i } = Q(l, ao);
2531
+ function u(c) {
2468
2532
  return {
2469
2533
  ...c,
2470
2534
  noBaseScales: !0
2471
2535
  // Alluvial chart never uses base scales
2472
2536
  };
2473
2537
  }
2474
- return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, groupSlots: u, options: o, allOptions: i, getAlluvialDiagramOptions: l, LumeChart: _e, LumeAlluvialGroup: qa };
2538
+ return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, groupSlots: o, options: l, allOptions: i, getAlluvialDiagramOptions: u, LumeChart: fe, LumeAlluvialGroup: ro };
2475
2539
  }
2476
2540
  });
2477
- var no = function() {
2541
+ var lo = function() {
2478
2542
  var e = this, r = e._self._c, n = e._self._setupProxy;
2479
2543
  return r(n.LumeChart, e._g(e._b({ attrs: { options: n.getAlluvialDiagramOptions(n.allOptions), "data-j-alluvial-diagram": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2480
- return [r(n.LumeAlluvialGroup, e._g(e._b({ attrs: { "hovered-element-id": e.hoveredElement }, scopedSlots: e._u([e._l(n.groupSlots, function(u, o) {
2481
- return { key: o, fn: function(i) {
2482
- return [e._t(o, null, null, i || {})];
2544
+ return [r(n.LumeAlluvialGroup, e._g(e._b({ attrs: { "hovered-element-id": e.hoveredElement }, scopedSlots: e._u([e._l(n.groupSlots, function(o, l) {
2545
+ return { key: l, fn: function(i) {
2546
+ return [e._t(l, null, null, i || {})];
2483
2547
  } };
2484
2548
  })], null, !0) }, "lume-alluvial-group", a, !1), n.componentEventPropagator))];
2485
- } }, e._l(n.slots, function(a, u) {
2486
- return { key: u, fn: function(o) {
2487
- return [e._t(u, null, null, o || {})];
2549
+ } }, e._l(n.slots, function(a, o) {
2550
+ return { key: o, fn: function(l) {
2551
+ return [e._t(o, null, null, l || {})];
2488
2552
  } };
2489
2553
  })], null, !0) }, "lume-chart", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
2490
- }, ro = [], ao = /* @__PURE__ */ D(
2491
- to,
2492
- no,
2493
- ro,
2554
+ }, uo = [], io = /* @__PURE__ */ S(
2555
+ oo,
2556
+ lo,
2557
+ uo,
2494
2558
  !1,
2495
2559
  null,
2496
2560
  null
2497
2561
  );
2498
- const gu = ao.exports;
2499
- var Ue = /* @__PURE__ */ ((t) => (t.grouped = "grouped", t.stacked = "stacked", t))(Ue || {});
2500
- const oo = /* @__PURE__ */ R({
2562
+ const xl = io.exports;
2563
+ var Ye = /* @__PURE__ */ ((t) => (t.grouped = "grouped", t.stacked = "stacked", t))(Ye || {});
2564
+ const so = /* @__PURE__ */ R({
2501
2565
  __name: "lume-bar-chart",
2502
2566
  props: {
2503
- ...me(),
2567
+ ...ve(),
2504
2568
  type: {
2505
2569
  type: String,
2506
2570
  default: null,
2507
- validator: (t) => t in Ue || t == null
2571
+ validator: (t) => t in Ye || t == null
2508
2572
  }
2509
2573
  },
2510
2574
  setup(t, { emit: e }) {
2511
- const r = t, n = He(
2512
- () => import("./Aka2OjK8.js")
2513
- ), a = He(
2514
- () => import("./BkCJnqDA.js")
2515
- ), u = He(
2516
- () => import("./BAc0dIxQ.js")
2517
- ), o = /* @__PURE__ */ new Map([
2575
+ const r = t, n = Re(
2576
+ () => import("./asrcm8__.js")
2577
+ ), a = Re(
2578
+ () => import("./BSSy21i7.js")
2579
+ ), o = Re(
2580
+ () => import("./es6xM4zX.js")
2581
+ ), l = /* @__PURE__ */ new Map([
2518
2582
  ["single", n],
2519
2583
  ["grouped", a],
2520
- ["stacked", u]
2521
- ]), { componentEventPropagator: i } = q(e), l = ce(X());
2522
- function c(v) {
2584
+ ["stacked", o]
2585
+ ]), { componentEventPropagator: i } = q(e), u = se(X());
2586
+ function c(f) {
2523
2587
  return {
2524
- ...v,
2588
+ ...f,
2525
2589
  startOnZero: !0,
2526
2590
  // Bar chart always starts on zero,
2527
2591
  tooltipOptions: {
2528
- ...(v == null ? void 0 : v.tooltipOptions) || {},
2592
+ ...(f == null ? void 0 : f.tooltipOptions) || {},
2529
2593
  position: r.orientation === O.HORIZONTAL ? "right" : void 0
2530
2594
  }
2531
2595
  };
2532
2596
  }
2533
- const s = f(() => {
2534
- if (Ze(r.data)) return o.get("single");
2597
+ const s = v(() => {
2598
+ if (Ke(r.data)) return l.get("single");
2535
2599
  if (!r.type)
2536
2600
  throw new Error("Bar chart needs a type when there's multiple datasets.");
2537
- return o.get(r.type);
2601
+ return l.get(r.type);
2538
2602
  });
2539
- return { __sfc: !0, TYPES: Ue, LumeSingleBarChart: n, LumeGroupedBarChart: a, LumeStackedBarChart: u, COMPONENT_MAP: o, props: r, emit: e, componentEventPropagator: i, slots: l, getBarChartOptions: c, component: s };
2603
+ return { __sfc: !0, TYPES: Ye, LumeSingleBarChart: n, LumeGroupedBarChart: a, LumeStackedBarChart: o, COMPONENT_MAP: l, props: r, emit: e, componentEventPropagator: i, slots: u, getBarChartOptions: c, component: s };
2540
2604
  }
2541
2605
  });
2542
- var uo = function() {
2606
+ var co = function() {
2543
2607
  var e = this, r = e._self._c, n = e._self._setupProxy;
2544
- return r(n.component, e._g(e._b({ tag: "component", attrs: { options: n.getBarChartOptions(e.options) }, scopedSlots: e._u([e._l(n.slots, function(a, u) {
2545
- return { key: u, fn: function(o) {
2546
- return [e._t(u, null, null, o || {})];
2608
+ return r(n.component, e._g(e._b({ tag: "component", attrs: { options: n.getBarChartOptions(e.options) }, scopedSlots: e._u([e._l(n.slots, function(a, o) {
2609
+ return { key: o, fn: function(l) {
2610
+ return [e._t(o, null, null, l || {})];
2547
2611
  } };
2548
2612
  })], null, !0) }, "component", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
2549
- }, lo = [], io = /* @__PURE__ */ D(
2550
- oo,
2551
- uo,
2552
- lo,
2613
+ }, vo = [], fo = /* @__PURE__ */ S(
2614
+ so,
2615
+ co,
2616
+ vo,
2553
2617
  !1,
2554
2618
  null,
2555
2619
  null
2556
2620
  );
2557
- const yu = io.exports;
2558
- function so(t) {
2559
- return Object.values(xn).includes(t) || t == null;
2621
+ const Ll = fo.exports;
2622
+ function po(t) {
2623
+ return Object.values(On).includes(t) || t == null;
2560
2624
  }
2561
- function co(t) {
2625
+ function mo(t) {
2562
2626
  return Object.values(O).includes(t);
2563
2627
  }
2564
- const vo = (t = !1) => ({
2628
+ const _o = (t = !1) => ({
2565
2629
  type: {
2566
2630
  type: String,
2567
2631
  default: null,
2568
- validator: so
2632
+ validator: po
2569
2633
  },
2570
2634
  ...t ? {
2571
2635
  orientation: {
2572
2636
  type: String,
2573
2637
  default: O.VERTICAL,
2574
- validator: co
2638
+ validator: mo
2575
2639
  }
2576
2640
  } : {}
2577
2641
  });
2578
- function Ft(t, e) {
2579
- const r = f(() => t.value.map((a) => {
2580
- var u;
2642
+ function Zt(t, e) {
2643
+ const r = v(() => t.value.map((a) => {
2644
+ var o;
2581
2645
  return {
2582
2646
  ...a,
2583
- values: Xe(
2647
+ values: Je(
2584
2648
  a.values,
2585
- ((u = e == null ? void 0 : e.value) == null ? void 0 : u.length) ?? 0
2586
- ).map((o) => ({
2587
- ...o,
2588
- value: (o == null ? void 0 : o.value) || 0
2649
+ ((o = e == null ? void 0 : e.value) == null ? void 0 : o.length) ?? 0
2650
+ ).map((l) => ({
2651
+ ...l,
2652
+ value: (l == null ? void 0 : l.value) || 0
2589
2653
  }))
2590
2654
  };
2591
- })), n = f(() => {
2655
+ })), n = v(() => {
2592
2656
  var a;
2593
- return (a = r.value) == null ? void 0 : a.reduce((u, o) => (o.values.forEach((i, l) => {
2594
- u[l] ? u[l].push(i) : u[l] = [i];
2595
- }), u), []);
2657
+ return (a = r.value) == null ? void 0 : a.reduce((o, l) => (l.values.forEach((i, u) => {
2658
+ o[u] ? o[u].push(i) : o[u] = [i];
2659
+ }), o), []);
2596
2660
  });
2597
2661
  return { multiBarData: r, groupedData: n };
2598
2662
  }
2599
- function fo(t, e) {
2663
+ function go(t, e) {
2600
2664
  return t.value.length === 1 ? "single" : e.value;
2601
2665
  }
2602
- function po(t, e, r) {
2603
- const n = f(
2666
+ function ho(t, e, r) {
2667
+ const n = v(
2604
2668
  () => r.value === O.HORIZONTAL
2605
2669
  );
2606
2670
  function a(i) {
2607
- i || Me(Ie.BarScaleNull), Math.min(...i.domain()) > 0 && Me(Ie.BarScaleDomainAbove0);
2671
+ i || Ue(Ae.BarScaleNull), Math.min(...i.domain()) > 0 && Ue(Ae.BarScaleDomainAbove0);
2608
2672
  }
2609
- const u = f(() => n.value ? (a(t.value), t.value) : t.value), o = f(() => n.value ? e.value : (a(e.value), e.value));
2610
- return { barXScale: u, barYScale: o };
2673
+ const o = v(() => n.value ? (a(t.value), t.value) : t.value), l = v(() => n.value ? e.value : (a(e.value), e.value));
2674
+ return { barXScale: o, barYScale: l };
2611
2675
  }
2612
- const mo = {
2676
+ const yo = {
2613
2677
  x: 0,
2614
2678
  y: 0,
2615
2679
  width: 0,
2616
2680
  height: 0
2617
2681
  };
2618
- function _o(t, e, r, n, a, u) {
2619
- const o = f(
2682
+ function bo(t, e, r, n, a, o) {
2683
+ const l = v(
2620
2684
  () => n.value === O.HORIZONTAL
2621
2685
  );
2622
- function i(v, m) {
2623
- let g, h;
2624
- return o.value ? (g = v >= 0 ? e.value(0) : e.value(v), h = r.value(r.value.domain()[m])) : (g = e.value(e.value.domain()[m]), h = v < 0 ? r.value(0) : r.value(v)), { x: g, y: h };
2686
+ function i(f, m) {
2687
+ let h, g;
2688
+ return l.value ? (h = f >= 0 ? e.value(0) : e.value(f), g = r.value(r.value.domain()[m])) : (h = e.value(e.value.domain()[m]), g = f < 0 ? r.value(0) : r.value(f)), { x: h, y: g };
2625
2689
  }
2626
- function l(v) {
2627
- return o.value ? v < 0 ? e.value(0) - e.value(v) : e.value(v) - e.value(0) : e.value.bandwidth();
2690
+ function u(f) {
2691
+ return l.value ? f < 0 ? e.value(0) - e.value(f) : e.value(f) - e.value(0) : e.value.bandwidth();
2628
2692
  }
2629
- function c(v) {
2630
- return o.value ? r.value.bandwidth() : v < 0 ? r.value(v) - r.value(0) : r.value(0) - r.value(v);
2693
+ function c(f) {
2694
+ return l.value ? r.value.bandwidth() : f < 0 ? r.value(f) - r.value(0) : r.value(0) - r.value(f);
2631
2695
  }
2632
- function s(v, m, g) {
2633
- if (!(e.value && r.value)) return mo;
2634
- const { value: _, color: x } = v, d = x ?? t.value[m].color ?? xe, { x: p, y } = i(_, g), b = l(_), A = c(_);
2696
+ function s(f, m, h) {
2697
+ if (!(e.value && r.value)) return yo;
2698
+ const { value: _, color: x } = f, d = x ?? t.value[m].color ?? ke, { x: p, y } = i(_, h), k = u(_), T = c(_);
2635
2699
  return {
2636
- classList: [`lume-fill--${d}`, ...u],
2700
+ classList: [`lume-fill--${d}`, ...o],
2637
2701
  x: p,
2638
2702
  y,
2639
- width: b,
2640
- height: A,
2641
- isFaded: a.value !== -1 && a.value !== g,
2703
+ width: k,
2704
+ height: T,
2705
+ isFaded: a.value !== -1 && a.value !== h,
2642
2706
  isNegative: _ < 0
2643
2707
  };
2644
2708
  }
2645
2709
  return { barAttributeGenerator: s };
2646
2710
  }
2647
- const ho = {
2711
+ const ko = {
2648
2712
  x: 0,
2649
2713
  y: 0,
2650
2714
  width: 0,
2651
2715
  height: 0
2652
2716
  };
2653
- function go(t, e, r, n, a, u) {
2654
- const o = f(
2717
+ function xo(t, e, r, n, a, o) {
2718
+ const l = v(
2655
2719
  () => n.value === O.HORIZONTAL
2656
- ), i = f(() => ye().domain(t.value.map((h, _) => _)).range([0, e.value.bandwidth()]).padding(0)), l = f(() => ye().domain(t.value.map((h, _) => _)).range([0, r.value.bandwidth()]).padding(0));
2657
- function c(h, _, x) {
2658
- if (o.value)
2659
- return h >= 0 ? e.value(0) : e.value(h);
2720
+ ), i = v(() => he().domain(t.value.map((g, _) => _)).range([0, e.value.bandwidth()]).padding(0)), u = v(() => he().domain(t.value.map((g, _) => _)).range([0, r.value.bandwidth()]).padding(0));
2721
+ function c(g, _, x) {
2722
+ if (l.value)
2723
+ return g >= 0 ? e.value(0) : e.value(g);
2660
2724
  const d = e.value.domain();
2661
2725
  return e.value(d[_]) + i.value(x);
2662
2726
  }
2663
- function s(h, _, x) {
2664
- if (o.value) {
2727
+ function s(g, _, x) {
2728
+ if (l.value) {
2665
2729
  const d = r.value.domain();
2666
- return r.value(d[_]) + l.value(x);
2730
+ return r.value(d[_]) + u.value(x);
2667
2731
  }
2668
- return h < 0 ? r.value(0) : r.value(h);
2732
+ return g < 0 ? r.value(0) : r.value(g);
2669
2733
  }
2670
- function v(h) {
2671
- return o.value ? h < 0 ? e.value(0) - e.value(h) : e.value(h) - e.value(0) : i.value.bandwidth();
2734
+ function f(g) {
2735
+ return l.value ? g < 0 ? e.value(0) - e.value(g) : e.value(g) - e.value(0) : i.value.bandwidth();
2672
2736
  }
2673
- function m(h) {
2674
- return o.value ? l.value.bandwidth() : h < 0 ? r.value(h) - r.value(0) : r.value(0) - r.value(h);
2737
+ function m(g) {
2738
+ return l.value ? u.value.bandwidth() : g < 0 ? r.value(g) - r.value(0) : r.value(0) - r.value(g);
2675
2739
  }
2676
- function g(h, _, x) {
2677
- if (!(e.value && r.value)) return ho;
2678
- const { value: p, color: y } = h, b = y ?? t.value[_].color ?? Object.values(Y)[_], A = c(p, x, _), $ = s(p, x, _), T = v(p), N = m(p);
2740
+ function h(g, _, x) {
2741
+ if (!(e.value && r.value)) return ko;
2742
+ const { value: p, color: y } = g, k = y ?? t.value[_].color ?? Object.values(Y)[_], T = c(p, x, _), N = s(p, x, _), A = f(p), D = m(p);
2679
2743
  return {
2680
- classList: [`lume-fill--${b}`, ...u],
2681
- x: A,
2682
- y: $,
2683
- width: T,
2684
- height: N,
2744
+ classList: [`lume-fill--${k}`, ...o],
2745
+ x: T,
2746
+ y: N,
2747
+ width: A,
2748
+ height: D,
2685
2749
  isFaded: a.value !== -1 && a.value !== x,
2686
2750
  isNegative: p < 0
2687
2751
  };
2688
2752
  }
2689
- return { barAttributeGenerator: g };
2753
+ return { barAttributeGenerator: h };
2690
2754
  }
2691
- function yo(t, e, r) {
2692
- const n = f(
2755
+ function Lo(t, e, r) {
2756
+ const n = v(
2693
2757
  () => e.value === O.HORIZONTAL
2694
- ), a = f(() => {
2695
- const l = t.value.map(
2696
- (c) => c.filter((s) => s.value < 0).reduce((s, v) => s + v.value, 0)
2758
+ ), a = v(() => {
2759
+ const u = t.value.map(
2760
+ (c) => c.filter((s) => s.value < 0).reduce((s, f) => s + f.value, 0)
2697
2761
  );
2698
- return Math.min(...l);
2699
- }), u = f(() => {
2700
- const l = t.value.map(
2762
+ return Math.min(...u);
2763
+ }), o = v(() => {
2764
+ const u = t.value.map(
2701
2765
  (c) => c.reduce(
2702
- (s, v) => v.value >= 0 ? s + v.value : s,
2766
+ (s, f) => f.value >= 0 ? s + f.value : s,
2703
2767
  0
2704
2768
  )
2705
2769
  );
2706
- return Math.max(...l);
2770
+ return Math.max(...u);
2707
2771
  });
2708
- function o(l, c, s) {
2709
- return c.length ? n.value ? ge().domain([a.value, u.value]).range([0, s.width]) : Object.assign(
2710
- dt(
2711
- ye().domain(c.map((v, m) => m)).range([0, s.width]),
2772
+ function l(u, c, s) {
2773
+ return c.length ? n.value ? ge().domain([a.value, o.value]).range([0, s.width]) : Object.assign(
2774
+ mt(
2775
+ he().domain(c.map((f, m) => m)).range([0, s.width]),
2712
2776
  e.value,
2713
2777
  r.value
2714
2778
  ),
2715
2779
  { labels: c }
2716
2780
  ) : null;
2717
2781
  }
2718
- function i(l, c, s) {
2782
+ function i(u, c, s) {
2719
2783
  return c.length ? n.value ? Object.assign(
2720
- dt(
2721
- ye().domain(c.map((v, m) => m)).range([0, s.height]),
2784
+ mt(
2785
+ he().domain(c.map((f, m) => m)).range([0, s.height]),
2722
2786
  e.value,
2723
2787
  r.value
2724
2788
  ),
2725
2789
  { labels: c }
2726
- ) : ge().domain([u.value, a.value]).range([0, s.height]) : null;
2790
+ ) : ge().domain([o.value, a.value]).range([0, s.height]) : null;
2727
2791
  }
2728
- return { stackedXScaleGenerator: o, stackedYScaleGenerator: i };
2792
+ return { stackedXScaleGenerator: l, stackedYScaleGenerator: i };
2729
2793
  }
2730
- function bo(t, e, r, n, a, u) {
2731
- const o = f(
2794
+ function To(t, e, r, n, a, o) {
2795
+ const l = v(
2732
2796
  () => n.value === O.HORIZONTAL
2733
- ), i = f(
2734
- () => o.value ? r.value.domain() : e.value.domain()
2735
- ), l = f(
2797
+ ), i = v(
2798
+ () => l.value ? r.value.domain() : e.value.domain()
2799
+ ), u = v(
2736
2800
  () => t.value.map((d) => d.values.map((p) => p == null ? void 0 : p.value))
2737
2801
  );
2738
2802
  function c(d, p, y) {
2739
- let b, A;
2740
- return o.value ? (b = e.value(d >= 0 ? 0 + y : d + y), A = r.value(i.value[p])) : (b = e.value(i.value[p]), A = r.value(d >= 0 ? d + y : 0 + y)), { x: b, y: A };
2803
+ let k, T;
2804
+ return l.value ? (k = e.value(d >= 0 ? 0 + y : d + y), T = r.value(i.value[p])) : (k = e.value(i.value[p]), T = r.value(d >= 0 ? d + y : 0 + y)), { x: k, y: T };
2741
2805
  }
2742
2806
  function s(d) {
2743
- return o.value ? e.value(d) - e.value(0) : e.value.bandwidth();
2807
+ return l.value ? e.value(d) - e.value(0) : e.value.bandwidth();
2744
2808
  }
2745
- function v(d) {
2746
- return o.value ? e.value(0) - e.value(d) : e.value.bandwidth();
2809
+ function f(d) {
2810
+ return l.value ? e.value(0) - e.value(d) : e.value.bandwidth();
2747
2811
  }
2748
2812
  function m(d) {
2749
- return o.value ? r.value.bandwidth() : r.value(0) - r.value(d);
2813
+ return l.value ? r.value.bandwidth() : r.value(0) - r.value(d);
2750
2814
  }
2751
- function g(d) {
2752
- return o.value ? r.value.bandwidth() : r.value(d) - r.value(0);
2815
+ function h(d) {
2816
+ return l.value ? r.value.bandwidth() : r.value(d) - r.value(0);
2753
2817
  }
2754
- function h(d, p) {
2755
- return d ? l.value.reduce((y, b, A) => (A < d && b[p] >= 0 && (y += b[p]), y), 0) : 0;
2818
+ function g(d, p) {
2819
+ return d ? u.value.reduce((y, k, T) => (T < d && k[p] >= 0 && (y += k[p]), y), 0) : 0;
2756
2820
  }
2757
2821
  function _(d, p) {
2758
- return d ? l.value.reduce((y, b, A) => (A < d && b[p] < 0 && (y += b[p]), y), 0) : 0;
2822
+ return d ? u.value.reduce((y, k, T) => (T < d && k[p] < 0 && (y += k[p]), y), 0) : 0;
2759
2823
  }
2760
2824
  function x(d, p, y) {
2761
- const { value: b, color: A } = d, $ = b >= 0 ? s(b) : v(b), T = b >= 0 ? m(b) : g(b), N = b >= 0 ? h(p, y) : _(p, y), { x: S, y: j } = c(b, y, N);
2825
+ const { value: k, color: T } = d, N = k >= 0 ? s(k) : f(k), A = k >= 0 ? m(k) : h(k), D = k >= 0 ? g(p, y) : _(p, y), { x: C, y: M } = c(k, y, D);
2762
2826
  return {
2763
- classList: [`lume-fill--${A ?? t.value[p].color ?? Object.values(Y)[p]}`, ...u],
2764
- width: $,
2765
- height: T,
2766
- x: S,
2767
- y: j,
2827
+ classList: [`lume-fill--${T ?? t.value[p].color ?? Object.values(Y)[p]}`, ...o],
2828
+ width: N,
2829
+ height: A,
2830
+ x: C,
2831
+ y: M,
2768
2832
  isFaded: a.value !== -1 && a.value !== y,
2769
- isNegative: b < 0
2833
+ isNegative: k < 0
2770
2834
  };
2771
2835
  }
2772
2836
  return { barAttributeGenerator: x };
2773
2837
  }
2774
- const yt = {
2775
- single: _o,
2776
- grouped: go,
2777
- stacked: bo
2778
- }, ko = /* @__PURE__ */ R({
2838
+ const Lt = {
2839
+ single: bo,
2840
+ grouped: xo,
2841
+ stacked: To
2842
+ }, Ao = /* @__PURE__ */ R({
2779
2843
  __name: "lume-bar-group",
2780
2844
  props: {
2781
- ...we(),
2845
+ ...Ee(),
2782
2846
  classList: {
2783
2847
  type: [String, Array],
2784
2848
  default: () => []
2785
2849
  },
2786
- ...vo(!0),
2850
+ ..._o(!0),
2787
2851
  transition: {
2788
2852
  type: Boolean,
2789
2853
  default: !0
@@ -2794,199 +2858,199 @@ const yt = {
2794
2858
  const r = t, {
2795
2859
  data: n,
2796
2860
  hoveredIndex: a,
2797
- orientation: u,
2798
- transition: o,
2861
+ orientation: o,
2862
+ transition: l,
2799
2863
  type: i,
2800
- xScale: l,
2864
+ xScale: u,
2801
2865
  yScale: c,
2802
2866
  classList: s,
2803
- labels: v
2804
- } = F(r), m = Ee("chartID"), { emitInternalEvent: g } = q(e, m), { groupedData: h } = Ft(n, v), { barXScale: _, barYScale: x } = po(l, c, u), d = f(() => typeof s.value == "string" ? [s.value] : s.value), p = f(() => {
2805
- const A = fo(n, i), { barAttributeGenerator: $ } = yt[A](
2867
+ labels: f
2868
+ } = V(r), m = Oe("chartID"), { emitInternalEvent: h } = q(e, m), { groupedData: g } = Zt(n, f), { barXScale: _, barYScale: x } = ho(u, c, o), d = v(() => typeof s.value == "string" ? [s.value] : s.value), p = v(() => {
2869
+ const T = go(n, i), { barAttributeGenerator: N } = Lt[T](
2806
2870
  n,
2807
2871
  _,
2808
2872
  x,
2809
- u,
2873
+ o,
2810
2874
  a,
2811
2875
  d.value
2812
2876
  );
2813
- return $;
2814
- }), y = f(() => {
2815
- if (o.value)
2816
- return u.value === O.HORIZONTAL ? "width" : "height";
2877
+ return N;
2878
+ }), y = v(() => {
2879
+ if (l.value)
2880
+ return o.value === O.HORIZONTAL ? "width" : "height";
2817
2881
  });
2818
- async function b(A) {
2819
- e("lume__internal--hover", A), g("lume__internal--hover", A);
2882
+ async function k(T) {
2883
+ e("lume__internal--hover", T), h("lume__internal--hover", T);
2820
2884
  }
2821
- return { __sfc: !0, MIXIN_MAP: yt, props: r, emit: e, data: n, hoveredIndex: a, orientation: u, transition: o, type: i, xScale: l, yScale: c, classList: s, labels: v, chartID: m, emitInternalEvent: g, groupedData: h, barXScale: _, barYScale: x, computedClasses: d, getBarAttributes: p, computedTransition: y, handleInternalHover: b, LumeBar: Ye };
2885
+ return { __sfc: !0, MIXIN_MAP: Lt, props: r, emit: e, data: n, hoveredIndex: a, orientation: o, transition: l, type: i, xScale: u, yScale: c, classList: s, labels: f, chartID: m, emitInternalEvent: h, groupedData: g, barXScale: _, barYScale: x, computedClasses: d, getBarAttributes: p, computedTransition: y, handleInternalHover: k, LumeBar: Qe };
2822
2886
  }
2823
2887
  });
2824
- var xo = function() {
2888
+ var Oo = function() {
2825
2889
  var e = this, r = e._self._c, n = e._self._setupProxy;
2826
- return r("g", { staticClass: "lume-bar-group", attrs: { "data-j-bars-group": "" } }, e._l(n.groupedData, function(a, u) {
2827
- return r("g", { key: u, on: { mouseenter: function(o) {
2828
- return n.handleInternalHover(u);
2829
- } } }, e._l(a, function(o, i) {
2830
- return r(n.LumeBar, e._b({ key: `bar-${i}`, attrs: { transition: n.computedTransition, "data-j-lume-bar": "" }, on: { click: function(l) {
2890
+ return r("g", { staticClass: "lume-bar-group", attrs: { "data-j-bars-group": "" } }, e._l(n.groupedData, function(a, o) {
2891
+ return r("g", { key: o, on: { mouseenter: function(l) {
2892
+ return n.handleInternalHover(o);
2893
+ } } }, e._l(a, function(l, i) {
2894
+ return r(n.LumeBar, e._b({ key: `bar-${i}`, attrs: { transition: n.computedTransition, "data-j-lume-bar": "" }, on: { click: function(u) {
2831
2895
  return n.emit("bar-click", {
2832
- index: u,
2896
+ index: o,
2833
2897
  datasetIndex: i,
2834
- event: l
2898
+ event: u
2835
2899
  });
2836
- } } }, "lume-bar", n.getBarAttributes(o, i, u, a), !1));
2900
+ } } }, "lume-bar", n.getBarAttributes(l, i, o, a), !1));
2837
2901
  }), 1);
2838
2902
  }), 0);
2839
- }, Ao = [], Lo = /* @__PURE__ */ D(
2840
- ko,
2841
- xo,
2903
+ }, Io = [], No = /* @__PURE__ */ S(
2842
2904
  Ao,
2905
+ Oo,
2906
+ Io,
2843
2907
  !1,
2844
2908
  null,
2845
2909
  null
2846
2910
  );
2847
- const rt = Lo.exports, To = {
2911
+ const ut = No.exports, Eo = {
2848
2912
  [O.VERTICAL]: {
2849
2913
  withTooltip: !0,
2850
2914
  xAxisOptions: {},
2851
2915
  yAxisOptions: { gridLines: !0 },
2852
- margins: se.VERTICAL
2916
+ margins: ie.VERTICAL
2853
2917
  },
2854
2918
  [O.HORIZONTAL]: {
2855
2919
  withTooltip: !0,
2856
2920
  xAxisOptions: { gridLines: !0 },
2857
2921
  yAxisOptions: { gridLines: !1 },
2858
- margins: se.HORIZONTAL
2922
+ margins: ie.HORIZONTAL
2859
2923
  }
2860
- }, Oo = /* @__PURE__ */ R({
2924
+ }, $o = /* @__PURE__ */ R({
2861
2925
  __name: "lume-single-bar-chart",
2862
2926
  props: {
2863
- ...me(Ze)
2927
+ ...ve(Ke)
2864
2928
  },
2865
2929
  setup(t, { emit: e }) {
2866
- const r = t, { componentEventPropagator: n } = q(e), a = ce(X()), { orientation: u, options: o } = F(r), i = f(
2867
- () => To[u.value || O.VERTICAL]
2930
+ const r = t, { componentEventPropagator: n } = q(e), a = se(X()), { orientation: o, options: l } = V(r), i = v(
2931
+ () => Eo[o.value || O.VERTICAL]
2868
2932
  // needs to be computed so that default options are reactive
2869
- ), { allOptions: l } = Q(o, i);
2870
- return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, orientation: u, options: o, baseOptions: i, allOptions: l, LumeChart: _e, LumeBarGroup: rt };
2933
+ ), { allOptions: u } = Q(l, i);
2934
+ return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, orientation: o, options: l, baseOptions: i, allOptions: u, LumeChart: fe, LumeBarGroup: ut };
2871
2935
  }
2872
2936
  });
2873
- var Io = function() {
2937
+ var wo = function() {
2874
2938
  var e = this, r = e._self._c, n = e._self._setupProxy;
2875
2939
  return r(n.LumeChart, e._g(e._b({ attrs: { "chart-type": "single-bar", options: n.allOptions, "data-j-single-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2876
2940
  return [r(n.LumeBarGroup, e._g(e._b({ attrs: { orientation: n.orientation } }, "lume-bar-group", a, !1), n.componentEventPropagator))];
2877
- } }, e._l(n.slots, function(a, u) {
2878
- return { key: u, fn: function(o) {
2879
- return [e._t(u, null, null, o || {})];
2941
+ } }, e._l(n.slots, function(a, o) {
2942
+ return { key: o, fn: function(l) {
2943
+ return [e._t(o, null, null, l || {})];
2880
2944
  } };
2881
2945
  })], null, !0) }, "lume-chart", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
2882
- }, Eo = [], $o = /* @__PURE__ */ D(
2883
- Oo,
2884
- Io,
2885
- Eo,
2946
+ }, Do = [], Ho = /* @__PURE__ */ S(
2947
+ $o,
2948
+ wo,
2949
+ Do,
2886
2950
  !1,
2887
2951
  null,
2888
2952
  null
2889
2953
  );
2890
- const bu = $o.exports, No = {
2954
+ const Tl = Ho.exports, So = {
2891
2955
  [O.VERTICAL]: {
2892
2956
  withTooltip: !0,
2893
2957
  xAxisOptions: {},
2894
2958
  yAxisOptions: { gridLines: !0 },
2895
- margins: se.VERTICAL
2959
+ margins: ie.VERTICAL
2896
2960
  },
2897
2961
  [O.HORIZONTAL]: {
2898
2962
  withTooltip: !0,
2899
2963
  xAxisOptions: { gridLines: !0 },
2900
2964
  yAxisOptions: { gridLines: !1 },
2901
- margins: se.HORIZONTAL,
2965
+ margins: ie.HORIZONTAL,
2902
2966
  tooltipOptions: { position: "right" }
2903
2967
  }
2904
- }, wo = /* @__PURE__ */ R({
2968
+ }, Po = /* @__PURE__ */ R({
2905
2969
  __name: "lume-grouped-bar-chart",
2906
2970
  props: {
2907
- ...me()
2971
+ ...ve()
2908
2972
  },
2909
2973
  setup(t, { emit: e }) {
2910
- const r = t, { componentEventPropagator: n } = q(e), a = ce(X()), { orientation: u, options: o } = F(r), i = f(
2911
- () => No[u.value || O.VERTICAL]
2974
+ const r = t, { componentEventPropagator: n } = q(e), a = se(X()), { orientation: o, options: l } = V(r), i = v(
2975
+ () => So[o.value || O.VERTICAL]
2912
2976
  // needs to be computed so that default options are reactive
2913
- ), { allOptions: l } = Q(
2914
- o,
2977
+ ), { allOptions: u } = Q(
2978
+ l,
2915
2979
  i
2916
2980
  );
2917
- return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, orientation: u, options: o, baseOptions: i, allOptions: l, LumeChart: _e, LumeBarGroup: rt };
2981
+ return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, orientation: o, options: l, baseOptions: i, allOptions: u, LumeChart: fe, LumeBarGroup: ut };
2918
2982
  }
2919
2983
  });
2920
- var Do = function() {
2984
+ var Ro = function() {
2921
2985
  var e = this, r = e._self._c, n = e._self._setupProxy;
2922
2986
  return r(n.LumeChart, e._g(e._b({ attrs: { "chart-type": "grouped-bar", options: n.allOptions, "data-j-grouped-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2923
2987
  return [r(n.LumeBarGroup, e._g(e._b({ attrs: { type: "grouped" } }, "lume-bar-group", a, !1), n.componentEventPropagator))];
2924
- } }, e._l(n.slots, function(a, u) {
2925
- return { key: u, fn: function(o) {
2926
- return [e._t(u, null, null, o || {})];
2988
+ } }, e._l(n.slots, function(a, o) {
2989
+ return { key: o, fn: function(l) {
2990
+ return [e._t(o, null, null, l || {})];
2927
2991
  } };
2928
2992
  })], null, !0) }, "lume-chart", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
2929
- }, Ho = [], Po = /* @__PURE__ */ D(
2930
- wo,
2931
- Do,
2932
- Ho,
2993
+ }, Bo = [], Co = /* @__PURE__ */ S(
2994
+ Po,
2995
+ Ro,
2996
+ Bo,
2933
2997
  !1,
2934
2998
  null,
2935
2999
  null
2936
3000
  );
2937
- const ku = Po.exports, Ro = {
3001
+ const Al = Co.exports, Fo = {
2938
3002
  [O.VERTICAL]: {
2939
3003
  withTooltip: !0,
2940
3004
  xAxisOptions: {},
2941
3005
  yAxisOptions: { gridLines: !0 },
2942
- margins: se.VERTICAL,
3006
+ margins: ie.VERTICAL,
2943
3007
  tooltipOptions: { inverse: !0 }
2944
3008
  },
2945
3009
  [O.HORIZONTAL]: {
2946
3010
  withTooltip: !0,
2947
3011
  xAxisOptions: { gridLines: !0 },
2948
3012
  yAxisOptions: { gridLines: !1 },
2949
- margins: se.HORIZONTAL,
3013
+ margins: ie.HORIZONTAL,
2950
3014
  tooltipOptions: { position: "right" }
2951
3015
  }
2952
- }, So = /* @__PURE__ */ R({
3016
+ }, Go = /* @__PURE__ */ R({
2953
3017
  __name: "lume-stacked-bar-chart",
2954
3018
  props: {
2955
- ...me()
3019
+ ...ve()
2956
3020
  },
2957
3021
  setup(t, { emit: e }) {
2958
- const r = t, { componentEventPropagator: n } = q(e), a = ce(X()), { data: u, orientation: o, options: i, labels: l } = F(r), c = f(
2959
- () => Ro[o.value || O.VERTICAL]
3022
+ const r = t, { componentEventPropagator: n } = q(e), a = se(X()), { data: o, orientation: l, options: i, labels: u } = V(r), c = v(
3023
+ () => Fo[l.value || O.VERTICAL]
2960
3024
  // needs to be computed so that default options are reactive
2961
3025
  ), { allOptions: s } = Q(
2962
3026
  i,
2963
3027
  c
2964
- ), { internalData: v } = et(u), { groupedData: m } = Ft(v, l), { stackedXScaleGenerator: g, stackedYScaleGenerator: h } = yo(
3028
+ ), { internalData: f } = rt(o), { groupedData: m } = Zt(f, u), { stackedXScaleGenerator: h, stackedYScaleGenerator: g } = Lo(
2965
3029
  m,
2966
- o,
3030
+ l,
2967
3031
  i
2968
- ), _ = f(() => r.xScale || g), x = f(() => r.yScale || h);
2969
- return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, data: u, orientation: o, options: i, labels: l, baseOptions: c, allOptions: s, internalData: v, groupedData: m, stackedXScaleGenerator: g, stackedYScaleGenerator: h, xScale: _, yScale: x, LumeChart: _e, LumeBarGroup: rt };
3032
+ ), _ = v(() => r.xScale || h), x = v(() => r.yScale || g);
3033
+ return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, data: o, orientation: l, options: i, labels: u, baseOptions: c, allOptions: s, internalData: f, groupedData: m, stackedXScaleGenerator: h, stackedYScaleGenerator: g, xScale: _, yScale: x, LumeChart: fe, LumeBarGroup: ut };
2970
3034
  }
2971
3035
  });
2972
- var Co = function() {
3036
+ var jo = function() {
2973
3037
  var e = this, r = e._self._c, n = e._self._setupProxy;
2974
3038
  return r(n.LumeChart, e._g(e._b({ attrs: { "chart-type": "stacked-bar", options: n.allOptions, "x-scale": n.xScale, "y-scale": n.yScale, "data-j-stacked-bar-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
2975
3039
  return [r(n.LumeBarGroup, e._g(e._b({ attrs: { type: "stacked" } }, "lume-bar-group", a, !1), n.componentEventPropagator))];
2976
- } }, e._l(n.slots, function(a, u) {
2977
- return { key: u, fn: function(o) {
2978
- return [e._t(u, null, null, o || {})];
3040
+ } }, e._l(n.slots, function(a, o) {
3041
+ return { key: o, fn: function(l) {
3042
+ return [e._t(o, null, null, l || {})];
2979
3043
  } };
2980
3044
  })], null, !0) }, "lume-chart", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
2981
- }, Bo = [], Go = /* @__PURE__ */ D(
2982
- So,
2983
- Co,
2984
- Bo,
3045
+ }, Vo = [], Mo = /* @__PURE__ */ S(
3046
+ Go,
3047
+ jo,
3048
+ Vo,
2985
3049
  !1,
2986
3050
  null,
2987
3051
  null
2988
3052
  );
2989
- const xu = Go.exports, bt = 2, Fo = /* @__PURE__ */ R({
3053
+ const Ol = Mo.exports, Tt = 2, zo = /* @__PURE__ */ R({
2990
3054
  __name: "lume-line",
2991
3055
  props: {
2992
3056
  pathDefinition: {
@@ -2995,7 +3059,7 @@ const xu = Go.exports, bt = 2, Fo = /* @__PURE__ */ R({
2995
3059
  },
2996
3060
  width: {
2997
3061
  type: Number,
2998
- default: bt
3062
+ default: Tt
2999
3063
  },
3000
3064
  color: {
3001
3065
  type: String,
@@ -3021,10 +3085,10 @@ const xu = Go.exports, bt = 2, Fo = /* @__PURE__ */ R({
3021
3085
  emits: ["click"],
3022
3086
  setup(t, { emit: e }) {
3023
3087
  const r = I(null);
3024
- return ae(() => Ne(r.value)), { __sfc: !0, DEFAULT_LINE_WIDTH: bt, emit: e, root: r };
3088
+ return re(() => Ne(r.value)), { __sfc: !0, DEFAULT_LINE_WIDTH: Tt, emit: e, root: r };
3025
3089
  }
3026
3090
  });
3027
- var jo = function() {
3091
+ var Wo = function() {
3028
3092
  var e = this, r = e._self._c, n = e._self._setupProxy;
3029
3093
  return r("path", { ref: "root", staticClass: "lume-line", class: {
3030
3094
  [`lume-stroke--${e.color}`]: !0,
@@ -3036,31 +3100,31 @@ var jo = function() {
3036
3100
  }, attrs: { d: e.pathDefinition, "stroke-width": e.width, "data-j-line": "" }, on: { click: function(a) {
3037
3101
  return n.emit("click", a);
3038
3102
  } } });
3039
- }, Vo = [], Mo = /* @__PURE__ */ D(
3040
- Fo,
3041
- jo,
3042
- Vo,
3103
+ }, Uo = [], Zo = /* @__PURE__ */ S(
3104
+ zo,
3105
+ Wo,
3106
+ Uo,
3043
3107
  !1,
3044
3108
  null,
3045
3109
  "59449838"
3046
3110
  );
3047
- const zo = Mo.exports, kt = 4, xt = 3, Wo = /* @__PURE__ */ R({
3111
+ const Xo = Zo.exports, At = 4, Ot = 3, Yo = /* @__PURE__ */ R({
3048
3112
  __name: "lume-point",
3049
3113
  props: {
3050
3114
  x: null,
3051
3115
  y: null,
3052
3116
  color: { default: Y.Skyblue },
3053
- radius: { default: kt },
3117
+ radius: { default: At },
3054
3118
  active: { type: Boolean, default: !1 },
3055
3119
  visible: { type: Boolean, default: !1 }
3056
3120
  },
3057
3121
  emits: ["click"],
3058
3122
  setup(t, { emit: e }) {
3059
- const r = t, n = I(null), a = f(() => r.radius / 2), u = f(() => r.active ? r.radius : r.visible ? xt : 0);
3060
- return ae(() => Ne(n.value)), { __sfc: !0, DEFAULT_RADIUS: kt, DEFAULT_VISIBLE_RADIUS: xt, props: r, emit: e, root: n, strokeWidth: a, computedRadius: u };
3123
+ const r = t, n = I(null), a = v(() => r.radius / 2), o = v(() => r.active ? r.radius : r.visible ? Ot : 0);
3124
+ return re(() => Ne(n.value)), { __sfc: !0, DEFAULT_RADIUS: At, DEFAULT_VISIBLE_RADIUS: Ot, props: r, emit: e, root: n, strokeWidth: a, computedRadius: o };
3061
3125
  }
3062
3126
  });
3063
- var Uo = function() {
3127
+ var Ko = function() {
3064
3128
  var e = this, r = e._self._c, n = e._self._setupProxy;
3065
3129
  return r("circle", { ref: "root", staticClass: "lume-point", class: {
3066
3130
  [`lume-stroke--${e.color}`]: !0,
@@ -3069,47 +3133,47 @@ var Uo = function() {
3069
3133
  }, attrs: { cx: e.x, cy: e.y, r: n.computedRadius, "stroke-width": n.strokeWidth, "data-j-point": "" }, on: { click: function(a) {
3070
3134
  return n.emit("click", a);
3071
3135
  } } });
3072
- }, Zo = [], Xo = /* @__PURE__ */ D(
3073
- Wo,
3074
- Uo,
3075
- Zo,
3136
+ }, Jo = [], Qo = /* @__PURE__ */ S(
3137
+ Yo,
3138
+ Ko,
3139
+ Jo,
3076
3140
  !1,
3077
3141
  null,
3078
3142
  "080270c0"
3079
3143
  );
3080
- const Yo = Xo.exports;
3081
- function jt(t, e) {
3082
- function r(o) {
3144
+ const qo = Qo.exports;
3145
+ function Xt(t, e) {
3146
+ function r(l) {
3083
3147
  let i = null;
3084
- return o == null ? void 0 : o.reduce((l, c, s) => (c == null || c.value == null ? (i ? i.push(s) : i = [s], s === (o == null ? void 0 : o.length) - 1 && l.push(i)) : i && (l.push(i), i = null), l), []);
3148
+ return l == null ? void 0 : l.reduce((u, c, s) => (c == null || c.value == null ? (i ? i.push(s) : i = [s], s === (l == null ? void 0 : l.length) - 1 && u.push(i)) : i && (u.push(i), i = null), u), []);
3085
3149
  }
3086
- function n(o, i, l, c) {
3087
- const m = Math.abs(o - i) / (l + 1) * (c + 1);
3088
- return o == null && i == null ? null : o > i ? o - m : o + m;
3150
+ function n(l, i, u, c) {
3151
+ const m = Math.abs(l - i) / (u + 1) * (c + 1);
3152
+ return l == null && i == null ? null : l > i ? l - m : l + m;
3089
3153
  }
3090
- function a(o) {
3091
- return function(l) {
3092
- return !!o.find(
3093
- (c) => c.includes(l) || c.includes(l - 1)
3154
+ function a(l) {
3155
+ return function(u) {
3156
+ return !!l.find(
3157
+ (c) => c.includes(u) || c.includes(u - 1)
3094
3158
  );
3095
3159
  };
3096
3160
  }
3097
- return { computedLineData: f(
3098
- () => t.value.map((o) => {
3099
- const i = r(o.values);
3161
+ return { computedLineData: v(
3162
+ () => t.value.map((l) => {
3163
+ const i = r(l.values);
3100
3164
  return {
3101
- ...o,
3165
+ ...l,
3102
3166
  isDashed: a(i),
3103
- values: o.values.map((l, c) => {
3104
- var v, m, g, h;
3167
+ values: l.values.map((u, c) => {
3168
+ var f, m, h, g;
3105
3169
  const s = i.find(
3106
3170
  (_) => _.includes(c)
3107
3171
  );
3108
3172
  if (s) {
3109
3173
  const _ = s[0] - 1, x = s[s.length - 1] + 1;
3110
- let d = (v = o.values[_]) == null ? void 0 : v.value, p = (m = o.values[x]) == null ? void 0 : m.value;
3174
+ let d = (f = l.values[_]) == null ? void 0 : f.value, p = (m = l.values[x]) == null ? void 0 : m.value;
3111
3175
  if (d == null) {
3112
- const y = (h = (g = e == null ? void 0 : e.value) == null ? void 0 : g.domain) == null ? void 0 : h.call(g);
3176
+ const y = (g = (h = e == null ? void 0 : e.value) == null ? void 0 : h.domain) == null ? void 0 : g.call(h);
3113
3177
  d = (y == null ? void 0 : y[1]) ?? 0, p = d;
3114
3178
  } else p == null && (p = d);
3115
3179
  return {
@@ -3119,33 +3183,33 @@ function jt(t, e) {
3119
3183
  s.length,
3120
3184
  s.indexOf(c)
3121
3185
  ),
3122
- label: wt,
3186
+ label: Pt,
3123
3187
  isNull: !0
3124
3188
  };
3125
3189
  }
3126
- return l;
3190
+ return u;
3127
3191
  })
3128
3192
  };
3129
3193
  })
3130
3194
  ) };
3131
3195
  }
3132
- function Ko(t, e) {
3196
+ function el(t, e) {
3133
3197
  const r = t.bandwidth() / 2;
3134
3198
  return (n, a) => t(t.domain()[e + (a - 1)]) + r;
3135
3199
  }
3136
- function Jo(t, e) {
3200
+ function tl(t, e) {
3137
3201
  return (r, n) => t(e + (n - 1));
3138
3202
  }
3139
- function Qo(t, e, r, n) {
3140
- const a = qt().x(
3141
- K(r) ? Ko(r, t) : Jo(r, t)
3142
- ).y((u) => n(u));
3143
- return e.every((u) => u == null) ? null : a(e);
3203
+ function nl(t, e, r, n) {
3204
+ const a = rn().x(
3205
+ K(r) ? el(r, t) : tl(r, t)
3206
+ ).y((o) => n(o));
3207
+ return e.every((o) => o == null) ? null : a(e);
3144
3208
  }
3145
- const At = 1, qo = /* @__PURE__ */ R({
3209
+ const It = 1, rl = /* @__PURE__ */ R({
3146
3210
  __name: "lume-line-group",
3147
3211
  props: {
3148
- ...we(),
3212
+ ...Ee(),
3149
3213
  withPoints: {
3150
3214
  type: [Boolean, String],
3151
3215
  default: !0
@@ -3157,152 +3221,152 @@ const At = 1, qo = /* @__PURE__ */ R({
3157
3221
  },
3158
3222
  emits: ["line-click", "point-click", "lume__internal--hover"],
3159
3223
  setup(t, { emit: e }) {
3160
- const r = t, { data: n, options: a, xScale: u, yScale: o, labels: i } = F(r), l = Ee(
3224
+ const r = t, { data: n, options: a, xScale: o, yScale: l, labels: i } = V(r), u = Oe(
3161
3225
  "tooltipAnchorAttributes",
3162
3226
  null
3163
- ), { updateTooltipAnchorAttributes: c } = Ct(
3164
- l,
3165
- a,
3227
+ ), { updateTooltipAnchorAttributes: c } = jt(
3166
3228
  u,
3229
+ a,
3167
3230
  o,
3231
+ l,
3168
3232
  i
3169
- ), s = f(() => {
3170
- if (n.value.every((N) => N.isDashed))
3233
+ ), s = v(() => {
3234
+ if (n.value.every((D) => D.isDashed))
3171
3235
  return n.value;
3172
- const { computedLineData: T } = jt(
3236
+ const { computedLineData: A } = Xt(
3173
3237
  n,
3174
- o
3238
+ l
3175
3239
  );
3176
- return a.value.withTooltip !== !1 && (l != null && l.value) && c(T.value), T.value;
3177
- }), v = f(() => {
3240
+ return a.value.withTooltip !== !1 && (u != null && u.value) && c(A.value), A.value;
3241
+ }), f = v(() => {
3178
3242
  if (r.hoveredIndex === -1) return;
3179
- const T = pn(
3243
+ const A = hn(
3180
3244
  s.value,
3181
3245
  r.hoveredIndex
3182
3246
  );
3183
3247
  return {
3184
- d: `M ${Be(u.value, r.hoveredIndex)},${o.value.range()[1]}
3185
- V ${o.value(T)}`
3248
+ d: `M ${je(o.value, r.hoveredIndex)},${l.value.range()[1]}
3249
+ V ${l.value(A)}`
3186
3250
  // Move to X index, Vertical line to the highest point
3187
3251
  };
3188
- }), m = f(
3189
- () => u.value && At / (mn(u.value) - 1)
3252
+ }), m = v(
3253
+ () => o.value && It / (yn(o.value) - 1)
3190
3254
  // Subtracting the first line (read below)
3191
- ), g = f(
3255
+ ), h = v(
3192
3256
  () => {
3193
- var T;
3194
- return ((T = a.value) == null ? void 0 : T.lineWidth) * 2 || void 0;
3257
+ var A;
3258
+ return ((A = a.value) == null ? void 0 : A.lineWidth) * 2 || void 0;
3195
3259
  }
3196
3260
  // If no `lineWidth`, returns NaN which needs to be undefined
3197
- ), h = f(
3198
- () => u.value.bandwidth() / 2
3199
- ), _ = f(() => u.value.domain()), x = f(
3261
+ ), g = v(
3262
+ () => o.value.bandwidth() / 2
3263
+ ), _ = v(() => o.value.domain()), x = v(
3200
3264
  () => a.value.withPoints ?? r.withPoints
3201
- ), d = f(
3265
+ ), d = v(
3202
3266
  () => a.value.withPoints === "visible" || r.withPoints === "visible"
3203
3267
  );
3204
- function p(T) {
3205
- return s.value[T].values;
3206
- }
3207
- function y(T, N) {
3208
- var j, V;
3209
- const S = T === 0 ? [] : [
3210
- (j = p(N)[T - 1]) == null ? void 0 : j.value,
3211
- (V = p(N)[T]) == null ? void 0 : V.value
3268
+ function p(A) {
3269
+ return s.value[A].values;
3270
+ }
3271
+ function y(A, D) {
3272
+ var M, z;
3273
+ const C = A === 0 ? [] : [
3274
+ (M = p(D)[A - 1]) == null ? void 0 : M.value,
3275
+ (z = p(D)[A]) == null ? void 0 : z.value
3212
3276
  ];
3213
- return Qo(
3214
- T,
3215
- S,
3216
- u.value,
3217
- o.value
3277
+ return nl(
3278
+ A,
3279
+ C,
3280
+ o.value,
3281
+ l.value
3218
3282
  ) || "";
3219
3283
  }
3220
- function b(T) {
3284
+ function k(A) {
3221
3285
  return {
3222
- animationDelay: T < 2 ? 0 : (T - 1) * m.value,
3286
+ animationDelay: A < 2 ? 0 : (A - 1) * m.value,
3223
3287
  animationDuration: m.value
3224
3288
  };
3225
3289
  }
3226
- function A(T, N) {
3227
- var j;
3228
- const S = (j = p(N)[T]) == null ? void 0 : j.value;
3290
+ function T(A, D) {
3291
+ var M;
3292
+ const C = (M = p(D)[A]) == null ? void 0 : M.value;
3229
3293
  return {
3230
- x: K(u.value) ? r.xScale(_.value[T]) + h.value : r.xScale(T),
3231
- y: S === null ? o.value(o.value.domain()[1]) : o.value(S)
3294
+ x: K(o.value) ? r.xScale(_.value[A]) + g.value : r.xScale(A),
3295
+ y: C === null ? l.value(l.value.domain()[1]) : l.value(C)
3232
3296
  };
3233
3297
  }
3234
- function $(T) {
3235
- return r.hoveredIndex === T;
3298
+ function N(A) {
3299
+ return r.hoveredIndex === A;
3236
3300
  }
3237
- return { __sfc: !0, LUME_TRANSITION_TIME_FULL: At, props: r, emit: e, data: n, options: a, xScale: u, yScale: o, labels: i, tooltipAnchorAttributes: l, updateTooltipAnchorAttributes: c, computedGroupData: s, overlayLineAttributes: v, animationDuration: m, pointRadius: g, xAxisOffset: h, domain: _, computedWithPoints: x, computedVisiblePoints: d, getValuesFromDataset: p, getPathDefinition: y, getLineTransitionParams: b, getPointPosition: A, isPointActive: $, LumeLine: zo, LumePoint: Yo };
3301
+ return { __sfc: !0, LUME_TRANSITION_TIME_FULL: It, props: r, emit: e, data: n, options: a, xScale: o, yScale: l, labels: i, tooltipAnchorAttributes: u, updateTooltipAnchorAttributes: c, computedGroupData: s, overlayLineAttributes: f, animationDuration: m, pointRadius: h, xAxisOffset: g, domain: _, computedWithPoints: x, computedVisiblePoints: d, getValuesFromDataset: p, getPathDefinition: y, getLineTransitionParams: k, getPointPosition: T, isPointActive: N, LumeLine: Xo, LumePoint: qo };
3238
3302
  }
3239
3303
  });
3240
- var eu = function() {
3304
+ var al = function() {
3241
3305
  var e = this, r = e._self._c, n = e._self._setupProxy;
3242
- 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, u) {
3243
- return r("g", { key: a.label, staticClass: "lume-line-group__group" }, [r("g", { staticClass: "lume-line-group__lines" }, e._l(a.values, function(o, i) {
3244
- return r(n.LumeLine, e._b({ key: `line-${i}`, attrs: { color: a.color, dashed: a.isDashed(i), "path-definition": n.getPathDefinition(i, u), transition: e.transition, width: n.options.lineWidth }, on: { click: function(l) {
3245
- return n.emit("line-click", { index: i, datasetIndex: u, event: l });
3306
+ 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) {
3307
+ return r("g", { key: a.label, staticClass: "lume-line-group__group" }, [r("g", { staticClass: "lume-line-group__lines" }, e._l(a.values, function(l, i) {
3308
+ 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(u) {
3309
+ return n.emit("line-click", { index: i, datasetIndex: o, event: u });
3246
3310
  } } }, "lume-line", n.getLineTransitionParams(i), !1));
3247
- }), 1), n.computedWithPoints ? r("g", { staticClass: "lume-line-group__points", attrs: { "data-j-lume-line-group__points": "" } }, [e._l(a.values, function(o, i) {
3248
- return [o.isNull ? e._e() : r(n.LumePoint, e._b({ attrs: { active: n.isPointActive(i), color: a.color, index: i, radius: n.pointRadius, visible: n.computedVisiblePoints }, on: { click: function(l) {
3249
- return n.emit("point-click", { index: i, datasetIndex: u, event: l });
3250
- } } }, "lume-point", n.getPointPosition(i, u), !1))];
3311
+ }), 1), n.computedWithPoints ? r("g", { staticClass: "lume-line-group__points", attrs: { "data-j-lume-line-group__points": "" } }, [e._l(a.values, function(l, i) {
3312
+ return [l.isNull ? e._e() : r(n.LumePoint, e._b({ attrs: { active: n.isPointActive(i), color: a.color, index: i, radius: n.pointRadius, visible: n.computedVisiblePoints }, on: { click: function(u) {
3313
+ return n.emit("point-click", { index: i, datasetIndex: o, event: u });
3314
+ } } }, "lume-point", n.getPointPosition(i, o), !1))];
3251
3315
  })], 2) : e._e()]);
3252
3316
  })], 2);
3253
- }, tu = [], nu = /* @__PURE__ */ D(
3254
- qo,
3255
- eu,
3256
- tu,
3317
+ }, ol = [], ll = /* @__PURE__ */ S(
3318
+ rl,
3319
+ al,
3320
+ ol,
3257
3321
  !1,
3258
3322
  null,
3259
3323
  "898c2e7a"
3260
3324
  );
3261
- const Vt = nu.exports, ru = {
3262
- margins: se.VERTICAL,
3325
+ const Yt = ll.exports, ul = {
3326
+ margins: ie.VERTICAL,
3263
3327
  startOnZero: !0,
3264
3328
  withTooltip: !0,
3265
3329
  xAxisOptions: {},
3266
3330
  yAxisOptions: { gridLines: !0 }
3267
- }, au = /* @__PURE__ */ R({
3331
+ }, il = /* @__PURE__ */ R({
3268
3332
  __name: "lume-line-chart",
3269
3333
  props: {
3270
- ...me(null, !1)
3334
+ ...ve(null, !1)
3271
3335
  },
3272
3336
  setup(t, { emit: e }) {
3273
- const r = t, { componentEventPropagator: n } = q(e), a = ce(X()), { options: u } = F(r), { allOptions: o } = Q(u, ru);
3274
- return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, options: u, allOptions: o, LumeChart: _e, LumeLineGroup: Vt };
3337
+ const r = t, { componentEventPropagator: n } = q(e), a = se(X()), { options: o } = V(r), { allOptions: l } = Q(o, ul);
3338
+ return { __sfc: !0, props: r, emit: e, componentEventPropagator: n, slots: a, options: o, allOptions: l, LumeChart: fe, LumeLineGroup: Yt };
3275
3339
  }
3276
3340
  });
3277
- var ou = function() {
3341
+ var sl = function() {
3278
3342
  var e = this, r = e._self._c, n = e._self._setupProxy;
3279
3343
  return r(n.LumeChart, e._g(e._b({ attrs: { "chart-type": "line", options: n.allOptions, "data-j-lume-line-chart": "" }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
3280
3344
  return [r(n.LumeLineGroup, e._g(e._b({}, "lume-line-group", a, !1), n.componentEventPropagator))];
3281
- } }, e._l(n.slots, function(a, u) {
3282
- return { key: u, fn: function(o) {
3283
- return [e._t(u, null, null, o || {})];
3345
+ } }, e._l(n.slots, function(a, o) {
3346
+ return { key: o, fn: function(l) {
3347
+ return [e._t(o, null, null, l || {})];
3284
3348
  } };
3285
3349
  })], null, !0) }, "lume-chart", { ...n.props, ...e.$attrs }, !1), n.componentEventPropagator));
3286
- }, uu = [], lu = /* @__PURE__ */ D(
3287
- au,
3288
- ou,
3289
- uu,
3350
+ }, cl = [], dl = /* @__PURE__ */ S(
3351
+ il,
3352
+ sl,
3353
+ cl,
3290
3354
  !1,
3291
3355
  null,
3292
3356
  null
3293
3357
  );
3294
- const Au = lu.exports;
3295
- function iu(t) {
3296
- return { areaPathDefinition: f(
3358
+ const Il = dl.exports;
3359
+ function vl(t) {
3360
+ return { areaPathDefinition: v(
3297
3361
  () => function(r, n) {
3298
3362
  if (!r || !n || K(r) || K(n))
3299
3363
  return;
3300
3364
  const a = t.value[0].values;
3301
- return en().x((u, o) => r(o)).y0(n(Math.min(...n.domain()))).y1((u) => n(u.value))(a);
3365
+ return an().x((o, l) => r(l)).y0(n(Math.min(...n.domain()))).y1((o) => n(o.value))(a);
3302
3366
  }
3303
3367
  ) };
3304
3368
  }
3305
- const su = {
3369
+ const fl = {
3306
3370
  margins: {
3307
3371
  top: 0,
3308
3372
  right: 0,
@@ -3316,23 +3380,23 @@ const su = {
3316
3380
  tooltipOptions: {
3317
3381
  showTitle: !1
3318
3382
  }
3319
- }, cu = /* @__PURE__ */ R({
3383
+ }, pl = /* @__PURE__ */ R({
3320
3384
  __name: "lume-sparkline-chart",
3321
3385
  props: {
3322
- ...qe(null),
3323
- ...be()
3386
+ ...nt(null),
3387
+ ...ye()
3324
3388
  },
3325
3389
  setup(t, { expose: e, emit: r }) {
3326
- const n = t, { componentEventPropagator: a } = q(r), u = ce(X()), { data: o, options: i } = F(n), { internalData: l } = et(o), { allOptions: c } = Q(i, su), { computedLineData: s } = jt(l), { areaPathDefinition: v } = iu(s), m = f(() => {
3390
+ const n = t, { componentEventPropagator: a } = q(r), o = se(X()), { data: l, options: i } = V(n), { internalData: u } = rt(l), { allOptions: c } = Q(i, fl), { computedLineData: s } = Xt(u), { areaPathDefinition: f } = vl(s), m = v(() => {
3327
3391
  var x, d;
3328
- return (d = (x = l.value) == null ? void 0 : x[0]) == null ? void 0 : d.color;
3329
- }), g = f(
3392
+ return (d = (x = u.value) == null ? void 0 : x[0]) == null ? void 0 : d.color;
3393
+ }), h = v(
3330
3394
  () => {
3331
3395
  var x, d;
3332
- return ((d = (x = o.value) == null ? void 0 : x[0]) == null ? void 0 : d.areaColor) || m.value;
3396
+ return ((d = (x = l.value) == null ? void 0 : x[0]) == null ? void 0 : d.areaColor) || m.value;
3333
3397
  }
3334
3398
  );
3335
- function h(x) {
3399
+ function g(x) {
3336
3400
  return {
3337
3401
  ...x,
3338
3402
  noMinSize: !0
@@ -3343,11 +3407,11 @@ const su = {
3343
3407
  return ge().range([0, p.width]).domain([0, x[0].values.length - 1]);
3344
3408
  }
3345
3409
  return e({
3346
- areaPathDefinition: v
3347
- }), { __sfc: !0, props: n, emit: r, componentEventPropagator: a, slots: u, data: o, options: i, internalData: l, allOptions: c, computedLineData: s, areaPathDefinition: v, computedColor: m, areaColor: g, getSparklineOptions: h, xScaleGenerator: _, LumeChart: _e, LumeLineGroup: Vt };
3410
+ areaPathDefinition: f
3411
+ }), { __sfc: !0, props: n, emit: r, componentEventPropagator: a, slots: o, data: l, options: i, internalData: u, allOptions: c, computedLineData: s, areaPathDefinition: f, computedColor: m, areaColor: h, getSparklineOptions: g, xScaleGenerator: _, LumeChart: fe, LumeLineGroup: Yt };
3348
3412
  }
3349
3413
  });
3350
- var du = function() {
3414
+ var ml = function() {
3351
3415
  var e = this, r = e._self._c, n = e._self._setupProxy;
3352
3416
  return r(n.LumeChart, e._g(e._b({ attrs: { "chart-type": "line", options: n.getSparklineOptions(n.allOptions), "x-scale": n.xScaleGenerator }, scopedSlots: e._u([{ key: "groups", fn: function(a) {
3353
3417
  return [n.allOptions.showArea ? r("path", { class: [
@@ -3356,70 +3420,70 @@ var du = function() {
3356
3420
  `lume-fill--${n.areaColor || n.computedColor}`,
3357
3421
  "lume-fill--faded"
3358
3422
  ], attrs: { d: n.areaPathDefinition(a.xScale, a.yScale), "data-j-sparkline__area": "" } }) : e._e(), r(n.LumeLineGroup, e._g(e._b({ attrs: { "with-points": !1 } }, "lume-line-group", a, !1), n.componentEventPropagator))];
3359
- } }, e._l(n.slots, function(a, u) {
3360
- return { key: u, fn: function(o) {
3361
- return [e._t(u, null, null, o || {})];
3423
+ } }, e._l(n.slots, function(a, o) {
3424
+ return { key: o, fn: function(l) {
3425
+ return [e._t(o, null, null, l || {})];
3362
3426
  } };
3363
3427
  })], null, !0) }, "lume-chart", n.props, !1), n.componentEventPropagator));
3364
- }, vu = [], fu = /* @__PURE__ */ D(
3365
- cu,
3366
- du,
3367
- vu,
3428
+ }, _l = [], gl = /* @__PURE__ */ S(
3429
+ pl,
3430
+ ml,
3431
+ _l,
3368
3432
  !1,
3369
3433
  null,
3370
3434
  "579f7e32"
3371
3435
  );
3372
- const Lu = fu.exports;
3436
+ const Nl = gl.exports;
3373
3437
  export {
3374
- Gr as A,
3375
- dt as B,
3376
- ie as C,
3377
- Ke as D,
3378
- Be as E,
3379
- ct as F,
3380
- tt as G,
3381
- et as H,
3382
- er as I,
3383
- jt as J,
3384
- Fr as K,
3385
- Qe as L,
3438
+ Mr as A,
3439
+ mt as B,
3440
+ ue as C,
3441
+ qe as D,
3442
+ je as E,
3443
+ pt as F,
3444
+ at as G,
3445
+ rt as H,
3446
+ ar as I,
3447
+ Xt as J,
3448
+ zr as K,
3449
+ tt as L,
3386
3450
  Q as M,
3387
- nr as N,
3388
- Je as O,
3389
- Mr as P,
3390
- Ct as Q,
3391
- zr as R,
3392
- St as S,
3393
- qe as T,
3394
- me as U,
3395
- tr as V,
3396
- be as W,
3397
- qn as X,
3451
+ lr as N,
3452
+ et as O,
3453
+ Zr as P,
3454
+ jt as Q,
3455
+ Xr as R,
3456
+ Gt as S,
3457
+ nt as T,
3458
+ ve as U,
3459
+ or as V,
3460
+ ye as W,
3461
+ rr as X,
3398
3462
  Y as a,
3399
- qa as b,
3400
- ha as c,
3401
- la as d,
3402
- va as e,
3403
- Sn as f,
3404
- Ye as g,
3405
- yu as h,
3406
- rt as i,
3407
- _e as j,
3408
- lr as k,
3409
- gu as l,
3410
- vr as m,
3411
- ku as n,
3412
- zo as o,
3413
- Au as p,
3414
- Vt as q,
3415
- Cr as r,
3416
- Yo as s,
3417
- bu as t,
3418
- Lu as u,
3419
- xu as v,
3420
- Dr as w,
3421
- Ir as x,
3422
- xr as y,
3423
- hr as z
3463
+ ro as b,
3464
+ ka as c,
3465
+ da as d,
3466
+ _a as e,
3467
+ Gn as f,
3468
+ Qe as g,
3469
+ Ll as h,
3470
+ ut as i,
3471
+ fe as j,
3472
+ dr as k,
3473
+ xl as l,
3474
+ _r as m,
3475
+ Al as n,
3476
+ Xo as o,
3477
+ Il as p,
3478
+ Yt as q,
3479
+ jr as r,
3480
+ qo as s,
3481
+ Tl as t,
3482
+ Nl as u,
3483
+ Ol as v,
3484
+ Rr as w,
3485
+ wr as x,
3486
+ Or as y,
3487
+ kr as z
3424
3488
  };
3425
- //# sourceMappingURL=vDk1lu85.js.map
3489
+ //# sourceMappingURL=h4DBladZ.js.map