vesant-sdk 1.7.1-dev.096c933 → 1.7.1-dev.23e1696
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +27 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +27 -8
- package/dist/index.mjs.map +1 -1
- package/dist/kyc/core.d.mts +1 -1
- package/dist/kyc/core.d.ts +1 -1
- package/dist/kyc/core.js +27 -7
- package/dist/kyc/core.js.map +1 -1
- package/dist/kyc/core.mjs +27 -8
- package/dist/kyc/core.mjs.map +1 -1
- package/dist/kyc/index.d.mts +130 -19
- package/dist/kyc/index.d.ts +130 -19
- package/dist/kyc/index.js +27 -7
- package/dist/kyc/index.js.map +1 -1
- package/dist/kyc/index.mjs +27 -8
- package/dist/kyc/index.mjs.map +1 -1
- package/dist/react.js +128 -22
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +128 -22
- package/dist/react.mjs.map +1 -1
- package/package.json +1 -1
package/dist/react.js
CHANGED
|
@@ -930,19 +930,19 @@ var Close = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0id
|
|
|
930
930
|
var FACE_MESSAGES = {
|
|
931
931
|
idle: "Initializing camera...",
|
|
932
932
|
loading: "Loading face detection...",
|
|
933
|
-
scanning: "Position your face in the
|
|
933
|
+
scanning: "Position your face in the oval",
|
|
934
934
|
too_far: "Face too far. Please move closer to the camera",
|
|
935
935
|
too_close: "Too close. Please move back a little",
|
|
936
|
-
off_center: "Center your face in the
|
|
936
|
+
off_center: "Center your face in the oval",
|
|
937
937
|
ok: "Looking great! Tap the button to capture"
|
|
938
938
|
};
|
|
939
939
|
var FACE_COLORS = {
|
|
940
940
|
idle: "#9ca3af",
|
|
941
|
-
loading: "#
|
|
942
|
-
scanning: "#
|
|
941
|
+
loading: "#ef4444",
|
|
942
|
+
scanning: "#ef4444",
|
|
943
943
|
too_far: "#ef4444",
|
|
944
|
-
too_close: "#
|
|
945
|
-
off_center: "#
|
|
944
|
+
too_close: "#ef4444",
|
|
945
|
+
off_center: "#ef4444",
|
|
946
946
|
ok: "#10b981"
|
|
947
947
|
};
|
|
948
948
|
var MEDIAPIPE_BASE = "https://cdn.jsdelivr.net/npm/@mediapipe/face_detection";
|
|
@@ -1007,11 +1007,24 @@ function loadMediaPipeFaceDetection(assetBasePath) {
|
|
|
1007
1007
|
return loader;
|
|
1008
1008
|
}
|
|
1009
1009
|
|
|
1010
|
+
// src/kyc/hostedJourney.ts
|
|
1011
|
+
var REUSE_KYC_SESSION_EXPIRY_MS = 10 * 60 * 1e3;
|
|
1012
|
+
function tryStartOperation(guard) {
|
|
1013
|
+
if (guard.current) return false;
|
|
1014
|
+
guard.current = true;
|
|
1015
|
+
return true;
|
|
1016
|
+
}
|
|
1017
|
+
function releaseOperation(guard) {
|
|
1018
|
+
guard.current = false;
|
|
1019
|
+
}
|
|
1020
|
+
function retryTarget(hasHostedJourney) {
|
|
1021
|
+
return hasHostedJourney ? "journey" : "capture";
|
|
1022
|
+
}
|
|
1023
|
+
|
|
1010
1024
|
// src/kyc/FaceCaptureModal.tsx
|
|
1011
1025
|
var MOBILE_UA = /Mobi|Android|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i;
|
|
1012
|
-
var SESSION_EXPIRY_MS = 15 * 60 * 1e3;
|
|
1013
1026
|
var LIVENESS_MESSAGES = [
|
|
1014
|
-
"Position your face inside the
|
|
1027
|
+
"Position your face inside the oval",
|
|
1015
1028
|
"Make sure your face is well lit",
|
|
1016
1029
|
"Remove glasses or hats if possible",
|
|
1017
1030
|
"Look straight at the camera, then tap Capture"
|
|
@@ -1020,6 +1033,8 @@ function headerSubtitle(stageKind) {
|
|
|
1020
1033
|
switch (stageKind) {
|
|
1021
1034
|
case "qr":
|
|
1022
1035
|
return "Use your phone to continue";
|
|
1036
|
+
case "journey":
|
|
1037
|
+
return "Follow the steps to verify your identity";
|
|
1023
1038
|
case "accepted":
|
|
1024
1039
|
return "All set";
|
|
1025
1040
|
case "declined":
|
|
@@ -1045,7 +1060,9 @@ function FaceCaptureModal({
|
|
|
1045
1060
|
}) {
|
|
1046
1061
|
const isMobile = typeof navigator !== "undefined" && MOBILE_UA.test(navigator.userAgent);
|
|
1047
1062
|
const initialChoice = defaultDevice ?? (isMobile ? "this" : "ask");
|
|
1063
|
+
const journeyMode = Boolean(session.verification_url);
|
|
1048
1064
|
const initialStage = (() => {
|
|
1065
|
+
if (journeyMode) return { kind: "journey", url: session.verification_url ?? "" };
|
|
1049
1066
|
if (initialChoice === "this") return { kind: "capture" };
|
|
1050
1067
|
if (initialChoice === "mobile") return { kind: "qr", mobileConnected: false };
|
|
1051
1068
|
return { kind: "choose" };
|
|
@@ -1063,19 +1080,20 @@ function FaceCaptureModal({
|
|
|
1063
1080
|
const qrPayload = session.link || `vesant://reuse-kyc?token=${encodeURIComponent(session.token)}`;
|
|
1064
1081
|
const cancelledRef = React.useRef(false);
|
|
1065
1082
|
const submittingRef = React.useRef(false);
|
|
1083
|
+
const journeyRetryingRef = React.useRef(false);
|
|
1066
1084
|
React.useEffect(() => {
|
|
1067
1085
|
const timer = setTimeout(() => {
|
|
1068
1086
|
setStage(
|
|
1069
|
-
(prev) => prev.kind === "choose" || prev.kind === "qr" || prev.kind === "capture" ? { kind: "error", message: "Session expired" } : prev
|
|
1087
|
+
(prev) => prev.kind === "choose" || prev.kind === "qr" || prev.kind === "capture" || prev.kind === "journey" ? { kind: "error", message: "Session expired" } : prev
|
|
1070
1088
|
);
|
|
1071
|
-
},
|
|
1089
|
+
}, REUSE_KYC_SESSION_EXPIRY_MS);
|
|
1072
1090
|
return () => clearTimeout(timer);
|
|
1073
1091
|
}, [session.token]);
|
|
1074
1092
|
React.useEffect(() => {
|
|
1075
1093
|
if (stage.kind !== "qr") return;
|
|
1076
1094
|
let stopped = false;
|
|
1077
1095
|
const intervalMs = 2e3;
|
|
1078
|
-
const deadline = Date.now() +
|
|
1096
|
+
const deadline = Date.now() + REUSE_KYC_SESSION_EXPIRY_MS;
|
|
1079
1097
|
let mobileSeen = stage.mobileConnected;
|
|
1080
1098
|
const tick = async () => {
|
|
1081
1099
|
if (stopped || cancelledRef.current) return;
|
|
@@ -1116,6 +1134,64 @@ function FaceCaptureModal({
|
|
|
1116
1134
|
stopped = true;
|
|
1117
1135
|
};
|
|
1118
1136
|
}, [stage.kind, stage.kind === "qr" ? stage.mobileConnected : false]);
|
|
1137
|
+
React.useEffect(() => {
|
|
1138
|
+
if (stage.kind !== "journey" || !stage.url) return;
|
|
1139
|
+
let stopped = false;
|
|
1140
|
+
const checkOnce = async () => {
|
|
1141
|
+
try {
|
|
1142
|
+
const result = await client.getEventBasedFaceVerificationSessionStatus(session.token);
|
|
1143
|
+
if (applyResult(result)) {
|
|
1144
|
+
stopped = true;
|
|
1145
|
+
return true;
|
|
1146
|
+
}
|
|
1147
|
+
} catch {
|
|
1148
|
+
}
|
|
1149
|
+
return false;
|
|
1150
|
+
};
|
|
1151
|
+
const tick = async () => {
|
|
1152
|
+
if (stopped || cancelledRef.current) return;
|
|
1153
|
+
await checkOnce();
|
|
1154
|
+
if (!stopped && !cancelledRef.current) {
|
|
1155
|
+
setTimeout(tick, 2500);
|
|
1156
|
+
}
|
|
1157
|
+
};
|
|
1158
|
+
void tick();
|
|
1159
|
+
let frameOrigin = "";
|
|
1160
|
+
try {
|
|
1161
|
+
frameOrigin = new URL(stage.url).origin;
|
|
1162
|
+
} catch {
|
|
1163
|
+
frameOrigin = "";
|
|
1164
|
+
}
|
|
1165
|
+
const onMessage = (e) => {
|
|
1166
|
+
if (!frameOrigin || e.origin !== frameOrigin) return;
|
|
1167
|
+
const status = e.data?.verification_status;
|
|
1168
|
+
if (status) void checkOnce();
|
|
1169
|
+
};
|
|
1170
|
+
window.addEventListener("message", onMessage);
|
|
1171
|
+
return () => {
|
|
1172
|
+
stopped = true;
|
|
1173
|
+
window.removeEventListener("message", onMessage);
|
|
1174
|
+
};
|
|
1175
|
+
}, [stage.kind, stage.kind === "journey" ? stage.url : ""]);
|
|
1176
|
+
const handleJourneyRetry = async () => {
|
|
1177
|
+
if (!tryStartOperation(journeyRetryingRef)) return;
|
|
1178
|
+
setStage({ kind: "journey", url: "" });
|
|
1179
|
+
try {
|
|
1180
|
+
const refreshed = await client.retryEventBasedFaceVerificationJourney(session.token);
|
|
1181
|
+
if (refreshed.verification_url) {
|
|
1182
|
+
setStage({ kind: "journey", url: refreshed.verification_url });
|
|
1183
|
+
return;
|
|
1184
|
+
}
|
|
1185
|
+
setStage({ kind: "error", message: "Unable to start a new attempt. Please try again." });
|
|
1186
|
+
} catch (err) {
|
|
1187
|
+
setStage({
|
|
1188
|
+
kind: "error",
|
|
1189
|
+
message: err instanceof Error ? err.message : "Unable to start a new attempt. Please try again."
|
|
1190
|
+
});
|
|
1191
|
+
} finally {
|
|
1192
|
+
releaseOperation(journeyRetryingRef);
|
|
1193
|
+
}
|
|
1194
|
+
};
|
|
1119
1195
|
const applyResult = (result) => {
|
|
1120
1196
|
if (result.status === "accepted") {
|
|
1121
1197
|
setStage({ kind: "accepted", result });
|
|
@@ -1307,12 +1383,28 @@ function FaceCaptureModal({
|
|
|
1307
1383
|
};
|
|
1308
1384
|
const renderSubmitting = () => /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: { ...spinnerStyle, margin: "24px auto", width: 32, height: 32 } }), /* @__PURE__ */ React__default.default.createElement("p", { style: subtitleStyle }, "Verifying your photo\u2026"), /* @__PURE__ */ React__default.default.createElement("p", { style: { ...attemptsTextStyle, marginTop: 8 } }, "This usually takes a few seconds."));
|
|
1309
1385
|
const renderAccepted = (result) => /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: successCircleStyle }, /* @__PURE__ */ React__default.default.createElement("img", { src: Done, alt: "", width: 48, height: 48 })), /* @__PURE__ */ React__default.default.createElement("h3", { style: titleStyle }, "Verified"), /* @__PURE__ */ React__default.default.createElement("p", { style: subtitleStyle }, "Your identity has been confirmed. You can continue."), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, /* @__PURE__ */ React__default.default.createElement("button", { style: primaryButtonStyle, onClick: () => close(result) }, "Continue")));
|
|
1310
|
-
const renderDeclined = (result) => /* @__PURE__ */ React__default.default.createElement("div", { style: contentStyle }, /* @__PURE__ */ React__default.default.createElement("div", { style: alertBoxStyle }, /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, result.declined_reason ?? "We couldn't match your selfie. Please take a new one.")), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, /* @__PURE__ */ React__default.default.createElement("button", { style: primaryButtonStyle, onClick: handleRetakeAfterDecline }, /* @__PURE__ */ React__default.default.createElement("img", { src: Camera, alt: "", width: 20, height: 20 }), /* @__PURE__ */ React__default.default.createElement("span", null, "Retake")), /* @__PURE__ */ React__default.default.createElement("button", { style: cancelButtonStyle, onClick: () => close(result) }, "Cancel")), /* @__PURE__ */ React__default.default.createElement("p", { style: attemptsTextStyle }, "Attempt ", Math.min(attempts + 1, maxAttempts), " of ", maxAttempts));
|
|
1386
|
+
const renderDeclined = (result) => /* @__PURE__ */ React__default.default.createElement("div", { style: contentStyle }, /* @__PURE__ */ React__default.default.createElement("div", { style: alertBoxStyle }, /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, result.declined_reason ?? "We couldn't match your selfie. Please take a new one.")), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, journeyMode ? /* @__PURE__ */ React__default.default.createElement("button", { style: primaryButtonStyle, onClick: () => void handleJourneyRetry() }, /* @__PURE__ */ React__default.default.createElement("span", null, "Try Again")) : /* @__PURE__ */ React__default.default.createElement("button", { style: primaryButtonStyle, onClick: handleRetakeAfterDecline }, /* @__PURE__ */ React__default.default.createElement("img", { src: Camera, alt: "", width: 20, height: 20 }), /* @__PURE__ */ React__default.default.createElement("span", null, "Retake")), /* @__PURE__ */ React__default.default.createElement("button", { style: cancelButtonStyle, onClick: () => close(result) }, "Cancel")), /* @__PURE__ */ React__default.default.createElement("p", { style: attemptsTextStyle }, "Attempt ", Math.min(attempts + 1, maxAttempts), " of ", maxAttempts));
|
|
1311
1387
|
const renderMaxAttempts = (result) => /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: errorCircleStyle }, "!"), /* @__PURE__ */ React__default.default.createElement("h3", { style: titleStyle }, "Maximum Attempts Reached"), /* @__PURE__ */ React__default.default.createElement("p", { style: subtitleStyle }, result.declined_reason ?? "We couldn't verify your identity after several attempts."), result.data?.freeze_account && /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, "For your security, your account has been temporarily restricted", result.data.freeze_duration_minutes ? ` for ${result.data.freeze_duration_minutes} minutes` : "", ". Please contact support if you need immediate help."), result.data?.enforce_logout && /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, "You will be signed out of your session."), result.data?.block && /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, "This action has been blocked for security reasons."), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, /* @__PURE__ */ React__default.default.createElement("button", { style: primaryButtonStyle, onClick: () => close(result) }, "Close")));
|
|
1312
1388
|
const renderError = (message) => {
|
|
1313
1389
|
const sessionExpired = /session\s+expired/i.test(message);
|
|
1314
|
-
return /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: errorCircleStyle }, "!"), /* @__PURE__ */ React__default.default.createElement("h3", { style: titleStyle }, sessionExpired ? "Session expired" : "Something Went Wrong"), /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, sessionExpired ? "Your verification session is no longer valid. Please start a new verification from the beginning." : message), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, !sessionExpired && /* @__PURE__ */ React__default.default.createElement(
|
|
1390
|
+
return /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: errorCircleStyle }, "!"), /* @__PURE__ */ React__default.default.createElement("h3", { style: titleStyle }, sessionExpired ? "Session expired" : "Something Went Wrong"), /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, sessionExpired ? "Your verification session is no longer valid. Please start a new verification from the beginning." : message), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, !sessionExpired && /* @__PURE__ */ React__default.default.createElement(
|
|
1391
|
+
"button",
|
|
1392
|
+
{
|
|
1393
|
+
style: primaryButtonStyle,
|
|
1394
|
+
onClick: () => retryTarget(journeyMode) === "journey" ? void handleJourneyRetry() : setStage({ kind: "capture" })
|
|
1395
|
+
},
|
|
1396
|
+
"Try Again"
|
|
1397
|
+
), /* @__PURE__ */ React__default.default.createElement("button", { style: cancelButtonStyle, onClick: () => close(null) }, sessionExpired ? "Close" : "Cancel")));
|
|
1315
1398
|
};
|
|
1399
|
+
const renderJourney = (url) => /* @__PURE__ */ React__default.default.createElement("div", { style: contentStyle }, url ? /* @__PURE__ */ React__default.default.createElement(
|
|
1400
|
+
"iframe",
|
|
1401
|
+
{
|
|
1402
|
+
src: url,
|
|
1403
|
+
title: "Identity verification",
|
|
1404
|
+
allow: "camera; microphone",
|
|
1405
|
+
style: journeyFrameStyle
|
|
1406
|
+
}
|
|
1407
|
+
) : /* @__PURE__ */ React__default.default.createElement("div", { style: { padding: 24, textAlign: "center" } }, /* @__PURE__ */ React__default.default.createElement("div", { style: { ...spinnerStyle, margin: "24px auto", width: 32, height: 32 } }), /* @__PURE__ */ React__default.default.createElement("p", { style: subtitleStyle }, "Preparing your next attempt\u2026")), /* @__PURE__ */ React__default.default.createElement("p", { style: { ...attemptsTextStyle, textAlign: "center" } }, "Attempt ", Math.min(attempts + 1, maxAttempts), " of ", maxAttempts));
|
|
1316
1408
|
const body = (() => {
|
|
1317
1409
|
switch (stage.kind) {
|
|
1318
1410
|
case "choose":
|
|
@@ -1321,6 +1413,8 @@ function FaceCaptureModal({
|
|
|
1321
1413
|
return renderQRStage(stage.mobileConnected);
|
|
1322
1414
|
case "capture":
|
|
1323
1415
|
return renderCapture(stage.declinedReason);
|
|
1416
|
+
case "journey":
|
|
1417
|
+
return renderJourney(stage.url);
|
|
1324
1418
|
case "submitting":
|
|
1325
1419
|
return renderSubmitting();
|
|
1326
1420
|
case "accepted":
|
|
@@ -1367,6 +1461,8 @@ var modalStyle = {
|
|
|
1367
1461
|
boxShadow: "0 25px 50px -12px rgba(0,0,0,.25)",
|
|
1368
1462
|
width: "100%",
|
|
1369
1463
|
maxWidth: 448,
|
|
1464
|
+
maxHeight: "calc(100vh - 32px)",
|
|
1465
|
+
overflowY: "auto",
|
|
1370
1466
|
animation: "zoomIn .2s ease-out"
|
|
1371
1467
|
};
|
|
1372
1468
|
var headerStyle = {
|
|
@@ -1392,6 +1488,13 @@ var contentStyle = {
|
|
|
1392
1488
|
flexDirection: "column",
|
|
1393
1489
|
gap: 16
|
|
1394
1490
|
};
|
|
1491
|
+
var journeyFrameStyle = {
|
|
1492
|
+
width: "100%",
|
|
1493
|
+
height: "min(520px, 60vh)",
|
|
1494
|
+
border: 0,
|
|
1495
|
+
borderRadius: 12,
|
|
1496
|
+
background: "#f9fafb"
|
|
1497
|
+
};
|
|
1395
1498
|
var visualGuideContainerStyle = { display: "flex", justifyContent: "center" };
|
|
1396
1499
|
var visualGuideStyle = { position: "relative" };
|
|
1397
1500
|
var circleStyle = {
|
|
@@ -1658,9 +1761,10 @@ function LiveCamera({ onCapture, onCancel, message, assetBasePath }) {
|
|
|
1658
1761
|
if (error) {
|
|
1659
1762
|
return /* @__PURE__ */ React__default.default.createElement("div", { style: { ...contentStyle, alignItems: "center", textAlign: "center", padding: 0 } }, /* @__PURE__ */ React__default.default.createElement("div", { style: errorCircleStyle }, "!"), /* @__PURE__ */ React__default.default.createElement("h3", { style: titleStyle }, "Camera unavailable"), /* @__PURE__ */ React__default.default.createElement("p", { style: alertTextStyle }, error), /* @__PURE__ */ React__default.default.createElement("div", { style: buttonsContainerStyle }, /* @__PURE__ */ React__default.default.createElement("button", { style: secondaryButtonStyle, onClick: onCancel }, "Back")));
|
|
1660
1763
|
}
|
|
1661
|
-
const
|
|
1662
|
-
const
|
|
1663
|
-
const
|
|
1764
|
+
const detectionAvailable = !faceDetectionFailed;
|
|
1765
|
+
const detectionActive = ready && detectionAvailable;
|
|
1766
|
+
const liveMessage = detectionAvailable ? FACE_MESSAGES[faceStatus] : message;
|
|
1767
|
+
const liveFaceColor = detectionAvailable ? FACE_COLORS[faceStatus] : void 0;
|
|
1664
1768
|
const captureDisabled = isCaptureDisabled(ready, detectionActive, faceStatus);
|
|
1665
1769
|
const ringPulse = detectionActive && (faceStatus === "too_far" || faceStatus === "too_close") ? "pulse 1.5s ease-in-out infinite" : void 0;
|
|
1666
1770
|
const dynamicCircleStyle = {
|
|
@@ -1776,20 +1880,22 @@ var faceOverlayContainerStyle = {
|
|
|
1776
1880
|
};
|
|
1777
1881
|
var faceRingWrapStyle = {
|
|
1778
1882
|
position: "relative",
|
|
1779
|
-
|
|
1780
|
-
aspectRatio: "
|
|
1883
|
+
height: "64%",
|
|
1884
|
+
aspectRatio: "3 / 4"
|
|
1781
1885
|
};
|
|
1782
1886
|
var faceDashedRingStyle = {
|
|
1783
1887
|
position: "absolute",
|
|
1784
1888
|
inset: -6,
|
|
1785
|
-
borderRadius:
|
|
1786
|
-
border: "6px dashed rgba(255, 255, 255, 0.4)"
|
|
1787
|
-
animation: "spin 10s linear infinite"
|
|
1889
|
+
borderRadius: 9999,
|
|
1890
|
+
border: "6px dashed rgba(255, 255, 255, 0.4)"
|
|
1788
1891
|
};
|
|
1789
1892
|
var faceCircleStyle = {
|
|
1790
1893
|
position: "absolute",
|
|
1791
1894
|
inset: 0,
|
|
1792
|
-
|
|
1895
|
+
// Tailwind's `rounded-full` resolves to a very large fixed radius. On a
|
|
1896
|
+
// 3:4 box that creates the normal KYC capsule/head guide with straighter
|
|
1897
|
+
// sides; 50% would instead produce a mathematically perfect ellipse.
|
|
1898
|
+
borderRadius: 9999,
|
|
1793
1899
|
border: "4px solid #00bc7d",
|
|
1794
1900
|
boxShadow: "0 0 0 1000px rgba(0, 0, 0, 0.5)"
|
|
1795
1901
|
};
|