@incodetech/core 2.4.1-agentic → 2.4.1-agentic.10
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/{BaseWasmProvider-Bq3OHo7P.d.ts → BaseWasmProvider-bBNquvYn.d.ts} +2 -2
- package/dist/BrowserNetworkStatusProvider-BrDXBEDd.esm.js +21 -0
- package/dist/{multipartRecordingService-DMBxHKS2.esm.js → CameraCompositor-DN7NkJzV.esm.js} +7 -734
- package/dist/DateFormattingProvider-DPq9zco-.esm.js +25 -0
- package/dist/{FaceDetectionProvider-B83VmClw.esm.js → FaceDetectionProvider-BSLpXAGx.esm.js} +11 -12
- package/dist/{IIdCaptureCapability-CGcEt2Cw.d.ts → IIdCaptureCapability-C-5M8pP1.d.ts} +2 -2
- package/dist/{IWasmUtilCapability-Cqiaxydi.d.ts → IWasmUtilCapability-BRn0wz8v.d.ts} +2 -2
- package/dist/MultipartRecordingProvider-BfQPSgSO.esm.js +151 -0
- package/dist/{StreamCanvasCapture-C3xNfOsv.d.ts → StreamCanvasCapture-ixfy84ys.d.ts} +2 -2
- package/dist/StreamCanvasProcessingSession-CBnbTnOr.esm.js +42 -0
- package/dist/{WasmUtilProvider-GTkoJyFY.esm.js → WasmUtilProvider-C_puwvVn.esm.js} +2 -2
- package/dist/WorkerEncoderRecordingProvider-CyCrQnZR.esm.js +80 -0
- package/dist/addressSearch-B_4JYKa-.esm.js +72 -0
- package/dist/ae-signature.esm.js +1 -1
- package/dist/antifraud.esm.js +2 -2
- package/dist/{antifraudManager-CQ08atTC.esm.js → antifraudManager-BWCVkSu2.esm.js} +2 -2
- package/dist/{antifraudStateMachine-BcsUTTIr.esm.js → antifraudStateMachine-CX9I2f3s.esm.js} +1 -1
- package/dist/{api-BO8JA7Pf.esm.js → api-BSnbg4HO.esm.js} +4 -0
- package/dist/{apiError-CfuIvnUy.esm.js → apiError-Bmwy1Fa7.esm.js} +1 -1
- package/dist/{attemptCarry-BjTJ6bMQ.esm.js → attemptCarry-zQH85Elh.esm.js} +2 -2
- package/dist/authentication.d.ts +3 -3
- package/dist/authentication.esm.js +2 -2
- package/dist/{authenticationManager-DvmklBTE.esm.js → authenticationManager-BoiOaB0m.esm.js} +5 -5
- package/dist/{authenticationManager-C-cOki0Y.d.ts → authenticationManager-CISxaY6N.d.ts} +1 -1
- package/dist/{authenticationStateMachine-BL2ptOA0.esm.js → authenticationStateMachine-BMD1JLwr.esm.js} +3 -3
- package/dist/avatar.d.ts +1 -1
- package/dist/backCameraLabel-yda5ugE4.esm.js +67 -0
- package/dist/{backCameraStream-C5_NNfUN.esm.js → backCameraStream-DS1oDiUq.esm.js} +10 -65
- package/dist/{browser-pQZA35G2-DtkAf6sn.esm.js → browser-pQZA35G2-PIj2uGBm.esm.js} +1 -1
- package/dist/camera.d.ts +2 -2
- package/dist/camera.esm.js +1 -1
- package/dist/certificate-issuance.esm.js +2 -2
- package/dist/{certificateIssuanceManager-CM0fuqDC.esm.js → certificateIssuanceManager-DzDuQTsK.esm.js} +2 -2
- package/dist/{certificateIssuanceStateMachine-kksIUOPD.esm.js → certificateIssuanceStateMachine-BAOYLACb.esm.js} +2 -2
- package/dist/{connectivity-HSl0diCx.esm.js → connectivity-BCuEoQ-n.esm.js} +2 -21
- package/dist/consent.d.ts +1 -1
- package/dist/consent.esm.js +2 -2
- package/dist/{consentManager-_q9yJUku.d.ts → consentManager-7aHaehwF.d.ts} +5 -5
- package/dist/{consentManager-CBwFozhv.esm.js → consentManager-DFSKQTcR.esm.js} +2 -2
- package/dist/{consentStateMachine-CpmRAcr2.esm.js → consentStateMachine-4nZIH2O8.esm.js} +1 -1
- package/dist/{cpf-uAZTPUBy.esm.js → cpf-BIADjddF.esm.js} +1 -25
- package/dist/{createFaceAvatar-lYX0VTYs.d.ts → createFaceAvatar-BimBTONm.d.ts} +1 -1
- package/dist/cross-document-data-match.esm.js +1 -1
- package/dist/{crossDocumentDataMatchManager-64O8t10a.esm.js → crossDocumentDataMatchManager-D7ka2qOC.esm.js} +2 -2
- package/dist/curp-validation.d.ts +1 -1
- package/dist/curp-validation.esm.js +2 -2
- package/dist/{curpValidationManager-CLgJQcx0.esm.js → curpValidationManager-BVTt7IgC.esm.js} +2 -2
- package/dist/{curpValidationManager-CXpFE-Mv.d.ts → curpValidationManager-DEqTUWdu.d.ts} +1 -1
- package/dist/{curpValidationStateMachine-Bx9YhVkJ.esm.js → curpValidationStateMachine-FB_MRbZQ.esm.js} +2 -2
- package/dist/custom-fields.esm.js +1 -1
- package/dist/custom-watchlist.esm.js +2 -2
- package/dist/{customFieldsManager-DWt_0YtJ.esm.js → customFieldsManager-gbsq53p6.esm.js} +2 -2
- package/dist/{customWatchlistManager-D8o-2Nej.esm.js → customWatchlistManager-50APwk4Z.esm.js} +2 -2
- package/dist/{customWatchlistStateMachine-Sbi6DIcK.esm.js → customWatchlistStateMachine-CpEVPzuT.esm.js} +1 -1
- package/dist/{deepsightService-twg3bXqY.esm.js → deepsightLoader-BKCT8UT1.esm.js} +34 -29
- package/dist/definitionSource-BHNxbuiv.esm.js +184 -0
- package/dist/{desktopCameraElection-kHY2IDJi.esm.js → desktopCameraElection-Dvvw7PRY.esm.js} +5 -5
- package/dist/document-capture.d.ts +3 -3
- package/dist/document-capture.esm.js +2 -2
- package/dist/{documentCaptureManager-CMSC_Mhd.esm.js → documentCaptureManager-BG5TuqJz.esm.js} +3 -2
- package/dist/{documentCaptureManager-6tnnDkMX.d.ts → documentCaptureManager-DDfviFg0.d.ts} +25 -4
- package/dist/{documentCaptureStateMachine-BCwD5Rto.esm.js → documentCaptureStateMachine-C7PW_Ah9.esm.js} +67 -26
- package/dist/dynamic-forms.esm.js +2 -2
- package/dist/{dynamicFormsManager-DU6W1e20.esm.js → dynamicFormsManager-B0bpHhhJ.esm.js} +2 -2
- package/dist/{dynamicFormsStateMachine-C8Z7k3vo.esm.js → dynamicFormsStateMachine-2ZHyejBc.esm.js} +2 -2
- package/dist/ekyb.d.ts +4 -4
- package/dist/ekyb.esm.js +3 -3
- package/dist/{ekybManager-TB6ZG5lX.d.ts → ekybManager-BLOkwmWO.d.ts} +2 -2
- package/dist/{ekybManager-TGfqyjuu.esm.js → ekybManager-P9mC7W9J.esm.js} +2 -2
- package/dist/{ekybStateMachine-DBgFuEPK.esm.js → ekybStateMachine-C7HKaeVr.esm.js} +7 -3
- 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 +3 -2
- package/dist/ekyc.esm.js +3 -3
- package/dist/{ekycManager-C2cgG2Pl.esm.js → ekycManager-CeeJoRFY.esm.js} +2 -2
- package/dist/{ekycManager-BSQteIfC.d.ts → ekycManager-q1fos6IY.d.ts} +2 -1
- package/dist/ekycPrefillManager-C6BFFKxc.esm.js +102 -0
- package/dist/ekycPrefillManager-PPGVZbWk.d.ts +565 -0
- package/dist/ekycPrefillStateMachine-Dku90kZL.esm.js +686 -0
- package/dist/ekycRules-BLX7Elcb.esm.js +319 -0
- package/dist/{ekycStateMachine-CuNF7z4O.esm.js → ekycStateMachine-DBTczgGE.esm.js} +719 -596
- package/dist/{ekycUtils-BFncpC4F.esm.js → ekycUtils-Dcff8BOD.esm.js} +103 -14
- package/dist/electronic-signature.esm.js +1 -1
- package/dist/{electronicSignatureManager-C7pqXsRm.esm.js → electronicSignatureManager-BKQuhJm_.esm.js} +4 -4
- package/dist/email.esm.js +2 -2
- package/dist/{emailManager-FH_CP0cT.esm.js → emailManager-CGmKbsBL.esm.js} +2 -2
- package/dist/{emailStateMachine-Cx-uTaBV.esm.js → emailStateMachine-CGY1UGs2.esm.js} +2 -2
- package/dist/{events-CQteqXfy.esm.js → events-C7h7oaTE.esm.js} +1 -1
- package/dist/events.esm.js +1 -1
- package/dist/extensibility.d.ts +20 -18
- package/dist/extensibility.esm.js +37 -35
- package/dist/{externalFetch-CQY41QT1.esm.js → externalFetch-cUjJYyXj.esm.js} +1 -1
- package/dist/face-match.d.ts +1 -1
- package/dist/face-match.esm.js +2 -2
- package/dist/{faceCaptureManagerFactory-C-xKdj-d.d.ts → faceCaptureManagerFactory-BVwVGa3z.d.ts} +7 -7
- package/dist/{faceCaptureManagerFactory-CBm05KnT.esm.js → faceCaptureManagerFactory-ClFsByZc.esm.js} +4 -4
- package/dist/{faceCaptureSetup-BQjCbL51.esm.js → faceCaptureSetup-9hv5GC_H.esm.js} +12 -403
- package/dist/{faceMatchManager-Z4UDLwAv.d.ts → faceMatchManager-BZtEw6bB.d.ts} +9 -3
- package/dist/{faceMatchManager-B2zp7yP4.esm.js → faceMatchManager-CRe7Nvm6.esm.js} +2 -2
- package/dist/{faceMatchStateMachine-ByTMQCUC.esm.js → faceMatchStateMachine-EX9QhxFE.esm.js} +28 -14
- package/dist/{feature-management-DjAG5lsJ.esm.js → feature-management-CmKTG_T5.esm.js} +35 -21
- package/dist/feature-management.esm.js +1 -1
- package/dist/field-comparison.esm.js +1 -1
- package/dist/{fieldComparisonManager-CC0vKmpf.esm.js → fieldComparisonManager-DuosZJso.esm.js} +2 -2
- package/dist/fiscal-qr.esm.js +1 -1
- package/dist/{fiscalQrManager-Be-r4oZj.esm.js → fiscalQrManager-ji0qDaTW.esm.js} +3 -3
- package/dist/flow-events.d.ts +1 -1
- package/dist/flow.d.ts +33 -18
- package/dist/flow.esm.js +82 -17
- package/dist/{flowCompletionService-ChMU2v79.esm.js → flowCompletionService-DvcH16XO.esm.js} +24 -3
- package/dist/{flowServices-g2tVWsJl.esm.js → flowServices-Ca2vKNt2.esm.js} +84 -139
- package/dist/geolocation.esm.js +2 -2
- package/dist/{geolocationManager-DLbvZwUB.esm.js → geolocationManager-CiG32lIm.esm.js} +2 -2
- package/dist/{geolocationStateMachine-CAJVongM.esm.js → geolocationStateMachine-5rnTEOuw.esm.js} +3 -3
- package/dist/government-validation.esm.js +2 -2
- package/dist/{governmentValidationManager-CkX9TEkh.esm.js → governmentValidationManager-BivVZNVe.esm.js} +2 -2
- package/dist/{governmentValidationStateMachine-PTPCP26N.esm.js → governmentValidationStateMachine-CeSDNgha.esm.js} +1 -1
- package/dist/home.d.ts +1 -1
- package/dist/home.esm.js +1 -1
- package/dist/http.esm.js +1 -1
- package/dist/id-ocr.d.ts +2 -2
- package/dist/id-ocr.esm.js +3 -19
- package/dist/id-selfie-flow.d.ts +3 -3
- package/dist/id-selfie-flow.esm.js +10 -9
- package/dist/id-verification.esm.js +2 -2
- package/dist/id.d.ts +4 -4
- package/dist/id.esm.js +4 -4
- package/dist/{idCaptureDefaults-MSQoqScU.esm.js → idCaptureDefaults-DBnOC28H.esm.js} +3 -3
- package/dist/{idCaptureManager-zZdTcpG1.esm.js → idCaptureManager-B5xqok0L.esm.js} +9 -8
- package/dist/{idCaptureManager-DzTfQ1Am.d.ts → idCaptureManager-CG8zbAp0.d.ts} +10 -8
- package/dist/{idCaptureServices-8OHinO0N.esm.js → idCaptureServices-BIF_7rub.esm.js} +27 -196
- package/dist/{idCaptureStateMachine-B3G6XoDG.esm.js → idCaptureStateMachine-B5cfgKvn.esm.js} +50 -22
- package/dist/idOcrCpfUtils-Nfln1Psb.esm.js +18 -0
- package/dist/{idOcrManager-DT3kPIB3.d.ts → idOcrManager-B5xeI2lg.d.ts} +3 -3
- package/dist/{idOcrManager-B64-fjWg.esm.js → idOcrManager-DNbVTMIu.esm.js} +2 -2
- package/dist/{idOcrStateMachine-B1aZnobs.esm.js → idOcrStateMachine-MAGnpWkb.esm.js} +8 -7
- package/dist/{idVerificationManager-_Kebv-Ue.esm.js → idVerificationManager-BEAkamNm.esm.js} +2 -2
- package/dist/{idVerificationStateMachine-DQn6c84z.esm.js → idVerificationStateMachine-D5mBN2Ye.esm.js} +1 -1
- package/dist/identity-reuse.esm.js +2 -2
- package/dist/{identityReuseManager-DDXkNVZi.esm.js → identityReuseManager-M8-BTjar.esm.js} +2 -2
- package/dist/{identityReuseStateMachine-Bcnkbjf8.esm.js → identityReuseStateMachine-D5bXgw9h.esm.js} +1 -1
- package/dist/{index-DEfwds5y.d.ts → index-Btj1EhiM.d.ts} +43 -19
- package/dist/{index-DMDAk85K.d.ts → index-CSPOoqah.d.ts} +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/{invokeOnCaptureCallback-CXIBwBeE.esm.js → invokeOnCaptureCallback-C1-j4fsq.esm.js} +1 -1
- package/dist/kyb-checks.d.ts +3 -0
- package/dist/kyb-checks.esm.js +3 -0
- package/dist/kybChecksManager-CblEL97E.d.ts +95 -0
- package/dist/kybChecksManager-CnqwgKoV.esm.js +89 -0
- package/dist/kybChecksStateMachine-Be41K_NS.esm.js +719 -0
- package/dist/mandatory-consent.d.ts +2 -2
- package/dist/mandatory-consent.esm.js +2 -2
- package/dist/{mandatoryConsentManager-xx3mY-xw.d.ts → mandatoryConsentManager-CYOJd_IZ.d.ts} +20 -11
- package/dist/{mandatoryConsentManager-43W5d_8G.esm.js → mandatoryConsentManager-LFhUlLvO.esm.js} +2 -2
- package/dist/{mandatoryConsentStateMachine-CVlgdlnt.esm.js → mandatoryConsentStateMachine-DTSyDqQs.esm.js} +11 -5
- package/dist/mediaRecorderOptions-B9-IEVtV.esm.js +70 -0
- package/dist/multipartRecordingService-CCiRpByl.esm.js +407 -0
- package/dist/{permissionGuards-B3OPL8Si.esm.js → permissionGuards-DjQUR1du.esm.js} +1 -1
- package/dist/{permissionServices-DnBAN_hW.esm.js → permissionServices-CZpORUWY.esm.js} +8 -6
- package/dist/phone.esm.js +2 -2
- package/dist/phoneFormat-DEpESpz2.esm.js +87 -0
- package/dist/{phoneManager-C6jut_pz.esm.js → phoneManager-C-qD3p3N.esm.js} +3 -3
- package/dist/phoneServices-BdR1nmSO.esm.js +77 -0
- package/dist/{phoneStateMachine-T1-drWfG.esm.js → phoneStateMachine-2FMTdjtJ.esm.js} +20 -60
- package/dist/{processFaceMatch-BWme3kVV.esm.js → processFaceMatch-B1YnoBer.esm.js} +1 -1
- package/dist/qe-signature.esm.js +1 -1
- package/dist/recordingService-BVSCo0ac.esm.js +397 -0
- package/dist/redirect-to-mobile.esm.js +2 -2
- package/dist/{redirectToMobileManager-BJXC6Kx9.esm.js → redirectToMobileManager-CqyDfDxs.esm.js} +3 -3
- package/dist/{redirectToMobileStateMachine-BBMAc2Gb.esm.js → redirectToMobileStateMachine-CXqfo2Gd.esm.js} +40 -22
- package/dist/resolveForm-f9PhUo9j.esm.js +143 -0
- package/dist/{runChildModule-DPHTqSdF.esm.js → runChildModule-BmteMhR7.esm.js} +2 -2
- package/dist/{sdkVersion-C3_P-Qbq.esm.js → sdkVersion-KZROt6l3.esm.js} +1 -1
- package/dist/selfie.d.ts +4 -4
- package/dist/selfie.esm.js +10 -10
- package/dist/{selfieErrorUtils-BL0BLMnp.esm.js → selfieErrorUtils-fqxp645p.esm.js} +1 -1
- package/dist/{selfieManager-Cbliomv7.esm.js → selfieManager-A-n3k9Tu.esm.js} +5 -5
- package/dist/{selfieManager-BMmpUii2.d.ts → selfieManager-DREuBhXZ.d.ts} +1 -1
- package/dist/{selfieStateMachine-B5m_Kn0O.esm.js → selfieStateMachine-48PKdKrw.esm.js} +3 -3
- package/dist/{session-DAaAewMX.esm.js → session-D0DWDKp9.esm.js} +4 -4
- package/dist/session.d.ts +2 -2
- package/dist/session.esm.js +6 -6
- package/dist/{sessionInitializer-CWFT4dfw.esm.js → sessionInitializer-I92b2dmL.esm.js} +94 -24
- package/dist/{setup-CDAKwTr7.esm.js → setup-BpjzWqR1.esm.js} +25 -27
- package/dist/{setup-D9qt8YVU.d.ts → setup-CG6oLkAa.d.ts} +2 -2
- package/dist/signature.esm.js +2 -2
- package/dist/{signatureManager-BeEVCcsC.esm.js → signatureManager-M9vQBj19.esm.js} +2 -2
- package/dist/{signatureStateMachine-_1c1vSid.esm.js → signatureStateMachine-0_frzAN5.esm.js} +1 -1
- package/dist/{stats-BpMz-hTP.esm.js → stats-C2sigf9p.esm.js} +1 -1
- package/dist/stats.esm.js +1 -1
- package/dist/step-up.d.ts +378 -0
- package/dist/step-up.esm.js +639 -0
- package/dist/textRules-D4NRinKY.d.ts +41 -0
- package/dist/{tri-BajQnjbf.esm.js → tri-DaUNvo-o.esm.js} +29 -34
- package/dist/tri.d.ts +2 -2
- package/dist/tri.esm-Df5eKLsY.esm.js +2165 -0
- package/dist/tri.esm.js +2 -2
- package/dist/{trueSightService-BujtUIW6.esm.js → trueSightService-DHYTBCIn.esm.js} +4 -4
- package/dist/trust-graph.esm.js +1 -1
- package/dist/types-B-PIc0en.d.ts +115 -0
- package/dist/{types-C397LhmN.d.ts → types-BgRHw-dR.d.ts} +1 -1
- package/dist/{types-CJ7Yl9K-.d.ts → types-Bpo97EOh.d.ts} +4 -2
- package/dist/{types-xEEWCx1j.d.ts → types-BqlZSoZ-.d.ts} +5 -5
- package/dist/types-CTaL0XJz.d.ts +80 -0
- package/dist/{types-e8fCsvvk.d.ts → types-Cbm9J2yF.d.ts} +1 -1
- package/dist/{types--3HDl2SF.d.ts → types-CgihAhT_.d.ts} +3 -3
- package/dist/{types-ZTZelfbM.d.ts → types-CyNndVAT.d.ts} +14 -6
- package/dist/{types-B2FK_wYb.d.ts → types-DEa3taWc.d.ts} +9 -41
- package/dist/{types-PTZHRhGX.d.ts → types-P9LzsfRo.d.ts} +3 -2
- package/dist/{types-DuD8TRJU.d.ts → types-TisHEbBg.d.ts} +12 -4
- package/dist/types-kLsU6Jkt.d.ts +6 -0
- package/dist/{urlUtils-eYiyWjh0.esm.js → urlUtils-B2wagB5v.esm.js} +14 -1
- package/dist/usStates-CwOQ2kAx.esm.js +209 -0
- package/dist/video-selfie.d.ts +5 -4
- package/dist/video-selfie.esm.js +9 -7
- package/dist/{videoSelfieCameraWarmer-DjkPpoj_.esm.js → videoSelfieCameraWarmer-CTOpqhov.esm.js} +16 -14
- package/dist/{videoSelfieStepDetector-RfSmlFFW.d.ts → videoSelfieStepDetector-4XE2QI5q.d.ts} +4 -4
- package/dist/virtualCameraCheck-eFOm2C9q.esm.js +27 -0
- package/dist/{warmup-BkfxQZsC.esm.js → warmup-9iKKNNuW.esm.js} +69 -20
- package/dist/{warmup-BO57syF6.d.ts → warmup-BNhIuURi.d.ts} +18 -2
- package/dist/wasm.d.ts +9 -3
- package/dist/wasm.esm.js +3 -3
- package/dist/{wasmDsFlagSync-BhU5H2oR.esm.js → wasmDsFlagSync-lRIgn5Ic.esm.js} +1 -1
- package/dist/{wasmWebClient-DTj9auyA.esm.js → wasmWebClient-C3v3s_4H.esm.js} +34 -19
- package/dist/watchlist-for-business.esm.js +2 -2
- package/dist/watchlist.esm.js +2 -2
- package/dist/{watchlistForBusinessManager-CVay6-9A.esm.js → watchlistForBusinessManager-C1S5y5yj.esm.js} +2 -2
- package/dist/{watchlistForBusinessStateMachine-DA6K5na4.esm.js → watchlistForBusinessStateMachine-Bj_hnoK5.esm.js} +1 -1
- package/dist/{watchlistManager-B8gQ_rw3.esm.js → watchlistManager-BpegtZbc.esm.js} +2 -2
- package/dist/{watchlistStateMachine-CSi_ZhtT.esm.js → watchlistStateMachine-Bgkh1gra.esm.js} +1 -1
- package/dist/workflow.d.ts +226 -41
- package/dist/workflow.esm.js +163 -67
- package/package.json +21 -5
- package/dist/addressSearch-41sMcnJk.esm.js +0 -604
- package/dist/deepsightLoader-DMxtowCm.esm.js +0 -33
- package/dist/tri.esm-CzTNi5Q_.esm.js +0 -3826
- package/dist/types-D9r3zRfY.d.ts +0 -6
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { t as getPhoneValidation } from "./phoneValidation-OggtfjRt.esm.js";
|
|
2
|
+
//#region src/shared/validators/textRules.ts
|
|
3
|
+
const CHARACTER_CLASSES = [
|
|
4
|
+
"letter",
|
|
5
|
+
"digit",
|
|
6
|
+
"space"
|
|
7
|
+
];
|
|
8
|
+
const CLASS_PATTERNS = {
|
|
9
|
+
letter: "\\p{L}\\p{M}",
|
|
10
|
+
digit: "0-9",
|
|
11
|
+
space: " "
|
|
12
|
+
};
|
|
13
|
+
const escapeForClass = (chars) => chars.replace(/[\\\]^-]/g, "\\$&");
|
|
14
|
+
const escapeForPattern = (chars) => chars.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
15
|
+
const NAME_REGEX = /^[\p{L}\p{M} '’-]+$/u;
|
|
16
|
+
/** `nameCharacters`: letters from any script, spaces, hyphens and apostrophes. */
|
|
17
|
+
function hasNameCharacters(value) {
|
|
18
|
+
return NAME_REGEX.test(value);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* `notFuture`: an ISO `YYYY-MM-DD` date on or before `today`, also ISO, in
|
|
22
|
+
* the user's calendar. A value that isn't an ISO date passes; the date input
|
|
23
|
+
* owns that.
|
|
24
|
+
*/
|
|
25
|
+
function isNotFuture(value, today) {
|
|
26
|
+
if (!/^\d{4}-\d{2}-\d{2}$/.test(value)) return true;
|
|
27
|
+
return value <= today;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* `maxAge`: an ISO `YYYY-MM-DD` date of birth at most `years` full years
|
|
31
|
+
* before `today`, also ISO, in the user's calendar. As in SDK1, someone turns
|
|
32
|
+
* a year older on their birthday. A value that isn't an ISO date passes; the
|
|
33
|
+
* date input owns that.
|
|
34
|
+
*/
|
|
35
|
+
function isWithinMaxAge(value, today, years) {
|
|
36
|
+
if (!/^\d{4}-\d{2}-\d{2}$/.test(value)) return true;
|
|
37
|
+
const [birthYear, birthMonthDay] = [value.slice(0, 4), value.slice(5)];
|
|
38
|
+
const [todayYear, todayMonthDay] = [today.slice(0, 4), today.slice(5)];
|
|
39
|
+
return Number(todayYear) - Number(birthYear) - (todayMonthDay < birthMonthDay ? 1 : 0) <= years;
|
|
40
|
+
}
|
|
41
|
+
/** `digitCount`: only the digits 0-9, with a count in `lengths` or between `min` and `max`. */
|
|
42
|
+
function hasDigitCount(value, count) {
|
|
43
|
+
if (!/^[0-9]+$/.test(value)) return false;
|
|
44
|
+
const { length } = value;
|
|
45
|
+
if (count.lengths) return count.lengths.includes(length);
|
|
46
|
+
return (count.min === void 0 || length >= count.min) && (count.max === void 0 || length <= count.max);
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* `allowedCharacters`: only characters from `classes`, plus any in `extra`.
|
|
50
|
+
* With `ascii`, `letter` means A-Z in either case instead of any script.
|
|
51
|
+
*/
|
|
52
|
+
function hasAllowedCharacters(value, classes, extra = "", ascii = false) {
|
|
53
|
+
const set = classes.map((c) => ascii && c === "letter" ? "A-Za-z" : CLASS_PATTERNS[c]).join("");
|
|
54
|
+
return new RegExp(`^[${set}${escapeForClass(extra)}]+$`, "u").test(value);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* `charTemplate`: the whole value matches one template, where `9` is a digit,
|
|
58
|
+
* `A` an uppercase letter A-Z and any other character stands for itself.
|
|
59
|
+
* `ignoreCase` also accepts lowercase letters and literals in either case.
|
|
60
|
+
*/
|
|
61
|
+
function matchesCharTemplate(value, templates, ignoreCase = false) {
|
|
62
|
+
return templates.some((template) => {
|
|
63
|
+
const pattern = [...template].map((char) => {
|
|
64
|
+
if (char === "9") return "[0-9]";
|
|
65
|
+
if (char === "A") return "[A-Z]";
|
|
66
|
+
return escapeForPattern(char);
|
|
67
|
+
}).join("");
|
|
68
|
+
return new RegExp(`^${pattern}$`, ignoreCase ? "iu" : "u").test(value);
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
/** `numericRange`: a whole number from `min` to `max`. */
|
|
72
|
+
function isInNumericRange(value, min, max) {
|
|
73
|
+
if (!/^-?[0-9]+$/.test(value)) return false;
|
|
74
|
+
const number = Number(value);
|
|
75
|
+
return number >= min && number <= max;
|
|
76
|
+
}
|
|
77
|
+
//#endregion
|
|
78
|
+
//#region src/shared/phoneFormat.ts
|
|
79
|
+
/**
|
|
80
|
+
* The phone in E.164, or the value as typed when the rules are not loaded
|
|
81
|
+
* (`loadPhoneValidation()`) or the number is not valid.
|
|
82
|
+
*/
|
|
83
|
+
function formatPhoneE164(phone, country) {
|
|
84
|
+
return getPhoneValidation()?.formatE164(phone, country) ?? phone;
|
|
85
|
+
}
|
|
86
|
+
//#endregion
|
|
87
|
+
export { hasNameCharacters as a, isWithinMaxAge as c, hasDigitCount as i, matchesCharTemplate as l, CHARACTER_CLASSES as n, isInNumericRange as o, hasAllowedCharacters as r, isNotFuture as s, formatPhoneE164 as t };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-
|
|
2
|
-
import { s as createActor, u as createManager } from "./xstate.esm-DSajW7CJ.esm.js";
|
|
1
|
+
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-C7h7oaTE.esm.js";
|
|
3
2
|
import { n as loadPhoneValidation, t as getPhoneValidation } from "./phoneValidation-OggtfjRt.esm.js";
|
|
3
|
+
import { s as createActor, u as createManager } from "./xstate.esm-DSajW7CJ.esm.js";
|
|
4
4
|
import { n as isOtpComplete } from "./otp-D2k3PeSL.esm.js";
|
|
5
|
-
import { t as phoneMachine } from "./phoneStateMachine-
|
|
5
|
+
import { t as phoneMachine } from "./phoneStateMachine-2FMTdjtJ.esm.js";
|
|
6
6
|
//#region src/modules/phone/phoneActor.ts
|
|
7
7
|
function createPhoneActor(options) {
|
|
8
8
|
return createActor(phoneMachine, { input: { config: options.config } }).start();
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { r as getToken, t as api, u as endpoints } from "./api-BSnbg4HO.esm.js";
|
|
2
|
+
//#region src/modules/phone/phoneServices.ts
|
|
3
|
+
function getPhoneServerFailureReason(error, invalidStatus) {
|
|
4
|
+
if (error.status === invalidStatus) return "invalidPhone";
|
|
5
|
+
return "serverError";
|
|
6
|
+
}
|
|
7
|
+
async function fetchPhone(signal) {
|
|
8
|
+
const res = await api.get(endpoints.getPhone, { signal });
|
|
9
|
+
if (!res.ok) throw new Error(`GET ${endpoints.getPhone} failed: ${res.status} ${res.statusText}`);
|
|
10
|
+
return res.data;
|
|
11
|
+
}
|
|
12
|
+
async function requestStartInfo(signal) {
|
|
13
|
+
const res = await api.get(endpoints.startInfo, { signal });
|
|
14
|
+
if (!res.ok) throw new Error(`GET ${endpoints.startInfo} failed: ${res.status} ${res.statusText}`);
|
|
15
|
+
return res.data;
|
|
16
|
+
}
|
|
17
|
+
let prefetchedStartInfo;
|
|
18
|
+
/**
|
|
19
|
+
* Starts the start-info request before the phone step runs (the flow calls
|
|
20
|
+
* it when the step is first), so the step's first screen does not wait for
|
|
21
|
+
* that round trip. The step's own `fetchStartInfo` uses the answer once.
|
|
22
|
+
*/
|
|
23
|
+
function prefetchStartInfo() {
|
|
24
|
+
const token = getToken();
|
|
25
|
+
if (!token || prefetchedStartInfo?.token === token) return;
|
|
26
|
+
const promise = requestStartInfo();
|
|
27
|
+
promise.catch(() => void 0);
|
|
28
|
+
prefetchedStartInfo = {
|
|
29
|
+
token,
|
|
30
|
+
promise
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
async function fetchStartInfo(signal) {
|
|
34
|
+
const prefetched = prefetchedStartInfo;
|
|
35
|
+
prefetchedStartInfo = void 0;
|
|
36
|
+
if (prefetched?.token === getToken()) {
|
|
37
|
+
const info = await prefetched.promise.catch(() => void 0);
|
|
38
|
+
if (info) return info;
|
|
39
|
+
}
|
|
40
|
+
return requestStartInfo(signal);
|
|
41
|
+
}
|
|
42
|
+
async function addPhone(params, signal) {
|
|
43
|
+
try {
|
|
44
|
+
return (await api.post(endpoints.phone, {
|
|
45
|
+
phone: params.phone,
|
|
46
|
+
optInGranted: params.optInGranted
|
|
47
|
+
}, { signal })).data;
|
|
48
|
+
} catch (error) {
|
|
49
|
+
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
async function addPhoneInstantVerify(params, signal) {
|
|
53
|
+
try {
|
|
54
|
+
return (await api.post(endpoints.phoneInstant, {
|
|
55
|
+
phone: params.phone,
|
|
56
|
+
optInGranted: params.optInGranted
|
|
57
|
+
}, { signal })).data;
|
|
58
|
+
} catch (error) {
|
|
59
|
+
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
async function sendOtp(signal) {
|
|
63
|
+
try {
|
|
64
|
+
await api.get(`${endpoints.sendSmsOtp}?communicationchannel=SMS`, { signal });
|
|
65
|
+
} catch (error) {
|
|
66
|
+
throw new Error(getPhoneServerFailureReason(error));
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
async function verifyOtp(code, signal) {
|
|
70
|
+
try {
|
|
71
|
+
return (await api.get(`${endpoints.compareOtp}?code=${code}&channel=SMS`, { signal })).data;
|
|
72
|
+
} catch (error) {
|
|
73
|
+
throw new Error(getPhoneServerFailureReason(error));
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
//#endregion
|
|
77
|
+
export { prefetchStartInfo as a, fetchStartInfo as i, addPhoneInstantVerify as n, sendOtp as o, fetchPhone as r, verifyOtp as s, addPhone as t };
|
|
@@ -1,60 +1,10 @@
|
|
|
1
|
-
import { t as api, u as endpoints } from "./api-BO8JA7Pf.esm.js";
|
|
2
1
|
import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
|
|
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-BdR1nmSO.esm.js";
|
|
3
4
|
import { i as assign, t as setup } from "./xstate.esm-DSajW7CJ.esm.js";
|
|
4
5
|
import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-8Gzepa_A.esm.js";
|
|
5
|
-
import { t as carryAttempts } from "./attemptCarry-
|
|
6
|
-
import { n as loadPhoneValidation } from "./phoneValidation-OggtfjRt.esm.js";
|
|
6
|
+
import { t as carryAttempts } from "./attemptCarry-zQH85Elh.esm.js";
|
|
7
7
|
import { n as isOtpComplete, t as computeOtpValidationErrors } from "./otp-D2k3PeSL.esm.js";
|
|
8
|
-
//#region src/modules/phone/phoneServices.ts
|
|
9
|
-
function getPhoneServerFailureReason(error, invalidStatus) {
|
|
10
|
-
if (error.status === invalidStatus) return "invalidPhone";
|
|
11
|
-
return "serverError";
|
|
12
|
-
}
|
|
13
|
-
async function fetchPhone(signal) {
|
|
14
|
-
const res = await api.get(endpoints.getPhone, { signal });
|
|
15
|
-
if (!res.ok) throw new Error(`GET ${endpoints.getPhone} failed: ${res.status} ${res.statusText}`);
|
|
16
|
-
return res.data;
|
|
17
|
-
}
|
|
18
|
-
async function fetchStartInfo(signal) {
|
|
19
|
-
const res = await api.get(endpoints.startInfo, { signal });
|
|
20
|
-
if (!res.ok) throw new Error(`GET ${endpoints.startInfo} failed: ${res.status} ${res.statusText}`);
|
|
21
|
-
return res.data;
|
|
22
|
-
}
|
|
23
|
-
async function addPhone(params, signal) {
|
|
24
|
-
try {
|
|
25
|
-
return (await api.post(endpoints.phone, {
|
|
26
|
-
phone: params.phone,
|
|
27
|
-
optInGranted: params.optInGranted
|
|
28
|
-
}, { signal })).data;
|
|
29
|
-
} catch (error) {
|
|
30
|
-
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
async function addPhoneInstantVerify(params, signal) {
|
|
34
|
-
try {
|
|
35
|
-
return (await api.post(endpoints.phoneInstant, {
|
|
36
|
-
phone: params.phone,
|
|
37
|
-
optInGranted: params.optInGranted
|
|
38
|
-
}, { signal })).data;
|
|
39
|
-
} catch (error) {
|
|
40
|
-
throw new Error(getPhoneServerFailureReason(error, 400));
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
async function sendOtp(signal) {
|
|
44
|
-
try {
|
|
45
|
-
await api.get(`${endpoints.sendSmsOtp}?communicationchannel=SMS`, { signal });
|
|
46
|
-
} catch (error) {
|
|
47
|
-
throw new Error(getPhoneServerFailureReason(error));
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
async function verifyOtp(code, signal) {
|
|
51
|
-
try {
|
|
52
|
-
return (await api.get(`${endpoints.compareOtp}?code=${code}&channel=SMS`, { signal })).data;
|
|
53
|
-
} catch (error) {
|
|
54
|
-
throw new Error(getPhoneServerFailureReason(error));
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
//#endregion
|
|
58
8
|
//#region src/modules/phone/phoneStateMachine.ts
|
|
59
9
|
const RESEND_TIMER_SECONDS = 30;
|
|
60
10
|
function getErrorMessage(error) {
|
|
@@ -149,6 +99,7 @@ const phoneMachine = setup({
|
|
|
149
99
|
setOptInGranted: assign(({ event }) => ({ optInGranted: event.granted })),
|
|
150
100
|
setError: assign(({ event }) => ({ error: getErrorMessage(event.error) })),
|
|
151
101
|
clearError: assign({ error: () => void 0 }),
|
|
102
|
+
settleLoad: assign({ pendingLoads: ({ context }) => context.pendingLoads - 1 }),
|
|
152
103
|
clearPhoneError: assign({ phoneError: () => void 0 }),
|
|
153
104
|
setOtpCode: assign(({ event }) => ({
|
|
154
105
|
otpCode: event.code,
|
|
@@ -191,6 +142,7 @@ const phoneMachine = setup({
|
|
|
191
142
|
prefilledPhone: void 0,
|
|
192
143
|
optInGranted: false,
|
|
193
144
|
startInfo: void 0,
|
|
145
|
+
pendingLoads: 0,
|
|
194
146
|
error: void 0,
|
|
195
147
|
otpCode: "",
|
|
196
148
|
otpError: void 0,
|
|
@@ -202,6 +154,7 @@ const phoneMachine = setup({
|
|
|
202
154
|
},
|
|
203
155
|
guards: {
|
|
204
156
|
hasPrefill: ({ context }) => context.config.prefill,
|
|
157
|
+
areLoadsSettled: ({ context }) => context.pendingLoads === 0,
|
|
205
158
|
hasOtpVerification: ({ context }) => context.config.otpVerification,
|
|
206
159
|
hasNoValidationErrors: ({ context }) => !context.validationErrors || Object.keys(context.validationErrors).length === 0,
|
|
207
160
|
hasAttemptsRemaining: ({ context }) => context.attemptsRemaining > 1,
|
|
@@ -224,6 +177,7 @@ const phoneMachine = setup({
|
|
|
224
177
|
prefilledPhone: void 0,
|
|
225
178
|
optInGranted: false,
|
|
226
179
|
startInfo: void 0,
|
|
180
|
+
pendingLoads: 0,
|
|
227
181
|
error: void 0,
|
|
228
182
|
otpCode: "",
|
|
229
183
|
otpError: void 0,
|
|
@@ -247,15 +201,21 @@ const phoneMachine = setup({
|
|
|
247
201
|
{ target: "loadingStartInfo" }
|
|
248
202
|
] } },
|
|
249
203
|
loadingPrefill: {
|
|
250
|
-
entry: "startLoadingPhoneRules",
|
|
251
|
-
invoke: {
|
|
204
|
+
entry: ["startLoadingPhoneRules", assign({ pendingLoads: () => 2 })],
|
|
205
|
+
invoke: [{
|
|
252
206
|
id: "fetchPhone",
|
|
253
207
|
src: "fetchPhone",
|
|
254
|
-
onDone: {
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
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"
|
|
259
219
|
}
|
|
260
220
|
},
|
|
261
221
|
loadingStartInfo: {
|
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-BKQuhJm_.esm.js";
|
|
2
2
|
//#region src/modules/qe-signature/index.ts
|
|
3
3
|
function createQeSignatureManager(options) {
|
|
4
4
|
return createElectronicSignatureManager({ config: {
|