@vpdev2/metakyc-sdk 1.0.17 → 1.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/steps/OverviewStep.d.ts.map +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +60 -129
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5,7 +5,7 @@ import et from "axios";
|
|
|
5
5
|
import * as Me from "react";
|
|
6
6
|
import ie, { createContext as tt, useState as N, useMemo as Re, useEffect as W, useContext as rt, useRef as H, useCallback as q, forwardRef as Le } from "react";
|
|
7
7
|
import { jsx as n, jsxs as o, Fragment as nt } from "react/jsx-runtime";
|
|
8
|
-
import { get as De, set as Ee, appendErrors as
|
|
8
|
+
import { get as De, set as Ee, appendErrors as je, useForm as Te, Controller as J } from "react-hook-form";
|
|
9
9
|
import { z as ue } from "zod";
|
|
10
10
|
var B = /* @__PURE__ */ ((t) => (t[t.IdentitySdk = 0] = "IdentitySdk", t[t.RiskScoring = 1] = "RiskScoring", t[t.Questionaries = 2] = "Questionaries", t[t.AdditionalData = 3] = "AdditionalData", t[t.AppropriatenessTest = 4] = "AppropriatenessTest", t[t.UploadDocument = 5] = "UploadDocument", t[t.ManualReview = 6] = "ManualReview", t[t.Overview = 7] = "Overview", t[t.InvestorCategorization = 8] = "InvestorCategorization", t))(B || {}), Ne = /* @__PURE__ */ ((t) => (t[t.NotStarted = 0] = "NotStarted", t[t.InProgress = 1] = "InProgress", t[t.Success = 2] = "Success", t[t.PartialSuccess = 3] = "PartialSuccess", t[t.Failed = 4] = "Failed", t[t.Skipped = 5] = "Skipped", t[t.AdminReview = 6] = "AdminReview", t[t.SkippedAndAdminReview = 7] = "SkippedAndAdminReview", t))(Ne || {}), le = /* @__PURE__ */ ((t) => (t[t.None = 0] = "None", t[t.InProgress = 1] = "InProgress", t[t.Finished = 2] = "Finished", t[t.OnHold = 3] = "OnHold", t[t.IdentityPending = 4] = "IdentityPending", t))(le || {}), st = /* @__PURE__ */ ((t) => (t[t.None = 0] = "None", t[t.RepresentativeKYC = 1] = "RepresentativeKYC", t[t.ManualRiskCriteria = 2] = "ManualRiskCriteria", t[t.UploadDocumentReview = 3] = "UploadDocumentReview", t[t.AdminReview = 4] = "AdminReview", t))(st || {}), at = /* @__PURE__ */ ((t) => (t[t.LowRisk = 0] = "LowRisk", t[t.MediumRisk = 1] = "MediumRisk", t[t.HighRisk = 2] = "HighRisk", t[t.Alert = 3] = "Alert", t))(at || {}), pe = /* @__PURE__ */ ((t) => (t[t.None = 0] = "None", t[t.Pending = 1] = "Pending", t[t.Approved = 2] = "Approved", t[t.Rejected = 3] = "Rejected", t[t.ResendRequested = 4] = "ResendRequested", t[t.Unknown = 5] = "Unknown", t[t.InProgress = 6] = "InProgress", t))(pe || {}), ge = /* @__PURE__ */ ((t) => (t[t.Approved = 0] = "Approved", t[t.Reject = 1] = "Reject", t[t.UnderReview = 2] = "UnderReview", t[t.Closed = 3] = "Closed", t[t.AdminReview = 4] = "AdminReview", t[t.New = 5] = "New", t[t.InProgress = 6] = "InProgress", t))(ge || {}), it = /* @__PURE__ */ ((t) => (t[t.ProviderResultPending = 0] = "ProviderResultPending", t[t.ProviderResultReceived = 1] = "ProviderResultReceived", t[t.Canceled = 2] = "Canceled", t[t.ExtendedToNewApplicant = 3] = "ExtendedToNewApplicant", t))(it || {}), ot = /* @__PURE__ */ ((t) => (t[t.None = 0] = "None", t[t.ProviderResultPending = 1] = "ProviderResultPending", t[t.ProviderResultReceived = 2] = "ProviderResultReceived", t[t.Canceled = 3] = "Canceled", t))(ot || {}), oe = /* @__PURE__ */ ((t) => (t[t.Onfido = 0] = "Onfido", t[t.Sumsub = 2] = "Sumsub", t[t.SardinAI = 3] = "SardinAI", t))(oe || {}), lt = /* @__PURE__ */ ((t) => (t[t.Individual = 0] = "Individual", t[t.Company = 1] = "Company", t))(lt || {}), Se = /* @__PURE__ */ ((t) => (t[t.Male = 0] = "Male", t[t.Female = 1] = "Female", t[t.Other = 2] = "Other", t))(Se || {}), ct = /* @__PURE__ */ ((t) => (t[t.Image = 0] = "Image", t[t.Video = 1] = "Video", t[t.PDF = 2] = "PDF", t[t.OfficePDF = 3] = "OfficePDF", t[t.Custom = 4] = "Custom", t))(ct || {}), dt = /* @__PURE__ */ ((t) => (t[t.Pending = 0] = "Pending", t[t.Approved = 1] = "Approved", t[t.Rejected = 2] = "Rejected", t[t.RequiresRevision = 3] = "RequiresRevision", t))(dt || {}), ut = /* @__PURE__ */ ((t) => (t[t.SingleChoice = 0] = "SingleChoice", t[t.MultipleChoice = 1] = "MultipleChoice", t[t.Text = 2] = "Text", t))(ut || {}), Pe = /* @__PURE__ */ ((t) => (t[t.String = 0] = "String", t[t.Integer = 1] = "Integer", t[t.Decimal = 2] = "Decimal", t[t.Boolean = 3] = "Boolean", t[t.Date = 4] = "Date", t[t.Country = 5] = "Country", t[t.DigitOnly = 6] = "DigitOnly", t))(Pe || {}), mt = /* @__PURE__ */ ((t) => (t[t.Text = 0] = "Text", t[t.Radio = 1] = "Radio", t[t.Checkbox = 2] = "Checkbox", t[t.Dropdown = 3] = "Dropdown", t[t.Country = 4] = "Country", t))(mt || {}), ht = /* @__PURE__ */ ((t) => (t[t.None = 0] = "None", t[t.Country = 1] = "Country", t))(ht || {}), re = /* @__PURE__ */ ((t) => (t[t.Individual = 0] = "Individual", t[t.Sophisticated = 1] = "Sophisticated", t[t.HighNetWorth = 2] = "HighNetWorth", t[t.Business = 3] = "Business", t))(re || {}), pt = /* @__PURE__ */ ((t) => (t[t.Retail = 0] = "Retail", t[t.Professional = 1] = "Professional", t[t.EligibleCounterparty = 2] = "EligibleCounterparty", t))(pt || {});
|
|
11
11
|
const gt = [
|
|
@@ -1338,7 +1338,7 @@ function Br(t) {
|
|
|
1338
1338
|
const e = document.getElementById(t);
|
|
1339
1339
|
e && e.remove();
|
|
1340
1340
|
}
|
|
1341
|
-
class
|
|
1341
|
+
class _t {
|
|
1342
1342
|
constructor(e) {
|
|
1343
1343
|
K(this, "sdk", null);
|
|
1344
1344
|
K(this, "config");
|
|
@@ -1393,7 +1393,7 @@ class jt {
|
|
|
1393
1393
|
this.sdk && this.sdk.on("idCheck.onError", e);
|
|
1394
1394
|
}
|
|
1395
1395
|
}
|
|
1396
|
-
class
|
|
1396
|
+
class jt {
|
|
1397
1397
|
constructor(e) {
|
|
1398
1398
|
K(this, "sdk", null);
|
|
1399
1399
|
K(this, "config");
|
|
@@ -1610,9 +1610,9 @@ class fe {
|
|
|
1610
1610
|
static createProvider(e, r) {
|
|
1611
1611
|
switch (e) {
|
|
1612
1612
|
case oe.Sumsub:
|
|
1613
|
-
return new jt(r);
|
|
1614
|
-
case oe.Onfido:
|
|
1615
1613
|
return new _t(r);
|
|
1614
|
+
case oe.Onfido:
|
|
1615
|
+
return new jt(r);
|
|
1616
1616
|
case oe.SardinAI:
|
|
1617
1617
|
return new Ut(r);
|
|
1618
1618
|
default:
|
|
@@ -1862,7 +1862,7 @@ function Ie(t) {
|
|
|
1862
1862
|
const e = 1024, r = ["Bytes", "KB", "MB", "GB"], s = Math.floor(Math.log(t) / Math.log(e));
|
|
1863
1863
|
return Math.round(t / Math.pow(e, s) * 100) / 100 + " " + r[s];
|
|
1864
1864
|
}
|
|
1865
|
-
function
|
|
1865
|
+
function _r(t) {
|
|
1866
1866
|
return t;
|
|
1867
1867
|
}
|
|
1868
1868
|
function te(...t) {
|
|
@@ -1901,7 +1901,7 @@ function Wt(t) {
|
|
|
1901
1901
|
console.warn("Failed to save workflow state to storage:", e);
|
|
1902
1902
|
}
|
|
1903
1903
|
}
|
|
1904
|
-
function
|
|
1904
|
+
function jr() {
|
|
1905
1905
|
try {
|
|
1906
1906
|
const t = localStorage.getItem(be.WORKFLOW_STATE);
|
|
1907
1907
|
return t ? JSON.parse(t) : null;
|
|
@@ -2408,7 +2408,7 @@ function rr() {
|
|
|
2408
2408
|
stopProgress: g
|
|
2409
2409
|
};
|
|
2410
2410
|
}
|
|
2411
|
-
const
|
|
2411
|
+
const j = ({
|
|
2412
2412
|
children: t,
|
|
2413
2413
|
variant: e = "primary",
|
|
2414
2414
|
size: r = "md",
|
|
@@ -2944,7 +2944,7 @@ function pr(t, e) {
|
|
|
2944
2944
|
});
|
|
2945
2945
|
}), e) {
|
|
2946
2946
|
var d = r[l].types, u = d && d[s.code];
|
|
2947
|
-
r[l] =
|
|
2947
|
+
r[l] = je(l, e, r, a, u ? [].concat(u, s.message) : s.message);
|
|
2948
2948
|
}
|
|
2949
2949
|
t.shift();
|
|
2950
2950
|
}
|
|
@@ -2963,7 +2963,7 @@ function gr(t, e) {
|
|
|
2963
2963
|
});
|
|
2964
2964
|
}), e) {
|
|
2965
2965
|
var d = r[l].types, u = d && d[s.code];
|
|
2966
|
-
r[l] =
|
|
2966
|
+
r[l] = je(l, e, r, a, u ? [].concat(u, s.message) : s.message);
|
|
2967
2967
|
}
|
|
2968
2968
|
t.shift();
|
|
2969
2969
|
}
|
|
@@ -3194,9 +3194,9 @@ const Vr = ue.any(), xr = ({
|
|
|
3194
3194
|
})
|
|
3195
3195
|
) }),
|
|
3196
3196
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3197
|
-
r && /* @__PURE__ */ n(
|
|
3197
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3198
3198
|
/* @__PURE__ */ n(
|
|
3199
|
-
|
|
3199
|
+
j,
|
|
3200
3200
|
{
|
|
3201
3201
|
type: "submit",
|
|
3202
3202
|
isLoading: i,
|
|
@@ -3262,8 +3262,8 @@ const Vr = ue.any(), xr = ({
|
|
|
3262
3262
|
v.id
|
|
3263
3263
|
)) }),
|
|
3264
3264
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3265
|
-
r && /* @__PURE__ */ n(
|
|
3266
|
-
/* @__PURE__ */ n(
|
|
3265
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3266
|
+
/* @__PURE__ */ n(j, { type: "submit", isLoading: i, children: "Continue" })
|
|
3267
3267
|
] })
|
|
3268
3268
|
] }) }) : null;
|
|
3269
3269
|
}, kr = ({ applicantId: t, onComplete: e, onBack: r }) => {
|
|
@@ -3278,82 +3278,13 @@ const Vr = ue.any(), xr = ({
|
|
|
3278
3278
|
/* @__PURE__ */ n("h2", { className: "text-lg font-bold", children: s.title || "Overview" }),
|
|
3279
3279
|
s.description && /* @__PURE__ */ n("p", { className: "text-gray-600 dark:text-gray-400 mt-1", children: s.description })
|
|
3280
3280
|
] }),
|
|
3281
|
-
/* @__PURE__ */
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
className: "metakyc-overview-step-item flex items-start p-4 rounded-lg bg-gray-50 dark:bg-gray-800",
|
|
3286
|
-
style: {
|
|
3287
|
-
border: "0",
|
|
3288
|
-
borderWidth: "0",
|
|
3289
|
-
borderStyle: "none",
|
|
3290
|
-
borderTop: "0",
|
|
3291
|
-
borderBottom: "0",
|
|
3292
|
-
borderLeft: "0",
|
|
3293
|
-
borderRight: "0"
|
|
3294
|
-
},
|
|
3295
|
-
children: [
|
|
3296
|
-
/* @__PURE__ */ n(
|
|
3297
|
-
"div",
|
|
3298
|
-
{
|
|
3299
|
-
className: "metakyc-step-icon flex-shrink-0",
|
|
3300
|
-
style: {
|
|
3301
|
-
border: "0",
|
|
3302
|
-
borderTop: "0"
|
|
3303
|
-
},
|
|
3304
|
-
children: /* @__PURE__ */ n("div", { className: "w-8 h-8 rounded-full bg-green-500 text-white flex items-center justify-center font-medium text-sm", children: "✓" })
|
|
3305
|
-
}
|
|
3306
|
-
),
|
|
3307
|
-
/* @__PURE__ */ o(
|
|
3308
|
-
"div",
|
|
3309
|
-
{
|
|
3310
|
-
className: "metakyc-step-content",
|
|
3311
|
-
style: {
|
|
3312
|
-
flex: 1,
|
|
3313
|
-
marginLeft: "1rem",
|
|
3314
|
-
border: "none",
|
|
3315
|
-
height: "auto",
|
|
3316
|
-
background: "transparent",
|
|
3317
|
-
margin: "0 0 0 1rem"
|
|
3318
|
-
},
|
|
3319
|
-
children: [
|
|
3320
|
-
/* @__PURE__ */ n(
|
|
3321
|
-
"h3",
|
|
3322
|
-
{
|
|
3323
|
-
className: "metakyc-step-title text-lg font-semibold text-gray-900 dark:text-white",
|
|
3324
|
-
style: {
|
|
3325
|
-
border: "0",
|
|
3326
|
-
borderWidth: "0",
|
|
3327
|
-
borderStyle: "none",
|
|
3328
|
-
borderTop: "0",
|
|
3329
|
-
borderBottom: "0",
|
|
3330
|
-
borderLeft: "0",
|
|
3331
|
-
borderRight: "0",
|
|
3332
|
-
paddingTop: "0",
|
|
3333
|
-
marginTop: "0",
|
|
3334
|
-
boxShadow: "none",
|
|
3335
|
-
outline: "none",
|
|
3336
|
-
textDecoration: "none"
|
|
3337
|
-
},
|
|
3338
|
-
children: u.title
|
|
3339
|
-
}
|
|
3340
|
-
),
|
|
3341
|
-
u.description && /* @__PURE__ */ n("p", { className: "metakyc-step-description text-sm text-gray-600 dark:text-gray-400 mt-1", children: u.description })
|
|
3342
|
-
]
|
|
3343
|
-
}
|
|
3344
|
-
)
|
|
3345
|
-
]
|
|
3346
|
-
},
|
|
3347
|
-
u.order
|
|
3348
|
-
)) }) : /* @__PURE__ */ n("div", { className: "text-center py-8", children: /* @__PURE__ */ n("p", { className: "text-gray-600 dark:text-gray-400", children: "Loading overview data..." }) }),
|
|
3349
|
-
s.steps && s.steps.length > 0 && /* @__PURE__ */ n("div", { className: "mt-6 p-4 bg-green-50 dark:bg-green-900/20 border border-green-200 dark:border-green-800 rounded-lg", children: /* @__PURE__ */ o("p", { className: "text-green-800 dark:text-green-300 text-sm", children: [
|
|
3350
|
-
/* @__PURE__ */ n("strong", { children: "✓ All steps completed!" }),
|
|
3351
|
-
" Review the information above and confirm to proceed."
|
|
3352
|
-
] }) })
|
|
3353
|
-
] }),
|
|
3281
|
+
/* @__PURE__ */ n(M, { className: "space-y-8", children: s.steps && s.steps.length > 0 ? s.steps.sort((u, y) => u.order - y.order).map((u) => /* @__PURE__ */ o("div", { className: "space-y-2", children: [
|
|
3282
|
+
/* @__PURE__ */ n("label", { className: "block text-sm font-medium text-gray-700 dark:text-gray-300", children: u.title }),
|
|
3283
|
+
u.description && /* @__PURE__ */ n("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: u.description })
|
|
3284
|
+
] }, u.order)) : /* @__PURE__ */ n("div", { className: "text-center py-8", children: /* @__PURE__ */ n("p", { className: "text-gray-600 dark:text-gray-400", children: "Loading overview data..." }) }) }),
|
|
3354
3285
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3355
|
-
r && /* @__PURE__ */ n(
|
|
3356
|
-
/* @__PURE__ */ n(
|
|
3286
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3287
|
+
/* @__PURE__ */ n(j, { onClick: d, isLoading: i, children: "Continue" })
|
|
3357
3288
|
] })
|
|
3358
3289
|
] }) : null;
|
|
3359
3290
|
}, Nr = ({
|
|
@@ -3520,9 +3451,9 @@ const Vr = ue.any(), xr = ({
|
|
|
3520
3451
|
] }, h.id);
|
|
3521
3452
|
}) }),
|
|
3522
3453
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3523
|
-
r && /* @__PURE__ */ n(
|
|
3454
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3524
3455
|
/* @__PURE__ */ n(
|
|
3525
|
-
|
|
3456
|
+
j,
|
|
3526
3457
|
{
|
|
3527
3458
|
type: "submit",
|
|
3528
3459
|
isLoading: i,
|
|
@@ -3664,9 +3595,9 @@ const Vr = ue.any(), xr = ({
|
|
|
3664
3595
|
] }) })
|
|
3665
3596
|
] }),
|
|
3666
3597
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3667
|
-
r && /* @__PURE__ */ n(
|
|
3598
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3668
3599
|
/* @__PURE__ */ n(
|
|
3669
|
-
|
|
3600
|
+
j,
|
|
3670
3601
|
{
|
|
3671
3602
|
type: "submit",
|
|
3672
3603
|
isLoading: l,
|
|
@@ -3894,7 +3825,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
3894
3825
|
] }),
|
|
3895
3826
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3896
3827
|
/* @__PURE__ */ n(
|
|
3897
|
-
|
|
3828
|
+
j,
|
|
3898
3829
|
{
|
|
3899
3830
|
type: "button",
|
|
3900
3831
|
variant: "outline",
|
|
@@ -3904,7 +3835,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
3904
3835
|
}
|
|
3905
3836
|
),
|
|
3906
3837
|
/* @__PURE__ */ n(
|
|
3907
|
-
|
|
3838
|
+
j,
|
|
3908
3839
|
{
|
|
3909
3840
|
type: "submit",
|
|
3910
3841
|
isLoading: d,
|
|
@@ -3946,9 +3877,9 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
3946
3877
|
U <= 0 && /* @__PURE__ */ n("div", { className: "p-4 bg-red-50 dark:bg-red-900/20 border border-red-200 dark:border-red-800 rounded-lg", children: /* @__PURE__ */ n("p", { className: "text-red-600 dark:text-red-400", children: "You have used all your attempts. Please contact support for assistance." }) })
|
|
3947
3878
|
] }),
|
|
3948
3879
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
3949
|
-
r && /* @__PURE__ */ n(
|
|
3880
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
3950
3881
|
/* @__PURE__ */ n(
|
|
3951
|
-
|
|
3882
|
+
j,
|
|
3952
3883
|
{
|
|
3953
3884
|
type: "button",
|
|
3954
3885
|
onClick: C,
|
|
@@ -3988,15 +3919,15 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
3988
3919
|
return !Ae || Y.has(Ae) ? !1 : (Y.add(Ae), !0);
|
|
3989
3920
|
});
|
|
3990
3921
|
A(ae);
|
|
3991
|
-
const
|
|
3922
|
+
const _ = D.applicantRequestData;
|
|
3992
3923
|
if (U.reset({
|
|
3993
|
-
street: (
|
|
3994
|
-
streetNumber: (
|
|
3995
|
-
city: (
|
|
3996
|
-
zip: (
|
|
3997
|
-
country: (
|
|
3998
|
-
nationality: (
|
|
3999
|
-
phonenumber: (
|
|
3924
|
+
street: (_ == null ? void 0 : _.street) || "",
|
|
3925
|
+
streetNumber: (_ == null ? void 0 : _.streetNumber) || "",
|
|
3926
|
+
city: (_ == null ? void 0 : _.city) || "",
|
|
3927
|
+
zip: (_ == null ? void 0 : _.zip) || "",
|
|
3928
|
+
country: (_ == null ? void 0 : _.country) || "",
|
|
3929
|
+
nationality: (_ == null ? void 0 : _.nationality) || "",
|
|
3930
|
+
phonenumber: (_ == null ? void 0 : _.phonenumber) || ""
|
|
4000
3931
|
}), D.kycRecords && D.kycRecords.length > 0 && D.kycRecords[0].providerTokenObject !== null && !V.current) {
|
|
4001
3932
|
console.log("[Identity] Found existing identity verification, auto-requesting..."), V.current = !0;
|
|
4002
3933
|
try {
|
|
@@ -4071,9 +4002,9 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4071
4002
|
e == null || e();
|
|
4072
4003
|
}, 2e3);
|
|
4073
4004
|
}).catch((Y) => {
|
|
4074
|
-
var
|
|
4005
|
+
var _;
|
|
4075
4006
|
console.error("[SardinAI] Failed to initialize:", Y);
|
|
4076
|
-
const ae = ((
|
|
4007
|
+
const ae = ((_ = Y.message) == null ? void 0 : _.toLowerCase()) || "";
|
|
4077
4008
|
ae.includes("expired") || ae.includes("invalid") || ae.includes("401") || ae.includes("400") ? (O(!0), C("Session expired or invalid. Please restart verification.")) : C(`Failed to initialize: ${Y.message}`);
|
|
4078
4009
|
});
|
|
4079
4010
|
} catch (D) {
|
|
@@ -4166,8 +4097,8 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4166
4097
|
] })
|
|
4167
4098
|
] }),
|
|
4168
4099
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
4169
|
-
r && /* @__PURE__ */ n(
|
|
4170
|
-
/* @__PURE__ */ n(
|
|
4100
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
4101
|
+
/* @__PURE__ */ n(j, { type: "button", onClick: x, disabled: u, children: u ? "Restarting..." : "Restart Verification" })
|
|
4171
4102
|
] })
|
|
4172
4103
|
] });
|
|
4173
4104
|
if (E && l) {
|
|
@@ -4179,7 +4110,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4179
4110
|
/* @__PURE__ */ n("p", { className: "text-gray-600 dark:text-gray-400 mt-1", children: "Please complete the identity verification process" })
|
|
4180
4111
|
] }),
|
|
4181
4112
|
/* @__PURE__ */ n(
|
|
4182
|
-
|
|
4113
|
+
j,
|
|
4183
4114
|
{
|
|
4184
4115
|
type: "button",
|
|
4185
4116
|
variant: "outline",
|
|
@@ -4206,7 +4137,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4206
4137
|
var G, Y, ae;
|
|
4207
4138
|
console.log("[Identity] Iframe loaded");
|
|
4208
4139
|
try {
|
|
4209
|
-
const
|
|
4140
|
+
const _ = D.target, Ce = _.contentDocument || ((G = _.contentWindow) == null ? void 0 : G.document);
|
|
4210
4141
|
if (Ce) {
|
|
4211
4142
|
const me = ((ae = (Y = Ce.body) == null ? void 0 : Y.textContent) == null ? void 0 : ae.toLowerCase()) || "";
|
|
4212
4143
|
(me.includes("expired") || me.includes("invalid") || me.includes("error")) && (console.warn("[Identity] Iframe shows expiration message"), O(!0), C("Your verification link has expired."));
|
|
@@ -4218,7 +4149,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4218
4149
|
}
|
|
4219
4150
|
) })
|
|
4220
4151
|
] }),
|
|
4221
|
-
r && /* @__PURE__ */ n(ne, { children: /* @__PURE__ */ n(
|
|
4152
|
+
r && /* @__PURE__ */ n(ne, { children: /* @__PURE__ */ n(j, { variant: "outline", onClick: r, children: "Back" }) })
|
|
4222
4153
|
] }) : L === oe.SardinAI ? /* @__PURE__ */ o(T, { children: [
|
|
4223
4154
|
/* @__PURE__ */ o(ee, { children: [
|
|
4224
4155
|
/* @__PURE__ */ n("h2", { className: "text-2xl font-bold", children: "Device Risk Assessment" }),
|
|
@@ -4235,7 +4166,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4235
4166
|
/* @__PURE__ */ n("p", { className: "text-gray-600 dark:text-gray-400 mt-1", children: "Please complete the identity verification process" })
|
|
4236
4167
|
] }),
|
|
4237
4168
|
/* @__PURE__ */ n(M, { children: /* @__PURE__ */ n("div", { id: "identity-container", className: "min-h-[400px]" }) }),
|
|
4238
|
-
r && /* @__PURE__ */ n(ne, { children: /* @__PURE__ */ n(
|
|
4169
|
+
r && /* @__PURE__ */ n(ne, { children: /* @__PURE__ */ n(j, { variant: "outline", onClick: r, children: "Back" }) })
|
|
4239
4170
|
] });
|
|
4240
4171
|
}
|
|
4241
4172
|
return /* @__PURE__ */ n("form", { onSubmit: U.handleSubmit(p), children: /* @__PURE__ */ o(T, { children: [
|
|
@@ -4355,11 +4286,11 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4355
4286
|
] })
|
|
4356
4287
|
] }),
|
|
4357
4288
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
4358
|
-
r && /* @__PURE__ */ n(
|
|
4359
|
-
/* @__PURE__ */ n(
|
|
4289
|
+
r && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: r, children: "Back" }),
|
|
4290
|
+
/* @__PURE__ */ n(j, { type: "submit", isLoading: u, children: "Confirm and Start Verification" })
|
|
4360
4291
|
] })
|
|
4361
4292
|
] }) });
|
|
4362
|
-
},
|
|
4293
|
+
}, _e = ({
|
|
4363
4294
|
kycStatus: t,
|
|
4364
4295
|
reviewStatus: e,
|
|
4365
4296
|
workflowResult: r,
|
|
@@ -4493,10 +4424,10 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4493
4424
|
] }) })
|
|
4494
4425
|
] }),
|
|
4495
4426
|
/* @__PURE__ */ o(ne, { className: "flex justify-center gap-4", children: [
|
|
4496
|
-
c.type === "success" && a && /* @__PURE__ */ n(
|
|
4427
|
+
c.type === "success" && a && /* @__PURE__ */ n(j, { onClick: a, size: "lg", children: "Continue" }),
|
|
4497
4428
|
c.type === "error" && /* @__PURE__ */ o(nt, { children: [
|
|
4498
|
-
i && /* @__PURE__ */ n(
|
|
4499
|
-
a && /* @__PURE__ */ n(
|
|
4429
|
+
i && /* @__PURE__ */ n(j, { variant: "outline", onClick: i, children: "Contact Support" }),
|
|
4430
|
+
a && /* @__PURE__ */ n(j, { onClick: a, children: "Try Again" })
|
|
4500
4431
|
] }),
|
|
4501
4432
|
c.type === "pending" && /* @__PURE__ */ n("div", { className: "text-center", children: /* @__PURE__ */ n("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: "Please check back later or wait for our email notification" }) })
|
|
4502
4433
|
] })
|
|
@@ -4734,8 +4665,8 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4734
4665
|
/* @__PURE__ */ n("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4", children: w.map((p) => F(p)) })
|
|
4735
4666
|
] }),
|
|
4736
4667
|
/* @__PURE__ */ o(ne, { className: "flex justify-between", children: [
|
|
4737
|
-
s && /* @__PURE__ */ n(
|
|
4738
|
-
/* @__PURE__ */ n(
|
|
4668
|
+
s && /* @__PURE__ */ n(j, { type: "button", variant: "outline", onClick: s, disabled: g || c, children: "Cancel" }),
|
|
4669
|
+
/* @__PURE__ */ n(j, { type: "submit", isLoading: g || c, children: "Create Applicant" })
|
|
4739
4670
|
] })
|
|
4740
4671
|
] }) }) });
|
|
4741
4672
|
}, Wr = ({
|
|
@@ -4805,7 +4736,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4805
4736
|
] }) }) }) });
|
|
4806
4737
|
if (i.status === le.Finished || i.status === le.OnHold)
|
|
4807
4738
|
return /* @__PURE__ */ n("div", { className: `metakyc-sdk ${a || ""}`, children: /* @__PURE__ */ n(
|
|
4808
|
-
|
|
4739
|
+
_e,
|
|
4809
4740
|
{
|
|
4810
4741
|
kycStatus: i.kycStatus,
|
|
4811
4742
|
reviewStatus: i.reviewStatus,
|
|
@@ -4914,7 +4845,7 @@ Failed to reload test data. Please refresh the page.`);
|
|
|
4914
4845
|
return /* @__PURE__ */ n(Cr, { ...w });
|
|
4915
4846
|
case B.ManualReview:
|
|
4916
4847
|
return /* @__PURE__ */ n(
|
|
4917
|
-
|
|
4848
|
+
_e,
|
|
4918
4849
|
{
|
|
4919
4850
|
kycStatus: i.kycStatus,
|
|
4920
4851
|
reviewStatus: i.reviewStatus,
|
|
@@ -4952,7 +4883,7 @@ export {
|
|
|
4952
4883
|
Cr as AppropriatenessTestStep,
|
|
4953
4884
|
he as Badge,
|
|
4954
4885
|
Et as BaseInformationService,
|
|
4955
|
-
|
|
4886
|
+
j as Button,
|
|
4956
4887
|
T as Card,
|
|
4957
4888
|
M as CardContent,
|
|
4958
4889
|
ne as CardFooter,
|
|
@@ -4981,13 +4912,13 @@ export {
|
|
|
4981
4912
|
pt as InvestorCategoryType,
|
|
4982
4913
|
ot as KycProcessStatus,
|
|
4983
4914
|
pe as KycStatus,
|
|
4984
|
-
|
|
4915
|
+
_e as KycStatusDisplay,
|
|
4985
4916
|
Wr as KycWorkflow,
|
|
4986
4917
|
Er as Logo,
|
|
4987
4918
|
Ke as MetaKYCContext,
|
|
4988
4919
|
de as MetaKYCError,
|
|
4989
4920
|
Or as MetaKYCProvider,
|
|
4990
|
-
|
|
4921
|
+
jt as OnfidoProvider,
|
|
4991
4922
|
St as OverviewService,
|
|
4992
4923
|
kr as OverviewStep,
|
|
4993
4924
|
sr as PhoneInput,
|
|
@@ -5002,7 +4933,7 @@ export {
|
|
|
5002
4933
|
ye as Select,
|
|
5003
4934
|
ce as Spinner,
|
|
5004
4935
|
zt as StepRouter,
|
|
5005
|
-
|
|
4936
|
+
_t as SumsubProvider,
|
|
5006
4937
|
Kt as ThemeManager,
|
|
5007
4938
|
Q as ThemePreset,
|
|
5008
4939
|
Mt as ThemeService,
|
|
@@ -5029,10 +4960,10 @@ export {
|
|
|
5029
4960
|
yr as generateQuestionnaireSchema,
|
|
5030
4961
|
br as generateRiskScoringSchema,
|
|
5031
4962
|
qr as generateUploadDocumentSchema,
|
|
5032
|
-
|
|
4963
|
+
_r as getAcceptString,
|
|
5033
4964
|
Vt as getApplicantId,
|
|
5034
4965
|
xe as getThemePreset,
|
|
5035
|
-
|
|
4966
|
+
jr as getWorkflowState,
|
|
5036
4967
|
Pt as healthcareTheme,
|
|
5037
4968
|
Mr as isScriptLoaded,
|
|
5038
4969
|
Ue as loadScript,
|