@incodetech/core 2.1.1 → 2.2.0-rc.1
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/{3dAvatarProvider-BwOmTMOy.esm.js → 3dAvatarProvider-g02DTFqT.esm.js} +811 -880
- package/dist/Actor-iTq7YY48.d.ts +1 -0
- package/dist/BrowserDiagnosticsCryptoProvider-BwGL3Lmi.esm.js +95 -0
- package/dist/BrowserLazyImportProvider-BhoA957O.esm.js +114 -0
- package/dist/{BrowserStorageProvider-CBHBhKQN.esm.js → BrowserStorageProvider-k-FDkC4W.esm.js} +2 -4
- package/dist/{BrowserTimerProvider-CHloo0eQ.esm.js → BrowserTimerProvider-BXhgNxLt.esm.js} +1 -2
- package/dist/{BrowserVisibilityObserverProvider-GBS6XSii.esm.js → BrowserVisibilityObserverProvider-BX1BiLDK.esm.js} +1 -2
- package/dist/Face2DProvider-UUQt_vRC.esm.js +437 -0
- package/dist/{createFaceAvatar-CpdYp9Iy.d.ts → FaceDetectionProvider-Mh6q3EbA.d.ts} +107 -159
- package/dist/IBrowserEnvironmentCapability-DEaRRk-R.esm.js +9 -0
- package/dist/IFaceAvatarCapability-BrL19G0s.d.ts +23 -0
- package/dist/IFeatureManagementCapability-DdEUp6tB.d.ts +1125 -0
- package/dist/IIdCaptureCapability-DHTT3FC2.d.ts +237 -0
- package/dist/IStorageCapability-ORkQfK3F.d.ts +242 -0
- package/dist/{ITimerCapability-DJ73P4RK.esm.js → ITimerCapability-DgdDzp8G.esm.js} +1 -2
- package/dist/{Manager-goNPc_h_.d.ts → Manager-CQQ99QOI.d.ts} +1 -0
- package/dist/{MotionSensorProvider-BHuHoYvJ.esm.js → MotionSensorProvider-DGiV77J_.esm.js} +2 -37
- package/dist/{OpenViduRecordingProvider-CK6A5kiU.esm.js → OpenViduRecordingProvider-Du98qevC.esm.js} +2 -4
- package/dist/PrivacyLensProvider-D8PS7AJa.esm.js +405 -0
- package/dist/StateMachine-EDpYWy0i.d.ts +6 -0
- package/dist/{StreamCanvasCapture-CAqUdVkM.esm.js → StreamCanvasCapture-D2XcXCZ4.esm.js} +2 -4
- package/dist/{addressSearch-D7msRieq.esm.js → addressSearch-DQyrvDQj.esm.js} +10 -21
- package/dist/ae-signature.d.ts +4 -6
- package/dist/ae-signature.esm.js +10 -11
- package/dist/antifraud.d.ts +1 -6
- package/dist/antifraud.esm.js +3 -8
- package/dist/{antifraudManager-5KA84wtF.esm.js → antifraudManager-B8Plzf7a.esm.js} +11 -8
- package/dist/{antifraudManager-DCiNI6np.d.ts → antifraudManager-BY36bS12.d.ts} +3 -3
- package/dist/{antifraudStateMachine-BQVw46N5.esm.js → antifraudStateMachine-r4VxSBS4.esm.js} +5 -7
- package/dist/api-Bx3gKW_y.esm.js +129 -0
- package/dist/{apiError-DkOXfFBu.esm.js → apiError-oiEnJIlk.esm.js} +25 -3
- package/dist/authentication.d.ts +3 -19
- package/dist/authentication.esm.js +3 -35
- package/dist/{authenticationManager-BeT6tNZm.d.ts → authenticationManager-BBMGTcwW.d.ts} +3 -4
- package/dist/{authenticationManager-BryLnSaF.esm.js → authenticationManager-Dq_tudSW.esm.js} +7 -10
- package/dist/{authenticationStateMachine-DbdxfGHx.esm.js → authenticationStateMachine-D4koAtP3.esm.js} +11 -15
- package/dist/avatar.d.ts +2 -2
- package/dist/avatar.esm.js +2 -3
- package/dist/avatar2dWarm-DqucNFX4.esm.js +1330 -0
- package/dist/avatarStats-CdUOb3VD.esm.js +136 -0
- package/dist/{backCameraStream-ChrMTJv-.esm.js → backCameraStream-CUeYm5eu.esm.js} +20 -8
- package/dist/browser-DlFgHpoC-DnyrCR8r.esm.js +1513 -0
- package/dist/callback-645_omgz.d.ts +133 -0
- package/dist/camera-_2sXMXiF.esm.js +140 -0
- package/dist/camera.d.ts +19 -2
- package/dist/camera.esm.js +2 -6
- package/dist/{canvas-Pi10hG_l.esm.js → canvas-E1zGkel4.esm.js} +1 -2
- package/dist/certificate-issuance.d.ts +34 -39
- package/dist/certificate-issuance.esm.js +4 -11
- package/dist/{certificateIssuanceStateMachine-DlZQT1_u.esm.js → certificateIssuanceStateMachine-COd7_l2T.esm.js} +7 -11
- package/dist/consent.d.ts +1 -4
- package/dist/consent.esm.js +3 -8
- package/dist/{consentManager-BwNu-uC-.esm.js → consentManager-BApTlfA0.esm.js} +5 -7
- package/dist/{consentManager-B4PMGXW-.d.ts → consentManager-uhDPdU6i.d.ts} +55 -61
- package/dist/{consentStateMachine-BOkVFiU7.esm.js → consentStateMachine-WD-S-Yhs.esm.js} +5 -7
- package/dist/{cpf-16m_cGAM.esm.js → cpf-BIADjddF.esm.js} +1 -2
- package/dist/createFaceAvatar-BEj18KXi.d.ts +50 -0
- package/dist/createFaceAvatar-DQKaRise.esm.js +103 -0
- package/dist/cross-document-data-match.d.ts +2 -26
- package/dist/cross-document-data-match.esm.js +2 -71
- package/dist/crossDocumentDataMatchManager-Dq8Z3SOg.d.ts +41 -0
- package/dist/crossDocumentDataMatchManager-OmYvyung.esm.js +84 -0
- package/dist/curp-validation.d.ts +1 -11
- package/dist/curp-validation.esm.js +3 -8
- package/dist/{curpValidationManager-CoqODZx5.d.ts → curpValidationManager-DVGr7Fq7.d.ts} +4 -6
- package/dist/{curpValidationManager-Cbji2inV.esm.js → curpValidationManager-UZxcrsrz.esm.js} +11 -7
- package/dist/{curpValidationStateMachine-Dlw4qfFb.esm.js → curpValidationStateMachine-9KwnqeoB.esm.js} +22 -14
- package/dist/custom-fields.d.ts +2 -5
- package/dist/custom-fields.esm.js +24 -11
- package/dist/custom-watchlist.d.ts +1 -3
- package/dist/custom-watchlist.esm.js +11 -10
- package/dist/{customWatchlistStateMachine-D8w0mNxm.esm.js → customWatchlistStateMachine-B_ey3TFj.esm.js} +5 -7
- package/dist/{dateUtils-BW6mBV6p.esm.js → dateUtils-CvG0FvK8.esm.js} +1 -2
- package/dist/{deepsightService-CViys6T4.esm.js → deepsightLoader-CWE0SvF1.esm.js} +68 -14
- package/dist/{deepsightService-BuTOFTr8.d.ts → deepsightService-DLVQS_RH.d.ts} +41 -2
- package/dist/device.d.ts +10 -2
- package/dist/device.esm.js +21 -21
- package/dist/document-capture.d.ts +3 -1816
- package/dist/document-capture.esm.js +3 -245
- package/dist/document-upload.d.ts +48 -55
- package/dist/document-upload.esm.js +8 -14
- package/dist/documentCaptureManager-B3t0ydtg.d.ts +2062 -0
- package/dist/documentCaptureManager-DszmcU-l.esm.js +296 -0
- package/dist/{documentCaptureStateMachine-BkTvU3yq.esm.js → documentCaptureStateMachine-D2jBwwVb.esm.js} +66 -40
- package/dist/dynamic-forms.d.ts +2 -4
- package/dist/dynamic-forms.esm.js +3 -9
- package/dist/{dynamicFormsManager-CHXUBNs4.esm.js → dynamicFormsManager-B-OmpJkU.esm.js} +48 -9
- package/dist/{dynamicFormsManager-CKZkE7Wo.d.ts → dynamicFormsManager-fhK0yINk.d.ts} +22 -46
- package/dist/{dynamicFormsStateMachine-DJ1HGZff.esm.js → dynamicFormsStateMachine-D_3oLtOE.esm.js} +161 -34
- package/dist/ekyb.d.ts +5 -137
- package/dist/ekyb.esm.js +4 -179
- package/dist/ekybManager-BJVp2ahf.esm.js +178 -0
- package/dist/ekybManager-Dzswb_b8.d.ts +114 -0
- package/dist/{ekybStateMachine-D9GzA4MW.esm.js → ekybStateMachine-BYcc9VaR.esm.js} +16 -193
- package/dist/ekyc.d.ts +2 -79
- package/dist/ekyc.esm.js +4 -154
- package/dist/ekycManager-BFpHbBoT.d.ts +97 -0
- package/dist/ekycManager-oTstTJuL.esm.js +156 -0
- package/dist/{ekycStateMachine-DnVRiu3s.esm.js → ekycStateMachine-DHvksnrr.esm.js} +141 -423
- package/dist/ekycUtils-Dew1rBG0.esm.js +223 -0
- package/dist/electronic-signature.d.ts +3 -5
- package/dist/electronic-signature.esm.js +2 -10
- package/dist/{electronicSignatureManager-DESRgObX.esm.js → electronicSignatureManager-CApcBEQd.esm.js} +47 -33
- package/dist/{index-36QX_21w.d.ts → electronicSignatureManager-CcUXQZS7.d.ts} +220 -251
- package/dist/email.d.ts +1 -5
- package/dist/email.esm.js +3 -10
- package/dist/{emailManager-CMS4q_r6.d.ts → emailManager-CADXW_9X.d.ts} +4 -7
- package/dist/{emailManager-B9Vrv3Ma.esm.js → emailManager-tE-YvNtS.esm.js} +76 -12
- package/dist/{emailStateMachine-CbmKFVSi.esm.js → emailStateMachine-Bm894MHB.esm.js} +7 -9
- package/dist/{endpoints-CwrFQfW7.esm.js → endpoints-CCzL3XD_.esm.js} +55 -6
- package/dist/{events-1wxZ97yf.esm.js → events-CxfNJVZW.esm.js} +43 -176
- package/dist/events.d.ts +28 -10
- package/dist/events.esm.js +2 -4
- package/dist/extensibility.d.ts +37 -37
- package/dist/extensibility.esm.js +31 -80
- package/dist/{externalFetch-hvmz_npP.esm.js → externalFetch-BKBThAUC.esm.js} +2 -4
- package/dist/face-match.d.ts +2 -225
- package/dist/face-match.esm.js +3 -173
- package/dist/{faceCaptureManagerFactory-C9TiGbkA.esm.js → faceCaptureManagerFactory-4VejGOQX.esm.js} +52 -31
- package/dist/{faceCaptureManagerFactory-DiJ64oem.d.ts → faceCaptureManagerFactory-BxWPpxyd.d.ts} +63 -24
- package/dist/{faceCaptureSetup-BqhqfFHL.esm.js → faceCaptureSetup-BB5KEtbV.esm.js} +57 -36
- package/dist/faceMatchManager-BXp2WUT-.esm.js +201 -0
- package/dist/faceMatchManager-BnvrZM2F.d.ts +268 -0
- package/dist/{faceMatchStateMachine-MDb30gCm.esm.js → faceMatchStateMachine-CJiO2yLO.esm.js} +14 -10
- package/dist/feature-management-DS_Nj5Gg.esm.js +615 -0
- package/dist/feature-management.d.ts +173 -0
- package/dist/feature-management.esm.js +2 -0
- package/dist/field-comparison.d.ts +1 -4
- package/dist/field-comparison.esm.js +2 -7
- package/dist/{fieldComparisonManager-OLKVsG2Z.d.ts → fieldComparisonManager-CBvEGxFx.d.ts} +3 -5
- package/dist/{fieldComparisonManager-Cw4uzD7S.esm.js → fieldComparisonManager-DhnYdYZ2.esm.js} +6 -11
- package/dist/fiscal-qr.d.ts +1 -6
- package/dist/fiscal-qr.esm.js +14 -29
- package/dist/flow-events.d.ts +2 -9
- package/dist/flow.d.ts +59 -21
- package/dist/flow.esm.js +132 -49
- package/dist/{flowCompletionService-B6P6_EF3.esm.js → flowCompletionService-Bt3wD28k.esm.js} +4 -6
- package/dist/flowServices-b0Pd4F1K.esm.js +620 -0
- package/dist/geolocation.d.ts +1 -4
- package/dist/geolocation.esm.js +3 -9
- package/dist/geolocationManager-Cz744E5S.d.ts +506 -0
- package/dist/{geolocationManager-CF6-NizA.esm.js → geolocationManager-DGwnL5lg.esm.js} +44 -16
- package/dist/{geolocationStateMachine-CD2XJs1b.esm.js → geolocationStateMachine-il6jz5DZ.esm.js} +53 -28
- package/dist/{getBrowser-1yNcfFZR.esm.js → getBrowser-Cb8Zgrgp.esm.js} +1 -2
- package/dist/getBrowser-DNrQeL4T.esm.js +16 -0
- package/dist/getDeviceClass-9y-kbVDw.esm.js +19 -0
- package/dist/{getDeviceClass-C-Dg6IsJ.esm.js → getDeviceClass-CeBiEayS.esm.js} +1 -2
- package/dist/getParsedUserAgent-pJjATANs.esm.js +1622 -0
- package/dist/government-validation.d.ts +3 -6
- package/dist/government-validation.esm.js +7 -13
- package/dist/{governmentValidationStateMachine-BE5wiQ7Y.esm.js → governmentValidationStateMachine-BYKYUdza.esm.js} +8 -11
- package/dist/home.d.ts +14 -22
- package/dist/home.esm.js +3 -8
- package/dist/http.d.ts +0 -1
- package/dist/http.esm.js +2 -4
- package/dist/id-ocr.d.ts +8 -7
- package/dist/id-ocr.esm.js +20 -9
- package/dist/id-selfie-flow.d.ts +179 -0
- package/dist/id-selfie-flow.esm.js +917 -0
- package/dist/id-verification.d.ts +2 -191
- package/dist/id-verification.esm.js +3 -43
- package/dist/id.d.ts +7 -18
- package/dist/id.esm.js +47 -53
- package/dist/{idCaptureDefaults-CZajItdO.esm.js → idCaptureDefaults-WeHbQM7W.esm.js} +54 -17
- package/dist/idCaptureManager-BjU-Wyow.d.ts +429 -0
- package/dist/{idCaptureManager-DASPUMtC.esm.js → idCaptureManager-DgohUfUQ.esm.js} +173 -34
- package/dist/idCaptureServices-RDiDS9tg.esm.js +396 -0
- package/dist/{idCaptureStateMachine-DZ2ZTSxu.esm.js → idCaptureStateMachine-DWocZD_m.esm.js} +438 -585
- package/dist/{idOcrManager-Tm4LzKR0.esm.js → idOcrManager-CvJZhmBR.esm.js} +4 -7
- package/dist/{idOcrManager-DLfAjDZn.d.ts → idOcrManager-DXc_xRN7.d.ts} +62 -229
- package/dist/{idOcrStateMachine-BJxZCxwS.esm.js → idOcrStateMachine-Bq_e3l4E.esm.js} +15 -20
- package/dist/idVerificationManager-BB4Pj_N6.d.ts +197 -0
- package/dist/idVerificationManager-CduNXhWd.esm.js +51 -0
- package/dist/{idVerificationStateMachine-DXN9WcdM.esm.js → idVerificationStateMachine-GEQWUPU2.esm.js} +5 -7
- package/dist/identity-reuse.d.ts +1 -4
- package/dist/identity-reuse.esm.js +3 -8
- package/dist/{identityReuseManager-LjkPvSQN.esm.js → identityReuseManager-D5vXknnJ.esm.js} +24 -7
- package/dist/{identityReuseManager-CLVOYxcp.d.ts → identityReuseManager-v2TH5g7e.d.ts} +38 -43
- package/dist/{identityReuseStateMachine-Bp-zONoV.esm.js → identityReuseStateMachine-AubRPhIi.esm.js} +6 -8
- package/dist/index-B8weJxmL.d.ts +1 -0
- package/dist/index-BKOWUhxG.d.ts +258 -0
- package/dist/{index-DrpWp15Z.d.ts → index-CLMF0QLQ.d.ts} +3 -3
- package/dist/index.d.ts +1 -3
- package/dist/index.esm.js +2 -15
- package/dist/{invokeOnCaptureCallback-CCS2Ruzi.esm.js → invokeOnCaptureCallback-1m1VJ3Q4.esm.js} +2 -4
- package/dist/{lib-Bjd6nOLG.esm.js → lib-DAyUtOTj.esm.js} +1510 -1589
- package/dist/mandatory-consent.d.ts +2 -10
- package/dist/mandatory-consent.esm.js +3 -8
- package/dist/{mandatoryConsentManager-DeBmOHcQ.d.ts → mandatoryConsentManager-B29kR0XA.d.ts} +60 -85
- package/dist/{mandatoryConsentManager-DZ26sg4B.esm.js → mandatoryConsentManager-BeELm1zS.esm.js} +4 -7
- package/dist/{mandatoryConsentStateMachine-_44ZoDSh.esm.js → mandatoryConsentStateMachine-zroQGzwb.esm.js} +5 -7
- package/dist/manualReviewService-D4IkipnN.esm.js +15 -0
- package/dist/{mediaRecorderOptions-CClCKAiF.esm.js → mediaRecorderOptions-dALSV8af.esm.js} +2 -4
- package/dist/{mediapipeShared-Bcmkzs3x.esm.js → mediapipeShared-B6oNoXEQ.esm.js} +21 -9
- package/dist/{onDeviceFaceResults-DILtthks.esm.js → onDeviceFaceResults-C6IRJHQB.esm.js} +30 -87
- package/dist/openviduLazy-CCDpFWg1.esm.js +10 -0
- package/dist/{otp-B1YeyRXu.d.ts → otp-CEWfTj9v.d.ts} +0 -1
- package/dist/{otp-uaXiKt_R.esm.js → otp-D2k3PeSL.esm.js} +3 -14
- package/dist/{permissionGuards-BNOe4Tnu.esm.js → permissionGuards-KINpmKtI.esm.js} +2 -4
- package/dist/{permissionServices-C_kxhNeo.esm.js → permissionServices-UvUcOSRb.esm.js} +35 -28
- package/dist/personhood.d.ts +13 -20
- package/dist/personhood.esm.js +153 -85
- package/dist/phone.d.ts +1 -5
- package/dist/phone.esm.js +3 -10
- package/dist/{phoneManager-_KtitbUA.d.ts → phoneManager-BBU8Lq0O.d.ts} +4 -7
- package/dist/{phoneManager-CRblfdcI.esm.js → phoneManager-Cpiai2IM.esm.js} +82 -12
- package/dist/{phoneStateMachine-DjFGWMjQ.esm.js → phoneStateMachine-E1fUUcNM.esm.js} +7 -9
- package/dist/{platform-0Ot-bF_a.esm.js → platform-BJrm5nzZ.esm.js} +31 -11
- package/dist/privacyLensWorker-DI-Rg83h.esm.js +355 -0
- package/dist/qe-signature.d.ts +4 -6
- package/dist/qe-signature.esm.js +10 -11
- package/dist/{recordingService-CxaYkITO.esm.js → recordingService-N4RhdyiT.esm.js} +13 -31
- package/dist/redirect-to-mobile.d.ts +2 -6
- package/dist/redirect-to-mobile.esm.js +3 -10
- package/dist/{redirectToMobileManager-dv29o_LS.d.ts → redirectToMobileManager-BD2PvT5B.d.ts} +8 -44
- package/dist/{redirectToMobileManager-DbuNUlru.esm.js → redirectToMobileManager-C0dfc7f6.esm.js} +28 -8
- package/dist/{redirectToMobileStateMachine-BRaIJWOM.esm.js → redirectToMobileStateMachine-C9SYCJcH.esm.js} +74 -18
- package/dist/rolldown-runtime-FZ4Itg2g.esm.js +42 -0
- package/dist/{runChildModule-kojSv3MH.esm.js → runChildModule-DpRmKWV0.esm.js} +10 -9
- package/dist/{WasmUtilProvider-BgzcXBdl.esm.js → safeStorage-Ep56I-f_.esm.js} +98 -473
- package/dist/selfie.d.ts +8 -21
- package/dist/selfie.esm.js +40 -47
- package/dist/selfieErrorUtils-C2PYBVsp.esm.js +90 -0
- package/dist/{selfieManager-B1Px3GGa.esm.js → selfieManager-CmoNiluM.esm.js} +7 -10
- package/dist/{selfieManager-4juKfrHG.d.ts → selfieManager-DwlCppg0.d.ts} +3 -4
- package/dist/{selfieStateMachine-D0TS93Tu.esm.js → selfieStateMachine-L9pghTly.esm.js} +14 -29
- package/dist/{session-CLsU2Jnb.esm.js → session-DeR_I24J.esm.js} +16 -7
- package/dist/session.d.ts +12 -10
- package/dist/session.esm.js +5 -15
- package/dist/sessionInitializer-DNgRpf5Y.esm.js +1865 -0
- package/dist/{setup-CfNsYAeB.esm.js → setup-DuYKUt0r.esm.js} +319 -137
- package/dist/{setup-CmA2apmN.d.ts → setup-DywQeePQ.d.ts} +186 -4
- package/dist/signature.d.ts +2 -96
- package/dist/signature.esm.js +3 -108
- package/dist/signatureManager-DGBSWz2_.d.ts +106 -0
- package/dist/signatureManager-DdPgcmou.esm.js +113 -0
- package/dist/{signatureStateMachine-CdhlMih-.esm.js → signatureStateMachine-Cf73DGWO.esm.js} +5 -7
- package/dist/spawn-D9jgw9pW.d.ts +1441 -0
- package/dist/src-0Jurt29N.esm.js +4482 -0
- package/dist/{stats-BVy52wLy.esm.js → stats-B0nFKawG.esm.js} +3 -5
- package/dist/stats.esm.js +2 -5
- package/dist/topLevelStateName-B5i2avbh.esm.js +41 -0
- package/dist/{tri-CFAPtAUM.esm.js → tri-4RsGrIt6.esm.js} +3 -119
- package/dist/tri.d.ts +2 -2
- package/dist/tri.esm-BIjHhBJ2.esm.js +2620 -0
- package/dist/tri.esm.js +2 -4
- package/dist/trueSight-BTl_vvd3.esm.js +1 -0
- package/dist/trueSightService-s3T95geD.esm.js +1894 -0
- package/dist/trust-graph.d.ts +4 -5
- package/dist/trust-graph.esm.js +13 -9
- package/dist/types-BEwVKkLJ.d.ts +15 -0
- package/dist/{types-BKLb3C42.esm.js → types-BN5RPPIZ.esm.js} +1 -2
- package/dist/types-BSBzhHRH.d.ts +57 -0
- package/dist/types-BX_XkMsQ2.d.ts +21 -0
- package/dist/types-BfHiko5D.d.ts +48 -0
- package/dist/{types-D8Cl1N2Z.d.ts → types-BfgmV7s72.d.ts} +2 -2
- package/dist/types-CJ7Yl9K-2.d.ts +164 -0
- package/dist/types-DPIDuhut.d.ts +40 -0
- package/dist/types-DVmXIdzW.d.ts +82 -0
- package/dist/types-DelMqZLe.d.ts +105 -0
- package/dist/types-EELWyWpd.d.ts +6 -0
- package/dist/{types-fO6KIdol.d.ts → types-Hmd7U0JA.d.ts} +80 -6
- package/dist/{types-BUgeB2X6.d.ts → types-KPvmag_B.d.ts} +7 -7
- package/dist/types-M6eb82ra2.d.ts +589 -0
- package/dist/{types-DV3wkhQ4.d.ts → types-Vb4P9ovf.d.ts} +1 -3
- package/dist/{urlUtils-CpiYwn7w.esm.js → urlUtils-D6phjq1-.esm.js} +1 -2
- package/dist/{video-ZY92rkel.esm.js → video-BtSWtHy1.esm.js} +1 -2
- package/dist/video-selfie.d.ts +71 -117
- package/dist/video-selfie.esm.js +575 -643
- package/dist/videoSelfieCameraWarmer-DPx5Lm3d.esm.js +651 -0
- package/dist/videoSelfieStepDetector-D3oo2ofo.d.ts +123 -0
- package/dist/wasm.d.ts +2 -4
- package/dist/wasm.esm.js +4 -15
- package/dist/wasmDefaults-DTUrftxR.esm.js +125 -0
- package/dist/{wasmDsFlagSync-Ch0mFJNT.esm.js → wasmDsFlagSync-BqUCwLY8.esm.js} +2 -4
- package/dist/wasmWebClient-DM8lkb0z.esm.js +407 -0
- package/dist/watchlist-for-business.d.ts +1 -3
- package/dist/watchlist-for-business.esm.js +9 -9
- package/dist/watchlist.d.ts +1 -52
- package/dist/watchlist.esm.js +3 -70
- package/dist/{watchlistForBusinessStateMachine-R1Yp1g5A.esm.js → watchlistForBusinessStateMachine-BcBMkMvV.esm.js} +5 -7
- package/dist/watchlistManager-CjSMmbyq.esm.js +83 -0
- package/dist/watchlistManager-DLXef90v.d.ts +68 -0
- package/dist/{watchlistStateMachine-D07UVq1m.esm.js → watchlistStateMachine-Bl7Wy9Cm.esm.js} +5 -7
- package/dist/workflow.d.ts +239 -203
- package/dist/workflow.esm.js +156 -101
- package/dist/xstate-actors.esm-CtI5S0f4.esm.js +310 -0
- package/dist/{xstate.esm-nY3M5UYm.esm.js → xstate.esm-Cf4e0Cfd.esm.js} +136 -610
- package/package.json +14 -9
- package/dist/Actor-BwgmOPkb.d.ts +0 -2
- package/dist/Face2DProvider-CZU11g6r.esm.js +0 -824
- package/dist/FaceDetectionProvider-CPWg-PAH.d.ts +0 -119
- package/dist/IWasmUtilCapability-DaSNxgA8.d.ts +0 -150
- package/dist/PrivacyLensProvider-B_zrV25p.esm.js +0 -339
- package/dist/StateMachine-D5WO6lHS.d.ts +0 -2
- package/dist/StreamCanvasCapture-DHaWferF.d.ts +0 -42
- package/dist/ae-signature-Pp4oCAHD.esm.js +0 -12
- package/dist/api-DsbUi7TO.esm.js +0 -72
- package/dist/browser-DlFgHpoC-Br3G10gw.esm.js +0 -1425
- package/dist/browserSimulation-DZwEy9bu.esm.js +0 -2804
- package/dist/camera-CxxXV0VN.esm.js +0 -79
- package/dist/canvas-90BqS0NF.d.ts +0 -112
- package/dist/chunk-CIKcdghV.esm.js +0 -49
- package/dist/clientLifecycle-VyzRfALg.esm.js +0 -534
- package/dist/cpf-ocr.d.ts +0 -10
- package/dist/cpf-ocr.esm.js +0 -8
- package/dist/cpfOcrManager-9eM4z4o7.esm.js +0 -190
- package/dist/cpfOcrManager-C5U9E0hf.d.ts +0 -216
- package/dist/createFaceAvatar-BZSg2MNo.esm.js +0 -46
- package/dist/deepsightLoader-CU_tiLMx.esm.js +0 -62
- package/dist/flowServices-DkQmOkLV.esm.js +0 -208
- package/dist/geolocationManager-DaHYFkVO.d.ts +0 -156
- package/dist/getDeviceClass-DIjnTPjR.esm.js +0 -14
- package/dist/http-CnsKEaJY.esm.js +0 -0
- package/dist/idCaptureManager-CwuXtVu6.d.ts +0 -1013
- package/dist/index-BAyZ8_iI.d.ts +0 -93
- package/dist/openviduLazy-jPgABwrt.esm.js +0 -3
- package/dist/openviduLazy-wEojM41w.esm.js +0 -12
- package/dist/qe-signature-BnWIpR-O.esm.js +0 -12
- package/dist/sessionInitializer-Dj7-aJaP.esm.js +0 -547
- package/dist/tri.esm-DDJ1zOqG.esm.js +0 -2593
- package/dist/types-BcF-fii5.d.ts +0 -5
- package/dist/videoSelfieSteps-Djpv7cjb.esm.js +0 -58
- /package/dist/{IVisibilityObserverCapability-BZ1rE7ly.d.ts → IVisibilityObserverCapability-D4tvIB5v.d.ts} +0 -0
- /package/dist/{camera-CKU96nwJ.d.ts → camera-9wWD-pwg.d.ts} +0 -0
- /package/dist/{flowCompletionService-BOSTlAWo.d.ts → flowCompletionService-BlAHsKyv.d.ts} +0 -0
- /package/dist/{types-BgjMAEXl.d.ts → types-Bk_6dmDa.d.ts} +0 -0
- /package/dist/{warmup-Dd0iq6KF.d.ts → warmup-Dv2alr2-.d.ts} +0 -0
package/dist/personhood.esm.js
CHANGED
|
@@ -1,45 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as
|
|
3
|
-
import { t as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import "./
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import "./
|
|
11
|
-
import "./
|
|
12
|
-
import "./
|
|
13
|
-
import {
|
|
14
|
-
import "./
|
|
15
|
-
import {
|
|
16
|
-
import { a as stopCameraStream, r as requestCameraAccess } from "./camera-CxxXV0VN.esm.js";
|
|
17
|
-
import { t as BrowserStorageProvider } from "./BrowserStorageProvider-CBHBhKQN.esm.js";
|
|
18
|
-
import { b as FaceDetectionProvider, f as stopStream, l as startDetection, s as initializeDeepsightSession } from "./onDeviceFaceResults-DILtthks.esm.js";
|
|
19
|
-
import { t as sleep } from "./ITimerCapability-DJ73P4RK.esm.js";
|
|
20
|
-
import "./canvas-Pi10hG_l.esm.js";
|
|
21
|
-
import "./backCameraStream-ChrMTJv-.esm.js";
|
|
22
|
-
import "./video-ZY92rkel.esm.js";
|
|
23
|
-
import "./getDeviceClass-C-Dg6IsJ.esm.js";
|
|
24
|
-
import "./deepsightService-CViys6T4.esm.js";
|
|
25
|
-
import "./getDeviceClass-DIjnTPjR.esm.js";
|
|
26
|
-
import "./types-BKLb3C42.esm.js";
|
|
27
|
-
import { t as StreamCanvasCapture } from "./StreamCanvasCapture-CAqUdVkM.esm.js";
|
|
28
|
-
|
|
29
|
-
//#region ../infra/src/crypto/randomUUID.ts
|
|
30
|
-
/**
|
|
31
|
-
* Cryptographically-strong UUID v4 (RFC 4122).
|
|
32
|
-
*
|
|
33
|
-
* Lives in infra (L0) so Core (L1) can mint secure identifiers without touching
|
|
34
|
-
* the `crypto` browser API directly — Core delegates here, keeping it free of
|
|
35
|
-
* browser globals (enforced by the `no-browser-api-in-core` lint rule). Backed
|
|
36
|
-
* by `crypto.randomUUID`, available in every browser the SDK targets.
|
|
37
|
-
*/
|
|
38
|
-
function randomUUID() {
|
|
39
|
-
return crypto.randomUUID();
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
//#endregion
|
|
1
|
+
import { r as WasmUtilProvider } from "./safeStorage-Ep56I-f_.esm.js";
|
|
2
|
+
import { t as BrowserStorageProvider } from "./BrowserStorageProvider-k-FDkC4W.esm.js";
|
|
3
|
+
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
4
|
+
import { t as api } from "./api-Bx3gKW_y.esm.js";
|
|
5
|
+
import { b as getStoredHttpConfig, w as createApi$1, y as randomUUID } from "./trueSightService-s3T95geD.esm.js";
|
|
6
|
+
import { n as eventModuleNames } from "./events-CxfNJVZW.esm.js";
|
|
7
|
+
import { _ as getDeviceFingerprintInfo, g as getThumbmarkId, n as getFingerprintEnabled, p as isBrowserSimulation, v as BrowserEnvironmentProvider } from "./sessionInitializer-DNgRpf5Y.esm.js";
|
|
8
|
+
import { t as endpoints } from "./endpoints-CCzL3XD_.esm.js";
|
|
9
|
+
import { c as createManager, o as createActor, r as assign, t as setup } from "./xstate.esm-Cf4e0Cfd.esm.js";
|
|
10
|
+
import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-CtI5S0f4.esm.js";
|
|
11
|
+
import { a as stopCameraStream, r as requestCameraAccess } from "./camera-_2sXMXiF.esm.js";
|
|
12
|
+
import { i as requestPermission, t as checkPermission } from "./permissionServices-UvUcOSRb.esm.js";
|
|
13
|
+
import { f as stopStream, l as startDetection, s as initializeDeepsightSession, v as FaceDetectionProvider } from "./onDeviceFaceResults-C6IRJHQB.esm.js";
|
|
14
|
+
import { t as sleep } from "./ITimerCapability-DgdDzp8G.esm.js";
|
|
15
|
+
import { t as StreamCanvasCapture } from "./StreamCanvasCapture-D2XcXCZ4.esm.js";
|
|
43
16
|
//#region src/modules/personhood/personhoodServices.ts
|
|
44
17
|
/**
|
|
45
18
|
* Config used for the passive liveness pass. Deliberately stripped down from
|
|
@@ -234,18 +207,6 @@ async function analyzeLiveness(params) {
|
|
|
234
207
|
};
|
|
235
208
|
}
|
|
236
209
|
/**
|
|
237
|
-
* Minimum combined yaw+pitch range (in degrees) required across the
|
|
238
|
-
* detection window to clear the no-motion guard. A static photo or a
|
|
239
|
-
* face with no head movement will fall below this.
|
|
240
|
-
*/
|
|
241
|
-
const MIN_POSE_MOTION_DEG = 4;
|
|
242
|
-
/**
|
|
243
|
-
* Upper bound of motion (degrees) that adds confidence — beyond this,
|
|
244
|
-
* additional head movement doesn't increase our belief that there's a
|
|
245
|
-
* human (and may just be noise from a moving phone).
|
|
246
|
-
*/
|
|
247
|
-
const MAX_POSE_MOTION_FOR_BONUS_DEG = 50;
|
|
248
|
-
/**
|
|
249
210
|
* Ceiling for on-device verdicts. Intentionally below 1.0 — nothing short
|
|
250
211
|
* of a signed server round-trip should claim perfect confidence, and the
|
|
251
212
|
* ceiling is strictly below what a server verdict would return so the two
|
|
@@ -253,13 +214,6 @@ const MAX_POSE_MOTION_FOR_BONUS_DEG = 50;
|
|
|
253
214
|
*/
|
|
254
215
|
const LOCAL_CONFIDENCE_CEILING = .95;
|
|
255
216
|
/**
|
|
256
|
-
* Default pass threshold when `PersonhoodConfig.threshold` is omitted. Single
|
|
257
|
-
* source of truth — keep `PersonhoodConfig.threshold`'s JSDoc and PERSONHOOD.md
|
|
258
|
-
* in sync with this value. (A clean local pass without strong head motion lands
|
|
259
|
-
* around here, so this is the effective on-device gate.)
|
|
260
|
-
*/
|
|
261
|
-
const DEFAULT_PERSONHOOD_THRESHOLD = .75;
|
|
262
|
-
/**
|
|
263
217
|
* Produces a verdict entirely on-device using an **additive** confidence
|
|
264
218
|
* model. Each positive signal contributes a measurable amount to the score;
|
|
265
219
|
* penalties subtract. This means clean passes vary — a user who swings
|
|
@@ -284,7 +238,7 @@ const DEFAULT_PERSONHOOD_THRESHOLD = .75;
|
|
|
284
238
|
* - Detection didn't reach 'success' → -0.2
|
|
285
239
|
*/
|
|
286
240
|
function produceLocalVerdict(params) {
|
|
287
|
-
const threshold = params.threshold ??
|
|
241
|
+
const threshold = params.threshold ?? .75;
|
|
288
242
|
const reasons = [];
|
|
289
243
|
let confidence = .4;
|
|
290
244
|
if (params.detectionOutcome === "success") confidence += .25;
|
|
@@ -294,12 +248,11 @@ function produceLocalVerdict(params) {
|
|
|
294
248
|
}
|
|
295
249
|
if (params.liveness) {
|
|
296
250
|
const motion = params.liveness.yawRange + params.liveness.pitchRange;
|
|
297
|
-
if (motion <
|
|
251
|
+
if (motion < 4) {
|
|
298
252
|
reasons.push("no_motion");
|
|
299
253
|
confidence -= .5;
|
|
300
254
|
} else {
|
|
301
|
-
const
|
|
302
|
-
const motionRatio = Math.min(1, Math.max(0, (motion - MIN_POSE_MOTION_DEG) / span));
|
|
255
|
+
const motionRatio = Math.min(1, Math.max(0, (motion - 4) / 46));
|
|
303
256
|
confidence += .25 * motionRatio;
|
|
304
257
|
}
|
|
305
258
|
if (!hasExplicitSpoofSignal(params.liveness.analysisStatus)) confidence += .05;
|
|
@@ -318,7 +271,7 @@ function produceLocalVerdict(params) {
|
|
|
318
271
|
reasons.push("emulator");
|
|
319
272
|
confidence -= .9;
|
|
320
273
|
}
|
|
321
|
-
const SUBSUMED_HINTS = new Set(["navigator.webdriver", "automation-marker"]);
|
|
274
|
+
const SUBSUMED_HINTS = /* @__PURE__ */ new Set(["navigator.webdriver", "automation-marker"]);
|
|
322
275
|
if (params.signals.headlessHints.filter((hint) => !SUBSUMED_HINTS.has(hint)).length > 0) {
|
|
323
276
|
reasons.push("headless");
|
|
324
277
|
confidence -= .3;
|
|
@@ -502,7 +455,7 @@ async function fetchPersonhoodAuthToken(params = {}) {
|
|
|
502
455
|
};
|
|
503
456
|
try {
|
|
504
457
|
let res;
|
|
505
|
-
if (params.authBaseUrl) res = await
|
|
458
|
+
if (params.authBaseUrl) res = await createApi$1({
|
|
506
459
|
apiURL: params.authBaseUrl,
|
|
507
460
|
customHeaders: getStoredHttpConfig()?.customHeaders
|
|
508
461
|
}).post(authPath, body, reqConfig);
|
|
@@ -582,7 +535,7 @@ function buildSpoofCheckResults(params) {
|
|
|
582
535
|
check: "motionLiveness",
|
|
583
536
|
result: "unknown"
|
|
584
537
|
});
|
|
585
|
-
if (liveness.yawRange + liveness.pitchRange >=
|
|
538
|
+
if (liveness.yawRange + liveness.pitchRange >= 4) results.push({
|
|
586
539
|
check: "headMotion",
|
|
587
540
|
result: "passed"
|
|
588
541
|
});
|
|
@@ -695,7 +648,6 @@ function isApiNotConfigured(error) {
|
|
|
695
648
|
function generateEvidenceId(siteKey) {
|
|
696
649
|
return `ph_${(siteKey || "site").replace(/[^a-zA-Z0-9_-]/g, "").slice(0, 12)}_${randomUUID().replace(/-/g, "")}`;
|
|
697
650
|
}
|
|
698
|
-
|
|
699
651
|
//#endregion
|
|
700
652
|
//#region src/modules/personhood/personhoodSignals.ts
|
|
701
653
|
/**
|
|
@@ -773,12 +725,19 @@ async function safeGetDeviceInfo() {
|
|
|
773
725
|
return;
|
|
774
726
|
}
|
|
775
727
|
}
|
|
776
|
-
|
|
777
728
|
//#endregion
|
|
778
729
|
//#region src/modules/personhood/types.ts
|
|
779
730
|
const PERSONHOOD_ERROR_CODES = {
|
|
780
731
|
CAMERA_DENIED: "CAMERA_DENIED",
|
|
781
732
|
DETECTION_FAILED: "DETECTION_FAILED",
|
|
733
|
+
/**
|
|
734
|
+
* The OAuth2 token fetch (`POST /omni/oauth2/token`,
|
|
735
|
+
* client-credentials) failed — non-2xx, network error, or no
|
|
736
|
+
* `access_token` in the response. The flow halts before the user
|
|
737
|
+
* opens the camera so a misconfigured `clientId` / `clientSecret`
|
|
738
|
+
* surfaces immediately instead of walking them through a capture we
|
|
739
|
+
* can't authenticate the verify hop for.
|
|
740
|
+
*/
|
|
782
741
|
AUTH_TOKEN_FAILED: "AUTH_TOKEN_FAILED",
|
|
783
742
|
VERIFY_FAILED: "VERIFY_FAILED",
|
|
784
743
|
INJECTION_SUSPECTED: "INJECTION_SUSPECTED",
|
|
@@ -786,10 +745,13 @@ const PERSONHOOD_ERROR_CODES = {
|
|
|
786
745
|
TIMEOUT: "TIMEOUT",
|
|
787
746
|
UNKNOWN: "UNKNOWN"
|
|
788
747
|
};
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
748
|
+
/**
|
|
749
|
+
* Public machine value. Typed as `AnyStateMachine` for declaration file
|
|
750
|
+
* portability — mirrors the convention used by `selfieMachine` and the
|
|
751
|
+
* other Core modules. Type safety is enforced by the `setup()` config
|
|
752
|
+
* above, not by the exported binding.
|
|
753
|
+
*/
|
|
754
|
+
const personhoodMachine = setup({
|
|
793
755
|
types: {
|
|
794
756
|
context: {},
|
|
795
757
|
events: {},
|
|
@@ -851,6 +813,12 @@ const _personhoodMachine = setup({
|
|
|
851
813
|
});
|
|
852
814
|
return cleanup;
|
|
853
815
|
}),
|
|
816
|
+
/**
|
|
817
|
+
* Local verdict — the PRD's primary path. Runs entirely on-device, no
|
|
818
|
+
* network round-trip. Wrapped in `fromPromise` only so the machine can
|
|
819
|
+
* `invoke` it the same way it does an async actor; the body itself is
|
|
820
|
+
* synchronous and returns immediately.
|
|
821
|
+
*/
|
|
854
822
|
produceLocalVerdict: fromPromise(async ({ input }) => {
|
|
855
823
|
return produceLocalVerdict({
|
|
856
824
|
siteKey: input.config.siteKey,
|
|
@@ -860,6 +828,11 @@ const _personhoodMachine = setup({
|
|
|
860
828
|
liveness: input.liveness
|
|
861
829
|
});
|
|
862
830
|
}),
|
|
831
|
+
/**
|
|
832
|
+
* Server fallback — only reached when the on-device path is impossible
|
|
833
|
+
* (no camera, permission denied, browser unsupported). Integrators see
|
|
834
|
+
* the same verdict shape either way.
|
|
835
|
+
*/
|
|
863
836
|
requestServerFallback: fromPromise(async ({ input, signal }) => {
|
|
864
837
|
return requestServerFallbackVerdict({
|
|
865
838
|
siteKey: input.config.siteKey,
|
|
@@ -869,6 +842,21 @@ const _personhoodMachine = setup({
|
|
|
869
842
|
signal
|
|
870
843
|
});
|
|
871
844
|
}),
|
|
845
|
+
/**
|
|
846
|
+
* Mints the OAuth2 Bearer token (client-credentials grant) for the
|
|
847
|
+
* verify hop. Hits `POST /omni/oauth2/token` on the omni base, or —
|
|
848
|
+
* when `config.authBaseUrl` is set — the auth server's own
|
|
849
|
+
* `/oauth2/token` directly (see {@link fetchPersonhoodAuthToken}).
|
|
850
|
+
* Runs in parallel with the other init tasks (signals + Deepsight) so
|
|
851
|
+
* the network round-trip overlaps
|
|
852
|
+
* with the WASM and camera-permission work — token is available
|
|
853
|
+
* by the time the user finishes the capture and we need to
|
|
854
|
+
* verify. The fetched token is assigned into actor context
|
|
855
|
+
* (`context.token`) by `setTokenFromEvent` and threaded into the
|
|
856
|
+
* downstream `analyzeLiveness` and `verifyOnDevice` actors as an
|
|
857
|
+
* explicit input, isolated from the main `currentToken` other
|
|
858
|
+
* modules use and from any concurrent personhood instances.
|
|
859
|
+
*/
|
|
872
860
|
fetchToken: fromPromise(async ({ input, signal }) => {
|
|
873
861
|
return fetchPersonhoodAuthToken({
|
|
874
862
|
clientId: input.config.clientId,
|
|
@@ -878,6 +866,14 @@ const _personhoodMachine = setup({
|
|
|
878
866
|
signal
|
|
879
867
|
});
|
|
880
868
|
}),
|
|
869
|
+
/**
|
|
870
|
+
* On-device verify — POST `/omni/personhood/verify` with the
|
|
871
|
+
* Deepsight metadata + derived `spoofCheckResults`, returns the
|
|
872
|
+
* server's authoritative verdict. The local verdict from
|
|
873
|
+
* {@link produceLocalVerdict} is used as a fallback if the
|
|
874
|
+
* network call fails. This is what becomes the final
|
|
875
|
+
* `state.verdict` the UI / integrator sees.
|
|
876
|
+
*/
|
|
881
877
|
verifyOnDevice: fromPromise(async ({ input, signal }) => {
|
|
882
878
|
return verifyPersonhoodOnDevice({
|
|
883
879
|
metadata: input.liveness?.metadata ?? "",
|
|
@@ -899,6 +895,12 @@ const _personhoodMachine = setup({
|
|
|
899
895
|
};
|
|
900
896
|
}),
|
|
901
897
|
setDetectionStatus: assign({ detectionStatus: ({ event }) => event.status }),
|
|
898
|
+
/**
|
|
899
|
+
* Commits the final head-pose ranges reported by the detection callback
|
|
900
|
+
* into context. This happens ONCE at DETECTION_SUCCESS, not per-frame —
|
|
901
|
+
* keeping pose off the hot XState path prevents React re-renders on
|
|
902
|
+
* every detector frame.
|
|
903
|
+
*/
|
|
902
904
|
setCapturedImageAndRangeFromEvent: assign(({ event }) => {
|
|
903
905
|
const e = event;
|
|
904
906
|
return {
|
|
@@ -912,6 +914,14 @@ const _personhoodMachine = setup({
|
|
|
912
914
|
setResetDetection: assign({ resetDetection: ({ event }) => event.reset }),
|
|
913
915
|
setSignalsFromEvent: assign({ signals: ({ event }) => event.output }),
|
|
914
916
|
setTokenFromEvent: assign({ token: ({ event }) => event.output }),
|
|
917
|
+
/**
|
|
918
|
+
* Stash the local verdict from the `processing` step's actor
|
|
919
|
+
* output so the subsequent `verifyOnServer` step can use it as a
|
|
920
|
+
* fallback if the network call fails. The same event also drives
|
|
921
|
+
* `setVerdictFromEvent` (the existing action), but that one
|
|
922
|
+
* writes to `verdict` — which we DON'T want to set yet because
|
|
923
|
+
* the final verdict comes from the server.
|
|
924
|
+
*/
|
|
915
925
|
setLocalVerdictFromEvent: assign({ localVerdict: ({ event }) => event.output }),
|
|
916
926
|
setVerdictFromEvent: assign({ verdict: ({ event }) => event.output }),
|
|
917
927
|
setPermissionResultFromEvent: assign({ permissionResult: ({ event }) => event.output }),
|
|
@@ -920,6 +930,11 @@ const _personhoodMachine = setup({
|
|
|
920
930
|
error: () => ({ code: PERSONHOOD_ERROR_CODES.CAMERA_DENIED })
|
|
921
931
|
}),
|
|
922
932
|
setDetectionError: assign({ error: () => ({ code: PERSONHOOD_ERROR_CODES.DETECTION_FAILED }) }),
|
|
933
|
+
/**
|
|
934
|
+
* Records that the server-fallback path is being taken because the camera
|
|
935
|
+
* could not be initialized (no device / OS block), so the fallback verdict
|
|
936
|
+
* reports `no_camera` rather than the default `permission_denied`.
|
|
937
|
+
*/
|
|
923
938
|
setFallbackReasonNoCamera: assign({ fallbackReason: () => "no_camera" }),
|
|
924
939
|
setTokenError: assign({ error: ({ event }) => ({
|
|
925
940
|
code: PERSONHOOD_ERROR_CODES.AUTH_TOKEN_FAILED,
|
|
@@ -929,10 +944,21 @@ const _personhoodMachine = setup({
|
|
|
929
944
|
code: PERSONHOOD_ERROR_CODES.VERIFY_FAILED,
|
|
930
945
|
message: String(event.error ?? "verify failed")
|
|
931
946
|
}) }),
|
|
947
|
+
/**
|
|
948
|
+
* Local-synthesis failure — the deterministic on-device verdict
|
|
949
|
+
* computation threw. Distinct from `setVerifyError` which is for
|
|
950
|
+
* the server verify hop; the verify hop never even ran here.
|
|
951
|
+
*/
|
|
932
952
|
setLocalVerdictError: assign({ error: ({ event }) => ({
|
|
933
953
|
code: PERSONHOOD_ERROR_CODES.UNKNOWN,
|
|
934
954
|
message: String(event.error ?? "local verdict synthesis failed")
|
|
935
955
|
}) }),
|
|
956
|
+
/**
|
|
957
|
+
* Server verify hop failed unrecoverably — fall back to the local
|
|
958
|
+
* verdict the integrator can still trust. Named (vs. an inline
|
|
959
|
+
* `assign`) so the machine config stays consistent with
|
|
960
|
+
* `setup({ actions: { ... } })`'s typed-action contract.
|
|
961
|
+
*/
|
|
936
962
|
setVerdictToLocal: assign({ verdict: ({ context }) => context.localVerdict }),
|
|
937
963
|
stopMediaStream: assign(({ context }) => {
|
|
938
964
|
context.frameCapturer?.dispose();
|
|
@@ -1017,6 +1043,12 @@ const _personhoodMachine = setup({
|
|
|
1017
1043
|
guard: "hasShowTutorial"
|
|
1018
1044
|
}, { target: "collectingSignals" }] } },
|
|
1019
1045
|
tutorial: { on: { NEXT_STEP: { target: "collectingSignals" } } },
|
|
1046
|
+
/**
|
|
1047
|
+
* Two prep tasks run in parallel: collect device/behavioral signals and
|
|
1048
|
+
* boot the Deepsight session (PRC warmup). Both are needed before we
|
|
1049
|
+
* touch the camera; running them concurrently keeps the pre-capture
|
|
1050
|
+
* latency budget under the PRD's 1.5s p50 target.
|
|
1051
|
+
*/
|
|
1020
1052
|
collectingSignals: {
|
|
1021
1053
|
type: "parallel",
|
|
1022
1054
|
states: {
|
|
@@ -1054,6 +1086,20 @@ const _personhoodMachine = setup({
|
|
|
1054
1086
|
done: { type: "final" }
|
|
1055
1087
|
}
|
|
1056
1088
|
},
|
|
1089
|
+
/**
|
|
1090
|
+
* Third parallel branch — fetches the personhood session
|
|
1091
|
+
* token. Latency-overlap with signals + Deepsight init so
|
|
1092
|
+
* the network round-trip is "free" by the time the user
|
|
1093
|
+
* finishes capturing. The mock-verify path returns a
|
|
1094
|
+
* synthetic token without hitting the network, so this
|
|
1095
|
+
* branch only fails when a real backend was configured AND
|
|
1096
|
+
* the call genuinely failed (non-2xx, network error,
|
|
1097
|
+
* missing token in the response). In that case we record
|
|
1098
|
+
* the error and let the parallel `onDone` route the flow
|
|
1099
|
+
* to the terminal `error` state — there's no point opening
|
|
1100
|
+
* the camera if we know we can't authenticate the verify
|
|
1101
|
+
* hop afterwards.
|
|
1102
|
+
*/
|
|
1057
1103
|
token: {
|
|
1058
1104
|
initial: "running",
|
|
1059
1105
|
states: {
|
|
@@ -1190,6 +1236,12 @@ const _personhoodMachine = setup({
|
|
|
1190
1236
|
}
|
|
1191
1237
|
}
|
|
1192
1238
|
},
|
|
1239
|
+
/**
|
|
1240
|
+
* On-device liveness analysis — Deepsight virtual-camera check + pipeline
|
|
1241
|
+
* analysis + pose-motion range. Runs after a good capture but before we
|
|
1242
|
+
* synthesize the verdict, so {@link produceLocalVerdict} can fold these
|
|
1243
|
+
* signals in. This is the actual "local liveness" step per PRD #4.
|
|
1244
|
+
*/
|
|
1193
1245
|
analyzing: {
|
|
1194
1246
|
exit: "stopMediaStream",
|
|
1195
1247
|
invoke: {
|
|
@@ -1228,6 +1280,14 @@ const _personhoodMachine = setup({
|
|
|
1228
1280
|
actions: "setLocalVerdictError"
|
|
1229
1281
|
}
|
|
1230
1282
|
} },
|
|
1283
|
+
/**
|
|
1284
|
+
* On-device verify hop. Sends the Deepsight metadata + derived
|
|
1285
|
+
* `spoofCheckResults` to `/omni/personhood/verify` (authenticated
|
|
1286
|
+
* with `Authorization: Bearer <token>`) and uses the server's
|
|
1287
|
+
* response as the final verdict. Falls back to the local
|
|
1288
|
+
* verdict if the network call fails — better to deliver SOMETHING
|
|
1289
|
+
* than nothing, but a reachable backend always wins.
|
|
1290
|
+
*/
|
|
1231
1291
|
verifyingOnServer: { invoke: {
|
|
1232
1292
|
id: "verifyOnDevice",
|
|
1233
1293
|
src: "verifyOnDevice",
|
|
@@ -1246,6 +1306,12 @@ const _personhoodMachine = setup({
|
|
|
1246
1306
|
actions: "setVerdictToLocal"
|
|
1247
1307
|
}
|
|
1248
1308
|
} },
|
|
1309
|
+
/**
|
|
1310
|
+
* Server fallback path — only reached when on-device liveness can't run
|
|
1311
|
+
* (currently: after the user explicitly denies camera permission). The
|
|
1312
|
+
* network call is gated by `config.mockVerify` the same as the primary
|
|
1313
|
+
* path, so the dev demo works offline.
|
|
1314
|
+
*/
|
|
1249
1315
|
serverFallback: { invoke: {
|
|
1250
1316
|
id: "requestServerFallback",
|
|
1251
1317
|
src: "requestServerFallback",
|
|
@@ -1277,14 +1343,6 @@ const _personhoodMachine = setup({
|
|
|
1277
1343
|
}
|
|
1278
1344
|
}
|
|
1279
1345
|
});
|
|
1280
|
-
/**
|
|
1281
|
-
* Public machine value. Typed as `AnyStateMachine` for declaration file
|
|
1282
|
-
* portability — mirrors the convention used by `selfieMachine` and the
|
|
1283
|
-
* other Core modules. Type safety is enforced by the `setup()` config
|
|
1284
|
-
* above, not by the exported binding.
|
|
1285
|
-
*/
|
|
1286
|
-
const personhoodMachine = _personhoodMachine;
|
|
1287
|
-
|
|
1288
1346
|
//#endregion
|
|
1289
1347
|
//#region src/modules/personhood/personhoodActor.ts
|
|
1290
1348
|
/**
|
|
@@ -1311,7 +1369,6 @@ function createPersonhoodActor(options) {
|
|
|
1311
1369
|
dependencies
|
|
1312
1370
|
} }).start();
|
|
1313
1371
|
}
|
|
1314
|
-
|
|
1315
1372
|
//#endregion
|
|
1316
1373
|
//#region src/modules/personhood/personhoodManager.ts
|
|
1317
1374
|
/**
|
|
@@ -1418,32 +1475,44 @@ function mapState(snapshot) {
|
|
|
1418
1475
|
}
|
|
1419
1476
|
function createApi({ actor, trackElementClicked }) {
|
|
1420
1477
|
return {
|
|
1478
|
+
/** Starts the flow (goes to tutorial or capture depending on config). */
|
|
1421
1479
|
load() {
|
|
1422
1480
|
actor.send({ type: "LOAD" });
|
|
1423
1481
|
},
|
|
1482
|
+
/** Advances from tutorial → capture. */
|
|
1424
1483
|
nextStep() {
|
|
1425
1484
|
trackElementClicked?.("nextStep");
|
|
1426
1485
|
actor.send({ type: "NEXT_STEP" });
|
|
1427
1486
|
},
|
|
1487
|
+
/** Triggers `getUserMedia` when in `permissions.idle`. */
|
|
1428
1488
|
requestPermission() {
|
|
1429
1489
|
trackElementClicked?.("requestPermission");
|
|
1430
1490
|
actor.send({ type: "REQUEST_PERMISSION" });
|
|
1431
1491
|
},
|
|
1492
|
+
/** Shows the permission rationale view. */
|
|
1432
1493
|
goToLearnMore() {
|
|
1433
1494
|
trackElementClicked?.("goToLearnMore");
|
|
1434
1495
|
actor.send({ type: "GO_TO_LEARN_MORE" });
|
|
1435
1496
|
},
|
|
1497
|
+
/** Returns from learn-more → permission prompt. */
|
|
1436
1498
|
back() {
|
|
1437
1499
|
trackElementClicked?.("back");
|
|
1438
1500
|
actor.send({ type: "BACK" });
|
|
1439
1501
|
},
|
|
1502
|
+
/** Dismisses the widget into the terminal `closed` state. */
|
|
1440
1503
|
close() {
|
|
1441
1504
|
trackElementClicked?.("close");
|
|
1442
1505
|
actor.send({ type: "QUIT" });
|
|
1443
1506
|
},
|
|
1507
|
+
/** Resets from the (non-final) `error` state back to `idle`. */
|
|
1444
1508
|
reset() {
|
|
1445
1509
|
actor.send({ type: "RESET" });
|
|
1446
1510
|
},
|
|
1511
|
+
/**
|
|
1512
|
+
* Skip the on-device path and hit the server fallback. Wired to the
|
|
1513
|
+
* "Continue without camera" button on the permission-denied screen; also
|
|
1514
|
+
* dispatched automatically when the device has no camera at all.
|
|
1515
|
+
*/
|
|
1447
1516
|
useFallback() {
|
|
1448
1517
|
trackElementClicked?.("useFallback");
|
|
1449
1518
|
actor.send({ type: "USE_FALLBACK" });
|
|
@@ -1501,6 +1570,5 @@ function createPersonhoodManagerFromActor(actor) {
|
|
|
1501
1570
|
function createPersonhoodManager(options) {
|
|
1502
1571
|
return wrapActor(createPersonhoodActor(options));
|
|
1503
1572
|
}
|
|
1504
|
-
|
|
1505
1573
|
//#endregion
|
|
1506
|
-
export { PERSONHOOD_ERROR_CODES, createPersonhoodActor, createPersonhoodManager, createPersonhoodManagerFromActor, personhoodMachine };
|
|
1574
|
+
export { PERSONHOOD_ERROR_CODES, createPersonhoodActor, createPersonhoodManager, createPersonhoodManagerFromActor, personhoodMachine };
|
package/dist/phone.d.ts
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./Manager-goNPc_h_.js";
|
|
3
|
-
import "./Actor-BwgmOPkb.js";
|
|
4
|
-
import "./otp-B1YeyRXu.js";
|
|
5
|
-
import { n as PhoneState, o as phoneMachine, r as createPhoneManager, s as PhoneConfig, t as PhoneManager } from "./phoneManager-_KtitbUA.js";
|
|
1
|
+
import { n as PhoneState, o as phoneMachine, r as createPhoneManager, s as PhoneConfig, t as PhoneManager } from "./phoneManager-BBU8Lq0O.js";
|
|
6
2
|
export { type PhoneConfig, type PhoneManager, type PhoneState, createPhoneManager, phoneMachine };
|
package/dist/phone.esm.js
CHANGED
|
@@ -1,10 +1,3 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
|
|
4
|
-
import "./endpoints-CwrFQfW7.esm.js";
|
|
5
|
-
import "./xstate.esm-nY3M5UYm.esm.js";
|
|
6
|
-
import "./otp-uaXiKt_R.esm.js";
|
|
7
|
-
import { t as phoneMachine } from "./phoneStateMachine-DjFGWMjQ.esm.js";
|
|
8
|
-
import { t as createPhoneManager } from "./phoneManager-CRblfdcI.esm.js";
|
|
9
|
-
|
|
10
|
-
export { createPhoneManager, phoneMachine };
|
|
1
|
+
import { t as phoneMachine } from "./phoneStateMachine-E1fUUcNM.esm.js";
|
|
2
|
+
import { t as createPhoneManager } from "./phoneManager-Cpiai2IM.esm.js";
|
|
3
|
+
export { createPhoneManager, phoneMachine };
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as
|
|
3
|
-
import
|
|
4
|
-
|
|
1
|
+
import { i as ActorRefFrom } from "./spawn-D9jgw9pW.js";
|
|
2
|
+
import { t as Manager } from "./Manager-CQQ99QOI.js";
|
|
3
|
+
import "./Actor-iTq7YY48.js";
|
|
4
|
+
import { t as OtpValidationErrors } from "./otp-CEWfTj9v.js";
|
|
5
5
|
//#region src/modules/phone/types.d.ts
|
|
6
|
-
|
|
7
6
|
/**
|
|
8
7
|
* Configuration options for phone verification.
|
|
9
8
|
*
|
|
@@ -69,7 +68,6 @@ type PhoneValidationErrors = {
|
|
|
69
68
|
};
|
|
70
69
|
//#endregion
|
|
71
70
|
//#region src/modules/phone/phoneStateMachine.d.ts
|
|
72
|
-
|
|
73
71
|
declare const phoneMachine: any;
|
|
74
72
|
type PhoneMachine = typeof phoneMachine;
|
|
75
73
|
//#endregion
|
|
@@ -80,7 +78,6 @@ type CreatePhoneActorOptions = {
|
|
|
80
78
|
type PhoneActor = ActorRefFrom<PhoneMachine>;
|
|
81
79
|
//#endregion
|
|
82
80
|
//#region src/modules/phone/phoneManager.d.ts
|
|
83
|
-
|
|
84
81
|
/** Phone manager is in initial state, waiting for `load()` to be called */
|
|
85
82
|
type PhoneIdleState = {
|
|
86
83
|
status: 'idle';
|