@mx-cartographer/insights-ui 1.7.9-alpha.mega10 → 1.7.9-alpha.mega12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +48 -50
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as t, jsxs as h, Fragment as S } from "react/jsx-runtime";
|
|
2
2
|
import * as e from "react";
|
|
3
|
-
import v, { useState as
|
|
3
|
+
import v, { useState as B, useRef as G, useLayoutEffect as ie, useMemo as N, useCallback as he, useEffect as re, forwardRef as V } from "react";
|
|
4
4
|
import me from "@mui/material/Dialog";
|
|
5
|
-
import { BottomSheetTransition as pe, Icon as y, P as
|
|
5
|
+
import { BottomSheetTransition as pe, Icon as y, P as x, Text as b, InstitutionLogo as R, H3 as le, Drawer as ue, createMXTheme as Ee, MerchantLogo as fe, CategoryIcon as ge } from "@kyper/mui";
|
|
6
6
|
import xe from "react-confetti";
|
|
7
7
|
import u from "@mui/material/Box";
|
|
8
8
|
import A from "@mui/material/Card";
|
|
@@ -33,7 +33,7 @@ import Te from "@mui/icons-material/ArrowBack";
|
|
|
33
33
|
import Pe from "@mui/material/Divider";
|
|
34
34
|
import U from "@mui/material/List";
|
|
35
35
|
import Q from "@mui/material/ListItem";
|
|
36
|
-
const
|
|
36
|
+
const je = ({
|
|
37
37
|
allowScroll: i,
|
|
38
38
|
children: r,
|
|
39
39
|
height: l,
|
|
@@ -84,7 +84,7 @@ const Be = ({
|
|
|
84
84
|
children: r
|
|
85
85
|
}
|
|
86
86
|
);
|
|
87
|
-
}, mt =
|
|
87
|
+
}, mt = je, ae = ({ height: i = 0, width: r = 0, shouldRun: l = !1 }) => /* @__PURE__ */ t(
|
|
88
88
|
xe,
|
|
89
89
|
{
|
|
90
90
|
"aria-hidden": !0,
|
|
@@ -105,7 +105,7 @@ const Be = ({
|
|
|
105
105
|
style: { inset: "auto" },
|
|
106
106
|
width: r
|
|
107
107
|
}
|
|
108
|
-
),
|
|
108
|
+
), Be = ({
|
|
109
109
|
backgroundColor: i,
|
|
110
110
|
color: r,
|
|
111
111
|
percent: l,
|
|
@@ -183,7 +183,7 @@ const Be = ({
|
|
|
183
183
|
children: [
|
|
184
184
|
/* @__PURE__ */ t(y, { color: "success", fill: !0, name: "check_circle", size: 16 }),
|
|
185
185
|
/* @__PURE__ */ t(
|
|
186
|
-
|
|
186
|
+
x,
|
|
187
187
|
{
|
|
188
188
|
bold: !0,
|
|
189
189
|
className: "mx-insights-goal-progress",
|
|
@@ -196,7 +196,7 @@ const Be = ({
|
|
|
196
196
|
}
|
|
197
197
|
),
|
|
198
198
|
/* @__PURE__ */ t(
|
|
199
|
-
|
|
199
|
+
Be,
|
|
200
200
|
{
|
|
201
201
|
backgroundColor: i || o.palette.background.highlight,
|
|
202
202
|
color: a || o.palette.primary.main,
|
|
@@ -224,7 +224,7 @@ const Be = ({
|
|
|
224
224
|
},
|
|
225
225
|
children: [
|
|
226
226
|
/* @__PURE__ */ t(A, { sx: { background: "transparent", boxShadow: "none", marginBottom: 16 }, children: l && /* @__PURE__ */ t(
|
|
227
|
-
|
|
227
|
+
x,
|
|
228
228
|
{
|
|
229
229
|
className: "mx-insights-gradient-box-title",
|
|
230
230
|
"data-ui-test": "gradient-box-title",
|
|
@@ -328,8 +328,8 @@ const Be = ({
|
|
|
328
328
|
tabIndex: o = 0,
|
|
329
329
|
...d
|
|
330
330
|
}) => {
|
|
331
|
-
const [s, c] =
|
|
332
|
-
m(), n(f,
|
|
331
|
+
const [s, c] = B(null), m = () => c(null), p = (f, g) => {
|
|
332
|
+
m(), n(f, g);
|
|
333
333
|
};
|
|
334
334
|
return /* @__PURE__ */ h(S, { children: [
|
|
335
335
|
/* @__PURE__ */ t(
|
|
@@ -366,7 +366,7 @@ const Be = ({
|
|
|
366
366
|
onClose: m,
|
|
367
367
|
open: !!s,
|
|
368
368
|
transformOrigin: { horizontal: "right", vertical: "top" },
|
|
369
|
-
children: l.map(({ icon: f, key:
|
|
369
|
+
children: l.map(({ icon: f, key: g, text: k }, M) => /* @__PURE__ */ h(Ae, { onClick: () => p(M, g), sx: { padding: 12 }, children: [
|
|
370
370
|
/* @__PURE__ */ t(J, { sx: { minWidth: "32px !important" }, children: f }),
|
|
371
371
|
/* @__PURE__ */ t(
|
|
372
372
|
T,
|
|
@@ -379,7 +379,7 @@ const Be = ({
|
|
|
379
379
|
}
|
|
380
380
|
}
|
|
381
381
|
)
|
|
382
|
-
] },
|
|
382
|
+
] }, g))
|
|
383
383
|
}
|
|
384
384
|
)
|
|
385
385
|
] });
|
|
@@ -501,7 +501,7 @@ const Be = ({
|
|
|
501
501
|
selectedTabIndex: s,
|
|
502
502
|
onBarClick: c
|
|
503
503
|
}) => {
|
|
504
|
-
const m = w(), { containerRef: p, height: E, width: f } = ke(),
|
|
504
|
+
const m = w(), { containerRef: p, height: E, width: f } = ke(), g = N(() => {
|
|
505
505
|
const H = `${r}80`;
|
|
506
506
|
return s === void 0 ? [...new Array(l.length - 1).fill(H), r] : l.map((L, Z) => Z === s ? r : H);
|
|
507
507
|
}, [r, l, s]), k = he(
|
|
@@ -592,7 +592,7 @@ const Be = ({
|
|
|
592
592
|
Ue,
|
|
593
593
|
{
|
|
594
594
|
...ce,
|
|
595
|
-
colorRange:
|
|
595
|
+
colorRange: g,
|
|
596
596
|
data: l,
|
|
597
597
|
dataIndex: L.dataIndex,
|
|
598
598
|
selectedTabIndex: s || l.length - 1,
|
|
@@ -618,7 +618,7 @@ const Be = ({
|
|
|
618
618
|
)
|
|
619
619
|
] });
|
|
620
620
|
}, oe = (i) => {
|
|
621
|
-
const [r, l] =
|
|
621
|
+
const [r, l] = B({ width: 0, height: 0 });
|
|
622
622
|
return re(() => {
|
|
623
623
|
const n = () => {
|
|
624
624
|
if (i.current) {
|
|
@@ -662,8 +662,8 @@ const Be = ({
|
|
|
662
662
|
display: "flex",
|
|
663
663
|
justifyContent: "center",
|
|
664
664
|
ref: p,
|
|
665
|
-
sx: (
|
|
666
|
-
backgroundColor:
|
|
665
|
+
sx: (g) => ({
|
|
666
|
+
backgroundColor: g.palette.grey[200],
|
|
667
667
|
padding: 16
|
|
668
668
|
}),
|
|
669
669
|
width: "100%",
|
|
@@ -673,13 +673,13 @@ const Be = ({
|
|
|
673
673
|
A,
|
|
674
674
|
{
|
|
675
675
|
elevation: 1,
|
|
676
|
-
sx: (
|
|
676
|
+
sx: (g) => ({
|
|
677
677
|
display: "flex",
|
|
678
678
|
flexDirection: "column",
|
|
679
679
|
alignItems: "center",
|
|
680
680
|
justifyContent: "center",
|
|
681
681
|
flexWrap: "wrap",
|
|
682
|
-
backgroundColor:
|
|
682
|
+
backgroundColor: g.palette.background.paper,
|
|
683
683
|
borderRadius: "8px",
|
|
684
684
|
overflow: "visible",
|
|
685
685
|
minHeight: 120,
|
|
@@ -742,7 +742,7 @@ const Be = ({
|
|
|
742
742
|
)
|
|
743
743
|
}
|
|
744
744
|
),
|
|
745
|
-
/* @__PURE__ */ t(
|
|
745
|
+
/* @__PURE__ */ t(x, { bold: !0, sx: { width: "100%", textAlign: "center" }, children: r })
|
|
746
746
|
] }), $e = ({ leftLowerText: i, leftUpperText: r }) => {
|
|
747
747
|
const l = w();
|
|
748
748
|
return /* @__PURE__ */ h(
|
|
@@ -758,7 +758,7 @@ const Be = ({
|
|
|
758
758
|
},
|
|
759
759
|
children: [
|
|
760
760
|
/* @__PURE__ */ t(
|
|
761
|
-
|
|
761
|
+
x,
|
|
762
762
|
{
|
|
763
763
|
"data-ui-test": "mx-insights-sudd-left-upper-text",
|
|
764
764
|
sx: { color: l.palette.secondary.light },
|
|
@@ -766,7 +766,7 @@ const Be = ({
|
|
|
766
766
|
children: r
|
|
767
767
|
}
|
|
768
768
|
),
|
|
769
|
-
/* @__PURE__ */ t(
|
|
769
|
+
/* @__PURE__ */ t(x, { bold: !0, "data-ui-test": "mx-insights-sudd-left-lower-text", variant: "Small", children: i })
|
|
770
770
|
]
|
|
771
771
|
}
|
|
772
772
|
);
|
|
@@ -786,7 +786,7 @@ const Be = ({
|
|
|
786
786
|
width: 20
|
|
787
787
|
}
|
|
788
788
|
),
|
|
789
|
-
/* @__PURE__ */ t(
|
|
789
|
+
/* @__PURE__ */ t(x, { bold: !0, "data-ui-test": "mx-insights-sudd-mini-body-header-text", children: r })
|
|
790
790
|
]
|
|
791
791
|
}
|
|
792
792
|
), t1 = ({
|
|
@@ -808,7 +808,7 @@ const Be = ({
|
|
|
808
808
|
},
|
|
809
809
|
children: /* @__PURE__ */ h(C, { alignItems: "center", gap: 2, justifyContent: "center", children: [
|
|
810
810
|
/* @__PURE__ */ t(
|
|
811
|
-
|
|
811
|
+
x,
|
|
812
812
|
{
|
|
813
813
|
"data-ui-test": "mx-insights-sudd-right-upper-text",
|
|
814
814
|
sx: {
|
|
@@ -819,7 +819,7 @@ const Be = ({
|
|
|
819
819
|
}
|
|
820
820
|
),
|
|
821
821
|
/* @__PURE__ */ t(
|
|
822
|
-
|
|
822
|
+
x,
|
|
823
823
|
{
|
|
824
824
|
bold: !0,
|
|
825
825
|
"data-ui-test": "mx-insights-sudd-right-lower-text",
|
|
@@ -886,7 +886,7 @@ const Be = ({
|
|
|
886
886
|
},
|
|
887
887
|
children: [
|
|
888
888
|
/* @__PURE__ */ t(q, { divProps: { style: o1 }, image: r1 }),
|
|
889
|
-
/* @__PURE__ */ t(
|
|
889
|
+
/* @__PURE__ */ t(x, { color: "secondary", sx: { mx: 8, mb: 8 }, variant: "ParagraphSmall", children: i })
|
|
890
890
|
]
|
|
891
891
|
}
|
|
892
892
|
), s1 = ({
|
|
@@ -928,17 +928,15 @@ const Be = ({
|
|
|
928
928
|
)
|
|
929
929
|
}
|
|
930
930
|
), m1 = ({ content: i, isLoading: r }) => {
|
|
931
|
-
const [l, n] =
|
|
931
|
+
const [l, n] = B(0), a = G(null), o = () => {
|
|
932
932
|
if (a.current) {
|
|
933
933
|
const d = a.current, s = d.parentElement;
|
|
934
934
|
if (s) {
|
|
935
|
-
const m = Array.from(s.children).reduce((
|
|
935
|
+
const m = Array.from(s.children).reduce((k, M) => M !== d ? k + M.clientHeight : k, 0), E = s.clientHeight - m, f = parseInt(
|
|
936
936
|
window.getComputedStyle(d).lineHeight,
|
|
937
937
|
10
|
|
938
|
-
),
|
|
939
|
-
|
|
940
|
-
);
|
|
941
|
-
k !== l && n(k);
|
|
938
|
+
), g = Math.floor(E / f);
|
|
939
|
+
g !== l && n(g);
|
|
942
940
|
}
|
|
943
941
|
}
|
|
944
942
|
};
|
|
@@ -1072,7 +1070,7 @@ const Be = ({
|
|
|
1072
1070
|
},
|
|
1073
1071
|
children: [
|
|
1074
1072
|
/* @__PURE__ */ t(
|
|
1075
|
-
|
|
1073
|
+
x,
|
|
1076
1074
|
{
|
|
1077
1075
|
dangerouslySetInnerHTML: { __html: a },
|
|
1078
1076
|
sx: {
|
|
@@ -1257,7 +1255,7 @@ const Be = ({
|
|
|
1257
1255
|
]
|
|
1258
1256
|
}
|
|
1259
1257
|
);
|
|
1260
|
-
}, yt = ({ bodyText: i }) => /* @__PURE__ */ t(u, { style: { padding: "8px 24px 8px 0px" }, children: /* @__PURE__ */ t(
|
|
1258
|
+
}, yt = ({ bodyText: i }) => /* @__PURE__ */ t(u, { style: { padding: "8px 24px 8px 0px" }, children: /* @__PURE__ */ t(x, { "data-ui-test": "feedback-description", children: i }) }), Ht = ({
|
|
1261
1259
|
feedbackOptions: i,
|
|
1262
1260
|
groupAriaLabel: r,
|
|
1263
1261
|
selectedRadio: l,
|
|
@@ -1352,7 +1350,7 @@ const Be = ({
|
|
|
1352
1350
|
}
|
|
1353
1351
|
),
|
|
1354
1352
|
l && /* @__PURE__ */ t(
|
|
1355
|
-
|
|
1353
|
+
x,
|
|
1356
1354
|
{
|
|
1357
1355
|
sx: {
|
|
1358
1356
|
color: i && p.palette.error.darker,
|
|
@@ -1369,7 +1367,7 @@ const Be = ({
|
|
|
1369
1367
|
function y1() {
|
|
1370
1368
|
return /* @__PURE__ */ t(q, { divProps: { style: {} }, image: C1 });
|
|
1371
1369
|
}
|
|
1372
|
-
var
|
|
1370
|
+
var j = /* @__PURE__ */ ((i) => (i.Primary = "Primary", i.Secondary = "Secondary", i))(j || {});
|
|
1373
1371
|
const At = ({
|
|
1374
1372
|
amounts: i,
|
|
1375
1373
|
beat: r,
|
|
@@ -1392,7 +1390,7 @@ const At = ({
|
|
|
1392
1390
|
{
|
|
1393
1391
|
...l,
|
|
1394
1392
|
beat: r,
|
|
1395
|
-
onClick: (p) => l?.onClick?.(p,
|
|
1393
|
+
onClick: (p) => l?.onClick?.(p, j.Primary)
|
|
1396
1394
|
}
|
|
1397
1395
|
),
|
|
1398
1396
|
/* @__PURE__ */ t(
|
|
@@ -1400,7 +1398,7 @@ const At = ({
|
|
|
1400
1398
|
{
|
|
1401
1399
|
...l,
|
|
1402
1400
|
beat: r,
|
|
1403
|
-
onClick: (p) => l?.onClick?.(p,
|
|
1401
|
+
onClick: (p) => l?.onClick?.(p, j.Secondary),
|
|
1404
1402
|
primary: !1
|
|
1405
1403
|
}
|
|
1406
1404
|
)
|
|
@@ -1615,7 +1613,7 @@ const At = ({
|
|
|
1615
1613
|
/* @__PURE__ */ h(u, { children: [
|
|
1616
1614
|
/* @__PURE__ */ t(le, { sx: { p: "16px 24px 8px 24px", whiteSpace: "wrap" }, children: l }),
|
|
1617
1615
|
/* @__PURE__ */ h(C, { sx: { gap: 12, px: 24 }, children: [
|
|
1618
|
-
/* @__PURE__ */ t(
|
|
1616
|
+
/* @__PURE__ */ t(x, { color: "secondary", fontSize: 13, children: m }),
|
|
1619
1617
|
/* @__PURE__ */ t(U, { children: p.map((E, f) => /* @__PURE__ */ h(
|
|
1620
1618
|
Q,
|
|
1621
1619
|
{
|
|
@@ -1641,7 +1639,7 @@ const At = ({
|
|
|
1641
1639
|
{
|
|
1642
1640
|
disableTypography: !0,
|
|
1643
1641
|
secondary: E,
|
|
1644
|
-
sx: (
|
|
1642
|
+
sx: (g) => ({ color: g.palette.text.secondary, fontSize: 13 })
|
|
1645
1643
|
}
|
|
1646
1644
|
)
|
|
1647
1645
|
]
|
|
@@ -1652,14 +1650,14 @@ const At = ({
|
|
|
1652
1650
|
] }),
|
|
1653
1651
|
/* @__PURE__ */ h(u, { children: [
|
|
1654
1652
|
/* @__PURE__ */ t(b, { bold: !0, fontSize: 15, sx: { p: "16px 24px 8px 24px" }, children: o }),
|
|
1655
|
-
/* @__PURE__ */ t(
|
|
1653
|
+
/* @__PURE__ */ t(x, { color: "secondary", fontSize: 13, sx: { mb: 16, mx: 24 }, children: a }),
|
|
1656
1654
|
/* @__PURE__ */ t(U, { sx: { p: "16px 24px" }, children: d.map((E, f) => /* @__PURE__ */ h(
|
|
1657
1655
|
Q,
|
|
1658
1656
|
{
|
|
1659
|
-
sx: (
|
|
1657
|
+
sx: (g) => ({
|
|
1660
1658
|
alignItems: "flex-start",
|
|
1661
1659
|
alignSelf: "stretch",
|
|
1662
|
-
border: `1px solid ${
|
|
1660
|
+
border: `1px solid ${g.palette.border.light}`,
|
|
1663
1661
|
borderRadius: "8px",
|
|
1664
1662
|
boxShadow: "0px 2px 8px 0px rgba(106, 115, 129, 0.12)",
|
|
1665
1663
|
gap: 12,
|
|
@@ -1673,9 +1671,9 @@ const At = ({
|
|
|
1673
1671
|
{
|
|
1674
1672
|
primary: E.title,
|
|
1675
1673
|
secondary: E.content,
|
|
1676
|
-
sx: (
|
|
1674
|
+
sx: (g) => ({
|
|
1677
1675
|
"& > p": {
|
|
1678
|
-
color:
|
|
1676
|
+
color: g.palette.text.secondary,
|
|
1679
1677
|
fontSize: 13,
|
|
1680
1678
|
fontWeight: "400",
|
|
1681
1679
|
lineHeight: "20px"
|
|
@@ -1888,7 +1886,7 @@ const At = ({
|
|
|
1888
1886
|
}
|
|
1889
1887
|
),
|
|
1890
1888
|
/* @__PURE__ */ t(
|
|
1891
|
-
|
|
1889
|
+
x,
|
|
1892
1890
|
{
|
|
1893
1891
|
className: "mx-insights-sdd-account-account-name",
|
|
1894
1892
|
sx: { textAlign: "center" },
|
|
@@ -2024,7 +2022,7 @@ const At = ({
|
|
|
2024
2022
|
}
|
|
2025
2023
|
),
|
|
2026
2024
|
/* @__PURE__ */ t(
|
|
2027
|
-
|
|
2025
|
+
x,
|
|
2028
2026
|
{
|
|
2029
2027
|
bold: !0,
|
|
2030
2028
|
sx: { color: "success.main", fontSize: 18, fontWeight: 700, mt: 12 },
|
|
@@ -2032,7 +2030,7 @@ const At = ({
|
|
|
2032
2030
|
children: l
|
|
2033
2031
|
}
|
|
2034
2032
|
),
|
|
2035
|
-
/* @__PURE__ */ t(
|
|
2033
|
+
/* @__PURE__ */ t(x, { sx: { fontSize: 13, fontWeight: 400, p: 4 }, variant: "Small", children: i.primary_transaction?.description }),
|
|
2036
2034
|
/* @__PURE__ */ h(P, { alignItems: "center", direction: "row", children: [
|
|
2037
2035
|
i.primary_transaction?.top_level_category_guid && /* @__PURE__ */ t(
|
|
2038
2036
|
ge,
|
|
@@ -2044,7 +2042,7 @@ const At = ({
|
|
|
2044
2042
|
}
|
|
2045
2043
|
),
|
|
2046
2044
|
/* @__PURE__ */ t(
|
|
2047
|
-
|
|
2045
|
+
x,
|
|
2048
2046
|
{
|
|
2049
2047
|
sx: { color: "text.secondary", fontSize: 11, fontWeight: 400, ml: 8 },
|
|
2050
2048
|
variant: "XSmall",
|
|
@@ -2149,7 +2147,7 @@ export {
|
|
|
2149
2147
|
L1 as ProjectedCompletionSection,
|
|
2150
2148
|
Ye as PulseGoalProgress,
|
|
2151
2149
|
Ne as PulseGraidentBox,
|
|
2152
|
-
|
|
2150
|
+
Be as PulseProgressBar,
|
|
2153
2151
|
t1 as RightBox,
|
|
2154
2152
|
kt as SetUpDirectDepositBody,
|
|
2155
2153
|
ft as Shell,
|