@mx-cartographer/experiences 9.7.171 → 9.7.173
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/CHANGELOG.md +10 -0
- package/dist/core/types/InsightsInstanceSlotData.es.js.map +1 -1
- package/dist/insights-v2/actionBlocks/TransactionListBlock/TransactionListSubscriptionHeader.es.js +16 -18
- package/dist/insights-v2/actionBlocks/TransactionListBlock/TransactionListSubscriptionHeader.es.js.map +1 -1
- package/dist/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.d.ts +2 -2
- package/dist/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.es.js.map +1 -1
- package/dist/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/layout.es.js +7 -8
- package/dist/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/layout.es.js.map +1 -1
- package/dist/insights-v2/blocks/ComponentBlocks/MerchantBlock/MerchantBlock.es.js +43 -40
- package/dist/insights-v2/blocks/ComponentBlocks/MerchantBlock/MerchantBlock.es.js.map +1 -1
- package/dist/insights-v2/blocks/ComponentBlocks/MerchantBlock/layout.d.ts +6 -0
- package/dist/insights-v2/blocks/ComponentBlocks/MerchantBlock/layout.es.js +28 -7
- package/dist/insights-v2/blocks/ComponentBlocks/MerchantBlock/layout.es.js.map +1 -1
- package/dist/insights-v2/components/ConnectionDetailDrillDown.es.js +15 -10
- package/dist/insights-v2/components/ConnectionDetailDrillDown.es.js.map +1 -1
- package/dist/insights-v2/components/P2PLogoStack.d.ts +7 -1
- package/dist/insights-v2/components/P2PLogoStack.es.js +22 -22
- package/dist/insights-v2/components/P2PLogoStack.es.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
+
## [9.7.173] - 11-17-2026
|
|
2
|
+
|
|
3
|
+
- **FIXED** - Discovered Accounts' pending card wash is at Figma's 127° (WEC-2342)
|
|
4
|
+
- **FIXED** - The Connection Details drawer's bullets are text.secondary, with each icon on the first line of text (WEC-2342)
|
|
5
|
+
- **CHANGED** - Discovered Accounts' `account_switch_block` slots: `from_logo` is the held institution and `to_logo` the discovered one (set by ditto; experiences draws them in the same order) (WEC-2342)
|
|
6
|
+
|
|
7
|
+
## [9.7.172] - 11-17-2026
|
|
8
|
+
|
|
9
|
+
- **FIXED** - Monthly Subscription Aggregate V2: 72px bordered logos and Subscriptions drawer count tile type and icon match Figma (WEC-2298)
|
|
10
|
+
|
|
1
11
|
## [9.7.171] - 11-17-2026
|
|
2
12
|
|
|
3
13
|
- **CHANGED** - Credit Card Close to Limit's embedded card matches Figma (bold amounts, "Remains", a tighter donut), and micro card titles and notification rows use Figma's line height and logo size (WEC-2030)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InsightsInstanceSlotData.es.js","names":[],"sources":["../../../src/core/types/InsightsInstanceSlotData.ts"],"sourcesContent":["import type { DataSeries, Legends, LogoRef } from '../../core'\n\nexport interface InsightsInstanceSlotData\n extends\n Partial<BudgetBlockData>,\n Partial<DonutChartBlockData>,\n Partial<ImageBlockData>,\n Partial<AccountBlockData>,\n Partial<SaveExtraBlockData>,\n Partial<StepChartBlockData>,\n Partial<SVGImageBlockData>,\n Partial<AccountSwitchBlockData>,\n Partial<TransactionDetailsBlockData>,\n Partial<CreditUtilizationBlockData>,\n Partial<MerchantBlockData>,\n Partial<CommonProps> {}\n\n//when any of the type is used more than one times, we can use the common props\ninterface CommonProps {\n amount?: number\n ariaLabel?: string\n date?: string\n legends?: Legends[]\n category_guid?: string\n data_series?: DataSeries | DataSet[]\n transaction_guids?: string[]\n account_guids?: string[]\n primary_transaction_guid?: string\n}\n\n//BarChart Block: `instance_slot.data` (Insights 2.0)\nexport interface BarChartBlockData {\n series?: DataSeries\n category_guid?: string\n average_amount?: number\n /** [0] monthly amount, [1] trend. */\n additional_data?: Legends[]\n}\n\n//DonutChart Block: `instance_slot.data` (Insights 2.0) — the same shape V1 sent as `instance_slot_data`.\n/** The donut's centre: the total and its caption (\"$6,306\" / \"Total\"). */\nexport interface DonutChartMain {\n value: string | number\n value_type: string\n label: string\n /** The embedded donut's shorter caption (Credit Card Close to Limit: \"Remains\"). */\n compact_label?: string\n}\nexport interface DonutChartBlockData {\n main: DonutChartMain\n /** The category whose colour fills the primary slice (Cost of Living to Income: Housing). */\n category_guid?: string\n /** Legend rows beside the donut: a label, its amount and an optional share (\"$5,550.00 (88%)\"). */\n legends?: Legends[]\n}\n\n//DoubleBarChart Block\n// TODO : This has to be revisited again to update the below types based on API response once we have the final shape of the data_series for double bar chart from BE\nexport interface LegendProps extends Legends {\n amount: number\n formattedAmount: string\n label: string\n color?: string\n}\n\nexport interface DataSet extends DataSeries {\n ariaLabelComparison: string\n ariaLabelMain: string\n comparison: number\n // The comparison bar's transaction guids (data_series aggregated_guids), for the drawer filter.\n comparisonGuids?: string[]\n // The month's 'yyyy-MM-dd' date (the main row's).\n date?: string\n formattedComparison: string\n formattedMain: string\n label: string\n main: number\n // The main bar's transaction guids (data_series aggregated_guids), for the drawer filter.\n mainGuids?: string[]\n}\n\n//DoubleProgressBar Block\n\n//Image Block\nexport interface ImageBlockData {\n image: string\n}\n\n//Account Block\nexport interface AccountBlockData {\n sub_text: string\n institution_guid?: string\n institution_name?: string\n icon_name?: string\n /** Header bar text (standard card), or the colored category strip label (deposit cards). */\n header_text?: string\n // Deposit variants (Unified Deposit, Unified Deposit Emergency Fund, Savings Account Deposit)\n /** Merchant guid — renders a real merchant logo in the deposit card when present. */\n merchant_guid?: string\n /** Merchant display name — logo alt text and the payer line under the amount. */\n merchant_name?: string\n /** Secondary label beside the amount, e.g. `On {date}, you saved` or `Balance as of MM/DD/YY`. */\n label?: string\n}\n\nexport interface SaveExtraBlockData {\n /** Styled segments `[lead-in, amount digits, trailing copy]`, e.g. `['Save an extra', '100', 'to help your funds grow']`. */\n primary_text?: string[]\n /** Styled segments `[projected balance, caption]`, e.g. `['$8,313.87', 'After payday & projected expenses']`. */\n secondary_text?: string[]\n /** MakeTransfer drilldown: available balance (both variants). */\n available_balance?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: average monthly spend. */\n avg_monthly_spend?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: how long the balance lasts, overlaid on the timeline SVG (e.g. \"2 months, 11 days\"). */\n time_period?: string\n /** SAVE_AN_EXTRA_100: upcoming expenses (the \"Expenses\" figure). */\n upcoming_expenses?: number\n /** SAVE_AN_EXTRA_100: total remaining after expenses. */\n total_remaining?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: date for the \"Your available balances as of {date}\" line. */\n date?: string\n}\n\n// AccountSwitch Block. State comes from `instance_slot.variant`, not a data flag.\nexport interface AccountSwitchBlockData {\n discovered_institution_guid: string\n discovered_institution_name: string\n held_institution_guid: string\n held_institution_name: string\n}\n\n// AccountSwitch Block: `instance_slot.data` (Insights 2.0
|
|
1
|
+
{"version":3,"file":"InsightsInstanceSlotData.es.js","names":[],"sources":["../../../src/core/types/InsightsInstanceSlotData.ts"],"sourcesContent":["import type { DataSeries, Legends, LogoRef } from '../../core'\n\nexport interface InsightsInstanceSlotData\n extends\n Partial<BudgetBlockData>,\n Partial<DonutChartBlockData>,\n Partial<ImageBlockData>,\n Partial<AccountBlockData>,\n Partial<SaveExtraBlockData>,\n Partial<StepChartBlockData>,\n Partial<SVGImageBlockData>,\n Partial<AccountSwitchBlockData>,\n Partial<TransactionDetailsBlockData>,\n Partial<CreditUtilizationBlockData>,\n Partial<MerchantBlockData>,\n Partial<CommonProps> {}\n\n//when any of the type is used more than one times, we can use the common props\ninterface CommonProps {\n amount?: number\n ariaLabel?: string\n date?: string\n legends?: Legends[]\n category_guid?: string\n data_series?: DataSeries | DataSet[]\n transaction_guids?: string[]\n account_guids?: string[]\n primary_transaction_guid?: string\n}\n\n//BarChart Block: `instance_slot.data` (Insights 2.0)\nexport interface BarChartBlockData {\n series?: DataSeries\n category_guid?: string\n average_amount?: number\n /** [0] monthly amount, [1] trend. */\n additional_data?: Legends[]\n}\n\n//DonutChart Block: `instance_slot.data` (Insights 2.0) — the same shape V1 sent as `instance_slot_data`.\n/** The donut's centre: the total and its caption (\"$6,306\" / \"Total\"). */\nexport interface DonutChartMain {\n value: string | number\n value_type: string\n label: string\n /** The embedded donut's shorter caption (Credit Card Close to Limit: \"Remains\"). */\n compact_label?: string\n}\nexport interface DonutChartBlockData {\n main: DonutChartMain\n /** The category whose colour fills the primary slice (Cost of Living to Income: Housing). */\n category_guid?: string\n /** Legend rows beside the donut: a label, its amount and an optional share (\"$5,550.00 (88%)\"). */\n legends?: Legends[]\n}\n\n//DoubleBarChart Block\n// TODO : This has to be revisited again to update the below types based on API response once we have the final shape of the data_series for double bar chart from BE\nexport interface LegendProps extends Legends {\n amount: number\n formattedAmount: string\n label: string\n color?: string\n}\n\nexport interface DataSet extends DataSeries {\n ariaLabelComparison: string\n ariaLabelMain: string\n comparison: number\n // The comparison bar's transaction guids (data_series aggregated_guids), for the drawer filter.\n comparisonGuids?: string[]\n // The month's 'yyyy-MM-dd' date (the main row's).\n date?: string\n formattedComparison: string\n formattedMain: string\n label: string\n main: number\n // The main bar's transaction guids (data_series aggregated_guids), for the drawer filter.\n mainGuids?: string[]\n}\n\n//DoubleProgressBar Block\n\n//Image Block\nexport interface ImageBlockData {\n image: string\n}\n\n//Account Block\nexport interface AccountBlockData {\n sub_text: string\n institution_guid?: string\n institution_name?: string\n icon_name?: string\n /** Header bar text (standard card), or the colored category strip label (deposit cards). */\n header_text?: string\n // Deposit variants (Unified Deposit, Unified Deposit Emergency Fund, Savings Account Deposit)\n /** Merchant guid — renders a real merchant logo in the deposit card when present. */\n merchant_guid?: string\n /** Merchant display name — logo alt text and the payer line under the amount. */\n merchant_name?: string\n /** Secondary label beside the amount, e.g. `On {date}, you saved` or `Balance as of MM/DD/YY`. */\n label?: string\n}\n\nexport interface SaveExtraBlockData {\n /** Styled segments `[lead-in, amount digits, trailing copy]`, e.g. `['Save an extra', '100', 'to help your funds grow']`. */\n primary_text?: string[]\n /** Styled segments `[projected balance, caption]`, e.g. `['$8,313.87', 'After payday & projected expenses']`. */\n secondary_text?: string[]\n /** MakeTransfer drilldown: available balance (both variants). */\n available_balance?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: average monthly spend. */\n avg_monthly_spend?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: how long the balance lasts, overlaid on the timeline SVG (e.g. \"2 months, 11 days\"). */\n time_period?: string\n /** SAVE_AN_EXTRA_100: upcoming expenses (the \"Expenses\" figure). */\n upcoming_expenses?: number\n /** SAVE_AN_EXTRA_100: total remaining after expenses. */\n total_remaining?: number\n /** SAVE_ENOUGH_TO_LIVE_ON: date for the \"Your available balances as of {date}\" line. */\n date?: string\n}\n\n// AccountSwitch Block. State comes from `instance_slot.variant`, not a data flag.\nexport interface AccountSwitchBlockData {\n discovered_institution_guid: string\n discovered_institution_name: string\n held_institution_guid: string\n held_institution_name: string\n}\n\n// AccountSwitch Block: `instance_slot.data` (Insights 2.0). Discovered Accounts V2: `from_logo` the held\n// institution (absent when the user holds no FI-managed account), `to_logo` the discovered one.\n// Switch Direct Deposit: `from_logo` the external institution, `to_logo` the held one. `logo` is the\n// compact card's (micro, notification) institution.\nexport interface AccountSwitchBlockV2Data {\n from_logo?: LogoRef\n to_logo?: LogoRef\n logo?: LogoRef\n}\n\n// StepChart Block\nexport interface StepChartBlockData {\n completed_steps: number\n label_1: string\n label_2?: string\n}\n\n//Budgets Blocks\nexport enum BudgetTierType {\n LOW_BUDGET_TIER = 'LOW',\n MEDIUM_BUDGET_TIER = 'MEDIUM',\n OFF_TRACK_BUDGET_TIER = 'OFF_TRACK',\n}\n\nexport type BudgetTierValue = `${BudgetTierType}`\n\nexport interface BudgetLocalizedPayload {\n primary_text?: string\n amount_left_label?: string\n spent_label?: string\n budgeted_label?: string\n}\n\nexport interface BudgetBlockData {\n budget_percent: number\n budget_tier: BudgetTierValue\n category_guid?: string\n merchant_guid?: string\n spent_amount: number\n budgeted_amount: number\n localized_payload: BudgetLocalizedPayload\n}\n\nexport interface SVGImageBlockData {\n isCIBC?: boolean\n}\n\n// TransactionDetails Action Block\n// The drawer's subject is `InsightsPayload.primary_transaction_guid`; only action configuration\n// lives here.\nexport interface TransactionDetailsBlockData {\n /** `TopActions` member names, e.g. `['Category', 'Date', 'Memo']`. Omit for the defaults. */\n top_actions?: string[]\n /** `BottomActions` member names, e.g. `['MerchantBudget', 'HideTransaction']`. Omit for defaults. */\n bottom_actions?: string[]\n}\n\n// Credit Utilization action block. The per-card rows are the beat's `data_series` table\n// (`guid`, `label`, `amount`, `total_amount`, `percentage`), carried on `CommonProps.data_series`.\nexport interface CreditUtilizationBlockData {\n accounts_balance_sum?: number\n accounts_credit_limit_sum?: number\n credit_utilization_percentage?: number\n}\n\n// Merchant block `instance_slot.data`; `primary_text` is ditto's name.\nexport interface MerchantBlockData {\n merchant_name?: string\n logo?: LogoRef\n amount?: number\n /** Pre-localized eyebrow; ditto sends `header_text`. */\n date?: string\n header_text?: string\n status_text?: string\n logos?: LogoRef[]\n}\n"],"mappings":"AAsJA,IAAY,IAAL,0BAAA,GAAA;AACL,SAAA,EAAA,kBAAA,OACA,EAAA,qBAAA,UACA,EAAA,wBAAA;AACF,GAAA,CAAA,CAAA"}
|
package/dist/insights-v2/actionBlocks/TransactionListBlock/TransactionListSubscriptionHeader.es.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { buildDynamicCopy as c } from "../../../core/utils/Localization.es.js";
|
|
2
|
-
import { DATE_FORMATS_INTL as
|
|
3
|
-
import { getLogoElevation as
|
|
2
|
+
import { DATE_FORMATS_INTL as m, formatDate as p } from "../../../core/constants/DateFormats.es.js";
|
|
3
|
+
import { getLogoElevation as d } from "../../components/logoShadow.es.js";
|
|
4
4
|
import { TipSection as l } from "../../../insights/components/shared/ChartDrawerTemplate/TipSection.es.js";
|
|
5
|
-
import { DRAWER_TIP_ICON as
|
|
6
|
-
import { TransactionListHeaderIconTile as
|
|
5
|
+
import { DRAWER_TIP_ICON as u } from "../../components/drawerTip.es.js";
|
|
6
|
+
import { TransactionListHeaderIconTile as g } from "./TransactionListHeaderIconTile.es.js";
|
|
7
7
|
import n from "@mui/material/Stack";
|
|
8
|
-
import { Text as
|
|
8
|
+
import { H2 as x, Text as _ } from "@mxenabled/mxui";
|
|
9
9
|
import { jsx as r, jsxs as e } from "react/jsx-runtime";
|
|
10
|
-
var L = ({ header: o, copy: i, tipTitle:
|
|
11
|
-
const
|
|
10
|
+
var L = ({ header: o, copy: i, tipTitle: s }) => {
|
|
11
|
+
const a = s && i.subscriptions_tip_message ? i.subscriptions_tip_message : void 0, t = o.month && i.subscriptions_in_month ? c(i.subscriptions_in_month, p(o.month, m.MONTH_LONG)) : void 0;
|
|
12
12
|
return /* @__PURE__ */ e(n, {
|
|
13
13
|
sx: {
|
|
14
14
|
gap: 16,
|
|
@@ -21,30 +21,28 @@ var L = ({ header: o, copy: i, tipTitle: a }) => {
|
|
|
21
21
|
alignItems: "center",
|
|
22
22
|
bgcolor: "background.paper",
|
|
23
23
|
borderRadius: "8px",
|
|
24
|
-
boxShadow:
|
|
24
|
+
boxShadow: d,
|
|
25
25
|
flexDirection: "row",
|
|
26
26
|
gap: 12,
|
|
27
27
|
p: 16
|
|
28
28
|
},
|
|
29
|
-
children: [/* @__PURE__ */ r(
|
|
29
|
+
children: [/* @__PURE__ */ r(g, { name: "currency_exchange" }), /* @__PURE__ */ e(n, {
|
|
30
30
|
"aria-label": t ? `${o.count} ${t}` : String(o.count),
|
|
31
31
|
role: "group",
|
|
32
|
-
children: [/* @__PURE__ */ r(
|
|
32
|
+
children: [/* @__PURE__ */ r(x, {
|
|
33
33
|
"aria-hidden": !0,
|
|
34
|
-
bold: !0,
|
|
35
|
-
component: "p",
|
|
36
|
-
variant: "h1",
|
|
37
34
|
children: o.count
|
|
38
|
-
}), t && /* @__PURE__ */ r(
|
|
35
|
+
}), t && /* @__PURE__ */ r(_, {
|
|
39
36
|
"aria-hidden": !0,
|
|
40
37
|
color: "text.secondary",
|
|
41
|
-
|
|
38
|
+
sx: { lineHeight: "20px" },
|
|
39
|
+
variant: "body2",
|
|
42
40
|
children: t
|
|
43
41
|
})]
|
|
44
42
|
})]
|
|
45
|
-
}),
|
|
46
|
-
icon:
|
|
47
|
-
message: c(
|
|
43
|
+
}), a && /* @__PURE__ */ r(l, {
|
|
44
|
+
icon: u,
|
|
45
|
+
message: c(a, /* @__PURE__ */ r("strong", { children: s })),
|
|
48
46
|
sx: { m: 0 }
|
|
49
47
|
})]
|
|
50
48
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TransactionListSubscriptionHeader.es.js","names":[],"sources":["../../../../src/insights-v2/actionBlocks/TransactionListBlock/TransactionListSubscriptionHeader.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\n\nimport Stack from '@mui/material/Stack'\n\nimport { Text } from '@mxenabled/mxui'\n\nimport { DATE_FORMATS_INTL, formatDate } from '../../../core/constants'\nimport type { InsightsFeedCopy } from '../../../core/types/localization'\nimport { buildDynamicCopy } from '../../../core/utils/Localization'\nimport { TipSection } from '../../../insights/components/shared/ChartDrawerTemplate/TipSection'\nimport { getLogoElevation } from '../../components/logoShadow'\nimport { DRAWER_TIP_ICON } from '../../components/drawerTip'\n\nimport { TransactionListHeaderIconTile } from './TransactionListHeaderIconTile'\nimport type { SubscriptionListHeader } from './layout'\n\nexport interface TransactionListSubscriptionHeaderProps {\n header: SubscriptionListHeader\n /** The caption and tip strings the header reads. */\n copy: Pick<\n NonNullable<InsightsFeedCopy['transaction_list_block']>,\n 'subscriptions_in_month' | 'subscriptions_tip_message'\n >\n /** The bold tip label (\"Tip\"), `insights_feed.general.tip_section_title`. */\n tipTitle: string\n}\n\n/** The Subscriptions drawer's header: the count tile and the tip (Figma 1268:54330). */\nexport const TransactionListSubscriptionHeader = ({\n header,\n copy,\n tipTitle,\n}: TransactionListSubscriptionHeaderProps) => {\n // Both halves or neither: a tip without its bold label would read \": Review…\".\n const tip =\n tipTitle && copy.subscriptions_tip_message ? copy.subscriptions_tip_message : undefined\n const caption =\n header.month && copy.subscriptions_in_month\n ? (buildDynamicCopy(\n copy.subscriptions_in_month,\n formatDate(header.month, DATE_FORMATS_INTL.MONTH_LONG),\n ) as string)\n : undefined\n\n return (\n <Stack sx={{ gap: 16, px: 24, pt: 24, pb: 12 }}>\n <Stack\n sx={{\n alignItems: 'center',\n bgcolor: 'background.paper',\n borderRadius: '8px',\n boxShadow: getLogoElevation,\n flexDirection: 'row',\n gap: 12,\n p: 16,\n }}\n >\n <TransactionListHeaderIconTile name=\"currency_exchange\" />\n {/* Read as one label: \"3 Subscriptions in October\", never a bare \"3\" read twice. */}\n <Stack\n aria-label={caption ? `${header.count} ${caption}` : String(header.count)}\n role=\"group\"\n >\n <
|
|
1
|
+
{"version":3,"file":"TransactionListSubscriptionHeader.es.js","names":[],"sources":["../../../../src/insights-v2/actionBlocks/TransactionListBlock/TransactionListSubscriptionHeader.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\n\nimport Stack from '@mui/material/Stack'\n\nimport { H2, Text } from '@mxenabled/mxui'\n\nimport { DATE_FORMATS_INTL, formatDate } from '../../../core/constants'\nimport type { InsightsFeedCopy } from '../../../core/types/localization'\nimport { buildDynamicCopy } from '../../../core/utils/Localization'\nimport { TipSection } from '../../../insights/components/shared/ChartDrawerTemplate/TipSection'\nimport { getLogoElevation } from '../../components/logoShadow'\nimport { DRAWER_TIP_ICON } from '../../components/drawerTip'\n\nimport { TransactionListHeaderIconTile } from './TransactionListHeaderIconTile'\nimport type { SubscriptionListHeader } from './layout'\n\nexport interface TransactionListSubscriptionHeaderProps {\n header: SubscriptionListHeader\n /** The caption and tip strings the header reads. */\n copy: Pick<\n NonNullable<InsightsFeedCopy['transaction_list_block']>,\n 'subscriptions_in_month' | 'subscriptions_tip_message'\n >\n /** The bold tip label (\"Tip\"), `insights_feed.general.tip_section_title`. */\n tipTitle: string\n}\n\n/** The Subscriptions drawer's header: the count tile and the tip (Figma 1268:54330). */\nexport const TransactionListSubscriptionHeader = ({\n header,\n copy,\n tipTitle,\n}: TransactionListSubscriptionHeaderProps) => {\n // Both halves or neither: a tip without its bold label would read \": Review…\".\n const tip =\n tipTitle && copy.subscriptions_tip_message ? copy.subscriptions_tip_message : undefined\n const caption =\n header.month && copy.subscriptions_in_month\n ? (buildDynamicCopy(\n copy.subscriptions_in_month,\n formatDate(header.month, DATE_FORMATS_INTL.MONTH_LONG),\n ) as string)\n : undefined\n\n return (\n <Stack sx={{ gap: 16, px: 24, pt: 24, pb: 12 }}>\n <Stack\n sx={{\n alignItems: 'center',\n bgcolor: 'background.paper',\n borderRadius: '8px',\n boxShadow: getLogoElevation,\n flexDirection: 'row',\n gap: 12,\n p: 16,\n }}\n >\n <TransactionListHeaderIconTile name=\"currency_exchange\" />\n {/* Read as one label: \"3 Subscriptions in October\", never a bare \"3\" read twice. */}\n <Stack\n aria-label={caption ? `${header.count} ${caption}` : String(header.count)}\n role=\"group\"\n >\n <H2 aria-hidden={true}>{header.count}</H2>\n {caption && (\n // Figma 13/400/20: mxui body2 (13/400) at a 20px line height.\n <Text\n aria-hidden={true}\n color=\"text.secondary\"\n sx={{ lineHeight: '20px' }}\n variant=\"body2\"\n >\n {caption}\n </Text>\n )}\n </Stack>\n </Stack>\n\n {tip && (\n <TipSection\n icon={DRAWER_TIP_ICON}\n message={buildDynamicCopy(tip, <strong>{tipTitle}</strong>) as ReactNode}\n sx={{ m: 0 }}\n />\n )}\n </Stack>\n )\n}\n\nexport default TransactionListSubscriptionHeader\n"],"mappings":";;;;;;;;;AA4BA,IAAa,IAAA,CAAqC,EAChD,QAAA,GACA,MAAA,GACA,UAAA,EAAA,MAC4C;AAE5C,QAAM,IACJ,KAAY,EAAK,4BAA4B,EAAK,4BAA4B,QAC1E,IACJ,EAAO,SAAS,EAAK,yBAChB,EACC,EAAK,wBACL,EAAW,EAAO,OAAO,EAAkB,UAAU,CACvD,IACA;AAEN,SACE,gBAAA,EAAC,GAAD;AAAA,IAAO,IAAI;AAAA,MAAE,KAAK;AAAA,MAAI,IAAI;AAAA,MAAI,IAAI;AAAA,MAAI,IAAI;AAAA,IAAG;AAAA,IAA7C,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA,MACE,IAAI;AAAA,QACF,YAAY;AAAA,QACZ,SAAS;AAAA,QACT,cAAc;AAAA,QACd,WAAW;AAAA,QACX,eAAe;AAAA,QACf,KAAK;AAAA,QACL,GAAG;AAAA,MACL;AAAA,MATF,UAAA,CAWE,gBAAA,EAAC,GAAD,EAA+B,MAAK,oBAAqB,CAAA,GAEzD,gBAAA,EAAC,GAAD;AAAA,QACE,cAAY,IAAU,GAAG,EAAO,KAAA,IAAS,CAAA,KAAY,OAAO,EAAO,KAAK;AAAA,QACxE,MAAK;AAAA,QAFP,UAAA,CAIE,gBAAA,EAAC,GAAD;AAAA,UAAI,eAAa;AAAA,UAAO,UAAA,EAAO;AAAA,QAAU,CAAA,GACxC,KAEC,gBAAA,EAAC,GAAD;AAAA,UACE,eAAa;AAAA,UACb,OAAM;AAAA,UACN,IAAI,EAAE,YAAY,OAAO;AAAA,UACzB,SAAQ;AAAA,UAEP,UAAA;AAAA,QACG,CAAA,CAEH;AAAA,MACF,CAAA,CAAA;AAAA,IAEN,CAAA,GAAA,KACC,gBAAA,EAAC,GAAD;AAAA,MACE,MAAM;AAAA,MACN,SAAS,EAAiB,GAAK,gBAAA,EAAC,UAAD,EAAA,UAAS,EAAiB,CAAA,CAAC;AAAA,MAC1D,IAAI,EAAE,GAAG,EAAE;AAAA,IACZ,CAAA,CAEE;AAAA;AAEX"}
|
|
@@ -4,8 +4,8 @@ import { BlockProps } from '../../types';
|
|
|
4
4
|
* Direct Deposit. `instance_slot.variant` picks the design branch from `./layout.ts`.
|
|
5
5
|
*
|
|
6
6
|
* The logos are the `from_logo` / `to_logo` slots on `instance_slot.data`; `LogoFromGuid` draws
|
|
7
|
-
* nothing for a missing slot or a guid that is not a logo guid (
|
|
8
|
-
* holds no FI-managed account).
|
|
7
|
+
* nothing for a missing slot or a guid that is not a logo guid (Discovered Accounts has no held
|
|
8
|
+
* institution logo when the user holds no FI-managed account).
|
|
9
9
|
*/
|
|
10
10
|
declare const AccountSwitchBlock: ({ payload }: BlockProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export default AccountSwitchBlock;
|
package/dist/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.es.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccountSwitchBlock.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.tsx"],"sourcesContent":["import { useTheme } from '@mui/material/styles'\nimport { Icon } from '@mxenabled/mx-icons'\n\nimport type { AccountSwitchBlockV2Data } from '../../../../core/types/InsightsInstanceSlotData'\n\nimport LogoFromGuid from '../../../components/LogoFromGuid'\nimport TransferLogoCard from '../../../components/TransferLogoCard'\n\nimport type { BlockProps } from '../../types'\nimport { resolveVariantConfig } from '../../resolveVariantConfig'\nimport { accountSwitchVariant, getLayoutConfig } from './layout'\n\nconst LOGO_SIZE = 64\n\n/**\n * Two institution logos on a transfer track, shared by Discovered Accounts and Switch\n * Direct Deposit. `instance_slot.variant` picks the design branch from `./layout.ts`.\n *\n * The logos are the `from_logo` / `to_logo` slots on `instance_slot.data`; `LogoFromGuid` draws\n * nothing for a missing slot or a guid that is not a logo guid (
|
|
1
|
+
{"version":3,"file":"AccountSwitchBlock.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.tsx"],"sourcesContent":["import { useTheme } from '@mui/material/styles'\nimport { Icon } from '@mxenabled/mx-icons'\n\nimport type { AccountSwitchBlockV2Data } from '../../../../core/types/InsightsInstanceSlotData'\n\nimport LogoFromGuid from '../../../components/LogoFromGuid'\nimport TransferLogoCard from '../../../components/TransferLogoCard'\n\nimport type { BlockProps } from '../../types'\nimport { resolveVariantConfig } from '../../resolveVariantConfig'\nimport { accountSwitchVariant, getLayoutConfig } from './layout'\n\nconst LOGO_SIZE = 64\n\n/**\n * Two institution logos on a transfer track, shared by Discovered Accounts and Switch\n * Direct Deposit. `instance_slot.variant` picks the design branch from `./layout.ts`.\n *\n * The logos are the `from_logo` / `to_logo` slots on `instance_slot.data`; `LogoFromGuid` draws\n * nothing for a missing slot or a guid that is not a logo guid (Discovered Accounts has no held\n * institution logo when the user holds no FI-managed account).\n */\nconst AccountSwitchBlock = ({ payload }: BlockProps) => {\n const theme = useTheme()\n const { data, variant } = payload.instance_slot\n const { from_logo, to_logo } = (data ?? {}) as AccountSwitchBlockV2Data\n\n // Pending connect is the safe default: it promises nothing (no success badge, no confetti).\n const { badgeIcon, badgeIconColor, badgeIconSize, ...cardProps } = resolveVariantConfig(\n getLayoutConfig(theme),\n variant,\n accountSwitchVariant.AccountConnect,\n 'AccountSwitchBlock',\n )\n\n return (\n <TransferLogoCard\n {...cardProps}\n from={<LogoFromGuid logo={from_logo} size={LOGO_SIZE} />}\n icon={\n <Icon\n aria-hidden={true}\n name={badgeIcon}\n size={badgeIconSize}\n sx={{ color: badgeIconColor }}\n />\n }\n to={<LogoFromGuid logo={to_logo} size={LOGO_SIZE} />}\n />\n )\n}\n\nexport default AccountSwitchBlock\n"],"mappings":";;;;;;;AAYA,IAAM,IAAY,IAUZ,IAAA,CAAsB,EAAE,SAAA,EAAA,MAA0B;AACtD,QAAM,IAAQ,EAAS,GACjB,EAAE,MAAA,GAAM,SAAA,EAAA,IAAY,EAAQ,eAC5B,EAAE,WAAA,GAAW,SAAA,EAAA,IAAa,KAAQ,CAAC,GAGnC,EAAE,WAAA,GAAW,gBAAA,GAAgB,eAAA,GAAe,GAAG,EAAA,IAAc,EACjE,EAAgB,CAAK,GACrB,GACA,EAAqB,gBACrB,oBACF;AAEA,SACE,gBAAA,EAAC,GAAD;AAAA,IACE,GAAI;AAAA,IACJ,MAAM,gBAAA,EAAC,GAAD;AAAA,MAAc,MAAM;AAAA,MAAW,MAAM;AAAA,IAAY,CAAA;AAAA,IACvD,MACE,gBAAA,EAAC,GAAD;AAAA,MACE,eAAa;AAAA,MACb,MAAM;AAAA,MACN,MAAM;AAAA,MACN,IAAI,EAAE,OAAO,EAAe;AAAA,IAC7B,CAAA;AAAA,IAEH,IAAI,gBAAA,EAAC,GAAD;AAAA,MAAc,MAAM;AAAA,MAAS,MAAM;AAAA,IAAY,CAAA;AAAA,EACpD,CAAA;AAEL"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { ACCOUNT_CONNECTED_GRADIENT as
|
|
1
|
+
import { ACCOUNT_CONNECTED_GRADIENT as e, getPrimaryWashGradient as n } from "../../../components/celebrationGradients.es.js";
|
|
2
2
|
var o = {
|
|
3
3
|
AccountConnect: "account_connect",
|
|
4
4
|
AccountConnected: "account_connected",
|
|
5
5
|
SwitchDirectDeposit: "switch_direct_deposit"
|
|
6
|
-
}, r = (
|
|
7
|
-
const
|
|
8
|
-
backgroundImage:
|
|
6
|
+
}, r = (t) => {
|
|
7
|
+
const c = {
|
|
8
|
+
backgroundImage: n(t, 127),
|
|
9
9
|
bgcolor: "background.paper",
|
|
10
10
|
badgeBgColor: "common.black",
|
|
11
11
|
badgeIconColor: "common.white",
|
|
@@ -15,11 +15,11 @@ var o = {
|
|
|
15
15
|
};
|
|
16
16
|
return {
|
|
17
17
|
[o.AccountConnect]: {
|
|
18
|
-
...
|
|
18
|
+
...c,
|
|
19
19
|
badgeIcon: "link"
|
|
20
20
|
},
|
|
21
21
|
[o.AccountConnected]: {
|
|
22
|
-
backgroundImage:
|
|
22
|
+
backgroundImage: e,
|
|
23
23
|
bgcolor: "background.paper",
|
|
24
24
|
badgeBgColor: "success.main",
|
|
25
25
|
badgeIcon: "check",
|
|
@@ -30,8 +30,7 @@ var o = {
|
|
|
30
30
|
showConfetti: !0
|
|
31
31
|
},
|
|
32
32
|
[o.SwitchDirectDeposit]: {
|
|
33
|
-
...
|
|
34
|
-
backgroundImage: e(c, 127),
|
|
33
|
+
...c,
|
|
35
34
|
badgeIcon: "arrow_right_alt"
|
|
36
35
|
}
|
|
37
36
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/layout.ts"],"sourcesContent":["import type { Theme } from '@mui/material/styles'\n\nimport {\n ACCOUNT_CONNECTED_GRADIENT,\n getPrimaryWashGradient,\n} from '../../../components/celebrationGradients'\n\n/**\n * Account Switch block variants, keyed by the backend `instance_slot.variant`. All share\n * `TransferLogoCard`; only the slot surface, center badge and connector dots differ.\n *\n * - `AccountConnect` — Discovered Accounts pending: blue gradient, black link badge.\n * - `AccountConnected` — Discovered Accounts success: pink wash, confetti, check badge.\n * - `SwitchDirectDeposit` — Switch Direct Deposit pending: the same look with an arrow badge.\n * Its complete state is a different layout, served by `direct_deposit_block`.\n */\nexport const accountSwitchVariant = {\n AccountConnect: 'account_connect',\n AccountConnected: 'account_connected',\n SwitchDirectDeposit: 'switch_direct_deposit',\n} as const\n\nexport type AccountSwitchVariant = (typeof accountSwitchVariant)[keyof typeof accountSwitchVariant]\n\nexport interface AccountSwitchLayoutConfig {\n /** Slot surface color token. */\n bgcolor: string\n /** Optional gradient layered over `bgcolor`. */\n backgroundImage?: string\n /** Center badge background color token. */\n badgeBgColor: string\n /** mx-icons glyph rendered in the center badge. */\n badgeIcon: string\n /** Color token for the badge glyph. */\n badgeIconColor: string\n /** Badge glyph size in px. */\n badgeIconSize: number\n /** Connector-dot color token. */\n dotColor: string\n /** Enlarge the inner connector dots (6px vs 4px). */\n hasBigDots: boolean\n /** Confetti burst filling the slot (success states). */\n showConfetti?: boolean\n}\n\n/** Per-variant `TransferLogoCard` props (mirrors DetailedAccountBlock's `getLayoutConfig`). */\nexport const getLayoutConfig = (\n theme: Theme,\n): Record<AccountSwitchVariant, AccountSwitchLayoutConfig> => {\n // Figma's pending look, shared by Discovered Accounts and Switch Direct Deposit: the blue wash
|
|
1
|
+
{"version":3,"file":"layout.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/AccountSwitchBlock/layout.ts"],"sourcesContent":["import type { Theme } from '@mui/material/styles'\n\nimport {\n ACCOUNT_CONNECTED_GRADIENT,\n getPrimaryWashGradient,\n} from '../../../components/celebrationGradients'\n\n/**\n * Account Switch block variants, keyed by the backend `instance_slot.variant`. All share\n * `TransferLogoCard`; only the slot surface, center badge and connector dots differ.\n *\n * - `AccountConnect` — Discovered Accounts pending: blue gradient, black link badge.\n * - `AccountConnected` — Discovered Accounts success: pink wash, confetti, check badge.\n * - `SwitchDirectDeposit` — Switch Direct Deposit pending: the same look with an arrow badge.\n * Its complete state is a different layout, served by `direct_deposit_block`.\n */\nexport const accountSwitchVariant = {\n AccountConnect: 'account_connect',\n AccountConnected: 'account_connected',\n SwitchDirectDeposit: 'switch_direct_deposit',\n} as const\n\nexport type AccountSwitchVariant = (typeof accountSwitchVariant)[keyof typeof accountSwitchVariant]\n\nexport interface AccountSwitchLayoutConfig {\n /** Slot surface color token. */\n bgcolor: string\n /** Optional gradient layered over `bgcolor`. */\n backgroundImage?: string\n /** Center badge background color token. */\n badgeBgColor: string\n /** mx-icons glyph rendered in the center badge. */\n badgeIcon: string\n /** Color token for the badge glyph. */\n badgeIconColor: string\n /** Badge glyph size in px. */\n badgeIconSize: number\n /** Connector-dot color token. */\n dotColor: string\n /** Enlarge the inner connector dots (6px vs 4px). */\n hasBigDots: boolean\n /** Confetti burst filling the slot (success states). */\n showConfetti?: boolean\n}\n\n/** Per-variant `TransferLogoCard` props (mirrors DetailedAccountBlock's `getLayoutConfig`). */\nexport const getLayoutConfig = (\n theme: Theme,\n): Record<AccountSwitchVariant, AccountSwitchLayoutConfig> => {\n // Figma's pending look (1943:219166, 1941:167577), shared by Discovered Accounts and Switch Direct\n // Deposit: the blue wash, text.secondary dots with the bigger inner pair, and a black badge with a\n // 16px white glyph.\n const pending = {\n backgroundImage: getPrimaryWashGradient(theme, 127),\n bgcolor: 'background.paper',\n badgeBgColor: 'common.black',\n badgeIconColor: 'common.white',\n badgeIconSize: 16,\n dotColor: 'text.secondary',\n hasBigDots: true,\n }\n\n return {\n [accountSwitchVariant.AccountConnect]: { ...pending, badgeIcon: 'link' },\n [accountSwitchVariant.AccountConnected]: {\n backgroundImage: ACCOUNT_CONNECTED_GRADIENT,\n bgcolor: 'background.paper',\n badgeBgColor: 'success.main',\n // Figma \"Common/Check\": a bare 20px check on the solid success badge (not `check_circle`).\n badgeIcon: 'check',\n badgeIconColor: 'common.white',\n badgeIconSize: 20,\n dotColor: 'text.secondary',\n hasBigDots: true,\n showConfetti: true,\n },\n [accountSwitchVariant.SwitchDirectDeposit]: { ...pending, badgeIcon: 'arrow_right_alt' },\n }\n}\n"],"mappings":";AAgBA,IAAa,IAAuB;AAAA,EAClC,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,qBAAqB;AACvB,GA0Ba,IAAA,CACX,MAC4D;AAI5D,QAAM,IAAU;AAAA,IACd,iBAAiB,EAAuB,GAAO,GAAG;AAAA,IAClD,SAAS;AAAA,IACT,cAAc;AAAA,IACd,gBAAgB;AAAA,IAChB,eAAe;AAAA,IACf,UAAU;AAAA,IACV,YAAY;AAAA,EACd;AAEA,SAAO;AAAA,IACJ,CAAA,EAAqB,cAAA,GAAiB;AAAA,MAAE,GAAG;AAAA,MAAS,WAAW;AAAA,IAAO;AAAA,IACtE,CAAA,EAAqB,gBAAA,GAAmB;AAAA,MACvC,iBAAiB;AAAA,MACjB,SAAS;AAAA,MACT,cAAc;AAAA,MAEd,WAAW;AAAA,MACX,gBAAgB;AAAA,MAChB,eAAe;AAAA,MACf,UAAU;AAAA,MACV,YAAY;AAAA,MACZ,cAAc;AAAA,IAChB;AAAA,IACC,CAAA,EAAqB,mBAAA,GAAsB;AAAA,MAAE,GAAG;AAAA,MAAS,WAAW;AAAA,IAAkB;AAAA,EACzF;AACF"}
|
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
import { slot as n } from "../../../../core/types/Insights.es.js";
|
|
2
|
-
import { CURRENCY_FORMAT as O, formatCurrency as
|
|
3
|
-
import
|
|
4
|
-
import { resolveVariantConfig as
|
|
5
|
-
import { asLogoRef as
|
|
6
|
-
import
|
|
2
|
+
import { CURRENCY_FORMAT as O, formatCurrency as x } from "../../../../core/utils/NumberFormatting.es.js";
|
|
3
|
+
import A from "../../../components/StatusPill.es.js";
|
|
4
|
+
import { resolveVariantConfig as E } from "../../resolveVariantConfig.es.js";
|
|
5
|
+
import { asLogoRef as R, asNumber as y, asText as i, slotOrFlat as d } from "../../slotReaders.es.js";
|
|
6
|
+
import _, { isLogoGuid as z } from "../../../components/LogoFromGuid.es.js";
|
|
7
7
|
import B from "../../../components/LogoClusterCard.es.js";
|
|
8
8
|
import M from "../../../components/MerchantHighlightCard.es.js";
|
|
9
9
|
import N from "../../../components/P2PLogoStack.es.js";
|
|
10
10
|
import { MERCHANT_LAYOUT as P, merchantBlockVariant as T } from "./layout.es.js";
|
|
11
11
|
import V from "@mui/material/Stack";
|
|
12
|
-
import { Icon as
|
|
12
|
+
import { Icon as C } from "@mxenabled/mx-icons";
|
|
13
13
|
import { jsx as e } from "react/jsx-runtime";
|
|
14
|
-
var
|
|
14
|
+
var p = 64, b = 6, w = 72, F = 3, G = [
|
|
15
15
|
10,
|
|
16
16
|
20,
|
|
17
17
|
35
|
|
18
|
-
],
|
|
19
|
-
const r =
|
|
20
|
-
return r?.guid &&
|
|
21
|
-
},
|
|
18
|
+
], I = 32, g = (a) => {
|
|
19
|
+
const r = R(a);
|
|
20
|
+
return r?.guid && z(r.guid) ? r : void 0;
|
|
21
|
+
}, D = (a) => {
|
|
22
22
|
if (!Array.isArray(a)) return [];
|
|
23
23
|
const r = /* @__PURE__ */ new Map();
|
|
24
24
|
for (const t of a.map(g)) t?.guid && !r.has(t.guid) && r.set(t.guid, t);
|
|
25
25
|
return [...r.values()];
|
|
26
|
-
},
|
|
26
|
+
}, L = /* @__PURE__ */ e(C, {
|
|
27
27
|
"aria-hidden": !0,
|
|
28
28
|
"data-icon": "storefront",
|
|
29
29
|
name: "storefront",
|
|
30
|
-
size:
|
|
30
|
+
size: I,
|
|
31
31
|
sx: { color: "text.secondary" }
|
|
32
|
-
}), k = (a, r) => a.length ? a.map((t) => /* @__PURE__ */ e(
|
|
32
|
+
}), k = (a, r) => a.length ? a.map((t) => /* @__PURE__ */ e(_, {
|
|
33
33
|
logo: t,
|
|
34
34
|
size: r
|
|
35
|
-
}, t.guid)) : [
|
|
36
|
-
const { instance_slot: r } = a, { data: t } = r, o =
|
|
37
|
-
icon: /* @__PURE__ */ e(
|
|
35
|
+
}, t.guid)) : [L], ro = ({ payload: a }) => {
|
|
36
|
+
const { instance_slot: r } = a, { data: t } = r, o = E(P, r.variant, T.SingleStandard, "MerchantBlock"), u = i(d(r, "status_text")), m = o.status && u ? /* @__PURE__ */ e(A, {
|
|
37
|
+
icon: /* @__PURE__ */ e(C, {
|
|
38
38
|
"aria-hidden": !0,
|
|
39
39
|
"data-icon": "check_circle",
|
|
40
40
|
fill: !0,
|
|
@@ -42,22 +42,24 @@ var u = 64, p = 6, w = 72, z = 3, F = [
|
|
|
42
42
|
size: 16,
|
|
43
43
|
sx: { color: "success.700" }
|
|
44
44
|
}),
|
|
45
|
-
label:
|
|
45
|
+
label: u,
|
|
46
46
|
sx: o.kind === "single" ? void 0 : {
|
|
47
47
|
alignSelf: "stretch",
|
|
48
48
|
justifyContent: "center"
|
|
49
49
|
}
|
|
50
50
|
}) : void 0;
|
|
51
51
|
if (o.kind !== "single") {
|
|
52
|
-
const c =
|
|
53
|
-
|
|
52
|
+
const c = D(n(t, "logos"));
|
|
53
|
+
if (o.kind === "ranked" && c.length) return /* @__PURE__ */ e(B, {
|
|
54
54
|
background: o.background,
|
|
55
55
|
fullBleed: !0,
|
|
56
|
-
logos: k(c.slice(0,
|
|
57
|
-
overlap:
|
|
58
|
-
rankOffsets:
|
|
56
|
+
logos: k(c.slice(0, F), w),
|
|
57
|
+
overlap: b,
|
|
58
|
+
rankOffsets: G,
|
|
59
59
|
ranked: !0
|
|
60
|
-
})
|
|
60
|
+
});
|
|
61
|
+
const v = o.logo?.size ?? p;
|
|
62
|
+
return /* @__PURE__ */ e(V, {
|
|
61
63
|
sx: {
|
|
62
64
|
background: o.background,
|
|
63
65
|
bgcolor: o.background ? void 0 : o.bgcolor,
|
|
@@ -65,47 +67,48 @@ var u = 64, p = 6, w = 72, z = 3, F = [
|
|
|
65
67
|
width: "100%"
|
|
66
68
|
},
|
|
67
69
|
children: /* @__PURE__ */ e(N, {
|
|
68
|
-
borderColor: null,
|
|
69
|
-
logos: k(c,
|
|
70
|
-
|
|
70
|
+
borderColor: o.logo?.borderColor ?? null,
|
|
71
|
+
logos: k(c, v),
|
|
72
|
+
offsets: o.cascade?.offsets,
|
|
73
|
+
overlap: o.cascade?.overlap ?? b,
|
|
71
74
|
shadow: "elevation",
|
|
72
|
-
size:
|
|
73
|
-
status:
|
|
75
|
+
size: v,
|
|
76
|
+
status: m
|
|
74
77
|
})
|
|
75
78
|
});
|
|
76
79
|
}
|
|
77
80
|
const l = i(n(t, "primary_text")) || i(d(r, "merchant_name"));
|
|
78
81
|
if (!l) return null;
|
|
79
|
-
const s =
|
|
82
|
+
const s = y(d(r, "amount")), S = i(n(t, "header_text")) || i(n(t, "date")), f = g(n(t, "logo")) ?? g({
|
|
80
83
|
alt: l,
|
|
81
84
|
fallback_guid: r.category_guid,
|
|
82
85
|
guid: r.merchant_guid
|
|
83
|
-
}),
|
|
86
|
+
}), h = o.logo?.size ?? p;
|
|
84
87
|
return /* @__PURE__ */ e(M, {
|
|
85
|
-
amount: s !== void 0 && s !== 0 ?
|
|
88
|
+
amount: s !== void 0 && s !== 0 ? x(s, O.cents) : void 0,
|
|
86
89
|
amountPill: o.amountPill,
|
|
87
90
|
amountVariant: o.amountVariant,
|
|
88
91
|
background: o.background,
|
|
89
92
|
bgcolor: o.bgcolor,
|
|
90
93
|
borderColor: o.borderColor,
|
|
91
|
-
eyebrow: o.hideDate ? void 0 :
|
|
94
|
+
eyebrow: o.hideDate ? void 0 : S,
|
|
92
95
|
fullBleed: o.fullBleed,
|
|
93
96
|
gap: o.gap,
|
|
94
|
-
logo:
|
|
95
|
-
logo:
|
|
96
|
-
size:
|
|
97
|
-
}) :
|
|
97
|
+
logo: f ? /* @__PURE__ */ e(_, {
|
|
98
|
+
logo: f,
|
|
99
|
+
size: h
|
|
100
|
+
}) : L,
|
|
98
101
|
logoBorderColor: o.logo?.borderColor,
|
|
99
102
|
logoRadius: o.logo?.radius,
|
|
100
103
|
logoShadow: o.logo?.shadow,
|
|
101
|
-
logoSize:
|
|
104
|
+
logoSize: h,
|
|
102
105
|
name: l,
|
|
103
106
|
nameVariant: o.nameVariant,
|
|
104
|
-
trailing:
|
|
107
|
+
trailing: m
|
|
105
108
|
});
|
|
106
109
|
};
|
|
107
110
|
export {
|
|
108
|
-
|
|
111
|
+
ro as default
|
|
109
112
|
};
|
|
110
113
|
|
|
111
114
|
//# sourceMappingURL=MerchantBlock.es.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MerchantBlock.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/MerchantBlock/MerchantBlock.tsx"],"sourcesContent":["import Stack from '@mui/material/Stack'\n\nimport { Icon } from '@mxenabled/mx-icons'\n\nimport { slot, type InsightsPayload, type LogoRef } from '../../../../core'\nimport type { MerchantBlockData } from '../../../../core/types/InsightsInstanceSlotData'\nimport { CURRENCY_FORMAT, formatCurrency } from '../../../../core/utils/NumberFormatting'\n\nimport LogoClusterCard from '../../../components/LogoClusterCard'\nimport LogoFromGuid, { isLogoGuid } from '../../../components/LogoFromGuid'\nimport MerchantHighlightCard from '../../../components/MerchantHighlightCard'\nimport P2PLogoStack from '../../../components/P2PLogoStack'\nimport StatusPill from '../../../components/StatusPill'\nimport { resolveVariantConfig } from '../../resolveVariantConfig'\nimport { asLogoRef, asNumber, asText, slotOrFlat } from '../../slotReaders'\n\nimport { MERCHANT_LAYOUT, merchantBlockVariant } from './layout'\n\ninterface MerchantBlockProps {\n payload: InsightsPayload\n}\n\nconst LOGO_SIZE = 64\nconst LOGO_OVERLAP = 6\nconst RANKED_LOGO_SIZE = 72\nconst RANKED_MAX = 3\nconst RANKED_OFFSETS = [10, 20, 35] as const\nconst FALLBACK_ICON_SIZE = 32\n\n/** A logo ref naming a known logo guid, else undefined, so an unusable one falls through. */\nconst asMerchantLogo = (value: unknown): LogoRef | undefined => {\n const ref = asLogoRef(value)\n return ref?.guid && isLogoGuid(ref.guid) ? ref : undefined\n}\n\nconst uniqueLogos = (refs: unknown): LogoRef[] => {\n if (!Array.isArray(refs)) return []\n const byGuid = new Map<string, LogoRef>()\n for (const ref of refs.map(asMerchantLogo)) {\n if (ref?.guid && !byGuid.has(ref.guid)) byGuid.set(ref.guid, ref)\n }\n return [...byGuid.values()]\n}\n\nconst storefront = (\n <Icon\n aria-hidden={true}\n data-icon=\"storefront\"\n name=\"storefront\"\n size={FALLBACK_ICON_SIZE}\n sx={{ color: 'text.secondary' }}\n />\n)\n\nconst logoTiles = (refs: LogoRef[], size: number) =>\n refs.length\n ? refs.map((ref) => <LogoFromGuid key={ref.guid} logo={ref} size={size} />)\n : [storefront]\n\nconst MerchantBlock = ({ payload }: MerchantBlockProps) => {\n const { instance_slot } = payload\n const { data } = instance_slot\n const config = resolveVariantConfig(\n MERCHANT_LAYOUT,\n instance_slot.variant,\n merchantBlockVariant.SingleStandard,\n 'MerchantBlock',\n )\n const statusText = asText(slotOrFlat(instance_slot, 'status_text'))\n const statusPill =\n config.status && statusText ? (\n <StatusPill\n icon={\n <Icon\n aria-hidden={true}\n data-icon=\"check_circle\"\n fill={true}\n name=\"check_circle\"\n size={16}\n sx={{ color: 'success.700' }}\n />\n }\n label={statusText}\n sx={\n config.kind === 'single' ? undefined : { alignSelf: 'stretch', justifyContent: 'center' }\n }\n />\n ) : undefined\n\n if (config.kind !== 'single') {\n const logos = uniqueLogos(slot<MerchantBlockData['logos']>(data, 'logos'))\n\n if (config.kind === 'ranked' && logos.length) {\n return (\n <LogoClusterCard\n background={config.background}\n fullBleed={true}\n logos={logoTiles(logos.slice(0, RANKED_MAX), RANKED_LOGO_SIZE)}\n overlap={LOGO_OVERLAP}\n rankOffsets={RANKED_OFFSETS}\n ranked={true}\n />\n )\n }\n\n return (\n <Stack\n sx={{\n background: config.background,\n bgcolor: config.background ? undefined : config.bgcolor,\n p: 16,\n width: '100%',\n }}\n >\n <P2PLogoStack\n borderColor={null}\n logos={logoTiles(logos,
|
|
1
|
+
{"version":3,"file":"MerchantBlock.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/MerchantBlock/MerchantBlock.tsx"],"sourcesContent":["import Stack from '@mui/material/Stack'\n\nimport { Icon } from '@mxenabled/mx-icons'\n\nimport { slot, type InsightsPayload, type LogoRef } from '../../../../core'\nimport type { MerchantBlockData } from '../../../../core/types/InsightsInstanceSlotData'\nimport { CURRENCY_FORMAT, formatCurrency } from '../../../../core/utils/NumberFormatting'\n\nimport LogoClusterCard from '../../../components/LogoClusterCard'\nimport LogoFromGuid, { isLogoGuid } from '../../../components/LogoFromGuid'\nimport MerchantHighlightCard from '../../../components/MerchantHighlightCard'\nimport P2PLogoStack from '../../../components/P2PLogoStack'\nimport StatusPill from '../../../components/StatusPill'\nimport { resolveVariantConfig } from '../../resolveVariantConfig'\nimport { asLogoRef, asNumber, asText, slotOrFlat } from '../../slotReaders'\n\nimport { MERCHANT_LAYOUT, merchantBlockVariant } from './layout'\n\ninterface MerchantBlockProps {\n payload: InsightsPayload\n}\n\nconst LOGO_SIZE = 64\nconst LOGO_OVERLAP = 6\nconst RANKED_LOGO_SIZE = 72\nconst RANKED_MAX = 3\nconst RANKED_OFFSETS = [10, 20, 35] as const\nconst FALLBACK_ICON_SIZE = 32\n\n/** A logo ref naming a known logo guid, else undefined, so an unusable one falls through. */\nconst asMerchantLogo = (value: unknown): LogoRef | undefined => {\n const ref = asLogoRef(value)\n return ref?.guid && isLogoGuid(ref.guid) ? ref : undefined\n}\n\nconst uniqueLogos = (refs: unknown): LogoRef[] => {\n if (!Array.isArray(refs)) return []\n const byGuid = new Map<string, LogoRef>()\n for (const ref of refs.map(asMerchantLogo)) {\n if (ref?.guid && !byGuid.has(ref.guid)) byGuid.set(ref.guid, ref)\n }\n return [...byGuid.values()]\n}\n\nconst storefront = (\n <Icon\n aria-hidden={true}\n data-icon=\"storefront\"\n name=\"storefront\"\n size={FALLBACK_ICON_SIZE}\n sx={{ color: 'text.secondary' }}\n />\n)\n\nconst logoTiles = (refs: LogoRef[], size: number) =>\n refs.length\n ? refs.map((ref) => <LogoFromGuid key={ref.guid} logo={ref} size={size} />)\n : [storefront]\n\nconst MerchantBlock = ({ payload }: MerchantBlockProps) => {\n const { instance_slot } = payload\n const { data } = instance_slot\n const config = resolveVariantConfig(\n MERCHANT_LAYOUT,\n instance_slot.variant,\n merchantBlockVariant.SingleStandard,\n 'MerchantBlock',\n )\n const statusText = asText(slotOrFlat(instance_slot, 'status_text'))\n const statusPill =\n config.status && statusText ? (\n <StatusPill\n icon={\n <Icon\n aria-hidden={true}\n data-icon=\"check_circle\"\n fill={true}\n name=\"check_circle\"\n size={16}\n sx={{ color: 'success.700' }}\n />\n }\n label={statusText}\n sx={\n config.kind === 'single' ? undefined : { alignSelf: 'stretch', justifyContent: 'center' }\n }\n />\n ) : undefined\n\n if (config.kind !== 'single') {\n const logos = uniqueLogos(slot<MerchantBlockData['logos']>(data, 'logos'))\n\n if (config.kind === 'ranked' && logos.length) {\n return (\n <LogoClusterCard\n background={config.background}\n fullBleed={true}\n logos={logoTiles(logos.slice(0, RANKED_MAX), RANKED_LOGO_SIZE)}\n overlap={LOGO_OVERLAP}\n rankOffsets={RANKED_OFFSETS}\n ranked={true}\n />\n )\n }\n\n const cascadeSize = config.logo?.size ?? LOGO_SIZE\n\n return (\n <Stack\n sx={{\n background: config.background,\n bgcolor: config.background ? undefined : config.bgcolor,\n p: 16,\n width: '100%',\n }}\n >\n <P2PLogoStack\n borderColor={config.logo?.borderColor ?? null}\n logos={logoTiles(logos, cascadeSize)}\n offsets={config.cascade?.offsets}\n overlap={config.cascade?.overlap ?? LOGO_OVERLAP}\n shadow=\"elevation\"\n size={cascadeSize}\n status={statusPill}\n />\n </Stack>\n )\n }\n\n // ditto's slot names first.\n const merchantName =\n asText(slot(data, 'primary_text')) || asText(slotOrFlat(instance_slot, 'merchant_name'))\n if (!merchantName) return null\n\n const amount = asNumber(slotOrFlat(instance_slot, 'amount'))\n const date = asText(slot(data, 'header_text')) || asText(slot(data, 'date'))\n const logo =\n asMerchantLogo(slot<unknown>(data, 'logo')) ??\n asMerchantLogo({\n alt: merchantName,\n fallback_guid: instance_slot.category_guid,\n guid: instance_slot.merchant_guid,\n })\n const logoSize = config.logo?.size ?? LOGO_SIZE\n\n return (\n <MerchantHighlightCard\n amount={\n amount !== undefined && amount !== 0\n ? formatCurrency(amount, CURRENCY_FORMAT.cents)\n : undefined\n }\n amountPill={config.amountPill}\n amountVariant={config.amountVariant}\n background={config.background}\n bgcolor={config.bgcolor}\n borderColor={config.borderColor}\n eyebrow={config.hideDate ? undefined : date}\n fullBleed={config.fullBleed}\n gap={config.gap}\n logo={logo ? <LogoFromGuid logo={logo} size={logoSize} /> : storefront}\n logoBorderColor={config.logo?.borderColor}\n logoRadius={config.logo?.radius}\n logoShadow={config.logo?.shadow}\n logoSize={logoSize}\n name={merchantName}\n nameVariant={config.nameVariant}\n trailing={statusPill}\n />\n )\n}\n\nexport default MerchantBlock\n"],"mappings":";;;;;;;;;;;;;AAsBA,IAAM,IAAY,IACZ,IAAe,GACf,IAAmB,IACnB,IAAa,GACb,IAAiB;AAAA,EAAC;AAAA,EAAI;AAAA,EAAI;AAAE,GAC5B,IAAqB,IAGrB,IAAA,CAAkB,M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M,QAAQ;AAEtC,SACE,gBAAA,EAAC,GAAD;AAAA,IACE,QACE,MAAW,UAAa,MAAW,IAC/B,EAAe,GAAQ,EAAgB,KAAK,IAC5C;AAAA,IAEN,YAAY,EAAO;AAAA,IACnB,eAAe,EAAO;AAAA,IACtB,YAAY,EAAO;AAAA,IACnB,SAAS,EAAO;AAAA,IAChB,aAAa,EAAO;AAAA,IACpB,SAAS,EAAO,WAAW,SAAY;AAAA,IACvC,WAAW,EAAO;AAAA,IAClB,KAAK,EAAO;AAAA,IACZ,MAAM,IAAO,gBAAA,EAAC,GAAD;AAAA,MAAoB,MAAA;AAAA,MAAM,MAAM;AAAA,IAAW,CAAA,IAAI;AAAA,IAC5D,iBAAiB,EAAO,MAAM;AAAA,IAC9B,YAAY,EAAO,MAAM;AAAA,IACzB,YAAY,EAAO,MAAM;AAAA,IACf,UAAA;AAAA,IACV,MAAM;AAAA,IACN,aAAa,EAAO;AAAA,IACpB,UAAU;AAAA,EACX,CAAA;AAEL"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CascadeOffsets } from '../../../components/P2PLogoStack';
|
|
1
2
|
import { AmountPillProps } from '../../../components/AmountPill';
|
|
2
3
|
/** ditto declares only `highlight` today. */
|
|
3
4
|
export declare const merchantBlockVariant: {
|
|
@@ -33,6 +34,11 @@ export interface MerchantBlockLayoutConfig {
|
|
|
33
34
|
borderColor?: string;
|
|
34
35
|
radius?: number;
|
|
35
36
|
};
|
|
37
|
+
/** Cascade only: px the tiles overlap, and each tile's drop from the top of the row per tile count. */
|
|
38
|
+
cascade?: {
|
|
39
|
+
overlap?: number;
|
|
40
|
+
offsets?: CascadeOffsets;
|
|
41
|
+
};
|
|
36
42
|
/** Draw `status_text` in a success pill. */
|
|
37
43
|
status?: boolean;
|
|
38
44
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { WARM_LIME_ACCENT_GRADIENT as
|
|
2
|
-
var
|
|
1
|
+
import { WARM_LIME_ACCENT_GRADIENT as r, celebrateGradient as e } from "../../../components/celebrationGradients.es.js";
|
|
2
|
+
var s = {
|
|
3
3
|
Highlight: "highlight",
|
|
4
4
|
SingleStandard: "single_standard",
|
|
5
5
|
SingleSuccess: "single_success",
|
|
@@ -9,7 +9,7 @@ var r = {
|
|
|
9
9
|
MultipleSubscription: "multiple_subscription",
|
|
10
10
|
MultipleBadged: "multiple_badged"
|
|
11
11
|
}, l = { bgcolor: "secondary.lighter" }, a = {
|
|
12
|
-
background:
|
|
12
|
+
background: r,
|
|
13
13
|
status: !0
|
|
14
14
|
}, i = {
|
|
15
15
|
kind: "single",
|
|
@@ -22,7 +22,7 @@ var r = {
|
|
|
22
22
|
borderColor: "divider",
|
|
23
23
|
radius: 8
|
|
24
24
|
}
|
|
25
|
-
},
|
|
25
|
+
}, n = {
|
|
26
26
|
highlight: {
|
|
27
27
|
kind: "single",
|
|
28
28
|
amountVariant: "text",
|
|
@@ -61,7 +61,28 @@ var r = {
|
|
|
61
61
|
},
|
|
62
62
|
multiple_subscription: {
|
|
63
63
|
kind: "cascade",
|
|
64
|
-
background: e(200.73)
|
|
64
|
+
background: e(200.73),
|
|
65
|
+
cascade: {
|
|
66
|
+
overlap: 8,
|
|
67
|
+
offsets: {
|
|
68
|
+
2: [0, 34],
|
|
69
|
+
3: [
|
|
70
|
+
0,
|
|
71
|
+
17,
|
|
72
|
+
34
|
|
73
|
+
],
|
|
74
|
+
4: [
|
|
75
|
+
0,
|
|
76
|
+
11,
|
|
77
|
+
23,
|
|
78
|
+
34
|
|
79
|
+
]
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
logo: {
|
|
83
|
+
size: 72,
|
|
84
|
+
borderColor: "divider"
|
|
85
|
+
}
|
|
65
86
|
},
|
|
66
87
|
multiple_badged: {
|
|
67
88
|
kind: "ranked",
|
|
@@ -69,8 +90,8 @@ var r = {
|
|
|
69
90
|
}
|
|
70
91
|
};
|
|
71
92
|
export {
|
|
72
|
-
|
|
73
|
-
|
|
93
|
+
n as MERCHANT_LAYOUT,
|
|
94
|
+
s as merchantBlockVariant
|
|
74
95
|
};
|
|
75
96
|
|
|
76
97
|
//# sourceMappingURL=layout.es.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/MerchantBlock/layout.ts"],"sourcesContent":["import {\n celebrateGradient,\n WARM_LIME_ACCENT_GRADIENT,\n} from '../../../components/celebrationGradients'\nimport type { AmountPillProps } from '../../../components/AmountPill'\n\n/** ditto declares only `highlight` today. */\nexport const merchantBlockVariant = {\n Highlight: 'highlight',\n SingleStandard: 'single_standard',\n SingleSuccess: 'single_success',\n SingleSubscription: 'single_subscription',\n MultipleStandard: 'multiple_standard',\n MultipleSuccess: 'multiple_success',\n MultipleSubscription: 'multiple_subscription',\n MultipleBadged: 'multiple_badged',\n} as const\n\nexport type MerchantBlockVariant = (typeof merchantBlockVariant)[keyof typeof merchantBlockVariant]\n\nexport interface MerchantBlockLayoutConfig {\n /** Merchant card, logo cascade, or ranked logos. */\n kind: 'single' | 'cascade' | 'ranked'\n amountVariant?: 'pill' | 'text'\n /** The amount pill's horizontal padding and text weight. */\n amountPill?: Pick<AmountPillProps, 'px' | 'fontWeight'>\n /** Gap between the logo and the text column. */\n gap?: number\n /** The merchant name's type; the card defaults to h2 beside a pill. */\n nameVariant?: 'h2' | 'h3'\n /** A wash; replaces `bgcolor`. */\n background?: string\n bgcolor?: string\n borderColor?: string\n fullBleed?: boolean\n hideDate?: boolean\n logo?: { size?: number; shadow?: 'offset' | 'elevation'; borderColor?: string; radius?: number }\n /** Draw `status_text` in a success pill. */\n status?: boolean\n}\n\nconst STANDARD = { bgcolor: 'secondary.lighter' }\nconst SUCCESS = { background: WARM_LIME_ACCENT_GRADIENT, status: true }\n\n// Figma 14633:139111\nconst SINGLE: MerchantBlockLayoutConfig = {\n kind: 'single',\n amountVariant: 'pill',\n fullBleed: true,\n hideDate: true,\n logo: { size: 72, shadow: 'elevation', borderColor: 'divider', radius: 8 },\n}\n\nexport const MERCHANT_LAYOUT: Record<MerchantBlockVariant, MerchantBlockLayoutConfig> = {\n highlight: {\n kind: 'single',\n amountVariant: 'text',\n bgcolor: 'warning.lighter',\n borderColor: 'warning.light',\n },\n single_standard: { ...SINGLE, ...STANDARD },\n single_success: { ...SINGLE, ...SUCCESS },\n // Figma 1268:54330 (Single): 64 logo, 12 gap, h3 name, pill 2/10 at 400.\n single_subscription: {\n ...SINGLE,\n amountPill: { px: 10, fontWeight: 400 },\n background: celebrateGradient(232.03),\n gap: 12,\n logo: { ...SINGLE.logo, size: 64 },\n nameVariant: 'h3',\n },\n multiple_standard: { kind: 'cascade', ...STANDARD },\n multiple_success: { kind: 'cascade', ...SUCCESS },\n multiple_subscription: {
|
|
1
|
+
{"version":3,"file":"layout.es.js","names":[],"sources":["../../../../../src/insights-v2/blocks/ComponentBlocks/MerchantBlock/layout.ts"],"sourcesContent":["import type { CascadeOffsets } from '../../../components/P2PLogoStack'\nimport {\n celebrateGradient,\n WARM_LIME_ACCENT_GRADIENT,\n} from '../../../components/celebrationGradients'\nimport type { AmountPillProps } from '../../../components/AmountPill'\n\n/** ditto declares only `highlight` today. */\nexport const merchantBlockVariant = {\n Highlight: 'highlight',\n SingleStandard: 'single_standard',\n SingleSuccess: 'single_success',\n SingleSubscription: 'single_subscription',\n MultipleStandard: 'multiple_standard',\n MultipleSuccess: 'multiple_success',\n MultipleSubscription: 'multiple_subscription',\n MultipleBadged: 'multiple_badged',\n} as const\n\nexport type MerchantBlockVariant = (typeof merchantBlockVariant)[keyof typeof merchantBlockVariant]\n\nexport interface MerchantBlockLayoutConfig {\n /** Merchant card, logo cascade, or ranked logos. */\n kind: 'single' | 'cascade' | 'ranked'\n amountVariant?: 'pill' | 'text'\n /** The amount pill's horizontal padding and text weight. */\n amountPill?: Pick<AmountPillProps, 'px' | 'fontWeight'>\n /** Gap between the logo and the text column. */\n gap?: number\n /** The merchant name's type; the card defaults to h2 beside a pill. */\n nameVariant?: 'h2' | 'h3'\n /** A wash; replaces `bgcolor`. */\n background?: string\n bgcolor?: string\n borderColor?: string\n fullBleed?: boolean\n hideDate?: boolean\n logo?: { size?: number; shadow?: 'offset' | 'elevation'; borderColor?: string; radius?: number }\n /** Cascade only: px the tiles overlap, and each tile's drop from the top of the row per tile count. */\n cascade?: { overlap?: number; offsets?: CascadeOffsets }\n /** Draw `status_text` in a success pill. */\n status?: boolean\n}\n\nconst STANDARD = { bgcolor: 'secondary.lighter' }\nconst SUCCESS = { background: WARM_LIME_ACCENT_GRADIENT, status: true }\n\n// Figma 14633:139111\nconst SINGLE: MerchantBlockLayoutConfig = {\n kind: 'single',\n amountVariant: 'pill',\n fullBleed: true,\n hideDate: true,\n logo: { size: 72, shadow: 'elevation', borderColor: 'divider', radius: 8 },\n}\n\nexport const MERCHANT_LAYOUT: Record<MerchantBlockVariant, MerchantBlockLayoutConfig> = {\n highlight: {\n kind: 'single',\n amountVariant: 'text',\n bgcolor: 'warning.lighter',\n borderColor: 'warning.light',\n },\n single_standard: { ...SINGLE, ...STANDARD },\n single_success: { ...SINGLE, ...SUCCESS },\n // Figma 1268:54330 (Single): 64 logo, 12 gap, h3 name, pill 2/10 at 400.\n single_subscription: {\n ...SINGLE,\n amountPill: { px: 10, fontWeight: 400 },\n background: celebrateGradient(232.03),\n gap: 12,\n logo: { ...SINGLE.logo, size: 64 },\n nameVariant: 'h3',\n },\n multiple_standard: { kind: 'cascade', ...STANDARD },\n multiple_success: { kind: 'cascade', ...SUCCESS },\n // Figma 1268:54330 `Logos`: 72px tiles with a divider border, 64px apart, top/centre/bottom of 106px.\n // The 2- and 4-tile staircases (not drawn in Figma) keep the shared shape over the same 34px drop.\n multiple_subscription: {\n kind: 'cascade',\n background: celebrateGradient(200.73),\n cascade: { overlap: 8, offsets: { 2: [0, 34], 3: [0, 17, 34], 4: [0, 11, 23, 34] } },\n logo: { size: 72, borderColor: 'divider' },\n },\n multiple_badged: {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,SAAS;AAAA,MAAE,SAAS;AAAA,MAAG,SAAS;AAAA,QAAE,GAAG,CAAC,GAAG,EAAE;AAAA,QAAG,GAAG;AAAA,UAAC;AAAA,UAAG;AAAA,UAAI;AAAA,QAAE;AAAA,QAAG,GAAG;AAAA,UAAC;AAAA,UAAG;AAAA,UAAI;AAAA,UAAI;AAAA,QAAE;AAAA,MAAE;AAAA,IAAE;AAAA,IACnF,MAAM;AAAA,MAAE,MAAM;AAAA,MAAI,aAAa;AAAA,IAAU;AAAA,EAC3C;AAAA,EACA,iBAAiB;AAAA,IAAE,MAAM;AAAA,IAAU,YAAY,EAAkB,MAAM;AAAA,EAAE;AAC3E"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import i from "@mui/material/Stack";
|
|
2
|
-
import { P as a, Text as
|
|
2
|
+
import { P as a, Text as c } from "@mxenabled/mxui";
|
|
3
3
|
import { Icon as l } from "@mxenabled/mx-icons";
|
|
4
4
|
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
5
5
|
import d from "@mui/material/IconButton";
|
|
@@ -15,7 +15,7 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
15
15
|
},
|
|
16
16
|
children: [r, /* @__PURE__ */ t(i, {
|
|
17
17
|
sx: { gap: 4 },
|
|
18
|
-
children: [/* @__PURE__ */ e(
|
|
18
|
+
children: [/* @__PURE__ */ e(c, {
|
|
19
19
|
bold: !0,
|
|
20
20
|
variant: "body1",
|
|
21
21
|
children: o
|
|
@@ -55,21 +55,26 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
55
55
|
})]
|
|
56
56
|
}), /* @__PURE__ */ e(i, {
|
|
57
57
|
sx: { gap: 12 },
|
|
58
|
-
children: r.benefits.map((n,
|
|
58
|
+
children: r.benefits.map((n, s) => /* @__PURE__ */ t(i, {
|
|
59
59
|
sx: {
|
|
60
|
+
alignItems: "flex-start",
|
|
60
61
|
flexDirection: "row",
|
|
61
62
|
gap: 8
|
|
62
63
|
},
|
|
63
64
|
children: [/* @__PURE__ */ e(l, {
|
|
64
65
|
color: "success",
|
|
65
66
|
name: "check_circle",
|
|
66
|
-
size: 16
|
|
67
|
+
size: 16,
|
|
68
|
+
sx: { mt: 2 }
|
|
67
69
|
}), /* @__PURE__ */ e(a, {
|
|
68
|
-
sx: {
|
|
70
|
+
sx: {
|
|
71
|
+
color: "text.secondary",
|
|
72
|
+
fontWeight: 400
|
|
73
|
+
},
|
|
69
74
|
variant: "subtitle2",
|
|
70
75
|
children: n
|
|
71
76
|
})]
|
|
72
|
-
},
|
|
77
|
+
}, s))
|
|
73
78
|
})]
|
|
74
79
|
}),
|
|
75
80
|
/* @__PURE__ */ t(i, {
|
|
@@ -77,7 +82,7 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
77
82
|
gap: 4,
|
|
78
83
|
py: 12
|
|
79
84
|
},
|
|
80
|
-
children: [/* @__PURE__ */ e(
|
|
85
|
+
children: [/* @__PURE__ */ e(c, {
|
|
81
86
|
sx: { fontWeight: 600 },
|
|
82
87
|
variant: "body1",
|
|
83
88
|
children: r.shared_info_header_text
|
|
@@ -95,7 +100,7 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
95
100
|
py: 16,
|
|
96
101
|
gap: 24
|
|
97
102
|
},
|
|
98
|
-
children: r.shared_info_items.map((n,
|
|
103
|
+
children: r.shared_info_items.map((n, s) => /* @__PURE__ */ e(m, {
|
|
99
104
|
description: n.content,
|
|
100
105
|
icon: /* @__PURE__ */ e(l, {
|
|
101
106
|
name: n.icon_name,
|
|
@@ -103,7 +108,7 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
103
108
|
sx: { color: "text.primary" }
|
|
104
109
|
}),
|
|
105
110
|
title: n.title
|
|
106
|
-
},
|
|
111
|
+
}, s))
|
|
107
112
|
}),
|
|
108
113
|
/* @__PURE__ */ t(i, {
|
|
109
114
|
sx: {
|
|
@@ -111,7 +116,7 @@ var m = ({ icon: r, title: o, description: n }) => /* @__PURE__ */ e(h, {
|
|
|
111
116
|
gap: 12,
|
|
112
117
|
alignItems: "center"
|
|
113
118
|
},
|
|
114
|
-
children: [/* @__PURE__ */ e(
|
|
119
|
+
children: [/* @__PURE__ */ e(c, {
|
|
115
120
|
bold: !0,
|
|
116
121
|
children: r.footer_title
|
|
117
122
|
}), /* @__PURE__ */ t(i, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConnectionDetailDrillDown.es.js","names":[],"sources":["../../../src/insights-v2/components/ConnectionDetailDrillDown.tsx"],"sourcesContent":["import Card from '@mui/material/Card'\nimport CardContent from '@mui/material/CardContent'\nimport IconButton from '@mui/material/IconButton'\nimport Stack from '@mui/material/Stack'\n\nimport { Icon } from '@mxenabled/mx-icons'\nimport { P, Text } from '@mxenabled/mxui'\n\ninterface InfoItemProps {\n icon: React.ReactNode\n title: string\n description: string\n}\n\nexport interface ConnectionDetailItem {\n content: string\n icon_name: string\n title: string\n}\n\n/** Resolved strings the drilldown renders (see ConnectionDetailActionBlock). */\nexport interface ConnectionDetailContent {\n aria_label_thumbs_down: string\n aria_label_thumbs_up: string\n benefits: string[]\n description: string\n footer_title: string\n header_text: string\n shared_info_description: string\n shared_info_header_text: string\n shared_info_items: ConnectionDetailItem[]\n}\n\ninterface ConnectionDetailDrillDownProps {\n copy: ConnectionDetailContent\n /** Thumbs response — `'yes'` (up) / `'no'` (down). */\n onRespond?: (response: 'yes' | 'no') => void\n}\n\nconst InfoItem = ({ icon, title, description }: InfoItemProps) => (\n <Card variant=\"outlined\">\n <CardContent sx={{ display: 'flex', gap: 12, '&:last-child': { pb: 16 } }}>\n {icon}\n <Stack sx={{ gap: 4 }}>\n <Text bold={true} variant=\"body1\">\n {title}\n </Text>\n <P sx={{ color: 'text.secondary', fontWeight: 400 }} variant=\"subtitle2\">\n {description}\n </P>\n </Stack>\n </CardContent>\n </Card>\n)\n\n/**\n * Insights-v2 copy of the V1 `insights/components/shared/ConnectionDetailDrillDown`:\n * the connection-details education panel (benefits, shared-info cards, and a\n * thumbs was-this-helpful footer).\n *\n * Unlike V1, this is drawer CONTENT only — the `connection_detail_block`\n * registry entry supplies the drawer and its title via ActionBlockLayer.\n */\nconst ConnectionDetailDrillDown = ({ copy, onRespond }: ConnectionDetailDrillDownProps) => (\n <Stack sx={{ p: 24, bgcolor: 'background.paper' }}>\n <Stack sx={{ gap: 16, pb: 16 }}>\n <Stack sx={{ gap: 4 }}>\n <P variant=\"h3\">{copy.header_text}</P>\n\n <P sx={{ fontWeight: 400, color: 'text.secondary' }} variant=\"subtitle2\">\n {copy.description}\n </P>\n </Stack>\n\n {/* Bullet points */}\n <Stack sx={{ gap: 12 }}>\n {copy.benefits.map((text, i) => (\n <Stack key={i} sx={{ flexDirection: 'row', gap: 8 }}>\n <Icon color=\"success\" name=\"check_circle\" size={16} />\n <P sx={{ fontWeight: 400 }} variant=\"subtitle2\">\n {text}\n </P>\n </Stack>\n ))}\n </Stack>\n </Stack>\n\n {/* Info section */}\n <Stack sx={{ gap: 4, py: 12 }}>\n <Text sx={{ fontWeight: 600 }} variant=\"body1\">\n {copy.shared_info_header_text}\n </Text>\n\n <P sx={{ color: 'text.secondary', lineHeight: '20px' }} variant=\"body2\">\n {copy.shared_info_description}\n </P>\n </Stack>\n\n {/* Cards */}\n <Stack sx={{ py: 16, gap: 24 }}>\n {copy.shared_info_items.map((item, index) => (\n <InfoItem\n description={item.content}\n icon={<Icon name={item.icon_name} size={24} sx={{ color: 'text.primary' }} />}\n key={index}\n title={item.title}\n />\n ))}\n </Stack>\n\n <Stack sx={{ py: 16, gap: 12, alignItems: 'center' }}>\n <Text bold={true}>{copy.footer_title}</Text>\n <Stack sx={{ flexDirection: 'row', alignItems: 'center', gap: 24 }}>\n <IconButton aria-label={copy.aria_label_thumbs_down} onClick={() => onRespond?.('no')}>\n <Icon color=\"secondary\" name=\"thumb_down\" size={24} />\n </IconButton>\n <IconButton aria-label={copy.aria_label_thumbs_up} onClick={() => onRespond?.('yes')}>\n <Icon color=\"secondary\" name=\"thumb_up\" size={24} />\n </IconButton>\n </Stack>\n </Stack>\n </Stack>\n)\n\nexport default ConnectionDetailDrillDown\n"],"mappings":";;;;;;;AAuCA,IAAM,IAAA,CAAY,EAAE,MAAA,GAAM,OAAA,GAAO,aAAA,EAAA,MAC/B,gBAAA,EAAC,GAAD;AAAA,EAAM,SAAQ;AAAA,EACZ,UAAA,gBAAA,EAAC,GAAD;AAAA,IAAa,IAAI;AAAA,MAAE,SAAS;AAAA,MAAQ,KAAK;AAAA,MAAI,gBAAgB,EAAE,IAAI,GAAG;AAAA,IAAE;AAAA,IAAxE,UAAA,CACG,GACD,gBAAA,EAAC,GAAD;AAAA,MAAO,IAAI,EAAE,KAAK,EAAE;AAAA,MAApB,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA,QAAM,MAAM;AAAA,QAAM,SAAQ;AAAA,QACvB,UAAA;AAAA,MACG,CAAA,GACN,gBAAA,EAAC,GAAD;AAAA,QAAG,IAAI;AAAA,UAAE,OAAO;AAAA,UAAkB,YAAY;AAAA,QAAI;AAAA,QAAG,SAAQ;AAAA,QAC1D,UAAA;AAAA,MACA,CAAA,CACE;AAAA,IACI,CAAA,CAAA;AAAA;AACT,CAAA,GAWF,IAAA,CAA6B,EAAE,MAAA,GAAM,WAAA,EAAA,MACzC,gBAAA,EAAC,GAAD;AAAA,EAAO,IAAI;AAAA,IAAE,GAAG;AAAA,IAAI,SAAS;AAAA,EAAmB;AAAA,EAAhD,UAAA;AAAA,IACE,gBAAA,EAAC,GAAD;AAAA,MAAO,IAAI;AAAA,QAAE,KAAK;AAAA,QAAI,IAAI;AAAA,MAAG;AAAA,MAA7B,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA,QAAO,IAAI,EAAE,KAAK,EAAE;AAAA,QAApB,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA,UAAG,SAAQ;AAAA,UAAM,UAAA,EAAK;AAAA,QAAe,CAAA,GAErC,gBAAA,EAAC,GAAD;AAAA,UAAG,IAAI;AAAA,YAAE,YAAY;AAAA,YAAK,OAAO;AAAA,UAAiB;AAAA,UAAG,SAAQ;AAAA,UAC1D,UAAA,EAAK;AAAA,QACL,CAAA,CACE;AAAA,MAGP,CAAA,GAAA,gBAAA,EAAC,GAAD;AAAA,QAAO,IAAI,EAAE,KAAK,GAAG;AAAA,QAClB,UAAA,EAAK,SAAS,IAAA,CAAK,GAAM,
|
|
1
|
+
{"version":3,"file":"ConnectionDetailDrillDown.es.js","names":[],"sources":["../../../src/insights-v2/components/ConnectionDetailDrillDown.tsx"],"sourcesContent":["import Card from '@mui/material/Card'\nimport CardContent from '@mui/material/CardContent'\nimport IconButton from '@mui/material/IconButton'\nimport Stack from '@mui/material/Stack'\n\nimport { Icon } from '@mxenabled/mx-icons'\nimport { P, Text } from '@mxenabled/mxui'\n\ninterface InfoItemProps {\n icon: React.ReactNode\n title: string\n description: string\n}\n\nexport interface ConnectionDetailItem {\n content: string\n icon_name: string\n title: string\n}\n\n/** Resolved strings the drilldown renders (see ConnectionDetailActionBlock). */\nexport interface ConnectionDetailContent {\n aria_label_thumbs_down: string\n aria_label_thumbs_up: string\n benefits: string[]\n description: string\n footer_title: string\n header_text: string\n shared_info_description: string\n shared_info_header_text: string\n shared_info_items: ConnectionDetailItem[]\n}\n\ninterface ConnectionDetailDrillDownProps {\n copy: ConnectionDetailContent\n /** Thumbs response — `'yes'` (up) / `'no'` (down). */\n onRespond?: (response: 'yes' | 'no') => void\n}\n\nconst InfoItem = ({ icon, title, description }: InfoItemProps) => (\n <Card variant=\"outlined\">\n <CardContent sx={{ display: 'flex', gap: 12, '&:last-child': { pb: 16 } }}>\n {icon}\n <Stack sx={{ gap: 4 }}>\n <Text bold={true} variant=\"body1\">\n {title}\n </Text>\n <P sx={{ color: 'text.secondary', fontWeight: 400 }} variant=\"subtitle2\">\n {description}\n </P>\n </Stack>\n </CardContent>\n </Card>\n)\n\n/**\n * Insights-v2 copy of the V1 `insights/components/shared/ConnectionDetailDrillDown`:\n * the connection-details education panel (benefits, shared-info cards, and a\n * thumbs was-this-helpful footer).\n *\n * Unlike V1, this is drawer CONTENT only — the `connection_detail_block`\n * registry entry supplies the drawer and its title via ActionBlockLayer.\n */\nconst ConnectionDetailDrillDown = ({ copy, onRespond }: ConnectionDetailDrillDownProps) => (\n <Stack sx={{ p: 24, bgcolor: 'background.paper' }}>\n <Stack sx={{ gap: 16, pb: 16 }}>\n <Stack sx={{ gap: 4 }}>\n <P variant=\"h3\">{copy.header_text}</P>\n\n <P sx={{ fontWeight: 400, color: 'text.secondary' }} variant=\"subtitle2\">\n {copy.description}\n </P>\n </Stack>\n\n {/* Bullet points */}\n <Stack sx={{ gap: 12 }}>\n {copy.benefits.map((text, i) => (\n // Figma: the icon sits on the first line of text.\n <Stack key={i} sx={{ alignItems: 'flex-start', flexDirection: 'row', gap: 8 }}>\n <Icon color=\"success\" name=\"check_circle\" size={16} sx={{ mt: 2 }} />\n <P sx={{ color: 'text.secondary', fontWeight: 400 }} variant=\"subtitle2\">\n {text}\n </P>\n </Stack>\n ))}\n </Stack>\n </Stack>\n\n {/* Info section */}\n <Stack sx={{ gap: 4, py: 12 }}>\n <Text sx={{ fontWeight: 600 }} variant=\"body1\">\n {copy.shared_info_header_text}\n </Text>\n\n <P sx={{ color: 'text.secondary', lineHeight: '20px' }} variant=\"body2\">\n {copy.shared_info_description}\n </P>\n </Stack>\n\n {/* Cards */}\n <Stack sx={{ py: 16, gap: 24 }}>\n {copy.shared_info_items.map((item, index) => (\n <InfoItem\n description={item.content}\n icon={<Icon name={item.icon_name} size={24} sx={{ color: 'text.primary' }} />}\n key={index}\n title={item.title}\n />\n ))}\n </Stack>\n\n <Stack sx={{ py: 16, gap: 12, alignItems: 'center' }}>\n <Text bold={true}>{copy.footer_title}</Text>\n <Stack sx={{ flexDirection: 'row', alignItems: 'center', gap: 24 }}>\n <IconButton aria-label={copy.aria_label_thumbs_down} onClick={() => onRespond?.('no')}>\n <Icon color=\"secondary\" name=\"thumb_down\" size={24} />\n </IconButton>\n <IconButton aria-label={copy.aria_label_thumbs_up} onClick={() => onRespond?.('yes')}>\n <Icon color=\"secondary\" name=\"thumb_up\" size={24} />\n </IconButton>\n </Stack>\n </Stack>\n </Stack>\n)\n\nexport default ConnectionDetailDrillDown\n"],"mappings":";;;;;;;AAuCA,IAAM,IAAA,CAAY,EAAE,MAAA,GAAM,OAAA,GAAO,aAAA,EAAA,MAC/B,gBAAA,EAAC,GAAD;AAAA,EAAM,SAAQ;AAAA,EACZ,UAAA,gBAAA,EAAC,GAAD;AAAA,IAAa,IAAI;AAAA,MAAE,SAAS;AAAA,MAAQ,KAAK;AAAA,MAAI,gBAAgB,EAAE,IAAI,GAAG;AAAA,IAAE;AAAA,IAAxE,UAAA,CACG,GACD,gBAAA,EAAC,GAAD;AAAA,MAAO,IAAI,EAAE,KAAK,EAAE;AAAA,MAApB,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA,QAAM,MAAM;AAAA,QAAM,SAAQ;AAAA,QACvB,UAAA;AAAA,MACG,CAAA,GACN,gBAAA,EAAC,GAAD;AAAA,QAAG,IAAI;AAAA,UAAE,OAAO;AAAA,UAAkB,YAAY;AAAA,QAAI;AAAA,QAAG,SAAQ;AAAA,QAC1D,UAAA;AAAA,MACA,CAAA,CACE;AAAA,IACI,CAAA,CAAA;AAAA;AACT,CAAA,GAWF,IAAA,CAA6B,EAAE,MAAA,GAAM,WAAA,EAAA,MACzC,gBAAA,EAAC,GAAD;AAAA,EAAO,IAAI;AAAA,IAAE,GAAG;AAAA,IAAI,SAAS;AAAA,EAAmB;AAAA,EAAhD,UAAA;AAAA,IACE,gBAAA,EAAC,GAAD;AAAA,MAAO,IAAI;AAAA,QAAE,KAAK;AAAA,QAAI,IAAI;AAAA,MAAG;AAAA,MAA7B,UAAA,CACE,gBAAA,EAAC,GAAD;AAAA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AAAA,MACF,CAAA,CAAA;AAAA;EACF"}
|
|
@@ -16,6 +16,11 @@ interface P2PLogoStackProps {
|
|
|
16
16
|
shadow?: boolean | 'offset' | 'elevation';
|
|
17
17
|
/** Overlap px; centred, right-most tile on top. */
|
|
18
18
|
overlap?: number;
|
|
19
|
+
/**
|
|
20
|
+
* Each tile's drop from the top of the row, keyed by rendered tile count (2, 3, or 4 incl. the "+N"
|
|
21
|
+
* tile), like `MT_OFFSETS`; a count it doesn't name keeps the shared cascade.
|
|
22
|
+
*/
|
|
23
|
+
offsets?: CascadeOffsets;
|
|
19
24
|
/**
|
|
20
25
|
* Fixed height of the cascading row in px (Figma `Logos` frame: 106). Gives
|
|
21
26
|
* the staircase `mt` offsets room without collapsing.
|
|
@@ -29,10 +34,11 @@ interface P2PLogoStackProps {
|
|
|
29
34
|
status?: ReactNode;
|
|
30
35
|
sx?: SxProps;
|
|
31
36
|
}
|
|
37
|
+
export type CascadeOffsets = Partial<Record<2 | 3 | 4, number[]>>;
|
|
32
38
|
/**
|
|
33
39
|
* A cascading row of shadowed brand tiles with an optional "+N" overflow tile
|
|
34
40
|
* (Peer-to-Peer Categorization). Layout math ported locally from v1
|
|
35
41
|
* `shared/P2P/P2PMultipleCategorization`.
|
|
36
42
|
*/
|
|
37
|
-
declare const P2PLogoStack: ({ logos, borderColor, overlap, rowHeight, shadow, size, status, total, sx, }: P2PLogoStackProps) => import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
declare const P2PLogoStack: ({ logos, borderColor, offsets: offsetsOverride, overlap, rowHeight, shadow, size, status, total, sx, }: P2PLogoStackProps) => import("react/jsx-runtime").JSX.Element;
|
|
38
44
|
export default P2PLogoStack;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { Text as
|
|
4
|
-
import { jsx as
|
|
5
|
-
var
|
|
1
|
+
import b from "./LogoTile.es.js";
|
|
2
|
+
import h from "@mui/material/Stack";
|
|
3
|
+
import { Text as j } from "@mxenabled/mxui";
|
|
4
|
+
import { jsx as y, jsxs as i } from "react/jsx-runtime";
|
|
5
|
+
var C = {
|
|
6
6
|
2: [0, 36],
|
|
7
7
|
3: [
|
|
8
8
|
0,
|
|
@@ -15,49 +15,49 @@ var j = {
|
|
|
15
15
|
24,
|
|
16
16
|
36
|
|
17
17
|
]
|
|
18
|
-
},
|
|
19
|
-
const o =
|
|
20
|
-
bgcolor:
|
|
21
|
-
borderColor:
|
|
22
|
-
reserveShadowSpace: t ===
|
|
23
|
-
shadow:
|
|
24
|
-
size:
|
|
18
|
+
}, O = ({ logos: n, borderColor: m = "background.paper", offsets: f, overlap: c, rowHeight: g = 106, shadow: x = !0, size: u = 64, status: d, total: v, sx: S }) => {
|
|
19
|
+
const o = c != null, a = v ?? n.length, e = a >= 4, r = e ? n.slice(0, 3) : n.slice(0, 4), l = e ? 4 : Math.min(Math.max(r.length, 2), 3), w = f?.[l] ?? C[l], T = e ? r.length + 1 : r.length, p = (s, t, k) => /* @__PURE__ */ y(b, {
|
|
20
|
+
bgcolor: k,
|
|
21
|
+
borderColor: m,
|
|
22
|
+
reserveShadowSpace: t === T - 1,
|
|
23
|
+
shadow: x,
|
|
24
|
+
size: u,
|
|
25
25
|
sx: {
|
|
26
|
-
mt: `${
|
|
26
|
+
mt: `${w?.[t] ?? 0}px`,
|
|
27
27
|
...o && {
|
|
28
|
-
ml: t ? `-${
|
|
28
|
+
ml: t ? `-${c}px` : 0,
|
|
29
29
|
position: "relative",
|
|
30
30
|
zIndex: t + 1
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
|
-
children:
|
|
33
|
+
children: s
|
|
34
34
|
}, t);
|
|
35
|
-
return /* @__PURE__ */
|
|
35
|
+
return /* @__PURE__ */ i(h, {
|
|
36
36
|
sx: {
|
|
37
37
|
gap: 12,
|
|
38
38
|
width: "100%",
|
|
39
|
-
...
|
|
39
|
+
...S
|
|
40
40
|
},
|
|
41
|
-
children: [/* @__PURE__ */
|
|
41
|
+
children: [/* @__PURE__ */ i(h, {
|
|
42
42
|
sx: {
|
|
43
43
|
flexDirection: "row",
|
|
44
44
|
gap: o ? 0 : e ? 8 : 24,
|
|
45
|
-
height:
|
|
45
|
+
height: g,
|
|
46
46
|
isolation: o ? "isolate" : void 0,
|
|
47
47
|
justifyContent: o || !e ? "center" : "flex-start"
|
|
48
48
|
},
|
|
49
|
-
children: [r.map((
|
|
49
|
+
children: [r.map((s, t) => p(s, t, "background.paper")), e && p(/* @__PURE__ */ i(j, {
|
|
50
50
|
"aria-label": `+${a - 3} more`,
|
|
51
51
|
component: "span",
|
|
52
52
|
sx: { color: "common.white" },
|
|
53
53
|
variant: "h3",
|
|
54
54
|
children: ["+", a - 3]
|
|
55
55
|
}), 3, "grey.800")]
|
|
56
|
-
}),
|
|
56
|
+
}), d]
|
|
57
57
|
});
|
|
58
58
|
};
|
|
59
59
|
export {
|
|
60
|
-
|
|
60
|
+
O as default
|
|
61
61
|
};
|
|
62
62
|
|
|
63
63
|
//# sourceMappingURL=P2PLogoStack.es.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"P2PLogoStack.es.js","names":[],"sources":["../../../src/insights-v2/components/P2PLogoStack.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\n\nimport Stack from '@mui/material/Stack'\nimport type { SxProps } from '@mui/material/styles'\n\nimport { Text } from '@mxenabled/mxui'\n\nimport LogoTile from './LogoTile'\n\ninterface P2PLogoStackProps {\n /** Brand/merchant logo visuals (rendered as shadowed, cascading tiles). */\n logos: ReactNode[]\n /**\n * Total number of merchants. When it exceeds the rendered logos, the last\n * tile becomes a \"+N\" more indicator. Defaults to `logos.length`.\n */\n total?: number\n /** Tile border token; `null` draws none. */\n borderColor?: string | null\n /** Logo tile size in px (Figma: 64). */\n size?: number\n /** Tile shadow (see `LogoTile`). Default offset. */\n shadow?: boolean | 'offset' | 'elevation'\n /** Overlap px; centred, right-most tile on top. */\n overlap?: number\n /**\n * Fixed height of the cascading row in px (Figma `Logos` frame: 106). Gives\n * the staircase `mt` offsets room without collapsing.\n */\n rowHeight?: number\n /**\n * Optional status element rendered below the logos (Figma: the full-width\n * \"Categorized\" `<StatusPill>` in P2P's categorized state). Pass a\n * `<StatusPill sx={{ alignSelf: 'stretch', justifyContent: 'center' }} />`.\n */\n status?: ReactNode\n sx?: SxProps\n}\n\n// Vertical offsets that produce the diagonal cascade, keyed by tile count.\n// Mirrors the shared P2PMultipleCategorization layout.\nconst MT_OFFSETS: Record<
|
|
1
|
+
{"version":3,"file":"P2PLogoStack.es.js","names":[],"sources":["../../../src/insights-v2/components/P2PLogoStack.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\n\nimport Stack from '@mui/material/Stack'\nimport type { SxProps } from '@mui/material/styles'\n\nimport { Text } from '@mxenabled/mxui'\n\nimport LogoTile from './LogoTile'\n\ninterface P2PLogoStackProps {\n /** Brand/merchant logo visuals (rendered as shadowed, cascading tiles). */\n logos: ReactNode[]\n /**\n * Total number of merchants. When it exceeds the rendered logos, the last\n * tile becomes a \"+N\" more indicator. Defaults to `logos.length`.\n */\n total?: number\n /** Tile border token; `null` draws none. */\n borderColor?: string | null\n /** Logo tile size in px (Figma: 64). */\n size?: number\n /** Tile shadow (see `LogoTile`). Default offset. */\n shadow?: boolean | 'offset' | 'elevation'\n /** Overlap px; centred, right-most tile on top. */\n overlap?: number\n /**\n * Each tile's drop from the top of the row, keyed by rendered tile count (2, 3, or 4 incl. the \"+N\"\n * tile), like `MT_OFFSETS`; a count it doesn't name keeps the shared cascade.\n */\n offsets?: CascadeOffsets\n /**\n * Fixed height of the cascading row in px (Figma `Logos` frame: 106). Gives\n * the staircase `mt` offsets room without collapsing.\n */\n rowHeight?: number\n /**\n * Optional status element rendered below the logos (Figma: the full-width\n * \"Categorized\" `<StatusPill>` in P2P's categorized state). Pass a\n * `<StatusPill sx={{ alignSelf: 'stretch', justifyContent: 'center' }} />`.\n */\n status?: ReactNode\n sx?: SxProps\n}\n\nexport type CascadeOffsets = Partial<Record<2 | 3 | 4, number[]>>\n\n// Vertical offsets that produce the diagonal cascade, keyed by tile count.\n// Mirrors the shared P2PMultipleCategorization layout.\nconst MT_OFFSETS: Record<2 | 3 | 4, number[]> = {\n 2: [0, 36],\n 3: [0, 18, 36],\n 4: [0, 12, 24, 36],\n}\n\n/**\n * A cascading row of shadowed brand tiles with an optional \"+N\" overflow tile\n * (Peer-to-Peer Categorization). Layout math ported locally from v1\n * `shared/P2P/P2PMultipleCategorization`.\n */\nconst P2PLogoStack = ({\n logos,\n borderColor = 'background.paper',\n offsets: offsetsOverride,\n overlap,\n rowHeight = 106,\n shadow = true,\n size = 64,\n status,\n total,\n sx,\n}: P2PLogoStackProps) => {\n const overlapping = overlap != null\n const merchantCount = total ?? logos.length\n // At 4+ merchants Figma shows 3 logos + a \"+N\" overflow tile (so exactly 4\n // renders as 3 + \"+1\"); below 4, all logos show. Mirrors v1.\n const hasOverflow = merchantCount >= 4\n const tiles = hasOverflow ? logos.slice(0, 3) : logos.slice(0, 4)\n const offsetKey = (hasOverflow ? 4 : Math.min(Math.max(tiles.length, 2), 3)) as 2 | 3 | 4\n const offsets = offsetsOverride?.[offsetKey] ?? MT_OFFSETS[offsetKey]\n // Total tiles actually rendered (logos, or 3 logos + the \"+N\" tile).\n const tileCount = hasOverflow ? tiles.length + 1 : tiles.length\n\n // The offset shadow takes no layout space, so interior tiles' shadows fall in\n // the row `gap`; only the LAST tile reserves its shadow footprint, else it\n // overlaps the card padding. (Index key is fine: the list is static.)\n const renderTile = (content: ReactNode, index: number, bgcolor: string) => (\n <LogoTile\n // eslint-disable-next-line react/no-array-index-key\n key={index}\n bgcolor={bgcolor}\n borderColor={borderColor}\n reserveShadowSpace={index === tileCount - 1}\n shadow={shadow}\n size={size}\n sx={{\n mt: `${offsets?.[index] ?? 0}px`,\n ...(overlapping && {\n ml: index ? `-${overlap}px` : 0,\n position: 'relative',\n zIndex: index + 1,\n }),\n }}\n >\n {content}\n </LogoTile>\n )\n\n return (\n <Stack sx={{ gap: 12, width: '100%', ...sx }}>\n {/* Fixed-height row gives the `mt` staircase room to cascade. */}\n <Stack\n sx={{\n flexDirection: 'row',\n gap: overlapping ? 0 : hasOverflow ? 8 : 24,\n height: rowHeight,\n // Contain the overlap z-indexes.\n isolation: overlapping ? 'isolate' : undefined,\n justifyContent: overlapping || !hasOverflow ? 'center' : 'flex-start',\n }}\n >\n {tiles.map((logo, index) => renderTile(logo, index, 'background.paper'))}\n {hasOverflow &&\n renderTile(\n // h3-sized span, not a semantic heading, inside a decorative tile.\n <Text\n aria-label={`+${merchantCount - 3} more`}\n component=\"span\"\n sx={{ color: 'common.white' }}\n variant=\"h3\"\n >\n +{merchantCount - 3}\n </Text>,\n 3,\n 'grey.800',\n )}\n </Stack>\n {status}\n </Stack>\n )\n}\n\nexport default P2PLogoStack\n"],"mappings":";;;;AAgDA,IAAM,IAA0C;AAAA,EAC9C,GAAG,CAAC,GAAG,EAAE;AAAA,EACT,GAAG;AAAA,IAAC;AAAA,IAAG;AAAA,IAAI;AAAA,EAAE;AAAA,EACb,GAAG;AAAA,IAAC;AAAA,IAAG;AAAA,IAAI;AAAA,IAAI;AAAA,EAAE;AACnB,GAOM,IAAA,CAAgB,EACpB,OAAA,GACA,aAAA,IAAc,oBACd,SAAS,GACT,SAAA,GACA,WAAA,IAAY,KACZ,QAAA,IAAS,IACT,MAAA,IAAO,IACP,QAAA,GACA,OAAA,GACA,IAAA,EAAA,MACuB;AACvB,QAAM,IAAc,KAAW,MACzB,IAAgB,KAAS,EAAM,QAG/B,IAAc,KAAiB,GAC/B,IAAQ,IAAc,EAAM,MAAM,GAAG,CAAC,IAAI,EAAM,MAAM,GAAG,CAAC,GAC1D,IAAa,IAAc,IAAI,KAAK,IAAI,KAAK,IAAI,EAAM,QAAQ,CAAC,GAAG,CAAC,GACpE,IAAU,IAAkB,CAAA,KAAc,EAAW,CAAA,GAErD,IAAY,IAAc,EAAM,SAAS,IAAI,EAAM,QAKnD,IAAA,C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