@incodetech/core 0.0.0-dev-20261201-b41183a2 → 0.0.0-dev-20261201-e37652f8
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/{FaceDetectionProvider-DILvXMxQ.esm.js → FaceDetectionProvider-DQYbHLxC.esm.js} +7 -7
- package/dist/{addressSearch-BJ711RHG.esm.js → addressSearch-gginelz3.esm.js} +29 -27
- package/dist/ae-signature.esm.js +1 -1
- package/dist/antifraud.esm.js +2 -2
- package/dist/{antifraudManager-DRMBLSh7.esm.js → antifraudManager-B673OXCo.esm.js} +2 -2
- package/dist/{antifraudStateMachine-Bi0m60oV.esm.js → antifraudStateMachine-C_d7-TUA.esm.js} +1 -1
- package/dist/{api-B58edv6M.esm.js → api-CsXnB7m6.esm.js} +1 -0
- package/dist/{apiError-B80OYJHb.esm.js → apiError-BRiJu_rv.esm.js} +1 -1
- package/dist/{attemptCarry-CxiYlUAO.esm.js → attemptCarry-8gUYc3pL.esm.js} +1 -1
- package/dist/authentication.d.ts +3 -3
- package/dist/authentication.esm.js +2 -2
- package/dist/{authenticationManager-CXDKsr-j.esm.js → authenticationManager-CrBlRkAd.esm.js} +4 -4
- package/dist/{authenticationManager-C_ttJLGU.d.ts → authenticationManager-Cv_jCMGJ.d.ts} +1 -1
- package/dist/{authenticationStateMachine-CjheAavc.esm.js → authenticationStateMachine-DLwEyCeH.esm.js} +3 -3
- package/dist/certificate-issuance.esm.js +2 -2
- package/dist/{certificateIssuanceManager-DGzHjp2j.esm.js → certificateIssuanceManager-D-Dm90F3.esm.js} +2 -2
- package/dist/{certificateIssuanceStateMachine-DpflnS6P.esm.js → certificateIssuanceStateMachine-CBNw9Niu.esm.js} +1 -1
- package/dist/consent.d.ts +1 -1
- package/dist/consent.esm.js +2 -2
- package/dist/{consentManager-Bx_osBME.d.ts → consentManager-Bow34QP_.d.ts} +13 -13
- package/dist/{consentManager-CyoeiABc.esm.js → consentManager-DQ1uiNhr.esm.js} +2 -2
- package/dist/{consentStateMachine-BTUrAslr.esm.js → consentStateMachine-Cb7dKk_1.esm.js} +1 -1
- package/dist/cross-document-data-match.esm.js +1 -1
- package/dist/{crossDocumentDataMatchManager-cmQmp7Bi.esm.js → crossDocumentDataMatchManager-CeeEmCV1.esm.js} +2 -2
- package/dist/curp-validation.d.ts +1 -1
- package/dist/curp-validation.esm.js +2 -2
- package/dist/{curpValidationManager-BFPZiliY.d.ts → curpValidationManager-DFWjZq3i.d.ts} +1 -1
- package/dist/{curpValidationManager-EW44fVpH.esm.js → curpValidationManager-vgHG8gob.esm.js} +2 -2
- package/dist/{curpValidationStateMachine-BFkt90Zs.esm.js → curpValidationStateMachine-DaSzh9OA.esm.js} +2 -2
- package/dist/custom-fields.esm.js +1 -1
- package/dist/custom-watchlist.esm.js +2 -2
- package/dist/{customFieldsManager-DPMBJrcH.esm.js → customFieldsManager-BuEt-nm4.esm.js} +2 -2
- package/dist/{customWatchlistManager-DiYpPjZx.esm.js → customWatchlistManager-C1z0B5NU.esm.js} +2 -2
- package/dist/{customWatchlistStateMachine-D7VxQggF.esm.js → customWatchlistStateMachine-DvwFHjkC.esm.js} +1 -1
- package/dist/{deepsightCaptureConfig-22yGNhzp.esm.js → deepsightCaptureConfig-BVJANeRn.esm.js} +2 -2
- package/dist/{deepsightLoader-DAvHxEmQ.esm.js → deepsightLoader-C6nKqY9Q.esm.js} +4 -4
- package/dist/{desktopCameraElection-DKHWoXIZ.esm.js → desktopCameraElection-BAq-Kaiq.esm.js} +5 -5
- package/dist/document-capture.d.ts +1 -1
- package/dist/document-capture.esm.js +2 -2
- package/dist/document-signature.esm.js +2 -2
- package/dist/{documentCaptureManager-sJWgqtUy.d.ts → documentCaptureManager-DOgJTJ4F.d.ts} +4 -4
- package/dist/{documentCaptureManager-ytELw-yO.esm.js → documentCaptureManager-DoHy82WC.esm.js} +2 -2
- package/dist/{documentCaptureStateMachine-lKG1IVEM.esm.js → documentCaptureStateMachine-C_HQH7vA.esm.js} +2 -2
- package/dist/{documentSignatureStateMachine-BVv6yTDC.esm.js → documentSignatureStateMachine-Btlg3q7j.esm.js} +3 -3
- package/dist/dynamic-forms.esm.js +2 -2
- package/dist/{dynamicFormsManager-L9BCGhY3.esm.js → dynamicFormsManager-SbEUnFoF.esm.js} +2 -2
- package/dist/{dynamicFormsStateMachine-UeIgfIgO.esm.js → dynamicFormsStateMachine-Dxv36mAP.esm.js} +2 -2
- package/dist/ekyb.d.ts +1 -1
- package/dist/ekyb.esm.js +2 -2
- package/dist/{ekybManager-BNG13W2D.esm.js → ekybManager-xhoOX9O9.esm.js} +2 -2
- package/dist/{ekybStateMachine-qSw4IjCe.esm.js → ekybStateMachine-CCjUH0j3.esm.js} +184 -57
- package/dist/ekyc-prefill.d.ts +1 -1
- package/dist/ekyc-prefill.esm.js +2 -2
- package/dist/ekyc.d.ts +3 -0
- package/dist/ekyc.esm.js +3 -3
- package/dist/{ekycManager-Bt0FZlZO.esm.js → ekycManager-DrGuK0kT.esm.js} +2 -2
- package/dist/{ekycPrefillManager-C5DMDJEA.esm.js → ekycPrefillManager-C9kdwCC6.esm.js} +2 -2
- package/dist/{ekycPrefillManager-D-8VY48A.d.ts → ekycPrefillManager-Di6aMx68.d.ts} +8 -8
- package/dist/{ekycPrefillStateMachine-66IiDSxQ.esm.js → ekycPrefillStateMachine-DiQifkkd.esm.js} +9 -88
- package/dist/{ekycStateMachine-lo3GvfpV.esm.js → ekycStateMachine-BmMdLe2G.esm.js} +299 -126
- package/dist/{ekycUtils-BnTyeA-_.esm.js → ekycUtils-DfBNTcvX.esm.js} +41 -5
- package/dist/electronic-signature.esm.js +1 -1
- package/dist/{electronicSignatureManager-Dc0_ymIt.esm.js → electronicSignatureManager-C6liTNbu.esm.js} +3 -3
- package/dist/email.esm.js +2 -2
- package/dist/{emailManager-BBdRYLtH.esm.js → emailManager-CUX2saAB.esm.js} +2 -2
- package/dist/{emailStateMachine-DO7lWYvn.esm.js → emailStateMachine-BzWHKLtW.esm.js} +2 -2
- package/dist/{events-PUWyizJn.esm.js → events-Dlkhhx5O.esm.js} +1 -1
- package/dist/events.esm.js +1 -1
- package/dist/extensibility.d.ts +14 -14
- package/dist/extensibility.esm.js +35 -35
- package/dist/face-match.esm.js +2 -2
- package/dist/{faceCaptureManagerFactory-D0y15MK_.d.ts → faceCaptureManagerFactory-2oqROMSB.d.ts} +3 -3
- package/dist/{faceCaptureManagerFactory-DePLuBnT.esm.js → faceCaptureManagerFactory-OL8BWaIW.esm.js} +3 -3
- package/dist/{faceCaptureSetup-C8qfvh2x.esm.js → faceCaptureSetup-DQVtmb1q.esm.js} +10 -10
- package/dist/{faceMatchManager-nBvS9z0o.esm.js → faceMatchManager-BzaXiW4H.esm.js} +2 -2
- package/dist/{faceMatchStateMachine-48O8j_Lx.esm.js → faceMatchStateMachine-BItwQ_yA.esm.js} +2 -2
- package/dist/{feature-management-srznX8Iz.esm.js → feature-management-D_T-MG_i.esm.js} +1 -1
- package/dist/feature-management.esm.js +1 -1
- package/dist/field-comparison.esm.js +1 -1
- package/dist/{fieldComparisonManager-B1ipvtnp.esm.js → fieldComparisonManager-CzX6IhGd.esm.js} +2 -2
- package/dist/fiscal-qr.esm.js +1 -1
- package/dist/{fiscalQrManager-yecjuXV4.esm.js → fiscalQrManager-Dg6Mp58y.esm.js} +2 -2
- package/dist/flow-events.d.ts +1 -1
- package/dist/flow.d.ts +31 -9
- package/dist/flow.esm.js +11 -7
- package/dist/{flowCompletionService-Cba59yFV.esm.js → flowCompletionService-L0J63ui-.esm.js} +2 -2
- package/dist/{flowServices-B33MhjQM.esm.js → flowServices-3OXrEqDE.esm.js} +25 -21
- package/dist/formDefinitionsRollout-B-c4yO2z.esm.js +30 -0
- package/dist/{formErrors-lSfh7Y8J.esm.js → formErrors-kpskZLNT.esm.js} +39 -180
- package/dist/geolocation.d.ts +1 -1
- package/dist/geolocation.esm.js +2 -2
- package/dist/{geolocationManager-C7cHHTkd.esm.js → geolocationManager-CREfQNgO.esm.js} +2 -2
- package/dist/{geolocationManager-CENrvxpK.d.ts → geolocationManager-Del2ddmt.d.ts} +1 -1
- package/dist/{geolocationStateMachine-QJqoWT7E.esm.js → geolocationStateMachine-D9_bBr19.esm.js} +3 -3
- package/dist/government-validation.esm.js +2 -2
- package/dist/{governmentValidationManager-0-L21hu6.esm.js → governmentValidationManager-B7lIuL4r.esm.js} +2 -2
- package/dist/{governmentValidationStateMachine-BFIcq3UB.esm.js → governmentValidationStateMachine-BuW6l3ah.esm.js} +1 -1
- package/dist/home.d.ts +1 -1
- package/dist/home.esm.js +1 -1
- package/dist/http.esm.js +1 -1
- package/dist/id-ocr.d.ts +1 -1
- package/dist/id-ocr.esm.js +2 -2
- package/dist/id-selfie-flow.d.ts +1 -1
- package/dist/id-selfie-flow.esm.js +6 -6
- package/dist/id-verification.esm.js +2 -2
- package/dist/id.d.ts +2 -2
- package/dist/id.esm.js +3 -3
- package/dist/{idCaptureManager-3YmXwvvY.esm.js → idCaptureManager-B5ZN7scK.esm.js} +6 -6
- package/dist/{idCaptureManager-B72fNOKa.d.ts → idCaptureManager-BMsGPjcf.d.ts} +2 -2
- package/dist/{idCaptureServices-j-hB9ROq.esm.js → idCaptureServices-7zZ457LW.esm.js} +4 -4
- package/dist/{idCaptureStateMachine-DcQQvjLv.esm.js → idCaptureStateMachine-FP4j-qeT.esm.js} +15 -15
- package/dist/{idOcrManager-CNGVEZ7B.d.ts → idOcrManager-C0C7lFGd.d.ts} +1 -1
- package/dist/{idOcrManager-bjBLjrEE.esm.js → idOcrManager-C9C8UaPr.esm.js} +2 -2
- package/dist/{idOcrStateMachine-D5ifJ1B8.esm.js → idOcrStateMachine-DANDVn-6.esm.js} +1 -1
- package/dist/{idVerificationManager-C8Ja-vKq.esm.js → idVerificationManager-B_6wwpeT.esm.js} +2 -2
- package/dist/{idVerificationStateMachine-BMnfZZli.esm.js → idVerificationStateMachine-MjQmD3yQ.esm.js} +1 -1
- package/dist/identity-reuse.d.ts +2 -2
- package/dist/identity-reuse.esm.js +2 -2
- package/dist/identity-search.esm.js +1 -1
- package/dist/{identityReuseManager-D_jiHp1n.d.ts → identityReuseManager-BE6LHcuP.d.ts} +157 -21
- package/dist/{identityReuseManager-B5BWAleT.esm.js → identityReuseManager-DWECWIiZ.esm.js} +7 -3
- package/dist/{identityReuseStateMachine-Cuggm1UP.esm.js → identityReuseStateMachine-nBv0KUJC.esm.js} +73 -5
- package/dist/{index-O5g5kKdI.d.ts → index-k1LUfkAo.d.ts} +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/kyb-checks.esm.js +2 -2
- package/dist/{kybChecksManager-BorQeoKZ.esm.js → kybChecksManager-tUsFKBCN.esm.js} +1 -1
- package/dist/{kybChecksStateMachine-kuV8xPAu.esm.js → kybChecksStateMachine-D1q4K7Xr.esm.js} +4 -4
- package/dist/mandatory-consent.d.ts +2 -2
- package/dist/mandatory-consent.esm.js +2 -2
- package/dist/{mandatoryConsentManager-C6jjFptX.d.ts → mandatoryConsentManager-De9ZX6o4.d.ts} +10 -10
- package/dist/{mandatoryConsentManager-FfgHdPYw.esm.js → mandatoryConsentManager-S8rgqCld.esm.js} +2 -2
- package/dist/{mandatoryConsentStateMachine-CXuYC3qR.esm.js → mandatoryConsentStateMachine-BtE4heVc.esm.js} +1 -1
- package/dist/{multipartRecordingService-CFmOUGQt.esm.js → multipartRecordingService-C8v02l56.esm.js} +1 -1
- package/dist/phone.esm.js +2 -2
- package/dist/{phoneManager-oIMdbeLG.esm.js → phoneManager-uQEAWKlO.esm.js} +2 -2
- package/dist/{phoneServices-Dk4j3NhI.esm.js → phoneServices-XoT74eS0.esm.js} +1 -1
- package/dist/{phoneStateMachine-Cu3y7ewi.esm.js → phoneStateMachine-B4W4CSqf.esm.js} +2 -2
- package/dist/{processFaceMatch-CHeI0DEt.esm.js → processFaceMatch-CpQYLU-y.esm.js} +1 -1
- package/dist/qe-signature.esm.js +1 -1
- package/dist/{recordingService-RHW4CWxh.esm.js → recordingService-OcyZO_w6.esm.js} +3 -3
- package/dist/redirect-to-mobile.esm.js +2 -2
- package/dist/{redirectToMobileManager-DmrPLTLG.esm.js → redirectToMobileManager-UQZkhZFB.esm.js} +2 -2
- package/dist/{redirectToMobileStateMachine-OeQDdgsK.esm.js → redirectToMobileStateMachine-D1wp--wG.esm.js} +1 -1
- package/dist/{runChildModule-pJrB5rsq.esm.js → runChildModule-BuZFd3Df.esm.js} +1 -1
- package/dist/{sdkVersion-CiTnubuK.esm.js → sdkVersion-BY8g-EEL.esm.js} +1 -1
- package/dist/selfie.d.ts +3 -3
- package/dist/selfie.esm.js +8 -8
- package/dist/{selfieErrorUtils-UJWNVxvr.esm.js → selfieErrorUtils-DIVWh0ih.esm.js} +1 -1
- package/dist/{selfieManager-B9nn8qKH.esm.js → selfieManager-DQ5xB8y6.esm.js} +4 -4
- package/dist/{selfieManager-C44cA6cA.d.ts → selfieManager-RgcJwpHg.d.ts} +1 -1
- package/dist/{selfieStateMachine-7H38L53x.esm.js → selfieStateMachine-fyNh2r31.esm.js} +3 -3
- package/dist/{session-BLrEehWj.esm.js → session-DKnCv6zu.esm.js} +5 -5
- package/dist/session.d.ts +9 -1
- package/dist/session.esm.js +5 -5
- package/dist/{sessionInitializer-DAC3I8PG.esm.js → sessionInitializer-q5b8Qwr3.esm.js} +7 -7
- package/dist/{setup-BajT35bZ.esm.js → setup-JGwc0kgu.esm.js} +8 -8
- package/dist/signature.esm.js +2 -2
- package/dist/{signatureManager-DRUflksL.esm.js → signatureManager-3g4_cavt.esm.js} +2 -2
- package/dist/{signatureStateMachine-BQZenxel.esm.js → signatureStateMachine-CkES2vVv.esm.js} +1 -1
- package/dist/{stats-DHu3li6G.esm.js → stats-D_gJvsTS.esm.js} +1 -1
- package/dist/stats.esm.js +1 -1
- package/dist/trim-OmrUb6mG.esm.js +297 -0
- package/dist/trueSight-9VsfHXFt.esm.js +1 -0
- package/dist/{trueSightService-BLyfduve.esm.js → trueSightService-Dx8AqgKD.esm.js} +3 -3
- package/dist/trust-graph.esm.js +2 -2
- package/dist/{trustGraphStateMachine-0Ehwried.esm.js → trustGraphStateMachine-fuYq0Cxf.esm.js} +1 -1
- package/dist/{types-C57lH3a8.d.ts → types-BV2Tl1wE.d.ts} +1 -1
- package/dist/{types-CaQV2ksk.d.ts → types-BVgTvWOP.d.ts} +1 -1
- package/dist/{types-DDmU-yVM.d.ts → types-DAhpyjuI.d.ts} +1 -1
- package/dist/{types-ujAUlvvI.d.ts → types-DH4VaTRC.d.ts} +4 -4
- package/dist/types-RLVmm_Hf.d.ts +6 -0
- package/dist/{types-ByNCQYE9.d.ts → types-YS7g_P7z.d.ts} +1 -1
- package/dist/uppercase-CwlIuiwR.esm.js +115 -0
- package/dist/video-selfie.d.ts +1 -1
- package/dist/video-selfie.esm.js +6 -6
- package/dist/{videoSelfieCameraWarmer-D4nY62Xt.esm.js → videoSelfieCameraWarmer-AoMytGBD.esm.js} +4 -4
- package/dist/{videoSelfieStepDetector-DAEJDeL3.d.ts → videoSelfieStepDetector-DCOmz3yk.d.ts} +2 -2
- package/dist/wasm.esm.js +1 -1
- package/dist/watchlist-for-business.esm.js +2 -2
- package/dist/watchlist.esm.js +2 -2
- package/dist/{watchlistForBusinessManager-d8kdf35n.esm.js → watchlistForBusinessManager-VDu1ypVz.esm.js} +2 -2
- package/dist/{watchlistForBusinessStateMachine-Y9wFmuMH.esm.js → watchlistForBusinessStateMachine-Dr85bA22.esm.js} +1 -1
- package/dist/{watchlistManager-D1BVrd3H.esm.js → watchlistManager-Dc9sFwZx.esm.js} +2 -2
- package/dist/{watchlistStateMachine-Da4p0sTE.esm.js → watchlistStateMachine-BnKGh6Kk.esm.js} +1 -1
- package/dist/workflow.d.ts +5 -5
- package/dist/workflow.esm.js +40 -40
- package/package.json +1 -1
- package/dist/definitionSource-B9WTvQb9.esm.js +0 -30
- package/dist/resolveForm-DaaQSVWp.esm.js +0 -146
- package/dist/trueSight-BdWbgUnZ.esm.js +0 -1
- package/dist/types-B_THBzAh.d.ts +0 -6
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { n as eventModuleNames } from "./types-DLsivQsu.esm.js";
|
|
2
|
-
import { t as createManagerInstrumentation } from "./events-
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-Dlkhhx5O.esm.js";
|
|
3
3
|
import { t as topLevelStateName } from "./topLevelStateName-B5i2avbh.esm.js";
|
|
4
4
|
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
5
5
|
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
6
|
-
import { t as signatureMachine } from "./signatureStateMachine-
|
|
6
|
+
import { t as signatureMachine } from "./signatureStateMachine-CkES2vVv.esm.js";
|
|
7
7
|
//#region src/modules/signature/signatureActor.ts
|
|
8
8
|
function createSignatureActor(options) {
|
|
9
9
|
return createActor(signatureMachine, { input: { config: options.config } }).start();
|
package/dist/{signatureStateMachine-BQZenxel.esm.js → signatureStateMachine-CkES2vVv.esm.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
2
2
|
import { i as assign, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
3
3
|
import { n as fromPromise } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
4
4
|
//#region src/modules/signature/signatureServices.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as getToken, t as api, u as endpoints } from "./api-
|
|
1
|
+
import { r as getToken, t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
2
2
|
//#region src/modules/stats/statsServices.ts
|
|
3
3
|
const deviceStatsQueue = [];
|
|
4
4
|
async function postDeviceStatsNow(stats) {
|
package/dist/stats.esm.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as flushDeviceStatsQueue, r as resetDeviceStatsQueue, t as addDeviceStats } from "./stats-
|
|
1
|
+
import { n as flushDeviceStatsQueue, r as resetDeviceStatsQueue, t as addDeviceStats } from "./stats-D_gJvsTS.esm.js";
|
|
2
2
|
export { addDeviceStats, flushDeviceStatsQueue, resetDeviceStatsQueue };
|
|
@@ -0,0 +1,297 @@
|
|
|
1
|
+
//#region src/shared/displayErrors.ts
|
|
2
|
+
const DYNAMIC_REQUIRED_KEY = "verification.errors.fieldRequiredDynamic";
|
|
3
|
+
//#endregion
|
|
4
|
+
//#region src/internal/forms/values.ts
|
|
5
|
+
/** Whether text is empty once trimmed. */
|
|
6
|
+
const blank = (value) => value.trim() === "";
|
|
7
|
+
/**
|
|
8
|
+
* A value as the kernel reads it: text, a list of texts, or absent. A host
|
|
9
|
+
* can set anything (`setField`), so `null` counts as absent and a number or
|
|
10
|
+
* other scalar as its text.
|
|
11
|
+
*/
|
|
12
|
+
function readValue(value) {
|
|
13
|
+
if (value === void 0 || value === null) return void 0;
|
|
14
|
+
if (typeof value === "string") return value;
|
|
15
|
+
if (Array.isArray(value)) return value.map((entry) => entry === void 0 || entry === null ? "" : String(entry));
|
|
16
|
+
return String(value);
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Whether a value is empty (spec semantic 2): absent or only whitespace, or
|
|
20
|
+
* a list with no entry that isn't.
|
|
21
|
+
*
|
|
22
|
+
* A phone with only its calling code is a value, not empty, as in every
|
|
23
|
+
* module (CK1 decision K15): the kernel can't tell a calling code from a
|
|
24
|
+
* number being typed (`+44` from `+441`) without calling-code data the phone
|
|
25
|
+
* rules don't expose, and the UI never stores one (an untouched phone input
|
|
26
|
+
* is `""`). ENG-63329 drops the spec's calling-code clause.
|
|
27
|
+
*/
|
|
28
|
+
function isEmptyValue(_field, value) {
|
|
29
|
+
const read = readValue(value);
|
|
30
|
+
if (read === void 0) return true;
|
|
31
|
+
return typeof read === "string" ? blank(read) : read.every(blank);
|
|
32
|
+
}
|
|
33
|
+
//#endregion
|
|
34
|
+
//#region src/internal/forms/buildPayload.ts
|
|
35
|
+
/** The request key a field writes, or nothing when it's never sent. */
|
|
36
|
+
const keyOf = (field) => field.payload?.omit ? void 0 : field.payload?.key ?? field.name;
|
|
37
|
+
const isBlank = (value) => (value ?? "").trim() === "";
|
|
38
|
+
/** The ids of a field's request transforms the registry doesn't implement. */
|
|
39
|
+
const unknownTransforms = (field, registry) => (field.payload?.transforms ?? []).map((ref) => ref.id).filter((id) => !registry.transforms.has(id));
|
|
40
|
+
function transform(field, value, registry, env) {
|
|
41
|
+
return (field.payload?.transforms ?? []).reduce((current, ref) => {
|
|
42
|
+
const impl = registry.transforms.get(ref.id);
|
|
43
|
+
return impl ? impl.apply(current, ref.params ?? {}, env) : current;
|
|
44
|
+
}, value);
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* A `submit.context` entry's runtime value, or nothing when it's empty: the
|
|
48
|
+
* source module configuration names (it can be an alias of the definition's
|
|
49
|
+
* source), else the definition's; the definition's country, else, for a form
|
|
50
|
+
* with no country, the flow's (`env.country`); module configuration's risk
|
|
51
|
+
* add-ons.
|
|
52
|
+
*/
|
|
53
|
+
function contextValue(name, definition, env) {
|
|
54
|
+
switch (name) {
|
|
55
|
+
case "source": return env.source || definition.source || void 0;
|
|
56
|
+
case "country": return definition.country || env.country || void 0;
|
|
57
|
+
case "riskAddons": return env.riskAddons?.length ? [...env.riskAddons] : void 0;
|
|
58
|
+
default: return;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* The request body a definition describes (spec semantic 5):
|
|
63
|
+
*
|
|
64
|
+
* 1. Every shown field with a non-empty value, under `payload.key` (default
|
|
65
|
+
* its name), after its request transforms. Empty values are left out,
|
|
66
|
+
* never sent as `""` or `null`, so `omitWhenEmpty` changes nothing here;
|
|
67
|
+
* so is a value its transforms leave blank. A list sends its non-blank
|
|
68
|
+
* entries, each transformed. A collection sends each entry with a value as
|
|
69
|
+
* its `join` fields' values, trimmed and joined with a space. With
|
|
70
|
+
* `payload.always` it's sent as `[]` when it isn't shown or no entry has
|
|
71
|
+
* a value; without, it's left out then.
|
|
72
|
+
* 2. `submit.static` keys as written, then `submit.context` keys: the source
|
|
73
|
+
* (`env.source`, else the definition's), the definition's country (else
|
|
74
|
+
* `env.country`), or `riskAddons`. An empty context value is left out.
|
|
75
|
+
* 3. `submit.copies` in order: each replaces `to` with `from`'s value, when
|
|
76
|
+
* `from` is in the body.
|
|
77
|
+
*
|
|
78
|
+
* Two writers of one key keep the first and report a problem.
|
|
79
|
+
*/
|
|
80
|
+
function buildPayload(form, values, registry, env, entries = {}) {
|
|
81
|
+
const { definition } = form;
|
|
82
|
+
const body = {};
|
|
83
|
+
const writers = /* @__PURE__ */ new Map();
|
|
84
|
+
const problems = [];
|
|
85
|
+
const write = (key, value, writer) => {
|
|
86
|
+
const first = writers.get(key);
|
|
87
|
+
if (first !== void 0) {
|
|
88
|
+
problems.push({
|
|
89
|
+
kind: "duplicateKey",
|
|
90
|
+
key,
|
|
91
|
+
writers: [first, writer]
|
|
92
|
+
});
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
writers.set(key, writer);
|
|
96
|
+
body[key] = value;
|
|
97
|
+
};
|
|
98
|
+
for (const { field } of form.fields) {
|
|
99
|
+
const key = keyOf(field);
|
|
100
|
+
const value = readValue(values[field.name]);
|
|
101
|
+
if (key === void 0 || isEmptyValue(field, value)) continue;
|
|
102
|
+
for (const id of unknownTransforms(field, registry)) problems.push({
|
|
103
|
+
kind: "unknownTransform",
|
|
104
|
+
field: field.name,
|
|
105
|
+
transform: id
|
|
106
|
+
});
|
|
107
|
+
if (typeof value === "string") {
|
|
108
|
+
const sent = transform(field, value, registry, env);
|
|
109
|
+
if (!isBlank(sent)) write(key, sent, field.name);
|
|
110
|
+
} else if (Array.isArray(value)) {
|
|
111
|
+
const sent = value.filter((entry) => !isBlank(entry)).map((entry) => transform(field, entry, registry, env)).filter((entry) => !isBlank(entry));
|
|
112
|
+
if (sent.length > 0) write(key, sent, field.name);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
const shown = new Set(form.collections.map(({ collection }) => collection.id));
|
|
116
|
+
for (const collection of definition.collections ?? []) {
|
|
117
|
+
const joined = shown.has(collection.id) ? (entries[collection.id] ?? []).map((entry) => collection.payload.join.map((name) => (entry[name] ?? "").trim()).filter((part) => part !== "").join(" ")).filter((value) => value !== "") : [];
|
|
118
|
+
if (joined.length > 0 || collection.payload.always === true) write(collection.payload.key, joined, collection.id);
|
|
119
|
+
}
|
|
120
|
+
for (const [key, value] of Object.entries(definition.submit.static ?? {})) write(key, value, "static");
|
|
121
|
+
for (const [key, name] of Object.entries(definition.submit.context ?? {})) {
|
|
122
|
+
const value = contextValue(name, definition, env);
|
|
123
|
+
if (value !== void 0) write(key, value, "context");
|
|
124
|
+
}
|
|
125
|
+
for (const { from, to } of definition.submit.copies ?? []) if (Object.prototype.hasOwnProperty.call(body, from)) body[to] = body[from];
|
|
126
|
+
return {
|
|
127
|
+
body,
|
|
128
|
+
problems
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
//#endregion
|
|
132
|
+
//#region src/internal/forms/checkSupport.ts
|
|
133
|
+
const GROUP_POLICIES = /* @__PURE__ */ new Set(["hide", "forceShow"]);
|
|
134
|
+
const OMIT_WHEN_EMPTY = "payload.omitWhenEmpty";
|
|
135
|
+
/** A collection flag (vocabulary 1.4). */
|
|
136
|
+
const ALWAYS = "payload.always";
|
|
137
|
+
/**
|
|
138
|
+
* Compares `major.minor` vocabulary versions. The compiler's twin is
|
|
139
|
+
* `compareVersions` in `packages/form-definitions/scripts/lib/checks.mjs`;
|
|
140
|
+
* both are tested against that package's `fixtures/vocabularyVersions.json`.
|
|
141
|
+
*/
|
|
142
|
+
function compareVocabulary(a, b) {
|
|
143
|
+
const [aMajor = 0, aMinor = 0] = a.split(".").map(Number);
|
|
144
|
+
const [bMajor = 0, bMinor = 0] = b.split(".").map(Number);
|
|
145
|
+
return aMajor - bMajor || aMinor - bMinor;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* Whether this build can use a definition. Any id or versioned flag it
|
|
149
|
+
* doesn't implement makes the definition unsupported, so the caller falls
|
|
150
|
+
* back to its bundled definition or current form. Presentation hints
|
|
151
|
+
* (widget, keyboard, autofill) never fail: an unknown hint falls back to the
|
|
152
|
+
* platform default.
|
|
153
|
+
*/
|
|
154
|
+
function checkSupport(definition, ids) {
|
|
155
|
+
const problems = [];
|
|
156
|
+
const need = (category, known, id, path) => {
|
|
157
|
+
if (!known.has(id)) problems.push({
|
|
158
|
+
category,
|
|
159
|
+
id,
|
|
160
|
+
path
|
|
161
|
+
});
|
|
162
|
+
};
|
|
163
|
+
if (!ids.schemaVersions.includes(definition.schemaVersion)) problems.push({
|
|
164
|
+
category: "schemaVersion",
|
|
165
|
+
id: String(definition.schemaVersion),
|
|
166
|
+
path: "schemaVersion"
|
|
167
|
+
});
|
|
168
|
+
if (compareVocabulary(definition.vocabulary, ids.vocabulary) > 0) problems.push({
|
|
169
|
+
category: "vocabulary",
|
|
170
|
+
id: definition.vocabulary,
|
|
171
|
+
path: "vocabulary"
|
|
172
|
+
});
|
|
173
|
+
const checkField = (field, path) => {
|
|
174
|
+
need("kind", ids.kinds, field.kind, `${path}.kind`);
|
|
175
|
+
need("group", ids.groups, field.group, `${path}.group`);
|
|
176
|
+
field.rules?.forEach((rule, i) => need("rule", ids.rules, rule.id, `${path}.rules[${i}]`));
|
|
177
|
+
field.input?.format?.forEach((t, i) => need("transform", ids.transforms, t.id, `${path}.input.format[${i}]`));
|
|
178
|
+
field.payload?.transforms?.forEach((t, i) => need("transform", ids.transforms, t.id, `${path}.payload.transforms[${i}]`));
|
|
179
|
+
if (field.payload?.omitWhenEmpty === true) need("flag", ids.flags, OMIT_WHEN_EMPTY, `${path}.${OMIT_WHEN_EMPTY}`);
|
|
180
|
+
if (field.optionsRef) need("optionList", ids.optionLists, field.optionsRef, `${path}.optionsRef`);
|
|
181
|
+
if (field.suggestionsRef) need("optionList", ids.optionLists, field.suggestionsRef, `${path}.suggestionsRef`);
|
|
182
|
+
field.requiredWhen?.forEach((condition, i) => {
|
|
183
|
+
const keys = Object.keys(condition);
|
|
184
|
+
if (keys.length !== 1) problems.push({
|
|
185
|
+
category: "condition",
|
|
186
|
+
id: keys.join("+") || "(empty)",
|
|
187
|
+
path: `${path}.requiredWhen[${i}]`
|
|
188
|
+
});
|
|
189
|
+
for (const key of keys) need("condition", ids.conditions, key, `${path}.requiredWhen[${i}]`);
|
|
190
|
+
});
|
|
191
|
+
field.prefill?.forEach((id, i) => need("prefillSource", ids.prefillSources, id, `${path}.prefill[${i}]`));
|
|
192
|
+
const lock = field.phone?.lockCountry;
|
|
193
|
+
if (typeof lock === "string" && lock !== "whenPhoneRisk") problems.push({
|
|
194
|
+
category: "phoneLock",
|
|
195
|
+
id: lock,
|
|
196
|
+
path: `${path}.phone`
|
|
197
|
+
});
|
|
198
|
+
};
|
|
199
|
+
definition.fields.forEach((field) => checkField(field, `fields.${field.name}`));
|
|
200
|
+
definition.groups?.forEach((policy) => {
|
|
201
|
+
need("group", ids.groups, policy.group, `groups.${policy.group}`);
|
|
202
|
+
if (!GROUP_POLICIES.has(policy.whenDisabled)) problems.push({
|
|
203
|
+
category: "groupPolicy",
|
|
204
|
+
id: policy.whenDisabled,
|
|
205
|
+
path: `groups.${policy.group}`
|
|
206
|
+
});
|
|
207
|
+
});
|
|
208
|
+
definition.groupRules?.forEach((rule, i) => {
|
|
209
|
+
need("groupRule", ids.groupRules, rule.id, `groupRules[${i}]`);
|
|
210
|
+
const cases = rule.id === "rulesByOption" ? rule.params?.cases : void 0;
|
|
211
|
+
if (cases && typeof cases === "object" && !Array.isArray(cases)) for (const [value, rules] of Object.entries(cases)) {
|
|
212
|
+
if (!Array.isArray(rules)) continue;
|
|
213
|
+
rules.forEach((ref, j) => {
|
|
214
|
+
const id = ref?.id;
|
|
215
|
+
need("rule", ids.rules, typeof id === "string" ? id : "(missing)", `groupRules[${i}].params.cases.${value}[${j}]`);
|
|
216
|
+
});
|
|
217
|
+
}
|
|
218
|
+
});
|
|
219
|
+
definition.collections?.forEach((collection) => {
|
|
220
|
+
need("group", ids.groups, collection.group, `collections.${collection.id}`);
|
|
221
|
+
if (collection.payload.always === true) need("flag", ids.flags, ALWAYS, `collections.${collection.id}.${ALWAYS}`);
|
|
222
|
+
collection.fields.forEach((field) => checkField(field, `collections.${collection.id}.fields.${field.name}`));
|
|
223
|
+
});
|
|
224
|
+
return problems.length === 0 ? { supported: true } : {
|
|
225
|
+
supported: false,
|
|
226
|
+
problems
|
|
227
|
+
};
|
|
228
|
+
}
|
|
229
|
+
//#endregion
|
|
230
|
+
//#region src/internal/forms/resolveForm.ts
|
|
231
|
+
const FORCE_SHOW = "forceShow";
|
|
232
|
+
const WHEN_PHONE_RISK = "whenPhoneRisk";
|
|
233
|
+
/**
|
|
234
|
+
* Resolves a definition against module configuration: which fields show,
|
|
235
|
+
* which are required, whether the phone is locked, and which group rules and
|
|
236
|
+
* collections apply. Pure and synchronous, so it runs inside an assign action.
|
|
237
|
+
*
|
|
238
|
+
* Call `checkSupport` first for any definition that wasn't bundled with this
|
|
239
|
+
* build; `resolveForm` ignores ids it doesn't know.
|
|
240
|
+
*/
|
|
241
|
+
function resolveForm(definition, context) {
|
|
242
|
+
const forcedGroups = new Set((definition.groups ?? []).filter((policy) => policy.whenDisabled === FORCE_SHOW).map((policy) => policy.group));
|
|
243
|
+
const isOn = (group) => context.groups[group] === true;
|
|
244
|
+
const isShown = (group) => isOn(group) || forcedGroups.has(group);
|
|
245
|
+
const riskAddons = new Set(context.riskAddons ?? []);
|
|
246
|
+
const shownFields = definition.fields.filter((field) => isShown(field.group));
|
|
247
|
+
const shownNames = new Set(shownFields.map((field) => field.name));
|
|
248
|
+
const fields = shownFields.map((field) => {
|
|
249
|
+
const conditions = field.requiredWhen ?? [];
|
|
250
|
+
const addonRequired = conditions.some((condition) => condition.riskAddon !== void 0 && riskAddons.has(condition.riskAddon));
|
|
251
|
+
const requiredIfFilled = conditions.map((condition) => condition.fieldFilled).filter((name) => name !== void 0 && shownNames.has(name));
|
|
252
|
+
const lock = field.phone?.lockCountry;
|
|
253
|
+
return {
|
|
254
|
+
field,
|
|
255
|
+
required: field.required === true || addonRequired,
|
|
256
|
+
requiredIfFilled,
|
|
257
|
+
forced: !isOn(field.group),
|
|
258
|
+
phoneLocked: field.kind === "phone" && (lock === true || lock === WHEN_PHONE_RISK && context.phoneRisk === true)
|
|
259
|
+
};
|
|
260
|
+
});
|
|
261
|
+
const order = shownFields.map((field) => field.name);
|
|
262
|
+
return {
|
|
263
|
+
definition,
|
|
264
|
+
fields,
|
|
265
|
+
groupRules: (definition.groupRules ?? []).map((rule) => ({
|
|
266
|
+
rule,
|
|
267
|
+
fields: order.filter((name) => rule.fields.includes(name))
|
|
268
|
+
})).filter((resolved) => resolved.fields.length > 0),
|
|
269
|
+
collections: (definition.collections ?? []).filter((collection) => isShown(collection.group)).map((collection) => ({
|
|
270
|
+
collection,
|
|
271
|
+
min: collection.min ?? 0,
|
|
272
|
+
max: collection.max
|
|
273
|
+
}))
|
|
274
|
+
};
|
|
275
|
+
}
|
|
276
|
+
//#endregion
|
|
277
|
+
//#region src/internal/forms/rules/e164.ts
|
|
278
|
+
/**
|
|
279
|
+
* `e164`: the phone as `+<country code><number>`. While the phone rules
|
|
280
|
+
* aren't loaded, or the number isn't valid, it stays as typed.
|
|
281
|
+
*/
|
|
282
|
+
const e164 = {
|
|
283
|
+
id: "e164",
|
|
284
|
+
apply: (value, _params, env) => env.deps.phone?.formatE164(value, env.country) ?? value
|
|
285
|
+
};
|
|
286
|
+
//#endregion
|
|
287
|
+
//#region src/internal/forms/rules/trim.ts
|
|
288
|
+
/**
|
|
289
|
+
* `trim`: removes leading and trailing whitespace. On a list, the caller
|
|
290
|
+
* applies it to each entry.
|
|
291
|
+
*/
|
|
292
|
+
const trim = {
|
|
293
|
+
id: "trim",
|
|
294
|
+
apply: (value) => value.trim()
|
|
295
|
+
};
|
|
296
|
+
//#endregion
|
|
297
|
+
export { buildPayload as a, readValue as c, checkSupport as i, DYNAMIC_REQUIRED_KEY as l, e164 as n, blank as o, resolveForm as r, isEmptyValue as s, trim as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "./trueSightService-Dx8AqgKD.esm.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { T as resolveWasmConfig, _ as emitWasmDiagnostic, a as setWebApiHttpTransport, i as initializeWasmWebClient, o as setupWasmConnection, r as executeWasmRequest, t as WasmWebClientError } from "./wasmWebClient-BIML49JC.esm.js";
|
|
2
2
|
import { n as getTimestamp } from "./IBrowserEnvironmentCapability-D7JG7ML3.esm.js";
|
|
3
3
|
import { S as subscribeEvent, n as eventModuleNames } from "./types-DLsivQsu.esm.js";
|
|
4
|
-
import { i as isApiConfigured, l as withTiming, n as getApi, o as setClient, r as getToken, t as api, u as endpoints } from "./api-
|
|
5
|
-
import "./events-
|
|
6
|
-
import { t as SDK_VERSION } from "./sdkVersion-
|
|
4
|
+
import { i as isApiConfigured, l as withTiming, n as getApi, o as setClient, r as getToken, t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
5
|
+
import "./events-Dlkhhx5O.esm.js";
|
|
6
|
+
import { t as SDK_VERSION } from "./sdkVersion-BY8g-EEL.esm.js";
|
|
7
7
|
import { n as reportHttpError, t as HttpRequestError } from "./HttpRequestError-Bh0pNGSC.esm.js";
|
|
8
8
|
/** Dirty-timer half of the interrupted-snapshot rebuild debounce (module boundaries + timer). */
|
|
9
9
|
const SNAPSHOT_DIRTY_INTERVAL_MS = 15e3;
|
package/dist/trust-graph.esm.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as eventModuleNames } from "./types-DLsivQsu.esm.js";
|
|
2
|
-
import { t as createManagerInstrumentation } from "./events-
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-Dlkhhx5O.esm.js";
|
|
3
3
|
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
4
4
|
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
5
|
-
import { t as trustGraphMachine } from "./trustGraphStateMachine-
|
|
5
|
+
import { t as trustGraphMachine } from "./trustGraphStateMachine-fuYq0Cxf.esm.js";
|
|
6
6
|
//#region src/modules/trust-graph/trustGraphActor.ts
|
|
7
7
|
function createTrustGraphActor() {
|
|
8
8
|
return createActor(trustGraphMachine, { input: {} }).start();
|
package/dist/{trustGraphStateMachine-0Ehwried.esm.js → trustGraphStateMachine-fuYq0Cxf.esm.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
2
2
|
import { t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
3
3
|
import { n as fromPromise } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
4
4
|
//#region src/modules/trust-graph/trustGraphServices.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as AvatarAssetsOverrides } from "./createFaceAvatar-Ct9QrQ66.js";
|
|
2
|
-
import { c as SelfieConcealmentOption, n as Flow, s as DeepsightCaptureConfig } from "./types-
|
|
2
|
+
import { c as SelfieConcealmentOption, n as Flow, s as DeepsightCaptureConfig } from "./types-DH4VaTRC.js";
|
|
3
3
|
import { a as IStorageCapability, n as IWasmUtilCapability } from "./IWasmUtilCapability-CLWIYHB4.js";
|
|
4
4
|
//#region src/internal/faceCapture/types.d.ts
|
|
5
5
|
type CameraResolution = {
|
|
@@ -447,10 +447,10 @@ type Flow = {
|
|
|
447
447
|
ds?: boolean;
|
|
448
448
|
oauth2Secured?: boolean;
|
|
449
449
|
/**
|
|
450
|
-
*
|
|
451
|
-
*
|
|
452
|
-
*
|
|
453
|
-
*
|
|
450
|
+
* @deprecated Ignored. The backend sends the identity search hint on the
|
|
451
|
+
* session start response, not on `/flow`: `<incode-flow>` reads it there,
|
|
452
|
+
* or from its `identitySearchHintProvided` config, and a headless host
|
|
453
|
+
* passes `getIdentitySearchHintProvided` to `createOrchestratedFlowManager`.
|
|
454
454
|
*/
|
|
455
455
|
identitySearchHintProvided?: boolean;
|
|
456
456
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { i as FlowModuleConfig } from "./types-DH4VaTRC.js";
|
|
2
|
+
import { t as BaseFaceCaptureConfig } from "./types-DAhpyjuI.js";
|
|
3
|
+
//#region src/modules/authentication/types.d.ts
|
|
4
|
+
type AuthenticationConfig = FlowModuleConfig['AUTHENTICATION'] & BaseFaceCaptureConfig;
|
|
5
|
+
//#endregion
|
|
6
|
+
export { AuthenticationConfig as t };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { y as IncodeCanvas } from "./createFaceAvatar-Ct9QrQ66.js";
|
|
2
|
-
import { a as RegulationTypes, n as Flow, o as TutorialIdConfig } from "./types-
|
|
2
|
+
import { a as RegulationTypes, n as Flow, o as TutorialIdConfig } from "./types-DH4VaTRC.js";
|
|
3
3
|
import { a as IStorageCapability } from "./IWasmUtilCapability-CLWIYHB4.js";
|
|
4
4
|
import { t as PermissionResult } from "./types-CeEcakO7.js";
|
|
5
5
|
import { n as DeepsightService, t as StreamCanvasCapture } from "./StreamCanvasCapture-BqaHTJF0.js";
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { n as e164 } from "./trim-OmrUb6mG.esm.js";
|
|
2
|
+
//#region src/internal/forms/checks/charTemplate.ts
|
|
3
|
+
const escapeForPattern = (chars) => chars.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
4
|
+
/**
|
|
5
|
+
* `charTemplate`: the whole value matches one template, where `9` is a digit,
|
|
6
|
+
* `A` an uppercase letter A-Z and any other character stands for itself.
|
|
7
|
+
* `ignoreCase` also accepts lowercase letters and literals in either case.
|
|
8
|
+
*/
|
|
9
|
+
function matchesCharTemplate(value, templates, ignoreCase = false) {
|
|
10
|
+
return templates.some((template) => {
|
|
11
|
+
const pattern = [...template].map((char) => {
|
|
12
|
+
if (char === "9") return "[0-9]";
|
|
13
|
+
if (char === "A") return "[A-Z]";
|
|
14
|
+
return escapeForPattern(char);
|
|
15
|
+
}).join("");
|
|
16
|
+
return new RegExp(`^${pattern}$`, ignoreCase ? "iu" : "u").test(value);
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
//#endregion
|
|
20
|
+
//#region src/internal/forms/definitionSource.ts
|
|
21
|
+
const queryKey = ({ module, source, country, riskAddon }) => `${module}|${source ?? ""}|${country ?? ""}|${riskAddon ?? ""}`;
|
|
22
|
+
/**
|
|
23
|
+
* The definitions bundled with this build. `select` matches module, source,
|
|
24
|
+
* country and risk add-on exactly, so a pair without its own definition keeps
|
|
25
|
+
* the current builder. Aliases live only in the selection index, so
|
|
26
|
+
* `sourceOf` takes them from it.
|
|
27
|
+
*/
|
|
28
|
+
function createBundledDefinitionSource(definitions, index = []) {
|
|
29
|
+
const byQuery = new Map(Object.values(definitions).map((definition) => [queryKey(definition), definition]));
|
|
30
|
+
const ownSources = new Set(Object.values(definitions).map((definition) => `${definition.module}|${definition.source ?? ""}`));
|
|
31
|
+
const aliases = /* @__PURE__ */ new Map();
|
|
32
|
+
for (const entry of index) {
|
|
33
|
+
const definition = definitions[entry.id];
|
|
34
|
+
if (!definition?.source) continue;
|
|
35
|
+
for (const alias of entry.aliases ?? []) aliases.set(`${definition.module}|${alias}|${definition.country ?? ""}`, definition.source);
|
|
36
|
+
}
|
|
37
|
+
return {
|
|
38
|
+
select: (query) => byQuery.get(queryKey(query)),
|
|
39
|
+
sourceOf: (module, id, country) => ownSources.has(`${module}|${id}`) ? id : aliases.get(`${module}|${id}|${country ?? ""}`) ?? aliases.get(`${module}|${id}|`) ?? id
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
//#endregion
|
|
43
|
+
//#region src/internal/forms/rules/digitGroups.ts
|
|
44
|
+
/**
|
|
45
|
+
* `digitGroups`: formats digits as the user types, such as an SSN shown as
|
|
46
|
+
* 3-2-4 (`groups: [3, 2, 4]`, `separator: "-"`). Other characters are
|
|
47
|
+
* dropped, digits past the last group are cut, and a separator appears once
|
|
48
|
+
* the next group has a digit (`1234` is `123-4`).
|
|
49
|
+
*
|
|
50
|
+
* `separators` (vocabulary 1.4) gives the separator after each group, in
|
|
51
|
+
* order, such as a CPF shown as 3.3.3-2 (`separators: [".", ".", "-"]`). A
|
|
52
|
+
* gap past the end of the list uses `separator`.
|
|
53
|
+
*/
|
|
54
|
+
const digitGroups = {
|
|
55
|
+
id: "digitGroups",
|
|
56
|
+
apply: (value, params) => {
|
|
57
|
+
const groups = Array.isArray(params.groups) ? params.groups.filter((size) => typeof size === "number") : [];
|
|
58
|
+
const separator = typeof params.separator === "string" ? params.separator : "";
|
|
59
|
+
const separators = Array.isArray(params.separators) ? params.separators : [];
|
|
60
|
+
const separatorAfter = (index) => {
|
|
61
|
+
const own = separators[index];
|
|
62
|
+
return typeof own === "string" ? own : separator;
|
|
63
|
+
};
|
|
64
|
+
let digits = value.replace(/[^0-9]/g, "");
|
|
65
|
+
let formatted = "";
|
|
66
|
+
for (const [index, size] of groups.entries()) {
|
|
67
|
+
if (!digits) break;
|
|
68
|
+
if (index > 0) formatted += separatorAfter(index - 1);
|
|
69
|
+
formatted += digits.slice(0, size);
|
|
70
|
+
digits = digits.slice(size);
|
|
71
|
+
}
|
|
72
|
+
return formatted;
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
//#endregion
|
|
76
|
+
//#region src/internal/forms/rules/e164NoPlus.ts
|
|
77
|
+
/** `e164NoPlus`: the phone as E.164 without the `+`. */
|
|
78
|
+
const e164NoPlus = {
|
|
79
|
+
id: "e164NoPlus",
|
|
80
|
+
apply: (value, params, env) => e164.apply(value, params, env).replace(/^\+/, "")
|
|
81
|
+
};
|
|
82
|
+
//#endregion
|
|
83
|
+
//#region src/internal/forms/rules/nationalNumber.ts
|
|
84
|
+
/**
|
|
85
|
+
* `nationalNumber`: the phone's national significant number, without the
|
|
86
|
+
* calling code or a trunk 0. While the phone rules aren't loaded, or the
|
|
87
|
+
* number can't be read, it stays as typed.
|
|
88
|
+
*/
|
|
89
|
+
const nationalNumber = {
|
|
90
|
+
id: "nationalNumber",
|
|
91
|
+
apply: (value, _params, env) => env.deps.phone?.nationalNumber(value, env.country) ?? value
|
|
92
|
+
};
|
|
93
|
+
//#endregion
|
|
94
|
+
//#region src/internal/forms/rules/stripSeparators.ts
|
|
95
|
+
/**
|
|
96
|
+
* `stripSeparators`: removes spaces, `-`, `.` and `/`, or the characters in
|
|
97
|
+
* `chars`. "Spaces" means any whitespace, as eKYC's input format reads it.
|
|
98
|
+
*/
|
|
99
|
+
const stripSeparators = {
|
|
100
|
+
id: "stripSeparators",
|
|
101
|
+
apply: (value, params) => {
|
|
102
|
+
if (typeof params.chars !== "string") return value.replace(/[\s./-]/g, "");
|
|
103
|
+
const remove = new Set(params.chars);
|
|
104
|
+
return [...value].filter((char) => !remove.has(char)).join("");
|
|
105
|
+
}
|
|
106
|
+
};
|
|
107
|
+
//#endregion
|
|
108
|
+
//#region src/internal/forms/rules/uppercase.ts
|
|
109
|
+
/** `uppercase`: converts letters to uppercase, over Unicode code points. */
|
|
110
|
+
const uppercase = {
|
|
111
|
+
id: "uppercase",
|
|
112
|
+
apply: (value) => value.toUpperCase()
|
|
113
|
+
};
|
|
114
|
+
//#endregion
|
|
115
|
+
export { digitGroups as a, e164NoPlus as i, stripSeparators as n, createBundledDefinitionSource as o, nationalNumber as r, matchesCharTemplate as s, uppercase as t };
|
package/dist/video-selfie.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import "./Actor-DqjOqDfU.js";
|
|
|
6
6
|
import { t as IVisibilityObserverCapability } from "./IVisibilityObserverCapability-D4tvIB5v.js";
|
|
7
7
|
import { n as FacingMode, t as CameraStream } from "./camera-9yYDUOsO.js";
|
|
8
8
|
import { t as DetectionOrientation } from "./IIdCaptureCapability-BRAZQtkM.js";
|
|
9
|
-
import { a as VideoSelfieConfig, i as CameraCompositor, n as VideoSelfieDetectionStatus, o as VideoSelfieSpeechResult, r as VideoSelfieValidationFailure, s as VideoSelfieStep, t as StepDetector } from "./videoSelfieStepDetector-
|
|
9
|
+
import { a as VideoSelfieConfig, i as CameraCompositor, n as VideoSelfieDetectionStatus, o as VideoSelfieSpeechResult, r as VideoSelfieValidationFailure, s as VideoSelfieStep, t as StepDetector } from "./videoSelfieStepDetector-DCOmz3yk.js";
|
|
10
10
|
//#region ../infra/src/capabilities/ITimerCapability.d.ts
|
|
11
11
|
type TimerHandle = ReturnType<typeof setTimeout>;
|
|
12
12
|
type ITimerCapability = {
|
package/dist/video-selfie.esm.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { t as ensureWasmPipelines } from "./setup-
|
|
1
|
+
import { t as ensureWasmPipelines } from "./setup-JGwc0kgu.esm.js";
|
|
2
2
|
import { t as WasmUtilProvider } from "./WasmUtilProvider-unrmGEHD.esm.js";
|
|
3
|
-
import { t as api, u as endpoints } from "./api-
|
|
3
|
+
import { t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
4
4
|
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
5
5
|
import { t as BrowserLazyImportProvider } from "./BrowserLazyImportProvider-BhoA957O.esm.js";
|
|
6
|
-
import { b as videoSelfieWasmPipelines, v as facingModeForStep, y as resolveVideoSelfieSteps } from "./flowServices-
|
|
6
|
+
import { b as videoSelfieWasmPipelines, v as facingModeForStep, y as resolveVideoSelfieSteps } from "./flowServices-3OXrEqDE.esm.js";
|
|
7
7
|
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
8
8
|
import { i as assign, l as raise, r as sendTo, s as createActor, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
9
9
|
import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
10
10
|
import { t as BrowserVisibilityObserverProvider } from "./BrowserVisibilityObserverProvider-BrJN1B8A.esm.js";
|
|
11
|
-
import { t as carryAttempts } from "./attemptCarry-
|
|
11
|
+
import { t as carryAttempts } from "./attemptCarry-8gUYc3pL.esm.js";
|
|
12
12
|
import { t as VIDEO_SELFIE_VALIDATION_ATTEMPTS_EXHAUSTED_CODE } from "./advanceableErrors-CxZyPRyh.esm.js";
|
|
13
|
-
import { c as VIDEO_SELFIE_MICROPHONE_UNAVAILABLE_CODE, l as isConnectionError, n as defaultAcquireCamera, r as createDefaultStepDetector, s as MicrophoneUnavailableError, t as createVideoSelfieCameraWarmer } from "./videoSelfieCameraWarmer-
|
|
13
|
+
import { c as VIDEO_SELFIE_MICROPHONE_UNAVAILABLE_CODE, l as isConnectionError, n as defaultAcquireCamera, r as createDefaultStepDetector, s as MicrophoneUnavailableError, t as createVideoSelfieCameraWarmer } from "./videoSelfieCameraWarmer-AoMytGBD.esm.js";
|
|
14
14
|
import { r as createRecordingCompositor } from "./CameraCompositor-C7N1N61V.esm.js";
|
|
15
15
|
import { t as WorkerEncoderRecordingProvider } from "./WorkerEncoderRecordingProvider-BO7urYwT.esm.js";
|
|
16
|
-
import { t as MultipartRecordingService } from "./multipartRecordingService-
|
|
16
|
+
import { t as MultipartRecordingService } from "./multipartRecordingService-C8v02l56.esm.js";
|
|
17
17
|
import { t as videoSelfieFlowModuleMachine } from "./videoSelfieFlowModuleMachine-IWdxw1TW.esm.js";
|
|
18
18
|
//#region ../../node_modules/.pnpm/audio-recorder-polyfill@0.4.1/node_modules/audio-recorder-polyfill/wave-encoder/index.js
|
|
19
19
|
var wave_encoder_default = () => {
|
package/dist/{videoSelfieCameraWarmer-D4nY62Xt.esm.js → videoSelfieCameraWarmer-AoMytGBD.esm.js}
RENAMED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CsXnB7m6.esm.js";
|
|
2
2
|
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
3
|
-
import { v as facingModeForStep, y as resolveVideoSelfieSteps } from "./flowServices-
|
|
3
|
+
import { v as facingModeForStep, y as resolveVideoSelfieSteps } from "./flowServices-3OXrEqDE.esm.js";
|
|
4
4
|
import { i as requestCameraWithFallback, r as requestCameraAccess } from "./camera-CJKApt0x.esm.js";
|
|
5
5
|
import { n as checkPermission } from "./permissionServices-GQyOY1tb.esm.js";
|
|
6
6
|
import { n as getWindowDimensions } from "./getDeviceClass-CeBiEayS.esm.js";
|
|
7
|
-
import { c as uploadSelfie, n as encryptSelfieImage, o as startDetection, s as processFace, t as FaceDetectionProvider, u as FACE_ERROR_CODES } from "./FaceDetectionProvider-
|
|
7
|
+
import { c as uploadSelfie, n as encryptSelfieImage, o as startDetection, s as processFace, t as FaceDetectionProvider, u as FACE_ERROR_CODES } from "./FaceDetectionProvider-DQYbHLxC.esm.js";
|
|
8
8
|
import { t as StreamCanvasProcessingSession } from "./StreamCanvasProcessingSession-CBnbTnOr.esm.js";
|
|
9
9
|
import { n as getBackCameraStream } from "./backCameraStream-6qVHvj76.esm.js";
|
|
10
|
-
import { t as getFaceErrorCodeFromUnknown } from "./selfieErrorUtils-
|
|
10
|
+
import { t as getFaceErrorCodeFromUnknown } from "./selfieErrorUtils-DIVWh0ih.esm.js";
|
|
11
11
|
import { n as DEFAULT_ID_CAPTURE_THRESHOLDS, r as IdCaptureProvider, t as DEFAULT_ID_CAPTURE_GEOMETRY } from "./idCaptureDefaults-CFyXIRuM.esm.js";
|
|
12
12
|
import { t as StreamCanvasCapture } from "./StreamCanvasCapture-CXd87trH.esm.js";
|
|
13
13
|
//#region src/modules/video-selfie/videoSelfieCompareService.ts
|
package/dist/{videoSelfieStepDetector-DAEJDeL3.d.ts → videoSelfieStepDetector-DCOmz3yk.d.ts}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as FlowModuleConfig } from "./types-
|
|
1
|
+
import { i as FlowModuleConfig } from "./types-DH4VaTRC.js";
|
|
2
2
|
import "./IWasmUtilCapability-CLWIYHB4.js";
|
|
3
|
-
import { n as DetectionStatus } from "./types-
|
|
3
|
+
import { n as DetectionStatus } from "./types-DAhpyjuI.js";
|
|
4
4
|
import { t as CameraStream } from "./camera-9yYDUOsO.js";
|
|
5
5
|
import { t as DetectionOrientation } from "./IIdCaptureCapability-BRAZQtkM.js";
|
|
6
6
|
//#region src/modules/video-selfie/types.d.ts
|
package/dist/wasm.esm.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { D as WASM_PIPELINE_LAZY_MODEL_NAMES, E as WASM_MODEL_FILES, S as buildWasmConfigFromBasePath, T as resolveWasmConfig, b as DEFAULT_WASM_VERSION, k as WASM_PIPELINE_MODEL_NAMES, x as buildDefaultWasmConfig } from "./wasmWebClient-BIML49JC.esm.js";
|
|
2
2
|
import { s as warmupWasm } from "./warmup-O3rAoe1-.esm.js";
|
|
3
|
-
import { a as resolveWasmConfigForPipelines, c as upgradeToWasmHttpClient, n as initializeWasmUtil, o as setWasmConfig, t as ensureWasmPipelines } from "./setup-
|
|
3
|
+
import { a as resolveWasmConfigForPipelines, c as upgradeToWasmHttpClient, n as initializeWasmUtil, o as setWasmConfig, t as ensureWasmPipelines } from "./setup-JGwc0kgu.esm.js";
|
|
4
4
|
//#region src/defineWasm.ts
|
|
5
5
|
function requiredModels(pipelines) {
|
|
6
6
|
const models = /* @__PURE__ */ new Set();
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as watchlistForBusinessMachine } from "./watchlistForBusinessStateMachine-
|
|
2
|
-
import { n as createWatchlistForBusinessManagerFromActor, t as createWatchlistForBusinessManager } from "./watchlistForBusinessManager-
|
|
1
|
+
import { n as watchlistForBusinessMachine } from "./watchlistForBusinessStateMachine-Dr85bA22.esm.js";
|
|
2
|
+
import { n as createWatchlistForBusinessManagerFromActor, t as createWatchlistForBusinessManager } from "./watchlistForBusinessManager-VDu1ypVz.esm.js";
|
|
3
3
|
export { createWatchlistForBusinessManager, createWatchlistForBusinessManagerFromActor, watchlistForBusinessMachine };
|
package/dist/watchlist.esm.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { t as watchlistMachine } from "./watchlistStateMachine-
|
|
2
|
-
import { t as createWatchlistManager } from "./watchlistManager-
|
|
1
|
+
import { t as watchlistMachine } from "./watchlistStateMachine-BnKGh6Kk.esm.js";
|
|
2
|
+
import { t as createWatchlistManager } from "./watchlistManager-Dc9sFwZx.esm.js";
|
|
3
3
|
export { createWatchlistManager, watchlistMachine };
|