@incodetech/core 2.2.0 → 2.3.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (258) hide show
  1. package/THIRD_PARTY_NOTICES.txt +281 -0
  2. package/dist/BaseWasmProvider-Dyi6dKp1.d.ts +65 -0
  3. package/dist/{BrowserDiagnosticsCryptoProvider-B8vorxN5.esm.js → BrowserDiagnosticsCryptoProvider-C_9o3L2L.esm.js} +1 -1
  4. package/dist/{BrowserVisibilityObserverProvider-BX1BiLDK.esm.js → BrowserVisibilityObserverProvider-BrJN1B8A.esm.js} +2 -0
  5. package/dist/FaceDetectionProvider-DTetAE8H.esm.js +476 -0
  6. package/dist/FaceDetectionProvider-LdZ47bWy.d.ts +36 -0
  7. package/dist/{IIdCaptureCapability-DHTT3FC2.d.ts → IIdCaptureCapability-RNiFhvXR.d.ts} +7 -33
  8. package/dist/IWasmUtilCapability-CXXDA5l1.d.ts +159 -0
  9. package/dist/{MotionSensorProvider-DGiV77J_.esm.js → MotionSensorProvider-BgTYwg9L.esm.js} +1 -1
  10. package/dist/{deepsightService-DLVQS_RH.d.ts → StreamCanvasCapture-B3YT2Bt6.d.ts} +54 -41
  11. package/dist/{StreamCanvasCapture-D2XcXCZ4.esm.js → StreamCanvasCapture-C9jtgBdT.esm.js} +2 -2
  12. package/dist/{addressSearch-D1XpBdUS.esm.js → addressSearch-BRSu_aGA.esm.js} +1 -1
  13. package/dist/advanceableErrors-CpF2cBy6.esm.js +21 -0
  14. package/dist/ae-signature.d.ts +4 -2
  15. package/dist/ae-signature.esm.js +1 -1
  16. package/dist/antifraud.esm.js +2 -2
  17. package/dist/{antifraudManager-CQFNgSPt.esm.js → antifraudManager-Bg9ynGum.esm.js} +2 -2
  18. package/dist/{antifraudStateMachine-Bf_JVNwn.esm.js → antifraudStateMachine-BHxehiJZ.esm.js} +1 -1
  19. package/dist/{apiError-BA1d_au0.esm.js → apiError-D0v5hFyN.esm.js} +14 -2
  20. package/dist/authentication.d.ts +3 -3
  21. package/dist/authentication.esm.js +2 -2
  22. package/dist/{authenticationManager-zh9TC62P.esm.js → authenticationManager-C4B4-29g.esm.js} +5 -5
  23. package/dist/{authenticationManager-BBMGTcwW.d.ts → authenticationManager-DXTIUcma.d.ts} +7 -1
  24. package/dist/{authenticationStateMachine-xzi-vnvE.esm.js → authenticationStateMachine-DJ0zUm-A.esm.js} +6 -62
  25. package/dist/avatar.d.ts +1 -2
  26. package/dist/avatar.esm.js +1 -1
  27. package/dist/{backCameraStream-CUeYm5eu.esm.js → backCameraStream-BOtyQowf.esm.js} +83 -22
  28. package/dist/{camera-_2sXMXiF.esm.js → camera-sIa9ceW2.esm.js} +19 -1
  29. package/dist/camera.esm.js +1 -1
  30. package/dist/{canvas-E1zGkel4.esm.js → canvas-BxFzWTt-.esm.js} +19 -0
  31. package/dist/certificate-issuance.d.ts +2 -302
  32. package/dist/certificate-issuance.esm.js +3 -66
  33. package/dist/certificateIssuanceManager-Bfvkq7Cy.esm.js +69 -0
  34. package/dist/certificateIssuanceManager-DCgEidHz.d.ts +312 -0
  35. package/dist/{certificateIssuanceStateMachine-D_R92TYu.esm.js → certificateIssuanceStateMachine-BBD5h8c4.esm.js} +1 -1
  36. package/dist/consent.d.ts +1 -1
  37. package/dist/consent.esm.js +2 -2
  38. package/dist/{consentManager-BxjpLZAG.esm.js → consentManager-B5Vqdez-.esm.js} +2 -2
  39. package/dist/{consentManager-3Pbtj-RV.d.ts → consentManager-uhDPdU6i.d.ts} +4 -4
  40. package/dist/{consentStateMachine-D9D4ON8Z.esm.js → consentStateMachine-DbUmqWgV.esm.js} +1 -1
  41. package/dist/createCameraCycleOwnership-DQ5-F2oW.esm.js +826 -0
  42. package/dist/{createFaceAvatar-DQKaRise.esm.js → createFaceAvatar-BNHdeFj8.esm.js} +2 -2
  43. package/dist/createFaceAvatar-BlcTYgJv.d.ts +497 -0
  44. package/dist/cross-document-data-match.esm.js +1 -1
  45. package/dist/{crossDocumentDataMatchManager-CGT0V6RV.esm.js → crossDocumentDataMatchManager-QMOGwHXR.esm.js} +2 -2
  46. package/dist/curp-validation.d.ts +1 -1
  47. package/dist/curp-validation.esm.js +2 -2
  48. package/dist/{curpValidationManager-6Nmkn5u1.esm.js → curpValidationManager-D1ppROcF.esm.js} +2 -2
  49. package/dist/{curpValidationManager-DVGr7Fq7.d.ts → curpValidationManager-SSKNrm5Z.d.ts} +1 -1
  50. package/dist/{curpValidationStateMachine-Ds7KMacK.esm.js → curpValidationStateMachine-DvUPC_8S.esm.js} +1 -1
  51. package/dist/custom-fields.d.ts +2 -114
  52. package/dist/custom-fields.esm.js +2 -232
  53. package/dist/custom-watchlist.d.ts +2 -51
  54. package/dist/custom-watchlist.esm.js +3 -70
  55. package/dist/customFieldsManager-2j_PBq4U.esm.js +264 -0
  56. package/dist/customFieldsManager-8-W2KY4n.d.ts +141 -0
  57. package/dist/customWatchlistManager-DUVrEdw9.esm.js +73 -0
  58. package/dist/customWatchlistManager-PBWHr_oM.d.ts +64 -0
  59. package/dist/{customWatchlistStateMachine-YWSgKLbF.esm.js → customWatchlistStateMachine-qZVgkKgP.esm.js} +1 -1
  60. package/dist/{deepsightLoader--wMKWECS.esm.js → deepsightLoader-Dm7ejW4v.esm.js} +27 -71
  61. package/dist/device.d.ts +25 -2
  62. package/dist/device.esm.js +69 -7
  63. package/dist/document-capture.d.ts +2 -2
  64. package/dist/document-capture.esm.js +2 -2
  65. package/dist/{documentCaptureManager-DsQQhWry.esm.js → documentCaptureManager-DR_Wv-3H.esm.js} +2 -2
  66. package/dist/{documentCaptureManager-B3t0ydtg.d.ts → documentCaptureManager-DensIj5F.d.ts} +83 -83
  67. package/dist/{documentCaptureStateMachine-BM4Ex_5x.esm.js → documentCaptureStateMachine-CWOATHfE.esm.js} +5 -5
  68. package/dist/dynamic-forms.d.ts +1 -1
  69. package/dist/dynamic-forms.esm.js +2 -2
  70. package/dist/{dynamicFormsManager-fhK0yINk.d.ts → dynamicFormsManager-D5R_uxLQ.d.ts} +25 -3
  71. package/dist/{dynamicFormsManager-fFVIRBNv.esm.js → dynamicFormsManager-Dt98SDfV.esm.js} +16 -5
  72. package/dist/{dynamicFormsStateMachine-D6D7oEYk.esm.js → dynamicFormsStateMachine-obKr4IIp.esm.js} +35 -3
  73. package/dist/ekyb.d.ts +1 -1
  74. package/dist/ekyb.esm.js +3 -3
  75. package/dist/{ekybManager-Y3MkoXpC.esm.js → ekybManager-DNZKrKF3.esm.js} +2 -2
  76. package/dist/{ekybStateMachine-3nlnqdlr.esm.js → ekybStateMachine-DjhHQXZ8.esm.js} +3 -3
  77. package/dist/ekyc.esm.js +2 -2
  78. package/dist/{ekycManager-DgT48ky6.esm.js → ekycManager-CmQBpeiI.esm.js} +2 -2
  79. package/dist/{ekycStateMachine-CQwqiR-R.esm.js → ekycStateMachine-CmdW2gVm.esm.js} +2 -2
  80. package/dist/electronic-signature.d.ts +3 -3
  81. package/dist/electronic-signature.esm.js +2 -2
  82. package/dist/electronicSignatureManager-Ds-KEVTq.d.ts +2786 -0
  83. package/dist/{electronicSignatureManager-DGbAJ00W.esm.js → electronicSignatureManager-DzulxM4_.esm.js} +357 -51
  84. package/dist/email.esm.js +2 -2
  85. package/dist/{emailManager-BY0jeYwR.esm.js → emailManager-B5ek_UfM.esm.js} +2 -2
  86. package/dist/{emailStateMachine-Crw8QVmc.esm.js → emailStateMachine-CyPFZ7dW.esm.js} +1 -1
  87. package/dist/{endpoints-CCzL3XD_.esm.js → endpoints-D3B9mUHh.esm.js} +24 -7
  88. package/dist/{events-DYiyoSlx.esm.js → events-ijlbX_Wx.esm.js} +2 -2
  89. package/dist/events.d.ts +1 -1
  90. package/dist/events.esm.js +1 -1
  91. package/dist/extensibility.d.ts +24 -64
  92. package/dist/extensibility.esm.js +35 -29
  93. package/dist/face-match.esm.js +2 -2
  94. package/dist/{faceCaptureManagerFactory-BxWPpxyd.d.ts → faceCaptureManagerFactory-CvtqcLxs.d.ts} +87 -54
  95. package/dist/{faceCaptureManagerFactory-CVnZ0fa5.esm.js → faceCaptureManagerFactory-pCmG4MeF.esm.js} +68 -7
  96. package/dist/faceCaptureSetup-BSextack.esm.js +2106 -0
  97. package/dist/{faceMatchManager-Ri4UbNz0.esm.js → faceMatchManager-Caal2zyV.esm.js} +2 -2
  98. package/dist/{faceMatchStateMachine-20DdZ3jg.esm.js → faceMatchStateMachine-BUc5FXYy.esm.js} +1 -1
  99. package/dist/{feature-management-CPQ4qv3F.esm.js → feature-management-B0sGlozZ.esm.js} +32 -7
  100. package/dist/feature-management.d.ts +1 -1
  101. package/dist/feature-management.esm.js +1 -1
  102. package/dist/field-comparison.esm.js +1 -1
  103. package/dist/{fieldComparisonManager-Cg6kPQQx.esm.js → fieldComparisonManager-BIs6HPJG.esm.js} +2 -2
  104. package/dist/fiscal-qr.d.ts +2 -56
  105. package/dist/fiscal-qr.esm.js +2 -308
  106. package/dist/fiscalQrManager-Bp_-3LJr.esm.js +34131 -0
  107. package/dist/fiscalQrManager-CHcBJwUM.d.ts +68 -0
  108. package/dist/flow-events.d.ts +1 -1
  109. package/dist/flow.d.ts +212 -185
  110. package/dist/flow.esm.js +119 -30
  111. package/dist/{flowCompletionService-tfeoGre9.esm.js → flowCompletionService-CLtbWhSK.esm.js} +2 -2
  112. package/dist/{flowServices-f5Ruz7R9.esm.js → flowServices-B5FwukTQ.esm.js} +91 -26
  113. package/dist/geolocation.esm.js +2 -2
  114. package/dist/{geolocationManager-CH6RfqFH.esm.js → geolocationManager-DIw-xq9a.esm.js} +2 -2
  115. package/dist/{geolocationStateMachine-DmbWFely.esm.js → geolocationStateMachine-DpG0TFOU.esm.js} +3 -3
  116. package/dist/getBrowser-CBiibsL-.esm.js +19 -0
  117. package/dist/{getBrowser-DNrQeL4T.esm.js → getBrowser-Cbe1C4Tn.esm.js} +2 -1
  118. package/dist/{getDeviceClass-9y-kbVDw.esm.js → getDeviceClass-5NYZg9s6.esm.js} +2 -2
  119. package/dist/getParsedUserAgent-B2iFDql1.esm.js +1278 -0
  120. package/dist/government-validation.d.ts +2 -85
  121. package/dist/government-validation.esm.js +3 -120
  122. package/dist/governmentValidationManager-D02vT4yY.d.ts +63 -0
  123. package/dist/governmentValidationManager-TjC9iVjH.esm.js +79 -0
  124. package/dist/governmentValidationStateMachine-D1ZnEqdd.esm.js +54 -0
  125. package/dist/home.d.ts +1 -1
  126. package/dist/home.esm.js +1 -1
  127. package/dist/id-ocr.d.ts +2 -2
  128. package/dist/id-ocr.esm.js +2 -2
  129. package/dist/id-selfie-flow.d.ts +3 -2
  130. package/dist/id-selfie-flow.esm.js +11 -10
  131. package/dist/id-verification.esm.js +2 -2
  132. package/dist/id.d.ts +29 -5
  133. package/dist/id.esm.js +48 -46
  134. package/dist/idCaptureDefaults-BcxjQDI3.esm.js +484 -0
  135. package/dist/{idCaptureManager-CqrqSjJV.d.ts → idCaptureManager-CvmHOWWd.d.ts} +227 -39
  136. package/dist/{idCaptureManager-BYwTZ2H8.esm.js → idCaptureManager-Vby8oYqh.esm.js} +259 -46
  137. package/dist/{idCaptureServices-44kwQItl.esm.js → idCaptureServices-CJIxD9ep.esm.js} +342 -31
  138. package/dist/idCaptureStateMachine-CmqihkUy.esm.js +5343 -0
  139. package/dist/{idOcrManager-DXc_xRN7.d.ts → idOcrManager-BF_cXZq8.d.ts} +1 -1
  140. package/dist/{idOcrManager-BIQYQXXj.esm.js → idOcrManager-DHU22hVn.esm.js} +2 -2
  141. package/dist/{idOcrStateMachine-cSxzHpHt.esm.js → idOcrStateMachine-33UvRAHE.esm.js} +1 -1
  142. package/dist/{idVerificationManager-JpV_SAsl.esm.js → idVerificationManager-CyaixD0D.esm.js} +2 -2
  143. package/dist/{idVerificationStateMachine-nPeUNyFq.esm.js → idVerificationStateMachine-BPGrQZEm.esm.js} +1 -1
  144. package/dist/identity-reuse.esm.js +2 -2
  145. package/dist/{identityReuseManager-kNCg9AbD.esm.js → identityReuseManager-CWaNHBO3.esm.js} +2 -2
  146. package/dist/{identityReuseStateMachine-DyulxDjP.esm.js → identityReuseStateMachine-CQgnATo5.esm.js} +1 -1
  147. package/dist/{index-CLMF0QLQ.d.ts → index-DLcJT5YP.d.ts} +1 -1
  148. package/dist/index.d.ts +1 -1
  149. package/dist/index.esm.js +1 -1
  150. package/dist/{invokeOnCaptureCallback-GpvMuz9o.esm.js → invokeOnCaptureCallback-BjzPjJ_p.esm.js} +1 -1
  151. package/dist/mandatory-consent.d.ts +2 -2
  152. package/dist/mandatory-consent.esm.js +2 -2
  153. package/dist/{mandatoryConsentManager-DyPzUmsZ.d.ts → mandatoryConsentManager-CJSyhTpi.d.ts} +5 -5
  154. package/dist/{mandatoryConsentManager-B4Niyg_u.esm.js → mandatoryConsentManager-Du-m-tZ_.esm.js} +2 -2
  155. package/dist/{mandatoryConsentStateMachine-B4-1u-L8.esm.js → mandatoryConsentStateMachine-DSDAk7WZ.esm.js} +1 -1
  156. package/dist/multipartRecordingService-B3C_zlev.esm.js +594 -0
  157. package/dist/{permissionGuards-KINpmKtI.esm.js → permissionGuards-uYZYFu4J.esm.js} +1 -1
  158. package/dist/{permissionServices-UvUcOSRb.esm.js → permissionServices-Bj_fyWtv.esm.js} +5 -5
  159. package/dist/personhood.d.ts +6 -5
  160. package/dist/personhood.esm.js +10 -10
  161. package/dist/phone.esm.js +2 -2
  162. package/dist/{phoneManager-FsJ0W2Ei.esm.js → phoneManager-N1-sbrY4.esm.js} +2 -2
  163. package/dist/{phoneStateMachine-Ba0wKHyX.esm.js → phoneStateMachine-jl8LJKCo.esm.js} +1 -1
  164. package/dist/{platform-BJrm5nzZ.esm.js → platform-DkcRc9JV.esm.js} +29 -1
  165. package/dist/qe-signature.d.ts +5 -3
  166. package/dist/qe-signature.esm.js +2 -2
  167. package/dist/recordingsRepository-CCWy13M-.esm.js +72 -0
  168. package/dist/redirect-to-mobile.esm.js +2 -2
  169. package/dist/{redirectToMobileManager-y4VQB11M.esm.js → redirectToMobileManager-DsFzdTwA.esm.js} +2 -2
  170. package/dist/{redirectToMobileStateMachine-Cyv2x0PP.esm.js → redirectToMobileStateMachine-v3otpT-L.esm.js} +1 -1
  171. package/dist/{rolldown-runtime-FZ4Itg2g.esm.js → rolldown-runtime-FDOR9p9I.esm.js} +1 -19
  172. package/dist/{runChildModule-Dukuw23X.esm.js → runChildModule-TuyGE00X.esm.js} +3 -21
  173. package/dist/safeStorage-B-trhxg6.esm.js +423 -0
  174. package/dist/{sdkVersion-D1Bm59g6.esm.js → sdkVersion-CLxKvdyz.esm.js} +1 -1
  175. package/dist/selfie.d.ts +5 -5
  176. package/dist/selfie.esm.js +14 -76
  177. package/dist/{selfieErrorUtils-C2PYBVsp.esm.js → selfieErrorUtils-C77GXJH6.esm.js} +30 -4
  178. package/dist/{selfieManager-Bj6B2ZVy.esm.js → selfieManager-CihVnODO.esm.js} +5 -5
  179. package/dist/{selfieManager-DwlCppg0.d.ts → selfieManager-D1KRJ39M.d.ts} +8 -11
  180. package/dist/selfieStateMachine-fwMmNtOi.esm.js +69 -0
  181. package/dist/{session-BFdLgN4i.esm.js → session-BHIeAamR.esm.js} +4 -5
  182. package/dist/session.d.ts +21 -11
  183. package/dist/session.esm.js +5 -5
  184. package/dist/{sessionInitializer-dlfDehHk.esm.js → sessionInitializer-BLoK7SP9.esm.js} +187 -68
  185. package/dist/{setup-BgoWtvIS.d.ts → setup-Cv-JM9QC.d.ts} +63 -69
  186. package/dist/{setup-BIAtLa8k.esm.js → setup-msLybMbC.esm.js} +226 -100
  187. package/dist/signature.esm.js +2 -2
  188. package/dist/{signatureManager-Ca43yhwk.esm.js → signatureManager-ChsB-nMD.esm.js} +2 -2
  189. package/dist/{signatureStateMachine-K1LMRrxG.esm.js → signatureStateMachine-BHPwkJZS.esm.js} +1 -1
  190. package/dist/{src-0Jurt29N.esm.js → src-35ekGRzK.esm.js} +1 -1
  191. package/dist/{stats-B0nFKawG.esm.js → stats-DkK-f8JT.esm.js} +1 -1
  192. package/dist/stats.esm.js +1 -1
  193. package/dist/{trueSightService---iW2KKJ.esm.js → trueSightService-CKrrfV0Q.esm.js} +7 -7
  194. package/dist/trust-graph.esm.js +1 -1
  195. package/dist/{types-BX_XkMsQ2.d.ts → types-9_esGTPj.d.ts} +1 -1
  196. package/dist/types-BT_Oalip.d.ts +1 -0
  197. package/dist/{types-DelMqZLe.d.ts → types-BjSly8cp.d.ts} +1 -1
  198. package/dist/{types-Hmd7U0JA.d.ts → types-CM-jtjJ2.d.ts} +6 -81
  199. package/dist/{types-Bdf8_LYB2.d.ts → types-CjKBS37a2.d.ts} +303 -13
  200. package/dist/{types-DVmXIdzW.d.ts → types-D0gekt4U.d.ts} +38 -5
  201. package/dist/types-DgDvvzg0.d.ts +10 -0
  202. package/dist/{types-KPvmag_B.d.ts → types-Do5rEXij.d.ts} +7 -4
  203. package/dist/types-ZT1XFIJ8.d.ts +6 -0
  204. package/dist/video-selfie.d.ts +59 -35
  205. package/dist/video-selfie.esm.js +510 -601
  206. package/dist/{videoSelfieCameraWarmer-NEhFZvWx.esm.js → videoSelfieCameraWarmer-CB1IzZkt.esm.js} +14 -153
  207. package/dist/videoSelfieFlowModuleMachine-BUe2uACW.esm.js +32 -0
  208. package/dist/{videoSelfieStepDetector-D3oo2ofo.d.ts → videoSelfieStepDetector-5YHFe0Mq.d.ts} +21 -5
  209. package/dist/virtualCameraCheck-WOloJ-do.esm.js +48 -0
  210. package/dist/warmup-CUUnwYxe.esm.js +714 -0
  211. package/dist/warmup-Cis2p6O0.d.ts +128 -0
  212. package/dist/wasm.d.ts +30 -6
  213. package/dist/wasm.esm.js +36 -4
  214. package/dist/{wasmDsFlagSync-BqUCwLY8.esm.js → wasmDsFlagSync-B2e8p268.esm.js} +2 -2
  215. package/dist/{wasmWebClient-DM8lkb0z.esm.js → wasmWebClient-B7baE-Wf.esm.js} +358 -28
  216. package/dist/watchlist-for-business.d.ts +2 -78
  217. package/dist/watchlist-for-business.esm.js +3 -102
  218. package/dist/watchlist.esm.js +2 -2
  219. package/dist/watchlistForBusinessManager-CpuuB1J2.esm.js +107 -0
  220. package/dist/watchlistForBusinessManager-CsnJnG-C.d.ts +99 -0
  221. package/dist/{watchlistForBusinessStateMachine-CxFnlshm.esm.js → watchlistForBusinessStateMachine-DEzgjz7C.esm.js} +13 -6
  222. package/dist/{watchlistManager-LoNZH9qm.esm.js → watchlistManager-CI8BHFob.esm.js} +2 -2
  223. package/dist/{watchlistStateMachine-DIKQDoUT.esm.js → watchlistStateMachine-DvOby3a-.esm.js} +1 -1
  224. package/dist/workflow.d.ts +12 -8
  225. package/dist/workflow.esm.js +48 -39
  226. package/package.json +4 -10
  227. package/dist/BrowserStorageProvider-k-FDkC4W.esm.js +0 -67
  228. package/dist/FaceDetectionProvider-Mh6q3EbA.d.ts +0 -349
  229. package/dist/IFaceAvatarCapability-BrL19G0s.d.ts +0 -23
  230. package/dist/IStorageCapability-ORkQfK3F.d.ts +0 -242
  231. package/dist/OpenViduRecordingProvider-Du98qevC.esm.js +0 -85
  232. package/dist/createFaceAvatar-BEj18KXi.d.ts +0 -50
  233. package/dist/document-upload.d.ts +0 -325
  234. package/dist/document-upload.esm.js +0 -197
  235. package/dist/electronicSignatureManager-CcUXQZS7.d.ts +0 -1300
  236. package/dist/faceCaptureSetup-Cd-04W_X.esm.js +0 -863
  237. package/dist/getBrowser-Cb8Zgrgp.esm.js +0 -7
  238. package/dist/getParsedUserAgent-pJjATANs.esm.js +0 -1622
  239. package/dist/governmentValidationStateMachine-CK9DrZXX.esm.js +0 -226
  240. package/dist/idCaptureDefaults-WeHbQM7W.esm.js +0 -225
  241. package/dist/idCaptureStateMachine-kZ5OpdfM.esm.js +0 -3342
  242. package/dist/lib-DAyUtOTj.esm.js +0 -12420
  243. package/dist/manualReviewService-D4IkipnN.esm.js +0 -15
  244. package/dist/mediaRecorderOptions-dALSV8af.esm.js +0 -40
  245. package/dist/onDeviceFaceResults-CUHwyZT4.esm.js +0 -646
  246. package/dist/openviduLazy-CCDpFWg1.esm.js +0 -10
  247. package/dist/recordingService-3NSENVwp.esm.js +0 -329
  248. package/dist/safeStorage-Ep56I-f_.esm.js +0 -982
  249. package/dist/selfieStateMachine-CHV_WNst.esm.js +0 -55
  250. package/dist/trueSight-B_icM8r2.esm.js +0 -1
  251. package/dist/types-EELWyWpd.d.ts +0 -6
  252. package/dist/types-Vb4P9ovf.d.ts +0 -22
  253. package/dist/warmup-Dv2alr2-.d.ts +0 -82
  254. package/dist/wasmDefaults-DTUrftxR.esm.js +0 -125
  255. package/dist/{Face2DProvider-UUQt_vRC.esm.js → Face2DProvider-BF48sz5c.esm.js} +1 -1
  256. package/dist/{PrivacyLensProvider-D8PS7AJa.esm.js → PrivacyLensProvider-EwnC_C5n.esm.js} +1 -1
  257. /package/dist/{types-BfgmV7s72.d.ts → types-BfgmV7s7.d.ts} +0 -0
  258. /package/dist/{types-CJ7Yl9K-2.d.ts → types-CJ7Yl9K-.d.ts} +0 -0
@@ -1,349 +0,0 @@
1
- import { n as WasmPipeline } from "./warmup-Dv2alr2-.js";
2
- import { a as MLProviderConfig, i as IMLProviderCapability, o as IncodeCanvas } from "./IStorageCapability-ORkQfK3F.js";
3
- //#region ../infra/src/wasm/wasmWebClient.d.ts
4
- /**
5
- * Configuration shape that the C++ `WebApi` passes when calling `.post(...)`
6
- * on its host JS adapter. Mirrors the upstream `ml-wasm-kit/WebClient`
7
- * `RequestConfig` for the subset of fields actually set by `WebApi`.
8
- */
9
- type WebApiHostRequestConfig = {
10
- ie?: boolean;
11
- headers?: Record<string, string>;
12
- params?: Record<string, string | number | boolean | undefined>;
13
- timeout?: number;
14
- };
15
- //#endregion
16
- //#region ../infra/src/capabilities/IFaceDetectionCapability.d.ts
17
- /**
18
- * Configuration for face detection provider.
19
- * Extends base ML provider config with face-detection specific options.
20
- */
21
- interface FaceDetectionConfig extends MLProviderConfig {
22
- autocaptureInterval?: number;
23
- /**
24
- * Load the on-device selfie workflow (6 models including liveness + age
25
- * estimation) instead of the default selfie workflow (4 models). Required
26
- * when SELFIE/AUTHENTICATION has `onDeviceFaceResultsSubmissionEnabled`.
27
- */
28
- useOnDeviceWorkflow?: boolean;
29
- /**
30
- * Load the video-selfie face workflow (`SelfieWithAggregationMetrics`, the
31
- * frame-aggregation best-shot pipeline used by the video-selfie flow)
32
- * instead of the default quality-metrics selfie workflow. Mutually exclusive
33
- * with `useOnDeviceWorkflow`.
34
- */
35
- videoSelfie?: boolean;
36
- }
37
- interface FacePositionConstraints {
38
- minX: number;
39
- minY: number;
40
- maxX: number;
41
- maxY: number;
42
- }
43
- interface FaceDetectionThresholds {
44
- brightnessThreshold: number;
45
- blurrinessThreshold: number;
46
- tiltRotationAngleThreshold: number;
47
- minMagicCropSize: number;
48
- autocaptureInterval: number;
49
- minFaceQualityScore: number;
50
- faceOcclusionThreshold: number;
51
- /**
52
- * Milliseconds the C++ workflow waits after `onGetReady` fires before
53
- * triggering autocapture. Mirrors V1's `getReadyDelay` (2000 ms) — without
54
- * it, autocapture can fire on the first quality-passing frame, before the
55
- * front camera has finished locking focus, producing blurry captures that
56
- * the on-device quality model rejects.
57
- */
58
- getReadyDelay: number;
59
- /**
60
- * Milliseconds over which face-detection results are aggregated before the
61
- * autocapture decision. Mirrors V1's `framesAggregationInterval` (2000 ms).
62
- */
63
- framesAggregationInterval: number;
64
- /**
65
- * Minimum consecutive frames with a detected face required before
66
- * autocapture can trigger. Mirrors V1's `minFramesWithFace` (3).
67
- */
68
- minFramesWithFace: number;
69
- }
70
- interface FaceAttributesThresholds {
71
- headwearThreshold: number;
72
- lensesThreshold: number;
73
- closedEyesThreshold: number;
74
- maskThreshold: number;
75
- }
76
- interface FaceChecksConfig {
77
- lenses: boolean;
78
- mask: boolean;
79
- closedEyes: boolean;
80
- headWear: boolean;
81
- occlusion: boolean;
82
- }
83
- interface FaceData {
84
- rect: {
85
- x: number;
86
- y: number;
87
- width: number;
88
- height: number;
89
- };
90
- rightEye: {
91
- x: number;
92
- y: number;
93
- };
94
- leftEye: {
95
- x: number;
96
- y: number;
97
- };
98
- noseTip: {
99
- x: number;
100
- y: number;
101
- };
102
- rightMouthCorner: {
103
- x: number;
104
- y: number;
105
- };
106
- leftMouthCorner: {
107
- x: number;
108
- y: number;
109
- };
110
- pitch: number;
111
- yaw: number;
112
- roll: number;
113
- }
114
- type FaceCoordinates = {
115
- rightEyeX: number;
116
- rightEyeY: number;
117
- leftEyeX: number;
118
- leftEyeY: number;
119
- noseTipX: number;
120
- noseTipY: number;
121
- rightMouthX: number;
122
- rightMouthY: number;
123
- mouthX: number;
124
- mouthY: number;
125
- x: number;
126
- y: number;
127
- width: number;
128
- height: number;
129
- };
130
- interface FaceDetectionCallbacks {
131
- onFarAway?: () => void;
132
- onTooClose?: () => void;
133
- onTooManyFaces?: () => void;
134
- onNoFace?: () => void;
135
- onCapture?: (canvas: IncodeCanvas, faceCoordinates: FaceCoordinates) => void;
136
- onGetReady?: () => void;
137
- onGetReadyFinished?: () => void;
138
- onCenterFace?: () => void;
139
- onDark?: () => void;
140
- onBlur?: () => void;
141
- onFaceAngle?: () => void;
142
- /**
143
- * Fires on **every** processed frame that contains at least one detected
144
- * face, with the freshly-computed face data (pitch/yaw/roll/landmarks).
145
- *
146
- * Use `onFaceData` when you need a dense per-frame signal for live UI
147
- * feedback — e.g. the Personhood avatar that mirrors head pose. The
148
- * default capture pipeline does not subscribe to this, so consumers
149
- * that don't need per-frame data pay no cost.
150
- *
151
- * `frameSize` is the source frame's pixel dimensions. Optional so
152
- * existing single-arg consumers keep working (TypeScript callback
153
- * variance handles it). Personhood uses it to compute an
154
- * orientation-invariant face-size ratio for distance-aware smoothing.
155
- */
156
- onFaceData?: (face: FaceData, frameSize?: {
157
- width: number;
158
- height: number;
159
- }) => void;
160
- onLenses?: () => void;
161
- onMask?: () => void;
162
- onEyesClosed?: () => void;
163
- onHeadWear?: () => void;
164
- onSwitchToManualCapture?: () => void;
165
- onFaceOccluded?: () => void;
166
- }
167
- /**
168
- * Capability interface for face detection and selfie capture.
169
- * Extends the base ML provider capability with face-detection specific methods.
170
- */
171
- interface IFaceDetectionCapability extends IMLProviderCapability<FaceDetectionConfig> {
172
- /**
173
- * Sets callbacks for face detection events.
174
- * @param callbacks - Object containing callback functions for various detection events
175
- */
176
- setCallbacks(callbacks: FaceDetectionCallbacks): void;
177
- /**
178
- * Sets position constraints for face detection.
179
- * @param constraints - Bounding box constraints for valid face position
180
- */
181
- setPositionConstraints(constraints: FacePositionConstraints): void;
182
- /**
183
- * Sets detection thresholds for quality checks.
184
- * @param thresholds - Threshold values for various quality metrics
185
- */
186
- setThresholds(thresholds: FaceDetectionThresholds): void;
187
- /**
188
- * Sets thresholds for face attribute detection.
189
- * @param thresholds - Threshold values for attribute detection (headwear, lenses, etc.)
190
- */
191
- setAttributesThresholds(thresholds: FaceAttributesThresholds): void;
192
- /**
193
- * Enables or disables specific face checks.
194
- * @param config - Configuration for which checks to enable
195
- */
196
- setChecksEnabled(config: FaceChecksConfig): void;
197
- /**
198
- * Sets video selfie mode.
199
- * @param enabled - Whether to enable video selfie mode
200
- */
201
- setVideoSelfieMode(enabled: boolean): void;
202
- /**
203
- * Manually triggers the `onCapture` callback registered via
204
- * `setCallbacks`, using the best-quality frame the provider has
205
- * seen so far (or the most recent processed frame as a fallback).
206
- * Used by callers that want to complete a capture flow without
207
- * waiting for WASM's own autocapture criteria — e.g. Personhood's
208
- * "complete with far-away face" path, where the user may be too
209
- * small in frame for autocapture to ever fire but a verdict
210
- * (likely lower-confidence) is still desired.
211
- *
212
- * No-op when no frame is available at all (camera hasn't produced
213
- * a single decoded frame yet) or when no `onCapture` callback was
214
- * registered.
215
- */
216
- forceCapture(): void;
217
- /**
218
- * Synchronous manual-capture entry point for the on-device selfie workflow.
219
- * Runs the full on-device pipeline on a single canvas image and stages the
220
- * results inside WASM for the next {@link postFaceResults} call. No-op for
221
- * default (non-on-device) configurations; callers should guard with the
222
- * `onDeviceFaceResultsSubmissionEnabled` flag.
223
- */
224
- processPhoto(canvas: HTMLCanvasElement): void;
225
- /**
226
- * POSTs the staged on-device face-results JSON to `/omni/add/face-results`.
227
- * The C++ side encrypts the body via `SessionEncryptor` and routes through
228
- * the WASM `WebClient`, so the SDK's WebClient must be initialized first
229
- * (consumers calling this must configure `setup({ apiURL, wasm })`).
230
- */
231
- postFaceResults(config?: WebApiHostRequestConfig): Promise<unknown>;
232
- }
233
- //#endregion
234
- //#region ../infra/src/wasm/WasmPipelineType.d.ts
235
- declare enum WasmPipelineType {
236
- IdBlurGlarePipeline = 0,
237
- IdBarcodeAndTextQualityPipeline = 1,
238
- IdVideoSelfiePipeline = 2,
239
- SelfieWithAggregationMetrics = 3,
240
- SelfieWithQualityMetrics = 4,
241
- OnDeviceSelfieWorkflow = 5
242
- }
243
- //#endregion
244
- //#region ../infra/src/providers/wasm/BaseWasmProvider.d.ts
245
- /**
246
- * Base configuration for WASM providers
247
- */
248
- interface BaseWasmConfig {
249
- /** Path to the WASM binary */
250
- wasmPath?: string;
251
- /** Path to the SIMD-optimized WASM binary (optional) */
252
- wasmSimdPath?: string;
253
- /** Path to the WASM glue code (paired with `wasmPath`) */
254
- glueCodePath?: string;
255
- /**
256
- * Path to the SIMD-optimized WASM glue code (paired with `wasmSimdPath`).
257
- * If omitted, defaults to a sibling `.js` derived from `wasmSimdPath`.
258
- */
259
- glueCodeSimdPath?: string;
260
- /** Whether to use SIMD optimizations (default: true) */
261
- useSimd?: boolean;
262
- /**
263
- * Base path for ML model files. Models will be loaded from `${modelsBasePath}/${modelFileName}`.
264
- * If not provided, models are expected in a 'models' subdirectory relative to the WASM binary.
265
- */
266
- modelsBasePath?: string;
267
- }
268
- /**
269
- * Base provider class that abstracts common WASM functionality.
270
- * This serves as a foundation for specific ML capability providers
271
- * like FaceDetectionProvider and IdCaptureProvider.
272
- */
273
- declare abstract class BaseWasmProvider {
274
- private _isInitialized;
275
- protected pipelineType: WasmPipelineType | undefined;
276
- /**
277
- * Creates a new BaseWasmProvider
278
- * @param pipelineType - The WASM pipeline type this provider uses
279
- */
280
- constructor(pipelineType?: WasmPipelineType);
281
- /**
282
- * Returns whether this provider has been initialized.
283
- */
284
- get initialized(): boolean;
285
- protected getPipelineType(): WasmPipelineType;
286
- /**
287
- * Initializes the provider by ensuring WASM is loaded
288
- * @param config - Provider configuration
289
- * @param pipeline - The pipeline type to warm up ('selfie', 'idCapture', etc.)
290
- */
291
- protected initializeBase(config: BaseWasmConfig, pipeline: WasmPipeline): Promise<void>;
292
- /**
293
- * Ensures the provider is initialized before performing operations.
294
- * @throws Error if not initialized
295
- */
296
- protected ensureInitialized(): void;
297
- /**
298
- * Processes a frame through the WASM pipeline
299
- * @param image - Image data to process
300
- * @returns The pipeline result (type depends on pipeline - WASM returns any)
301
- */
302
- protected processFrameWasm(image: ImageData): Promise<any>;
303
- abstract processFrame(image: ImageData): Promise<void>;
304
- /**
305
- * Resets the pipeline to its initial state.
306
- * Safe to call even if not initialized (no-op in that case).
307
- */
308
- reset(): void;
309
- /**
310
- * Disposes of resources and resets initialization state.
311
- * Safe to call even if not initialized.
312
- */
313
- dispose(): Promise<void>;
314
- }
315
- //#endregion
316
- //#region ../infra/src/providers/wasm/FaceDetectionProvider.d.ts
317
- declare class FaceDetectionProvider extends BaseWasmProvider implements IFaceDetectionCapability {
318
- private defaultThresholds;
319
- private currentThresholds;
320
- private currentFrame;
321
- private onFaceDataCallback;
322
- constructor();
323
- processFrame(image: ImageData): Promise<void>;
324
- initialize(config: FaceDetectionConfig): Promise<void>;
325
- /**
326
- * Last-registered onCapture callback — captured into a private
327
- * field so `forceCapture()` (called from outside the WASM-callback
328
- * lifecycle) can re-fire the same wrapper. `setCallbacks` rebinds
329
- * this on each invocation, so the field always reflects the
330
- * current consumer.
331
- */
332
- private currentOnCaptureWrapper;
333
- processPhoto(canvas: HTMLCanvasElement): void;
334
- postFaceResults(config?: WebApiHostRequestConfig): Promise<unknown>;
335
- setCallbacks(callbacks: FaceDetectionCallbacks): void;
336
- setPositionConstraints(constraints: FacePositionConstraints): void;
337
- applyDefaults(autocaptureInterval?: number): void;
338
- setAutocaptureInterval(interval: number): void;
339
- setThresholds(thresholds: FaceDetectionThresholds): void;
340
- setAttributesThresholds(thresholds: FaceAttributesThresholds): void;
341
- setChecksEnabled(config: FaceChecksConfig): void;
342
- setVideoSelfieMode(enabled: boolean): void;
343
- forceCapture(): void;
344
- reset(): void;
345
- private createDefaultFaceCoordinates;
346
- private formatFaceCoordinates;
347
- }
348
- //#endregion
349
- export { FaceData as i, BaseWasmProvider as n, FaceCoordinates as r, FaceDetectionProvider as t };
@@ -1,23 +0,0 @@
1
- //#region ../infra/src/capabilities/IFaceAvatarCapability.d.ts
2
- /**
3
- * Caller-supplied overrides. Any omitted field falls back to the default
4
- * CDN layout (see `avatar/avatarDefaults.ts`). `basePath`/`version` rewrite
5
- * the whole directory; the individual `*Path` fields win over both.
6
- */
7
- interface AvatarAssetsOverrides {
8
- basePath?: string;
9
- version?: string;
10
- mediapipeModulePath?: string;
11
- mediapipeWasmPath?: string;
12
- faceLandmarkerModelPath?: string;
13
- vrmModelPath?: string;
14
- }
15
- /**
16
- * Verdict cue an avatar can reflect: `detecting` (working) / `success` / `error`.
17
- * Pose-driven 2D avatars colour the face accordingly (green wink / red frown);
18
- * avatars without a verdict visual (VRM, privacy-lens) treat `setState` as a no-op.
19
- * Driven by the host module (selfie capture outcome, personhood verdict).
20
- */
21
- type AvatarFaceState = 'detecting' | 'success' | 'error';
22
- //#endregion
23
- export { AvatarFaceState as n, AvatarAssetsOverrides as t };
@@ -1,242 +0,0 @@
1
- //#region ../infra/src/media/canvas.d.ts
2
- /**
3
- * Class representing a canvas element for image capture and manipulation.
4
- */
5
- declare class IncodeCanvas {
6
- canvas: HTMLCanvasElement;
7
- private base64Image;
8
- private blobData;
9
- /**
10
- * Creates an {@link IncodeCanvas} from a raw {@link ImageData} frame.
11
- * @param imageData - Frame pixels in RGBA format
12
- * @returns An {@link IncodeCanvas} containing the provided pixels
13
- */
14
- static fromImageData(imageData: ImageData): IncodeCanvas;
15
- /**
16
- * Create a new canvas element.
17
- * @param canvas_ - The canvas element to clone.
18
- */
19
- constructor(canvas_: HTMLCanvasElement);
20
- /**
21
- * Check if the current canvas is valid.
22
- */
23
- private checkCanvas;
24
- /**
25
- * Disposes of resources, including revoking object URLs to prevent memory leaks.
26
- */
27
- dispose(): void;
28
- /**
29
- * Release the data stored by IncodeCanvas.
30
- */
31
- release(): void;
32
- /**
33
- * Revokes the object URL if one exists, preventing memory leaks.
34
- * Use this when you no longer need the preview image URL.
35
- */
36
- revokeObjectURL(): void;
37
- /**
38
- * Get the width of the canvas.
39
- */
40
- width(): number | null;
41
- /**
42
- * Get the height of the canvas.
43
- */
44
- height(): number | null;
45
- /**
46
- * Set the width of the canvas.
47
- */
48
- setWidth(width: number): void;
49
- /**
50
- * Set the height of the canvas.
51
- */
52
- setHeight(height: number): void;
53
- /**
54
- * Clone the current canvas.
55
- */
56
- clone(): IncodeCanvas | null;
57
- /**
58
- * Deep clone the current IncodeCanvas including blob data.
59
- */
60
- deepClone(): Promise<IncodeCanvas | null>;
61
- /**
62
- * Returns the drawing context on the canvas.
63
- */
64
- getContext(contextId: '2d', contextAttributes?: CanvasRenderingContext2DSettings): CanvasRenderingContext2D | null;
65
- /**
66
- * Retrieves the image data from the canvas.
67
- */
68
- getImageData(): ImageData | null;
69
- /**
70
- * Updates the base64 representation of the current canvas image.
71
- */
72
- updateBase64Image(jpegQuality?: number): void;
73
- /**
74
- * Converts the current canvas element to a base64 string.
75
- */
76
- getBase64Image(jpegQuality?: number, includeDataURLPrefix?: boolean): string | null;
77
- /**
78
- * Sets the base64 representation of the current canvas image.
79
- */
80
- setBase64Image(base64Image: string | null): void;
81
- /**
82
- * Updates the Blob representation of the current canvas image.
83
- */
84
- updateBlob(jpegQuality?: number, includeDataURLPrefix?: boolean): void;
85
- /**
86
- * Converts a base64 string to a Blob and creates a URL for it.
87
- */
88
- static base64ToBlob(base64: string): {
89
- blob: Blob;
90
- url: string;
91
- } | null;
92
- /**
93
- * Retrieves the Blob data and its URL from the current canvas.
94
- */
95
- getBlobData(jpegQuality?: number, includeDataURLPrefix?: boolean): {
96
- blob: Blob;
97
- url: string;
98
- } | null;
99
- /**
100
- * Sets the Blob data of the current canvas image.
101
- */
102
- setBlobData(blobData: {
103
- blob: Blob;
104
- url: string;
105
- }): Promise<void>;
106
- /**
107
- * Returns a resized canvas according to video element size.
108
- */
109
- getResizedCanvas(videoElementWidth: number, videoElementHeight: number): IncodeCanvas | null;
110
- }
111
- //#endregion
112
- //#region ../infra/src/capabilities/IMLProviderCapability.d.ts
113
- /**
114
- * Base configuration shared by all ML provider capabilities.
115
- */
116
- interface MLProviderConfig {
117
- /** Path to the WASM binary */
118
- wasmPath?: string;
119
- /** Path to the SIMD-optimized WASM binary (optional) */
120
- wasmSimdPath?: string;
121
- /** Path to the WASM glue code (paired with `wasmPath`) */
122
- glueCodePath?: string;
123
- /**
124
- * Path to the SIMD-optimized WASM glue code (paired with `wasmSimdPath`).
125
- * If omitted, defaults to a sibling `.js` derived from `wasmSimdPath`.
126
- */
127
- glueCodeSimdPath?: string;
128
- /** Whether to use SIMD optimizations (default: true) */
129
- useSimd?: boolean;
130
- /**
131
- * Base path for ML model files. Models will be loaded from `${modelsBasePath}/${modelFileName}`.
132
- * If not provided, models are expected in a 'models' subdirectory relative to the WASM binary.
133
- */
134
- modelsBasePath?: string;
135
- }
136
- /**
137
- * Base interface for ML provider capabilities.
138
- * Provides common lifecycle and frame processing methods shared by
139
- * FaceDetectionCapability and IdCaptureCapability.
140
- */
141
- interface IMLProviderCapability<TConfig extends MLProviderConfig> {
142
- /**
143
- * Whether the provider has been initialized and is ready to process frames.
144
- */
145
- readonly initialized: boolean;
146
- /**
147
- * Initializes the provider with the given configuration.
148
- * If WASM was already warmed up via `setup()` or `warmupWasm()`, this returns almost instantly.
149
- * @param config - Provider configuration including WASM paths
150
- */
151
- initialize(config: TConfig): Promise<void>;
152
- /**
153
- * Processes a frame through the ML pipeline.
154
- * Callbacks set via `setCallbacks()` will be invoked based on the analysis results.
155
- * @param image - Image data to process
156
- * @throws Error if provider is not initialized
157
- */
158
- processFrame(image: ImageData): Promise<void>;
159
- /**
160
- * Resets the pipeline to its initial state.
161
- * Safe to call even if not initialized (no-op in that case).
162
- */
163
- reset(): void;
164
- /**
165
- * Disposes of resources and resets initialization state.
166
- * Safe to call even if not initialized.
167
- */
168
- dispose(): Promise<void>;
169
- }
170
- //#endregion
171
- //#region ../infra/src/capabilities/IRecordingCapability.d.ts
172
- type RecordingPublisher = {
173
- getStreamId: () => string | undefined;
174
- replaceVideoTrack: (track: MediaStreamTrack) => Promise<void>;
175
- destroy: () => void;
176
- };
177
- type RecordingConnection = {
178
- sessionId: string | undefined;
179
- publisher: RecordingPublisher;
180
- disconnect: () => Promise<void>;
181
- };
182
- type RecordingConnectionEvents = {
183
- onSessionConnected?: (sessionId: string | undefined) => void;
184
- onSessionDisconnected?: (sessionId: string | undefined) => void;
185
- onSessionException?: (params: {
186
- name?: string;
187
- message?: string;
188
- sessionId?: string;
189
- }) => void;
190
- onPublisherCreated?: (params: {
191
- streamId?: string;
192
- sessionId?: string;
193
- }) => void;
194
- onPublisherError?: (params: {
195
- message?: string;
196
- sessionId?: string;
197
- streamId?: string;
198
- }) => void;
199
- };
200
- type ConnectRecordingParams = {
201
- sessionToken: string;
202
- stream: MediaStream;
203
- events?: RecordingConnectionEvents;
204
- };
205
- type IRecordingCapability = {
206
- /**
207
- * Connects to a recording session and publishes the provided media stream.
208
- * Returns a connection handle that can be disconnected and used to manage the publisher.
209
- */
210
- connect: (params: ConnectRecordingParams) => Promise<RecordingConnection>;
211
- };
212
- //#endregion
213
- //#region ../infra/src/capabilities/IStorageCapability.d.ts
214
- /**
215
- * Storage capability interface for abstracting storage operations.
216
- * Enables swapping between browser localStorage and future WASM-based storage.
217
- */
218
- interface IStorageCapability {
219
- /**
220
- * Retrieves a value from storage.
221
- * @param key - The storage key
222
- * @returns The stored value or null if not found
223
- */
224
- get<T>(key: string): Promise<T | null>;
225
- /**
226
- * Stores a value in storage.
227
- * @param key - The storage key
228
- * @param value - The value to store (will be serialized)
229
- */
230
- set<T>(key: string, value: T): Promise<void>;
231
- /**
232
- * Removes a value from storage.
233
- * @param key - The storage key to remove
234
- */
235
- remove(key: string): Promise<void>;
236
- /**
237
- * Clears all values from storage.
238
- */
239
- clear(): Promise<void>;
240
- }
241
- //#endregion
242
- export { MLProviderConfig as a, IMLProviderCapability as i, IRecordingCapability as n, IncodeCanvas as o, RecordingConnection as r, IStorageCapability as t };
@@ -1,85 +0,0 @@
1
- import { loadOpenVidu } from "./openviduLazy-CCDpFWg1.esm.js";
2
- //#region ../infra/src/providers/browser/OpenViduRecordingProvider.ts
3
- function createHiddenContainer() {
4
- const id = `inc_rec_${Math.random().toString(36).slice(2)}`;
5
- const existing = document.getElementById(id);
6
- if (existing) return {
7
- id,
8
- element: existing
9
- };
10
- const div = document.createElement("div");
11
- div.id = id;
12
- div.style.display = "none";
13
- document.body.appendChild(div);
14
- return {
15
- id,
16
- element: div
17
- };
18
- }
19
- var OpenViduRecordingProvider = class {
20
- async connect(params) {
21
- const { OpenVidu } = await loadOpenVidu();
22
- const container = createHiddenContainer();
23
- const ov = new OpenVidu();
24
- const session = ov.initSession();
25
- const videoTrack = params.stream.getVideoTracks()[0];
26
- const audioTrack = params.stream.getAudioTracks()[0];
27
- const hasAudio = audioTrack !== void 0;
28
- const publisher = ov.initPublisher(container.id, {
29
- publishAudio: hasAudio,
30
- audioSource: hasAudio ? audioTrack : false,
31
- videoSource: videoTrack ?? false,
32
- frameRate: 30
33
- });
34
- session.on("exception", (event) => {
35
- const e = event;
36
- params.events?.onSessionException?.({
37
- name: e?.name,
38
- message: e?.message,
39
- sessionId: session.sessionId
40
- });
41
- });
42
- publisher.on("streamCreated", () => {
43
- params.events?.onPublisherCreated?.({
44
- sessionId: session.sessionId,
45
- streamId: publisher.stream?.streamId
46
- });
47
- });
48
- await session.connect(params.sessionToken);
49
- params.events?.onSessionConnected?.(session.sessionId);
50
- try {
51
- await session.publish(publisher);
52
- } catch (error) {
53
- const message = error instanceof Error ? error.message : String(error);
54
- params.events?.onPublisherError?.({
55
- message,
56
- sessionId: session.sessionId,
57
- streamId: publisher.stream?.streamId
58
- });
59
- throw error;
60
- }
61
- return {
62
- sessionId: session.sessionId,
63
- publisher: {
64
- getStreamId: () => publisher.stream?.streamId,
65
- replaceVideoTrack: async (track) => {
66
- await publisher.replaceTrack(track);
67
- },
68
- destroy: () => {}
69
- },
70
- disconnect: async () => {
71
- try {
72
- session.disconnect();
73
- params.stream.getTracks().forEach((t) => {
74
- t.stop();
75
- });
76
- } finally {
77
- params.events?.onSessionDisconnected?.(session.sessionId);
78
- if (container.element.parentNode) container.element.parentNode.removeChild(container.element);
79
- }
80
- }
81
- };
82
- }
83
- };
84
- //#endregion
85
- export { OpenViduRecordingProvider };