@cogentic-co/ds 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +139 -0
- package/dist/animations/animation-ai-analysis.d.ts +7 -0
- package/dist/animations/animation-ai-analysis.js +7 -0
- package/dist/animations/animation-ai-analysis.js.map +1 -0
- package/dist/animations/animation-audit-trail.d.ts +7 -0
- package/dist/animations/animation-audit-trail.js +5 -0
- package/dist/animations/animation-audit-trail.js.map +1 -0
- package/dist/animations/animation-compliance-reports.d.ts +7 -0
- package/dist/animations/animation-compliance-reports.js +7 -0
- package/dist/animations/animation-compliance-reports.js.map +1 -0
- package/dist/animations/animation-custom-rules.d.ts +7 -0
- package/dist/animations/animation-custom-rules.js +7 -0
- package/dist/animations/animation-custom-rules.js.map +1 -0
- package/dist/animations/animation-jira-ticket.d.ts +7 -0
- package/dist/animations/animation-jira-ticket.js +6 -0
- package/dist/animations/animation-jira-ticket.js.map +1 -0
- package/dist/animations/animation-jurisdiction-detection.d.ts +7 -0
- package/dist/animations/animation-jurisdiction-detection.js +7 -0
- package/dist/animations/animation-jurisdiction-detection.js.map +1 -0
- package/dist/animations/animation-multi-protocol.d.ts +7 -0
- package/dist/animations/animation-multi-protocol.js +5 -0
- package/dist/animations/animation-multi-protocol.js.map +1 -0
- package/dist/animations/animation-pricing-preview.d.ts +16 -0
- package/dist/animations/animation-pricing-preview.js +7 -0
- package/dist/animations/animation-pricing-preview.js.map +1 -0
- package/dist/animations/animation-realtime-updates.d.ts +7 -0
- package/dist/animations/animation-realtime-updates.js +8 -0
- package/dist/animations/animation-realtime-updates.js.map +1 -0
- package/dist/animations/animation-rest-api.d.ts +7 -0
- package/dist/animations/animation-rest-api.js +5 -0
- package/dist/animations/animation-rest-api.js.map +1 -0
- package/dist/animations/animation-risk-scoring.d.ts +7 -0
- package/dist/animations/animation-risk-scoring.js +8 -0
- package/dist/animations/animation-risk-scoring.js.map +1 -0
- package/dist/animations/animation-sandbox.d.ts +7 -0
- package/dist/animations/animation-sandbox.js +5 -0
- package/dist/animations/animation-sandbox.js.map +1 -0
- package/dist/animations/animation-scheduled-reports.d.ts +7 -0
- package/dist/animations/animation-scheduled-reports.js +7 -0
- package/dist/animations/animation-scheduled-reports.js.map +1 -0
- package/dist/animations/animation-secure-messaging.d.ts +7 -0
- package/dist/animations/animation-secure-messaging.js +6 -0
- package/dist/animations/animation-secure-messaging.js.map +1 -0
- package/dist/animations/animation-slack-notification.d.ts +7 -0
- package/dist/animations/animation-slack-notification.js +6 -0
- package/dist/animations/animation-slack-notification.js.map +1 -0
- package/dist/animations/animation-sop-mapping.d.ts +7 -0
- package/dist/animations/animation-sop-mapping.js +5 -0
- package/dist/animations/animation-sop-mapping.js.map +1 -0
- package/dist/animations/animation-team-routing.d.ts +7 -0
- package/dist/animations/animation-team-routing.js +7 -0
- package/dist/animations/animation-team-routing.js.map +1 -0
- package/dist/animations/animation-teams-notification.d.ts +7 -0
- package/dist/animations/animation-teams-notification.js +6 -0
- package/dist/animations/animation-teams-notification.js.map +1 -0
- package/dist/animations/animation-vasp-identification.d.ts +7 -0
- package/dist/animations/animation-vasp-identification.js +7 -0
- package/dist/animations/animation-vasp-identification.js.map +1 -0
- package/dist/animations/animation-webhooks.d.ts +7 -0
- package/dist/animations/animation-webhooks.js +6 -0
- package/dist/animations/animation-webhooks.js.map +1 -0
- package/dist/blocks/auth-form.d.ts +18 -0
- package/dist/blocks/auth-form.js +7 -0
- package/dist/blocks/auth-form.js.map +1 -0
- package/dist/blocks/feature-section.d.ts +17 -0
- package/dist/blocks/feature-section.js +5 -0
- package/dist/blocks/feature-section.js.map +1 -0
- package/dist/blocks/hero-section.d.ts +19 -0
- package/dist/blocks/hero-section.js +5 -0
- package/dist/blocks/hero-section.js.map +1 -0
- package/dist/blocks/pricing-table.d.ts +24 -0
- package/dist/blocks/pricing-table.js +6 -0
- package/dist/blocks/pricing-table.js.map +1 -0
- package/dist/blocks/stat-card.d.ts +15 -0
- package/dist/blocks/stat-card.js +6 -0
- package/dist/blocks/stat-card.js.map +1 -0
- package/dist/card-Cumdyf_G.d.ts +15 -0
- package/dist/charts.d.ts +4 -0
- package/dist/charts.js +5 -0
- package/dist/charts.js.map +1 -0
- package/dist/chatbot.d.ts +280 -0
- package/dist/chatbot.js +2202 -0
- package/dist/chatbot.js.map +1 -0
- package/dist/chunk-4NEQV6H2.js +39 -0
- package/dist/chunk-4NEQV6H2.js.map +1 -0
- package/dist/chunk-4YD3YS4B.js +110 -0
- package/dist/chunk-4YD3YS4B.js.map +1 -0
- package/dist/chunk-5JLZ42JT.js +125 -0
- package/dist/chunk-5JLZ42JT.js.map +1 -0
- package/dist/chunk-5OOO6TRA.js +111 -0
- package/dist/chunk-5OOO6TRA.js.map +1 -0
- package/dist/chunk-65Z2VEKG.js +161 -0
- package/dist/chunk-65Z2VEKG.js.map +1 -0
- package/dist/chunk-6RWCZUAD.js +12 -0
- package/dist/chunk-6RWCZUAD.js.map +1 -0
- package/dist/chunk-7HRPF2N2.js +56 -0
- package/dist/chunk-7HRPF2N2.js.map +1 -0
- package/dist/chunk-BNFSXNP2.js +71 -0
- package/dist/chunk-BNFSXNP2.js.map +1 -0
- package/dist/chunk-BTFYV3TI.js +102 -0
- package/dist/chunk-BTFYV3TI.js.map +1 -0
- package/dist/chunk-BTZB4JRC.js +117 -0
- package/dist/chunk-BTZB4JRC.js.map +1 -0
- package/dist/chunk-BZSA47MS.js +121 -0
- package/dist/chunk-BZSA47MS.js.map +1 -0
- package/dist/chunk-CG5JA7FM.js +107 -0
- package/dist/chunk-CG5JA7FM.js.map +1 -0
- package/dist/chunk-EFLWU2JP.js +145 -0
- package/dist/chunk-EFLWU2JP.js.map +1 -0
- package/dist/chunk-F7REPQOA.js +93 -0
- package/dist/chunk-F7REPQOA.js.map +1 -0
- package/dist/chunk-FKPK3CB7.js +143 -0
- package/dist/chunk-FKPK3CB7.js.map +1 -0
- package/dist/chunk-GZNLQE3I.js +55 -0
- package/dist/chunk-GZNLQE3I.js.map +1 -0
- package/dist/chunk-H7VUIMEL.js +172 -0
- package/dist/chunk-H7VUIMEL.js.map +1 -0
- package/dist/chunk-HTYR73ON.js +161 -0
- package/dist/chunk-HTYR73ON.js.map +1 -0
- package/dist/chunk-I26ZXVSY.js +124 -0
- package/dist/chunk-I26ZXVSY.js.map +1 -0
- package/dist/chunk-IKATDPHG.js +92 -0
- package/dist/chunk-IKATDPHG.js.map +1 -0
- package/dist/chunk-KUOF3XRZ.js +108 -0
- package/dist/chunk-KUOF3XRZ.js.map +1 -0
- package/dist/chunk-LW6GAWZM.js +148 -0
- package/dist/chunk-LW6GAWZM.js.map +1 -0
- package/dist/chunk-N7PBUY7G.js +110 -0
- package/dist/chunk-N7PBUY7G.js.map +1 -0
- package/dist/chunk-NAPDFVBI.js +102 -0
- package/dist/chunk-NAPDFVBI.js.map +1 -0
- package/dist/chunk-RTK7R4KZ.js +66 -0
- package/dist/chunk-RTK7R4KZ.js.map +1 -0
- package/dist/chunk-RXV2XUDZ.js +31 -0
- package/dist/chunk-RXV2XUDZ.js.map +1 -0
- package/dist/chunk-RZZTDJHG.js +110 -0
- package/dist/chunk-RZZTDJHG.js.map +1 -0
- package/dist/chunk-SNOJLZP4.js +197 -0
- package/dist/chunk-SNOJLZP4.js.map +1 -0
- package/dist/chunk-TAPJEVUA.js +24 -0
- package/dist/chunk-TAPJEVUA.js.map +1 -0
- package/dist/chunk-U4EPKN7G.js +518 -0
- package/dist/chunk-U4EPKN7G.js.map +1 -0
- package/dist/chunk-VWSX75RB.js +202 -0
- package/dist/chunk-VWSX75RB.js.map +1 -0
- package/dist/chunk-XFWKI45G.js +800 -0
- package/dist/chunk-XFWKI45G.js.map +1 -0
- package/dist/chunk-XQYFQ6PU.js +77 -0
- package/dist/chunk-XQYFQ6PU.js.map +1 -0
- package/dist/index-CcPuHWa-.d.ts +118 -0
- package/dist/index.d.ts +1385 -0
- package/dist/index.js +8673 -0
- package/dist/index.js.map +1 -0
- package/dist/workflow.d.ts +165 -0
- package/dist/workflow.js +5 -0
- package/dist/workflow.js.map +1 -0
- package/package.json +157 -0
- package/src/styles/globals.css +211 -0
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useCycleIndex } from './chunk-6RWCZUAD.js';
|
|
3
|
+
import { __spreadProps, __spreadValues, cn } from './chunk-GZNLQE3I.js';
|
|
4
|
+
import { CheckCircle2 } from 'lucide-react';
|
|
5
|
+
import { LazyMotion, domAnimation, m, AnimatePresence } from 'motion/react';
|
|
6
|
+
import { useMemo } from 'react';
|
|
7
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
8
|
+
|
|
9
|
+
var DEFAULT_PLANS = [
|
|
10
|
+
{
|
|
11
|
+
name: "Starter",
|
|
12
|
+
features: ["50 transfers/mo", "5 jurisdictions", "Audit trail"],
|
|
13
|
+
ctaLabel: "Get started",
|
|
14
|
+
highlight: false
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
name: "Growth",
|
|
18
|
+
monthlyPrice: "$499",
|
|
19
|
+
annualPrice: "$399",
|
|
20
|
+
features: ["1,000 transfers/mo", "25 jurisdictions", "AI investigation"],
|
|
21
|
+
ctaLabel: "Start trial",
|
|
22
|
+
highlight: true
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
name: "Enterprise",
|
|
26
|
+
features: ["Unlimited transfers", "45+ jurisdictions", "Custom workflows"],
|
|
27
|
+
ctaLabel: "Talk to sales",
|
|
28
|
+
highlight: false
|
|
29
|
+
}
|
|
30
|
+
];
|
|
31
|
+
var MAX_FEATURES = 3;
|
|
32
|
+
var CYCLE_MS = 4e3;
|
|
33
|
+
function AnimationPricingPreview({
|
|
34
|
+
className,
|
|
35
|
+
plans
|
|
36
|
+
}) {
|
|
37
|
+
const [containerRef, cycleIndex] = useCycleIndex(2, CYCLE_MS);
|
|
38
|
+
const yearly = cycleIndex === 0;
|
|
39
|
+
const items = useMemo(() => {
|
|
40
|
+
if (!(plans == null ? void 0 : plans.length)) return DEFAULT_PLANS;
|
|
41
|
+
return plans.slice(0, 3).map((p) => __spreadProps(__spreadValues({}, p), {
|
|
42
|
+
features: p.features.slice(0, MAX_FEATURES)
|
|
43
|
+
}));
|
|
44
|
+
}, [plans]);
|
|
45
|
+
return /* @__PURE__ */ jsx(LazyMotion, { features: domAnimation, children: /* @__PURE__ */ jsxs(
|
|
46
|
+
"div",
|
|
47
|
+
{
|
|
48
|
+
ref: containerRef,
|
|
49
|
+
className: cn("flex flex-col items-center justify-center p-5", className),
|
|
50
|
+
children: [
|
|
51
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
52
|
+
/* @__PURE__ */ jsx(
|
|
53
|
+
"span",
|
|
54
|
+
{
|
|
55
|
+
className: cn(
|
|
56
|
+
"font-semibold text-[11px] transition-colors",
|
|
57
|
+
!yearly ? "text-gray-900" : "text-gray-400"
|
|
58
|
+
),
|
|
59
|
+
children: "Monthly"
|
|
60
|
+
}
|
|
61
|
+
),
|
|
62
|
+
/* @__PURE__ */ jsx(
|
|
63
|
+
"span",
|
|
64
|
+
{
|
|
65
|
+
className: "relative h-5 w-9 rounded-full bg-gray-900 transition-colors",
|
|
66
|
+
"aria-label": "Toggle billing",
|
|
67
|
+
children: /* @__PURE__ */ jsx(
|
|
68
|
+
m.div,
|
|
69
|
+
{
|
|
70
|
+
className: "absolute top-0.5 size-4 rounded-full bg-white",
|
|
71
|
+
animate: { left: yearly ? 18 : 2 },
|
|
72
|
+
transition: { type: "spring", stiffness: 500, damping: 30 }
|
|
73
|
+
}
|
|
74
|
+
)
|
|
75
|
+
}
|
|
76
|
+
),
|
|
77
|
+
/* @__PURE__ */ jsx(
|
|
78
|
+
"span",
|
|
79
|
+
{
|
|
80
|
+
className: cn(
|
|
81
|
+
"font-semibold text-[11px] transition-colors",
|
|
82
|
+
yearly ? "text-gray-900" : "text-gray-400"
|
|
83
|
+
),
|
|
84
|
+
children: "Yearly"
|
|
85
|
+
}
|
|
86
|
+
)
|
|
87
|
+
] }),
|
|
88
|
+
/* @__PURE__ */ jsx("div", { className: "-mx-[70px] mt-4 flex w-[calc(100%+140px)] gap-2.5 sm:mx-0 sm:w-full", children: items.map((plan, i) => {
|
|
89
|
+
const rawPrice = yearly ? plan.annualPrice : plan.monthlyPrice;
|
|
90
|
+
const price = rawPrice || (i === 0 ? "Free" : "Let\u2019s talk");
|
|
91
|
+
const hasPrice = yearly ? !!plan.annualPrice : !!plan.monthlyPrice;
|
|
92
|
+
return /* @__PURE__ */ jsxs(
|
|
93
|
+
m.div,
|
|
94
|
+
{
|
|
95
|
+
initial: { opacity: 0, y: 12 },
|
|
96
|
+
animate: { opacity: 1, y: 0 },
|
|
97
|
+
transition: { duration: 0.4, delay: 0.1 + i * 0.08 },
|
|
98
|
+
className: cn(
|
|
99
|
+
"flex flex-1 flex-col rounded-xl border p-3",
|
|
100
|
+
plan.highlight ? "border-gray-900 bg-gray-50 shadow-sm" : "border-gray-200 bg-white"
|
|
101
|
+
),
|
|
102
|
+
children: [
|
|
103
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
|
|
104
|
+
/* @__PURE__ */ jsx("span", { className: "font-bold text-[11px] text-gray-900", children: plan.name }),
|
|
105
|
+
plan.highlight && /* @__PURE__ */ jsx("span", { className: "rounded bg-gray-900 px-1.5 py-0.5 font-bold text-[8px] text-white", children: "Popular" })
|
|
106
|
+
] }),
|
|
107
|
+
/* @__PURE__ */ jsxs("div", { className: "mt-2 flex items-baseline gap-0.5", children: [
|
|
108
|
+
/* @__PURE__ */ jsx(AnimatePresence, { mode: "wait", children: /* @__PURE__ */ jsx(
|
|
109
|
+
m.span,
|
|
110
|
+
{
|
|
111
|
+
initial: { opacity: 0, y: -6 },
|
|
112
|
+
animate: { opacity: 1, y: 0 },
|
|
113
|
+
exit: { opacity: 0, y: 6 },
|
|
114
|
+
transition: { duration: 0.2 },
|
|
115
|
+
className: "font-bold text-gray-900 text-lg",
|
|
116
|
+
children: price
|
|
117
|
+
},
|
|
118
|
+
price
|
|
119
|
+
) }),
|
|
120
|
+
hasPrice && /* @__PURE__ */ jsx("span", { className: "text-[9px] text-gray-400", children: "/mo" })
|
|
121
|
+
] }),
|
|
122
|
+
/* @__PURE__ */ jsx("div", { className: "mt-2.5 flex flex-col gap-1.5", children: plan.features.map((f) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
|
|
123
|
+
/* @__PURE__ */ jsx(
|
|
124
|
+
CheckCircle2,
|
|
125
|
+
{
|
|
126
|
+
className: "size-3 shrink-0 text-emerald-500",
|
|
127
|
+
strokeWidth: 2.5
|
|
128
|
+
}
|
|
129
|
+
),
|
|
130
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium text-[9px] text-gray-600 leading-tight", children: f })
|
|
131
|
+
] }, f)) }),
|
|
132
|
+
/* @__PURE__ */ jsx(
|
|
133
|
+
"div",
|
|
134
|
+
{
|
|
135
|
+
className: cn(
|
|
136
|
+
"mt-3 rounded-md py-1.5 text-center font-semibold text-[9px]",
|
|
137
|
+
plan.highlight ? "bg-gray-900 text-white" : "border border-gray-200 text-gray-700"
|
|
138
|
+
),
|
|
139
|
+
children: plan.ctaLabel
|
|
140
|
+
}
|
|
141
|
+
)
|
|
142
|
+
]
|
|
143
|
+
},
|
|
144
|
+
plan.name
|
|
145
|
+
);
|
|
146
|
+
}) }),
|
|
147
|
+
/* @__PURE__ */ jsx("div", { className: "mt-3 flex w-full gap-2.5", children: [
|
|
148
|
+
{ label: "Avg. savings", value: "42%", sub: "vs manual compliance" },
|
|
149
|
+
{ label: "Setup time", value: "<1hr", sub: "fully operational" },
|
|
150
|
+
{ label: "Uptime SLA", value: "99.9%", sub: "guaranteed" }
|
|
151
|
+
].map((metric, i) => /* @__PURE__ */ jsxs(
|
|
152
|
+
m.div,
|
|
153
|
+
{
|
|
154
|
+
initial: { opacity: 0, y: 6 },
|
|
155
|
+
animate: { opacity: 1, y: 0 },
|
|
156
|
+
transition: { duration: 0.3, delay: 0.4 + i * 0.08 },
|
|
157
|
+
className: "flex flex-1 flex-col items-center rounded-lg border border-gray-100 bg-white px-2 py-2",
|
|
158
|
+
children: [
|
|
159
|
+
/* @__PURE__ */ jsx("span", { className: "font-bold text-gray-900 text-sm", children: metric.value }),
|
|
160
|
+
/* @__PURE__ */ jsx("span", { className: "text-[8px] text-gray-400", children: metric.sub })
|
|
161
|
+
]
|
|
162
|
+
},
|
|
163
|
+
metric.label
|
|
164
|
+
)) })
|
|
165
|
+
]
|
|
166
|
+
}
|
|
167
|
+
) });
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export { AnimationPricingPreview };
|
|
171
|
+
//# sourceMappingURL=chunk-H7VUIMEL.js.map
|
|
172
|
+
//# sourceMappingURL=chunk-H7VUIMEL.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/animations/animation-pricing-preview.tsx"],"names":[],"mappings":";;;;;;;AAmBA,IAAM,aAAA,GAAwB;AAAA,EAC5B;AAAA,IACE,IAAA,EAAM,SAAA;AAAA,IACN,QAAA,EAAU,CAAC,iBAAA,EAAmB,iBAAA,EAAmB,aAAa,CAAA;AAAA,IAC9D,QAAA,EAAU,aAAA;AAAA,IACV,SAAA,EAAW;AAAA,GACb;AAAA,EACA;AAAA,IACE,IAAA,EAAM,QAAA;AAAA,IACN,YAAA,EAAc,MAAA;AAAA,IACd,WAAA,EAAa,MAAA;AAAA,IACb,QAAA,EAAU,CAAC,oBAAA,EAAsB,kBAAA,EAAoB,kBAAkB,CAAA;AAAA,IACvE,QAAA,EAAU,aAAA;AAAA,IACV,SAAA,EAAW;AAAA,GACb;AAAA,EACA;AAAA,IACE,IAAA,EAAM,YAAA;AAAA,IACN,QAAA,EAAU,CAAC,qBAAA,EAAuB,mBAAA,EAAqB,kBAAkB,CAAA;AAAA,IACzE,QAAA,EAAU,eAAA;AAAA,IACV,SAAA,EAAW;AAAA;AAEf,CA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C5B,OAAA,EAAS,EAAE,OAAA,EAAS,CAAA,EAAG,GAAG,CAAA,EAAE;AAAA,YAC5B,YAAY,EAAE,QAAA,EAAU,KAAK,KAAA,EAAO,GAAA,GAAM,IAAI,IAAA,EAAK;AAAA,YACnD,SAAA,EAAU,wFAAA;AAAA,YAEV,QAAA,EAAA;AAAA,8BAAA,GAAA,CAAC,MAAA,EAAA,EAAK,SAAA,EAAU,iCAAA,EAAmC,QAAA,EAAA,MAAA,CAAO,KAAA,EAAM,CAAA;AAAA,8BAChE,GAAA,CAAC,MAAA,EAAA,EAAK,SAAA,EAAU,0BAAA,EAA4B,iBAAO,GAAA,EAAI;AAAA;AAAA,WAAA;AAAA,UAPlD,MAAA,CAAO;AAAA,SASf,CAAA,EACH;AAAA;AAAA;AAAA,GACF,EACF,CAAA;AAEJ","file":"chunk-H7VUIMEL.js","sourcesContent":["\"use client\"\n\nimport { CheckCircle2 } from \"lucide-react\"\nimport { AnimatePresence, domAnimation, LazyMotion, m } from \"motion/react\"\nimport { useMemo } from \"react\"\n\nimport { useCycleIndex } from \"../hooks/use-cycle-index\"\n\nimport { cn } from \"../lib/utils\"\n\ninterface Plan {\n name: string\n features: string[]\n ctaLabel: string\n highlight?: boolean\n monthlyPrice?: string\n annualPrice?: string\n}\n\nconst DEFAULT_PLANS: Plan[] = [\n {\n name: \"Starter\",\n features: [\"50 transfers/mo\", \"5 jurisdictions\", \"Audit trail\"],\n ctaLabel: \"Get started\",\n highlight: false,\n },\n {\n name: \"Growth\",\n monthlyPrice: \"$499\",\n annualPrice: \"$399\",\n features: [\"1,000 transfers/mo\", \"25 jurisdictions\", \"AI investigation\"],\n ctaLabel: \"Start trial\",\n highlight: true,\n },\n {\n name: \"Enterprise\",\n features: [\"Unlimited transfers\", \"45+ jurisdictions\", \"Custom workflows\"],\n ctaLabel: \"Talk to sales\",\n highlight: false,\n },\n]\n\nconst MAX_FEATURES = 3\nconst CYCLE_MS = 4000\n\nexport default function AnimationPricingPreview({\n className,\n plans,\n}: {\n className?: string\n plans?: Plan[]\n}) {\n const [containerRef, cycleIndex] = useCycleIndex(2, CYCLE_MS)\n const yearly = cycleIndex === 0\n\n // Use CMS plans if provided (pick first 3), otherwise defaults\n const items = useMemo(() => {\n if (!plans?.length) return DEFAULT_PLANS\n return plans.slice(0, 3).map((p) => ({\n ...p,\n features: p.features.slice(0, MAX_FEATURES),\n }))\n }, [plans])\n\n return (\n <LazyMotion features={domAnimation}>\n <div\n ref={containerRef}\n className={cn(\"flex flex-col items-center justify-center p-5\", className)}\n >\n {/* Toggle */}\n <div className=\"flex items-center gap-3\">\n <span\n className={cn(\n \"font-semibold text-[11px] transition-colors\",\n !yearly ? \"text-gray-900\" : \"text-gray-400\",\n )}\n >\n Monthly\n </span>\n <span\n className=\"relative h-5 w-9 rounded-full bg-gray-900 transition-colors\"\n aria-label=\"Toggle billing\"\n >\n <m.div\n className=\"absolute top-0.5 size-4 rounded-full bg-white\"\n animate={{ left: yearly ? 18 : 2 }}\n transition={{ type: \"spring\", stiffness: 500, damping: 30 }}\n />\n </span>\n <span\n className={cn(\n \"font-semibold text-[11px] transition-colors\",\n yearly ? \"text-gray-900\" : \"text-gray-400\",\n )}\n >\n Yearly\n </span>\n </div>\n\n {/* Cards */}\n <div className=\"-mx-[70px] mt-4 flex w-[calc(100%+140px)] gap-2.5 sm:mx-0 sm:w-full\">\n {items.map((plan, i) => {\n const rawPrice = yearly ? plan.annualPrice : plan.monthlyPrice\n const price = rawPrice || (i === 0 ? \"Free\" : \"Let\\u2019s talk\")\n const hasPrice = yearly ? !!plan.annualPrice : !!plan.monthlyPrice\n return (\n <m.div\n key={plan.name}\n initial={{ opacity: 0, y: 12 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.4, delay: 0.1 + i * 0.08 }}\n className={cn(\n \"flex flex-1 flex-col rounded-xl border p-3\",\n plan.highlight\n ? \"border-gray-900 bg-gray-50 shadow-sm\"\n : \"border-gray-200 bg-white\",\n )}\n >\n <div className=\"flex items-center gap-1.5\">\n <span className=\"font-bold text-[11px] text-gray-900\">{plan.name}</span>\n {plan.highlight && (\n <span className=\"rounded bg-gray-900 px-1.5 py-0.5 font-bold text-[8px] text-white\">\n Popular\n </span>\n )}\n </div>\n\n <div className=\"mt-2 flex items-baseline gap-0.5\">\n <AnimatePresence mode=\"wait\">\n <m.span\n key={price}\n initial={{ opacity: 0, y: -6 }}\n animate={{ opacity: 1, y: 0 }}\n exit={{ opacity: 0, y: 6 }}\n transition={{ duration: 0.2 }}\n className=\"font-bold text-gray-900 text-lg\"\n >\n {price}\n </m.span>\n </AnimatePresence>\n {hasPrice && <span className=\"text-[9px] text-gray-400\">/mo</span>}\n </div>\n\n <div className=\"mt-2.5 flex flex-col gap-1.5\">\n {plan.features.map((f) => (\n <div key={f} className=\"flex items-center gap-1\">\n <CheckCircle2\n className=\"size-3 shrink-0 text-emerald-500\"\n strokeWidth={2.5}\n />\n <span className=\"font-medium text-[9px] text-gray-600 leading-tight\">\n {f}\n </span>\n </div>\n ))}\n </div>\n\n <div\n className={cn(\n \"mt-3 rounded-md py-1.5 text-center font-semibold text-[9px]\",\n plan.highlight\n ? \"bg-gray-900 text-white\"\n : \"border border-gray-200 text-gray-700\",\n )}\n >\n {plan.ctaLabel}\n </div>\n </m.div>\n )\n })}\n </div>\n\n {/* Bottom metric row */}\n <div className=\"mt-3 flex w-full gap-2.5\">\n {[\n { label: \"Avg. savings\", value: \"42%\", sub: \"vs manual compliance\" },\n { label: \"Setup time\", value: \"<1hr\", sub: \"fully operational\" },\n { label: \"Uptime SLA\", value: \"99.9%\", sub: \"guaranteed\" },\n ].map((metric, i) => (\n <m.div\n key={metric.label}\n initial={{ opacity: 0, y: 6 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.3, delay: 0.4 + i * 0.08 }}\n className=\"flex flex-1 flex-col items-center rounded-lg border border-gray-100 bg-white px-2 py-2\"\n >\n <span className=\"font-bold text-gray-900 text-sm\">{metric.value}</span>\n <span className=\"text-[8px] text-gray-400\">{metric.sub}</span>\n </m.div>\n ))}\n </div>\n </div>\n </LazyMotion>\n )\n}\n"]}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { EASE_OUT } from './chunk-TAPJEVUA.js';
|
|
3
|
+
import { useCycleIndex } from './chunk-6RWCZUAD.js';
|
|
4
|
+
import { cn } from './chunk-GZNLQE3I.js';
|
|
5
|
+
import { ShieldCheck, ShieldAlert, AlertTriangle } from 'lucide-react';
|
|
6
|
+
import { LazyMotion, domAnimation, m } from 'motion/react';
|
|
7
|
+
import { useState, useEffect } from 'react';
|
|
8
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
9
|
+
|
|
10
|
+
var SCENARIOS = [
|
|
11
|
+
{
|
|
12
|
+
txn: "TXN-0847",
|
|
13
|
+
corridor: "AU \u2192 SG",
|
|
14
|
+
score: 18,
|
|
15
|
+
level: "Low",
|
|
16
|
+
colour: "text-emerald-600",
|
|
17
|
+
barColour: "bg-emerald-400",
|
|
18
|
+
icon: ShieldCheck,
|
|
19
|
+
checks: [
|
|
20
|
+
{ label: "Sanctions", result: "Clear", ok: true },
|
|
21
|
+
{ label: "PEP screening", result: "Clear", ok: true },
|
|
22
|
+
{ label: "Travel Rule", result: "Verified", ok: true },
|
|
23
|
+
{ label: "Threshold", result: "Below limit", ok: true }
|
|
24
|
+
]
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
txn: "TXN-0846",
|
|
28
|
+
corridor: "HK \u2192 GB",
|
|
29
|
+
score: 72,
|
|
30
|
+
level: "High",
|
|
31
|
+
colour: "text-red-500",
|
|
32
|
+
barColour: "bg-red-400",
|
|
33
|
+
icon: ShieldAlert,
|
|
34
|
+
checks: [
|
|
35
|
+
{ label: "Sanctions", result: "Clear", ok: true },
|
|
36
|
+
{ label: "PEP screening", result: "1 match", ok: false },
|
|
37
|
+
{ label: "Travel Rule", result: "Verified", ok: true },
|
|
38
|
+
{ label: "Threshold", result: "Exceeded", ok: false }
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
txn: "TXN-0845",
|
|
43
|
+
corridor: "AE \u2192 NL",
|
|
44
|
+
score: 41,
|
|
45
|
+
level: "Medium",
|
|
46
|
+
colour: "text-amber-500",
|
|
47
|
+
barColour: "bg-amber-400",
|
|
48
|
+
icon: AlertTriangle,
|
|
49
|
+
checks: [
|
|
50
|
+
{ label: "Sanctions", result: "Clear", ok: true },
|
|
51
|
+
{ label: "PEP screening", result: "Clear", ok: true },
|
|
52
|
+
{ label: "Travel Rule", result: "Pending", ok: false },
|
|
53
|
+
{ label: "Threshold", result: "Below limit", ok: true }
|
|
54
|
+
]
|
|
55
|
+
}
|
|
56
|
+
];
|
|
57
|
+
var CYCLE_MS = 3800;
|
|
58
|
+
function AnimatedNumber({ value, duration = 1e3 }) {
|
|
59
|
+
const [display, setDisplay] = useState(0);
|
|
60
|
+
useEffect(() => {
|
|
61
|
+
let start = null;
|
|
62
|
+
let raf;
|
|
63
|
+
function tick(ts) {
|
|
64
|
+
if (start === null) start = ts;
|
|
65
|
+
const progress = Math.min((ts - start) / duration, 1);
|
|
66
|
+
const eased = 1 - (1 - progress) ** 3;
|
|
67
|
+
setDisplay(Math.round(value * eased));
|
|
68
|
+
if (progress < 1) raf = requestAnimationFrame(tick);
|
|
69
|
+
}
|
|
70
|
+
raf = requestAnimationFrame(tick);
|
|
71
|
+
return () => cancelAnimationFrame(raf);
|
|
72
|
+
}, [value, duration]);
|
|
73
|
+
return /* @__PURE__ */ jsx(Fragment, { children: display });
|
|
74
|
+
}
|
|
75
|
+
function AnimationRiskScoring({ className }) {
|
|
76
|
+
const [containerRef, index] = useCycleIndex(SCENARIOS.length, CYCLE_MS);
|
|
77
|
+
const s = SCENARIOS[index];
|
|
78
|
+
const Icon = s.icon;
|
|
79
|
+
return /* @__PURE__ */ jsx(LazyMotion, { features: domAnimation, children: /* @__PURE__ */ jsxs("div", { ref: containerRef, className: cn("flex flex-col p-5", className), children: [
|
|
80
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between", children: [
|
|
81
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
82
|
+
/* @__PURE__ */ jsx("p", { className: "font-semibold text-[15px] text-forground", children: "Risk Analysis" }),
|
|
83
|
+
/* @__PURE__ */ jsx("p", { className: "text-[12px] text-gray-400", children: "Real-time transfer scoring" })
|
|
84
|
+
] }),
|
|
85
|
+
/* @__PURE__ */ jsxs(
|
|
86
|
+
m.div,
|
|
87
|
+
{
|
|
88
|
+
initial: { opacity: 0, scale: 0.9 },
|
|
89
|
+
animate: { opacity: 1, scale: 1 },
|
|
90
|
+
className: cn(
|
|
91
|
+
"flex items-center gap-1.5 rounded-full px-2.5 py-1",
|
|
92
|
+
s.level === "Low" ? "bg-emerald-50" : s.level === "Medium" ? "bg-amber-50" : "bg-red-50"
|
|
93
|
+
),
|
|
94
|
+
children: [
|
|
95
|
+
/* @__PURE__ */ jsx(Icon, { className: cn("size-3.5", s.colour), strokeWidth: 2 }),
|
|
96
|
+
/* @__PURE__ */ jsx("span", { className: cn("font-semibold text-[11px]", s.colour), children: s.level })
|
|
97
|
+
]
|
|
98
|
+
},
|
|
99
|
+
index
|
|
100
|
+
)
|
|
101
|
+
] }),
|
|
102
|
+
/* @__PURE__ */ jsxs(
|
|
103
|
+
m.div,
|
|
104
|
+
{
|
|
105
|
+
initial: { opacity: 0, y: 6 },
|
|
106
|
+
animate: { opacity: 1, y: 0 },
|
|
107
|
+
transition: { duration: 0.3 },
|
|
108
|
+
className: "mt-4 flex items-center gap-3 rounded-lg border border-gray-100 bg-gray-50 px-3 py-2.5",
|
|
109
|
+
children: [
|
|
110
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1", children: [
|
|
111
|
+
/* @__PURE__ */ jsx("p", { className: "font-bold font-mono text-[11px] text-gray-400", children: s.txn }),
|
|
112
|
+
/* @__PURE__ */ jsx("p", { className: "font-medium text-[12px] text-gray-700", children: s.corridor })
|
|
113
|
+
] }),
|
|
114
|
+
/* @__PURE__ */ jsxs("div", { className: "text-right", children: [
|
|
115
|
+
/* @__PURE__ */ jsx("p", { className: "font-bold font-mono text-2xl text-gray-900", children: /* @__PURE__ */ jsx(AnimatedNumber, { value: s.score }) }),
|
|
116
|
+
/* @__PURE__ */ jsx("p", { className: "text-[10px] text-gray-400", children: "/100" })
|
|
117
|
+
] })
|
|
118
|
+
]
|
|
119
|
+
},
|
|
120
|
+
`info-${index}`
|
|
121
|
+
),
|
|
122
|
+
/* @__PURE__ */ jsx("div", { className: "mt-3 h-2 overflow-hidden rounded-full bg-gray-100", children: /* @__PURE__ */ jsx(
|
|
123
|
+
m.div,
|
|
124
|
+
{
|
|
125
|
+
className: cn("h-full rounded-full", s.barColour),
|
|
126
|
+
style: { transformOrigin: "left", width: "100%" },
|
|
127
|
+
initial: { scaleX: 0 },
|
|
128
|
+
animate: { scaleX: s.score / 100 },
|
|
129
|
+
transition: { duration: 1, ease: EASE_OUT }
|
|
130
|
+
},
|
|
131
|
+
`bar-${index}`
|
|
132
|
+
) }),
|
|
133
|
+
/* @__PURE__ */ jsx("div", { className: "mt-4 grid grid-cols-2 gap-2", children: s.checks.map((check, i) => /* @__PURE__ */ jsxs(
|
|
134
|
+
m.div,
|
|
135
|
+
{
|
|
136
|
+
initial: { opacity: 0, y: 4 },
|
|
137
|
+
animate: { opacity: 1, y: 0 },
|
|
138
|
+
transition: { duration: 0.25, delay: 0.1 + i * 0.08 },
|
|
139
|
+
className: "flex items-center justify-between rounded-lg border border-gray-100 bg-white px-3 py-2",
|
|
140
|
+
children: [
|
|
141
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium text-[11px] text-gray-600", children: check.label }),
|
|
142
|
+
/* @__PURE__ */ jsx(
|
|
143
|
+
"span",
|
|
144
|
+
{
|
|
145
|
+
className: cn(
|
|
146
|
+
"font-semibold text-[10px]",
|
|
147
|
+
check.ok ? "text-emerald-600" : "text-red-500"
|
|
148
|
+
),
|
|
149
|
+
children: check.result
|
|
150
|
+
}
|
|
151
|
+
)
|
|
152
|
+
]
|
|
153
|
+
},
|
|
154
|
+
`${check.label}-${index}`
|
|
155
|
+
)) })
|
|
156
|
+
] }) });
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
export { AnimationRiskScoring };
|
|
160
|
+
//# sourceMappingURL=chunk-HTYR73ON.js.map
|
|
161
|
+
//# sourceMappingURL=chunk-HTYR73ON.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/animations/animation-risk-scoring.tsx"],"names":[],"mappings":";;;;;;;;AAsBA,IAAM,SAAA,GAAwB;AAAA,EAC5B;AAAA,IACE,GAAA,EAAK,UAAA;AAAA,IACL,QAAA,EAAU,cAAA;AAAA,IACV,KAAA,EAAO,EAAA;AAAA,IACP,KAAA,EAAO,KAAA;AAAA,IACP,MAAA,EAAQ,kBAAA;AAAA,IACR,SAAA,EAAW,gBAAA;AAAA,IACX,IAAA,EAAM,WAAA;AAAA,IACN,MAAA,EAAQ;AAAA,MACN,EAAE,KAAA,EAAO,WAAA,EAAa,MAAA,EAAQ,OAAA,EAAS,IAAI,IAAA,EAAK;AAAA,MAChD,EAAE,KAAA,EAAO,eAAA,EAAiB,MAAA,EAAQ,OAAA,EAAS,IAAI,IAAA,EAAK;AAAA,MACpD,EAAE,KAAA,EAAO,aAAA,EAAe,MAAA,EAAQ,UAAA,EAAY,IAAI,IAAA,EAAK;AAAA,MACrD,EAAE,KAAA,EAAO,WAAA,EAAa,MAAA,EAAQ,aAAA,EAAe,IAAI,IAAA;AAAK;AACxD,GACF;AAAA,EACA;AAAA,IACE,GAAA,EAAK,UAAA;AAAA,IACL,QAAA,EAAU,cAAA;AAAA,IACV,KAAA,EAAO,EAAA;AAAA,IACP,KAAA,EAAO,MAAA;AAAA,IACP,MAAA,EAAQ,cAAA;AAAA,IACR,SAAA,EAAW,YAAA;AAAA,IACX,IAAA,EAAM,WAAA;AAA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A,CAAC,SAAI,SAAA,EAAU,6BAAA,EACZ,YAAE,MAAA,CAAO,GAAA,CAAI,CAAC,KAAA,EAAO,CAAA,qBACpB,IAAA;AAAA,MAAC,CAAA,CAAE,GAAA;AAAA,MAAF;AAAA,QAEC,OAAA,EAAS,EAAE,OAAA,EAAS,CAAA,EAAG,GAAG,CAAA,EAAE;AAAA,QAC5B,OAAA,EAAS,EAAE,OAAA,EAAS,CAAA,EAAG,GAAG,CAAA,EAAE;AAAA,QAC5B,YAAY,EAAE,QAAA,EAAU,MAAM,KAAA,EAAO,GAAA,GAAM,IAAI,IAAA,EAAK;AAAA,QACpD,SAAA,EAAU,wFAAA;AAAA,QAEV,QAAA,EAAA;AAAA,0BAAA,GAAA,CAAC,MAAA,EAAA,EAAK,SAAA,EAAU,uCAAA,EAAyC,QAAA,EAAA,KAAA,CAAM,KAAA,EAAM,CAAA;AAAA,0BACrE,GAAA;AAAA,YAAC,MAAA;AAAA,YAAA;AAAA,cACC,SAAA,EAAW,EAAA;AAAA,gBACT,2BAAA;AAAA,gBACA,KAAA,CAAM,KAAK,kBAAA,GAAqB;AAAA,eAClC;AAAA,cAEC,QAAA,EAAA,KAAA,CAAM;AAAA;AAAA;AACT;AAAA,OAAA;AAAA,MAdK,CAAA,EAAG,KAAA,CAAM,KAAK,CAAA,CAAA,EAAI,KAAK,CAAA;AAAA,KAgB/B,CAAA,EACH;AAAA,GAAA,EACF,CAAA,EACF,CAAA;AAEJ","file":"chunk-HTYR73ON.js","sourcesContent":["\"use client\"\n\nimport { AlertTriangle, ShieldAlert, ShieldCheck } from \"lucide-react\"\nimport { domAnimation, LazyMotion, m } from \"motion/react\"\nimport { useEffect, useState } from \"react\"\n\nimport { useCycleIndex } from \"../hooks/use-cycle-index\"\n\nimport { EASE_OUT } from \"../lib/animation\"\nimport { cn } from \"../lib/utils\"\n\ntype Scenario = {\n txn: string\n corridor: string\n score: number\n level: \"Low\" | \"Medium\" | \"High\"\n colour: string\n barColour: string\n icon: typeof ShieldCheck\n checks: { label: string; result: string; ok: boolean }[]\n}\n\nconst SCENARIOS: Scenario[] = [\n {\n txn: \"TXN-0847\",\n corridor: \"AU \\u2192 SG\",\n score: 18,\n level: \"Low\",\n colour: \"text-emerald-600\",\n barColour: \"bg-emerald-400\",\n icon: ShieldCheck,\n checks: [\n { label: \"Sanctions\", result: \"Clear\", ok: true },\n { label: \"PEP screening\", result: \"Clear\", ok: true },\n { label: \"Travel Rule\", result: \"Verified\", ok: true },\n { label: \"Threshold\", result: \"Below limit\", ok: true },\n ],\n },\n {\n txn: \"TXN-0846\",\n corridor: \"HK \\u2192 GB\",\n score: 72,\n level: \"High\",\n colour: \"text-red-500\",\n barColour: \"bg-red-400\",\n icon: ShieldAlert,\n checks: [\n { label: \"Sanctions\", result: \"Clear\", ok: true },\n { label: \"PEP screening\", result: \"1 match\", ok: false },\n { label: \"Travel Rule\", result: \"Verified\", ok: true },\n { label: \"Threshold\", result: \"Exceeded\", ok: false },\n ],\n },\n {\n txn: \"TXN-0845\",\n corridor: \"AE \\u2192 NL\",\n score: 41,\n level: \"Medium\",\n colour: \"text-amber-500\",\n barColour: \"bg-amber-400\",\n icon: AlertTriangle,\n checks: [\n { label: \"Sanctions\", result: \"Clear\", ok: true },\n { label: \"PEP screening\", result: \"Clear\", ok: true },\n { label: \"Travel Rule\", result: \"Pending\", ok: false },\n { label: \"Threshold\", result: \"Below limit\", ok: true },\n ],\n },\n]\n\nconst CYCLE_MS = 3800\n\nfunction AnimatedNumber({ value, duration = 1000 }: { value: number; duration?: number }) {\n const [display, setDisplay] = useState(0)\n\n useEffect(() => {\n let start: number | null = null\n let raf: number\n\n function tick(ts: number) {\n if (start === null) start = ts\n const progress = Math.min((ts - start) / duration, 1)\n const eased = 1 - (1 - progress) ** 3\n setDisplay(Math.round(value * eased))\n if (progress < 1) raf = requestAnimationFrame(tick)\n }\n\n raf = requestAnimationFrame(tick)\n return () => cancelAnimationFrame(raf)\n }, [value, duration])\n\n return <>{display}</>\n}\n\nexport default function AnimationRiskScoring({ className }: { className?: string }) {\n const [containerRef, index] = useCycleIndex(SCENARIOS.length, CYCLE_MS)\n const s = SCENARIOS[index]\n const Icon = s.icon\n\n return (\n <LazyMotion features={domAnimation}>\n <div ref={containerRef} className={cn(\"flex flex-col p-5\", className)}>\n {/* Header */}\n <div className=\"flex items-center justify-between\">\n <div>\n <p className=\"font-semibold text-[15px] text-forground\">Risk Analysis</p>\n <p className=\"text-[12px] text-gray-400\">Real-time transfer scoring</p>\n </div>\n <m.div\n key={index}\n initial={{ opacity: 0, scale: 0.9 }}\n animate={{ opacity: 1, scale: 1 }}\n className={cn(\n \"flex items-center gap-1.5 rounded-full px-2.5 py-1\",\n s.level === \"Low\"\n ? \"bg-emerald-50\"\n : s.level === \"Medium\"\n ? \"bg-amber-50\"\n : \"bg-red-50\",\n )}\n >\n <Icon className={cn(\"size-3.5\", s.colour)} strokeWidth={2} />\n <span className={cn(\"font-semibold text-[11px]\", s.colour)}>{s.level}</span>\n </m.div>\n </div>\n\n {/* Transfer info */}\n <m.div\n key={`info-${index}`}\n initial={{ opacity: 0, y: 6 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.3 }}\n className=\"mt-4 flex items-center gap-3 rounded-lg border border-gray-100 bg-gray-50 px-3 py-2.5\"\n >\n <div className=\"flex-1\">\n <p className=\"font-bold font-mono text-[11px] text-gray-400\">{s.txn}</p>\n <p className=\"font-medium text-[12px] text-gray-700\">{s.corridor}</p>\n </div>\n <div className=\"text-right\">\n <p className=\"font-bold font-mono text-2xl text-gray-900\">\n <AnimatedNumber value={s.score} />\n </p>\n <p className=\"text-[10px] text-gray-400\">/100</p>\n </div>\n </m.div>\n\n {/* Score bar */}\n <div className=\"mt-3 h-2 overflow-hidden rounded-full bg-gray-100\">\n <m.div\n key={`bar-${index}`}\n className={cn(\"h-full rounded-full\", s.barColour)}\n style={{ transformOrigin: \"left\", width: \"100%\" }}\n initial={{ scaleX: 0 }}\n animate={{ scaleX: s.score / 100 }}\n transition={{ duration: 1, ease: EASE_OUT }}\n />\n </div>\n\n {/* Check results */}\n <div className=\"mt-4 grid grid-cols-2 gap-2\">\n {s.checks.map((check, i) => (\n <m.div\n key={`${check.label}-${index}`}\n initial={{ opacity: 0, y: 4 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.25, delay: 0.1 + i * 0.08 }}\n className=\"flex items-center justify-between rounded-lg border border-gray-100 bg-white px-3 py-2\"\n >\n <span className=\"font-medium text-[11px] text-gray-600\">{check.label}</span>\n <span\n className={cn(\n \"font-semibold text-[10px]\",\n check.ok ? \"text-emerald-600\" : \"text-red-500\",\n )}\n >\n {check.result}\n </span>\n </m.div>\n ))}\n </div>\n </div>\n </LazyMotion>\n )\n}\n"]}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn } from './chunk-GZNLQE3I.js';
|
|
3
|
+
import { LazyMotion, domAnimation, m } from 'motion/react';
|
|
4
|
+
import { useState, useRef, useCallback, useEffect } from 'react';
|
|
5
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
var REQUEST = [
|
|
8
|
+
{ text: "POST /v1/transfers/screen", colour: "text-emerald-400" },
|
|
9
|
+
{ text: "Authorization: Bearer sk_live_\u2022\u2022\u2022", colour: "text-gray-500" },
|
|
10
|
+
{ text: "Content-Type: application/json", colour: "text-gray-500" },
|
|
11
|
+
{ text: "" },
|
|
12
|
+
{ text: "{", colour: "text-gray-300" },
|
|
13
|
+
{ text: '"transfer_id": "TXN-0847",', colour: "text-[#00D4FF]", indent: 1 },
|
|
14
|
+
{ text: '"originator": {', colour: "text-gray-300", indent: 1 },
|
|
15
|
+
{ text: '"vasp_id": "vasp_au_001",', colour: "text-amber-400", indent: 2 },
|
|
16
|
+
{ text: '"jurisdiction": "AU"', colour: "text-amber-400", indent: 2 },
|
|
17
|
+
{ text: "},", colour: "text-gray-300", indent: 1 },
|
|
18
|
+
{ text: '"beneficiary": {', colour: "text-gray-300", indent: 1 },
|
|
19
|
+
{ text: '"vasp_id": "vasp_sg_042",', colour: "text-amber-400", indent: 2 },
|
|
20
|
+
{ text: '"jurisdiction": "SG"', colour: "text-amber-400", indent: 2 },
|
|
21
|
+
{ text: "},", colour: "text-gray-300", indent: 1 },
|
|
22
|
+
{ text: '"amount": "45000.00",', colour: "text-violet-400", indent: 1 },
|
|
23
|
+
{ text: '"currency": "USD"', colour: "text-violet-400", indent: 1 },
|
|
24
|
+
{ text: "}", colour: "text-gray-300" }
|
|
25
|
+
];
|
|
26
|
+
var RESPONSE = [
|
|
27
|
+
{ text: "200 OK", colour: "text-emerald-400" },
|
|
28
|
+
{ text: "" },
|
|
29
|
+
{ text: "{", colour: "text-gray-300" },
|
|
30
|
+
{ text: '"status": "compliant",', colour: "text-emerald-400", indent: 1 },
|
|
31
|
+
{ text: '"risk_score": 18,', colour: "text-[#00D4FF]", indent: 1 },
|
|
32
|
+
{ text: '"travel_rule": "verified",', colour: "text-emerald-400", indent: 1 },
|
|
33
|
+
{ text: '"jurisdiction_pair": "AU\u2192SG",', colour: "text-amber-400", indent: 1 },
|
|
34
|
+
{ text: '"report_ref": "CR-2024-0847"', colour: "text-violet-400", indent: 1 },
|
|
35
|
+
{ text: "}", colour: "text-gray-300" }
|
|
36
|
+
];
|
|
37
|
+
function AnimationRestApi({ className }) {
|
|
38
|
+
const [phase, setPhase] = useState("request");
|
|
39
|
+
const [visibleLines, setVisibleLines] = useState(0);
|
|
40
|
+
const scrollRef = useRef(null);
|
|
41
|
+
const lines = phase === "request" ? REQUEST : RESPONSE;
|
|
42
|
+
const reset = useCallback(() => {
|
|
43
|
+
setPhase("request");
|
|
44
|
+
setVisibleLines(0);
|
|
45
|
+
}, []);
|
|
46
|
+
useEffect(() => {
|
|
47
|
+
if (visibleLines < lines.length) {
|
|
48
|
+
const id = setTimeout(() => setVisibleLines((v) => v + 1), 80);
|
|
49
|
+
return () => clearTimeout(id);
|
|
50
|
+
} else if (phase === "request") {
|
|
51
|
+
const id = setTimeout(() => {
|
|
52
|
+
setPhase("response");
|
|
53
|
+
setVisibleLines(0);
|
|
54
|
+
}, 1200);
|
|
55
|
+
return () => clearTimeout(id);
|
|
56
|
+
} else {
|
|
57
|
+
const id = setTimeout(reset, 3e3);
|
|
58
|
+
return () => clearTimeout(id);
|
|
59
|
+
}
|
|
60
|
+
}, [visibleLines, lines.length, phase, reset]);
|
|
61
|
+
useEffect(() => {
|
|
62
|
+
const el = scrollRef.current;
|
|
63
|
+
if (!el) return;
|
|
64
|
+
requestAnimationFrame(() => {
|
|
65
|
+
el.scrollTop = el.scrollHeight;
|
|
66
|
+
});
|
|
67
|
+
}, []);
|
|
68
|
+
return /* @__PURE__ */ jsx(LazyMotion, { features: domAnimation, children: /* @__PURE__ */ jsxs("div", { className: cn("flex flex-col bg-[#1a1a2e]", className), children: [
|
|
69
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 border-white/10 border-b px-4 py-2", children: [
|
|
70
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-1.5", children: [
|
|
71
|
+
/* @__PURE__ */ jsx("span", { className: "size-2.5 rounded-full bg-red-400/80" }),
|
|
72
|
+
/* @__PURE__ */ jsx("span", { className: "size-2.5 rounded-full bg-amber-400/80" }),
|
|
73
|
+
/* @__PURE__ */ jsx("span", { className: "size-2.5 rounded-full bg-emerald-400/80" })
|
|
74
|
+
] }),
|
|
75
|
+
/* @__PURE__ */ jsx("span", { className: "ml-2 font-mono text-[10px] text-white/40", children: "cogentic-api" }),
|
|
76
|
+
/* @__PURE__ */ jsx(
|
|
77
|
+
m.span,
|
|
78
|
+
{
|
|
79
|
+
initial: { opacity: 0 },
|
|
80
|
+
animate: { opacity: 1 },
|
|
81
|
+
className: cn(
|
|
82
|
+
"ml-auto rounded-full px-2 py-0.5 font-bold text-[9px]",
|
|
83
|
+
phase === "request" ? "bg-amber-500/20 text-amber-300" : "bg-emerald-500/20 text-emerald-300"
|
|
84
|
+
),
|
|
85
|
+
children: phase === "request" ? "REQUEST" : "RESPONSE"
|
|
86
|
+
},
|
|
87
|
+
phase
|
|
88
|
+
)
|
|
89
|
+
] }),
|
|
90
|
+
/* @__PURE__ */ jsx("div", { ref: scrollRef, className: "scrollbar-none flex-1 overflow-y-auto px-4 py-3", children: /* @__PURE__ */ jsxs("div", { className: "space-y-0.5", children: [
|
|
91
|
+
lines.slice(0, visibleLines).map((line, i) => {
|
|
92
|
+
var _a, _b;
|
|
93
|
+
return /* @__PURE__ */ jsxs(
|
|
94
|
+
m.div,
|
|
95
|
+
{
|
|
96
|
+
initial: { opacity: 0 },
|
|
97
|
+
animate: { opacity: 1 },
|
|
98
|
+
className: "flex",
|
|
99
|
+
children: [
|
|
100
|
+
/* @__PURE__ */ jsx("span", { className: "w-5 shrink-0 text-right font-mono text-[10px] text-white/20", children: i + 1 }),
|
|
101
|
+
/* @__PURE__ */ jsx(
|
|
102
|
+
"span",
|
|
103
|
+
{
|
|
104
|
+
className: cn("ml-3 font-mono text-[11px]", (_a = line.colour) != null ? _a : "text-white/60"),
|
|
105
|
+
style: { paddingLeft: ((_b = line.indent) != null ? _b : 0) * 16 },
|
|
106
|
+
children: line.text || "\xA0"
|
|
107
|
+
}
|
|
108
|
+
)
|
|
109
|
+
]
|
|
110
|
+
},
|
|
111
|
+
`${phase}-${i}`
|
|
112
|
+
);
|
|
113
|
+
}),
|
|
114
|
+
visibleLines < lines.length && /* @__PURE__ */ jsxs("div", { className: "flex", children: [
|
|
115
|
+
/* @__PURE__ */ jsx("span", { className: "w-5" }),
|
|
116
|
+
/* @__PURE__ */ jsx("span", { className: "ml-3 animate-pulse font-mono text-[11px] text-white/30", children: "\u2588" })
|
|
117
|
+
] })
|
|
118
|
+
] }) })
|
|
119
|
+
] }) });
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export { AnimationRestApi };
|
|
123
|
+
//# sourceMappingURL=chunk-I26ZXVSY.js.map
|
|
124
|
+
//# sourceMapping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["\"use client\"\n\nimport { domAnimation, LazyMotion, m } from \"motion/react\"\nimport { useCallback, useEffect, useRef, useState } from \"react\"\n\nimport { cn } from \"../lib/utils\"\n\ntype CodeLine = {\n text: string\n colour?: string\n indent?: number\n}\n\nconst REQUEST: CodeLine[] = [\n { text: \"POST /v1/transfers/screen\", colour: \"text-emerald-400\" },\n { text: \"Authorization: Bearer sk_live_\\u2022\\u2022\\u2022\", colour: \"text-gray-500\" },\n { text: \"Content-Type: application/json\", colour: \"text-gray-500\" },\n { text: \"\" },\n { text: \"{\", colour: \"text-gray-300\" },\n { text: '\"transfer_id\": \"TXN-0847\",', colour: \"text-[#00D4FF]\", indent: 1 },\n { text: '\"originator\": {', colour: \"text-gray-300\", indent: 1 },\n { text: '\"vasp_id\": \"vasp_au_001\",', colour: \"text-amber-400\", indent: 2 },\n { text: '\"jurisdiction\": \"AU\"', colour: \"text-amber-400\", indent: 2 },\n { text: \"},\", colour: \"text-gray-300\", indent: 1 },\n { text: '\"beneficiary\": {', colour: \"text-gray-300\", indent: 1 },\n { text: '\"vasp_id\": \"vasp_sg_042\",', colour: \"text-amber-400\", indent: 2 },\n { text: '\"jurisdiction\": \"SG\"', colour: \"text-amber-400\", indent: 2 },\n { text: \"},\", colour: \"text-gray-300\", indent: 1 },\n { text: '\"amount\": \"45000.00\",', colour: \"text-violet-400\", indent: 1 },\n { text: '\"currency\": \"USD\"', colour: \"text-violet-400\", indent: 1 },\n { text: \"}\", colour: \"text-gray-300\" },\n]\n\nconst RESPONSE: CodeLine[] = [\n { text: \"200 OK\", colour: \"text-emerald-400\" },\n { text: \"\" },\n { text: \"{\", colour: \"text-gray-300\" },\n { text: '\"status\": \"compliant\",', colour: \"text-emerald-400\", indent: 1 },\n { text: '\"risk_score\": 18,', colour: \"text-[#00D4FF]\", indent: 1 },\n { text: '\"travel_rule\": \"verified\",', colour: \"text-emerald-400\", indent: 1 },\n { text: '\"jurisdiction_pair\": \"AU→SG\",', colour: \"text-amber-400\", indent: 1 },\n { text: '\"report_ref\": \"CR-2024-0847\"', colour: \"text-violet-400\", indent: 1 },\n { text: \"}\", colour: \"text-gray-300\" },\n]\n\nexport default function AnimationRestApi({ className }: { className?: string }) {\n const [phase, setPhase] = useState<\"request\" | \"response\">(\"request\")\n const [visibleLines, setVisibleLines] = useState(0)\n const scrollRef = useRef<HTMLDivElement>(null)\n const lines = phase === \"request\" ? REQUEST : RESPONSE\n\n const reset = useCallback(() => {\n setPhase(\"request\")\n setVisibleLines(0)\n }, [])\n\n useEffect(() => {\n if (visibleLines < lines.length) {\n const id = setTimeout(() => setVisibleLines((v) => v + 1), 80)\n return () => clearTimeout(id)\n } else if (phase === \"request\") {\n const id = setTimeout(() => {\n setPhase(\"response\")\n setVisibleLines(0)\n }, 1200)\n return () => clearTimeout(id)\n } else {\n const id = setTimeout(reset, 3000)\n return () => clearTimeout(id)\n }\n }, [visibleLines, lines.length, phase, reset])\n\n useEffect(() => {\n const el = scrollRef.current\n if (!el) return\n requestAnimationFrame(() => {\n el.scrollTop = el.scrollHeight\n })\n }, [])\n\n return (\n <LazyMotion features={domAnimation}>\n <div className={cn(\"flex flex-col bg-[#1a1a2e]\", className)}>\n {/* Tab bar */}\n <div className=\"flex items-center gap-3 border-white/10 border-b px-4 py-2\">\n <div className=\"flex gap-1.5\">\n <span className=\"size-2.5 rounded-full bg-red-400/80\" />\n <span className=\"size-2.5 rounded-full bg-amber-400/80\" />\n <span className=\"size-2.5 rounded-full bg-emerald-400/80\" />\n </div>\n <span className=\"ml-2 font-mono text-[10px] text-white/40\">cogentic-api</span>\n <m.span\n key={phase}\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n className={cn(\n \"ml-auto rounded-full px-2 py-0.5 font-bold text-[9px]\",\n phase === \"request\"\n ? \"bg-amber-500/20 text-amber-300\"\n : \"bg-emerald-500/20 text-emerald-300\",\n )}\n >\n {phase === \"request\" ? \"REQUEST\" : \"RESPONSE\"}\n </m.span>\n </div>\n\n {/* Code */}\n <div ref={scrollRef} className=\"scrollbar-none flex-1 overflow-y-auto px-4 py-3\">\n <div className=\"space-y-0.5\">\n {lines.slice(0, visibleLines).map((line, i) => (\n <m.div\n key={`${phase}-${i}`}\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n className=\"flex\"\n >\n <span className=\"w-5 shrink-0 text-right font-mono text-[10px] text-white/20\">\n {i + 1}\n </span>\n <span\n className={cn(\"ml-3 font-mono text-[11px]\", line.colour ?? \"text-white/60\")}\n style={{ paddingLeft: (line.indent ?? 0) * 16 }}\n >\n {line.text || \"\\u00A0\"}\n </span>\n </m.div>\n ))}\n {visibleLines < lines.length && (\n <div className=\"flex\">\n <span className=\"w-5\" />\n <span className=\"ml-3 animate-pulse font-mono text-[11px] text-white/30\">\n {\"\\u2588\"}\n </span>\n </div>\n )}\n </div>\n </div>\n </div>\n </LazyMotion>\n )\n}\n"]}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { EASE_OUT } from './chunk-TAPJEVUA.js';
|
|
3
|
+
import { cn } from './chunk-GZNLQE3I.js';
|
|
4
|
+
import { motion } from 'motion/react';
|
|
5
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
function AnimationTeamsNotification({ className }) {
|
|
8
|
+
return /* @__PURE__ */ jsxs("div", { className: cn("flex flex-col bg-[#f5f5f5] p-4", className), children: [
|
|
9
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 pb-2.5", children: [
|
|
10
|
+
/* @__PURE__ */ jsx("div", { className: "flex size-5 items-center justify-center rounded bg-[#6264A7]", children: /* @__PURE__ */ jsx("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsx("path", { d: "M1 3H9M1 5H6M1 7H7", stroke: "white", strokeWidth: "1", strokeLinecap: "round" }) }) }),
|
|
11
|
+
/* @__PURE__ */ jsx("span", { className: "font-semibold text-[13px] text-gray-900", children: "Compliance Reviews" })
|
|
12
|
+
] }),
|
|
13
|
+
/* @__PURE__ */ jsxs(
|
|
14
|
+
motion.div,
|
|
15
|
+
{
|
|
16
|
+
initial: { opacity: 0, y: 10 },
|
|
17
|
+
animate: { opacity: 1, y: 0 },
|
|
18
|
+
transition: { duration: 0.5, ease: EASE_OUT, delay: 0.3 },
|
|
19
|
+
className: "rounded-lg bg-white shadow-sm",
|
|
20
|
+
children: [
|
|
21
|
+
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-t-lg bg-[#6264A7]" }),
|
|
22
|
+
/* @__PURE__ */ jsxs("div", { className: "p-3.5", children: [
|
|
23
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
24
|
+
/* @__PURE__ */ jsx("div", { className: "flex size-6 items-center justify-center rounded bg-gray-900", children: /* @__PURE__ */ jsx("svg", { width: "10", height: "10", viewBox: "0 0 14 14", fill: "none", children: /* @__PURE__ */ jsx("path", { d: "M7 1L12 4V10L7 13L2 10V4L7 1Z", stroke: "#00D4FF", strokeWidth: "1.2" }) }) }),
|
|
25
|
+
/* @__PURE__ */ jsx("span", { className: "font-bold text-[12px] text-gray-900", children: "Cogentic Compliance" }),
|
|
26
|
+
/* @__PURE__ */ jsx("span", { className: "text-[10px] text-gray-400", children: "10:42 AM" })
|
|
27
|
+
] }),
|
|
28
|
+
/* @__PURE__ */ jsxs(
|
|
29
|
+
motion.div,
|
|
30
|
+
{
|
|
31
|
+
initial: { opacity: 0 },
|
|
32
|
+
animate: { opacity: 1 },
|
|
33
|
+
transition: { duration: 0.4, delay: 0.6 },
|
|
34
|
+
children: [
|
|
35
|
+
/* @__PURE__ */ jsx("p", { className: "mt-2.5 font-semibold text-[12px] text-gray-900", children: "Transfer requires review" }),
|
|
36
|
+
/* @__PURE__ */ jsx("div", { className: "mt-2 grid grid-cols-2 gap-x-4 gap-y-1.5", children: [
|
|
37
|
+
{ label: "Transfer", value: "TXN-0847" },
|
|
38
|
+
{ label: "Corridor", value: "AU \u2192 SG" },
|
|
39
|
+
{ label: "Risk score", value: "72 / 100", highlight: true },
|
|
40
|
+
{ label: "Trigger", value: "PEP match" }
|
|
41
|
+
].map((item) => /* @__PURE__ */ jsxs("div", { children: [
|
|
42
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium text-[10px] text-gray-400", children: item.label }),
|
|
43
|
+
/* @__PURE__ */ jsx(
|
|
44
|
+
"p",
|
|
45
|
+
{
|
|
46
|
+
className: cn(
|
|
47
|
+
"font-semibold text-[11px]",
|
|
48
|
+
item.highlight ? "text-red-500" : "text-gray-800"
|
|
49
|
+
),
|
|
50
|
+
children: item.value
|
|
51
|
+
}
|
|
52
|
+
)
|
|
53
|
+
] }, item.label)) }),
|
|
54
|
+
/* @__PURE__ */ jsxs(
|
|
55
|
+
motion.div,
|
|
56
|
+
{
|
|
57
|
+
initial: { opacity: 0, scale: 0.95 },
|
|
58
|
+
animate: { opacity: 1, scale: 1 },
|
|
59
|
+
transition: { duration: 0.3, delay: 0.9 },
|
|
60
|
+
className: "mt-2.5 flex items-center gap-2 rounded bg-amber-50 px-2.5 py-1.5",
|
|
61
|
+
children: [
|
|
62
|
+
/* @__PURE__ */ jsx("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", children: /* @__PURE__ */ jsx("path", { d: "M6 1L11 3.5V8.5L6 11L1 8.5V3.5L6 1Z", stroke: "#D97706", strokeWidth: "1" }) }),
|
|
63
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium text-[10px] text-amber-700", children: "SG jurisdiction requires beneficiary verification within 24h" })
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
)
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
),
|
|
70
|
+
/* @__PURE__ */ jsxs(
|
|
71
|
+
motion.div,
|
|
72
|
+
{
|
|
73
|
+
initial: { opacity: 0 },
|
|
74
|
+
animate: { opacity: 1 },
|
|
75
|
+
transition: { duration: 0.3, delay: 1.1 },
|
|
76
|
+
className: "mt-3 flex gap-2",
|
|
77
|
+
children: [
|
|
78
|
+
/* @__PURE__ */ jsx("span", { className: "rounded bg-[#6264A7] px-3 py-1.5 font-semibold text-[11px] text-white", children: "Review transfer" }),
|
|
79
|
+
/* @__PURE__ */ jsx("span", { className: "rounded border border-gray-200 px-3 py-1.5 font-semibold text-[11px] text-gray-600", children: "Assign reviewer" })
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
)
|
|
83
|
+
] })
|
|
84
|
+
]
|
|
85
|
+
}
|
|
86
|
+
)
|
|
87
|
+
] });
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export { AnimationTeamsNotification };
|
|
91
|
+
//# sourceMappingURL=chunk-IKATDPHG.js.map
|
|
92
|
+
//# sourceMappingURL=chunk-IKATDPHG.js.map
|