@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.
Files changed (239) hide show
  1. package/dist/{BaseWasmProvider-Bq3OHo7P.d.ts → BaseWasmProvider-bBNquvYn.d.ts} +2 -2
  2. package/dist/BrowserNetworkStatusProvider-BrDXBEDd.esm.js +21 -0
  3. package/dist/{multipartRecordingService-DMBxHKS2.esm.js → CameraCompositor-DN7NkJzV.esm.js} +7 -734
  4. package/dist/DateFormattingProvider-DPq9zco-.esm.js +25 -0
  5. package/dist/{FaceDetectionProvider-B83VmClw.esm.js → FaceDetectionProvider-BSLpXAGx.esm.js} +11 -12
  6. package/dist/{IIdCaptureCapability-CGcEt2Cw.d.ts → IIdCaptureCapability-C-5M8pP1.d.ts} +2 -2
  7. package/dist/{IWasmUtilCapability-Cqiaxydi.d.ts → IWasmUtilCapability-BRn0wz8v.d.ts} +2 -2
  8. package/dist/MultipartRecordingProvider-BfQPSgSO.esm.js +151 -0
  9. package/dist/{StreamCanvasCapture-C3xNfOsv.d.ts → StreamCanvasCapture-ixfy84ys.d.ts} +2 -2
  10. package/dist/StreamCanvasProcessingSession-CBnbTnOr.esm.js +42 -0
  11. package/dist/{WasmUtilProvider-GTkoJyFY.esm.js → WasmUtilProvider-C_puwvVn.esm.js} +2 -2
  12. package/dist/WorkerEncoderRecordingProvider-CyCrQnZR.esm.js +80 -0
  13. package/dist/addressSearch-B_4JYKa-.esm.js +72 -0
  14. package/dist/ae-signature.esm.js +1 -1
  15. package/dist/antifraud.esm.js +2 -2
  16. package/dist/{antifraudManager-CQ08atTC.esm.js → antifraudManager-BWCVkSu2.esm.js} +2 -2
  17. package/dist/{antifraudStateMachine-BcsUTTIr.esm.js → antifraudStateMachine-CX9I2f3s.esm.js} +1 -1
  18. package/dist/{api-BO8JA7Pf.esm.js → api-BSnbg4HO.esm.js} +4 -0
  19. package/dist/{apiError-CfuIvnUy.esm.js → apiError-Bmwy1Fa7.esm.js} +1 -1
  20. package/dist/{attemptCarry-BjTJ6bMQ.esm.js → attemptCarry-zQH85Elh.esm.js} +2 -2
  21. package/dist/authentication.d.ts +3 -3
  22. package/dist/authentication.esm.js +2 -2
  23. package/dist/{authenticationManager-DvmklBTE.esm.js → authenticationManager-BoiOaB0m.esm.js} +5 -5
  24. package/dist/{authenticationManager-C-cOki0Y.d.ts → authenticationManager-CISxaY6N.d.ts} +1 -1
  25. package/dist/{authenticationStateMachine-BL2ptOA0.esm.js → authenticationStateMachine-BMD1JLwr.esm.js} +3 -3
  26. package/dist/avatar.d.ts +1 -1
  27. package/dist/backCameraLabel-yda5ugE4.esm.js +67 -0
  28. package/dist/{backCameraStream-C5_NNfUN.esm.js → backCameraStream-DS1oDiUq.esm.js} +10 -65
  29. package/dist/{browser-pQZA35G2-DtkAf6sn.esm.js → browser-pQZA35G2-PIj2uGBm.esm.js} +1 -1
  30. package/dist/camera.d.ts +2 -2
  31. package/dist/camera.esm.js +1 -1
  32. package/dist/certificate-issuance.esm.js +2 -2
  33. package/dist/{certificateIssuanceManager-CM0fuqDC.esm.js → certificateIssuanceManager-DzDuQTsK.esm.js} +2 -2
  34. package/dist/{certificateIssuanceStateMachine-kksIUOPD.esm.js → certificateIssuanceStateMachine-BAOYLACb.esm.js} +2 -2
  35. package/dist/{connectivity-HSl0diCx.esm.js → connectivity-BCuEoQ-n.esm.js} +2 -21
  36. package/dist/consent.d.ts +1 -1
  37. package/dist/consent.esm.js +2 -2
  38. package/dist/{consentManager-_q9yJUku.d.ts → consentManager-7aHaehwF.d.ts} +5 -5
  39. package/dist/{consentManager-CBwFozhv.esm.js → consentManager-DFSKQTcR.esm.js} +2 -2
  40. package/dist/{consentStateMachine-CpmRAcr2.esm.js → consentStateMachine-4nZIH2O8.esm.js} +1 -1
  41. package/dist/{cpf-uAZTPUBy.esm.js → cpf-BIADjddF.esm.js} +1 -25
  42. package/dist/{createFaceAvatar-lYX0VTYs.d.ts → createFaceAvatar-BimBTONm.d.ts} +1 -1
  43. package/dist/cross-document-data-match.esm.js +1 -1
  44. package/dist/{crossDocumentDataMatchManager-64O8t10a.esm.js → crossDocumentDataMatchManager-D7ka2qOC.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-CLgJQcx0.esm.js → curpValidationManager-BVTt7IgC.esm.js} +2 -2
  48. package/dist/{curpValidationManager-CXpFE-Mv.d.ts → curpValidationManager-DEqTUWdu.d.ts} +1 -1
  49. package/dist/{curpValidationStateMachine-Bx9YhVkJ.esm.js → curpValidationStateMachine-FB_MRbZQ.esm.js} +2 -2
  50. package/dist/custom-fields.esm.js +1 -1
  51. package/dist/custom-watchlist.esm.js +2 -2
  52. package/dist/{customFieldsManager-DWt_0YtJ.esm.js → customFieldsManager-gbsq53p6.esm.js} +2 -2
  53. package/dist/{customWatchlistManager-D8o-2Nej.esm.js → customWatchlistManager-50APwk4Z.esm.js} +2 -2
  54. package/dist/{customWatchlistStateMachine-Sbi6DIcK.esm.js → customWatchlistStateMachine-CpEVPzuT.esm.js} +1 -1
  55. package/dist/{deepsightService-twg3bXqY.esm.js → deepsightLoader-BKCT8UT1.esm.js} +34 -29
  56. package/dist/definitionSource-BHNxbuiv.esm.js +184 -0
  57. package/dist/{desktopCameraElection-kHY2IDJi.esm.js → desktopCameraElection-Dvvw7PRY.esm.js} +5 -5
  58. package/dist/document-capture.d.ts +3 -3
  59. package/dist/document-capture.esm.js +2 -2
  60. package/dist/{documentCaptureManager-CMSC_Mhd.esm.js → documentCaptureManager-BG5TuqJz.esm.js} +3 -2
  61. package/dist/{documentCaptureManager-6tnnDkMX.d.ts → documentCaptureManager-DDfviFg0.d.ts} +25 -4
  62. package/dist/{documentCaptureStateMachine-BCwD5Rto.esm.js → documentCaptureStateMachine-C7PW_Ah9.esm.js} +67 -26
  63. package/dist/dynamic-forms.esm.js +2 -2
  64. package/dist/{dynamicFormsManager-DU6W1e20.esm.js → dynamicFormsManager-B0bpHhhJ.esm.js} +2 -2
  65. package/dist/{dynamicFormsStateMachine-C8Z7k3vo.esm.js → dynamicFormsStateMachine-2ZHyejBc.esm.js} +2 -2
  66. package/dist/ekyb.d.ts +4 -4
  67. package/dist/ekyb.esm.js +3 -3
  68. package/dist/{ekybManager-TB6ZG5lX.d.ts → ekybManager-BLOkwmWO.d.ts} +2 -2
  69. package/dist/{ekybManager-TGfqyjuu.esm.js → ekybManager-P9mC7W9J.esm.js} +2 -2
  70. package/dist/{ekybStateMachine-DBgFuEPK.esm.js → ekybStateMachine-C7HKaeVr.esm.js} +7 -3
  71. package/dist/ekybUtils-Cw8Ta9Qi.esm.js +140 -0
  72. package/dist/ekyc-prefill.d.ts +17 -0
  73. package/dist/ekyc-prefill.esm.js +3 -0
  74. package/dist/ekyc.d.ts +3 -2
  75. package/dist/ekyc.esm.js +3 -3
  76. package/dist/{ekycManager-C2cgG2Pl.esm.js → ekycManager-CeeJoRFY.esm.js} +2 -2
  77. package/dist/{ekycManager-BSQteIfC.d.ts → ekycManager-q1fos6IY.d.ts} +2 -1
  78. package/dist/ekycPrefillManager-C6BFFKxc.esm.js +102 -0
  79. package/dist/ekycPrefillManager-PPGVZbWk.d.ts +565 -0
  80. package/dist/ekycPrefillStateMachine-Dku90kZL.esm.js +686 -0
  81. package/dist/ekycRules-BLX7Elcb.esm.js +319 -0
  82. package/dist/{ekycStateMachine-CuNF7z4O.esm.js → ekycStateMachine-DBTczgGE.esm.js} +719 -596
  83. package/dist/{ekycUtils-BFncpC4F.esm.js → ekycUtils-Dcff8BOD.esm.js} +103 -14
  84. package/dist/electronic-signature.esm.js +1 -1
  85. package/dist/{electronicSignatureManager-C7pqXsRm.esm.js → electronicSignatureManager-BKQuhJm_.esm.js} +4 -4
  86. package/dist/email.esm.js +2 -2
  87. package/dist/{emailManager-FH_CP0cT.esm.js → emailManager-CGmKbsBL.esm.js} +2 -2
  88. package/dist/{emailStateMachine-Cx-uTaBV.esm.js → emailStateMachine-CGY1UGs2.esm.js} +2 -2
  89. package/dist/{events-CQteqXfy.esm.js → events-C7h7oaTE.esm.js} +1 -1
  90. package/dist/events.esm.js +1 -1
  91. package/dist/extensibility.d.ts +20 -18
  92. package/dist/extensibility.esm.js +37 -35
  93. package/dist/{externalFetch-CQY41QT1.esm.js → externalFetch-cUjJYyXj.esm.js} +1 -1
  94. package/dist/face-match.d.ts +1 -1
  95. package/dist/face-match.esm.js +2 -2
  96. package/dist/{faceCaptureManagerFactory-C-xKdj-d.d.ts → faceCaptureManagerFactory-BVwVGa3z.d.ts} +7 -7
  97. package/dist/{faceCaptureManagerFactory-CBm05KnT.esm.js → faceCaptureManagerFactory-ClFsByZc.esm.js} +4 -4
  98. package/dist/{faceCaptureSetup-BQjCbL51.esm.js → faceCaptureSetup-9hv5GC_H.esm.js} +12 -403
  99. package/dist/{faceMatchManager-Z4UDLwAv.d.ts → faceMatchManager-BZtEw6bB.d.ts} +9 -3
  100. package/dist/{faceMatchManager-B2zp7yP4.esm.js → faceMatchManager-CRe7Nvm6.esm.js} +2 -2
  101. package/dist/{faceMatchStateMachine-ByTMQCUC.esm.js → faceMatchStateMachine-EX9QhxFE.esm.js} +28 -14
  102. package/dist/{feature-management-DjAG5lsJ.esm.js → feature-management-CmKTG_T5.esm.js} +35 -21
  103. package/dist/feature-management.esm.js +1 -1
  104. package/dist/field-comparison.esm.js +1 -1
  105. package/dist/{fieldComparisonManager-CC0vKmpf.esm.js → fieldComparisonManager-DuosZJso.esm.js} +2 -2
  106. package/dist/fiscal-qr.esm.js +1 -1
  107. package/dist/{fiscalQrManager-Be-r4oZj.esm.js → fiscalQrManager-ji0qDaTW.esm.js} +3 -3
  108. package/dist/flow-events.d.ts +1 -1
  109. package/dist/flow.d.ts +33 -18
  110. package/dist/flow.esm.js +82 -17
  111. package/dist/{flowCompletionService-ChMU2v79.esm.js → flowCompletionService-DvcH16XO.esm.js} +24 -3
  112. package/dist/{flowServices-g2tVWsJl.esm.js → flowServices-Ca2vKNt2.esm.js} +84 -139
  113. package/dist/geolocation.esm.js +2 -2
  114. package/dist/{geolocationManager-DLbvZwUB.esm.js → geolocationManager-CiG32lIm.esm.js} +2 -2
  115. package/dist/{geolocationStateMachine-CAJVongM.esm.js → geolocationStateMachine-5rnTEOuw.esm.js} +3 -3
  116. package/dist/government-validation.esm.js +2 -2
  117. package/dist/{governmentValidationManager-CkX9TEkh.esm.js → governmentValidationManager-BivVZNVe.esm.js} +2 -2
  118. package/dist/{governmentValidationStateMachine-PTPCP26N.esm.js → governmentValidationStateMachine-CeSDNgha.esm.js} +1 -1
  119. package/dist/home.d.ts +1 -1
  120. package/dist/home.esm.js +1 -1
  121. package/dist/http.esm.js +1 -1
  122. package/dist/id-ocr.d.ts +2 -2
  123. package/dist/id-ocr.esm.js +3 -19
  124. package/dist/id-selfie-flow.d.ts +3 -3
  125. package/dist/id-selfie-flow.esm.js +10 -9
  126. package/dist/id-verification.esm.js +2 -2
  127. package/dist/id.d.ts +4 -4
  128. package/dist/id.esm.js +4 -4
  129. package/dist/{idCaptureDefaults-MSQoqScU.esm.js → idCaptureDefaults-DBnOC28H.esm.js} +3 -3
  130. package/dist/{idCaptureManager-zZdTcpG1.esm.js → idCaptureManager-B5xqok0L.esm.js} +9 -8
  131. package/dist/{idCaptureManager-DzTfQ1Am.d.ts → idCaptureManager-CG8zbAp0.d.ts} +10 -8
  132. package/dist/{idCaptureServices-8OHinO0N.esm.js → idCaptureServices-BIF_7rub.esm.js} +27 -196
  133. package/dist/{idCaptureStateMachine-B3G6XoDG.esm.js → idCaptureStateMachine-B5cfgKvn.esm.js} +50 -22
  134. package/dist/idOcrCpfUtils-Nfln1Psb.esm.js +18 -0
  135. package/dist/{idOcrManager-DT3kPIB3.d.ts → idOcrManager-B5xeI2lg.d.ts} +3 -3
  136. package/dist/{idOcrManager-B64-fjWg.esm.js → idOcrManager-DNbVTMIu.esm.js} +2 -2
  137. package/dist/{idOcrStateMachine-B1aZnobs.esm.js → idOcrStateMachine-MAGnpWkb.esm.js} +8 -7
  138. package/dist/{idVerificationManager-_Kebv-Ue.esm.js → idVerificationManager-BEAkamNm.esm.js} +2 -2
  139. package/dist/{idVerificationStateMachine-DQn6c84z.esm.js → idVerificationStateMachine-D5mBN2Ye.esm.js} +1 -1
  140. package/dist/identity-reuse.esm.js +2 -2
  141. package/dist/{identityReuseManager-DDXkNVZi.esm.js → identityReuseManager-M8-BTjar.esm.js} +2 -2
  142. package/dist/{identityReuseStateMachine-Bcnkbjf8.esm.js → identityReuseStateMachine-D5bXgw9h.esm.js} +1 -1
  143. package/dist/{index-DEfwds5y.d.ts → index-Btj1EhiM.d.ts} +43 -19
  144. package/dist/{index-DMDAk85K.d.ts → index-CSPOoqah.d.ts} +1 -1
  145. package/dist/index.d.ts +1 -1
  146. package/dist/index.esm.js +1 -1
  147. package/dist/{invokeOnCaptureCallback-CXIBwBeE.esm.js → invokeOnCaptureCallback-C1-j4fsq.esm.js} +1 -1
  148. package/dist/kyb-checks.d.ts +3 -0
  149. package/dist/kyb-checks.esm.js +3 -0
  150. package/dist/kybChecksManager-CblEL97E.d.ts +95 -0
  151. package/dist/kybChecksManager-CnqwgKoV.esm.js +89 -0
  152. package/dist/kybChecksStateMachine-Be41K_NS.esm.js +719 -0
  153. package/dist/mandatory-consent.d.ts +2 -2
  154. package/dist/mandatory-consent.esm.js +2 -2
  155. package/dist/{mandatoryConsentManager-xx3mY-xw.d.ts → mandatoryConsentManager-CYOJd_IZ.d.ts} +20 -11
  156. package/dist/{mandatoryConsentManager-43W5d_8G.esm.js → mandatoryConsentManager-LFhUlLvO.esm.js} +2 -2
  157. package/dist/{mandatoryConsentStateMachine-CVlgdlnt.esm.js → mandatoryConsentStateMachine-DTSyDqQs.esm.js} +11 -5
  158. package/dist/mediaRecorderOptions-B9-IEVtV.esm.js +70 -0
  159. package/dist/multipartRecordingService-CCiRpByl.esm.js +407 -0
  160. package/dist/{permissionGuards-B3OPL8Si.esm.js → permissionGuards-DjQUR1du.esm.js} +1 -1
  161. package/dist/{permissionServices-DnBAN_hW.esm.js → permissionServices-CZpORUWY.esm.js} +8 -6
  162. package/dist/phone.esm.js +2 -2
  163. package/dist/phoneFormat-DEpESpz2.esm.js +87 -0
  164. package/dist/{phoneManager-C6jut_pz.esm.js → phoneManager-C-qD3p3N.esm.js} +3 -3
  165. package/dist/phoneServices-BdR1nmSO.esm.js +77 -0
  166. package/dist/{phoneStateMachine-T1-drWfG.esm.js → phoneStateMachine-2FMTdjtJ.esm.js} +20 -60
  167. package/dist/{processFaceMatch-BWme3kVV.esm.js → processFaceMatch-B1YnoBer.esm.js} +1 -1
  168. package/dist/qe-signature.esm.js +1 -1
  169. package/dist/recordingService-BVSCo0ac.esm.js +397 -0
  170. package/dist/redirect-to-mobile.esm.js +2 -2
  171. package/dist/{redirectToMobileManager-BJXC6Kx9.esm.js → redirectToMobileManager-CqyDfDxs.esm.js} +3 -3
  172. package/dist/{redirectToMobileStateMachine-BBMAc2Gb.esm.js → redirectToMobileStateMachine-CXqfo2Gd.esm.js} +40 -22
  173. package/dist/resolveForm-f9PhUo9j.esm.js +143 -0
  174. package/dist/{runChildModule-DPHTqSdF.esm.js → runChildModule-BmteMhR7.esm.js} +2 -2
  175. package/dist/{sdkVersion-C3_P-Qbq.esm.js → sdkVersion-KZROt6l3.esm.js} +1 -1
  176. package/dist/selfie.d.ts +4 -4
  177. package/dist/selfie.esm.js +10 -10
  178. package/dist/{selfieErrorUtils-BL0BLMnp.esm.js → selfieErrorUtils-fqxp645p.esm.js} +1 -1
  179. package/dist/{selfieManager-Cbliomv7.esm.js → selfieManager-A-n3k9Tu.esm.js} +5 -5
  180. package/dist/{selfieManager-BMmpUii2.d.ts → selfieManager-DREuBhXZ.d.ts} +1 -1
  181. package/dist/{selfieStateMachine-B5m_Kn0O.esm.js → selfieStateMachine-48PKdKrw.esm.js} +3 -3
  182. package/dist/{session-DAaAewMX.esm.js → session-D0DWDKp9.esm.js} +4 -4
  183. package/dist/session.d.ts +2 -2
  184. package/dist/session.esm.js +6 -6
  185. package/dist/{sessionInitializer-CWFT4dfw.esm.js → sessionInitializer-I92b2dmL.esm.js} +94 -24
  186. package/dist/{setup-CDAKwTr7.esm.js → setup-BpjzWqR1.esm.js} +25 -27
  187. package/dist/{setup-D9qt8YVU.d.ts → setup-CG6oLkAa.d.ts} +2 -2
  188. package/dist/signature.esm.js +2 -2
  189. package/dist/{signatureManager-BeEVCcsC.esm.js → signatureManager-M9vQBj19.esm.js} +2 -2
  190. package/dist/{signatureStateMachine-_1c1vSid.esm.js → signatureStateMachine-0_frzAN5.esm.js} +1 -1
  191. package/dist/{stats-BpMz-hTP.esm.js → stats-C2sigf9p.esm.js} +1 -1
  192. package/dist/stats.esm.js +1 -1
  193. package/dist/step-up.d.ts +378 -0
  194. package/dist/step-up.esm.js +639 -0
  195. package/dist/textRules-D4NRinKY.d.ts +41 -0
  196. package/dist/{tri-BajQnjbf.esm.js → tri-DaUNvo-o.esm.js} +29 -34
  197. package/dist/tri.d.ts +2 -2
  198. package/dist/tri.esm-Df5eKLsY.esm.js +2165 -0
  199. package/dist/tri.esm.js +2 -2
  200. package/dist/{trueSightService-BujtUIW6.esm.js → trueSightService-DHYTBCIn.esm.js} +4 -4
  201. package/dist/trust-graph.esm.js +1 -1
  202. package/dist/types-B-PIc0en.d.ts +115 -0
  203. package/dist/{types-C397LhmN.d.ts → types-BgRHw-dR.d.ts} +1 -1
  204. package/dist/{types-CJ7Yl9K-.d.ts → types-Bpo97EOh.d.ts} +4 -2
  205. package/dist/{types-xEEWCx1j.d.ts → types-BqlZSoZ-.d.ts} +5 -5
  206. package/dist/types-CTaL0XJz.d.ts +80 -0
  207. package/dist/{types-e8fCsvvk.d.ts → types-Cbm9J2yF.d.ts} +1 -1
  208. package/dist/{types--3HDl2SF.d.ts → types-CgihAhT_.d.ts} +3 -3
  209. package/dist/{types-ZTZelfbM.d.ts → types-CyNndVAT.d.ts} +14 -6
  210. package/dist/{types-B2FK_wYb.d.ts → types-DEa3taWc.d.ts} +9 -41
  211. package/dist/{types-PTZHRhGX.d.ts → types-P9LzsfRo.d.ts} +3 -2
  212. package/dist/{types-DuD8TRJU.d.ts → types-TisHEbBg.d.ts} +12 -4
  213. package/dist/types-kLsU6Jkt.d.ts +6 -0
  214. package/dist/{urlUtils-eYiyWjh0.esm.js → urlUtils-B2wagB5v.esm.js} +14 -1
  215. package/dist/usStates-CwOQ2kAx.esm.js +209 -0
  216. package/dist/video-selfie.d.ts +5 -4
  217. package/dist/video-selfie.esm.js +9 -7
  218. package/dist/{videoSelfieCameraWarmer-DjkPpoj_.esm.js → videoSelfieCameraWarmer-CTOpqhov.esm.js} +16 -14
  219. package/dist/{videoSelfieStepDetector-RfSmlFFW.d.ts → videoSelfieStepDetector-4XE2QI5q.d.ts} +4 -4
  220. package/dist/virtualCameraCheck-eFOm2C9q.esm.js +27 -0
  221. package/dist/{warmup-BkfxQZsC.esm.js → warmup-9iKKNNuW.esm.js} +69 -20
  222. package/dist/{warmup-BO57syF6.d.ts → warmup-BNhIuURi.d.ts} +18 -2
  223. package/dist/wasm.d.ts +9 -3
  224. package/dist/wasm.esm.js +3 -3
  225. package/dist/{wasmDsFlagSync-BhU5H2oR.esm.js → wasmDsFlagSync-lRIgn5Ic.esm.js} +1 -1
  226. package/dist/{wasmWebClient-DTj9auyA.esm.js → wasmWebClient-C3v3s_4H.esm.js} +34 -19
  227. package/dist/watchlist-for-business.esm.js +2 -2
  228. package/dist/watchlist.esm.js +2 -2
  229. package/dist/{watchlistForBusinessManager-CVay6-9A.esm.js → watchlistForBusinessManager-C1S5y5yj.esm.js} +2 -2
  230. package/dist/{watchlistForBusinessStateMachine-DA6K5na4.esm.js → watchlistForBusinessStateMachine-Bj_hnoK5.esm.js} +1 -1
  231. package/dist/{watchlistManager-B8gQ_rw3.esm.js → watchlistManager-BpegtZbc.esm.js} +2 -2
  232. package/dist/{watchlistStateMachine-CSi_ZhtT.esm.js → watchlistStateMachine-Bgkh1gra.esm.js} +1 -1
  233. package/dist/workflow.d.ts +226 -41
  234. package/dist/workflow.esm.js +163 -67
  235. package/package.json +21 -5
  236. package/dist/addressSearch-41sMcnJk.esm.js +0 -604
  237. package/dist/deepsightLoader-DMxtowCm.esm.js +0 -33
  238. package/dist/tri.esm-CzTNi5Q_.esm.js +0 -3826
  239. package/dist/types-D9r3zRfY.d.ts +0 -6
@@ -0,0 +1,397 @@
1
+ import { t as api, u as endpoints } from "./api-BSnbg4HO.esm.js";
2
+ import { t as BrowserLazyImportProvider } from "./BrowserLazyImportProvider-BhoA957O.esm.js";
3
+ import { r as createRecordingCompositor } from "./CameraCompositor-DN7NkJzV.esm.js";
4
+ import { t as getAdaptiveMediaRecorderOptions } from "./mediaRecorderOptions-B9-IEVtV.esm.js";
5
+ import { t as WorkerEncoderRecordingProvider } from "./WorkerEncoderRecordingProvider-CyCrQnZR.esm.js";
6
+ import { t as MultipartRecordingService } from "./multipartRecordingService-CCiRpByl.esm.js";
7
+ //#region ../infra/src/media/VideoTrimmer.ts
8
+ /** A trim that runs longer than this uploads the full recording instead. */
9
+ const TRIM_TIMEOUT_MS = 1e4;
10
+ const trimmer = BrowserLazyImportProvider.getInstance().create(() => import("./videoTrimByCopy-BFfAiNpv.esm.js").then((module) => module.trimLastNSecondsByCopy), {
11
+ label: "Video liveness",
12
+ moduleName: "mediabunny",
13
+ timeoutMs: 1e4,
14
+ disabledMessage: "the full recording will be uploaded untrimmed."
15
+ });
16
+ /** Starts loading the trimmer, e.g. when a recording that will be trimmed starts. */
17
+ function preloadVideoTrimmer() {
18
+ trimmer.load();
19
+ }
20
+ /**
21
+ * Keeps about the last `seconds` of a recording. Never rejects and never
22
+ * hangs: when the trimmer cannot load, fails, or takes longer than
23
+ * {@link TRIM_TIMEOUT_MS}, it resolves the untrimmed recording.
24
+ */
25
+ async function trimLastNSeconds(videoBlob, seconds) {
26
+ const trim = await trimmer.load();
27
+ if (!trim) return videoBlob;
28
+ let timeout;
29
+ try {
30
+ return await Promise.race([trim(videoBlob, seconds), new Promise((resolve) => {
31
+ timeout = setTimeout(() => {
32
+ console.warn("[Video liveness] Trimming timed out; the full recording will be uploaded untrimmed.");
33
+ resolve(videoBlob);
34
+ }, TRIM_TIMEOUT_MS);
35
+ })]);
36
+ } catch (error) {
37
+ console.warn("[Video liveness] Trimming failed; the full recording will be uploaded untrimmed.", error);
38
+ return videoBlob;
39
+ } finally {
40
+ clearTimeout(timeout);
41
+ }
42
+ }
43
+ //#endregion
44
+ //#region ../infra/src/providers/browser/LocalRecordingProvider.ts
45
+ function toBase64(videoBlob) {
46
+ return new Promise((resolve, reject) => {
47
+ const reader = new FileReader();
48
+ reader.onloadend = () => {
49
+ const base64 = reader.result.split(",")[1];
50
+ resolve(base64);
51
+ };
52
+ reader.onerror = () => reject(reader.error ?? /* @__PURE__ */ new Error("FileReader error"));
53
+ reader.readAsDataURL(videoBlob);
54
+ });
55
+ }
56
+ /** `MediaRecorderOptions.videoKeyFrameIntervalDuration`, see `startRecording`. */
57
+ const KEYFRAME_INTERVAL_MS = 1e3;
58
+ var LocalRecordingProvider = class {
59
+ constructor() {
60
+ this.mediaRecorder = null;
61
+ this._isRecording = false;
62
+ this._hasError = false;
63
+ this._error = null;
64
+ this.mimeType = "";
65
+ this.stream = null;
66
+ this.pauseRecordingBound = this.pauseRecording.bind(this);
67
+ }
68
+ get isRecording() {
69
+ return this._isRecording;
70
+ }
71
+ get hasError() {
72
+ return this._hasError;
73
+ }
74
+ get error() {
75
+ return this._error;
76
+ }
77
+ startRecording(stream) {
78
+ this.reset();
79
+ preloadVideoTrimmer();
80
+ this.registerEventListeners();
81
+ this.stream = stream;
82
+ try {
83
+ const options = getAdaptiveMediaRecorderOptions();
84
+ this.mimeType = options.mimeType;
85
+ const recorder = new MediaRecorder(stream.clone(), {
86
+ ...options,
87
+ videoKeyFrameIntervalDuration: KEYFRAME_INTERVAL_MS
88
+ });
89
+ recorder.onerror = (event) => {
90
+ this._error = `Recording error: ${event}`;
91
+ this._isRecording = false;
92
+ this._hasError = true;
93
+ };
94
+ recorder.start();
95
+ this.mediaRecorder = recorder;
96
+ this._isRecording = true;
97
+ this._error = null;
98
+ this._hasError = false;
99
+ } catch (err) {
100
+ this._error = `Failed to start recording: ${err}`;
101
+ this._hasError = true;
102
+ }
103
+ }
104
+ async stopRecording(trimSeconds, encrypt, generateChecksum) {
105
+ const recorder = this.mediaRecorder;
106
+ return new Promise((resolve, reject) => {
107
+ this.removeEventListeners();
108
+ if (recorder && this._isRecording) {
109
+ const chunks = [];
110
+ recorder.ondataavailable = (event) => {
111
+ if (event.data.size > 0) chunks.push(event.data);
112
+ };
113
+ recorder.onstop = async () => {
114
+ try {
115
+ const trimmedVideo = await trimLastNSeconds(new Blob(chunks, { type: this.mimeType }), trimSeconds);
116
+ const encryptedVideoBase64 = encrypt(await toBase64(trimmedVideo));
117
+ generateChecksum(await trimmedVideo.arrayBuffer());
118
+ this._isRecording = false;
119
+ resolve({
120
+ trimmedBlob: trimmedVideo,
121
+ encryptedVideo: encryptedVideoBase64
122
+ });
123
+ } catch (error) {
124
+ this._isRecording = false;
125
+ this._error = `Recording stop failed: ${error}`;
126
+ this._hasError = true;
127
+ reject(error);
128
+ }
129
+ };
130
+ recorder.stop();
131
+ this._isRecording = false;
132
+ } else resolve({
133
+ trimmedBlob: new Blob([], { type: this.mimeType }),
134
+ encryptedVideo: ""
135
+ });
136
+ recorder?.stream?.getTracks().forEach((track) => track.stop());
137
+ });
138
+ }
139
+ /**
140
+ * Discards the in-progress recording without producing a result: detaches
141
+ * the recorder's handlers, stops it, releases its cloned tracks and clears
142
+ * the flags. Idempotent, and safe after `stopRecording` or when never
143
+ * started. Mirrors `MultipartRecordingProvider.reset()` so an attempt that is
144
+ * released before finalization cannot leave a live camera clone behind
145
+ * (ENG-56648).
146
+ */
147
+ reset() {
148
+ this.removeEventListeners();
149
+ const recorder = this.mediaRecorder;
150
+ if (recorder) {
151
+ recorder.ondataavailable = null;
152
+ recorder.onerror = null;
153
+ recorder.onstop = null;
154
+ if (recorder.state !== "inactive") try {
155
+ recorder.stop();
156
+ } catch {}
157
+ recorder.stream?.getTracks().forEach((track) => track.stop());
158
+ this.mediaRecorder = null;
159
+ }
160
+ this.stream = null;
161
+ this._isRecording = false;
162
+ this._error = null;
163
+ this._hasError = false;
164
+ }
165
+ pauseRecording() {
166
+ if (!this._isRecording) return;
167
+ if (this.mediaRecorder?.state === "recording") try {
168
+ this.mediaRecorder.pause();
169
+ } catch {}
170
+ }
171
+ registerEventListeners() {
172
+ document.addEventListener("visibilitychange", this.pauseRecordingBound);
173
+ }
174
+ removeEventListeners() {
175
+ document.removeEventListener("visibilitychange", this.pauseRecordingBound);
176
+ }
177
+ };
178
+ //#endregion
179
+ //#region src/internal/recordings/recordingsRepository.ts
180
+ async function uploadDeepsightVideo(encryptedVideo, token) {
181
+ try {
182
+ return (await api.post(endpoints.deepsightVideoImport, {
183
+ video: encryptedVideo,
184
+ type: "selfie"
185
+ }, { headers: { "X-Incode-Hardware-Id": token } })).data.recordingId ?? "";
186
+ } catch {
187
+ return "";
188
+ }
189
+ }
190
+ //#endregion
191
+ //#region src/internal/faceCapture/recordingService.ts
192
+ /**
193
+ * Records on-device and uploads encrypted video for liveness.
194
+ */
195
+ var LocalRecordingService = class {
196
+ constructor(wasmUtil, sessionToken) {
197
+ this.recorder = new LocalRecordingProvider();
198
+ this.sessionToken = sessionToken;
199
+ this.wasmUtil = wasmUtil;
200
+ }
201
+ async start(stream) {
202
+ this.recorder.startRecording(stream);
203
+ this.wasmUtil.osv();
204
+ }
205
+ async stop() {
206
+ if (!this.recorder.isRecording) return { recordingId: null };
207
+ this.wasmUtil.oev();
208
+ const result = await this.recorder.stopRecording(10, (base64) => this.wasmUtil.encryptImage(base64), (buffer) => this.wasmUtil.ckvcks(buffer));
209
+ if (!this.sessionToken) return { recordingId: null };
210
+ return { recordingId: await uploadDeepsightVideo(result.encryptedVideo, this.sessionToken) };
211
+ }
212
+ prepareUpload() {
213
+ return this.stop();
214
+ }
215
+ async stopAndGetVideo() {
216
+ if (!this.recorder.isRecording) return { videoBase64: void 0 };
217
+ try {
218
+ this.wasmUtil.oev();
219
+ const videoBase64 = (await this.recorder.stopRecording(10, (base64) => base64, () => {})).encryptedVideo;
220
+ return { videoBase64: videoBase64 ? videoBase64 : void 0 };
221
+ } catch {
222
+ return { videoBase64: void 0 };
223
+ }
224
+ }
225
+ cleanup() {
226
+ this.recorder.reset();
227
+ }
228
+ };
229
+ /**
230
+ * Records a regular Selfie capture locally and streams it through the scoped
231
+ * video-selfie-service multipart protocol. The recording is associated with
232
+ * the interview asynchronously by the backend's `selfie` scope consumer, so
233
+ * its upload id must not be forwarded to `/omni/add/face` as a legacy
234
+ * `recordingId`.
235
+ *
236
+ * The recording is scoped to the capture step (ENG-56648). The recorder
237
+ * records a stable `CameraCompositor` stream instead of a raw camera clone, so
238
+ * every attempt can end its own clone before PRC and POC run and the next
239
+ * attempt swaps a fresh clone into the same multipart upload. The owning
240
+ * controller completes the upload once the backend accepts a capture or the
241
+ * step ends without a retry.
242
+ */
243
+ var MultipartFaceRecordingService = class {
244
+ constructor() {
245
+ this.recordingCompositor = createRecordingCompositor();
246
+ this.service = new MultipartRecordingService("selfie", new WorkerEncoderRecordingProvider(this.recordingCompositor));
247
+ this.audioSource = [];
248
+ this.needsVideoSourceReplacement = false;
249
+ this.pausedForAttempt = false;
250
+ this.startInFlight = false;
251
+ this.suspendRequested = false;
252
+ this.stopping = false;
253
+ }
254
+ async start(stream) {
255
+ if (this.stopping) throw new Error("Face recording already completed");
256
+ if (this.compositor) {
257
+ await this.resume(stream);
258
+ return;
259
+ }
260
+ const recordingSource = stream.clone();
261
+ const compositor = this.recordingCompositor;
262
+ this.startInFlight = true;
263
+ try {
264
+ const composite = compositor.start(recordingSource);
265
+ await this.service.start(composite);
266
+ } catch (error) {
267
+ compositor.stop();
268
+ recordingSource.getTracks().forEach((track) => track.stop());
269
+ this.service.cleanup();
270
+ throw error;
271
+ } finally {
272
+ this.startInFlight = false;
273
+ }
274
+ if (this.stopping) {
275
+ compositor.stop();
276
+ recordingSource.getTracks().forEach((track) => track.stop());
277
+ this.service.cleanup();
278
+ return;
279
+ }
280
+ this.compositor = compositor;
281
+ this.recordingSource = recordingSource;
282
+ this.audioSource = recordingSource.getAudioTracks();
283
+ if (this.suspendRequested) {
284
+ this.suspendRequested = false;
285
+ this.suspend();
286
+ }
287
+ }
288
+ /**
289
+ * Pauses the container and ends the camera clone on the calling thread. The
290
+ * composite stream and the upload stay open for the next attempt.
291
+ */
292
+ suspend() {
293
+ if (this.stopping) return;
294
+ if (!this.compositor) {
295
+ this.suspendRequested = this.startInFlight;
296
+ return;
297
+ }
298
+ if (!this.pausedForAttempt) this.pausedForAttempt = this.service.pause();
299
+ this.releaseCameraClone({ keepAudio: true });
300
+ this.needsVideoSourceReplacement = true;
301
+ }
302
+ async prepareUpload() {
303
+ this.suspend();
304
+ return { recordingId: null };
305
+ }
306
+ async stop() {
307
+ await this.complete();
308
+ return { recordingId: null };
309
+ }
310
+ pauseForBackground() {
311
+ this.suspend();
312
+ }
313
+ async resumeFromBackground(stream) {
314
+ if (!this.compositor || this.stopping) return;
315
+ await this.resume(stream);
316
+ }
317
+ async stopAndGetVideo() {
318
+ await this.complete();
319
+ return { videoBase64: void 0 };
320
+ }
321
+ cleanup() {
322
+ this.suspendRequested = false;
323
+ this.pausedForAttempt = false;
324
+ this.needsVideoSourceReplacement = false;
325
+ this.releaseCameraClone({ keepAudio: false });
326
+ this.compositor?.stop();
327
+ this.compositor = void 0;
328
+ this.recordingSource = void 0;
329
+ this.audioSource = [];
330
+ this.service.cleanup();
331
+ }
332
+ /** Swaps this attempt's camera clone into the composite and resumes. */
333
+ async resume(stream) {
334
+ const compositor = this.compositor;
335
+ if (!compositor) return;
336
+ if (this.needsVideoSourceReplacement) {
337
+ const recordingSource = stream.clone();
338
+ recordingSource.getAudioTracks().forEach((track) => track.stop());
339
+ compositor.switchVideo(recordingSource);
340
+ this.needsVideoSourceReplacement = false;
341
+ this.recordingSource = recordingSource;
342
+ const result = await compositor.resume();
343
+ if (result !== "resumed") throw new Error(`Face recording camera did not resume: ${result}`);
344
+ }
345
+ if (this.pausedForAttempt && !this.service.resume()) throw new Error("Face recording did not resume");
346
+ this.pausedForAttempt = false;
347
+ }
348
+ /**
349
+ * Completes the scoped upload. The camera clone ends synchronously before the
350
+ * drain so a step that ends mid-attempt never pins the camera; the composite
351
+ * stays alive until the recorder has emitted its final chunk.
352
+ */
353
+ async complete() {
354
+ this.stopping = true;
355
+ this.suspendRequested = false;
356
+ this.releaseCameraClone({ keepAudio: false });
357
+ try {
358
+ await this.service.stop();
359
+ } finally {
360
+ this.compositor?.stop();
361
+ this.compositor = void 0;
362
+ this.recordingSource = void 0;
363
+ this.audioSource = [];
364
+ this.pausedForAttempt = false;
365
+ this.needsVideoSourceReplacement = false;
366
+ }
367
+ }
368
+ releaseCameraClone(options) {
369
+ try {
370
+ this.compositor?.pause();
371
+ } catch {}
372
+ const tracks = options.keepAudio ? this.recordingSource?.getVideoTracks() ?? [] : /* @__PURE__ */ new Set([...this.recordingSource?.getTracks() ?? [], ...this.audioSource]);
373
+ for (const track of tracks) try {
374
+ track.stop();
375
+ } catch {}
376
+ }
377
+ };
378
+ /**
379
+ * Creates the recording service for the current configuration.
380
+ *
381
+ * Order of precedence:
382
+ * 1. `onDeviceFaceResultsSubmissionEnabled === true` → no recording. The
383
+ * on-device workflow never uploads media, only the staged face-results
384
+ * JSON via `WebApi.postFaceResults`. Mirrors V1's
385
+ * `FaceFlowManager.setRecorders()` early return.
386
+ * 2. `deepsightLiveness === 'VIDEOLIVENESS'` → local Deepsight recorder.
387
+ * 3. `enableFaceRecording === true` → scoped multipart recorder.
388
+ * 4. otherwise → no recording.
389
+ */
390
+ function createRecordingService(params) {
391
+ if (params.config.onDeviceFaceResultsSubmissionEnabled === true) return;
392
+ if (params.localDelivery === true) return params.config.enableFaceRecording === true || params.config.deepsightLiveness === "VIDEOLIVENESS" ? new LocalRecordingService(params.wasmUtil, null) : void 0;
393
+ if (params.config.deepsightLiveness === "VIDEOLIVENESS") return new LocalRecordingService(params.wasmUtil, params.sessionToken);
394
+ if (params.config.enableFaceRecording === true) return new MultipartFaceRecordingService();
395
+ }
396
+ //#endregion
397
+ export { createRecordingService };
@@ -1,3 +1,3 @@
1
- import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices } from "./redirectToMobileStateMachine-BBMAc2Gb.esm.js";
2
- import { n as createRedirectToMobileManagerFromActor, t as createRedirectToMobileManager } from "./redirectToMobileManager-BJXC6Kx9.esm.js";
1
+ import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices } from "./redirectToMobileStateMachine-CXqfo2Gd.esm.js";
2
+ import { n as createRedirectToMobileManagerFromActor, t as createRedirectToMobileManager } from "./redirectToMobileManager-CqyDfDxs.esm.js";
3
3
  export { createRedirectToMobileManager, createRedirectToMobileManagerFromActor, defaultRedirectToMobileServices, redirectToMobileMachine };
@@ -1,8 +1,8 @@
1
- import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-CQteqXfy.esm.js";
1
+ import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-C7h7oaTE.esm.js";
2
2
  import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
3
3
  import { s as createActor, u as createManager } from "./xstate.esm-DSajW7CJ.esm.js";
4
4
  import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-8Gzepa_A.esm.js";
5
- import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices, t as canResendSmsFromContext } from "./redirectToMobileStateMachine-BBMAc2Gb.esm.js";
5
+ import { n as redirectToMobileMachine, r as defaultRedirectToMobileServices, t as canResendSmsFromContext } from "./redirectToMobileStateMachine-CXqfo2Gd.esm.js";
6
6
  //#region src/modules/redirect-to-mobile/redirectToMobileActor.ts
7
7
  const POLL_INTERVAL_MS = 5e3;
8
8
  const QR_REFRESH_INTERVAL_MS = 5e3;
@@ -58,7 +58,7 @@ function mapState(snapshot) {
58
58
  const typedSnapshot = snapshot;
59
59
  const { context } = typedSnapshot;
60
60
  if (typedSnapshot.matches("idle")) return { status: "idle" };
61
- if (typedSnapshot.matches("generatingUrl") || typedSnapshot.matches("loadingStartInfo")) return { status: "loading" };
61
+ if (typedSnapshot.matches("generatingUrl")) return { status: "loading" };
62
62
  if (typedSnapshot.matches("showingQr")) return {
63
63
  status: "redirecting",
64
64
  redirectUrl: context.redirectUrl,
@@ -1,8 +1,8 @@
1
- import { t as api, u as endpoints } from "./api-BO8JA7Pf.esm.js";
1
+ import { t as api, u as endpoints } from "./api-BSnbg4HO.esm.js";
2
2
  import { t as BrowserTimerProvider } from "./BrowserTimerProvider-BXhgNxLt.esm.js";
3
3
  import { i as assign, t as setup } from "./xstate.esm-DSajW7CJ.esm.js";
4
4
  import { n as fromPromise, t as fromCallback } from "./xstate-actors.esm-8Gzepa_A.esm.js";
5
- import { n as getUrlSearchParam, r as resolveAgainstPageOrigin, t as buildUrlWithSearchParams } from "./urlUtils-eYiyWjh0.esm.js";
5
+ import { i as resolveAgainstPageOrigin, r as getUrlSearchParam, t as buildUrlWithSearchParams } from "./urlUtils-B2wagB5v.esm.js";
6
6
  //#region src/modules/redirect-to-mobile/redirectToMobileServices.ts
7
7
  async function fetchRedirectUrl(signal) {
8
8
  const res = await api.get(endpoints.onboardingUrl, { signal });
@@ -210,27 +210,45 @@ const redirectToMobileMachine = setup({
210
210
  guard: "hasInvalidUrl",
211
211
  actions: "setInvalidUrlError"
212
212
  }, { target: "generatingUrl" }] } },
213
- generatingUrl: { invoke: {
214
- id: "fetchRedirectUrl",
215
- src: "fetchRedirectUrl",
216
- onDone: {
217
- target: "loadingStartInfo",
218
- actions: "setBaseUrl"
219
- },
220
- onError: {
221
- target: "error",
222
- actions: "setError"
223
- }
224
- } },
225
- loadingStartInfo: { invoke: {
226
- id: "fetchStartInfo",
227
- src: "fetchStartInfo",
228
- onDone: {
229
- target: "showingQr",
230
- actions: "setStartInfo"
213
+ generatingUrl: {
214
+ type: "parallel",
215
+ states: {
216
+ redirectUrl: {
217
+ initial: "loading",
218
+ states: {
219
+ loading: { invoke: {
220
+ id: "fetchRedirectUrl",
221
+ src: "fetchRedirectUrl",
222
+ onDone: {
223
+ target: "done",
224
+ actions: "setBaseUrl"
225
+ },
226
+ onError: {
227
+ target: "#redirectToMobile.error",
228
+ actions: "setError"
229
+ }
230
+ } },
231
+ done: { type: "final" }
232
+ }
233
+ },
234
+ startInfo: {
235
+ initial: "loading",
236
+ states: {
237
+ loading: { invoke: {
238
+ id: "fetchStartInfo",
239
+ src: "fetchStartInfo",
240
+ onDone: {
241
+ target: "done",
242
+ actions: "setStartInfo"
243
+ },
244
+ onError: { target: "done" }
245
+ } },
246
+ done: { type: "final" }
247
+ }
248
+ }
231
249
  },
232
- onError: { target: "showingQr" }
233
- } },
250
+ onDone: { target: "showingQr" }
251
+ },
234
252
  showingQr: {
235
253
  type: "parallel",
236
254
  states: {
@@ -0,0 +1,143 @@
1
+ //#region src/shared/displayErrors.ts
2
+ const DYNAMIC_REQUIRED_KEY = "verification.errors.fieldRequiredDynamic";
3
+ //#endregion
4
+ //#region src/internal/forms/checkSupport.ts
5
+ const GROUP_POLICIES = /* @__PURE__ */ new Set(["hide", "forceShow"]);
6
+ /**
7
+ * Compares `major.minor` vocabulary versions. The compiler's twin is
8
+ * `compareVersions` in `packages/form-definitions/scripts/lib/checks.mjs`;
9
+ * both are tested against that package's `fixtures/vocabularyVersions.json`.
10
+ */
11
+ function compareVocabulary(a, b) {
12
+ const [aMajor = 0, aMinor = 0] = a.split(".").map(Number);
13
+ const [bMajor = 0, bMinor = 0] = b.split(".").map(Number);
14
+ return aMajor - bMajor || aMinor - bMinor;
15
+ }
16
+ /**
17
+ * Whether this build can use a definition. Any id it doesn't implement makes
18
+ * the definition unsupported, so the caller falls back to its bundled
19
+ * definition or current form. Presentation hints (widget, keyboard, autofill)
20
+ * never fail: an unknown hint falls back to the platform default.
21
+ */
22
+ function checkSupport(definition, ids) {
23
+ const problems = [];
24
+ const need = (category, known, id, path) => {
25
+ if (!known.has(id)) problems.push({
26
+ category,
27
+ id,
28
+ path
29
+ });
30
+ };
31
+ if (!ids.schemaVersions.includes(definition.schemaVersion)) problems.push({
32
+ category: "schemaVersion",
33
+ id: String(definition.schemaVersion),
34
+ path: "schemaVersion"
35
+ });
36
+ if (compareVocabulary(definition.vocabulary, ids.vocabulary) > 0) problems.push({
37
+ category: "vocabulary",
38
+ id: definition.vocabulary,
39
+ path: "vocabulary"
40
+ });
41
+ const checkField = (field, path) => {
42
+ need("kind", ids.kinds, field.kind, `${path}.kind`);
43
+ need("group", ids.groups, field.group, `${path}.group`);
44
+ field.rules?.forEach((rule, i) => need("rule", ids.rules, rule.id, `${path}.rules[${i}]`));
45
+ field.input?.format?.forEach((t, i) => need("transform", ids.transforms, t.id, `${path}.input.format[${i}]`));
46
+ field.payload?.transforms?.forEach((t, i) => need("transform", ids.transforms, t.id, `${path}.payload.transforms[${i}]`));
47
+ if (field.optionsRef) need("optionList", ids.optionLists, field.optionsRef, `${path}.optionsRef`);
48
+ if (field.suggestionsRef) need("optionList", ids.optionLists, field.suggestionsRef, `${path}.suggestionsRef`);
49
+ field.requiredWhen?.forEach((condition, i) => {
50
+ const keys = Object.keys(condition);
51
+ if (keys.length !== 1) problems.push({
52
+ category: "condition",
53
+ id: keys.join("+") || "(empty)",
54
+ path: `${path}.requiredWhen[${i}]`
55
+ });
56
+ for (const key of keys) need("condition", ids.conditions, key, `${path}.requiredWhen[${i}]`);
57
+ });
58
+ field.prefill?.forEach((id, i) => need("prefillSource", ids.prefillSources, id, `${path}.prefill[${i}]`));
59
+ const lock = field.phone?.lockCountry;
60
+ if (typeof lock === "string" && lock !== "whenPhoneRisk") problems.push({
61
+ category: "phoneLock",
62
+ id: lock,
63
+ path: `${path}.phone`
64
+ });
65
+ };
66
+ definition.fields.forEach((field) => checkField(field, `fields.${field.name}`));
67
+ definition.groups?.forEach((policy) => {
68
+ need("group", ids.groups, policy.group, `groups.${policy.group}`);
69
+ if (!GROUP_POLICIES.has(policy.whenDisabled)) problems.push({
70
+ category: "groupPolicy",
71
+ id: policy.whenDisabled,
72
+ path: `groups.${policy.group}`
73
+ });
74
+ });
75
+ definition.groupRules?.forEach((rule, i) => {
76
+ need("groupRule", ids.groupRules, rule.id, `groupRules[${i}]`);
77
+ const cases = rule.id === "rulesByOption" ? rule.params?.cases : void 0;
78
+ if (cases && typeof cases === "object" && !Array.isArray(cases)) for (const [value, rules] of Object.entries(cases)) {
79
+ if (!Array.isArray(rules)) continue;
80
+ rules.forEach((ref, j) => {
81
+ const id = ref?.id;
82
+ need("rule", ids.rules, typeof id === "string" ? id : "(missing)", `groupRules[${i}].params.cases.${value}[${j}]`);
83
+ });
84
+ }
85
+ });
86
+ definition.collections?.forEach((collection) => {
87
+ need("group", ids.groups, collection.group, `collections.${collection.id}`);
88
+ collection.fields.forEach((field) => checkField(field, `collections.${collection.id}.fields.${field.name}`));
89
+ });
90
+ return problems.length === 0 ? { supported: true } : {
91
+ supported: false,
92
+ problems
93
+ };
94
+ }
95
+ //#endregion
96
+ //#region src/internal/forms/resolveForm.ts
97
+ const FORCE_SHOW = "forceShow";
98
+ const WHEN_PHONE_RISK = "whenPhoneRisk";
99
+ /**
100
+ * Resolves a definition against module configuration: which fields show,
101
+ * which are required, whether the phone is locked, and which group rules and
102
+ * collections apply. Pure and synchronous, so it runs inside an assign action.
103
+ *
104
+ * Call `checkSupport` first for any definition that wasn't bundled with this
105
+ * build; `resolveForm` ignores ids it doesn't know.
106
+ */
107
+ function resolveForm(definition, context) {
108
+ const forcedGroups = new Set((definition.groups ?? []).filter((policy) => policy.whenDisabled === FORCE_SHOW).map((policy) => policy.group));
109
+ const isOn = (group) => context.groups[group] === true;
110
+ const isShown = (group) => isOn(group) || forcedGroups.has(group);
111
+ const riskAddons = new Set(context.riskAddons ?? []);
112
+ const shownFields = definition.fields.filter((field) => isShown(field.group));
113
+ const shownNames = new Set(shownFields.map((field) => field.name));
114
+ const fields = shownFields.map((field) => {
115
+ const conditions = field.requiredWhen ?? [];
116
+ const addonRequired = conditions.some((condition) => condition.riskAddon !== void 0 && riskAddons.has(condition.riskAddon));
117
+ const requiredIfFilled = conditions.map((condition) => condition.fieldFilled).filter((name) => name !== void 0 && shownNames.has(name));
118
+ const lock = field.phone?.lockCountry;
119
+ return {
120
+ field,
121
+ required: field.required === true || addonRequired,
122
+ requiredIfFilled,
123
+ forced: !isOn(field.group),
124
+ phoneLocked: field.kind === "phone" && (lock === true || lock === WHEN_PHONE_RISK && context.phoneRisk === true)
125
+ };
126
+ });
127
+ const order = shownFields.map((field) => field.name);
128
+ return {
129
+ definition,
130
+ fields,
131
+ groupRules: (definition.groupRules ?? []).map((rule) => ({
132
+ rule,
133
+ fields: order.filter((name) => rule.fields.includes(name))
134
+ })).filter((resolved) => resolved.fields.length > 0),
135
+ collections: (definition.collections ?? []).filter((collection) => isShown(collection.group)).map((collection) => ({
136
+ collection,
137
+ min: collection.min ?? 0,
138
+ max: collection.max
139
+ }))
140
+ };
141
+ }
142
+ //#endregion
143
+ export { checkSupport as n, DYNAMIC_REQUIRED_KEY as r, resolveForm as t };
@@ -1,6 +1,6 @@
1
1
  import { n as getTimestamp } from "./IBrowserEnvironmentCapability-D7JG7ML3.esm.js";
2
- import { w as createEventBus } from "./events-CQteqXfy.esm.js";
3
- import { a as notifyTrueSightManagerStopped, i as notifyTrueSightFlowEvent } from "./trueSightService-BujtUIW6.esm.js";
2
+ import { w as createEventBus } from "./events-C7h7oaTE.esm.js";
3
+ import { a as notifyTrueSightManagerStopped, i as notifyTrueSightFlowEvent } from "./trueSightService-DHYTBCIn.esm.js";
4
4
  import { s as createActor } from "./xstate.esm-DSajW7CJ.esm.js";
5
5
  import { t as fromCallback } from "./xstate-actors.esm-8Gzepa_A.esm.js";
6
6
  //#region src/internal/flow-events/flowEvents.ts
@@ -1,4 +1,4 @@
1
1
  //#region src/internal/version/sdkVersion.ts
2
- const SDK_VERSION = "2.4.1-agentic";
2
+ const SDK_VERSION = "2.4.1-agentic.10";
3
3
  //#endregion
4
4
  export { SDK_VERSION as t };
package/dist/selfie.d.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  import { t as IVisibilityObserverCapability } from "./IVisibilityObserverCapability-D4tvIB5v.js";
2
- import { _ as SelfieCaptureOnlyConfig, a as SelfieCaptureOnlyMachine, c as SelfieActor, g as processFace, h as ProcessFaceResponse, i as SelfieCaptureOnlyActor, l as SelfieMachine, n as FaceCaptureManagerState, o as selfieCaptureOnlyMachine, r as CreateSelfieCaptureOnlyActorOptions, t as FaceCaptureManager, u as selfieMachine, v as SelfieConfig } from "./faceCaptureManagerFactory-C-xKdj-d.js";
2
+ import { _ as SelfieCaptureOnlyConfig, a as SelfieCaptureOnlyMachine, c as SelfieActor, g as processFace, h as ProcessFaceResponse, i as SelfieCaptureOnlyActor, l as SelfieMachine, n as FaceCaptureManagerState, o as selfieCaptureOnlyMachine, r as CreateSelfieCaptureOnlyActorOptions, t as FaceCaptureManager, u as selfieMachine, v as SelfieConfig } from "./faceCaptureManagerFactory-BVwVGa3z.js";
3
3
  import { n as PermissionStatus, t as PermissionResult } from "./types-BEwVKkLJ.js";
4
- import { a as FaceCapturedImageData, i as FaceCaptureOnlyResponse, n as DetectionStatus, o as FaceErrorCode } from "./types--3HDl2SF.js";
5
- import { n as DeepsightService } from "./StreamCanvasCapture-C3xNfOsv.js";
4
+ import { a as FaceCapturedImageData, i as FaceCaptureOnlyResponse, n as DetectionStatus, o as FaceErrorCode } from "./types-CgihAhT_.js";
5
+ import { n as DeepsightService } from "./StreamCanvasCapture-ixfy84ys.js";
6
6
  import { t as CameraStream } from "./camera-9wWD-pwg.js";
7
- import { i as createSelfieManagerFromActor, n as SelfieState, r as createSelfieManager, t as SelfieManager } from "./selfieManager-BMmpUii2.js";
7
+ import { i as createSelfieManagerFromActor, n as SelfieState, r as createSelfieManager, t as SelfieManager } from "./selfieManager-DREuBhXZ.js";
8
8
  //#region src/modules/selfie/selfieCaptureOnlyManager.d.ts
9
9
  type SelfieCaptureOnlyState = FaceCaptureManagerState;
10
10
  type SelfieCaptureOnlyManager = FaceCaptureManager;