@incodetech/core 2.4.1 → 2.5.0-rc.0
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/BrowserNetworkStatusProvider-BrDXBEDd.esm.js +21 -0
- package/dist/{multipartRecordingService-CLwrF5wD.esm.js → CameraCompositor-ppyMYVoY.esm.js} +7 -744
- package/dist/DateFormattingProvider-DPq9zco-.esm.js +25 -0
- package/dist/{FaceDetectionProvider-J_-1Cwck.esm.js → FaceDetectionProvider-n9u4dEn_.esm.js} +28 -64
- package/dist/IBrowserEnvironmentCapability-D7JG7ML3.esm.js +16 -0
- package/dist/IGeolocationCapability-r49Qo7rR.d.ts +10 -0
- package/dist/{IIdCaptureCapability-CGcEt2Cw.d.ts → IIdCaptureCapability-C-5M8pP1.d.ts} +2 -2
- package/dist/{IWasmUtilCapability-GF2n7sfm.d.ts → IWasmUtilCapability-BRn0wz8v.d.ts} +33 -6
- package/dist/Manager-BvXAwDv9.esm.js +125 -0
- package/dist/{Manager-C9T5amUN.d.ts → Manager-DufwKlav.d.ts} +1 -7
- package/dist/MultipartRecordingProvider-CduV32Qa.esm.js +151 -0
- package/dist/{PhoneValidationProvider-SZiOS0jB.esm.js → PhoneValidationProvider-Co4zk2en.esm.js} +7 -0
- package/dist/{StreamCanvasCapture-7JRf-2ck.d.ts → StreamCanvasCapture-ixfy84ys.d.ts} +13 -4
- package/dist/StreamCanvasProcessingSession-CBnbTnOr.esm.js +42 -0
- package/dist/{WasmUtilProvider-DtJuBdt-.esm.js → WasmUtilProvider-0xTxgP0R.esm.js} +114 -25
- package/dist/WorkerEncoderRecordingProvider-CsDED9UU.esm.js +80 -0
- package/dist/addressSearch-Rxm1K67A.esm.js +73 -0
- package/dist/{advanceableErrors-q_pfU3Cn.esm.js → advanceableErrors-CxZyPRyh.esm.js} +4 -2
- 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-CaweCYnY.esm.js → antifraudManager-DKNOi9-z.esm.js} +5 -3
- package/dist/{antifraudStateMachine-DRl0UVyA.esm.js → antifraudStateMachine-BJ6PmCsw.esm.js} +3 -3
- package/dist/{api-Cz90EHyu.esm.js → api-CZpuJuZl.esm.js} +11 -6
- package/dist/{apiError-9Yi8xMeB.esm.js → apiError-CtArBUt-.esm.js} +1 -1
- package/dist/attemptCarry-BecGGZK8.esm.js +45 -0
- package/dist/authentication.d.ts +3 -3
- package/dist/authentication.esm.js +2 -2
- package/dist/{authenticationManager-pKQS4fHT.esm.js → authenticationManager-9N3eg3Uh.esm.js} +7 -6
- package/dist/{authenticationManager-BIZC55Bi.d.ts → authenticationManager-DRaugLgH.d.ts} +2 -2
- package/dist/{authenticationStateMachine-D_DygKtQ.esm.js → authenticationStateMachine-DoK5RKIS.esm.js} +50 -18
- package/dist/avatar.d.ts +1 -1
- package/dist/backCameraLabel-yda5ugE4.esm.js +67 -0
- package/dist/{backCameraStream-CMvXj4X4.esm.js → backCameraStream-DS1oDiUq.esm.js} +12 -107
- package/dist/{callback-645_omgz.d.ts → callback-BmjJ1G-5.d.ts} +1 -1
- package/dist/{camera-sIa9ceW2.esm.js → camera-E_Kcre4O.esm.js} +15 -23
- package/dist/camera.d.ts +2 -2
- 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-BfeMv2PU.esm.js → certificateIssuanceManager-DaUklfNj.esm.js} +5 -3
- package/dist/{certificateIssuanceStateMachine-Frgjbjw8.esm.js → certificateIssuanceStateMachine-_EQcjGE3.esm.js} +4 -4
- package/dist/cnpj-Bl_olpdX.esm.js +79 -0
- package/dist/connectivity-BCuEoQ-n.esm.js +114 -0
- package/dist/consent.d.ts +1 -1
- package/dist/consent.esm.js +2 -2
- package/dist/{consentManager-CvEu8h_W.esm.js → consentManager-BPocwpm2.esm.js} +7 -4
- package/dist/{consentManager-Ca8FHlC4.d.ts → consentManager-vI6QHkHU.d.ts} +16 -8
- package/dist/{consentStateMachine-DJTgN_-1.esm.js → consentStateMachine-DgiIcT9q.esm.js} +22 -9
- 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-Cu141CE8.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-B-z9q5V3.esm.js → curpValidationManager-CbvBDoE1.esm.js} +6 -3
- package/dist/{curpValidationManager-C9sqoh9n.d.ts → curpValidationManager-Ci2iVuog.d.ts} +4 -4
- package/dist/{curpValidationStateMachine-vDEFLMPw.esm.js → curpValidationStateMachine-BQ8XK2Y3.esm.js} +30 -22
- 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-D1ex2cFM.esm.js → customFieldsManager-BRqSCR9R.esm.js} +6 -4
- package/dist/{customFieldsManager-CF-cO8ap.d.ts → customFieldsManager-CdWTbsew.d.ts} +3 -3
- package/dist/{customWatchlistManager-CTI-SGk0.esm.js → customWatchlistManager-Bd1ooIDB.esm.js} +5 -3
- package/dist/{customWatchlistManager-DolUswyR.d.ts → customWatchlistManager-lJrveDS4.d.ts} +3 -3
- package/dist/{customWatchlistStateMachine-hmRd0f2I.esm.js → customWatchlistStateMachine-r8nGhyo1.esm.js} +3 -3
- package/dist/{deepsightService-C3DVBOZd.esm.js → deepsightLoader-zG373VVx.esm.js} +39 -69
- package/dist/definitionSource-Nw0YCbpe.esm.js +221 -0
- package/dist/{createCameraCycleOwnership-Dj_LHUvN.esm.js → desktopCameraElection-BKFjsQpO.esm.js} +178 -41
- package/dist/device.esm.js +2 -2
- package/dist/document-capture.d.ts +3 -3
- package/dist/document-capture.esm.js +2 -2
- package/dist/{documentCaptureManager-DUJwpKC5.esm.js → documentCaptureManager-BKaJVQxg.esm.js} +30 -20
- package/dist/{documentCaptureManager-DkyDtm3Y.d.ts → documentCaptureManager-CoGcEiMK.d.ts} +42 -8
- package/dist/{documentCaptureStateMachine-B8i7GnLh.esm.js → documentCaptureStateMachine-BYLb5Azk.esm.js} +107 -58
- package/dist/dynamic-forms.d.ts +2 -2
- package/dist/dynamic-forms.esm.js +2 -2
- package/dist/{dynamicFormsManager-DK_oc5Oy.esm.js → dynamicFormsManager-BfQKWG7a.esm.js} +5 -3
- package/dist/{dynamicFormsManager-C0dHs1ty.d.ts → dynamicFormsManager-C45pTncO.d.ts} +4 -4
- package/dist/{dynamicFormsStateMachine-CGlIAWZ6.esm.js → dynamicFormsStateMachine-CRq01QNK.esm.js} +4 -4
- package/dist/ekyb.d.ts +5 -5
- package/dist/ekyb.esm.js +3 -3
- package/dist/{ekybManager-BLgkiWXw.esm.js → ekybManager-B489iXyO.esm.js} +5 -3
- package/dist/{ekybManager-BaZ_7CEu.d.ts → ekybManager-BflWuTe4.d.ts} +5 -5
- package/dist/{ekybStateMachine-BfgOUZMK.esm.js → ekybStateMachine-DZxg8T0H.esm.js} +40 -56
- package/dist/ekybUtils-Cw8Ta9Qi.esm.js +140 -0
- package/dist/ekyc-prefill.d.ts +17 -0
- package/dist/ekyc-prefill.esm.js +3 -0
- package/dist/ekyc.d.ts +4 -3
- package/dist/ekyc.esm.js +3 -3
- package/dist/{ekycManager-DW-ynodd.d.ts → ekycManager-BKVQazAb.d.ts} +49 -7
- package/dist/{ekycManager-BO-Lui3t.esm.js → ekycManager-nRT0rxei.esm.js} +39 -16
- package/dist/ekycPrefillManager-BXWDF7vT.esm.js +103 -0
- package/dist/ekycPrefillManager-DOTl3Y2w.d.ts +566 -0
- package/dist/ekycPrefillStateMachine-CuWTVze1.esm.js +687 -0
- package/dist/ekycRules-DXP2hqVw.esm.js +479 -0
- package/dist/ekycStateMachine-nwJRel2s.esm.js +7897 -0
- package/dist/ekycUtils-FcqA6oU4.esm.js +1491 -0
- 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-CjKvJ6E-.esm.js → electronicSignatureManager-BcE0XMrN.esm.js} +8 -6
- package/dist/email.d.ts +1 -1
- package/dist/email.esm.js +2 -2
- package/dist/{emailManager-ButFktRm.esm.js → emailManager-Co4jarT1.esm.js} +5 -3
- package/dist/{emailManager-Dy6omJVp.d.ts → emailManager-pM7ZPuMa.d.ts} +3 -3
- package/dist/{emailStateMachine-BXtlC0NV.esm.js → emailStateMachine-CTEaYncs.esm.js} +34 -22
- 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 -41
- package/dist/extensibility.esm.js +39 -37
- package/dist/{externalFetch-DrR9xshk.esm.js → externalFetch-CQY41QT1.esm.js} +4 -1
- package/dist/face-match.d.ts +1 -1
- package/dist/face-match.esm.js +2 -2
- package/dist/{faceCaptureManagerFactory-BDGhg24q.esm.js → faceCaptureManagerFactory-BBQzNrku.esm.js} +17 -6
- package/dist/{faceCaptureManagerFactory-1hzeS_rB.d.ts → faceCaptureManagerFactory-CRGajjZ4.d.ts} +84 -72
- package/dist/{faceCaptureSetup-CvGYG4GZ.esm.js → faceCaptureSetup-D8_ilXFc.esm.js} +117 -482
- package/dist/{faceMatchManager-DIgG-UFS.d.ts → faceMatchManager-C5b5WtcY.d.ts} +23 -7
- package/dist/{faceMatchManager-DWFUQjMQ.esm.js → faceMatchManager-CGmNGbov.esm.js} +5 -3
- package/dist/{faceMatchStateMachine-CUCvlydD.esm.js → faceMatchStateMachine-BuHt7kec.esm.js} +68 -29
- package/dist/{feature-management-D4ne_hXW.esm.js → feature-management-SIBmKJs8.esm.js} +35 -21
- 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-v3knTYV_.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-Dt9fHG7h.esm.js → fiscalQrManager-DOLq45ph.esm.js} +8 -6
- package/dist/flow-events.d.ts +1 -1
- package/dist/flow.d.ts +75 -24
- package/dist/flow.esm.js +288 -70
- package/dist/{flowCompletionService-Cemwaa5b.esm.js → flowCompletionService-BFCddN3G.esm.js} +24 -3
- package/dist/{flowServices-X6Rwf_7E.esm.js → flowServices-NX4ksmS5.esm.js} +447 -183
- package/dist/geolocation.d.ts +1 -1
- package/dist/geolocation.esm.js +2 -2
- package/dist/{geolocationManager-Dn24g1fl.d.ts → geolocationManager-CENrvxpK.d.ts} +19 -20
- package/dist/{geolocationManager-B0dc5rW9.esm.js → geolocationManager-D1Ga7_lB.esm.js} +9 -9
- package/dist/{geolocationStateMachine-B3rcoODF.esm.js → geolocationStateMachine-oPgI5FIQ.esm.js} +14 -10
- package/dist/{getDeviceClass-bsWdEDxP.esm.js → getDeviceClass-DoIWuKI8.esm.js} +1 -1
- package/dist/government-validation.d.ts +1 -1
- package/dist/government-validation.esm.js +2 -2
- package/dist/{governmentValidationManager-BtXWHICu.esm.js → governmentValidationManager-6JQQkzha.esm.js} +5 -3
- package/dist/{governmentValidationManager-B82zOut8.d.ts → governmentValidationManager-De_vU7bm.d.ts} +4 -4
- package/dist/{governmentValidationStateMachine-COL-Vs48.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 +13 -11
- package/dist/id-verification.d.ts +1 -1
- package/dist/id-verification.esm.js +2 -2
- package/dist/id.d.ts +4 -17
- package/dist/id.esm.js +4 -4
- package/dist/{idCaptureDefaults-BGsG2OAs.esm.js → idCaptureDefaults-Drh207VJ.esm.js} +3 -3
- package/dist/{idCaptureManager-0M02hSuC.d.ts → idCaptureManager-Cqx2y_fC.d.ts} +76 -12
- package/dist/{idCaptureManager-IouAnrFm.esm.js → idCaptureManager-DjZyIbxc.esm.js} +68 -19
- package/dist/{idCaptureServices-VTKIPSpT.esm.js → idCaptureServices-DWs9Fb58.esm.js} +29 -198
- package/dist/{idCaptureStateMachine-_Pn2Xkpb.esm.js → idCaptureStateMachine-BGMkWF9t.esm.js} +961 -553
- package/dist/idOcrCpfUtils-D5Gwskxu.esm.js +18 -0
- package/dist/{idOcrManager-DT3kPIB3.d.ts → idOcrManager-DflRx-_u.d.ts} +6 -5
- package/dist/{idOcrManager-D3-HNMXP.esm.js → idOcrManager-im7VfJQi.esm.js} +5 -3
- package/dist/{idOcrStateMachine-DyENX6Ki.esm.js → idOcrStateMachine-B832arAl.esm.js} +11 -10
- package/dist/{idVerificationManager-BJapZfpy.d.ts → idVerificationManager-B6R8xNZq.d.ts} +4 -3
- package/dist/{idVerificationManager-iWz7Avkr.esm.js → idVerificationManager-PMGM4hXY.esm.js} +5 -3
- package/dist/{idVerificationStateMachine-CL1kUdBe.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-C40ngKeM.d.ts} +86 -19
- package/dist/{identityReuseManager-CD1ucp1d.esm.js → identityReuseManager-CjFZ7WRa.esm.js} +9 -4
- package/dist/{identityReuseStateMachine-DfV81wQC.esm.js → identityReuseStateMachine-CLFjPp13.esm.js} +22 -25
- package/dist/index-DHuAkTe0.d.ts +1 -0
- package/dist/{index-CKQ9QBZP.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-DYrkOXO6.esm.js → invokeOnCaptureCallback-lXP41N7b.esm.js} +1 -1
- package/dist/kyb-checks.d.ts +3 -0
- package/dist/kyb-checks.esm.js +3 -0
- package/dist/kybChecksManager-B7Di9auB.d.ts +95 -0
- package/dist/kybChecksManager-eRU3ht0m.esm.js +90 -0
- package/dist/kybChecksStateMachine-CU0oIYDR.esm.js +720 -0
- package/dist/mandatory-consent.d.ts +2 -2
- package/dist/mandatory-consent.esm.js +2 -2
- package/dist/{mandatoryConsentManager-qYojnZYg.d.ts → mandatoryConsentManager-C1B2ERZk.d.ts} +28 -11
- package/dist/{mandatoryConsentManager-Cwqx1nK7.esm.js → mandatoryConsentManager-Dh3pBhOe.esm.js} +7 -4
- package/dist/{mandatoryConsentStateMachine-pXWqAHo_.esm.js → mandatoryConsentStateMachine-BjuI72HZ.esm.js} +32 -13
- package/dist/mediaRecorderOptions-g1TwTlhd.esm.js +87 -0
- package/dist/multipartRecordingService-WgK8ieRI.esm.js +407 -0
- package/dist/{permissionGuards-gcy3U0SL.esm.js → permissionGuards-pcrrqrPR.esm.js} +1 -1
- package/dist/{permissionServices-Ca-tSNhT.esm.js → permissionServices-DFJlH7K3.esm.js} +11 -9
- package/dist/phone-number.d.ts +7 -1
- package/dist/phone-number.esm.js +15 -2
- 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-BO-LTih5.d.ts → phoneManager-VO1HEoUZ.d.ts} +8 -3
- package/dist/{phoneManager-KKUq-Vgo.esm.js → phoneManager-rA7updqF.esm.js} +6 -4
- package/dist/phoneServices-CFXcwCFr.esm.js +77 -0
- package/dist/{phoneStateMachine-D2QWS2cu.esm.js → phoneStateMachine-DKdY2Scx.esm.js} +56 -84
- package/dist/{phoneValidation-DnBcNUNh.esm.js → phoneValidation-OggtfjRt.esm.js} +1 -2
- package/dist/{platform-DkcRc9JV.esm.js → platform-aPh7gTWh.esm.js} +15 -1
- package/dist/processFaceMatch-B_DkDTE5.esm.js +21 -0
- package/dist/qe-signature.d.ts +2 -2
- package/dist/qe-signature.esm.js +1 -1
- package/dist/recordingService-DxiwS8TV.esm.js +397 -0
- package/dist/redirect-to-mobile.d.ts +2 -2
- package/dist/redirect-to-mobile.esm.js +2 -2
- package/dist/{redirectToMobileManager-uHW3dyuQ.esm.js → redirectToMobileManager-DjsEtWLq.esm.js} +9 -6
- package/dist/{redirectToMobileManager-CVsvpVbQ.d.ts → redirectToMobileManager-pT6FiPE7.d.ts} +6 -4
- package/dist/{redirectToMobileStateMachine-b-H-ipGM.esm.js → redirectToMobileStateMachine-CMjjUXSu.esm.js} +67 -28
- package/dist/resolveForm-DaaQSVWp.esm.js +146 -0
- package/dist/{runChildModule-DSpP41Hl.esm.js → runChildModule-CJ_aQO92.esm.js} +9 -7
- package/dist/{sdkVersion-DKHwWEyH.esm.js → sdkVersion-C9kbIDeX.esm.js} +1 -1
- package/dist/selfie.d.ts +4 -4
- package/dist/selfie.esm.js +13 -12
- package/dist/{selfieErrorUtils-DoN1KFSQ.esm.js → selfieErrorUtils-DUokfsv4.esm.js} +1 -1
- package/dist/{selfieManager-BJdNu_nd.d.ts → selfieManager-DihwheJ6.d.ts} +2 -2
- package/dist/{selfieManager-DtQegA6T.esm.js → selfieManager-uJtbzEp9.esm.js} +7 -6
- package/dist/{selfieStateMachine-CnCwJZuC.esm.js → selfieStateMachine-CKXAmNkA.esm.js} +5 -5
- package/dist/{session-CNUfjlRc.esm.js → session-Bk2K8TEv.esm.js} +77 -9
- package/dist/session.d.ts +96 -10
- package/dist/session.esm.js +7 -6
- package/dist/{sessionInitializer-JM_glXR2.esm.js → sessionInitializer-CUCBGZ_s.esm.js} +359 -115
- package/dist/{setup-C5tfWt6W.esm.js → setup-B3a5KQeI.esm.js} +36 -27
- package/dist/{setup-YPKTUCY5.d.ts → setup-DpOr8H_l.d.ts} +2 -2
- package/dist/signature.d.ts +1 -1
- package/dist/signature.esm.js +2 -2
- package/dist/{signatureManager-f_dPAGXn.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-C-nUq_oq.esm.js → signatureStateMachine-CVPmvU2p.esm.js} +3 -3
- package/dist/{spawn-D9jgw9pW.d.ts → spawn-COZKetCS.d.ts} +1 -1
- package/dist/{stats-BEvexnKC.esm.js → stats-DoByUnTa.esm.js} +1 -1
- package/dist/stats.esm.js +1 -1
- package/dist/textRules-D4NRinKY.d.ts +41 -0
- package/dist/{trueSightService-fLmL_cyg.esm.js → trueSightService-BnQDjqUu.esm.js} +22 -10
- package/dist/trust-graph.d.ts +4 -3
- package/dist/trust-graph.esm.js +5 -3
- package/dist/{types-yPH8lAH-.d.ts → types-9wlf1-GE.d.ts} +3 -3
- package/dist/types-B-PIc0en.d.ts +115 -0
- package/dist/types-B9C8W01q.d.ts +34 -0
- package/dist/{types-0L-eFDmr.d.ts → types-BgRHw-dR.d.ts} +1 -1
- 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-CTaL0XJz.d.ts +80 -0
- package/dist/{types-BAxn7MpY.d.ts → types-Cpdum4vi.d.ts} +125 -50
- package/dist/{types-DUnFZ08M.d.ts → types-CyNndVAT.d.ts} +16 -8
- package/dist/types-DEa3taWc.d.ts +217 -0
- package/dist/{types-CK8Jbjkp.d.ts → types-DFP7eSle.d.ts} +1 -1
- package/dist/{types-Ckir_BEs.d.ts → types-DJPU3W2M.d.ts} +3 -2
- package/dist/{types-DPIDuhut.d.ts → types-DNVzoRvi.d.ts} +2 -1
- package/dist/{events-Du2A4-Qr.esm.js → types-DYYMdAGv.esm.js} +4 -299
- package/dist/{types-B6HsSzpk.d.ts → types-Ddc4Tr_f.d.ts} +42 -6
- package/dist/{urlUtils-6jsE6rKp.esm.js → urlUtils-eYiyWjh0.esm.js} +4 -1
- package/dist/usStates-CwOQ2kAx.esm.js +209 -0
- package/dist/video-selfie.d.ts +16 -14
- package/dist/video-selfie.esm.js +100 -24
- package/dist/{videoSelfieCameraWarmer-BBNKiau1.esm.js → videoSelfieCameraWarmer-CgqaNI-W.esm.js} +26 -27
- package/dist/{videoSelfieFlowModuleMachine-BCFVHBQ1.esm.js → videoSelfieFlowModuleMachine-IWdxw1TW.esm.js} +1 -1
- package/dist/{videoSelfieStepDetector-CGsTltqB.d.ts → videoSelfieStepDetector-DRrh4P0A.d.ts} +10 -5
- package/dist/virtualCameraCheck-eFOm2C9q.esm.js +27 -0
- package/dist/{warmup-BO57syF6.d.ts → warmup-BNhIuURi.d.ts} +18 -2
- package/dist/{warmup-BElYWRh7.esm.js → warmup-BZOMg303.esm.js} +243 -30
- package/dist/wasm.d.ts +9 -3
- package/dist/wasm.esm.js +3 -3
- package/dist/{wasmDsFlagSync-CYj5LL9z.esm.js → wasmDsFlagSync-DPK7qGgo.esm.js} +1 -1
- package/dist/wasmMetadataVersionSync-U8EFUr1T.esm.js +27 -0
- package/dist/{wasmWebClient-BjZw_7OB.esm.js → wasmWebClient-CyLCM31e.esm.js} +45 -26
- package/dist/watchlist-for-business.d.ts +2 -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-CZZOFkGl.esm.js → watchlistForBusinessManager-BH6M4kqA.esm.js} +40 -8
- package/dist/{watchlistForBusinessManager-B3GDPZrr.d.ts → watchlistForBusinessManager-l7ZERQcV.d.ts} +57 -21
- package/dist/watchlistForBusinessStateMachine-BMWm5mcP.esm.js +166 -0
- package/dist/{watchlistManager-DXtX94SN.esm.js → watchlistManager-BDaVjzLW.esm.js} +5 -3
- package/dist/{watchlistManager-DJQOd8Pw.d.ts → watchlistManager-DQq4GxBO.d.ts} +3 -3
- package/dist/{watchlistStateMachine-McALifag.esm.js → watchlistStateMachine-Cx-6QAvu.esm.js} +3 -3
- package/dist/workflow.d.ts +234 -45
- package/dist/workflow.esm.js +194 -80
- 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 +22 -5
- package/dist/Actor-DpTj5PFb.d.ts +0 -1
- package/dist/IBrowserEnvironmentCapability-DEaRRk-R.esm.js +0 -9
- package/dist/addressSearch-DPjIKJrX.esm.js +0 -563
- package/dist/cpf-uAZTPUBy.esm.js +0 -61
- package/dist/deepsightLoader-sH7920zw.esm.js +0 -55
- package/dist/ekycStateMachine-CDnI_NRq.esm.js +0 -1443
- package/dist/ekycUtils-zY8CdKJL.esm.js +0 -300
- package/dist/index-DpTj5PFb.d.ts +0 -1
- package/dist/types-BvLo3U4u.d.ts +0 -134
- package/dist/types-zOgZqMni.d.ts +0 -6
- package/dist/watchlistForBusinessStateMachine-B66E7jud.esm.js +0 -78
- /package/dist/{types-BSBzhHRH2.d.ts → types-BSBzhHRH.d.ts} +0 -0
|
@@ -1,59 +1,10 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-Cz90EHyu.esm.js";
|
|
2
1
|
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
3
|
-
import {
|
|
4
|
-
import { n as
|
|
5
|
-
import {
|
|
2
|
+
import { n as loadPhoneValidation } from "./phoneValidation-OggtfjRt.esm.js";
|
|
3
|
+
import { i as fetchStartInfo, n as addPhoneInstantVerify, o as sendOtp, r as fetchPhone, s as verifyOtp, t as addPhone } from "./phoneServices-CFXcwCFr.esm.js";
|
|
4
|
+
import { i as assign, t as setup } from "./xstate.esm-CIqUf_i6.esm.js";
|
|
5
|
+
import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-BCcwgosu.esm.js";
|
|
6
|
+
import { t as carryAttempts } from "./attemptCarry-BecGGZK8.esm.js";
|
|
6
7
|
import { n as isOtpComplete, t as computeOtpValidationErrors } from "./otp-D2k3PeSL.esm.js";
|
|
7
|
-
//#region src/modules/phone/phoneServices.ts
|
|
8
|
-
function getPhoneServerFailureReason(error, invalidStatus) {
|
|
9
|
-
if (error.status === invalidStatus) return "invalidPhone";
|
|
10
|
-
return "serverError";
|
|
11
|
-
}
|
|
12
|
-
async function fetchPhone(signal) {
|
|
13
|
-
const res = await api.get(endpoints.getPhone, { signal });
|
|
14
|
-
if (!res.ok) throw new Error(`GET ${endpoints.getPhone} failed: ${res.status} ${res.statusText}`);
|
|
15
|
-
return res.data;
|
|
16
|
-
}
|
|
17
|
-
async function fetchStartInfo(signal) {
|
|
18
|
-
const res = await api.get(endpoints.startInfo, { signal });
|
|
19
|
-
if (!res.ok) throw new Error(`GET ${endpoints.startInfo} failed: ${res.status} ${res.statusText}`);
|
|
20
|
-
return res.data;
|
|
21
|
-
}
|
|
22
|
-
async function addPhone(params, signal) {
|
|
23
|
-
try {
|
|
24
|
-
return (await api.post(endpoints.phone, {
|
|
25
|
-
phone: params.phone,
|
|
26
|
-
optInGranted: params.optInGranted
|
|
27
|
-
}, { signal })).data;
|
|
28
|
-
} catch (error) {
|
|
29
|
-
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
async function addPhoneInstantVerify(params, signal) {
|
|
33
|
-
try {
|
|
34
|
-
return (await api.post(endpoints.phoneInstant, {
|
|
35
|
-
phone: params.phone,
|
|
36
|
-
optInGranted: params.optInGranted
|
|
37
|
-
}, { signal })).data;
|
|
38
|
-
} catch (error) {
|
|
39
|
-
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
async function sendOtp(signal) {
|
|
43
|
-
try {
|
|
44
|
-
await api.get(`${endpoints.sendSmsOtp}?communicationchannel=SMS`, { signal });
|
|
45
|
-
} catch (error) {
|
|
46
|
-
throw new Error(getPhoneServerFailureReason(error));
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
async function verifyOtp(code, signal) {
|
|
50
|
-
try {
|
|
51
|
-
return (await api.get(`${endpoints.compareOtp}?code=${code}&channel=SMS`, { signal })).data;
|
|
52
|
-
} catch (error) {
|
|
53
|
-
throw new Error(getPhoneServerFailureReason(error));
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
//#endregion
|
|
57
8
|
//#region src/modules/phone/phoneStateMachine.ts
|
|
58
9
|
const RESEND_TIMER_SECONDS = 30;
|
|
59
10
|
function getErrorMessage(error) {
|
|
@@ -148,6 +99,7 @@ const phoneMachine = setup({
|
|
|
148
99
|
setOptInGranted: assign(({ event }) => ({ optInGranted: event.granted })),
|
|
149
100
|
setError: assign(({ event }) => ({ error: getErrorMessage(event.error) })),
|
|
150
101
|
clearError: assign({ error: () => void 0 }),
|
|
102
|
+
settleLoad: assign({ pendingLoads: ({ context }) => context.pendingLoads - 1 }),
|
|
151
103
|
clearPhoneError: assign({ phoneError: () => void 0 }),
|
|
152
104
|
setOtpCode: assign(({ event }) => ({
|
|
153
105
|
otpCode: event.code,
|
|
@@ -190,6 +142,7 @@ const phoneMachine = setup({
|
|
|
190
142
|
prefilledPhone: void 0,
|
|
191
143
|
optInGranted: false,
|
|
192
144
|
startInfo: void 0,
|
|
145
|
+
pendingLoads: 0,
|
|
193
146
|
error: void 0,
|
|
194
147
|
otpCode: "",
|
|
195
148
|
otpError: void 0,
|
|
@@ -201,6 +154,7 @@ const phoneMachine = setup({
|
|
|
201
154
|
},
|
|
202
155
|
guards: {
|
|
203
156
|
hasPrefill: ({ context }) => context.config.prefill,
|
|
157
|
+
areLoadsSettled: ({ context }) => context.pendingLoads === 0,
|
|
204
158
|
hasOtpVerification: ({ context }) => context.config.otpVerification,
|
|
205
159
|
hasNoValidationErrors: ({ context }) => !context.validationErrors || Object.keys(context.validationErrors).length === 0,
|
|
206
160
|
hasAttemptsRemaining: ({ context }) => context.attemptsRemaining > 1,
|
|
@@ -210,40 +164,58 @@ const phoneMachine = setup({
|
|
|
210
164
|
}).createMachine({
|
|
211
165
|
id: "phone",
|
|
212
166
|
initial: "idle",
|
|
213
|
-
context: ({ input }) =>
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
167
|
+
context: ({ input, self }) => {
|
|
168
|
+
const carried = carryAttempts("phone", self, (s) => ({ attemptsRemaining: s.matches("error") ? s.context.attemptsRemaining - 1 : s.context.attemptsRemaining }));
|
|
169
|
+
return {
|
|
170
|
+
config: input.config,
|
|
171
|
+
phone: "",
|
|
172
|
+
isValid: false,
|
|
173
|
+
phoneError: void 0,
|
|
174
|
+
validationErrors: void 0,
|
|
175
|
+
countryCode: "",
|
|
176
|
+
phonePrefix: "",
|
|
177
|
+
prefilledPhone: void 0,
|
|
178
|
+
optInGranted: false,
|
|
179
|
+
startInfo: void 0,
|
|
180
|
+
pendingLoads: 0,
|
|
181
|
+
error: void 0,
|
|
182
|
+
otpCode: "",
|
|
183
|
+
otpError: void 0,
|
|
184
|
+
otpValidationErrors: void 0,
|
|
185
|
+
attemptsRemaining: carried.attemptsRemaining ?? input.config.maxOtpAttempts ?? 3,
|
|
186
|
+
resendTimer: 0,
|
|
187
|
+
resendTimerActive: false
|
|
188
|
+
};
|
|
189
|
+
},
|
|
232
190
|
states: {
|
|
233
|
-
idle: { on: { LOAD: [
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
191
|
+
idle: { on: { LOAD: [
|
|
192
|
+
{
|
|
193
|
+
target: "error",
|
|
194
|
+
guard: ({ context }) => context.attemptsRemaining <= 0 && context.attemptsRemaining < (context.config.maxOtpAttempts ?? 3),
|
|
195
|
+
actions: assign({ error: () => "Maximum OTP attempts exceeded" })
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
target: "loadingPrefill",
|
|
199
|
+
guard: "hasPrefill"
|
|
200
|
+
},
|
|
201
|
+
{ target: "loadingStartInfo" }
|
|
202
|
+
] } },
|
|
237
203
|
loadingPrefill: {
|
|
238
|
-
entry: "startLoadingPhoneRules",
|
|
239
|
-
invoke: {
|
|
204
|
+
entry: ["startLoadingPhoneRules", assign({ pendingLoads: () => 2 })],
|
|
205
|
+
invoke: [{
|
|
240
206
|
id: "fetchPhone",
|
|
241
207
|
src: "fetchPhone",
|
|
242
|
-
onDone: {
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
208
|
+
onDone: { actions: ["setPrefilledPhone", "settleLoad"] },
|
|
209
|
+
onError: { actions: "settleLoad" }
|
|
210
|
+
}, {
|
|
211
|
+
id: "fetchStartInfo",
|
|
212
|
+
src: "fetchStartInfo",
|
|
213
|
+
onDone: { actions: ["setStartInfo", "settleLoad"] },
|
|
214
|
+
onError: { actions: "settleLoad" }
|
|
215
|
+
}],
|
|
216
|
+
always: {
|
|
217
|
+
target: "loadingPhoneRules",
|
|
218
|
+
guard: "areLoadsSettled"
|
|
247
219
|
}
|
|
248
220
|
},
|
|
249
221
|
loadingStartInfo: {
|
|
@@ -18,8 +18,7 @@ const LAZY_IMPORT_OPTIONS = {
|
|
|
18
18
|
var LazyPhoneValidationProvider = class LazyPhoneValidationProvider {
|
|
19
19
|
constructor() {
|
|
20
20
|
this._lazy = BrowserLazyImportProvider.getInstance().create(async () => {
|
|
21
|
-
|
|
22
|
-
return new PhoneValidationProvider();
|
|
21
|
+
return new (await (import("./PhoneValidationProvider-Co4zk2en.esm.js").then((n) => n.n))).PhoneValidationProvider();
|
|
23
22
|
}, LAZY_IMPORT_OPTIONS);
|
|
24
23
|
}
|
|
25
24
|
static getInstance() {
|
|
@@ -16,6 +16,20 @@ function isAndroid(userAgent) {
|
|
|
16
16
|
return /Android/i.test(ua);
|
|
17
17
|
}
|
|
18
18
|
/**
|
|
19
|
+
* True on a Samsung Android device, as far as the user agent tells.
|
|
20
|
+
*
|
|
21
|
+
* Two signals: Samsung Internet stamps `SamsungBrowser/<n>`, and unreduced
|
|
22
|
+
* user agents (WebViews, older Chrome) carry the `SAMSUNG` / `SM-<model>`
|
|
23
|
+
* device token. Chrome 110+ reduces the Android model to `K`, so Chrome on a
|
|
24
|
+
* Samsung phone is NOT detected — callers gating a Samsung-only feature on
|
|
25
|
+
* this err on the side of hiding it.
|
|
26
|
+
*/
|
|
27
|
+
function isSamsungDevice(userAgent) {
|
|
28
|
+
const ua = userAgent || (typeof navigator !== "undefined" ? navigator.userAgent : "");
|
|
29
|
+
if (!isAndroid(ua)) return false;
|
|
30
|
+
return /SamsungBrowser\/|\bSAMSUNG\b|\bSM-[A-Z0-9]+/i.test(ua);
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
19
33
|
* True when the page runs inside an Android WebView — web content hosted by a
|
|
20
34
|
* native app — rather than a standalone Android browser.
|
|
21
35
|
*
|
|
@@ -128,4 +142,4 @@ function isIPhone14OrHigher() {
|
|
|
128
142
|
return IPHONE_14_PLUS_DIMENSIONS.some((dims) => dims.outerHeight === outerHeight && dims.outerWidth === outerWidth || dims.innerHeight === innerHeight && dims.innerWidth === innerWidth);
|
|
129
143
|
}
|
|
130
144
|
//#endregion
|
|
131
|
-
export { isIOS as a, isIPhone14OrHigher as c, isSafari as d,
|
|
145
|
+
export { isIOS as a, isIPhone14OrHigher as c, isSafari as d, isSamsungDevice as f, isDesktop as i, isIslandBrowser as l, isAndroidWebView as n, isIOSWebView as o, isTabletWithoutAndroid as p, isBraveBrowser as r, isIPad as s, isAndroid as t, isMacOsSafari as u };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { r as getToken } from "./api-CZpuJuZl.esm.js";
|
|
2
|
+
//#region src/internal/session/processFaceMatch.ts
|
|
3
|
+
let saved = null;
|
|
4
|
+
/**
|
|
5
|
+
* Saves the `success` field of a selfie `/omni/process/face` response, so a
|
|
6
|
+
* later face match in the same session shows it without a second call. A
|
|
7
|
+
* response without `success` clears the saved result.
|
|
8
|
+
*/
|
|
9
|
+
function saveProcessFaceMatch(success) {
|
|
10
|
+
const token = getToken();
|
|
11
|
+
saved = token !== null && typeof success === "boolean" ? {
|
|
12
|
+
token,
|
|
13
|
+
matched: success
|
|
14
|
+
} : null;
|
|
15
|
+
}
|
|
16
|
+
/** The saved face match result of the current session, or `null`. */
|
|
17
|
+
function getProcessFaceMatch() {
|
|
18
|
+
return saved !== null && saved.token === getToken() ? saved.matched : null;
|
|
19
|
+
}
|
|
20
|
+
//#endregion
|
|
21
|
+
export { saveProcessFaceMatch as n, getProcessFaceMatch as t };
|
package/dist/qe-signature.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as Manager } from "./Manager-
|
|
1
|
+
import { t as Manager } from "./Manager-DufwKlav.js";
|
|
2
2
|
import { S as getDefaultConsentChecks, a as ElectronicSignatureConfig, b as areAllConsented, f as NAMIRIAL_QES_CONSENT_KEYS, h as QE_CONSENT_KEYS, i as ConsentKey, m as NamirialQesConsentKey, p as NAMIRIAL_QES_PROVIDER_CODE, r as ConsentChecks, s as ElectronicSignatureDocument, u as ElectronicSignatureProviderTerms } from "./types-D0gekt4U.js";
|
|
3
|
-
import { n as ElectronicSignatureState, o as electronicSignatureMachine } from "./electronicSignatureManager-
|
|
3
|
+
import { n as ElectronicSignatureState, o as electronicSignatureMachine } from "./electronicSignatureManager-5tYz-a4o.js";
|
|
4
4
|
import "./electronic-signature.js";
|
|
5
5
|
//#region src/modules/qe-signature/index.d.ts
|
|
6
6
|
type QeSignatureConfig = Omit<ElectronicSignatureConfig, 'variant'>;
|
package/dist/qe-signature.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as NAMIRIAL_QES_CONSENT_KEYS, c as areAllConsented, o as NAMIRIAL_QES_PROVIDER_CODE, r as electronicSignatureMachine, s as QE_CONSENT_KEYS, t as createElectronicSignatureManager, u as getDefaultConsentChecks } from "./electronicSignatureManager-
|
|
1
|
+
import { a as NAMIRIAL_QES_CONSENT_KEYS, c as areAllConsented, o as NAMIRIAL_QES_PROVIDER_CODE, r as electronicSignatureMachine, s as QE_CONSENT_KEYS, t as createElectronicSignatureManager, u as getDefaultConsentChecks } from "./electronicSignatureManager-BcE0XMrN.esm.js";
|
|
2
2
|
//#region src/modules/qe-signature/index.ts
|
|
3
3
|
function createQeSignatureManager(options) {
|
|
4
4
|
return createElectronicSignatureManager({ config: {
|
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
import { t as api, u as endpoints } from "./api-CZpuJuZl.esm.js";
|
|
2
|
+
import { t as BrowserLazyImportProvider } from "./BrowserLazyImportProvider-BhoA957O.esm.js";
|
|
3
|
+
import { r as createRecordingCompositor } from "./CameraCompositor-ppyMYVoY.esm.js";
|
|
4
|
+
import { t as getAdaptiveMediaRecorderOptions } from "./mediaRecorderOptions-g1TwTlhd.esm.js";
|
|
5
|
+
import { t as WorkerEncoderRecordingProvider } from "./WorkerEncoderRecordingProvider-CsDED9UU.esm.js";
|
|
6
|
+
import { t as MultipartRecordingService } from "./multipartRecordingService-WgK8ieRI.esm.js";
|
|
7
|
+
//#region ../infra/src/media/VideoTrimmer.ts
|
|
8
|
+
/** A trim that runs longer than this uploads the full recording instead. */
|
|
9
|
+
const TRIM_TIMEOUT_MS = 1e4;
|
|
10
|
+
const trimmer = BrowserLazyImportProvider.getInstance().create(() => import("./videoTrimByCopy-BFfAiNpv.esm.js").then((module) => module.trimLastNSecondsByCopy), {
|
|
11
|
+
label: "Video liveness",
|
|
12
|
+
moduleName: "mediabunny",
|
|
13
|
+
timeoutMs: 1e4,
|
|
14
|
+
disabledMessage: "the full recording will be uploaded untrimmed."
|
|
15
|
+
});
|
|
16
|
+
/** Starts loading the trimmer, e.g. when a recording that will be trimmed starts. */
|
|
17
|
+
function preloadVideoTrimmer() {
|
|
18
|
+
trimmer.load();
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Keeps about the last `seconds` of a recording. Never rejects and never
|
|
22
|
+
* hangs: when the trimmer cannot load, fails, or takes longer than
|
|
23
|
+
* {@link TRIM_TIMEOUT_MS}, it resolves the untrimmed recording.
|
|
24
|
+
*/
|
|
25
|
+
async function trimLastNSeconds(videoBlob, seconds) {
|
|
26
|
+
const trim = await trimmer.load();
|
|
27
|
+
if (!trim) return videoBlob;
|
|
28
|
+
let timeout;
|
|
29
|
+
try {
|
|
30
|
+
return await Promise.race([trim(videoBlob, seconds), new Promise((resolve) => {
|
|
31
|
+
timeout = setTimeout(() => {
|
|
32
|
+
console.warn("[Video liveness] Trimming timed out; the full recording will be uploaded untrimmed.");
|
|
33
|
+
resolve(videoBlob);
|
|
34
|
+
}, TRIM_TIMEOUT_MS);
|
|
35
|
+
})]);
|
|
36
|
+
} catch (error) {
|
|
37
|
+
console.warn("[Video liveness] Trimming failed; the full recording will be uploaded untrimmed.", error);
|
|
38
|
+
return videoBlob;
|
|
39
|
+
} finally {
|
|
40
|
+
clearTimeout(timeout);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
//#endregion
|
|
44
|
+
//#region ../infra/src/providers/browser/LocalRecordingProvider.ts
|
|
45
|
+
function toBase64(videoBlob) {
|
|
46
|
+
return new Promise((resolve, reject) => {
|
|
47
|
+
const reader = new FileReader();
|
|
48
|
+
reader.onloadend = () => {
|
|
49
|
+
const base64 = reader.result.split(",")[1];
|
|
50
|
+
resolve(base64);
|
|
51
|
+
};
|
|
52
|
+
reader.onerror = () => reject(reader.error ?? /* @__PURE__ */ new Error("FileReader error"));
|
|
53
|
+
reader.readAsDataURL(videoBlob);
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
/** `MediaRecorderOptions.videoKeyFrameIntervalDuration`, see `startRecording`. */
|
|
57
|
+
const KEYFRAME_INTERVAL_MS = 1e3;
|
|
58
|
+
var LocalRecordingProvider = class {
|
|
59
|
+
constructor() {
|
|
60
|
+
this.mediaRecorder = null;
|
|
61
|
+
this._isRecording = false;
|
|
62
|
+
this._hasError = false;
|
|
63
|
+
this._error = null;
|
|
64
|
+
this.mimeType = "";
|
|
65
|
+
this.stream = null;
|
|
66
|
+
this.pauseRecordingBound = this.pauseRecording.bind(this);
|
|
67
|
+
}
|
|
68
|
+
get isRecording() {
|
|
69
|
+
return this._isRecording;
|
|
70
|
+
}
|
|
71
|
+
get hasError() {
|
|
72
|
+
return this._hasError;
|
|
73
|
+
}
|
|
74
|
+
get error() {
|
|
75
|
+
return this._error;
|
|
76
|
+
}
|
|
77
|
+
startRecording(stream) {
|
|
78
|
+
this.reset();
|
|
79
|
+
preloadVideoTrimmer();
|
|
80
|
+
this.registerEventListeners();
|
|
81
|
+
this.stream = stream;
|
|
82
|
+
try {
|
|
83
|
+
const options = getAdaptiveMediaRecorderOptions();
|
|
84
|
+
this.mimeType = options.mimeType;
|
|
85
|
+
const recorder = new MediaRecorder(stream.clone(), {
|
|
86
|
+
...options,
|
|
87
|
+
videoKeyFrameIntervalDuration: KEYFRAME_INTERVAL_MS
|
|
88
|
+
});
|
|
89
|
+
recorder.onerror = (event) => {
|
|
90
|
+
this._error = `Recording error: ${event}`;
|
|
91
|
+
this._isRecording = false;
|
|
92
|
+
this._hasError = true;
|
|
93
|
+
};
|
|
94
|
+
recorder.start();
|
|
95
|
+
this.mediaRecorder = recorder;
|
|
96
|
+
this._isRecording = true;
|
|
97
|
+
this._error = null;
|
|
98
|
+
this._hasError = false;
|
|
99
|
+
} catch (err) {
|
|
100
|
+
this._error = `Failed to start recording: ${err}`;
|
|
101
|
+
this._hasError = true;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
async stopRecording(trimSeconds, encrypt, generateChecksum) {
|
|
105
|
+
const recorder = this.mediaRecorder;
|
|
106
|
+
return new Promise((resolve, reject) => {
|
|
107
|
+
this.removeEventListeners();
|
|
108
|
+
if (recorder && this._isRecording) {
|
|
109
|
+
const chunks = [];
|
|
110
|
+
recorder.ondataavailable = (event) => {
|
|
111
|
+
if (event.data.size > 0) chunks.push(event.data);
|
|
112
|
+
};
|
|
113
|
+
recorder.onstop = async () => {
|
|
114
|
+
try {
|
|
115
|
+
const trimmedVideo = await trimLastNSeconds(new Blob(chunks, { type: this.mimeType }), trimSeconds);
|
|
116
|
+
const encryptedVideoBase64 = encrypt(await toBase64(trimmedVideo));
|
|
117
|
+
generateChecksum(await trimmedVideo.arrayBuffer());
|
|
118
|
+
this._isRecording = false;
|
|
119
|
+
resolve({
|
|
120
|
+
trimmedBlob: trimmedVideo,
|
|
121
|
+
encryptedVideo: encryptedVideoBase64
|
|
122
|
+
});
|
|
123
|
+
} catch (error) {
|
|
124
|
+
this._isRecording = false;
|
|
125
|
+
this._error = `Recording stop failed: ${error}`;
|
|
126
|
+
this._hasError = true;
|
|
127
|
+
reject(error);
|
|
128
|
+
}
|
|
129
|
+
};
|
|
130
|
+
recorder.stop();
|
|
131
|
+
this._isRecording = false;
|
|
132
|
+
} else resolve({
|
|
133
|
+
trimmedBlob: new Blob([], { type: this.mimeType }),
|
|
134
|
+
encryptedVideo: ""
|
|
135
|
+
});
|
|
136
|
+
recorder?.stream?.getTracks().forEach((track) => track.stop());
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Discards the in-progress recording without producing a result: detaches
|
|
141
|
+
* the recorder's handlers, stops it, releases its cloned tracks and clears
|
|
142
|
+
* the flags. Idempotent, and safe after `stopRecording` or when never
|
|
143
|
+
* started. Mirrors `MultipartRecordingProvider.reset()` so an attempt that is
|
|
144
|
+
* released before finalization cannot leave a live camera clone behind
|
|
145
|
+
* (ENG-56648).
|
|
146
|
+
*/
|
|
147
|
+
reset() {
|
|
148
|
+
this.removeEventListeners();
|
|
149
|
+
const recorder = this.mediaRecorder;
|
|
150
|
+
if (recorder) {
|
|
151
|
+
recorder.ondataavailable = null;
|
|
152
|
+
recorder.onerror = null;
|
|
153
|
+
recorder.onstop = null;
|
|
154
|
+
if (recorder.state !== "inactive") try {
|
|
155
|
+
recorder.stop();
|
|
156
|
+
} catch {}
|
|
157
|
+
recorder.stream?.getTracks().forEach((track) => track.stop());
|
|
158
|
+
this.mediaRecorder = null;
|
|
159
|
+
}
|
|
160
|
+
this.stream = null;
|
|
161
|
+
this._isRecording = false;
|
|
162
|
+
this._error = null;
|
|
163
|
+
this._hasError = false;
|
|
164
|
+
}
|
|
165
|
+
pauseRecording() {
|
|
166
|
+
if (!this._isRecording) return;
|
|
167
|
+
if (this.mediaRecorder?.state === "recording") try {
|
|
168
|
+
this.mediaRecorder.pause();
|
|
169
|
+
} catch {}
|
|
170
|
+
}
|
|
171
|
+
registerEventListeners() {
|
|
172
|
+
document.addEventListener("visibilitychange", this.pauseRecordingBound);
|
|
173
|
+
}
|
|
174
|
+
removeEventListeners() {
|
|
175
|
+
document.removeEventListener("visibilitychange", this.pauseRecordingBound);
|
|
176
|
+
}
|
|
177
|
+
};
|
|
178
|
+
//#endregion
|
|
179
|
+
//#region src/internal/recordings/recordingsRepository.ts
|
|
180
|
+
async function uploadDeepsightVideo(encryptedVideo, token) {
|
|
181
|
+
try {
|
|
182
|
+
return (await api.post(endpoints.deepsightVideoImport, {
|
|
183
|
+
video: encryptedVideo,
|
|
184
|
+
type: "selfie"
|
|
185
|
+
}, { headers: { "X-Incode-Hardware-Id": token } })).data.recordingId ?? "";
|
|
186
|
+
} catch {
|
|
187
|
+
return "";
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
//#endregion
|
|
191
|
+
//#region src/internal/faceCapture/recordingService.ts
|
|
192
|
+
/**
|
|
193
|
+
* Records on-device and uploads encrypted video for liveness.
|
|
194
|
+
*/
|
|
195
|
+
var LocalRecordingService = class {
|
|
196
|
+
constructor(wasmUtil, sessionToken) {
|
|
197
|
+
this.recorder = new LocalRecordingProvider();
|
|
198
|
+
this.sessionToken = sessionToken;
|
|
199
|
+
this.wasmUtil = wasmUtil;
|
|
200
|
+
}
|
|
201
|
+
async start(stream) {
|
|
202
|
+
this.recorder.startRecording(stream);
|
|
203
|
+
this.wasmUtil.osv();
|
|
204
|
+
}
|
|
205
|
+
async stop() {
|
|
206
|
+
if (!this.recorder.isRecording) return { recordingId: null };
|
|
207
|
+
this.wasmUtil.oev();
|
|
208
|
+
const result = await this.recorder.stopRecording(10, (base64) => this.wasmUtil.encryptImage(base64), (buffer) => this.wasmUtil.ckvcks(buffer));
|
|
209
|
+
if (!this.sessionToken) return { recordingId: null };
|
|
210
|
+
return { recordingId: await uploadDeepsightVideo(result.encryptedVideo, this.sessionToken) };
|
|
211
|
+
}
|
|
212
|
+
prepareUpload() {
|
|
213
|
+
return this.stop();
|
|
214
|
+
}
|
|
215
|
+
async stopAndGetVideo() {
|
|
216
|
+
if (!this.recorder.isRecording) return { videoBase64: void 0 };
|
|
217
|
+
try {
|
|
218
|
+
this.wasmUtil.oev();
|
|
219
|
+
const videoBase64 = (await this.recorder.stopRecording(10, (base64) => base64, () => {})).encryptedVideo;
|
|
220
|
+
return { videoBase64: videoBase64 ? videoBase64 : void 0 };
|
|
221
|
+
} catch {
|
|
222
|
+
return { videoBase64: void 0 };
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
cleanup() {
|
|
226
|
+
this.recorder.reset();
|
|
227
|
+
}
|
|
228
|
+
};
|
|
229
|
+
/**
|
|
230
|
+
* Records a regular Selfie capture locally and streams it through the scoped
|
|
231
|
+
* video-selfie-service multipart protocol. The recording is associated with
|
|
232
|
+
* the interview asynchronously by the backend's `selfie` scope consumer, so
|
|
233
|
+
* its upload id must not be forwarded to `/omni/add/face` as a legacy
|
|
234
|
+
* `recordingId`.
|
|
235
|
+
*
|
|
236
|
+
* The recording is scoped to the capture step (ENG-56648). The recorder
|
|
237
|
+
* records a stable `CameraCompositor` stream instead of a raw camera clone, so
|
|
238
|
+
* every attempt can end its own clone before PRC and POC run and the next
|
|
239
|
+
* attempt swaps a fresh clone into the same multipart upload. The owning
|
|
240
|
+
* controller completes the upload once the backend accepts a capture or the
|
|
241
|
+
* step ends without a retry.
|
|
242
|
+
*/
|
|
243
|
+
var MultipartFaceRecordingService = class {
|
|
244
|
+
constructor() {
|
|
245
|
+
this.recordingCompositor = createRecordingCompositor();
|
|
246
|
+
this.service = new MultipartRecordingService("selfie", new WorkerEncoderRecordingProvider(this.recordingCompositor));
|
|
247
|
+
this.audioSource = [];
|
|
248
|
+
this.needsVideoSourceReplacement = false;
|
|
249
|
+
this.pausedForAttempt = false;
|
|
250
|
+
this.startInFlight = false;
|
|
251
|
+
this.suspendRequested = false;
|
|
252
|
+
this.stopping = false;
|
|
253
|
+
}
|
|
254
|
+
async start(stream) {
|
|
255
|
+
if (this.stopping) throw new Error("Face recording already completed");
|
|
256
|
+
if (this.compositor) {
|
|
257
|
+
await this.resume(stream);
|
|
258
|
+
return;
|
|
259
|
+
}
|
|
260
|
+
const recordingSource = stream.clone();
|
|
261
|
+
const compositor = this.recordingCompositor;
|
|
262
|
+
this.startInFlight = true;
|
|
263
|
+
try {
|
|
264
|
+
const composite = compositor.start(recordingSource);
|
|
265
|
+
await this.service.start(composite);
|
|
266
|
+
} catch (error) {
|
|
267
|
+
compositor.stop();
|
|
268
|
+
recordingSource.getTracks().forEach((track) => track.stop());
|
|
269
|
+
this.service.cleanup();
|
|
270
|
+
throw error;
|
|
271
|
+
} finally {
|
|
272
|
+
this.startInFlight = false;
|
|
273
|
+
}
|
|
274
|
+
if (this.stopping) {
|
|
275
|
+
compositor.stop();
|
|
276
|
+
recordingSource.getTracks().forEach((track) => track.stop());
|
|
277
|
+
this.service.cleanup();
|
|
278
|
+
return;
|
|
279
|
+
}
|
|
280
|
+
this.compositor = compositor;
|
|
281
|
+
this.recordingSource = recordingSource;
|
|
282
|
+
this.audioSource = recordingSource.getAudioTracks();
|
|
283
|
+
if (this.suspendRequested) {
|
|
284
|
+
this.suspendRequested = false;
|
|
285
|
+
this.suspend();
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
/**
|
|
289
|
+
* Pauses the container and ends the camera clone on the calling thread. The
|
|
290
|
+
* composite stream and the upload stay open for the next attempt.
|
|
291
|
+
*/
|
|
292
|
+
suspend() {
|
|
293
|
+
if (this.stopping) return;
|
|
294
|
+
if (!this.compositor) {
|
|
295
|
+
this.suspendRequested = this.startInFlight;
|
|
296
|
+
return;
|
|
297
|
+
}
|
|
298
|
+
if (!this.pausedForAttempt) this.pausedForAttempt = this.service.pause();
|
|
299
|
+
this.releaseCameraClone({ keepAudio: true });
|
|
300
|
+
this.needsVideoSourceReplacement = true;
|
|
301
|
+
}
|
|
302
|
+
async prepareUpload() {
|
|
303
|
+
this.suspend();
|
|
304
|
+
return { recordingId: null };
|
|
305
|
+
}
|
|
306
|
+
async stop() {
|
|
307
|
+
await this.complete();
|
|
308
|
+
return { recordingId: null };
|
|
309
|
+
}
|
|
310
|
+
pauseForBackground() {
|
|
311
|
+
this.suspend();
|
|
312
|
+
}
|
|
313
|
+
async resumeFromBackground(stream) {
|
|
314
|
+
if (!this.compositor || this.stopping) return;
|
|
315
|
+
await this.resume(stream);
|
|
316
|
+
}
|
|
317
|
+
async stopAndGetVideo() {
|
|
318
|
+
await this.complete();
|
|
319
|
+
return { videoBase64: void 0 };
|
|
320
|
+
}
|
|
321
|
+
cleanup() {
|
|
322
|
+
this.suspendRequested = false;
|
|
323
|
+
this.pausedForAttempt = false;
|
|
324
|
+
this.needsVideoSourceReplacement = false;
|
|
325
|
+
this.releaseCameraClone({ keepAudio: false });
|
|
326
|
+
this.compositor?.stop();
|
|
327
|
+
this.compositor = void 0;
|
|
328
|
+
this.recordingSource = void 0;
|
|
329
|
+
this.audioSource = [];
|
|
330
|
+
this.service.cleanup();
|
|
331
|
+
}
|
|
332
|
+
/** Swaps this attempt's camera clone into the composite and resumes. */
|
|
333
|
+
async resume(stream) {
|
|
334
|
+
const compositor = this.compositor;
|
|
335
|
+
if (!compositor) return;
|
|
336
|
+
if (this.needsVideoSourceReplacement) {
|
|
337
|
+
const recordingSource = stream.clone();
|
|
338
|
+
recordingSource.getAudioTracks().forEach((track) => track.stop());
|
|
339
|
+
compositor.switchVideo(recordingSource);
|
|
340
|
+
this.needsVideoSourceReplacement = false;
|
|
341
|
+
this.recordingSource = recordingSource;
|
|
342
|
+
const result = await compositor.resume();
|
|
343
|
+
if (result !== "resumed") throw new Error(`Face recording camera did not resume: ${result}`);
|
|
344
|
+
}
|
|
345
|
+
if (this.pausedForAttempt && !this.service.resume()) throw new Error("Face recording did not resume");
|
|
346
|
+
this.pausedForAttempt = false;
|
|
347
|
+
}
|
|
348
|
+
/**
|
|
349
|
+
* Completes the scoped upload. The camera clone ends synchronously before the
|
|
350
|
+
* drain so a step that ends mid-attempt never pins the camera; the composite
|
|
351
|
+
* stays alive until the recorder has emitted its final chunk.
|
|
352
|
+
*/
|
|
353
|
+
async complete() {
|
|
354
|
+
this.stopping = true;
|
|
355
|
+
this.suspendRequested = false;
|
|
356
|
+
this.releaseCameraClone({ keepAudio: false });
|
|
357
|
+
try {
|
|
358
|
+
await this.service.stop();
|
|
359
|
+
} finally {
|
|
360
|
+
this.compositor?.stop();
|
|
361
|
+
this.compositor = void 0;
|
|
362
|
+
this.recordingSource = void 0;
|
|
363
|
+
this.audioSource = [];
|
|
364
|
+
this.pausedForAttempt = false;
|
|
365
|
+
this.needsVideoSourceReplacement = false;
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
releaseCameraClone(options) {
|
|
369
|
+
try {
|
|
370
|
+
this.compositor?.pause();
|
|
371
|
+
} catch {}
|
|
372
|
+
const tracks = options.keepAudio ? this.recordingSource?.getVideoTracks() ?? [] : /* @__PURE__ */ new Set([...this.recordingSource?.getTracks() ?? [], ...this.audioSource]);
|
|
373
|
+
for (const track of tracks) try {
|
|
374
|
+
track.stop();
|
|
375
|
+
} catch {}
|
|
376
|
+
}
|
|
377
|
+
};
|
|
378
|
+
/**
|
|
379
|
+
* Creates the recording service for the current configuration.
|
|
380
|
+
*
|
|
381
|
+
* Order of precedence:
|
|
382
|
+
* 1. `onDeviceFaceResultsSubmissionEnabled === true` → no recording. The
|
|
383
|
+
* on-device workflow never uploads media, only the staged face-results
|
|
384
|
+
* JSON via `WebApi.postFaceResults`. Mirrors V1's
|
|
385
|
+
* `FaceFlowManager.setRecorders()` early return.
|
|
386
|
+
* 2. `deepsightLiveness === 'VIDEOLIVENESS'` → local Deepsight recorder.
|
|
387
|
+
* 3. `enableFaceRecording === true` → scoped multipart recorder.
|
|
388
|
+
* 4. otherwise → no recording.
|
|
389
|
+
*/
|
|
390
|
+
function createRecordingService(params) {
|
|
391
|
+
if (params.config.onDeviceFaceResultsSubmissionEnabled === true) return;
|
|
392
|
+
if (params.localDelivery === true) return params.config.enableFaceRecording === true || params.config.deepsightLiveness === "VIDEOLIVENESS" ? new LocalRecordingService(params.wasmUtil, null) : void 0;
|
|
393
|
+
if (params.config.deepsightLiveness === "VIDEOLIVENESS") return new LocalRecordingService(params.wasmUtil, params.sessionToken);
|
|
394
|
+
if (params.config.enableFaceRecording === true) return new MultipartFaceRecordingService();
|
|
395
|
+
}
|
|
396
|
+
//#endregion
|
|
397
|
+
export { createRecordingService };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as RedirectToMobileActor, i as createRedirectToMobileManagerFromActor, n as RedirectToMobileState, o as redirectToMobileMachine, r as createRedirectToMobileManager, t as RedirectToMobileManager } from "./redirectToMobileManager-
|
|
1
|
+
import { r as RedirectToMobileServices, t as RedirectToMobileConfig } from "./types-DNVzoRvi.js";
|
|
2
|
+
import { a as RedirectToMobileActor, i as createRedirectToMobileManagerFromActor, n as RedirectToMobileState, o as redirectToMobileMachine, r as createRedirectToMobileManager, t as RedirectToMobileManager } from "./redirectToMobileManager-pT6FiPE7.js";
|
|
3
3
|
//#region src/modules/redirect-to-mobile/redirectToMobileServices.d.ts
|
|
4
4
|
declare const defaultRedirectToMobileServices: RedirectToMobileServices;
|
|
5
5
|
//#endregion
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices } from "./redirectToMobileStateMachine-
|
|
2
|
-
import { n as createRedirectToMobileManagerFromActor, t as createRedirectToMobileManager } from "./redirectToMobileManager-
|
|
1
|
+
import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices } from "./redirectToMobileStateMachine-CMjjUXSu.esm.js";
|
|
2
|
+
import { n as createRedirectToMobileManagerFromActor, t as createRedirectToMobileManager } from "./redirectToMobileManager-DjsEtWLq.esm.js";
|
|
3
3
|
export { createRedirectToMobileManager, createRedirectToMobileManagerFromActor, defaultRedirectToMobileServices, redirectToMobileMachine };
|