@mx-cartographer/experiences 9.6.13 → 9.6.14
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 +13 -0
- package/dist/common/components/CurrencyDialog.d.ts +6 -1
- package/dist/common/components/CurrencyDialog.es.js +24 -23
- package/dist/common/components/CurrencyDialog.es.js.map +1 -1
- package/dist/insights-v2/actionBlocks/ActionBlockLayer.es.js +3 -3
- package/dist/insights-v2/actionBlocks/AmountInputModalBlock/AmountInputModalBlock.es.js +64 -59
- package/dist/insights-v2/actionBlocks/AmountInputModalBlock/AmountInputModalBlock.es.js.map +1 -1
- package/dist/insights-v2/actionBlocks/ConnectWidgetActionBlock.es.js +17 -11
- package/dist/insights-v2/actionBlocks/ConnectWidgetActionBlock.es.js.map +1 -1
- package/dist/insights-v2/actionBlocks/TransactionHistoryBlock/TransactionHistoryBlock.es.js +63 -57
- package/dist/insights-v2/actionBlocks/TransactionHistoryBlock/TransactionHistoryBlock.es.js.map +1 -1
- package/dist/insights-v2/analytics/analyticsEventsConfig.d.ts +67 -0
- package/dist/insights-v2/analytics/analyticsEventsConfig.es.js +59 -0
- package/dist/insights-v2/analytics/analyticsEventsConfig.es.js.map +1 -0
- package/dist/insights-v2/analytics/index.d.ts +3 -0
- package/dist/insights-v2/analytics/resolveAnalyticsEvent.d.ts +5 -0
- package/dist/insights-v2/analytics/resolveAnalyticsEvent.es.js +19 -0
- package/dist/insights-v2/analytics/resolveAnalyticsEvent.es.js.map +1 -0
- package/dist/insights-v2/analytics/useAnalyticsEvent.d.ts +3 -0
- package/dist/insights-v2/analytics/useAnalyticsEvent.es.js +20 -0
- package/dist/insights-v2/analytics/useAnalyticsEvent.es.js.map +1 -0
- package/dist/insights-v2/beatActions.d.ts +18 -13
- package/dist/insights-v2/beatActions.es.js.map +1 -1
- package/dist/insights-v2/blocks/ChartBlocks/BarchartBlock/BarchartBlock.es.js +24 -22
- package/dist/insights-v2/blocks/ChartBlocks/BarchartBlock/BarchartBlock.es.js.map +1 -1
- package/dist/insights-v2/components/BaseLayout.es.js +89 -79
- package/dist/insights-v2/components/BaseLayout.es.js.map +1 -1
- package/dist/insights-v2/ctaActions/ctaHandlers.d.ts +1 -6
- package/dist/insights-v2/ctaActions/ctaHandlers.es.js.map +1 -1
- package/dist/insights-v2/ctaActions/index.d.ts +1 -1
- package/dist/insights-v2/ctaActions/runCtaAction.d.ts +20 -5
- package/dist/insights-v2/ctaActions/runCtaAction.es.js +63 -41
- package/dist/insights-v2/ctaActions/runCtaAction.es.js.map +1 -1
- package/dist/insights-v2/ctaActions/types.d.ts +6 -5
- package/dist/insights-v2/index.es.js +84 -84
- package/dist/insights-v2/mappings/blocks.es.js +2 -2
- package/package.json +1 -1
|
@@ -1,40 +1,58 @@
|
|
|
1
|
-
import { sendBeatCta as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import { sendBeatCta as m } from "../../common/utils/PostMessage.es.js";
|
|
2
|
+
import { ANALYTICS_EVENTS_CONFIG as n } from "../analytics/analyticsEventsConfig.es.js";
|
|
3
|
+
import { resolveAnalyticsEvent as f } from "../analytics/resolveAnalyticsEvent.es.js";
|
|
4
|
+
import { HOST_ACTIONS as v } from "./hostActions.es.js";
|
|
5
|
+
import { ctaActions as _ } from "./ctaConfig.es.js";
|
|
6
|
+
import { ctaHandlers as A } from "./ctaHandlers.es.js";
|
|
7
|
+
import { resolveCtaMetadata as E } from "./ctaPostMessages.es.js";
|
|
8
|
+
import { hasDrawerBlock as S } from "../mappings/hasDrawerBlock.es.js";
|
|
9
|
+
var y = {}, c = ({ cta: t }) => t.action_key && _[t.action_key] || y, B = (t) => {
|
|
10
|
+
const a = c(t);
|
|
9
11
|
return { disabled: t.stores.insightsV2Store.ctaStatus[t.beat.guid] === "pending" || (a.disabledWhen?.(t) ?? !1) };
|
|
10
|
-
},
|
|
12
|
+
}, l = ({ beat: t, slot: a, stores: r }) => {
|
|
11
13
|
r.insightsV2Store.openCtaDrawer(t.guid, a === "primary" ? "primaryCta" : "secondaryCta");
|
|
12
14
|
}, h = ({ beat: t, stores: a }, r) => {
|
|
13
|
-
const { is_mobile_webview: e, clientConfig: s } = a.appDataStore.appConfig, { event: i, action:
|
|
14
|
-
|
|
15
|
+
const { is_mobile_webview: e, clientConfig: s } = a.appDataStore.appConfig, { event: i, action: u, payload: C } = r;
|
|
16
|
+
m(t, {
|
|
15
17
|
event: i ?? void 0,
|
|
16
|
-
op:
|
|
17
|
-
extras:
|
|
18
|
+
op: u ?? void 0,
|
|
19
|
+
extras: C ?? void 0,
|
|
18
20
|
isMobileWebview: e,
|
|
19
21
|
webviewScheme: s?.master?.ui_message_webview_url_scheme,
|
|
20
22
|
userGuid: t.insights_payload?.user_guid ?? t.user_guid
|
|
21
23
|
});
|
|
22
|
-
},
|
|
23
|
-
|
|
24
|
-
},
|
|
24
|
+
}, g = (t) => {
|
|
25
|
+
S(t.cta.block) && l(t);
|
|
26
|
+
}, w = (t, { beat: a, stores: r }) => {
|
|
25
27
|
t === "refreshBeat" && r.emitUpdate({ staleBeatGuid: a.guid });
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
28
|
+
}, o = (t, a) => {
|
|
29
|
+
try {
|
|
30
|
+
t.hostActions.onAnalyticsEvent?.(f(a, t.beat));
|
|
31
|
+
} catch (r) {
|
|
32
|
+
t.stores.captureException(r, {
|
|
33
|
+
store: "ctaActions",
|
|
34
|
+
template: t.beat.template,
|
|
35
|
+
handler: "sendCtaAnalytics"
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
}, k = (t) => {
|
|
39
|
+
const { beat: a, slot: r, hostActions: e, stores: s } = t;
|
|
40
|
+
r !== "primary" || a.cta_clicked_at || (o(t, n.FIRST_TIME_PRIMARY_ACTION_SELECTED), Promise.resolve().then(() => e.onCtaAction?.({
|
|
41
|
+
beatGuid: a.guid,
|
|
42
|
+
name: v.markCtaClicked
|
|
43
|
+
})).catch((i) => s.captureException(i, {
|
|
44
|
+
store: "ctaActions",
|
|
45
|
+
template: a.template,
|
|
46
|
+
handler: "markCtaClicked"
|
|
47
|
+
})));
|
|
48
|
+
}, T = (t, { skipCtaClicked: a = !1 } = {}) => {
|
|
49
|
+
o(t, t.slot === "primary" ? n.PRIMARY_ACTION_SELECTED : n.SECONDARY_ACTION_SELECTED), a || k(t);
|
|
50
|
+
}, p = async (t, a, r) => {
|
|
51
|
+
const e = A[a];
|
|
34
52
|
if (!e) throw new Error(`Unknown CTA handler "${a}"`);
|
|
35
53
|
await e(t);
|
|
36
|
-
for (const s of r)
|
|
37
|
-
},
|
|
54
|
+
for (const s of r) w(s, t);
|
|
55
|
+
}, d = async ({ beat: t, stores: a }, r, e = {}) => {
|
|
38
56
|
const { insightsV2Store: s } = a;
|
|
39
57
|
s.setCtaStatus(t.guid, "pending");
|
|
40
58
|
try {
|
|
@@ -46,37 +64,41 @@ var w = {}, o = ({ cta: t }) => t.action_key && m[t.action_key] || w, H = (t) =>
|
|
|
46
64
|
...e
|
|
47
65
|
}), !1;
|
|
48
66
|
}
|
|
49
|
-
},
|
|
50
|
-
const a =
|
|
67
|
+
}, F = async (t) => {
|
|
68
|
+
const a = c(t), r = typeof a.params == "function" ? a.params(t) : a.params, e = {
|
|
51
69
|
...t,
|
|
52
70
|
params: {
|
|
53
71
|
...r,
|
|
54
72
|
...t.params
|
|
55
73
|
}
|
|
56
74
|
};
|
|
57
|
-
a.skipCtaClicked
|
|
58
|
-
a.run && await
|
|
59
|
-
const s =
|
|
75
|
+
T(e, { skipCtaClicked: a.skipCtaClicked }), await d(e, async () => {
|
|
76
|
+
a.run && await p(e, a.run, a.onSuccess ?? []), a.analytics && o(e, a.analytics);
|
|
77
|
+
const s = E(e);
|
|
60
78
|
s && h(e, s);
|
|
61
79
|
const i = a.next ?? (a.run ? "none" : "default");
|
|
62
|
-
i === "default" ?
|
|
80
|
+
i === "default" ? g(e) : i === "drawer" && l(e);
|
|
63
81
|
});
|
|
64
|
-
},
|
|
82
|
+
}, b = {
|
|
65
83
|
label: "",
|
|
66
84
|
block: ""
|
|
67
|
-
},
|
|
68
|
-
const
|
|
85
|
+
}, G = (t, a, { onSuccess: r = [], analytics: e } = {}) => {
|
|
86
|
+
const s = {
|
|
69
87
|
...t,
|
|
70
|
-
cta:
|
|
88
|
+
cta: b,
|
|
71
89
|
slot: "primary"
|
|
72
90
|
};
|
|
73
|
-
return
|
|
91
|
+
return d(s, async () => {
|
|
92
|
+
await p(s, a, r), e && o(s, e);
|
|
93
|
+
}, { handler: a });
|
|
74
94
|
};
|
|
75
95
|
export {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
96
|
+
T as reportCtaClick,
|
|
97
|
+
B as resolveCtaState,
|
|
98
|
+
c as resolveStep,
|
|
99
|
+
F as runCtaAction,
|
|
100
|
+
G as runCtaHandler,
|
|
101
|
+
o as sendCtaAnalytics
|
|
80
102
|
};
|
|
81
103
|
|
|
82
104
|
//# sourceMappingURL=runCtaAction.es.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runCtaAction.es.js","names":[],"sources":["../../../src/insights-v2/ctaActions/runCtaAction.ts"],"sourcesContent":["import { sendBeatCta } from '../../common/utils/PostMessage'\nimport { hasDrawerBlock } from '../mappings/hasDrawerBlock'\nimport { ctaActions } from './ctaConfig'\nimport { resolveCtaMetadata } from './ctaPostMessages'\nimport { ctaHandlers, type CtaHandlerName } from './ctaHandlers'\nimport { HOST_ACTIONS } from './hostActions'\nimport type { CtaPostMessageMetadata } from '../../core'\nimport type {\n CtaContext,\n CtaEffect,\n CtaHandler,\n CtaHandlerContext,\n CtaState,\n CtaStateContext,\n CtaStep,\n RunHandlerOptions,\n} from './types'\n\nconst DEFAULT_STEP: CtaStep = {}\n\n// ─── Resolution ─────────────────────────────────────────────────────────────\n\n/** The beat's own context (input a block collected for it), `{}` until something is written. */\nexport const beatContextOf = ({ beat, stores }: Pick<CtaStateContext, 'beat' | 'stores'>) =>\n stores.insightsV2Store.beatContext[beat.guid] ?? {}\n\n/** The step named by the CTA's `action_key`, or the empty default (no key / unknown key). */\nexport const resolveStep = ({ cta }: Pick<CtaStateContext, 'cta'>): CtaStep =>\n (cta.action_key && ctaActions[cta.action_key]) || DEFAULT_STEP\n\n/** Pending always disables; the step's `disabledWhen` may add to that. */\nexport const resolveCtaState = (ctx: CtaStateContext): CtaState => {\n const step = resolveStep(ctx)\n const pending = ctx.stores.insightsV2Store.ctaStatus[ctx.beat.guid] === 'pending'\n\n return { disabled: pending || (step.disabledWhen?.(ctx) ?? false) }\n}\n\n// ─── Targets and effects ────────────────────────────────────────────────────\n\n/** Opens the beat's drawer for whichever slot triggered the current step. */\nconst openDrawerForSlot = ({\n beat,\n slot,\n stores,\n}: Pick<CtaContext, 'beat' | 'slot' | 'stores'>) => {\n stores.insightsV2Store.openCtaDrawer(\n beat.guid,\n slot === 'primary' ? 'primaryCta' : 'secondaryCta',\n )\n}\n\n/**\n * Posts this CTA's resolved message (event, op and beat-specific payload, from the backend's\n * `cta.metadata` or the template's `ctaPostMessages` entry) to the host.\n */\nconst postCtaMessage = ({ beat, stores }: CtaContext, metadata: CtaPostMessageMetadata) => {\n const { is_mobile_webview, clientConfig } = stores.appDataStore.appConfig\n const { event, action, payload } = metadata\n\n sendBeatCta(beat, {\n event: event ?? undefined,\n op: action ?? undefined,\n extras: payload ?? undefined,\n isMobileWebview: is_mobile_webview,\n webviewScheme: clientConfig?.master?.ui_message_webview_url_scheme,\n userGuid: beat.insights_payload?.user_guid ?? beat.user_guid,\n })\n}\n\n/**\n * Default target: open the drawer for a real block, otherwise nothing. A post message is never\n * implied by a missing block; it is sent only when one resolves (see runCtaAction).\n */\nconst runDefaultTarget = (ctx: CtaContext) => {\n if (hasDrawerBlock(ctx.cta.block)) openDrawerForSlot(ctx)\n}\n\nconst runEffect = (effect: CtaEffect, { beat, stores }: CtaContext) => {\n switch (effect) {\n case 'refreshBeat':\n stores.emitUpdate({ staleBeatGuid: beat.guid })\n break\n }\n}\n\n/**\n * First primary click records `cta_clicked_at` through the host. Fire-and-forget: whatever the\n * host does (reject, throw, return nothing) must never fail the user's action.\n */\nconst markCtaClicked = ({ beat, slot, hostActions }: CtaContext) => {\n if (slot !== 'primary' || beat.cta_clicked_at) return\n\n // Wrapping the call in `.then` turns a synchronous throw into a rejection, and the `.catch`\n // swallows both: a failed cta_clicked_at write is not the user's action.\n Promise.resolve()\n .then(() =>\n hostActions.onCtaAction?.({ beatGuid: beat.guid, name: HOST_ACTIONS.markCtaClicked }),\n )\n .catch(() => {})\n}\n\n// ─── Shared bookkeeping ─────────────────────────────────────────────────────\n\n/** Runs a named handler, then its `onSuccess` effects. Shared by card CTAs and drawer saves. */\nconst runHandlerWithEffects = async (\n ctx: CtaContext,\n handlerName: CtaHandlerName,\n onSuccess: CtaEffect[],\n): Promise<void> => {\n // Names are typed, but the map is still indexed defensively: config can come from anywhere.\n const handler = (ctaHandlers as Record<string, CtaHandler>)[handlerName]\n\n if (!handler) throw new Error(`Unknown CTA handler \"${handlerName}\"`)\n\n await handler(ctx)\n\n for (const effect of onSuccess) runEffect(effect, ctx)\n}\n\n/** Per-beat status around `work`: `pending` -> `done` | `error` (+ captureException). */\nconst withCtaStatus = async (\n { beat, stores }: Pick<CtaContext, 'beat' | 'stores'>,\n work: () => Promise<void>,\n captureContext: Record<string, string> = {},\n): Promise<boolean> => {\n const { insightsV2Store } = stores\n\n insightsV2Store.setCtaStatus(beat.guid, 'pending')\n\n try {\n await work()\n insightsV2Store.setCtaStatus(beat.guid, 'done')\n\n return true\n } catch (error) {\n insightsV2Store.setCtaStatus(beat.guid, 'error')\n stores.captureException(error, {\n store: 'ctaActions',\n template: beat.template,\n ...captureContext,\n })\n\n return false\n }\n}\n\n// ─── Entry points ───────────────────────────────────────────────────────────\n\n/**\n * Runs the CTA's step: `run` handler, `onSuccess` effects, the CTA's post message if one resolves\n * (backend `cta.metadata` or the template's `ctaPostMessages` entry; skipped when the handler\n * throws), then the `next` target. No resolved message = no post.\n */\nexport const runCtaAction = async (ctx: CtaContext): Promise<void> => {\n const step = resolveStep(ctx)\n const stepParams = typeof step.params === 'function' ? step.params(ctx) : step.params\n const stepCtx: CtaContext = { ...ctx, params: { ...stepParams, ...ctx.params } }\n\n if (!step.skipCtaClicked) markCtaClicked(stepCtx)\n\n await withCtaStatus(stepCtx, async () => {\n if (step.run) await runHandlerWithEffects(stepCtx, step.run, step.onSuccess ?? [])\n\n const metadata = resolveCtaMetadata(stepCtx)\n\n if (metadata) postCtaMessage(stepCtx, metadata)\n\n const target = step.next ?? (step.run ? 'none' : 'default')\n\n if (target === 'default') runDefaultTarget(stepCtx)\n else if (target === 'drawer') openDrawerForSlot(stepCtx)\n })\n}\n\n/** Placeholder CTA for handlers run from inside a drawer, where no card slot is involved. */\nconst DIRECT_CTA = { label: '', block: '' }\n\n/** Runs a handler directly (drawer Save buttons): same bookkeeping as a card CTA. True on success. */\nexport const runCtaHandler = (\n ctx: CtaHandlerContext,\n handlerName: CtaHandlerName,\n { onSuccess = [] }: RunHandlerOptions = {},\n): Promise<boolean> => {\n const fullCtx: CtaContext = { ...ctx, cta: DIRECT_CTA, slot: 'primary' }\n\n return withCtaStatus(fullCtx, () => runHandlerWithEffects(fullCtx, handlerName, onSuccess), {\n handler: handlerName,\n })\n}\n"],"mappings":";;;;;;AAkBA,IAAM,IAAwB,CAAC,GASlB,IAAA,CAAe,EAAE,KAAA,EAAA,MAC3B,EAAI,cAAc,EAAW,EAAI,UAAA,KAAgB,GAGvC,IAAA,CAAmB,MAAmC;AACjE,QAAM,IAAO,EAAY,CAAG;AAG5B,SAAO,EAAE,UAFO,EAAI,OAAO,gBAAgB,UAAU,EAAI,KAAK,IAAA,MAAU,cAEzC,EAAK,eAAe,CAAG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K,KAAK;AAAA,IAAY,MAAM;AAAA,EAAU;AAEvE,SAAO,EAAc,GAAA,MAAe,EAAsB,GAAS,GAAa,CAAS,GAAG,EAC1F,SAAS,EACX,CAAC;AACH"}
|
|
1
|
+
{"version":3,"file":"runCtaAction.es.js","names":[],"sources":["../../../src/insights-v2/ctaActions/runCtaAction.ts"],"sourcesContent":["import { sendBeatCta } from '../../common/utils/PostMessage'\nimport {\n ANALYTICS_EVENTS_CONFIG,\n type AnalyticsEventConfigEntry,\n} from '../analytics/analyticsEventsConfig'\nimport { resolveAnalyticsEvent } from '../analytics/resolveAnalyticsEvent'\nimport { hasDrawerBlock } from '../mappings/hasDrawerBlock'\nimport { ctaActions } from './ctaConfig'\nimport { resolveCtaMetadata } from './ctaPostMessages'\nimport { ctaHandlers, type CtaHandlerName } from './ctaHandlers'\nimport { HOST_ACTIONS } from './hostActions'\nimport type { CtaPostMessageMetadata } from '../../core'\nimport type {\n CtaContext,\n CtaEffect,\n CtaHandler,\n CtaHandlerContext,\n CtaState,\n CtaStateContext,\n CtaStep,\n RunHandlerOptions,\n} from './types'\n\nconst DEFAULT_STEP: CtaStep = {}\n\n// ─── Resolution ─────────────────────────────────────────────────────────────\n\n/** The beat's own context (input a block collected for it), `{}` until something is written. */\nexport const beatContextOf = ({ beat, stores }: Pick<CtaStateContext, 'beat' | 'stores'>) =>\n stores.insightsV2Store.beatContext[beat.guid] ?? {}\n\n/** The step named by the CTA's `action_key`, or the empty default (no key / unknown key). */\nexport const resolveStep = ({ cta }: Pick<CtaStateContext, 'cta'>): CtaStep =>\n (cta.action_key && ctaActions[cta.action_key]) || DEFAULT_STEP\n\n/** Pending always disables; the step's `disabledWhen` may add to that. */\nexport const resolveCtaState = (ctx: CtaStateContext): CtaState => {\n const step = resolveStep(ctx)\n const pending = ctx.stores.insightsV2Store.ctaStatus[ctx.beat.guid] === 'pending'\n\n return { disabled: pending || (step.disabledWhen?.(ctx) ?? false) }\n}\n\n// ─── Targets and effects ────────────────────────────────────────────────────\n\n/** Opens the beat's drawer for whichever slot triggered the current step. */\nconst openDrawerForSlot = ({\n beat,\n slot,\n stores,\n}: Pick<CtaContext, 'beat' | 'slot' | 'stores'>) => {\n stores.insightsV2Store.openCtaDrawer(\n beat.guid,\n slot === 'primary' ? 'primaryCta' : 'secondaryCta',\n )\n}\n\n/**\n * Posts this CTA's resolved message (event, op and beat-specific payload, from the backend's\n * `cta.metadata` or the template's `ctaPostMessages` entry) to the host.\n */\nconst postCtaMessage = ({ beat, stores }: CtaContext, metadata: CtaPostMessageMetadata) => {\n const { is_mobile_webview, clientConfig } = stores.appDataStore.appConfig\n const { event, action, payload } = metadata\n\n sendBeatCta(beat, {\n event: event ?? undefined,\n op: action ?? undefined,\n extras: payload ?? undefined,\n isMobileWebview: is_mobile_webview,\n webviewScheme: clientConfig?.master?.ui_message_webview_url_scheme,\n userGuid: beat.insights_payload?.user_guid ?? beat.user_guid,\n })\n}\n\n/**\n * Default target: open the drawer for a real block, otherwise nothing. A post message is never\n * implied by a missing block; it is sent only when one resolves (see runCtaAction).\n */\nconst runDefaultTarget = (ctx: CtaContext) => {\n if (hasDrawerBlock(ctx.cta.block)) openDrawerForSlot(ctx)\n}\n\nconst runEffect = (effect: CtaEffect, { beat, stores }: CtaContext) => {\n switch (effect) {\n case 'refreshBeat':\n stores.emitUpdate({ staleBeatGuid: beat.guid })\n break\n }\n}\n\ntype AnalyticsCtx = Pick<CtaContext, 'beat' | 'stores' | 'hostActions'>\n\n/**\n * The one way to fire a catalogued analytics event. Takes the catalogue entry itself (e.g.\n * `ANALYTICS_EVENTS_CONFIG.PRIMARY_ACTION_SELECTED`), not a lookup key — the call site already\n * has the entry via property access, so there is no key to look up or mistype. Resolves the\n * payload and hands it to the host directly. Never throws: a failed fire is captured, it\n * cannot fail or disable anything.\n */\nexport const sendCtaAnalytics = (ctx: AnalyticsCtx, event: AnalyticsEventConfigEntry): void => {\n try {\n ctx.hostActions.onAnalyticsEvent?.(resolveAnalyticsEvent(event, ctx.beat))\n } catch (error) {\n ctx.stores.captureException(error, {\n store: 'ctaActions',\n template: ctx.beat.template,\n handler: 'sendCtaAnalytics',\n })\n }\n}\n\n// First primary click: fires FIRST_TIME_PRIMARY_ACTION_SELECTED and records cta_clicked_at.\nconst markCtaClicked = (ctx: AnalyticsCtx & Pick<CtaContext, 'slot'>): void => {\n const { beat, slot, hostActions, stores } = ctx\n\n if (slot !== 'primary' || beat.cta_clicked_at) return\n\n sendCtaAnalytics(ctx, ANALYTICS_EVENTS_CONFIG.FIRST_TIME_PRIMARY_ACTION_SELECTED)\n\n // Fire-and-forget; a failed write must not fail the user's action, but still report it.\n Promise.resolve()\n .then(() =>\n hostActions.onCtaAction?.({ beatGuid: beat.guid, name: HOST_ACTIONS.markCtaClicked }),\n )\n .catch((error) =>\n stores.captureException(error, {\n store: 'ctaActions',\n template: beat.template,\n handler: 'markCtaClicked',\n }),\n )\n}\n\n/**\n * Trigger 1 + the first-click bookkeeping together: every CTA press's generic analytics\n * (`Primary/Secondary Action Selected`), plus `FIRST_TIME_PRIMARY_ACTION_SELECTED` /\n * `cta_clicked_at` on the first primary press. The one call site for \"a CTA got pressed\",\n * used by the runner and by the contact-support bypass in `BaseLayout`.\n */\nexport const reportCtaClick = (\n ctx: AnalyticsCtx & Pick<CtaContext, 'slot'>,\n { skipCtaClicked = false }: { skipCtaClicked?: boolean } = {},\n): void => {\n sendCtaAnalytics(\n ctx,\n ctx.slot === 'primary'\n ? ANALYTICS_EVENTS_CONFIG.PRIMARY_ACTION_SELECTED\n : ANALYTICS_EVENTS_CONFIG.SECONDARY_ACTION_SELECTED,\n )\n\n if (!skipCtaClicked) markCtaClicked(ctx)\n}\n\n// ─── Shared bookkeeping ─────────────────────────────────────────────────────\n\n/** Runs a named handler, then its `onSuccess` effects. Shared by card CTAs and drawer saves. */\nconst runHandlerWithEffects = async (\n ctx: CtaContext,\n handlerName: CtaHandlerName,\n onSuccess: CtaEffect[],\n): Promise<void> => {\n // Names are typed, but the map is still indexed defensively: config can come from anywhere.\n const handler = (ctaHandlers as Record<string, CtaHandler>)[handlerName]\n\n if (!handler) throw new Error(`Unknown CTA handler \"${handlerName}\"`)\n\n await handler(ctx)\n\n for (const effect of onSuccess) runEffect(effect, ctx)\n}\n\n/** Per-beat status around `work`: `pending` -> `done` | `error` (+ captureException). */\nconst withCtaStatus = async (\n { beat, stores }: Pick<CtaContext, 'beat' | 'stores'>,\n work: () => Promise<void>,\n captureContext: Record<string, string> = {},\n): Promise<boolean> => {\n const { insightsV2Store } = stores\n\n insightsV2Store.setCtaStatus(beat.guid, 'pending')\n\n try {\n await work()\n insightsV2Store.setCtaStatus(beat.guid, 'done')\n\n return true\n } catch (error) {\n insightsV2Store.setCtaStatus(beat.guid, 'error')\n stores.captureException(error, {\n store: 'ctaActions',\n template: beat.template,\n ...captureContext,\n })\n\n return false\n }\n}\n\n// ─── Entry points ───────────────────────────────────────────────────────────\n\n// Runs the CTA's step: handler, onSuccess effects, post message, then the next target.\nexport const runCtaAction = async (ctx: CtaContext): Promise<void> => {\n const step = resolveStep(ctx)\n const stepParams = typeof step.params === 'function' ? step.params(ctx) : step.params\n const stepCtx: CtaContext = { ...ctx, params: { ...stepParams, ...ctx.params } }\n\n reportCtaClick(stepCtx, { skipCtaClicked: step.skipCtaClicked })\n\n await withCtaStatus(stepCtx, async () => {\n if (step.run) await runHandlerWithEffects(stepCtx, step.run, step.onSuccess ?? [])\n\n // For future ctaConfig entries; none define `analytics` yet.\n if (step.analytics) sendCtaAnalytics(stepCtx, step.analytics)\n\n const metadata = resolveCtaMetadata(stepCtx)\n\n if (metadata) postCtaMessage(stepCtx, metadata)\n\n const target = step.next ?? (step.run ? 'none' : 'default')\n\n if (target === 'default') runDefaultTarget(stepCtx)\n else if (target === 'drawer') openDrawerForSlot(stepCtx)\n })\n}\n\n/** Placeholder CTA for handlers run from inside a drawer, where no card slot is involved. */\nconst DIRECT_CTA = { label: '', block: '' }\n\n/** Runs a handler directly (drawer Save buttons). True on success. */\nexport const runCtaHandler = (\n ctx: CtaHandlerContext,\n handlerName: CtaHandlerName,\n { onSuccess = [], analytics }: RunHandlerOptions = {},\n): Promise<boolean> => {\n const fullCtx: CtaContext = { ...ctx, cta: DIRECT_CTA, slot: 'primary' }\n\n return withCtaStatus(\n fullCtx,\n async () => {\n await runHandlerWithEffects(fullCtx, handlerName, onSuccess)\n\n // Success-time analytics for drawer Saves.\n if (analytics) sendCtaAnalytics(fullCtx, analytics)\n },\n { handler: handlerName },\n )\n}\n"],"mappings":";;;;;;;;AAuBA,IAAM,IAAwB,CAAC,GASlB,IAAA,CAAe,EAAE,KAAA,EAAA,MAC3B,EAAI,cAAc,EAAW,EAAI,UAAA,KAAgB,GAGvC,IAAA,CAAmB,MAAmC;AACjE,QAAM,IAAO,EAAY,CAAG;AAG5B,SAAO,EAAE,UAFO,EAAI,OAAO,gBAAgB,UAAU,EAAI,KAAK,IAAA,MAAU,cAEzC,EAAK,eAAe,CAAG,KAAK,IAAO;AACpE,GAKM,IAAA,CAAqB,EACzB,MAAA,GACA,MAAA,GACA,QAAA,EAAA,MACkD;AAClD,EAAA,EAAO,gBAAgB,cACrB,EAAK,MACL,MAAS,YAAY,eAAe,cACtC;AACF,GAMM,IAAA,CAAkB,EAAE,MAAA,GAAM,QAAA,EAAA,GAAsB,MAAqC;AACzF,QAAM,EAAE,mBAAA,GAAmB,cAAA,EAAA,IAAiB,EAAO,aAAa,WAC1D,EAAE,OAAA,GAAO,QAAA,GAAQ,SAAA,EAAA,IAAY;AAEnC,EAAA,EAAY,GAAM;AAAA,IAChB,OAAO,KAAS;AAAA,IAChB,IAAI,KAAU;AAAA,IACd,QAAQ,KAAW;AAAA,IACnB,iBAAiB;AAAA,IACjB,eAAe,GAAc,QAAQ;AAAA,IACrC,UAAU,EAAK,kBAAkB,aAAa,EAAK;AAAA,EACrD,CAAC;AACH,GAMM,IAAA,CAAoB,MAAoB;AAC5C,EAAI,EAAe,EAAI,IAAI,KAAK,KAAG,EAAkB,CA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AsB;AAAA,IAAE,GAAG;AAAA,IAAK,KAAK;AAAA,IAAY,MAAM;AAAA,EAAU;AAEvE,SAAO,EACL,GACA,YAAY;AACV,UAAM,EAAsB,GAAS,GAAa,CAAS,GAGvD,KAAW,EAAiB,GAAS,CAAS;AAAA,EACpD,GACA,EAAE,SAAS,EAAY,CACzB;AACF"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Beat, PrimaryCTA, SecondaryCTA } from '../../core';
|
|
2
2
|
import { GlobalStore } from '../../core/stores/GlobalStore';
|
|
3
|
+
import { AnalyticsEventConfigEntry } from '../analytics/analyticsEventsConfig';
|
|
3
4
|
import { BeatActions } from '../beatActions';
|
|
4
5
|
import { CtaHandlerName } from './ctaHandlers';
|
|
5
6
|
export type CtaSlot = 'primary' | 'secondary';
|
|
@@ -26,14 +27,12 @@ export type CtaEffect = 'refreshBeat';
|
|
|
26
27
|
export interface CtaStep {
|
|
27
28
|
/** Handler to await first (typed: a misspelt name fails typecheck). */
|
|
28
29
|
run?: CtaHandlerName;
|
|
29
|
-
/**
|
|
30
|
-
* Forwarded to the handler as `ctx.params`. A function computes them at press time from the
|
|
31
|
-
* beat and stores (e.g. a user pick from `beatContextOf(ctx)`); keep it to reading values, the
|
|
32
|
-
* backend picks behaviour per state via `action_key`.
|
|
33
|
-
*/
|
|
30
|
+
/** Forwarded to the handler as ctx.params; may compute from beat/stores at press time. */
|
|
34
31
|
params?: CtaParams | ((ctx: CtaStateContext) => CtaParams);
|
|
35
32
|
/** Effects executed after `run` resolves successfully. */
|
|
36
33
|
onSuccess?: CtaEffect[];
|
|
34
|
+
/** Fired after `run` succeeds. No ctaConfig entry uses it yet. */
|
|
35
|
+
analytics?: AnalyticsEventConfigEntry;
|
|
37
36
|
/**
|
|
38
37
|
* After `run`: `default` = drawer if the CTA has a block, else nothing; `drawer` forces the
|
|
39
38
|
* drawer; `none` stops. Omitted = `none` with `run`, `default` without.
|
|
@@ -52,6 +51,8 @@ export type CtaHandlerContext = Omit<CtaContext, 'cta' | 'slot'>;
|
|
|
52
51
|
export interface RunHandlerOptions {
|
|
53
52
|
/** Runner-owned effects executed after the handler resolves. */
|
|
54
53
|
onSuccess?: CtaEffect[];
|
|
54
|
+
/** Catalogue entry (e.g. ANALYTICS_EVENTS_CONFIG.X) fired after the handler resolves (drawer Saves). */
|
|
55
|
+
analytics?: AnalyticsEventConfigEntry;
|
|
55
56
|
}
|
|
56
57
|
/** A named side effect. Must throw (or reject) on failure so the runner can report it. */
|
|
57
58
|
export type CtaHandler = (ctx: CtaContext) => Promise<void> | void;
|
|
@@ -8,46 +8,46 @@ import d, { isLogoGuid as B } from "./components/LogoFromGuid.es.js";
|
|
|
8
8
|
import g from "./components/StatusBadge.es.js";
|
|
9
9
|
import k from "./components/CompactInsightCard.es.js";
|
|
10
10
|
import h from "./components/InsightErrorCard.es.js";
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import
|
|
40
|
-
import
|
|
41
|
-
import
|
|
42
|
-
import
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import {
|
|
11
|
+
import { HOST_ACTIONS as b } from "./ctaActions/hostActions.es.js";
|
|
12
|
+
import { useBeatCtaActions as T, useCtaHandler as I } from "./ctaActions/useCtaAction.es.js";
|
|
13
|
+
import { BAR_CHART_VARIANTS as v, barChartVariant as H, buildChartData as O, buildDataSeries as w } from "./blocks/ChartBlocks/BarchartBlock/utils.es.js";
|
|
14
|
+
import { BarchartBlock as M } from "./blocks/ChartBlocks/BarchartBlock/BarchartBlock.es.js";
|
|
15
|
+
import { DoubleBarChartBlock as E } from "./blocks/ChartBlocks/DoubleBarChartBlock/DoubleBarChartBlock.es.js";
|
|
16
|
+
import F from "./blocks/ChartBlocks/StepChartBlock/StepChartBlock.es.js";
|
|
17
|
+
import x from "./blocks/ChartBlocks/DonutChartBlock/DonutChartBlock.es.js";
|
|
18
|
+
import U from "./blocks/ChartBlocks/DoubleProgressBarBlock/DoubleProgressBarBlock.es.js";
|
|
19
|
+
import N from "./blocks/ComponentBlocks/AccountBlock/AccountBlock.es.js";
|
|
20
|
+
import j from "./components/TransferLogoCard.es.js";
|
|
21
|
+
import z from "./blocks/ComponentBlocks/AccountSwitchBlock/AccountSwitchBlock.es.js";
|
|
22
|
+
import K from "./components/AccountHeroCard.es.js";
|
|
23
|
+
import X from "./components/DirectDepositCard.es.js";
|
|
24
|
+
import Z from "./blocks/ComponentBlocks/DirectDepositBlock/DirectDepositBlock.es.js";
|
|
25
|
+
import { BudgetBlock as oo } from "./blocks/ComponentBlocks/BudgetBlock/BudgetBlock.es.js";
|
|
26
|
+
import to from "./components/DebtPayoffCard.es.js";
|
|
27
|
+
import io from "./components/UpcomingBillCard.es.js";
|
|
28
|
+
import po from "./blocks/ComponentBlocks/UpcomingBillBlock/UpcomingBillBlock.es.js";
|
|
29
|
+
import eo from "./blocks/ComponentBlocks/DebtsBlock/DebtsBlock.es.js";
|
|
30
|
+
import co from "./components/SaveAnExtraCard.es.js";
|
|
31
|
+
import so from "./blocks/ComponentBlocks/SaveExtraBlock/SaveExtraBlock.es.js";
|
|
32
|
+
import Co from "./components/SavingsOpportunityCard.es.js";
|
|
33
|
+
import uo from "./blocks/ComponentBlocks/SavingsOpportunityBlock/SavingsOpportunityBlock.es.js";
|
|
34
|
+
import So from "./components/InsightTransactionRow.es.js";
|
|
35
|
+
import Do from "./components/TransactionListCard.es.js";
|
|
36
|
+
import { transactionBlockVariant as Ao } from "./blocks/ComponentBlocks/TransactionBlock/layout.es.js";
|
|
37
|
+
import { TransactionBlock as Io } from "./blocks/ComponentBlocks/TransactionBlock/TransactionBlock.es.js";
|
|
38
|
+
import vo from "./components/AmountPill.es.js";
|
|
39
|
+
import Oo from "./components/SubscriptionHeroCard.es.js";
|
|
40
|
+
import yo from "./blocks/ComponentBlocks/UpcomingSubscriptionBlock/UpcomingSubscriptionBlock.es.js";
|
|
41
|
+
import Po from "./components/WithdrawalCard.es.js";
|
|
42
|
+
import Ro from "./blocks/ComponentBlocks/WithdrawalBlock/WithdrawalBlock.es.js";
|
|
43
|
+
import { SVGImageBlock as Vo } from "./blocks/ImageBlocks/SVGImageBlock/SVGImageBlock.es.js";
|
|
44
|
+
import Go from "./components/ConnectionDetailDrillDown.es.js";
|
|
45
|
+
import _o from "./components/DesignateEmergencySavingsCard.es.js";
|
|
46
|
+
import Wo from "./components/shared/StatusSnackbar.es.js";
|
|
47
|
+
import qo from "./components/FeedbackDialog.es.js";
|
|
48
|
+
import Jo from "./components/FeedbackModal.es.js";
|
|
49
|
+
import Qo from "./components/SurveyModal.es.js";
|
|
50
|
+
import { ErrorCard as Yo } from "./components/ErrorCard.es.js";
|
|
51
51
|
import { FeedbackBar as $o } from "./components/FeedbackBar.es.js";
|
|
52
52
|
import { DismissInsightDialog as rr } from "./components/DismissInsightDialog.es.js";
|
|
53
53
|
import { HiddenConfirmationCard as mr } from "./components/HiddenConfirmationCard.es.js";
|
|
@@ -60,35 +60,35 @@ import Cr from "./components/LogoClusterCard.es.js";
|
|
|
60
60
|
import ur from "./components/MerchantHighlightCard.es.js";
|
|
61
61
|
import Sr from "./components/P2PLogoStack.es.js";
|
|
62
62
|
export {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
63
|
+
N as AccountBlock,
|
|
64
|
+
K as AccountHeroCard,
|
|
65
|
+
z as AccountSwitchBlock,
|
|
66
|
+
vo as AmountPill,
|
|
67
|
+
v as BAR_CHART_VARIANTS,
|
|
68
68
|
f as BadgedTile,
|
|
69
|
-
|
|
69
|
+
M as BarchartBlock,
|
|
70
70
|
nr as BaseLayout,
|
|
71
|
-
|
|
71
|
+
oo as BudgetBlock,
|
|
72
72
|
k as CompactInsightCard,
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
73
|
+
Go as ConnectionDetailDrillDown,
|
|
74
|
+
to as DebtPayoffCard,
|
|
75
|
+
eo as DebtsBlock,
|
|
76
|
+
_o as DesignateEmergencySavingsCard,
|
|
77
|
+
Z as DirectDepositBlock,
|
|
78
|
+
X as DirectDepositCard,
|
|
79
79
|
rr as DismissInsightDialog,
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
80
|
+
x as DonutChartBlock,
|
|
81
|
+
E as DoubleBarChartBlock,
|
|
82
|
+
U as DoubleProgressBarBlock,
|
|
83
|
+
Yo as ErrorCard,
|
|
84
84
|
$o as FeedbackBar,
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
85
|
+
qo as FeedbackDialog,
|
|
86
|
+
Jo as FeedbackModal,
|
|
87
|
+
b as HOST_ACTIONS,
|
|
88
88
|
mr as HiddenConfirmationCard,
|
|
89
89
|
h as InsightErrorCard,
|
|
90
90
|
l as InsightOptionsMenu,
|
|
91
|
-
|
|
91
|
+
So as InsightTransactionRow,
|
|
92
92
|
ar as LoadingCard,
|
|
93
93
|
Cr as LogoClusterCard,
|
|
94
94
|
d as LogoFromGuid,
|
|
@@ -97,33 +97,33 @@ export {
|
|
|
97
97
|
fr as ObsolesceBanner,
|
|
98
98
|
n as OverflowMenu,
|
|
99
99
|
Sr as P2PLogoStack,
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
100
|
+
Vo as SVGImageBlock,
|
|
101
|
+
co as SaveAnExtraCard,
|
|
102
|
+
so as SaveExtraBlock,
|
|
103
|
+
uo as SavingsOpportunityBlock,
|
|
104
|
+
Co as SavingsOpportunityCard,
|
|
105
105
|
g as StatusBadge,
|
|
106
106
|
lr as StatusMessageCard,
|
|
107
107
|
r as StatusPill,
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
108
|
+
Wo as StatusSnackbar,
|
|
109
|
+
F as StepChartBlock,
|
|
110
|
+
Oo as SubscriptionHeroCard,
|
|
111
|
+
Qo as SurveyModal,
|
|
112
|
+
Io as TransactionBlock,
|
|
113
|
+
Do as TransactionListCard,
|
|
114
|
+
j as TransferLogoCard,
|
|
115
|
+
po as UpcomingBillBlock,
|
|
116
|
+
io as UpcomingBillCard,
|
|
117
|
+
yo as UpcomingSubscriptionBlock,
|
|
118
|
+
Ro as WithdrawalBlock,
|
|
119
|
+
Po as WithdrawalCard,
|
|
120
|
+
H as barChartVariant,
|
|
121
|
+
O as buildChartData,
|
|
122
|
+
w as buildDataSeries,
|
|
123
123
|
B as isLogoGuid,
|
|
124
124
|
m as resolveInsightRender,
|
|
125
|
-
|
|
125
|
+
Ao as transactionBlockVariant,
|
|
126
126
|
a as useBeatActions,
|
|
127
|
-
|
|
128
|
-
|
|
127
|
+
T as useBeatCtaActions,
|
|
128
|
+
I as useCtaHandler
|
|
129
129
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ContactSupportActionBlock as n } from "../actionBlocks/ContactSupportActionBlock.es.js";
|
|
2
2
|
import { actionBlocksKey as o } from "./actionBlocksKey.es.js";
|
|
3
|
+
import { hasDrawerBlock as W } from "./hasDrawerBlock.es.js";
|
|
3
4
|
import { BarchartBlock as m } from "../blocks/ChartBlocks/BarchartBlock/BarchartBlock.es.js";
|
|
4
5
|
import { DoubleBarChartBlock as l } from "../blocks/ChartBlocks/DoubleBarChartBlock/DoubleBarChartBlock.es.js";
|
|
5
6
|
import p from "../blocks/ChartBlocks/StepChartBlock/StepChartBlock.es.js";
|
|
@@ -33,7 +34,6 @@ import { useRecurringTransactionPrepare as a } from "../actionBlocks/RecurringTr
|
|
|
33
34
|
import { RecurringTransactionBlock as w } from "../actionBlocks/RecurringTransactionBlock/RecurringTransactionBlock.es.js";
|
|
34
35
|
import { TransactionListBlock as y } from "../actionBlocks/TransactionListBlock/TransactionListBlock.es.js";
|
|
35
36
|
import { RemainingCashBlock as U } from "../actionBlocks/RemainingCashBlock/RemainingCashBlock.es.js";
|
|
36
|
-
import { hasDrawerBlock as No } from "./hasDrawerBlock.es.js";
|
|
37
37
|
import { AmountInputModalBlock as H } from "../actionBlocks/AmountInputModalBlock/AmountInputModalBlock.es.js";
|
|
38
38
|
var r = (e) => {
|
|
39
39
|
}, go = {
|
|
@@ -124,7 +124,7 @@ var r = (e) => {
|
|
|
124
124
|
export {
|
|
125
125
|
go as actionBlocks,
|
|
126
126
|
Lo as blocks,
|
|
127
|
-
|
|
127
|
+
W as hasDrawerBlock
|
|
128
128
|
};
|
|
129
129
|
|
|
130
130
|
//# sourceMappingURL=blocks.es.js.map
|