@incodetech/core 2.4.1-agentic.1 → 2.4.1-agentic.11
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/Actor-DqjOqDfU.d.ts +1 -0
- package/dist/{BaseWasmProvider-Bq3OHo7P.d.ts → BaseWasmProvider-bBNquvYn.d.ts} +2 -2
- package/dist/{CameraCompositor-DN7NkJzV.esm.js → CameraCompositor-ppyMYVoY.esm.js} +1 -1
- package/dist/DateFormattingProvider-DPq9zco-.esm.js +25 -0
- package/dist/{FaceDetectionProvider-CAY43vSI.esm.js → FaceDetectionProvider-2NzWDbV8.esm.js} +9 -9
- package/dist/{IIdCaptureCapability-CGcEt2Cw.d.ts → IIdCaptureCapability-C-5M8pP1.d.ts} +2 -2
- package/dist/{IWasmUtilCapability-Cqiaxydi.d.ts → IWasmUtilCapability-BRn0wz8v.d.ts} +2 -2
- package/dist/Manager-BvXAwDv9.esm.js +125 -0
- package/dist/{Manager-C9T5amUN.d.ts → Manager-DufwKlav.d.ts} +1 -7
- package/dist/{MultipartRecordingProvider-D9mauUdS.esm.js → MultipartRecordingProvider-CduV32Qa.esm.js} +6 -1
- package/dist/{StreamCanvasCapture-C3xNfOsv.d.ts → StreamCanvasCapture-ixfy84ys.d.ts} +2 -2
- package/dist/{WasmUtilProvider-Dp2V-Uct.esm.js → WasmUtilProvider-DdhAHHw4.esm.js} +42 -6
- package/dist/{WorkerEncoderRecordingProvider-B1ODYtgN.esm.js → WorkerEncoderRecordingProvider-CsDED9UU.esm.js} +1 -1
- package/dist/addressSearch-Rxm1K67A.esm.js +73 -0
- package/dist/{advanceableErrors-k-U-cL5m.esm.js → advanceableErrors-CxZyPRyh.esm.js} +3 -0
- package/dist/ae-signature.d.ts +2 -2
- package/dist/ae-signature.esm.js +1 -1
- package/dist/antifraud.d.ts +1 -1
- package/dist/antifraud.esm.js +2 -2
- package/dist/{antifraudManager-DbGCvlJs.d.ts → antifraudManager-BxfCsyA7.d.ts} +3 -3
- package/dist/{antifraudManager-BObuHBjn.esm.js → antifraudManager-DKNOi9-z.esm.js} +5 -3
- package/dist/{antifraudStateMachine-Dfrd2-26.esm.js → antifraudStateMachine-BJ6PmCsw.esm.js} +3 -3
- package/dist/{api-CpP4PS4S.esm.js → api-CZpuJuZl.esm.js} +3 -1
- package/dist/{apiError-DH-CH4Nz.esm.js → apiError-BamZ815u.esm.js} +1 -1
- package/dist/{attemptCarry-WOkfvFMw.esm.js → attemptCarry-BecGGZK8.esm.js} +1 -1
- package/dist/authentication.d.ts +3 -3
- package/dist/authentication.esm.js +2 -2
- package/dist/{authenticationManager-CWmh7aSY.d.ts → authenticationManager-DRaugLgH.d.ts} +2 -2
- package/dist/{authenticationManager-DjX0XDyH.esm.js → authenticationManager-yBVGiIf_.esm.js} +7 -6
- package/dist/{authenticationStateMachine-BMbZL8wm.esm.js → authenticationStateMachine-DPqTOJPp.esm.js} +50 -18
- package/dist/avatar.d.ts +1 -1
- package/dist/{browser-pQZA35G2-DtkAf6sn.esm.js → browser-pQZA35G2-DxIBykpe.esm.js} +1 -1
- package/dist/{callback-645_omgz.d.ts → callback-BmjJ1G-5.d.ts} +1 -1
- package/dist/camera.esm.js +1 -1
- package/dist/certificate-issuance.d.ts +1 -1
- package/dist/certificate-issuance.esm.js +2 -2
- package/dist/{certificateIssuanceManager-Dr8A4Lgr.d.ts → certificateIssuanceManager-BcYhxO63.d.ts} +4 -3
- package/dist/{certificateIssuanceManager-C1nETQos.esm.js → certificateIssuanceManager-Dxl9UwR0.esm.js} +5 -3
- package/dist/{certificateIssuanceStateMachine-DThXMDqr.esm.js → certificateIssuanceStateMachine-CM4q71h1.esm.js} +4 -4
- package/dist/{cnpj-Co1ottYN.esm.js → cnpj-Bl_olpdX.esm.js} +5 -3
- package/dist/consent.d.ts +1 -1
- package/dist/consent.esm.js +2 -2
- package/dist/{consentManager-bjfVXO7p.d.ts → consentManager-B2F_VeAo.d.ts} +12 -11
- package/dist/{consentManager-DMlSL6Ax.esm.js → consentManager-BPocwpm2.esm.js} +5 -3
- package/dist/{consentStateMachine-DIYSMxKQ.esm.js → consentStateMachine-DgiIcT9q.esm.js} +3 -3
- package/dist/cpf-DDXMTLYr.esm.js +37 -0
- package/dist/{createFaceAvatar-lYX0VTYs.d.ts → createFaceAvatar-BimBTONm.d.ts} +1 -1
- package/dist/cross-document-data-match.d.ts +1 -1
- package/dist/cross-document-data-match.esm.js +1 -1
- package/dist/{crossDocumentDataMatchManager-BFTdiEDB.esm.js → crossDocumentDataMatchManager-BfA29Aji.esm.js} +6 -4
- package/dist/{crossDocumentDataMatchManager-yCWCOzcU.d.ts → crossDocumentDataMatchManager-crZcIUSY.d.ts} +3 -3
- package/dist/curp-DZGvefg3.esm.js +14 -0
- package/dist/curp-validation.d.ts +1 -1
- package/dist/curp-validation.esm.js +2 -2
- package/dist/{curpValidationManager-DNpC3wyf.esm.js → curpValidationManager-CbvBDoE1.esm.js} +6 -4
- package/dist/{curpValidationManager-z8428oCM.d.ts → curpValidationManager-Ci2iVuog.d.ts} +4 -4
- package/dist/{curpValidationStateMachine-B3iVsDyt.esm.js → curpValidationStateMachine-BQ8XK2Y3.esm.js} +5 -5
- package/dist/custom-fields.d.ts +1 -1
- package/dist/custom-fields.esm.js +1 -1
- package/dist/custom-watchlist.d.ts +1 -1
- package/dist/custom-watchlist.esm.js +2 -2
- package/dist/{customFieldsManager-CvI-pDT3.esm.js → customFieldsManager-BRqSCR9R.esm.js} +6 -4
- package/dist/{customFieldsManager-CF-cO8ap.d.ts → customFieldsManager-CdWTbsew.d.ts} +3 -3
- package/dist/{customWatchlistManager-BuHtUb0y.esm.js → customWatchlistManager-Bd1ooIDB.esm.js} +5 -3
- package/dist/{customWatchlistManager-DolUswyR.d.ts → customWatchlistManager-lJrveDS4.d.ts} +3 -3
- package/dist/{customWatchlistStateMachine-CiVD9wyF.esm.js → customWatchlistStateMachine-r8nGhyo1.esm.js} +3 -3
- package/dist/{deepsightLoader-B7DEYoyY.esm.js → deepsightLoader-CEY2mSPM.esm.js} +5 -5
- package/dist/{addressSearch-DzbE9Ogt.esm.js → definitionSource-Nw0YCbpe.esm.js} +39 -72
- package/dist/{desktopCameraElection-BGMtYwk3.esm.js → desktopCameraElection-enVPfRsQ.esm.js} +5 -5
- package/dist/document-capture.d.ts +1 -1
- package/dist/document-capture.esm.js +2 -2
- package/dist/{documentCaptureManager-CD5iQiUI.d.ts → documentCaptureManager-BZBmcOKI.d.ts} +4 -3
- package/dist/{documentCaptureManager-DLPqruXJ.esm.js → documentCaptureManager-C11k5BO-.esm.js} +5 -3
- package/dist/{documentCaptureStateMachine-DCvWQhFG.esm.js → documentCaptureStateMachine-g0gfL0_1.esm.js} +6 -6
- package/dist/dynamic-forms.d.ts +1 -1
- package/dist/dynamic-forms.esm.js +2 -2
- package/dist/{dynamicFormsManager-DfqCEPg9.esm.js → dynamicFormsManager-BmfCZ2zV.esm.js} +5 -3
- package/dist/{dynamicFormsManager-9kwY8Bf5.d.ts → dynamicFormsManager-C45pTncO.d.ts} +3 -3
- package/dist/{dynamicFormsStateMachine-USQMB-uV.esm.js → dynamicFormsStateMachine-B-eYytau.esm.js} +4 -4
- package/dist/ekyb.d.ts +3 -3
- package/dist/ekyb.esm.js +2 -2
- package/dist/{ekybManager-CR8YSYux.esm.js → ekybManager-BPaMfbgw.esm.js} +5 -3
- package/dist/{ekybManager-BLOkwmWO.d.ts → ekybManager-BflWuTe4.d.ts} +3 -3
- package/dist/{ekybStateMachine-kHwdz6hm.esm.js → ekybStateMachine-C_lEw4I7.esm.js} +19 -19
- package/dist/ekyc-prefill.d.ts +17 -0
- package/dist/ekyc-prefill.esm.js +3 -0
- package/dist/ekyc.d.ts +3 -3
- package/dist/ekyc.esm.js +3 -3
- package/dist/{ekycManager-DlGIn9wA.d.ts → ekycManager-BKVQazAb.d.ts} +48 -7
- package/dist/{ekycManager-DymCvmVB.esm.js → ekycManager-nRT0rxei.esm.js} +39 -16
- package/dist/ekycPrefillManager-CCtbmrFd.esm.js +103 -0
- package/dist/ekycPrefillManager-DOTl3Y2w.d.ts +566 -0
- package/dist/ekycPrefillStateMachine-XpxgCAoC.esm.js +687 -0
- package/dist/ekycRules-DXP2hqVw.esm.js +479 -0
- package/dist/{ekycStateMachine-CoFCUJ2z.esm.js → ekycStateMachine-nwJRel2s.esm.js} +915 -596
- package/dist/{ekycUtils-GRuMELYr.esm.js → ekycUtils-FcqA6oU4.esm.js} +68 -49
- package/dist/electronic-signature.d.ts +1 -1
- package/dist/electronic-signature.esm.js +1 -1
- package/dist/{electronicSignatureManager-DTSLOvKR.d.ts → electronicSignatureManager-5tYz-a4o.d.ts} +4 -3
- package/dist/{electronicSignatureManager-BCE3uA3z.esm.js → electronicSignatureManager-M2O2VDks.esm.js} +8 -6
- package/dist/email.d.ts +1 -1
- package/dist/email.esm.js +2 -2
- package/dist/{emailManager-CGoE3CUe.esm.js → emailManager-Co4jarT1.esm.js} +5 -3
- package/dist/{emailManager-Dy6omJVp.d.ts → emailManager-pM7ZPuMa.d.ts} +3 -3
- package/dist/{emailStateMachine-KgHfDNvM.esm.js → emailStateMachine-CTEaYncs.esm.js} +4 -4
- package/dist/events-CP3yOzAl.esm.js +299 -0
- package/dist/events.d.ts +3 -1
- package/dist/events.esm.js +2 -1
- package/dist/extensibility.d.ts +43 -42
- package/dist/extensibility.esm.js +39 -38
- package/dist/{externalFetch-CQY41QT1.esm.js → externalFetch-cUjJYyXj.esm.js} +1 -1
- package/dist/face-match.d.ts +1 -1
- package/dist/face-match.esm.js +2 -2
- package/dist/{faceCaptureManagerFactory-Dp90bedH.esm.js → faceCaptureManagerFactory-3Or5qfbA.esm.js} +17 -6
- package/dist/{faceCaptureManagerFactory-DV2ULUYS.d.ts → faceCaptureManagerFactory-CRGajjZ4.d.ts} +18 -11
- package/dist/{faceCaptureSetup-ZfiWg0fo.esm.js → faceCaptureSetup-Cf87i0rT.esm.js} +46 -38
- package/dist/{faceMatchManager-Z4UDLwAv.d.ts → faceMatchManager-C5b5WtcY.d.ts} +12 -5
- package/dist/{faceMatchManager-D2xKPjjQ.esm.js → faceMatchManager-CGmNGbov.esm.js} +5 -3
- package/dist/{faceMatchStateMachine-CUvwiQi9.esm.js → faceMatchStateMachine-BuHt7kec.esm.js} +44 -18
- package/dist/{feature-management-BbCIA4og.esm.js → feature-management-DG016L6E.esm.js} +1 -1
- package/dist/feature-management.esm.js +1 -1
- package/dist/field-comparison.d.ts +1 -1
- package/dist/field-comparison.esm.js +1 -1
- package/dist/{fieldComparisonManager-DgDbEeFZ.esm.js → fieldComparisonManager-VgCU4X96.esm.js} +6 -4
- package/dist/{fieldComparisonManager-CUX4gza2.d.ts → fieldComparisonManager-mFOHRhVd.d.ts} +3 -3
- package/dist/fiscal-qr.d.ts +1 -1
- package/dist/fiscal-qr.esm.js +1 -1
- package/dist/{fiscalQrManager-D0Iy7EKR.d.ts → fiscalQrManager-DFnFVpP9.d.ts} +3 -3
- package/dist/{fiscalQrManager-BZeklojR.esm.js → fiscalQrManager-DOLq45ph.esm.js} +6 -4
- package/dist/flow-events.d.ts +1 -1
- package/dist/flow.d.ts +71 -20
- package/dist/flow.esm.js +285 -68
- package/dist/{flowCompletionService-CcCnPs_T.esm.js → flowCompletionService-BpeAbbXc.esm.js} +24 -3
- package/dist/{flowServices-Dmnc8Rye.esm.js → flowServices-rDg1bAMs.esm.js} +393 -13
- package/dist/geolocation.d.ts +1 -1
- package/dist/geolocation.esm.js +2 -2
- package/dist/{geolocationManager-6e1i9UIR.d.ts → geolocationManager-CENrvxpK.d.ts} +4 -3
- package/dist/{geolocationManager-BJJ3m_I8.esm.js → geolocationManager-T8m4lqvF.esm.js} +5 -3
- package/dist/{geolocationStateMachine-CTI3m4Ie.esm.js → geolocationStateMachine-NWmA1Dtn.esm.js} +5 -5
- package/dist/government-validation.d.ts +1 -1
- package/dist/government-validation.esm.js +2 -2
- package/dist/{governmentValidationManager-CjChjZ3C.esm.js → governmentValidationManager-6JQQkzha.esm.js} +5 -3
- package/dist/{governmentValidationManager-B82zOut8.d.ts → governmentValidationManager-De_vU7bm.d.ts} +4 -4
- package/dist/{governmentValidationStateMachine-AEbn3Afi.esm.js → governmentValidationStateMachine-wBunpfQ9.esm.js} +3 -3
- package/dist/home.d.ts +4 -3
- package/dist/home.esm.js +4 -2
- package/dist/http.esm.js +1 -1
- package/dist/id-ocr.d.ts +2 -2
- package/dist/id-ocr.esm.js +3 -19
- package/dist/id-selfie-flow.d.ts +6 -5
- package/dist/id-selfie-flow.esm.js +12 -11
- package/dist/id-verification.d.ts +1 -1
- package/dist/id-verification.esm.js +2 -2
- package/dist/id.d.ts +3 -3
- package/dist/id.esm.js +3 -3
- package/dist/{idCaptureDefaults-Dszuq9ng.esm.js → idCaptureDefaults-Cjesf5i9.esm.js} +3 -3
- package/dist/{idCaptureManager-B3oR4RnA.esm.js → idCaptureManager-5-ReVgbB.esm.js} +12 -10
- package/dist/{idCaptureManager-CCA2D1Ah.d.ts → idCaptureManager-Cqx2y_fC.d.ts} +12 -11
- package/dist/{idCaptureServices-DK0QboqT.esm.js → idCaptureServices-exB6I9lV.esm.js} +7 -7
- package/dist/{idCaptureStateMachine-zzar9MPy.esm.js → idCaptureStateMachine-DQ14d3GR.esm.js} +51 -21
- package/dist/idOcrCpfUtils-D5Gwskxu.esm.js +18 -0
- package/dist/{idOcrManager-BTdHlJ9D.d.ts → idOcrManager-C0C7lFGd.d.ts} +6 -5
- package/dist/{idOcrManager-xyEZNOBa.esm.js → idOcrManager-im7VfJQi.esm.js} +5 -3
- package/dist/{idOcrStateMachine-DNKXh4Rn.esm.js → idOcrStateMachine-B832arAl.esm.js} +10 -9
- package/dist/{idVerificationManager-BJapZfpy.d.ts → idVerificationManager-B6R8xNZq.d.ts} +4 -3
- package/dist/{idVerificationManager-DdnvYfgN.esm.js → idVerificationManager-PMGM4hXY.esm.js} +5 -3
- package/dist/{idVerificationStateMachine-DtIBCa32.esm.js → idVerificationStateMachine-DeeugC00.esm.js} +3 -3
- package/dist/identity-reuse.d.ts +2 -2
- package/dist/identity-reuse.esm.js +2 -2
- package/dist/identity-search.d.ts +97 -0
- package/dist/identity-search.esm.js +97 -0
- package/dist/{identityReuseManager-ooAbp6Kc.d.ts → identityReuseManager-CZ-qJ_Aa.d.ts} +82 -15
- package/dist/{identityReuseManager-CcpovlfD.esm.js → identityReuseManager-CjFZ7WRa.esm.js} +9 -4
- package/dist/{identityReuseStateMachine-DxZFWy47.esm.js → identityReuseStateMachine-CLFjPp13.esm.js} +22 -25
- package/dist/index-DHuAkTe0.d.ts +1 -0
- package/dist/{index-DEfwds5y.d.ts → index-DM43R87x.d.ts} +43 -19
- package/dist/{index-DC0P2Vzw.d.ts → index-DxYNO94y.d.ts} +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/{invokeOnCaptureCallback-BJ0GVHGr.esm.js → invokeOnCaptureCallback-lXP41N7b.esm.js} +1 -1
- package/dist/kyb-checks.d.ts +1 -1
- package/dist/kyb-checks.esm.js +2 -2
- package/dist/{kybChecksManager-CblEL97E.d.ts → kybChecksManager-B7Di9auB.d.ts} +3 -3
- package/dist/{kybChecksManager-DpGOp4Su.esm.js → kybChecksManager-CZfdCkLC.esm.js} +3 -2
- package/dist/{kybChecksStateMachine-B43NAnv7.esm.js → kybChecksStateMachine-DkWxSU4L.esm.js} +9 -7
- package/dist/mandatory-consent.d.ts +2 -2
- package/dist/mandatory-consent.esm.js +2 -2
- package/dist/{mandatoryConsentManager-B88Sm5nd.d.ts → mandatoryConsentManager-Bh1asNJh.d.ts} +24 -14
- package/dist/{mandatoryConsentManager-B4vCYslr.esm.js → mandatoryConsentManager-Dh3pBhOe.esm.js} +5 -3
- package/dist/{mandatoryConsentStateMachine-DWslYPA3.esm.js → mandatoryConsentStateMachine-BjuI72HZ.esm.js} +13 -7
- package/dist/{mediaRecorderOptions-B9-IEVtV.esm.js → mediaRecorderOptions-g1TwTlhd.esm.js} +20 -3
- package/dist/{multipartRecordingService-BTqkHGG9.esm.js → multipartRecordingService-WgK8ieRI.esm.js} +2 -2
- package/dist/{permissionGuards-DFV-Ws0a.esm.js → permissionGuards-D-4_VU7-.esm.js} +1 -1
- package/dist/{permissionServices-D190ATGD.esm.js → permissionServices-DpccEnzE.esm.js} +1 -1
- package/dist/phone.d.ts +1 -1
- package/dist/phone.esm.js +2 -2
- package/dist/phoneFormat-C3q0Ukh4.esm.js +27 -0
- package/dist/{phoneManager-6nrJkvkG.d.ts → phoneManager-VO1HEoUZ.d.ts} +3 -3
- package/dist/{phoneManager-Dy5tODCU.esm.js → phoneManager-rA7updqF.esm.js} +5 -3
- package/dist/{phoneServices-DJgyOzU2.esm.js → phoneServices-CFXcwCFr.esm.js} +1 -1
- package/dist/{phoneStateMachine-DnlPhnw7.esm.js → phoneStateMachine-DKdY2Scx.esm.js} +4 -4
- package/dist/{processFaceMatch-Bst83HaS.esm.js → processFaceMatch-B_DkDTE5.esm.js} +1 -1
- package/dist/qe-signature.d.ts +2 -2
- package/dist/qe-signature.esm.js +1 -1
- package/dist/{recordingService-CTko6Cjn.esm.js → recordingService-DxiwS8TV.esm.js} +5 -5
- package/dist/redirect-to-mobile.d.ts +1 -1
- package/dist/redirect-to-mobile.esm.js +2 -2
- package/dist/{redirectToMobileManager-CgGaT2NP.esm.js → redirectToMobileManager-DTB_pWuS.esm.js} +6 -4
- package/dist/{redirectToMobileManager-Dm9ctRCC.d.ts → redirectToMobileManager-pT6FiPE7.d.ts} +3 -3
- package/dist/{redirectToMobileStateMachine-CbhN8uVN.esm.js → redirectToMobileStateMachine-nP9DM01_.esm.js} +4 -4
- package/dist/{resolveForm-O7-r79VA.esm.js → resolveForm-DaaQSVWp.esm.js} +8 -213
- package/dist/{runChildModule-BffFArwl.esm.js → runChildModule-CXLcOcXN.esm.js} +8 -6
- package/dist/{sdkVersion-CDd_gaR7.esm.js → sdkVersion-fqxsdqFZ.esm.js} +1 -1
- package/dist/selfie.d.ts +4 -4
- package/dist/selfie.esm.js +13 -12
- package/dist/{selfieErrorUtils-f4MgAG2A.esm.js → selfieErrorUtils-MOfYdGPz.esm.js} +1 -1
- package/dist/{selfieManager-DmZFzs1-.d.ts → selfieManager-DihwheJ6.d.ts} +2 -2
- package/dist/{selfieManager-hopelYEk.esm.js → selfieManager-Dq8tIqGd.esm.js} +7 -6
- package/dist/{selfieStateMachine-DaZIVv3Q.esm.js → selfieStateMachine-BZVDQB8R.esm.js} +5 -5
- package/dist/{session-CdSX4wsZ.esm.js → session-C7x_iJ-p.esm.js} +4 -4
- package/dist/session.d.ts +2 -2
- package/dist/session.esm.js +5 -5
- package/dist/{sessionInitializer-DsL7X2j9.esm.js → sessionInitializer-k-hKIBg8.esm.js} +21 -9
- package/dist/{setup-DDahygZs.esm.js → setup-BRbhjHiU.esm.js} +13 -15
- package/dist/{setup-D9qt8YVU.d.ts → setup-CpXbdA1X.d.ts} +2 -2
- package/dist/signature.d.ts +1 -1
- package/dist/signature.esm.js +2 -2
- package/dist/{signatureManager-CwqjcxPg.esm.js → signatureManager-BgAja97K.esm.js} +5 -3
- package/dist/{signatureManager-BpVt_Jv7.d.ts → signatureManager-daT_8fj_.d.ts} +3 -3
- package/dist/{signatureStateMachine-DBVDd1Eu.esm.js → signatureStateMachine-CVPmvU2p.esm.js} +3 -3
- package/dist/{spawn-D9jgw9pW.d.ts → spawn-COZKetCS.d.ts} +1 -1
- package/dist/{stats-CatA2dea.esm.js → stats-DoByUnTa.esm.js} +1 -1
- package/dist/stats.esm.js +1 -1
- package/dist/step-up.d.ts +379 -0
- package/dist/step-up.esm.js +640 -0
- package/dist/{tri-DG6priFa.esm.js → tri-CI2exudk.esm.js} +29 -34
- package/dist/tri.d.ts +2 -2
- package/dist/tri.esm-CxLWmTZk.esm.js +2287 -0
- package/dist/tri.esm.js +2 -2
- package/dist/{trueSightService-GuLthUVK.esm.js → trueSightService-DhW2O8mB.esm.js} +7 -4
- package/dist/trust-graph.d.ts +4 -3
- package/dist/trust-graph.esm.js +5 -3
- package/dist/{types-BEVHQbbC.d.ts → types-9wlf1-GE.d.ts} +3 -3
- package/dist/types-B-PIc0en.d.ts +115 -0
- package/dist/{types-CJ7Yl9K-.d.ts → types-Bpo97EOh.d.ts} +4 -2
- package/dist/{types-BQA7lRDV.d.ts → types-C3rfDzgE.d.ts} +4 -2
- package/dist/types-CE1jkHw3.d.ts +6 -0
- package/dist/{types-BPm1JSu7.d.ts → types-Cpdum4vi.d.ts} +5 -5
- package/dist/{types-CuMJ2M7D.d.ts → types-DEa3taWc.d.ts} +8 -1
- package/dist/{types-Csh8vzPo.d.ts → types-DFP7eSle.d.ts} +1 -1
- package/dist/{types-Cd0J0F9D.d.ts → types-DJPU3W2M.d.ts} +3 -2
- package/dist/{events-ggpBBaZ8.esm.js → types-DYYMdAGv.esm.js} +3 -298
- package/dist/{types-CRaFu6wS.d.ts → types-Ddc4Tr_f.d.ts} +37 -4
- package/dist/{urlUtils-eYiyWjh0.esm.js → urlUtils-B2wagB5v.esm.js} +14 -1
- package/dist/usStates-CwOQ2kAx.esm.js +209 -0
- package/dist/video-selfie.d.ts +9 -7
- package/dist/video-selfie.esm.js +14 -13
- package/dist/{videoSelfieCameraWarmer-e3irGfcO.esm.js → videoSelfieCameraWarmer-YwO_uP-b.esm.js} +14 -12
- package/dist/{videoSelfieFlowModuleMachine-BCFVHBQ1.esm.js → videoSelfieFlowModuleMachine-IWdxw1TW.esm.js} +1 -1
- package/dist/{videoSelfieStepDetector-Dv3Mgws-.d.ts → videoSelfieStepDetector-DRrh4P0A.d.ts} +4 -4
- package/dist/{warmup-DtB0DJpl.esm.js → warmup-9iKKNNuW.esm.js} +46 -4
- package/dist/{warmup-BO57syF6.d.ts → warmup-BNhIuURi.d.ts} +18 -2
- package/dist/wasm.d.ts +9 -3
- package/dist/wasm.esm.js +3 -3
- package/dist/{wasmDsFlagSync-BtiR5pig.esm.js → wasmDsFlagSync-D_6e8W62.esm.js} +1 -1
- package/dist/{wasmWebClient-BDrax6Eu.esm.js → wasmWebClient-C3v3s_4H.esm.js} +22 -10
- package/dist/watchlist-for-business.d.ts +1 -1
- package/dist/watchlist-for-business.esm.js +2 -2
- package/dist/watchlist.d.ts +1 -1
- package/dist/watchlist.esm.js +2 -2
- package/dist/{watchlistForBusinessManager-DqUpAEj_.esm.js → watchlistForBusinessManager-BH6M4kqA.esm.js} +5 -3
- package/dist/{watchlistForBusinessManager-DX2AyM4Y.d.ts → watchlistForBusinessManager-l7ZERQcV.d.ts} +3 -3
- package/dist/{watchlistForBusinessStateMachine-DdaPl2PS.esm.js → watchlistForBusinessStateMachine-BMWm5mcP.esm.js} +4 -4
- package/dist/{watchlistManager-CdpXzT4B.esm.js → watchlistManager-BDaVjzLW.esm.js} +5 -3
- package/dist/{watchlistManager-DJQOd8Pw.d.ts → watchlistManager-DQq4GxBO.d.ts} +3 -3
- package/dist/{watchlistStateMachine-ofHW_lPk.esm.js → watchlistStateMachine-Cx-6QAvu.esm.js} +3 -3
- package/dist/workflow.d.ts +230 -44
- package/dist/workflow.esm.js +171 -67
- package/dist/{xstate-actors.esm-8Gzepa_A.esm.js → xstate-actors.esm-BCcwgosu.esm.js} +1 -1
- package/dist/xstate.cjs-D6Ur0X1F.d.ts +7 -0
- package/dist/{xstate.esm-DSajW7CJ.esm.js → xstate.esm-CIqUf_i6.esm.js} +1 -125
- package/package.json +16 -1
- package/dist/Actor-DpTj5PFb.d.ts +0 -1
- package/dist/cpf-uAZTPUBy.esm.js +0 -61
- package/dist/index-DpTj5PFb.d.ts +0 -1
- package/dist/nationalIds-B91f_RuB.esm.js +0 -99
- package/dist/phoneFormat-JJNaWthV.esm.js +0 -75
- package/dist/tri.esm-CzTNi5Q_.esm.js +0 -3826
- package/dist/types-J6g6iKe_.d.ts +0 -6
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-CpP4PS4S.esm.js";
|
|
2
|
-
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
3
|
-
import { t as fromCallback } from "./xstate-actors.esm-8Gzepa_A.esm.js";
|
|
4
1
|
//#region src/shared/addressSuggestion.ts
|
|
5
2
|
/** Shown when an autocomplete suggestion has no street (city/region-level result). */
|
|
6
3
|
const STREET_LEVEL_REQUIRED_ERROR = { key: "verification.errors.streetLevelRequired" };
|
|
@@ -55,6 +52,31 @@ function buildStreetValue(street, houseNumber, hasHouseNoField) {
|
|
|
55
52
|
if (houseNumber && street) return `${houseNumber} ${street}`;
|
|
56
53
|
return houseNumber ?? street ?? "";
|
|
57
54
|
}
|
|
55
|
+
/**
|
|
56
|
+
* Keeps an address suggestion's region inside the `state` dropdown. A region
|
|
57
|
+
* that matches an option's value or label, ignoring case, becomes that
|
|
58
|
+
* option's value. One that matches none is dropped, as if the suggestion had
|
|
59
|
+
* no region, so the previous `state` stays if it matches an option the same
|
|
60
|
+
* way, also as that option's value (a prefill can leave `KOWLOON`, or a value
|
|
61
|
+
* no option has). Without this, a code such as `HK` would pass `required` and
|
|
62
|
+
* be submitted though the dropdown can't show it. A free-text `state` takes
|
|
63
|
+
* the suggestion as it is. Shared between eKYC and eKYB address forms; run it
|
|
64
|
+
* on `fillFromSuggestion`'s values.
|
|
65
|
+
*/
|
|
66
|
+
function keepSuggestedStateInOptions(fields, previous, next) {
|
|
67
|
+
const options = fields.find((field) => field.name === "state")?.options;
|
|
68
|
+
const suggested = next.state;
|
|
69
|
+
if (!options || !suggested) return next;
|
|
70
|
+
const optionFor = (value) => {
|
|
71
|
+
const wanted = value?.trim().toUpperCase();
|
|
72
|
+
if (!wanted) return void 0;
|
|
73
|
+
return options.find((option) => option.value.toUpperCase() === wanted || option.label.toUpperCase() === wanted)?.value;
|
|
74
|
+
};
|
|
75
|
+
return {
|
|
76
|
+
...next,
|
|
77
|
+
state: optionFor(suggested) ?? optionFor(previous.state)
|
|
78
|
+
};
|
|
79
|
+
}
|
|
58
80
|
const POSTAL_CODE_MAX_LENGTH_BY_COUNTRY = {
|
|
59
81
|
US: 10,
|
|
60
82
|
BR: 9,
|
|
@@ -86,6 +108,7 @@ const FIXED_DIGIT_POSTAL_CODE_LENGTH = {
|
|
|
86
108
|
CN: 6,
|
|
87
109
|
IN: 6,
|
|
88
110
|
NG: 6,
|
|
111
|
+
RO: 6,
|
|
89
112
|
SG: 6,
|
|
90
113
|
IL: 7
|
|
91
114
|
};
|
|
@@ -102,6 +125,18 @@ function getPostalCodeErrorKey(country) {
|
|
|
102
125
|
if (country === "US") return "verification.errors.zipCodeInvalidFormat";
|
|
103
126
|
return "verification.errors.postalCodeInvalidFormat";
|
|
104
127
|
}
|
|
128
|
+
/**
|
|
129
|
+
* The params of a postal code's error message: the digit count for a
|
|
130
|
+
* fixed-length format, otherwise the maximum length. US and BR don't count
|
|
131
|
+
* the dash.
|
|
132
|
+
*/
|
|
133
|
+
function getPostalCodeErrorParams(country) {
|
|
134
|
+
const fixedLength = FIXED_DIGIT_POSTAL_CODE_LENGTH[country];
|
|
135
|
+
if (fixedLength !== void 0) return { length: fixedLength };
|
|
136
|
+
let maxLength = getPostalCodeMaxLength(country);
|
|
137
|
+
if (country === "US" || country === "BR") maxLength = maxLength - 1;
|
|
138
|
+
return { maxLength };
|
|
139
|
+
}
|
|
105
140
|
const US_POSTAL_CODE_REGEX = /^(?:\d{5}|\d{9}|\d{5}-\d{4})$/;
|
|
106
141
|
const BR_POSTAL_CODE_REGEX = /^(?:\d{5}|\d{8}|\d{5}-\d{3})$/;
|
|
107
142
|
const CA_POSTAL_CODE_REGEX = /^[A-Za-z]\d[A-Za-z] \d[A-Za-z]\d$/;
|
|
@@ -183,72 +218,4 @@ function createBundledDefinitionSource(definitions) {
|
|
|
183
218
|
return { select: (query) => byQuery.get(queryKey(query)) };
|
|
184
219
|
}
|
|
185
220
|
//#endregion
|
|
186
|
-
|
|
187
|
-
/**
|
|
188
|
-
* The rollout switch for form definitions (ENG-59781): one all-or-nothing
|
|
189
|
-
* answer to "do eKYC and eKYB build their forms from catalog definitions, or
|
|
190
|
-
* with today's builders?". Both module adapters ask it before selecting a
|
|
191
|
-
* definition (`selectEkycDefinition`, `selectEkybForm`); the forms kernel
|
|
192
|
-
* (`internal/forms`) knows nothing about it.
|
|
193
|
-
*
|
|
194
|
-
* Off by default, so every source and country keeps today's builder. A
|
|
195
|
-
* catalog-only eKYC source, one today's builder never knew, uses its
|
|
196
|
-
* definition either way, since it has no old path to fall back to.
|
|
197
|
-
*
|
|
198
|
-
* This is Incode's rollout decision, not the integrator's: it is not a
|
|
199
|
-
* `setup()` option. A later step reads a Statsig gate here instead of the
|
|
200
|
-
* constant.
|
|
201
|
-
*/
|
|
202
|
-
const ENABLED_BY_DEFAULT = false;
|
|
203
|
-
/** Whether sources and countries with a form definition use it. */
|
|
204
|
-
function isFormDefinitionsEnabled() {
|
|
205
|
-
return ENABLED_BY_DEFAULT;
|
|
206
|
-
}
|
|
207
|
-
//#endregion
|
|
208
|
-
//#region src/shared/addressSearch.ts
|
|
209
|
-
/** Searches for address suggestions via the address autocomplete API. */
|
|
210
|
-
async function searchAddress(query, signal) {
|
|
211
|
-
const res = await api.post(endpoints.addressAutocomplete, { search: query }, { signal });
|
|
212
|
-
if (!res.ok) throw new Error(`POST ${endpoints.addressAutocomplete} failed: ${res.status} ${res.statusText}`);
|
|
213
|
-
return { apiResponse: { items: (res.data.apiResponse?.items ?? []).map((item, i) => {
|
|
214
|
-
const addr = item.address ?? item;
|
|
215
|
-
return {
|
|
216
|
-
id: item.id ?? i,
|
|
217
|
-
label: addr.label ?? item.title ?? "",
|
|
218
|
-
street: addr.street,
|
|
219
|
-
city: addr.city,
|
|
220
|
-
stateCode: addr.stateCode ?? addr.state,
|
|
221
|
-
postalCode: addr.postalCode,
|
|
222
|
-
houseNumber: addr.houseNumber,
|
|
223
|
-
countryCode: addr.countryCode
|
|
224
|
-
};
|
|
225
|
-
}) } };
|
|
226
|
-
}
|
|
227
|
-
const DEBOUNCE_MS = 300;
|
|
228
|
-
/**
|
|
229
|
-
* XState callback actor that debounces address search requests.
|
|
230
|
-
* Cancels in-flight HTTP requests when the actor is stopped.
|
|
231
|
-
*/
|
|
232
|
-
const debounceSearchActor = fromCallback(({ input, sendBack }) => {
|
|
233
|
-
const timerProvider = BrowserTimerProvider.getInstance();
|
|
234
|
-
const controller = new AbortController();
|
|
235
|
-
const handle = timerProvider.setTimeout(async () => {
|
|
236
|
-
try {
|
|
237
|
-
sendBack({
|
|
238
|
-
type: "RESULTS",
|
|
239
|
-
suggestions: (await searchAddress(input.query, controller.signal)).apiResponse?.items ?? []
|
|
240
|
-
});
|
|
241
|
-
} catch {
|
|
242
|
-
if (!controller.signal.aborted) sendBack({
|
|
243
|
-
type: "RESULTS",
|
|
244
|
-
suggestions: []
|
|
245
|
-
});
|
|
246
|
-
}
|
|
247
|
-
}, DEBOUNCE_MS);
|
|
248
|
-
return () => {
|
|
249
|
-
timerProvider.clearTimeout(handle);
|
|
250
|
-
controller.abort();
|
|
251
|
-
};
|
|
252
|
-
});
|
|
253
|
-
//#endregion
|
|
254
|
-
export { FIXED_DIGIT_POSTAL_CODE_LENGTH as a, getPostalCodeMaxLength as c, fillFromSuggestion as d, getStreetLevelErrorForSuggestion as f, createBundledDefinitionSource as i, validatePostalCode as l, searchAddress as n, formatPostalCode as o, isFormDefinitionsEnabled as r, getPostalCodeErrorKey as s, debounceSearchActor as t, STREET_LEVEL_REQUIRED_ERROR as u };
|
|
221
|
+
export { getPostalCodeMaxLength as a, fillFromSuggestion as c, getPostalCodeErrorParams as i, getStreetLevelErrorForSuggestion as l, formatPostalCode as n, validatePostalCode as o, getPostalCodeErrorKey as r, STREET_LEVEL_REQUIRED_ERROR as s, createBundledDefinitionSource as t, keepSuggestedStateInOptions as u };
|
package/dist/{desktopCameraElection-BGMtYwk3.esm.js → desktopCameraElection-enVPfRsQ.esm.js}
RENAMED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { n as getTimestamp } from "./IBrowserEnvironmentCapability-D7JG7ML3.esm.js";
|
|
2
|
-
import { d as getCameraCycleOwnershipDomain, l as wasmRuntime, u as CAMERA_CYCLE_OWNERSHIP_DOMAIN } from "./warmup-
|
|
3
|
-
import { i as utilityWasmApi } from "./WasmUtilProvider-
|
|
4
|
-
import { t as api, u as endpoints } from "./api-
|
|
5
|
-
import { t as fromCallback } from "./xstate-actors.esm-
|
|
2
|
+
import { d as getCameraCycleOwnershipDomain, l as wasmRuntime, u as CAMERA_CYCLE_OWNERSHIP_DOMAIN } from "./warmup-9iKKNNuW.esm.js";
|
|
3
|
+
import { i as utilityWasmApi } from "./WasmUtilProvider-DdhAHHw4.esm.js";
|
|
4
|
+
import { t as api, u as endpoints } from "./api-CZpuJuZl.esm.js";
|
|
5
|
+
import { t as fromCallback } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
6
6
|
import { l as markCameraGrantedInDocument, n as enumerateVideoDevices, o as clearCameraGrantedInDocument, s as isCameraDenialErrorName } from "./camera-E_Kcre4O.esm.js";
|
|
7
|
-
import { l as queryCameraPermission } from "./permissionServices-
|
|
7
|
+
import { l as queryCameraPermission } from "./permissionServices-DpccEnzE.esm.js";
|
|
8
8
|
import { r as selectBestBackDevice, t as isBackCameraLabel } from "./backCameraLabel-yda5ugE4.esm.js";
|
|
9
9
|
import { t as getDeviceClass } from "./getDeviceClass-DoIWuKI8.esm.js";
|
|
10
10
|
//#region ../infra/src/capabilities/ICameraCycleCapability.ts
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { a as DocumentCaptureErrorCode, c as DocumentType, n as DOCUMENT_CAPTURE_ERROR_CODES, r as DocumentCaptureConfig, s as DocumentCaptureNextPageType, u as DocumentUploadStatus } from "./types-CyNndVAT.js";
|
|
2
|
-
import { a as DocumentCaptureActor, i as createDocumentCaptureManagerFromActor, n as DocumentCaptureState, o as documentCaptureMachine, r as createDocumentCaptureManager, t as DocumentCaptureManager } from "./documentCaptureManager-
|
|
2
|
+
import { a as DocumentCaptureActor, i as createDocumentCaptureManagerFromActor, n as DocumentCaptureState, o as documentCaptureMachine, r as createDocumentCaptureManager, t as DocumentCaptureManager } from "./documentCaptureManager-BZBmcOKI.js";
|
|
3
3
|
export { DOCUMENT_CAPTURE_ERROR_CODES, type DocumentCaptureActor, type DocumentCaptureConfig, type DocumentCaptureErrorCode, type DocumentCaptureManager, type DocumentCaptureNextPageType, type DocumentCaptureState, type DocumentType, type DocumentUploadStatus, createDocumentCaptureManager, createDocumentCaptureManagerFromActor, documentCaptureMachine };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { r as DOCUMENT_CAPTURE_ERROR_CODES, t as documentCaptureMachine } from "./documentCaptureStateMachine-
|
|
2
|
-
import { n as createDocumentCaptureManagerFromActor, t as createDocumentCaptureManager } from "./documentCaptureManager-
|
|
1
|
+
import { r as DOCUMENT_CAPTURE_ERROR_CODES, t as documentCaptureMachine } from "./documentCaptureStateMachine-g0gfL0_1.esm.js";
|
|
2
|
+
import { n as createDocumentCaptureManagerFromActor, t as createDocumentCaptureManager } from "./documentCaptureManager-C11k5BO-.esm.js";
|
|
3
3
|
export { DOCUMENT_CAPTURE_ERROR_CODES, createDocumentCaptureManager, createDocumentCaptureManagerFromActor, documentCaptureMachine };
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { A as
|
|
2
|
-
import
|
|
3
|
-
import "./
|
|
1
|
+
import { A as MachineSnapshot, O as PromiseActorLogic, S as RequiredLogicInput, T as Values, _ as IsNotNever, a as ActorRefFromLogic, b as NonReducibleUnknown, c as AnyEventObject, d as DoneActorEvent, g as InputFrom, h as GetConcreteByKey, i as ActorRefFrom, j as StateMachine, m as EventObject, o as AnyActorLogic, p as ErrorActorEvent, r as ActorRef, s as AnyActorRef, t as ActionFunction, u as ConditionalRequired, w as StateValue, x as RequiredActorOptions, y as MetaObject } from "./spawn-COZKetCS.js";
|
|
2
|
+
import "./xstate.cjs-D6Ur0X1F.js";
|
|
3
|
+
import { t as Manager } from "./Manager-DufwKlav.js";
|
|
4
|
+
import "./Actor-DqjOqDfU.js";
|
|
4
5
|
import { n as PermissionStatus, t as PermissionResult } from "./types-BEwVKkLJ.js";
|
|
5
6
|
import { a as DocumentCaptureErrorCode, c as DocumentType, d as FinalizeDocumentResponse, i as DocumentCaptureContext, l as DocumentUploadResponse, o as DocumentCaptureInput, r as DocumentCaptureConfig, s as DocumentCaptureNextPageType, t as CapturedDocument, u as DocumentUploadStatus } from "./types-CyNndVAT.js";
|
|
6
7
|
//#region src/modules/document-capture/documentCaptureStateMachine.d.ts
|
package/dist/{documentCaptureManager-DLPqruXJ.esm.js → documentCaptureManager-C11k5BO-.esm.js}
RENAMED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { n as eventModuleNames
|
|
1
|
+
import { n as eventModuleNames } from "./types-DYYMdAGv.esm.js";
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-CP3yOzAl.esm.js";
|
|
2
3
|
import { t as topLevelStateName } from "./topLevelStateName-B5i2avbh.esm.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
4
|
+
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
5
|
+
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
6
|
+
import { n as DEFAULT_MAX_FILE_SIZE, r as DOCUMENT_CAPTURE_ERROR_CODES, t as documentCaptureMachine } from "./documentCaptureStateMachine-g0gfL0_1.esm.js";
|
|
5
7
|
//#region src/modules/document-capture/documentCaptureActor.ts
|
|
6
8
|
function createDocumentCaptureActor(options) {
|
|
7
9
|
return createActor(documentCaptureMachine, { input: { config: options.config } }).start();
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
2
|
-
import { i as assign, t as setup } from "./xstate.esm-
|
|
3
|
-
import { n as fromPromise } from "./xstate-actors.esm-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CZpuJuZl.esm.js";
|
|
2
|
+
import { i as assign, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
3
|
+
import { n as fromPromise } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
4
4
|
import { a as stopCameraStream } from "./camera-E_Kcre4O.esm.js";
|
|
5
|
-
import { n as invokeRequestPermissionActor, t as checkPermission } from "./permissionServices-
|
|
6
|
-
import { r as resolveStoredPermissionResult, t as isReadyForCaptureFromPermission } from "./permissionGuards-
|
|
7
|
-
import { t as carryAttempts } from "./attemptCarry-
|
|
5
|
+
import { n as invokeRequestPermissionActor, t as checkPermission } from "./permissionServices-DpccEnzE.esm.js";
|
|
6
|
+
import { r as resolveStoredPermissionResult, t as isReadyForCaptureFromPermission } from "./permissionGuards-D-4_VU7-.esm.js";
|
|
7
|
+
import { t as carryAttempts } from "./attemptCarry-BecGGZK8.esm.js";
|
|
8
8
|
import { n as getBackCameraStream } from "./backCameraStream-DS1oDiUq.esm.js";
|
|
9
9
|
//#region src/modules/document-capture/types.ts
|
|
10
10
|
const PROCESSING_TYPE_MAP = {
|
package/dist/dynamic-forms.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { i as Screen, n as InputType, r as Question, t as DynamicFormsConfig } from "./types-BSBzhHRH.js";
|
|
2
|
-
import { c as DynamicFormsValidationErrors, n as DynamicFormsState, o as DynamicFormsResult, r as createDynamicFormsManager, s as dynamicFormsMachine, t as DynamicFormsManager } from "./dynamicFormsManager-
|
|
2
|
+
import { c as DynamicFormsValidationErrors, n as DynamicFormsState, o as DynamicFormsResult, r as createDynamicFormsManager, s as dynamicFormsMachine, t as DynamicFormsManager } from "./dynamicFormsManager-C45pTncO.js";
|
|
3
3
|
export { type DynamicFormsConfig, type DynamicFormsManager, type DynamicFormsResult, type DynamicFormsState, type DynamicFormsValidationErrors, type InputType, type Question, type Screen, createDynamicFormsManager, dynamicFormsMachine };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { t as dynamicFormsMachine } from "./dynamicFormsStateMachine-
|
|
2
|
-
import { t as createDynamicFormsManager } from "./dynamicFormsManager-
|
|
1
|
+
import { t as dynamicFormsMachine } from "./dynamicFormsStateMachine-B-eYytau.esm.js";
|
|
2
|
+
import { t as createDynamicFormsManager } from "./dynamicFormsManager-BmfCZ2zV.esm.js";
|
|
3
3
|
export { createDynamicFormsManager, dynamicFormsMachine };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { n as eventModuleNames
|
|
1
|
+
import { n as eventModuleNames } from "./types-DYYMdAGv.esm.js";
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-CP3yOzAl.esm.js";
|
|
2
3
|
import { t as topLevelStateName } from "./topLevelStateName-B5i2avbh.esm.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
4
|
+
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
5
|
+
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
6
|
+
import { t as dynamicFormsMachine } from "./dynamicFormsStateMachine-B-eYytau.esm.js";
|
|
5
7
|
//#region src/modules/dynamic-forms/dynamicFormsActor.ts
|
|
6
8
|
function createDynamicFormsActor(options) {
|
|
7
9
|
return createActor(dynamicFormsMachine, { input: { config: options.config } }).start();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as ActorRefFrom } from "./spawn-
|
|
2
|
-
import { t as Manager } from "./Manager-
|
|
3
|
-
import "./Actor-
|
|
1
|
+
import { i as ActorRefFrom } from "./spawn-COZKetCS.js";
|
|
2
|
+
import { t as Manager } from "./Manager-DufwKlav.js";
|
|
3
|
+
import "./Actor-DqjOqDfU.js";
|
|
4
4
|
import { i as Screen, t as DynamicFormsConfig } from "./types-BSBzhHRH.js";
|
|
5
5
|
//#region src/modules/dynamic-forms/dynamicFormsFields.d.ts
|
|
6
6
|
/** Map of `questionId` → currently-displayed i18n error key. */
|
package/dist/{dynamicFormsStateMachine-USQMB-uV.esm.js → dynamicFormsStateMachine-B-eYytau.esm.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
2
|
-
import { i as toIncodeApiError, r as isServerError, t as IncodeApiError } from "./apiError-
|
|
3
|
-
import { i as assign, t as setup } from "./xstate.esm-
|
|
4
|
-
import { n as fromPromise } from "./xstate-actors.esm-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CZpuJuZl.esm.js";
|
|
2
|
+
import { i as toIncodeApiError, r as isServerError, t as IncodeApiError } from "./apiError-BamZ815u.esm.js";
|
|
3
|
+
import { i as assign, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
4
|
+
import { n as fromPromise } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
5
5
|
import { t as isoDateToMs } from "./dateUtils-CvG0FvK8.esm.js";
|
|
6
6
|
//#region src/modules/dynamic-forms/dynamicFormsFields.ts
|
|
7
7
|
function getEffectiveType(question) {
|
package/dist/ekyb.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "./
|
|
1
|
+
import "./xstate.cjs-D6Ur0X1F.js";
|
|
2
2
|
import { n as AddressSuggestion } from "./textRules-D4NRinKY.js";
|
|
3
|
-
import { i as FlowModuleConfig } from "./types-
|
|
3
|
+
import { i as FlowModuleConfig } from "./types-Ddc4Tr_f.js";
|
|
4
4
|
import { a as EkybValidationError, n as EkybCountry, o as EkybValidationErrors, r as EkybFieldDef, s as UboEntry, t as EkybConfig } from "./types-BgRHw-dR.js";
|
|
5
|
-
import { n as EkybState, o as ekybMachine, r as createEkybManager, t as EkybManager } from "./ekybManager-
|
|
5
|
+
import { n as EkybState, o as ekybMachine, r as createEkybManager, t as EkybManager } from "./ekybManager-BflWuTe4.js";
|
|
6
6
|
//#region src/modules/ekyb/ekybServices.d.ts
|
|
7
7
|
type EkybFlowConfig = FlowModuleConfig['EKYB'];
|
|
8
8
|
//#endregion
|
package/dist/ekyb.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { c as ALL_COUNTRIES, f as SUPPORTED_COUNTRIES, l as DEV_ONLY_COUNTRIES, m as isSupportedCountry, o as toEkybConfig } from "./ekybUtils-Cw8Ta9Qi.esm.js";
|
|
2
|
-
import { t as ekybMachine } from "./ekybStateMachine-
|
|
3
|
-
import { t as createEkybManager } from "./ekybManager-
|
|
2
|
+
import { t as ekybMachine } from "./ekybStateMachine-C_lEw4I7.esm.js";
|
|
3
|
+
import { t as createEkybManager } from "./ekybManager-BPaMfbgw.esm.js";
|
|
4
4
|
export { ALL_COUNTRIES, DEV_ONLY_COUNTRIES, SUPPORTED_COUNTRIES, createEkybManager, ekybMachine, isSupportedCountry, toEkybConfig };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { n as eventModuleNames
|
|
1
|
+
import { n as eventModuleNames } from "./types-DYYMdAGv.esm.js";
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-CP3yOzAl.esm.js";
|
|
2
3
|
import { t as topLevelStateName } from "./topLevelStateName-B5i2avbh.esm.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
4
|
+
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
5
|
+
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
6
|
+
import { t as ekybMachine } from "./ekybStateMachine-C_lEw4I7.esm.js";
|
|
5
7
|
//#region src/modules/ekyb/ekybActor.ts
|
|
6
8
|
/**
|
|
7
9
|
* Creates and starts an eKYB actor.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as ActorRefFrom } from "./spawn-
|
|
2
|
-
import { t as Manager } from "./Manager-
|
|
3
|
-
import "./Actor-
|
|
1
|
+
import { i as ActorRefFrom } from "./spawn-COZKetCS.js";
|
|
2
|
+
import { t as Manager } from "./Manager-DufwKlav.js";
|
|
3
|
+
import "./Actor-DqjOqDfU.js";
|
|
4
4
|
import { n as AddressSuggestion } from "./textRules-D4NRinKY.js";
|
|
5
5
|
import { i as EkybFormValues, o as EkybValidationErrors, r as EkybFieldDef, s as UboEntry, t as EkybConfig } from "./types-BgRHw-dR.js";
|
|
6
6
|
//#region src/modules/ekyb/ekybStateMachine.d.ts
|
|
@@ -1,19 +1,14 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-
|
|
2
|
-
import { n as getFlow } from "./flowServices-
|
|
3
|
-
import { i as assign, t as setup } from "./xstate.esm-
|
|
4
|
-
import { n as fromPromise } from "./xstate-actors.esm-
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CZpuJuZl.esm.js";
|
|
2
|
+
import { n as getFlow } from "./flowServices-rDg1bAMs.esm.js";
|
|
3
|
+
import { i as assign, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
4
|
+
import { n as fromPromise } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
5
5
|
import { a as sortModulesByOrder, c as ALL_COUNTRIES, d as FIELD_ORDER, i as requiresAddressValidation, m as isSupportedCountry, n as hasAtLeastOneAddressField, o as toEkybConfig, p as UBO_FIELD_LABELS, r as isFieldOptional, s as ADDRESS_FIELDS, u as FIELD_NAME_MAPPING } from "./ekybUtils-Cw8Ta9Qi.esm.js";
|
|
6
|
-
import {
|
|
7
|
-
import { n as requiresCnpjValidation, r as validateCNPJ } from "./cnpj-
|
|
8
|
-
import { a as
|
|
6
|
+
import { t as usStateOptions } from "./usStates-CwOQ2kAx.esm.js";
|
|
7
|
+
import { n as requiresCnpjValidation, r as validateCNPJ } from "./cnpj-Bl_olpdX.esm.js";
|
|
8
|
+
import { a as getPostalCodeMaxLength, c as fillFromSuggestion, i as getPostalCodeErrorParams, l as getStreetLevelErrorForSuggestion, n as formatPostalCode, o as validatePostalCode, r as getPostalCodeErrorKey, s as STREET_LEVEL_REQUIRED_ERROR, t as createBundledDefinitionSource, u as keepSuggestedStateInOptions } from "./definitionSource-Nw0YCbpe.esm.js";
|
|
9
|
+
import { n as checkSupport, r as DYNAMIC_REQUIRED_KEY, t as resolveForm } from "./resolveForm-DaaQSVWp.esm.js";
|
|
10
|
+
import { r as isFormDefinitionsEnabled, t as debounceSearchActor } from "./addressSearch-Rxm1K67A.esm.js";
|
|
9
11
|
//#region src/modules/ekyb/ekybValidators.ts
|
|
10
|
-
const buildPostalCodeParams = (country) => {
|
|
11
|
-
const fixedLen = FIXED_DIGIT_POSTAL_CODE_LENGTH[country];
|
|
12
|
-
if (fixedLen !== void 0) return { length: fixedLen };
|
|
13
|
-
let maxLen = getPostalCodeMaxLength(country);
|
|
14
|
-
if (country === "US" || country === "BR") maxLen = maxLen - 1;
|
|
15
|
-
return { maxLength: maxLen };
|
|
16
|
-
};
|
|
17
12
|
const createValidators = () => ({
|
|
18
13
|
required: (value, _rule, field) => {
|
|
19
14
|
if (value.trim().length > 0) return void 0;
|
|
@@ -37,7 +32,7 @@ const createValidators = () => ({
|
|
|
37
32
|
if (validatePostalCode(value, rule.country)) return void 0;
|
|
38
33
|
return {
|
|
39
34
|
key: getPostalCodeErrorKey(rule.country),
|
|
40
|
-
params:
|
|
35
|
+
params: getPostalCodeErrorParams(rule.country)
|
|
41
36
|
};
|
|
42
37
|
}
|
|
43
38
|
});
|
|
@@ -342,7 +337,8 @@ const EKYB_SUPPORTED_IDS = {
|
|
|
342
337
|
groupRules: /* @__PURE__ */ new Set(),
|
|
343
338
|
optionLists: new Set(Object.keys(OPTION_LISTS)),
|
|
344
339
|
conditions: /* @__PURE__ */ new Set(),
|
|
345
|
-
prefillSources: /* @__PURE__ */ new Set()
|
|
340
|
+
prefillSources: /* @__PURE__ */ new Set(),
|
|
341
|
+
flags: /* @__PURE__ */ new Set()
|
|
346
342
|
};
|
|
347
343
|
/** Today's UBO actions use a fixed limit and a single collection. */
|
|
348
344
|
const UBO_COLLECTION = "ubos";
|
|
@@ -413,8 +409,10 @@ const bundled = createBundledDefinitionSource(EKYB_DEFINITIONS);
|
|
|
413
409
|
/**
|
|
414
410
|
* The resolved definition for this country and configuration, if one applies
|
|
415
411
|
* and the rollout is on. Every country has a builder today, so none is exempt.
|
|
412
|
+
* `useDefinitions` is the rollout answer the machine read once, when it was
|
|
413
|
+
* created.
|
|
416
414
|
*/
|
|
417
|
-
function selectEkybForm(config, verificationFields, country, useDefinitions
|
|
415
|
+
function selectEkybForm(config, verificationFields, country, useDefinitions) {
|
|
418
416
|
if (!useDefinitions) return void 0;
|
|
419
417
|
const context = toEkybResolveContext(config, verificationFields);
|
|
420
418
|
if (!context) return void 0;
|
|
@@ -756,7 +754,8 @@ const ekybMachine = setup({
|
|
|
756
754
|
fillAddressFields: assign(({ context, event }) => {
|
|
757
755
|
const { suggestion } = event;
|
|
758
756
|
const activeFields = new Set(context.fields.map((f) => f.name));
|
|
759
|
-
const { values:
|
|
757
|
+
const { values: filled } = fillFromSuggestion(context.values, {}, suggestion, activeFields);
|
|
758
|
+
const newValues = keepSuggestedStateInOptions(context.fields, context.values, filled);
|
|
760
759
|
const errs = context.validationErrors;
|
|
761
760
|
let newErrors = errs;
|
|
762
761
|
if (errs) {
|
|
@@ -849,7 +848,8 @@ const ekybMachine = setup({
|
|
|
849
848
|
RESULTS: {
|
|
850
849
|
target: "inputting",
|
|
851
850
|
actions: "setAddressSuggestions"
|
|
852
|
-
}
|
|
851
|
+
},
|
|
852
|
+
SUBMIT: { target: "validatingSubmit" }
|
|
853
853
|
}
|
|
854
854
|
},
|
|
855
855
|
validatingSubmit: {
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { a as EkycFormValues, c as EkycValidationErrors, s as EkycValidationError } from "./types-DEa3taWc.js";
|
|
2
|
+
import { a as EkycPrefillFieldDef, c as EkycPrefillModuleConfig, i as EkycPrefillErrorKind, l as EkycPrefillServedField, n as EkycPrefillConfigField, s as EkycPrefillInputFormat, t as EkycPrefillConfig } from "./types-B-PIc0en.js";
|
|
3
|
+
import { a as EkycPrefillFormState, c as EkycPrefillManager, d as EkycPrefillSubmittingState, f as createEkycPrefillManager, h as ekycPrefillMachine, i as EkycPrefillFinishedState, l as EkycPrefillMisconfiguredState, n as EkycPrefillClosedState, o as EkycPrefillIdleState, r as EkycPrefillErrorState, s as EkycPrefillLimitReachedState, t as EkycPrefillAnyOfState, u as EkycPrefillState } from "./ekycPrefillManager-DOTl3Y2w.js";
|
|
4
|
+
//#region src/modules/ekyc-prefill/ekycPrefillConfig.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Normalizes the served `EKYC_PREFILL` configuration. Idempotent, so a
|
|
7
|
+
* configuration that is already normalized passes through unchanged.
|
|
8
|
+
*
|
|
9
|
+
* - `check` and `mandatory` are `true` only when served as `true`; a `null`
|
|
10
|
+
* check hides the field.
|
|
11
|
+
* - `fields` stays `undefined` when the configuration has no `fields` array:
|
|
12
|
+
* the flat dashboard shape, which the module can't render.
|
|
13
|
+
* - `source`, `displayMode` and other per-field keys are dropped.
|
|
14
|
+
*/
|
|
15
|
+
declare function toEkycPrefillConfig(raw: EkycPrefillModuleConfig | EkycPrefillConfig | undefined): EkycPrefillConfig;
|
|
16
|
+
//#endregion
|
|
17
|
+
export { type EkycPrefillAnyOfState, type EkycPrefillClosedState, type EkycPrefillConfig, type EkycPrefillConfigField, type EkycPrefillErrorKind, type EkycPrefillErrorState, type EkycPrefillFieldDef, type EkycValidationError as EkycPrefillFieldError, type EkycValidationErrors as EkycPrefillFieldErrors, type EkycPrefillFinishedState, type EkycPrefillFormState, type EkycPrefillIdleState, type EkycPrefillInputFormat, type EkycPrefillLimitReachedState, type EkycPrefillManager, type EkycPrefillMisconfiguredState, type EkycPrefillModuleConfig, type EkycPrefillServedField, type EkycPrefillState, type EkycPrefillSubmittingState, type EkycFormValues as EkycPrefillValues, createEkycPrefillManager, ekycPrefillMachine, toEkycPrefillConfig };
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { i as toEkycPrefillConfig, t as ekycPrefillMachine } from "./ekycPrefillStateMachine-XpxgCAoC.esm.js";
|
|
2
|
+
import { t as createEkycPrefillManager } from "./ekycPrefillManager-CCtbmrFd.esm.js";
|
|
3
|
+
export { createEkycPrefillManager, ekycPrefillMachine, toEkycPrefillConfig };
|
package/dist/ekyc.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as AddressSuggestion } from "./textRules-D4NRinKY.js";
|
|
2
|
-
import { c as EkycValidationErrors, i as EkycFieldDisplayMode, n as EkycDisplayModes, o as EkycModuleConfig, s as EkycValidationError, t as EkycConfig } from "./types-
|
|
3
|
-
import {
|
|
2
|
+
import { c as EkycValidationErrors, i as EkycFieldDisplayMode, n as EkycDisplayModes, o as EkycModuleConfig, s as EkycValidationError, t as EkycConfig } from "./types-DEa3taWc.js";
|
|
3
|
+
import { a as EkycStep, n as EkycState, r as createEkycManager, s as ekycMachine, t as EkycManager } from "./ekycManager-BKVQazAb.js";
|
|
4
4
|
//#region src/modules/ekyc/ekycUtils.d.ts
|
|
5
5
|
/**
|
|
6
6
|
* Normalizes any supported eKYC config input into a manager-ready `EkycConfig`.
|
|
@@ -19,4 +19,4 @@ import { n as EkycState, o as ekycMachine, r as createEkycManager, t as EkycMana
|
|
|
19
19
|
*/
|
|
20
20
|
declare function toEkycConfig(config: Partial<EkycModuleConfig> & Partial<EkycConfig>): EkycConfig;
|
|
21
21
|
//#endregion
|
|
22
|
-
export { type AddressSuggestion, type EkycConfig, type EkycDisplayModes, type EkycFieldDisplayMode, type EkycManager, type EkycModuleConfig, type EkycState, type EkycValidationError, type EkycValidationErrors, createEkycManager, ekycMachine, toEkycConfig };
|
|
22
|
+
export { type AddressSuggestion, type EkycConfig, type EkycDisplayModes, type EkycFieldDisplayMode, type EkycManager, type EkycModuleConfig, type EkycState, type EkycStep, type EkycValidationError, type EkycValidationErrors, createEkycManager, ekycMachine, toEkycConfig };
|
package/dist/ekyc.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as ekycMachine } from "./ekycStateMachine-
|
|
2
|
-
import { l as toEkycConfig } from "./ekycUtils-
|
|
3
|
-
import { t as createEkycManager } from "./ekycManager-
|
|
1
|
+
import { t as ekycMachine } from "./ekycStateMachine-nwJRel2s.esm.js";
|
|
2
|
+
import { l as toEkycConfig } from "./ekycUtils-FcqA6oU4.esm.js";
|
|
3
|
+
import { t as createEkycManager } from "./ekycManager-nRT0rxei.esm.js";
|
|
4
4
|
export { createEkycManager, ekycMachine, toEkycConfig };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { i as ActorRefFrom } from "./spawn-
|
|
2
|
-
import { t as Manager } from "./Manager-
|
|
3
|
-
import "./Actor-
|
|
1
|
+
import { i as ActorRefFrom } from "./spawn-COZKetCS.js";
|
|
2
|
+
import { t as Manager } from "./Manager-DufwKlav.js";
|
|
3
|
+
import "./Actor-DqjOqDfU.js";
|
|
4
4
|
import { n as AddressSuggestion } from "./textRules-D4NRinKY.js";
|
|
5
|
-
import { a as EkycFormValues, c as EkycValidationErrors, r as EkycFieldDef, t as EkycConfig } from "./types-
|
|
5
|
+
import { a as EkycFormValues, c as EkycValidationErrors, r as EkycFieldDef, t as EkycConfig } from "./types-DEa3taWc.js";
|
|
6
6
|
//#region src/modules/ekyc/ekycStateMachine.d.ts
|
|
7
7
|
declare const ekycMachine: any;
|
|
8
8
|
type EkycMachine = typeof ekycMachine;
|
|
@@ -13,6 +13,17 @@ type CreateEkycActorOptions = {
|
|
|
13
13
|
config: EkycConfig;
|
|
14
14
|
};
|
|
15
15
|
//#endregion
|
|
16
|
+
//#region src/modules/ekyc/ekycSteps.d.ts
|
|
17
|
+
/**
|
|
18
|
+
* One screen of the eKYC form: a run of visible fields that share a section.
|
|
19
|
+
* `id` is `'personal'` for fields without a section, otherwise the section
|
|
20
|
+
* (`'driverLicense'` or `'address'` today).
|
|
21
|
+
*/
|
|
22
|
+
type EkycStep = {
|
|
23
|
+
id: string;
|
|
24
|
+
fieldNames: string[];
|
|
25
|
+
};
|
|
26
|
+
//#endregion
|
|
16
27
|
//#region src/modules/ekyc/ekycManager.d.ts
|
|
17
28
|
type EkycLoadingState = {
|
|
18
29
|
status: 'loading';
|
|
@@ -29,6 +40,16 @@ type EkycFormState = {
|
|
|
29
40
|
hideEmail: boolean;
|
|
30
41
|
fieldsCountry: string;
|
|
31
42
|
submitError: string;
|
|
43
|
+
/**
|
|
44
|
+
* The form's screens, one per run of visible fields that share a section
|
|
45
|
+
* (`'personal'` for fields without one). A form with one step has a single
|
|
46
|
+
* screen.
|
|
47
|
+
*/
|
|
48
|
+
steps: EkycStep[];
|
|
49
|
+
/** Index into `steps` of the screen the user is on. */
|
|
50
|
+
currentStepIndex: number;
|
|
51
|
+
/** True iff the current step's fields have no validation errors. */
|
|
52
|
+
isStepValid: boolean;
|
|
32
53
|
};
|
|
33
54
|
type EkycSubmittingState = {
|
|
34
55
|
status: 'submitting';
|
|
@@ -64,7 +85,17 @@ declare function createEkycManagerFromActor(actor: EkycActor): Manager<EkycState
|
|
|
64
85
|
searchAddress(query: string): void;
|
|
65
86
|
/** Selects an address suggestion and populates address fields */
|
|
66
87
|
selectAddress(suggestion: AddressSuggestion): void;
|
|
67
|
-
/**
|
|
88
|
+
/**
|
|
89
|
+
* Continues from the current step: validates its fields and moves to the
|
|
90
|
+
* next step when they pass. On the last step it submits, like `submit()`.
|
|
91
|
+
*/
|
|
92
|
+
next(): void;
|
|
93
|
+
/** Returns to the previous step. Keeps values and errors; does not validate. */
|
|
94
|
+
back(): void;
|
|
95
|
+
/**
|
|
96
|
+
* Submits the form. Runs full-form validation whatever the current step;
|
|
97
|
+
* advances only when no errors, otherwise moves to the first step with one.
|
|
98
|
+
*/
|
|
68
99
|
submit(): void;
|
|
69
100
|
/** Retries from failure state, returning to the form */
|
|
70
101
|
retry(): void;
|
|
@@ -84,7 +115,17 @@ declare function createEkycManager(options: CreateEkycActorOptions): Manager<Eky
|
|
|
84
115
|
searchAddress(query: string): void;
|
|
85
116
|
/** Selects an address suggestion and populates address fields */
|
|
86
117
|
selectAddress(suggestion: AddressSuggestion): void;
|
|
87
|
-
/**
|
|
118
|
+
/**
|
|
119
|
+
* Continues from the current step: validates its fields and moves to the
|
|
120
|
+
* next step when they pass. On the last step it submits, like `submit()`.
|
|
121
|
+
*/
|
|
122
|
+
next(): void;
|
|
123
|
+
/** Returns to the previous step. Keeps values and errors; does not validate. */
|
|
124
|
+
back(): void;
|
|
125
|
+
/**
|
|
126
|
+
* Submits the form. Runs full-form validation whatever the current step;
|
|
127
|
+
* advances only when no errors, otherwise moves to the first step with one.
|
|
128
|
+
*/
|
|
88
129
|
submit(): void;
|
|
89
130
|
/** Retries from failure state, returning to the form */
|
|
90
131
|
retry(): void;
|
|
@@ -95,4 +136,4 @@ declare function createEkycManager(options: CreateEkycActorOptions): Manager<Eky
|
|
|
95
136
|
};
|
|
96
137
|
type EkycManager = ReturnType<typeof createEkycManager>;
|
|
97
138
|
//#endregion
|
|
98
|
-
export {
|
|
139
|
+
export { EkycStep as a, createEkycManagerFromActor as i, EkycState as n, EkycActor as o, createEkycManager as r, ekycMachine as s, EkycManager as t };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { n as eventModuleNames
|
|
1
|
+
import { n as eventModuleNames } from "./types-DYYMdAGv.esm.js";
|
|
2
|
+
import { t as createManagerInstrumentation } from "./events-CP3yOzAl.esm.js";
|
|
2
3
|
import { t as topLevelStateName } from "./topLevelStateName-B5i2avbh.esm.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
4
|
+
import { t as createManager } from "./Manager-BvXAwDv9.esm.js";
|
|
5
|
+
import { s as createActor } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
6
|
+
import { i as isStepValid, n as buildEkycSteps, r as clampStepIndex, t as ekycMachine } from "./ekycStateMachine-nwJRel2s.esm.js";
|
|
5
7
|
//#region src/modules/ekyc/ekycActor.ts
|
|
6
8
|
/**
|
|
7
9
|
* Creates and starts an eKYC actor.
|
|
@@ -44,18 +46,25 @@ function mapState(snapshot) {
|
|
|
44
46
|
const typedSnapshot = snapshot;
|
|
45
47
|
const { context } = typedSnapshot;
|
|
46
48
|
if (typedSnapshot.matches("idle") || typedSnapshot.matches("loading") || typedSnapshot.matches("prefilling")) return { status: "loading" };
|
|
47
|
-
if (typedSnapshot.matches("form"))
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
49
|
+
if (typedSnapshot.matches("form")) {
|
|
50
|
+
const steps = buildEkycSteps(context.fields, context.hideEmail);
|
|
51
|
+
const currentStepIndex = clampStepIndex(context.currentStepIndex, steps);
|
|
52
|
+
return {
|
|
53
|
+
status: "form",
|
|
54
|
+
fields: context.fields,
|
|
55
|
+
values: context.values,
|
|
56
|
+
validationErrors: context.validationErrors,
|
|
57
|
+
isValid: Object.keys(context.validationErrors ?? {}).length === 0,
|
|
58
|
+
addressSuggestions: context.addressSuggestions,
|
|
59
|
+
prefilled: context.prefilled,
|
|
60
|
+
hideEmail: context.hideEmail,
|
|
61
|
+
fieldsCountry: context.fieldsCountry,
|
|
62
|
+
submitError: context.submitError,
|
|
63
|
+
steps,
|
|
64
|
+
currentStepIndex,
|
|
65
|
+
isStepValid: isStepValid(steps[currentStepIndex], context.validationErrors)
|
|
66
|
+
};
|
|
67
|
+
}
|
|
59
68
|
if (typedSnapshot.matches("submitting")) return { status: "submitting" };
|
|
60
69
|
if (typedSnapshot.matches("success")) return { status: "success" };
|
|
61
70
|
if (typedSnapshot.matches("error")) return {
|
|
@@ -102,7 +111,21 @@ function createApi({ actor, trackElementClicked }) {
|
|
|
102
111
|
suggestion
|
|
103
112
|
});
|
|
104
113
|
},
|
|
105
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* Continues from the current step: validates its fields and moves to the
|
|
116
|
+
* next step when they pass. On the last step it submits, like `submit()`.
|
|
117
|
+
*/
|
|
118
|
+
next() {
|
|
119
|
+
actor.send({ type: "NEXT_STEP" });
|
|
120
|
+
},
|
|
121
|
+
/** Returns to the previous step. Keeps values and errors; does not validate. */
|
|
122
|
+
back() {
|
|
123
|
+
actor.send({ type: "PREVIOUS_STEP" });
|
|
124
|
+
},
|
|
125
|
+
/**
|
|
126
|
+
* Submits the form. Runs full-form validation whatever the current step;
|
|
127
|
+
* advances only when no errors, otherwise moves to the first step with one.
|
|
128
|
+
*/
|
|
106
129
|
submit() {
|
|
107
130
|
trackElementClicked?.("submit");
|
|
108
131
|
actor.send({ type: "SUBMIT" });
|