@adyen/lume 1.11.0 → 1.11.1
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lume-chart.vue.d.ts","sourceRoot":"","sources":["../../../../../../lib/src/components/core/lume-chart/lume-chart.vue.ts"],"names":[],"mappings":"AAEA,OAAO,EAGL,QAAQ,EAMT,MAAM,KAAK,CAAC;AAYb,OAAO,EAAW,KAAK,EAAiB,MAAM,sBAAsB,CAAC;AAqBrE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAE5C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"lume-chart.vue.d.ts","sourceRoot":"","sources":["../../../../../../lib/src/components/core/lume-chart/lume-chart.vue.ts"],"names":[],"mappings":"AAEA,OAAO,EAGL,QAAQ,EAMT,MAAM,KAAK,CAAC;AAYb,OAAO,EAAW,KAAK,EAAiB,MAAM,sBAAsB,CAAC;AAqBrE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAE5C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAkJtD,iBAAS,mBAAmB,CAAC,KAAK,EAAE,MAAM,QAqBzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0zBD,wBAAwG;AAGxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,YAAY,EAAE,CAAC,CAAC;KACf,CAAA;CAAE,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -533,7 +533,7 @@ const En = /* @__PURE__ */ H({
|
|
|
533
533
|
() => f.value.withHover && y.value && l.value > -1
|
|
534
534
|
), S = v(
|
|
535
535
|
() => f.value.tickPadding + me || n
|
|
536
|
-
),
|
|
536
|
+
), C = v(() => h.value === "x" ? (
|
|
537
537
|
// If x axis, get the tick height
|
|
538
538
|
Math.max(
|
|
539
539
|
...(c.value || []).map(
|
|
@@ -554,7 +554,7 @@ const En = /* @__PURE__ */ H({
|
|
|
554
554
|
)
|
|
555
555
|
)
|
|
556
556
|
));
|
|
557
|
-
function
|
|
557
|
+
function P(I) {
|
|
558
558
|
const { showTicks: g } = f.value;
|
|
559
559
|
return g === !1 ? "" : $.value(I);
|
|
560
560
|
}
|
|
@@ -572,7 +572,7 @@ const En = /* @__PURE__ */ H({
|
|
|
572
572
|
function te() {
|
|
573
573
|
m.value = A.value.map(
|
|
574
574
|
(I, g) => ({
|
|
575
|
-
value:
|
|
575
|
+
value: P(I),
|
|
576
576
|
group: d.getTickGroupAttributes(I, g),
|
|
577
577
|
ghost: d.getTickGhostAttributes(W(g)),
|
|
578
578
|
label: d.getTickLabelAttributes(),
|
|
@@ -593,7 +593,7 @@ const En = /* @__PURE__ */ H({
|
|
|
593
593
|
}
|
|
594
594
|
);
|
|
595
595
|
}
|
|
596
|
-
return D(a, ne, { flush: "sync", immediate: !0 }), D(a, te, { immediate: !0 }), D(c, te), D(
|
|
596
|
+
return D(a, ne, { flush: "sync", immediate: !0 }), D(a, te, { immediate: !0 }), D(c, te), D(C, (I) => e("lume__internal--axis-size", I)), D(r.containerSize, Q), ee(() => $e(_.value)), { __sfc: !0, SCALE_MIXIN_MAP: Se, POSITIONS: Re, TYPES: xe, AXIS_LABEL_OFFSET: n, props: r, emit: e, scale: a, containerSize: o, hoveredIndex: l, options: i, orientation: u, isEmpty: s, mixins: d, tickRefs: c, root: _, ticksWithAttributes: m, computedPosition: p, computedType: h, shouldHover: y, allOptions: f, showTick: k, axisTransform: x, ticks: A, tickFormatter: $, isHovering: T, axisLabelOffset: S, axisSize: C, formatTick: P, handleTickMouseenter: F, handleTickClick: V, getTextNode: W, setTicks: te, updateGridlines: Q, init: ne, LumeTick: rn };
|
|
597
597
|
}
|
|
598
598
|
});
|
|
599
599
|
var wn = function() {
|
|
@@ -1486,7 +1486,7 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1486
1486
|
}
|
|
1487
1487
|
},
|
|
1488
1488
|
setup(t, { emit: e }) {
|
|
1489
|
-
const r = t, n = M(), { data: a, labels: o, color: l, options: i, orientation: u, chartType: s } = B(r), d = E(-1), c = E(null), _ = E(null), m = E([]), p = E(null), h = E(0), y = E(0), { allOptions: f } = K(i), { internalData: k, computedLabels: x, containerSize: A, updateSize: $, chartID: T } = Qe(a, o, l, f, u), { listenInternalEvent: S } = J(e, T), { xScale:
|
|
1489
|
+
const r = t, n = M(), { data: a, labels: o, color: l, options: i, orientation: u, chartType: s } = B(r), d = E(-1), c = E(null), _ = E(null), m = E([]), p = E(null), h = E(0), y = E(0), { allOptions: f } = K(i), { internalData: k, computedLabels: x, containerSize: A, updateSize: $, chartID: T } = Qe(a, o, l, f, u), { listenInternalEvent: S } = J(e, T), { xScale: C, yScale: P } = Jn(
|
|
1490
1490
|
k,
|
|
1491
1491
|
x,
|
|
1492
1492
|
A,
|
|
@@ -1499,10 +1499,10 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1499
1499
|
left: Wr(f.value.margins, y.value)
|
|
1500
1500
|
})), V = v(() => {
|
|
1501
1501
|
var b;
|
|
1502
|
-
return r.xScale ? st(r.xScale) ? r.xScale : (b = r.xScale) == null ? void 0 : b.call(r, k.value, o.value, A) :
|
|
1502
|
+
return r.xScale ? st(r.xScale) ? r.xScale : (b = r.xScale) == null ? void 0 : b.call(r, k.value, o.value, A) : C.value;
|
|
1503
1503
|
}), W = v(() => {
|
|
1504
1504
|
var b;
|
|
1505
|
-
return r.yScale ? st(r.yScale) ? r.yScale : (b = r.yScale) == null ? void 0 : b.call(r, k.value, o.value, A) :
|
|
1505
|
+
return r.yScale ? st(r.yScale) ? r.yScale : (b = r.yScale) == null ? void 0 : b.call(r, k.value, o.value, A) : P.value;
|
|
1506
1506
|
}), te = v(() => ({
|
|
1507
1507
|
...f.value.xAxisOptions,
|
|
1508
1508
|
withHover: u.value === L.VERTICAL
|
|
@@ -1522,10 +1522,10 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1522
1522
|
var b;
|
|
1523
1523
|
return ((b = f.value.yAxisOptions) == null ? void 0 : b.withTitle) !== !1 && I.value;
|
|
1524
1524
|
}), N = v(
|
|
1525
|
-
() => a.value.every((b) => !b.values.length)
|
|
1525
|
+
() => a.value.every((b) => !b.values.length) || a.value.every((b) => b.values.every((R) => R === null))
|
|
1526
1526
|
), Z = v(() => {
|
|
1527
|
-
const b = [], { noBaseScales:
|
|
1528
|
-
return
|
|
1527
|
+
const b = [], { noBaseScales: R } = f.value;
|
|
1528
|
+
return R || b.push(() => !!(V.value && W.value)), b.every((j) => j() === !0);
|
|
1529
1529
|
}), { hasNegativeValues: U } = Cr(k), { negativeBarAttributes: G } = Pr(
|
|
1530
1530
|
A,
|
|
1531
1531
|
V,
|
|
@@ -1546,20 +1546,20 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1546
1546
|
return ((b = f.value.tooltipOptions) == null ? void 0 : b.position) || "top";
|
|
1547
1547
|
}
|
|
1548
1548
|
), nt = v(() => {
|
|
1549
|
-
var
|
|
1550
|
-
const b = (
|
|
1549
|
+
var R;
|
|
1550
|
+
const b = (R = f.value.tooltipOptions) == null ? void 0 : R.withPointerEvents;
|
|
1551
1551
|
return ve.opened && (!b || b && p.value === !1);
|
|
1552
1552
|
});
|
|
1553
1553
|
function be(b) {
|
|
1554
1554
|
var j;
|
|
1555
1555
|
if (f.value.withHover === !1 || b === d.value)
|
|
1556
1556
|
return;
|
|
1557
|
-
const
|
|
1557
|
+
const R = d.value;
|
|
1558
1558
|
if (d.value = b, f.value.withTooltip !== !1) {
|
|
1559
1559
|
const Mt = (j = f.value.tooltipOptions) != null && j.targetElement ? f.value.tooltipOptions.targetElement === "self" ? _.value.$el : f.value.tooltipOptions.targetElement : c.value[b];
|
|
1560
1560
|
ge(Mt);
|
|
1561
1561
|
}
|
|
1562
|
-
e("hovered-index-changed", { newIndex: b, oldIndex:
|
|
1562
|
+
e("hovered-index-changed", { newIndex: b, oldIndex: R }), e("update:hoveredIndex", b);
|
|
1563
1563
|
}
|
|
1564
1564
|
function ke() {
|
|
1565
1565
|
le(), d.value = -1, e("update:hoveredIndex", -1);
|
|
@@ -1581,18 +1581,18 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1581
1581
|
function Ft(b) {
|
|
1582
1582
|
$(b), e("resize", b);
|
|
1583
1583
|
}
|
|
1584
|
-
function Vt({ index: b, value:
|
|
1585
|
-
b !== null && be(b), e("axis-mouseenter", { index: b, value:
|
|
1584
|
+
function Vt({ index: b, value: R, event: j }) {
|
|
1585
|
+
b !== null && be(b), e("axis-mouseenter", { index: b, value: R, event: j });
|
|
1586
1586
|
}
|
|
1587
|
-
function jt({ index: b, value:
|
|
1588
|
-
e("axis-click", { index: b, value:
|
|
1587
|
+
function jt({ index: b, value: R, event: j }) {
|
|
1588
|
+
e("axis-click", { index: b, value: R, event: j });
|
|
1589
1589
|
}
|
|
1590
1590
|
return D(
|
|
1591
1591
|
a,
|
|
1592
|
-
(b,
|
|
1592
|
+
(b, R) => e("data-changed", { newValue: b, oldValue: R })
|
|
1593
1593
|
), D(
|
|
1594
1594
|
o,
|
|
1595
|
-
(b,
|
|
1595
|
+
(b, R) => e("labels-changed", { newValue: b, oldValue: R })
|
|
1596
1596
|
), D(N, (b) => b && q(Y.Empty), { immediate: !0 }), D(() => r.hoveredIndex, Ee), D(
|
|
1597
1597
|
m,
|
|
1598
1598
|
(b) => {
|
|
@@ -1603,7 +1603,7 @@ const Zr = /* @__PURE__ */ H({
|
|
|
1603
1603
|
b === !1 && ve.opened && ke();
|
|
1604
1604
|
}), ee(async () => {
|
|
1605
1605
|
e("rendered"), n.groups || console.error('"groups" `<slot>` must have content.'), S("lume__internal--hover", be);
|
|
1606
|
-
}), we("chartID", T), we("isEmpty", N), we("tooltipAnchorAttributes", m), { __sfc: !0, props: r, slots: n, emit: e, data: a, labels: o, color: l, options: i, orientation: u, chartType: s, internalHoveredIndex: d, tooltipAnchor: c, chartContainer: _, tooltipAnchorAttributes: m, isHoveringTooltip: p, xAxisHeight: h, yAxisWidth: y, allOptions: f, internalData: k, computedLabels: x, containerSize: A, updateSize: $, chartID: T, listenInternalEvent: S, xScale:
|
|
1606
|
+
}), we("chartID", T), we("isEmpty", N), we("tooltipAnchorAttributes", m), { __sfc: !0, props: r, slots: n, emit: e, data: a, labels: o, color: l, options: i, orientation: u, chartType: s, internalHoveredIndex: d, tooltipAnchor: c, chartContainer: _, tooltipAnchorAttributes: m, isHoveringTooltip: p, xAxisHeight: h, yAxisWidth: y, allOptions: f, internalData: k, computedLabels: x, containerSize: A, updateSize: $, chartID: T, listenInternalEvent: S, xScale: C, yScale: P, computedMargins: F, computedXScale: V, computedYScale: W, computedXAxisOptions: te, computedYAxisOptions: Q, xAxisTitle: ne, yAxisTitle: I, showXAxisTitle: g, showYAxisTitle: O, isEmpty: N, isReady: Z, hasNegativeValues: U, negativeBarAttributes: G, shouldGenerateTooltipAnchors: tt, tooltipConfig: ve, showTooltip: ge, hideTooltip: le, getTooltipItems: ye, tooltipPosition: ue, shouldHideTooltip: nt, handleInternalHover: be, handleHideTooltip: ke, handleExternalHover: Ee, handleMouseleave: Gt, handleResize: Ft, handleAxisMouseenter: Vt, handleAxisClick: jt, LumeAxis: Dn, LumeBar: Ue, LumeChartContainer: ar, LumeChartLegend: sr, LumeTooltip: Er, LumeOverlayGroup: Sr, TOOLTIP_ANCHOR_RADIUS: bn };
|
|
1607
1607
|
}
|
|
1608
1608
|
});
|
|
1609
1609
|
var Ur = function() {
|
|
@@ -1669,7 +1669,7 @@ var Ur = function() {
|
|
|
1669
1669
|
Xr,
|
|
1670
1670
|
!1,
|
|
1671
1671
|
null,
|
|
1672
|
-
"
|
|
1672
|
+
"5aa3d9ab",
|
|
1673
1673
|
null,
|
|
1674
1674
|
null
|
|
1675
1675
|
);
|
|
@@ -2096,10 +2096,10 @@ const wa = /* @__PURE__ */ H({
|
|
|
2096
2096
|
function S(g) {
|
|
2097
2097
|
return y.value.length > 0 && !y.value.includes(g.toString());
|
|
2098
2098
|
}
|
|
2099
|
-
function
|
|
2099
|
+
function C(g) {
|
|
2100
2100
|
return y.value.length > 0 && y.value.includes(g.toString());
|
|
2101
2101
|
}
|
|
2102
|
-
function
|
|
2102
|
+
function P(g) {
|
|
2103
2103
|
return p.value.links.length > 0 && !p.value.links.includes(g);
|
|
2104
2104
|
}
|
|
2105
2105
|
function F(g) {
|
|
@@ -2139,7 +2139,7 @@ const wa = /* @__PURE__ */ H({
|
|
|
2139
2139
|
l.value = ya(g.nodes), i.value = Aa(g.links).reverse(), m.value == null && r.hoveredElementId != null && Q(r.hoveredElementId);
|
|
2140
2140
|
}), D([r.containerSize, u], () => {
|
|
2141
2141
|
r.containerSize.width && r.containerSize.height && I();
|
|
2142
|
-
}), D(() => r.hoveredElementId, Q), { __sfc: !0, props: r, emit: e, chartID: n, data: a, options: o, nodeBlocks: l, linkPaths: i, nodeTextRefs: u, extents: s, updateExtents: d, columns: c, graph: _, hoveredElement: m, highlightedElements: p, formatValue: h, hoveredNodeIds: y, nodeColumnPositions: f, nodeHeaders: k, computedNodeHeaderPadding: x, gradients: A, nodesDerivingColorFromIncomingLinks: $, getLinkStroke: T, isNodeFaded: S, isNodeFocused:
|
|
2142
|
+
}), D(() => r.hoveredElementId, Q), { __sfc: !0, props: r, emit: e, chartID: n, data: a, options: o, nodeBlocks: l, linkPaths: i, nodeTextRefs: u, extents: s, updateExtents: d, columns: c, graph: _, hoveredElement: m, highlightedElements: p, formatValue: h, hoveredNodeIds: y, nodeColumnPositions: f, nodeHeaders: k, computedNodeHeaderPadding: x, gradients: A, nodesDerivingColorFromIncomingLinks: $, getLinkStroke: T, isNodeFaded: S, isNodeFocused: C, isLinkFaded: P, isLinkFocused: F, shouldDeriveNodeColorFromIncomingLinks: V, handleLinkMouseover: W, handleLinkMouseleave: te, handleExternalHover: Q, getSubNodesDerivingColorFromIncomingLinks: ne, updateMargins: I, LumeAlluvialNodeLabel: na, LumeAlluvialNodeValue: ua, LumeAlluvialNodeHeader: va, GHOST_STROKE_WIDTH_OFFSET: Kr };
|
|
2143
2143
|
}
|
|
2144
2144
|
});
|
|
2145
2145
|
var Na = function() {
|
|
@@ -2450,13 +2450,13 @@ function Qa(t, e, r, n, a, o) {
|
|
|
2450
2450
|
function m(p, h, y) {
|
|
2451
2451
|
if (!(e.value && r.value))
|
|
2452
2452
|
return Ja;
|
|
2453
|
-
const { value: k, color: x } = p, A = x ?? t.value[h].color ?? Object.values(z)[h], $ = s(k, y, h), T = d(k, y, h), S = c(k),
|
|
2453
|
+
const { value: k, color: x } = p, A = x ?? t.value[h].color ?? Object.values(z)[h], $ = s(k, y, h), T = d(k, y, h), S = c(k), C = _(k);
|
|
2454
2454
|
return {
|
|
2455
2455
|
classList: [`lume-fill--${A}`, ...o],
|
|
2456
2456
|
x: $,
|
|
2457
2457
|
y: T,
|
|
2458
2458
|
width: S,
|
|
2459
|
-
height:
|
|
2459
|
+
height: C,
|
|
2460
2460
|
isFaded: a.value !== -1 && a.value !== y,
|
|
2461
2461
|
isNegative: k < 0
|
|
2462
2462
|
};
|
|
@@ -2533,12 +2533,12 @@ function eo(t, e, r, n, a, o) {
|
|
|
2533
2533
|
return f ? u.value.reduce((x, A, $) => ($ < f && A[k] < 0 && (x += A[k]), x), 0) : 0;
|
|
2534
2534
|
}
|
|
2535
2535
|
function y(f, k, x) {
|
|
2536
|
-
const { value: A, color: $ } = f, T = A >= 0 ? d(A) : c(A), S = A >= 0 ? _(A) : m(A),
|
|
2536
|
+
const { value: A, color: $ } = f, T = A >= 0 ? d(A) : c(A), S = A >= 0 ? _(A) : m(A), C = A >= 0 ? p(k, x) : h(k, x), { x: P, y: F } = s(A, x, C);
|
|
2537
2537
|
return {
|
|
2538
2538
|
classList: [`lume-fill--${$ ?? t.value[k].color ?? Object.values(z)[k]}`, ...o],
|
|
2539
2539
|
width: T,
|
|
2540
2540
|
height: S,
|
|
2541
|
-
x:
|
|
2541
|
+
x: P,
|
|
2542
2542
|
y: F,
|
|
2543
2543
|
isFaded: a.value !== -1 && a.value !== x,
|
|
2544
2544
|
isNegative: A < 0
|
|
@@ -2985,14 +2985,14 @@ const bt = 1, So = /* @__PURE__ */ H({
|
|
|
2985
2985
|
return d.value[T].values;
|
|
2986
2986
|
}
|
|
2987
2987
|
function k(T, S) {
|
|
2988
|
-
var
|
|
2989
|
-
const
|
|
2990
|
-
(
|
|
2988
|
+
var P, F;
|
|
2989
|
+
const C = T === 0 ? [] : [
|
|
2990
|
+
(P = f(S)[T - 1]) == null ? void 0 : P.value,
|
|
2991
2991
|
(F = f(S)[T]) == null ? void 0 : F.value
|
|
2992
2992
|
];
|
|
2993
2993
|
return Do(
|
|
2994
2994
|
T,
|
|
2995
|
-
|
|
2995
|
+
C,
|
|
2996
2996
|
o.value,
|
|
2997
2997
|
l.value
|
|
2998
2998
|
) || "";
|
|
@@ -3004,11 +3004,11 @@ const bt = 1, So = /* @__PURE__ */ H({
|
|
|
3004
3004
|
};
|
|
3005
3005
|
}
|
|
3006
3006
|
function A(T, S) {
|
|
3007
|
-
var
|
|
3008
|
-
const
|
|
3007
|
+
var P;
|
|
3008
|
+
const C = (P = f(S)[T]) == null ? void 0 : P.value;
|
|
3009
3009
|
return {
|
|
3010
3010
|
x: X(o.value) ? r.xScale(h.value[T]) + p.value : r.xScale(T),
|
|
3011
|
-
y:
|
|
3011
|
+
y: C === null ? l.value(l.value.domain()[1]) : l.value(C)
|
|
3012
3012
|
};
|
|
3013
3013
|
}
|
|
3014
3014
|
function $(T) {
|