@incodetech/core 2.4.0 → 2.4.1-agentic.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.
Files changed (252) hide show
  1. package/dist/BrowserNetworkStatusProvider-BrDXBEDd.esm.js +21 -0
  2. package/dist/{multipartRecordingService-CLwrF5wD.esm.js → CameraCompositor-DN7NkJzV.esm.js} +7 -744
  3. package/dist/{FaceDetectionProvider-DcPOC2gS.esm.js → FaceDetectionProvider-CAY43vSI.esm.js} +28 -64
  4. package/dist/IBrowserEnvironmentCapability-D7JG7ML3.esm.js +16 -0
  5. package/dist/IGeolocationCapability-r49Qo7rR.d.ts +10 -0
  6. package/dist/{IWasmUtilCapability-GF2n7sfm.d.ts → IWasmUtilCapability-Cqiaxydi.d.ts} +31 -4
  7. package/dist/MultipartRecordingProvider-D9mauUdS.esm.js +146 -0
  8. package/dist/{PhoneValidationProvider-SZiOS0jB.esm.js → PhoneValidationProvider-Co4zk2en.esm.js} +7 -0
  9. package/dist/{StreamCanvasCapture-7JRf-2ck.d.ts → StreamCanvasCapture-C3xNfOsv.d.ts} +12 -3
  10. package/dist/StreamCanvasProcessingSession-CBnbTnOr.esm.js +42 -0
  11. package/dist/{WasmUtilProvider-DtJuBdt-.esm.js → WasmUtilProvider-Dp2V-Uct.esm.js} +75 -22
  12. package/dist/WorkerEncoderRecordingProvider-B1ODYtgN.esm.js +80 -0
  13. package/dist/addressSearch-DzbE9Ogt.esm.js +254 -0
  14. package/dist/{advanceableErrors-q_pfU3Cn.esm.js → advanceableErrors-k-U-cL5m.esm.js} +1 -2
  15. package/dist/ae-signature.esm.js +1 -1
  16. package/dist/antifraud.esm.js +2 -2
  17. package/dist/{antifraudManager-CaweCYnY.esm.js → antifraudManager-BObuHBjn.esm.js} +2 -2
  18. package/dist/{antifraudStateMachine-DRl0UVyA.esm.js → antifraudStateMachine-Dfrd2-26.esm.js} +1 -1
  19. package/dist/{api-Cz90EHyu.esm.js → api-CpP4PS4S.esm.js} +8 -5
  20. package/dist/{apiError-DPwFas2f.esm.js → apiError-DH-CH4Nz.esm.js} +1 -1
  21. package/dist/attemptCarry-WOkfvFMw.esm.js +45 -0
  22. package/dist/authentication.d.ts +3 -3
  23. package/dist/authentication.esm.js +2 -2
  24. package/dist/{authenticationManager-BIZC55Bi.d.ts → authenticationManager-CWmh7aSY.d.ts} +1 -1
  25. package/dist/{authenticationManager-2Lr5V_7p.esm.js → authenticationManager-DjX0XDyH.esm.js} +5 -5
  26. package/dist/{authenticationStateMachine-C99B0GFP.esm.js → authenticationStateMachine-BMbZL8wm.esm.js} +3 -3
  27. package/dist/backCameraLabel-yda5ugE4.esm.js +67 -0
  28. package/dist/{backCameraStream-CMvXj4X4.esm.js → backCameraStream-DS1oDiUq.esm.js} +12 -107
  29. package/dist/{browser-DlFgHpoC-DnyrCR8r.esm.js → browser-pQZA35G2-DtkAf6sn.esm.js} +161 -150
  30. package/dist/{camera-sIa9ceW2.esm.js → camera-E_Kcre4O.esm.js} +15 -23
  31. package/dist/camera.d.ts +2 -2
  32. package/dist/camera.esm.js +1 -1
  33. package/dist/certificate-issuance.esm.js +2 -2
  34. package/dist/{certificateIssuanceManager-BfeMv2PU.esm.js → certificateIssuanceManager-C1nETQos.esm.js} +2 -2
  35. package/dist/{certificateIssuanceStateMachine-Frgjbjw8.esm.js → certificateIssuanceStateMachine-DThXMDqr.esm.js} +2 -2
  36. package/dist/cnpj-Co1ottYN.esm.js +77 -0
  37. package/dist/connectivity-BCuEoQ-n.esm.js +114 -0
  38. package/dist/consent.d.ts +1 -1
  39. package/dist/consent.esm.js +2 -2
  40. package/dist/{consentManager-CvEu8h_W.esm.js → consentManager-DMlSL6Ax.esm.js} +4 -3
  41. package/dist/{consentManager-Cv_0QKLD.d.ts → consentManager-bjfVXO7p.d.ts} +9 -2
  42. package/dist/{consentStateMachine-DJTgN_-1.esm.js → consentStateMachine-DIYSMxKQ.esm.js} +20 -7
  43. package/dist/cross-document-data-match.esm.js +1 -1
  44. package/dist/{crossDocumentDataMatchManager-Cu141CE8.esm.js → crossDocumentDataMatchManager-BFTdiEDB.esm.js} +2 -2
  45. package/dist/curp-validation.d.ts +1 -1
  46. package/dist/curp-validation.esm.js +2 -2
  47. package/dist/{curpValidationManager-B-z9q5V3.esm.js → curpValidationManager-DNpC3wyf.esm.js} +3 -2
  48. package/dist/{curpValidationManager-C9sqoh9n.d.ts → curpValidationManager-z8428oCM.d.ts} +1 -1
  49. package/dist/{curpValidationStateMachine-vDEFLMPw.esm.js → curpValidationStateMachine-B3iVsDyt.esm.js} +28 -20
  50. package/dist/custom-fields.esm.js +1 -1
  51. package/dist/custom-watchlist.esm.js +2 -2
  52. package/dist/{customFieldsManager-D1ex2cFM.esm.js → customFieldsManager-CvI-pDT3.esm.js} +2 -2
  53. package/dist/{customWatchlistManager-CTI-SGk0.esm.js → customWatchlistManager-BuHtUb0y.esm.js} +2 -2
  54. package/dist/{customWatchlistStateMachine-hmRd0f2I.esm.js → customWatchlistStateMachine-CiVD9wyF.esm.js} +1 -1
  55. package/dist/{deepsightService-CKTYDIXD.esm.js → deepsightLoader-B7DEYoyY.esm.js} +40 -74
  56. package/dist/{createCameraCycleOwnership-Dj_LHUvN.esm.js → desktopCameraElection-BGMtYwk3.esm.js} +177 -40
  57. package/dist/device.esm.js +2 -2
  58. package/dist/document-capture.d.ts +3 -3
  59. package/dist/document-capture.esm.js +2 -2
  60. package/dist/{documentCaptureManager-DkyDtm3Y.d.ts → documentCaptureManager-CD5iQiUI.d.ts} +37 -4
  61. package/dist/{documentCaptureManager-DUJwpKC5.esm.js → documentCaptureManager-DLPqruXJ.esm.js} +27 -19
  62. package/dist/{documentCaptureStateMachine-B8i7GnLh.esm.js → documentCaptureStateMachine-DCvWQhFG.esm.js} +105 -56
  63. package/dist/dynamic-forms.d.ts +2 -2
  64. package/dist/dynamic-forms.esm.js +2 -2
  65. package/dist/{dynamicFormsManager-C0dHs1ty.d.ts → dynamicFormsManager-9kwY8Bf5.d.ts} +1 -1
  66. package/dist/{dynamicFormsManager-DiKYjcF3.esm.js → dynamicFormsManager-DfqCEPg9.esm.js} +2 -2
  67. package/dist/{dynamicFormsStateMachine-DEI45xYW.esm.js → dynamicFormsStateMachine-USQMB-uV.esm.js} +2 -2
  68. package/dist/ekyb.d.ts +4 -4
  69. package/dist/ekyb.esm.js +3 -3
  70. package/dist/{ekybManager-BaZ_7CEu.d.ts → ekybManager-BLOkwmWO.d.ts} +2 -2
  71. package/dist/{ekybManager-8WLkNcqg.esm.js → ekybManager-CR8YSYux.esm.js} +2 -2
  72. package/dist/{ekybStateMachine-BLRT45Ex.esm.js → ekybStateMachine-kHwdz6hm.esm.js} +28 -44
  73. package/dist/ekybUtils-Cw8Ta9Qi.esm.js +140 -0
  74. package/dist/ekyc.d.ts +4 -3
  75. package/dist/ekyc.esm.js +3 -3
  76. package/dist/{ekycManager-DW-ynodd.d.ts → ekycManager-DlGIn9wA.d.ts} +2 -1
  77. package/dist/{ekycManager-BO-Lui3t.esm.js → ekycManager-DymCvmVB.esm.js} +2 -2
  78. package/dist/ekycStateMachine-CoFCUJ2z.esm.js +7578 -0
  79. package/dist/ekycUtils-GRuMELYr.esm.js +1472 -0
  80. package/dist/electronic-signature.esm.js +1 -1
  81. package/dist/{electronicSignatureManager-CcIMOb_Y.esm.js → electronicSignatureManager-BCE3uA3z.esm.js} +4 -4
  82. package/dist/email.esm.js +2 -2
  83. package/dist/{emailManager-ButFktRm.esm.js → emailManager-CGoE3CUe.esm.js} +2 -2
  84. package/dist/{emailStateMachine-BXtlC0NV.esm.js → emailStateMachine-KgHfDNvM.esm.js} +32 -20
  85. package/dist/{events-Du2A4-Qr.esm.js → events-ggpBBaZ8.esm.js} +2 -2
  86. package/dist/events.esm.js +1 -1
  87. package/dist/extensibility.d.ts +37 -22
  88. package/dist/extensibility.esm.js +36 -35
  89. package/dist/{externalFetch-DrR9xshk.esm.js → externalFetch-CQY41QT1.esm.js} +4 -1
  90. package/dist/face-match.d.ts +1 -1
  91. package/dist/face-match.esm.js +2 -2
  92. package/dist/{faceCaptureManagerFactory-1hzeS_rB.d.ts → faceCaptureManagerFactory-DV2ULUYS.d.ts} +71 -66
  93. package/dist/{faceCaptureManagerFactory-BlGvXzXA.esm.js → faceCaptureManagerFactory-Dp90bedH.esm.js} +4 -4
  94. package/dist/{faceCaptureSetup-TY8RXc2N.esm.js → faceCaptureSetup-ZfiWg0fo.esm.js} +84 -457
  95. package/dist/{faceMatchManager-DWFUQjMQ.esm.js → faceMatchManager-D2xKPjjQ.esm.js} +2 -2
  96. package/dist/{faceMatchManager-DIgG-UFS.d.ts → faceMatchManager-Z4UDLwAv.d.ts} +16 -7
  97. package/dist/{faceMatchStateMachine-CUCvlydD.esm.js → faceMatchStateMachine-CUvwiQi9.esm.js} +40 -27
  98. package/dist/{feature-management-B5rR10uS.esm.js → feature-management-BbCIA4og.esm.js} +35 -21
  99. package/dist/feature-management.esm.js +1 -1
  100. package/dist/field-comparison.esm.js +1 -1
  101. package/dist/{fieldComparisonManager-v3knTYV_.esm.js → fieldComparisonManager-DgDbEeFZ.esm.js} +2 -2
  102. package/dist/fiscal-qr.esm.js +1 -1
  103. package/dist/{fiscalQrManager-Dt9fHG7h.esm.js → fiscalQrManager-BZeklojR.esm.js} +4 -4
  104. package/dist/flow-events.d.ts +1 -1
  105. package/dist/flow.d.ts +10 -10
  106. package/dist/flow.esm.js +10 -9
  107. package/dist/{flowCompletionService-BDI5QpfR.esm.js → flowCompletionService-CcCnPs_T.esm.js} +2 -2
  108. package/dist/{flowServices-roD0oIQL.esm.js → flowServices-Dmnc8Rye.esm.js} +69 -185
  109. package/dist/geolocation.d.ts +1 -1
  110. package/dist/geolocation.esm.js +2 -2
  111. package/dist/{geolocationManager-Dn24g1fl.d.ts → geolocationManager-6e1i9UIR.d.ts} +15 -17
  112. package/dist/{geolocationManager-DnONzWL5.esm.js → geolocationManager-BJJ3m_I8.esm.js} +6 -8
  113. package/dist/{geolocationStateMachine-eWy_G4Os.esm.js → geolocationStateMachine-CTI3m4Ie.esm.js} +12 -8
  114. package/dist/{getDeviceClass-bsWdEDxP.esm.js → getDeviceClass-DoIWuKI8.esm.js} +1 -1
  115. package/dist/government-validation.esm.js +2 -2
  116. package/dist/{governmentValidationManager-BtXWHICu.esm.js → governmentValidationManager-CjChjZ3C.esm.js} +2 -2
  117. package/dist/{governmentValidationStateMachine-COL-Vs48.esm.js → governmentValidationStateMachine-AEbn3Afi.esm.js} +1 -1
  118. package/dist/home.d.ts +1 -1
  119. package/dist/home.esm.js +1 -1
  120. package/dist/http.esm.js +1 -1
  121. package/dist/id-ocr.d.ts +1 -1
  122. package/dist/id-ocr.esm.js +2 -2
  123. package/dist/id-selfie-flow.d.ts +1 -1
  124. package/dist/id-selfie-flow.esm.js +10 -9
  125. package/dist/id-verification.esm.js +2 -2
  126. package/dist/id.d.ts +3 -16
  127. package/dist/id.esm.js +4 -4
  128. package/dist/{idCaptureDefaults-BGsG2OAs.esm.js → idCaptureDefaults-Dszuq9ng.esm.js} +3 -3
  129. package/dist/{idCaptureManager-BrfYjCm_.esm.js → idCaptureManager-B3oR4RnA.esm.js} +64 -17
  130. package/dist/{idCaptureManager-0M02hSuC.d.ts → idCaptureManager-CCA2D1Ah.d.ts} +68 -5
  131. package/dist/{idCaptureServices-BSj6EH2l.esm.js → idCaptureServices-DK0QboqT.esm.js} +29 -198
  132. package/dist/{idCaptureStateMachine-dXKBYHQp.esm.js → idCaptureStateMachine-zzar9MPy.esm.js} +914 -536
  133. package/dist/{idOcrManager-DT3kPIB3.d.ts → idOcrManager-BTdHlJ9D.d.ts} +1 -1
  134. package/dist/{idOcrManager-D3-HNMXP.esm.js → idOcrManager-xyEZNOBa.esm.js} +2 -2
  135. package/dist/{idOcrStateMachine-DyENX6Ki.esm.js → idOcrStateMachine-DNKXh4Rn.esm.js} +2 -2
  136. package/dist/{idVerificationManager-iWz7Avkr.esm.js → idVerificationManager-DdnvYfgN.esm.js} +2 -2
  137. package/dist/{idVerificationStateMachine-CL1kUdBe.esm.js → idVerificationStateMachine-DtIBCa32.esm.js} +1 -1
  138. package/dist/identity-reuse.esm.js +2 -2
  139. package/dist/{identityReuseManager-CD1ucp1d.esm.js → identityReuseManager-CcpovlfD.esm.js} +2 -2
  140. package/dist/{identityReuseStateMachine-DfV81wQC.esm.js → identityReuseStateMachine-DxZFWy47.esm.js} +1 -1
  141. package/dist/{index-CKQ9QBZP.d.ts → index-DC0P2Vzw.d.ts} +1 -1
  142. package/dist/{index-BKOWUhxG.d.ts → index-DEfwds5y.d.ts} +55 -8
  143. package/dist/index.d.ts +1 -1
  144. package/dist/index.esm.js +1 -1
  145. package/dist/{invokeOnCaptureCallback-DYrkOXO6.esm.js → invokeOnCaptureCallback-BJ0GVHGr.esm.js} +1 -1
  146. package/dist/kyb-checks.d.ts +3 -0
  147. package/dist/kyb-checks.esm.js +3 -0
  148. package/dist/kybChecksManager-CblEL97E.d.ts +95 -0
  149. package/dist/kybChecksManager-DpGOp4Su.esm.js +89 -0
  150. package/dist/kybChecksStateMachine-B43NAnv7.esm.js +718 -0
  151. package/dist/mandatory-consent.d.ts +2 -2
  152. package/dist/mandatory-consent.esm.js +2 -2
  153. package/dist/{mandatoryConsentManager-Cwqx1nK7.esm.js → mandatoryConsentManager-B4vCYslr.esm.js} +4 -3
  154. package/dist/{mandatoryConsentManager-BQ43yndC.d.ts → mandatoryConsentManager-B88Sm5nd.d.ts} +10 -3
  155. package/dist/{mandatoryConsentStateMachine-pXWqAHo_.esm.js → mandatoryConsentStateMachine-DWslYPA3.esm.js} +20 -7
  156. package/dist/mediaRecorderOptions-B9-IEVtV.esm.js +70 -0
  157. package/dist/multipartRecordingService-BTqkHGG9.esm.js +407 -0
  158. package/dist/nationalIds-B91f_RuB.esm.js +99 -0
  159. package/dist/{permissionGuards-gcy3U0SL.esm.js → permissionGuards-DFV-Ws0a.esm.js} +1 -1
  160. package/dist/{permissionServices-Ca-tSNhT.esm.js → permissionServices-D190ATGD.esm.js} +11 -9
  161. package/dist/phone-number.d.ts +7 -1
  162. package/dist/phone-number.esm.js +15 -2
  163. package/dist/phone.d.ts +1 -1
  164. package/dist/phone.esm.js +2 -2
  165. package/dist/phoneFormat-JJNaWthV.esm.js +75 -0
  166. package/dist/{phoneManager-BO-LTih5.d.ts → phoneManager-6nrJkvkG.d.ts} +5 -0
  167. package/dist/{phoneManager-KKUq-Vgo.esm.js → phoneManager-Dy5tODCU.esm.js} +3 -3
  168. package/dist/phoneServices-DJgyOzU2.esm.js +77 -0
  169. package/dist/{phoneStateMachine-D2QWS2cu.esm.js → phoneStateMachine-DnlPhnw7.esm.js} +54 -82
  170. package/dist/{phoneValidation-DnBcNUNh.esm.js → phoneValidation-OggtfjRt.esm.js} +1 -2
  171. package/dist/{platform-DkcRc9JV.esm.js → platform-aPh7gTWh.esm.js} +15 -1
  172. package/dist/processFaceMatch-Bst83HaS.esm.js +21 -0
  173. package/dist/qe-signature.esm.js +1 -1
  174. package/dist/recordingService-CTko6Cjn.esm.js +397 -0
  175. package/dist/redirect-to-mobile.d.ts +2 -2
  176. package/dist/redirect-to-mobile.esm.js +2 -2
  177. package/dist/{redirectToMobileManager-uHW3dyuQ.esm.js → redirectToMobileManager-CgGaT2NP.esm.js} +5 -4
  178. package/dist/{redirectToMobileManager-CVsvpVbQ.d.ts → redirectToMobileManager-Dm9ctRCC.d.ts} +3 -1
  179. package/dist/{redirectToMobileStateMachine-b-H-ipGM.esm.js → redirectToMobileStateMachine-CbhN8uVN.esm.js} +65 -26
  180. package/dist/resolveForm-O7-r79VA.esm.js +351 -0
  181. package/dist/{runChildModule-BF_atgNx.esm.js → runChildModule-BffFArwl.esm.js} +3 -3
  182. package/dist/{sdkVersion-CsIbltJF.esm.js → sdkVersion-CDd_gaR7.esm.js} +1 -1
  183. package/dist/selfie.d.ts +4 -4
  184. package/dist/selfie.esm.js +10 -10
  185. package/dist/{selfieErrorUtils-BY0-YbPW.esm.js → selfieErrorUtils-f4MgAG2A.esm.js} +1 -1
  186. package/dist/{selfieManager-BJdNu_nd.d.ts → selfieManager-DmZFzs1-.d.ts} +1 -1
  187. package/dist/{selfieManager-vAAwzsHk.esm.js → selfieManager-hopelYEk.esm.js} +5 -5
  188. package/dist/{selfieStateMachine-BFVp3ElQ.esm.js → selfieStateMachine-DaZIVv3Q.esm.js} +3 -3
  189. package/dist/{session-CpwfoVdH.esm.js → session-CdSX4wsZ.esm.js} +77 -9
  190. package/dist/session.d.ts +96 -10
  191. package/dist/session.esm.js +7 -6
  192. package/dist/{sessionInitializer-BTjYgE-V.esm.js → sessionInitializer-DsL7X2j9.esm.js} +465 -206
  193. package/dist/{setup-YPKTUCY5.d.ts → setup-D9qt8YVU.d.ts} +2 -2
  194. package/dist/{setup-BInNAvQw.esm.js → setup-DDahygZs.esm.js} +44 -30
  195. package/dist/signature.esm.js +2 -2
  196. package/dist/{signatureManager-f_dPAGXn.esm.js → signatureManager-CwqjcxPg.esm.js} +2 -2
  197. package/dist/{signatureStateMachine-C-nUq_oq.esm.js → signatureStateMachine-DBVDd1Eu.esm.js} +1 -1
  198. package/dist/{stats-BEvexnKC.esm.js → stats-CatA2dea.esm.js} +1 -1
  199. package/dist/stats.esm.js +1 -1
  200. package/dist/textRules-D4NRinKY.d.ts +41 -0
  201. package/dist/{tri-xzRLIIMN.esm.js → tri-DG6priFa.esm.js} +142 -8
  202. package/dist/tri.d.ts +1 -1
  203. package/dist/tri.esm-CzTNi5Q_.esm.js +3826 -0
  204. package/dist/tri.esm.js +1 -1
  205. package/dist/{trueSightService-BMT-TubT.esm.js → trueSightService-GuLthUVK.esm.js} +19 -10
  206. package/dist/trust-graph.esm.js +1 -1
  207. package/dist/types-B9C8W01q.d.ts +34 -0
  208. package/dist/{types-yPH8lAH-.d.ts → types-BEVHQbbC.d.ts} +2 -2
  209. package/dist/{types-BAxn7MpY.d.ts → types-BPm1JSu7.d.ts} +123 -48
  210. package/dist/{types-0L-eFDmr.d.ts → types-BgRHw-dR.d.ts} +1 -1
  211. package/dist/{types-B6HsSzpk.d.ts → types-CRaFu6wS.d.ts} +6 -3
  212. package/dist/types-CTaL0XJz.d.ts +80 -0
  213. package/dist/{types-Ckir_BEs.d.ts → types-Cd0J0F9D.d.ts} +1 -1
  214. package/dist/{types-CK8Jbjkp.d.ts → types-Csh8vzPo.d.ts} +1 -1
  215. package/dist/types-CuMJ2M7D.d.ts +210 -0
  216. package/dist/{types-DUnFZ08M.d.ts → types-CyNndVAT.d.ts} +16 -8
  217. package/dist/{types-DPIDuhut.d.ts → types-DNVzoRvi.d.ts} +2 -1
  218. package/dist/types-J6g6iKe_.d.ts +6 -0
  219. package/dist/{urlUtils-6jsE6rKp.esm.js → urlUtils-eYiyWjh0.esm.js} +4 -1
  220. package/dist/video-selfie.d.ts +8 -8
  221. package/dist/video-selfie.esm.js +97 -22
  222. package/dist/{videoSelfieCameraWarmer-D1xA0u8y.esm.js → videoSelfieCameraWarmer-e3irGfcO.esm.js} +18 -21
  223. package/dist/{videoSelfieStepDetector-CGsTltqB.d.ts → videoSelfieStepDetector-Dv3Mgws-.d.ts} +9 -4
  224. package/dist/virtualCameraCheck-eFOm2C9q.esm.js +27 -0
  225. package/dist/{warmup-BElYWRh7.esm.js → warmup-DtB0DJpl.esm.js} +198 -27
  226. package/dist/wasm.d.ts +2 -2
  227. package/dist/wasm.esm.js +3 -3
  228. package/dist/{wasmDsFlagSync-CYj5LL9z.esm.js → wasmDsFlagSync-BtiR5pig.esm.js} +1 -1
  229. package/dist/wasmMetadataVersionSync-U8EFUr1T.esm.js +27 -0
  230. package/dist/{wasmWebClient-BjZw_7OB.esm.js → wasmWebClient-BDrax6Eu.esm.js} +55 -26
  231. package/dist/watchlist-for-business.d.ts +2 -1
  232. package/dist/watchlist-for-business.esm.js +2 -2
  233. package/dist/watchlist.esm.js +2 -2
  234. package/dist/{watchlistForBusinessManager-B3GDPZrr.d.ts → watchlistForBusinessManager-DX2AyM4Y.d.ts} +54 -18
  235. package/dist/{watchlistForBusinessManager-CZZOFkGl.esm.js → watchlistForBusinessManager-DqUpAEj_.esm.js} +37 -7
  236. package/dist/watchlistForBusinessStateMachine-DdaPl2PS.esm.js +166 -0
  237. package/dist/{watchlistManager-DXtX94SN.esm.js → watchlistManager-CdpXzT4B.esm.js} +2 -2
  238. package/dist/{watchlistStateMachine-McALifag.esm.js → watchlistStateMachine-ofHW_lPk.esm.js} +1 -1
  239. package/dist/workflow.d.ts +5 -2
  240. package/dist/workflow.esm.js +60 -50
  241. package/package.json +12 -5
  242. package/dist/IBrowserEnvironmentCapability-DEaRRk-R.esm.js +0 -9
  243. package/dist/addressSearch-DPjIKJrX.esm.js +0 -563
  244. package/dist/deepsightLoader-DeNvGU3c.esm.js +0 -55
  245. package/dist/ekycStateMachine-CDnI_NRq.esm.js +0 -1443
  246. package/dist/ekycUtils-zY8CdKJL.esm.js +0 -300
  247. package/dist/thumbmark.esm-CRc0cYvz.esm.js +0 -1242
  248. package/dist/tri.esm-BIjHhBJ2.esm.js +0 -2620
  249. package/dist/types-BvLo3U4u.d.ts +0 -134
  250. package/dist/types-zOgZqMni.d.ts +0 -6
  251. package/dist/watchlistForBusinessStateMachine-B66E7jud.esm.js +0 -78
  252. /package/dist/{types-BSBzhHRH2.d.ts → types-BSBzhHRH.d.ts} +0 -0
@@ -0,0 +1,99 @@
1
+ //#region src/shared/validators/nationalIds.ts
2
+ /**
3
+ * The national ID rules from `vocabulary.json`: `rut`, `esDni`,
4
+ * `fiPersonalIdentityCode`, `inDrivingLicenseNumber` and `curp`. Each accepts
5
+ * the usual punctuation and either letter case.
6
+ */
7
+ /**
8
+ * Chilean RUT/RUN: a 7- or 8-digit body and a check character, 0-9 or K,
9
+ * computed modulo 11. Dots, a hyphen and spaces are ignored
10
+ * (`12.345.678-5`, `12345678-5`, `123456785`).
11
+ */
12
+ function isValidRut(value) {
13
+ const rut = value.replace(/[.\s-]/g, "").toUpperCase();
14
+ const match = /^([0-9]{7,8})([0-9K])$/.exec(rut);
15
+ if (!match) return false;
16
+ const [, body, check] = match;
17
+ let sum = 0;
18
+ let factor = 2;
19
+ for (let i = body.length - 1; i >= 0; i--) {
20
+ sum += Number(body[i]) * factor;
21
+ factor = factor === 7 ? 2 : factor + 1;
22
+ }
23
+ const rest = 11 - sum % 11;
24
+ return check === (rest === 11 ? "0" : rest === 10 ? "K" : String(rest));
25
+ }
26
+ const DNI_LETTERS = "TRWAGMYFPDXBNJZSQVHLCKE";
27
+ /**
28
+ * Spanish DNI: 8 digits and the check letter for their value modulo 23
29
+ * (`12345678Z`). A space or hyphen before the letter is ignored. NIEs, the
30
+ * foreigners' IDs, are not DNIs and fail.
31
+ */
32
+ function isValidEsDni(value) {
33
+ const dni = value.replace(/[\s-]/g, "").toUpperCase();
34
+ const match = /^([0-9]{8})([A-Z])$/.exec(dni);
35
+ if (!match) return false;
36
+ const [, digits, letter] = match;
37
+ return DNI_LETTERS[Number(digits) % 23] === letter;
38
+ }
39
+ const FI_CHECK_CHARACTERS = "0123456789ABCDEFHJKLMNPRSTUVWXY";
40
+ /** The first year of each century sign; the 2023 reform added Y-U and B-F. */
41
+ const FI_CENTURY = {
42
+ "+": 1800,
43
+ "-": 1900,
44
+ Y: 1900,
45
+ X: 1900,
46
+ W: 1900,
47
+ V: 1900,
48
+ U: 1900,
49
+ A: 2e3,
50
+ B: 2e3,
51
+ C: 2e3,
52
+ D: 2e3,
53
+ E: 2e3,
54
+ F: 2e3
55
+ };
56
+ const isLeapYear = (year) => year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;
57
+ const daysInMonth = (year, month) => month === 2 ? isLeapYear(year) ? 29 : 28 : [
58
+ 4,
59
+ 6,
60
+ 9,
61
+ 11
62
+ ].includes(month) ? 30 : 31;
63
+ /**
64
+ * Finnish personal identity code (henkilötunnus): `DDMMYY`, a century sign,
65
+ * a 3-digit individual number and a check character for the 9 digits modulo
66
+ * 31 (`131052-308T`). The date must exist.
67
+ */
68
+ function isValidFiPersonalIdentityCode(value) {
69
+ const match = /^([0-9]{2})([0-9]{2})([0-9]{2})([-+A-FU-Y])([0-9]{3})([0-9A-Y])$/.exec(value.trim().toUpperCase());
70
+ if (!match) return false;
71
+ const [, dd, mm, yy, sign, individual, check] = match;
72
+ const year = FI_CENTURY[sign] + Number(yy);
73
+ const month = Number(mm);
74
+ const day = Number(dd);
75
+ if (month < 1 || month > 12 || day < 1 || day > daysInMonth(year, month)) return false;
76
+ return FI_CHECK_CHARACTERS[Number(`${dd}${mm}${yy}${individual}`) % 31] === check;
77
+ }
78
+ const IN_DRIVING_LICENSE_REGEX = /^[A-Z]{2}[-\s]?[0-9]{2}(?:[0-9]{2})?[-\s]?(?:19|20)[0-9]{2}[-\s]?[0-9]{7}$/i;
79
+ /**
80
+ * Indian driving licence number format, `SS-RR[RR]-YYYY-NNNNNNN`, with or
81
+ * without hyphens (`MH-12-2011-0012345`, `MH1220110012345`). Format only:
82
+ * the number has no check digit.
83
+ */
84
+ function isValidInDrivingLicenseNumber(value) {
85
+ return IN_DRIVING_LICENSE_REGEX.test(value.trim());
86
+ }
87
+ const CURP_PATTERN = /^([A-Z][AEIOUX][A-Z]{2}\d{2}(?:0[1-9]|1[0-2])(?:0[1-9]|[12]\d|3[01])[HMX](?:AS|B[CS]|C[CLMSH]|D[FG]|G[TR]|HG|JC|M[CNS]|N[ETL]|OC|PL|Q[TR]|S[PLR]|T[CSL]|VZ|YN|ZS)[B-DF-HJ-NP-TV-Z]{3}[A-Z\d])(\d)$/;
88
+ /**
89
+ * Mexican CURP layout: 4 letters (the second a vowel or X), a YYMMDD birth
90
+ * date, H, M or X for sex, a state code (NE for born abroad), 3 consonants, a
91
+ * letter or digit, and a final digit. Format only: the check digit isn't
92
+ * computed, as in SDK1 (see "Gaps" in the eKYC drafts README for how to add
93
+ * it). The CURP module checks the same layout.
94
+ */
95
+ function isValidCurp(curp) {
96
+ return typeof curp === "string" && curp.length === 18 && CURP_PATTERN.test(curp.toUpperCase());
97
+ }
98
+ //#endregion
99
+ export { isValidRut as a, isValidInDrivingLicenseNumber as i, isValidEsDni as n, isValidFiPersonalIdentityCode as r, isValidCurp as t };
@@ -1,4 +1,4 @@
1
- import { s as isWasmMotionPrimedForModule } from "./permissionServices-Ca-tSNhT.esm.js";
1
+ import { s as isWasmMotionPrimedForModule } from "./permissionServices-D190ATGD.esm.js";
2
2
  //#region src/internal/permissions/permissionGuards.ts
3
3
  function resolveStoredPermissionResult(fromEvent, fromContext) {
4
4
  if (fromEvent === "granted" || fromEvent === "denied" || fromEvent === "prompt" || fromEvent === "refresh") return fromEvent;
@@ -1,7 +1,7 @@
1
- import { t as WasmUtilProvider } from "./WasmUtilProvider-DtJuBdt-.esm.js";
2
- import { n as isAndroidWebView } from "./platform-DkcRc9JV.esm.js";
1
+ import { t as WasmUtilProvider } from "./WasmUtilProvider-Dp2V-Uct.esm.js";
2
+ import { n as isAndroidWebView } from "./platform-aPh7gTWh.esm.js";
3
3
  import { t as MotionSensorProvider } from "./MotionSensorProvider-DYxh8TjR.esm.js";
4
- import { c as isCameraGrantedInDocument, i as requestCameraAccess, o as stopCameraStream, s as clearCameraGrantedInDocument } from "./camera-sIa9ceW2.esm.js";
4
+ import { a as stopCameraStream, c as isCameraGrantedInDocument, o as clearCameraGrantedInDocument, r as requestCameraAccess } from "./camera-E_Kcre4O.esm.js";
5
5
  //#region ../infra/src/media/permissions.ts
6
6
  async function queryPermission(name) {
7
7
  try {
@@ -136,20 +136,22 @@ async function requestMotionPermission() {
136
136
  /**
137
137
  * Requests camera permission by attempting to access the camera, then immediately
138
138
  * stops the obtained stream. When `requestMotion` is true (deepsight), requests
139
- * motion OS permission, primes WASM sensors, then camera — all in one user gesture
140
- * chain, matching SDK v1.
139
+ * motion OS permission first, then primes WASM sensors while it requests the
140
+ * camera — all in one user gesture chain, as in SDK v1.
141
141
  */
142
142
  async function requestPermission(options = {}) {
143
143
  try {
144
+ let motionPrimed;
144
145
  if (options.requestMotion) {
145
146
  const motionSensor = new MotionSensorProvider();
146
147
  if (await resolveMotionOsPermission(motionSensor) === "denied") return "denied";
147
- if (!isWasmMotionPrimedForModule()) await primeWasmMotionSensor(motionSensor);
148
+ if (!isWasmMotionPrimedForModule()) motionPrimed = primeWasmMotionSensor(motionSensor);
148
149
  }
149
- stopCameraStream(await requestCameraAccess({
150
+ const [stream] = await Promise.all([requestCameraAccess({
150
151
  video: true,
151
152
  audio: options.requestAudio ?? false
152
- }));
153
+ }), motionPrimed]);
154
+ stopCameraStream(stream);
153
155
  return "granted";
154
156
  } catch (error) {
155
157
  const name = error instanceof Error ? error.name : void 0;
@@ -170,4 +172,4 @@ async function invokeRequestPermissionActor(input) {
170
172
  return requestPermission({ requestMotion: true });
171
173
  }
172
174
  //#endregion
173
- export { requestPermission as a, resetWasmMotionPrimedForModule as c, requestMotionPermission as i, queryCameraPermission as l, invokeRequestPermissionActor as n, requiresMotionPermissionUserGesture as o, primeMotionFromUserGestureIfNeeded as r, isWasmMotionPrimedForModule as s, checkPermission as t };
175
+ export { requestPermission as a, resetWasmMotionPrimedForModule as c, requestMotionPermission as i, queryCameraPermission as l, invokeRequestPermissionActor as n, requiresMotionPermissionUserGesture as o, primeMotionFromUserGestureIfNeeded as r, isWasmMotionPrimedForModule as s, checkPermission as t, queryPermission as u };
@@ -8,6 +8,12 @@ type CountryCode = 'AC' | 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO'
8
8
  declare function getCallingCode(country: CountryCode): string;
9
9
  /** Formats national digits while the user types them, without the calling code. */
10
10
  declare function formatPhoneAsYouType(nationalDigits: string, country: CountryCode): string;
11
+ /**
12
+ * Returns the national significant number in digits typed after the calling
13
+ * code: without a trunk prefix the rules drop, such as `0612345678` in `NL` →
14
+ * `612345678`. Counts the digits the way phone validation does.
15
+ */
16
+ declare function getNationalSignificantNumber(nationalDigits: string, country: CountryCode): string;
11
17
  /** Returns an example mobile number in national format, without a trunk prefix. */
12
18
  declare function formatExamplePhoneNumber(country: CountryCode): string;
13
19
  /**
@@ -21,4 +27,4 @@ declare function parsePhoneNumber(phone: string): {
21
27
  /** Checks a full international number against the rules of `country`. */
22
28
  declare function isValidPhoneNumber(phone: string, country: CountryCode): boolean;
23
29
  //#endregion
24
- export { type CountryCode, formatExamplePhoneNumber, formatPhoneAsYouType, getCallingCode, isValidPhoneNumber, parsePhoneNumber };
30
+ export { type CountryCode, formatExamplePhoneNumber, formatPhoneAsYouType, getCallingCode, getNationalSignificantNumber, isValidPhoneNumber, parsePhoneNumber };
@@ -1,4 +1,4 @@
1
- import { C as metadata_min_json_default, S as withMetadataArgument, _ as VALID_PUNCTUATION, a as PhoneNumber, b as getCountryCallingCode$1, c as applyInternationalSeparatorStyle, d as getCountryByCallingCode, f as getCountryByNationalNumber, g as VALID_DIGITS, h as PLUS_CHARS, i as parseDigits, l as extractCountryCallingCode, m as stripIddPrefix, o as FIRST_GROUP_PATTERN, p as extractNationalNumberFromPossiblyIncompleteNumber, r as parsePhoneNumber$1, s as formatNationalNumberUsingFormat, t as PhoneValidationProvider, u as extractCountryCallingCodeFromInternationalNumberWithoutPlusSign, v as checkNumberLength, x as isObject, y as Metadata } from "./PhoneValidationProvider-SZiOS0jB.esm.js";
1
+ import { C as metadata_min_json_default, S as withMetadataArgument, _ as VALID_PUNCTUATION, a as PhoneNumber, b as getCountryCallingCode$1, c as applyInternationalSeparatorStyle, d as getCountryByCallingCode, f as getCountryByNationalNumber, g as VALID_DIGITS, h as PLUS_CHARS, i as parseDigits, l as extractCountryCallingCode, m as stripIddPrefix, o as FIRST_GROUP_PATTERN, p as extractNationalNumberFromPossiblyIncompleteNumber, r as parsePhoneNumber$1, s as formatNationalNumberUsingFormat, t as PhoneValidationProvider, u as extractCountryCallingCodeFromInternationalNumberWithoutPlusSign, v as checkNumberLength, x as isObject, y as Metadata } from "./PhoneValidationProvider-Co4zk2en.esm.js";
2
2
  //#region ../../node_modules/.pnpm/libphonenumber-js@1.12.31/node_modules/libphonenumber-js/es6/AsYouTypeState.js
3
3
  function _typeof$5(o) {
4
4
  "@babel/helpers - typeof";
@@ -1877,6 +1877,11 @@ var PhoneFormattingProvider = class {
1877
1877
  const callingCode = this.getCallingCode(country);
1878
1878
  return new AsYouType(country).input(`${callingCode}${nationalDigits}`).replace(callingCode, "").trimStart();
1879
1879
  }
1880
+ nationalSignificantNumber(nationalDigits, country) {
1881
+ const asYouType = new AsYouType(country);
1882
+ asYouType.input(`${this.getCallingCode(country)}${nationalDigits}`);
1883
+ return asYouType.getNumber()?.nationalNumber ?? "";
1884
+ }
1880
1885
  formatExampleNumber(country) {
1881
1886
  const example = getExampleNumber(country, examples_mobile_json_default);
1882
1887
  if (!example) return "";
@@ -1903,6 +1908,14 @@ function getCallingCode(country) {
1903
1908
  function formatPhoneAsYouType(nationalDigits, country) {
1904
1909
  return formatting.formatAsYouType(nationalDigits, country);
1905
1910
  }
1911
+ /**
1912
+ * Returns the national significant number in digits typed after the calling
1913
+ * code: without a trunk prefix the rules drop, such as `0612345678` in `NL` →
1914
+ * `612345678`. Counts the digits the way phone validation does.
1915
+ */
1916
+ function getNationalSignificantNumber(nationalDigits, country) {
1917
+ return formatting.nationalSignificantNumber(nationalDigits, country);
1918
+ }
1906
1919
  /** Returns an example mobile number in national format, without a trunk prefix. */
1907
1920
  function formatExamplePhoneNumber(country) {
1908
1921
  return formatting.formatExampleNumber(country);
@@ -1919,4 +1932,4 @@ function isValidPhoneNumber(phone, country) {
1919
1932
  return validation.isValid(phone, country);
1920
1933
  }
1921
1934
  //#endregion
1922
- export { formatExamplePhoneNumber, formatPhoneAsYouType, getCallingCode, isValidPhoneNumber, parsePhoneNumber };
1935
+ export { formatExamplePhoneNumber, formatPhoneAsYouType, getCallingCode, getNationalSignificantNumber, isValidPhoneNumber, parsePhoneNumber };
package/dist/phone.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { n as PhoneState, o as phoneMachine, r as createPhoneManager, s as PhoneConfig, t as PhoneManager } from "./phoneManager-BO-LTih5.js";
1
+ import { n as PhoneState, o as phoneMachine, r as createPhoneManager, s as PhoneConfig, t as PhoneManager } from "./phoneManager-6nrJkvkG.js";
2
2
  export { type PhoneConfig, type PhoneManager, type PhoneState, createPhoneManager, phoneMachine };
package/dist/phone.esm.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as phoneMachine } from "./phoneStateMachine-D2QWS2cu.esm.js";
2
- import { t as createPhoneManager } from "./phoneManager-KKUq-Vgo.esm.js";
1
+ import { t as phoneMachine } from "./phoneStateMachine-DnlPhnw7.esm.js";
2
+ import { t as createPhoneManager } from "./phoneManager-Dy5tODCU.esm.js";
3
3
  export { createPhoneManager, phoneMachine };
@@ -0,0 +1,75 @@
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
+ /** `digitCount`: only the digits 0-9, with a count in `lengths` or between `min` and `max`. */
30
+ function hasDigitCount(value, count) {
31
+ if (!/^[0-9]+$/.test(value)) return false;
32
+ const { length } = value;
33
+ if (count.lengths) return count.lengths.includes(length);
34
+ return (count.min === void 0 || length >= count.min) && (count.max === void 0 || length <= count.max);
35
+ }
36
+ /**
37
+ * `allowedCharacters`: only characters from `classes`, plus any in `extra`.
38
+ * With `ascii`, `letter` means A-Z in either case instead of any script.
39
+ */
40
+ function hasAllowedCharacters(value, classes, extra = "", ascii = false) {
41
+ const set = classes.map((c) => ascii && c === "letter" ? "A-Za-z" : CLASS_PATTERNS[c]).join("");
42
+ return new RegExp(`^[${set}${escapeForClass(extra)}]+$`, "u").test(value);
43
+ }
44
+ /**
45
+ * `charTemplate`: the whole value matches one template, where `9` is a digit,
46
+ * `A` an uppercase letter A-Z and any other character stands for itself.
47
+ * `ignoreCase` also accepts lowercase letters and literals in either case.
48
+ */
49
+ function matchesCharTemplate(value, templates, ignoreCase = false) {
50
+ return templates.some((template) => {
51
+ const pattern = [...template].map((char) => {
52
+ if (char === "9") return "[0-9]";
53
+ if (char === "A") return "[A-Z]";
54
+ return escapeForPattern(char);
55
+ }).join("");
56
+ return new RegExp(`^${pattern}$`, ignoreCase ? "iu" : "u").test(value);
57
+ });
58
+ }
59
+ /** `numericRange`: a whole number from `min` to `max`. */
60
+ function isInNumericRange(value, min, max) {
61
+ if (!/^-?[0-9]+$/.test(value)) return false;
62
+ const number = Number(value);
63
+ return number >= min && number <= max;
64
+ }
65
+ //#endregion
66
+ //#region src/shared/phoneFormat.ts
67
+ /**
68
+ * The phone in E.164, or the value as typed when the rules are not loaded
69
+ * (`loadPhoneValidation()`) or the number is not valid.
70
+ */
71
+ function formatPhoneE164(phone, country) {
72
+ return getPhoneValidation()?.formatE164(phone, country) ?? phone;
73
+ }
74
+ //#endregion
75
+ export { hasNameCharacters as a, matchesCharTemplate as c, hasDigitCount as i, CHARACTER_CLASSES as n, isInNumericRange as o, hasAllowedCharacters as r, isNotFuture as s, formatPhoneE164 as t };
@@ -8,6 +8,11 @@ type IPhoneValidationCapability = {
8
8
  isPossible(phone: string): boolean;
9
9
  isValid(phone: string, country: string): boolean;
10
10
  formatE164(phone: string, country: string): string | null;
11
+ /**
12
+ * The national significant number's digits (no calling code or trunk
13
+ * prefix), or `null` when the phone can't be parsed. It needn't be valid.
14
+ */
15
+ nationalNumber(phone: string, country: string): string | null;
11
16
  };
12
17
  //#endregion
13
18
  //#region src/modules/phone/types.d.ts
@@ -1,8 +1,8 @@
1
- import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-Du2A4-Qr.esm.js";
1
+ import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-ggpBBaZ8.esm.js";
2
+ import { n as loadPhoneValidation, t as getPhoneValidation } from "./phoneValidation-OggtfjRt.esm.js";
2
3
  import { s as createActor, u as createManager } from "./xstate.esm-DSajW7CJ.esm.js";
3
- import { n as loadPhoneValidation, t as getPhoneValidation } from "./phoneValidation-DnBcNUNh.esm.js";
4
4
  import { n as isOtpComplete } from "./otp-D2k3PeSL.esm.js";
5
- import { t as phoneMachine } from "./phoneStateMachine-D2QWS2cu.esm.js";
5
+ import { t as phoneMachine } from "./phoneStateMachine-DnlPhnw7.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-CpP4PS4S.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,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";
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-DJgyOzU2.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 { n as loadPhoneValidation } from "./phoneValidation-DnBcNUNh.esm.js";
6
+ import { t as carryAttempts } from "./attemptCarry-WOkfvFMw.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
- config: input.config,
215
- phone: "",
216
- isValid: false,
217
- phoneError: void 0,
218
- validationErrors: void 0,
219
- countryCode: "",
220
- phonePrefix: "",
221
- prefilledPhone: void 0,
222
- optInGranted: false,
223
- startInfo: void 0,
224
- error: void 0,
225
- otpCode: "",
226
- otpError: void 0,
227
- otpValidationErrors: void 0,
228
- attemptsRemaining: input.config.maxOtpAttempts ?? 3,
229
- resendTimer: 0,
230
- resendTimerActive: false
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
- target: "loadingPrefill",
235
- guard: "hasPrefill"
236
- }, { target: "loadingStartInfo" }] } },
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
- target: "loadingStartInfo",
244
- actions: "setPrefilledPhone"
245
- },
246
- onError: { target: "loadingStartInfo" }
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
- const { PhoneValidationProvider } = await import("./PhoneValidationProvider-SZiOS0jB.esm.js").then((n) => n.n);
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, isTabletWithoutAndroid as f, isDesktop as i, isIslandBrowser as l, isAndroidWebView as n, isIOSWebView as o, isBraveBrowser as r, isIPad as s, isAndroid as t, isMacOsSafari as u };
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-CpP4PS4S.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 };
@@ -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-CcIMOb_Y.esm.js";
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-BCE3uA3z.esm.js";
2
2
  //#region src/modules/qe-signature/index.ts
3
3
  function createQeSignatureManager(options) {
4
4
  return createElectronicSignatureManager({ config: {