@incodetech/core 0.0.0-dev-20260610-8787196e → 0.0.0-dev-20260610-e5b4c4d5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{OpenViduRecordingProvider-BtAVDH2Y.esm.js → OpenViduRecordingProvider-O4GjBseO.esm.js} +1 -1
- package/dist/StreamCanvasCapture-ImiDQdVA.esm.js +118 -0
- package/dist/StreamCanvasCapture-yyl20qd9.d.ts +152 -0
- package/dist/{addressSearch-DPmseXCM.esm.js → addressSearch-rHF9QriL.esm.js} +4 -4
- package/dist/{ae-signature-lqjX_h2U.esm.js → ae-signature-CQjOxLrv.esm.js} +1 -1
- package/dist/ae-signature.d.ts +3 -3
- package/dist/ae-signature.esm.js +7 -7
- package/dist/antifraud.d.ts +3 -3
- package/dist/antifraud.esm.js +6 -6
- package/dist/{antifraudManager-DaUfoGLZ.esm.js → antifraudManager-CZDCQli0.esm.js} +3 -3
- package/dist/{antifraudManager-Bbgl_P0Y.d.ts → antifraudManager-CznnhyvD.d.ts} +2 -2
- package/dist/{antifraudStateMachine-DmhL7cti.esm.js → antifraudStateMachine-Bp7yS1LV.esm.js} +3 -3
- package/dist/authentication.d.ts +13 -12
- package/dist/authentication.esm.js +27 -25
- package/dist/{authenticationManager-DIN4eL_6.esm.js → authenticationManager-C3-IUymg.esm.js} +6 -6
- package/dist/{authenticationManager-ozJVUfiA.d.ts → authenticationManager-CIVY80H9.d.ts} +2 -2
- package/dist/{authenticationStateMachine-DzrcG7XX.esm.js → authenticationStateMachine-3HbNfPoL.esm.js} +8 -8
- package/dist/{backCameraStream-BtCwSIuT.esm.js → backCameraStream-D7Wo4Nbx.esm.js} +3 -3
- package/dist/{browserSimulation-CHpyEI-W.esm.js → browserSimulation-B1dWiXp7.esm.js} +2 -2
- package/dist/camera.d.ts +1 -1
- package/dist/camera.esm.js +4 -4
- package/dist/canvas-SKcRBxsk.esm.js +230 -0
- package/dist/consent.d.ts +3 -3
- package/dist/consent.esm.js +6 -6
- package/dist/{consentManager-CHV12fjQ.d.ts → consentManager-66SjOJ7U.d.ts} +52 -52
- package/dist/{consentManager-D0NGejCx.esm.js → consentManager-DOufCKTj.esm.js} +3 -3
- package/dist/{consentStateMachine-CUOuuC7d.esm.js → consentStateMachine-CUVp1kKY.esm.js} +3 -3
- package/dist/cpf-ocr.d.ts +3 -3
- package/dist/cpf-ocr.esm.js +6 -6
- package/dist/{cpfOcrManager-9ciXe_XT.esm.js → cpfOcrManager-Bm5OlZSa.esm.js} +5 -5
- package/dist/{cpfOcrManager-BR_dJaKV.d.ts → cpfOcrManager-DVSJov4W.d.ts} +22 -22
- package/dist/cross-document-data-match.d.ts +1 -1
- package/dist/cross-document-data-match.esm.js +5 -5
- package/dist/curp-validation.d.ts +7 -7
- package/dist/curp-validation.esm.js +6 -6
- package/dist/{curpValidationManager-BJDxY7JH.esm.js → curpValidationManager-CMXS-tjU.esm.js} +3 -3
- package/dist/{curpValidationManager-VE0Ndj36.d.ts → curpValidationManager-DIFa6O03.d.ts} +3 -3
- package/dist/{curpValidationStateMachine-BBUREbWY.esm.js → curpValidationStateMachine-CD-npCgV.esm.js} +3 -3
- package/dist/custom-fields.d.ts +2 -2
- package/dist/custom-fields.esm.js +5 -5
- package/dist/custom-watchlist.d.ts +1 -1
- package/dist/custom-watchlist.esm.js +5 -5
- package/dist/{customWatchlistStateMachine-qfxMGhCV.esm.js → customWatchlistStateMachine-CF4ETN-z.esm.js} +3 -3
- package/dist/{deepsightLoader-OlmqoVtS.esm.js → deepsightLoader-CTf5NdIB.esm.js} +13 -12
- package/dist/{deepsightService-CeXd7dhh.d.ts → deepsightService-B7ShOkWL.d.ts} +2 -152
- package/dist/{deepsightService-Dh9EiWze.esm.js → deepsightService-Da56SkD4.esm.js} +8 -236
- package/dist/device.esm.js +4 -4
- package/dist/document-capture.d.ts +235 -235
- package/dist/document-capture.esm.js +13 -13
- package/dist/document-upload.d.ts +53 -53
- package/dist/document-upload.esm.js +8 -8
- package/dist/{documentCaptureStateMachine-JqM4pyfY.esm.js → documentCaptureStateMachine-CV1dzgbn.esm.js} +7 -7
- package/dist/dynamic-forms.d.ts +2 -2
- package/dist/dynamic-forms.esm.js +5 -5
- package/dist/ekyb.d.ts +6 -6
- package/dist/ekyb.esm.js +16 -16
- package/dist/{ekybStateMachine-C0DLJplY.esm.js → ekybStateMachine-DWm7C2qW.esm.js} +5 -5
- package/dist/ekyc.d.ts +3 -3
- package/dist/ekyc.esm.js +8 -8
- package/dist/{ekycStateMachine-B5brX021.esm.js → ekycStateMachine-CRiViUGB.esm.js} +5 -5
- package/dist/electronic-signature.d.ts +3 -3
- package/dist/electronic-signature.esm.js +6 -6
- package/dist/{electronicSignatureManager-BY6tiZPR.esm.js → electronicSignatureManager-DECEJ9hm.esm.js} +5 -5
- package/dist/email.d.ts +4 -4
- package/dist/email.esm.js +8 -8
- package/dist/{emailManager-DRUHedQg.esm.js → emailManager-DAIwweQa.esm.js} +4 -4
- package/dist/{emailManager-VP0mIGdj.d.ts → emailManager-lAzDoQOs.d.ts} +3 -3
- package/dist/{emailStateMachine-CZgKn7a1.esm.js → emailStateMachine-C-ltLrvi.esm.js} +5 -5
- package/dist/{endpoints-BPHddOTi.esm.js → endpoints-zEf_JIJU.esm.js} +2 -1
- package/dist/{events-Bsw1l0pH.esm.js → events-Dvvriq9l.esm.js} +3 -2
- package/dist/events.d.ts +1 -0
- package/dist/events.esm.js +2 -2
- package/dist/extensibility.d.ts +26 -25
- package/dist/extensibility.esm.js +56 -54
- package/dist/face-match.d.ts +1 -1
- package/dist/face-match.esm.js +5 -5
- package/dist/{faceCaptureManagerFactory-BTsmDJ06.d.ts → faceCaptureManagerFactory-C_hRHx8a.d.ts} +9 -8
- package/dist/{faceCaptureManagerFactory-DKE4-MLG.esm.js → faceCaptureManagerFactory-kqbUqtrr.esm.js} +4 -4
- package/dist/{faceCaptureSetup-0XUJwf3G.esm.js → faceCaptureSetup-CoZCFG0w.esm.js} +7 -6
- package/dist/{faceMatchStateMachine-i3qgZ176.esm.js → faceMatchStateMachine-CN81-J0s.esm.js} +3 -3
- package/dist/field-comparison.d.ts +3 -3
- package/dist/field-comparison.esm.js +5 -5
- package/dist/{fieldComparisonManager-Bfb3-iwn.esm.js → fieldComparisonManager-Bnuq1mA0.esm.js} +4 -4
- package/dist/{fieldComparisonManager-DAP7RbND.d.ts → fieldComparisonManager-Bu5TaSr3.d.ts} +2 -2
- package/dist/fiscal-qr.d.ts +59 -0
- package/dist/fiscal-qr.esm.js +323 -0
- package/dist/flow-events.d.ts +6 -6
- package/dist/flow.d.ts +12 -12
- package/dist/flow.esm.js +16 -16
- package/dist/{flowCompletionService-DFV8vmO3.esm.js → flowCompletionService-DHpnjBvp.esm.js} +3 -3
- package/dist/{flowServices-DhaF-fP3.esm.js → flowServices-BykryjdA.esm.js} +4 -4
- package/dist/geolocation.d.ts +2 -2
- package/dist/geolocation.esm.js +6 -6
- package/dist/{geolocationStateMachine-DCG_hQkW.esm.js → geolocationStateMachine-D6yBlOQ_.esm.js} +4 -4
- package/dist/{getDeviceClass-cJ-TvND7.esm.js → getDeviceClass-C8Do2qYu.esm.js} +1 -1
- package/dist/government-validation.d.ts +3 -3
- package/dist/government-validation.esm.js +7 -7
- package/dist/{governmentValidationStateMachine-KY_Eu5b-.esm.js → governmentValidationStateMachine-M-iiovMY.esm.js} +5 -5
- package/dist/home.d.ts +15 -15
- package/dist/home.esm.js +3 -3
- package/dist/http-Cai3IoLS.esm.js +0 -0
- package/dist/http.esm.js +2 -1
- package/dist/id-ocr.d.ts +54 -54
- package/dist/id-ocr.esm.js +6 -6
- package/dist/id-verification.d.ts +27 -27
- package/dist/id-verification.esm.js +5 -5
- package/dist/id.d.ts +12 -11
- package/dist/id.esm.js +31 -29
- package/dist/{idCaptureManager-BXkPnZIc.d.ts → idCaptureManager-D-QYESvF.d.ts} +8 -7
- package/dist/{idCaptureManager-CWG0Qgeq.esm.js → idCaptureManager-mQGmxqf1.esm.js} +5 -5
- package/dist/{idCaptureStateMachine-Dqfxbea3.esm.js → idCaptureStateMachine-DXeLlQa_.esm.js} +19 -18
- package/dist/{idOcrStateMachine-DVjkIw10.esm.js → idOcrStateMachine-Cj2uN_q_.esm.js} +5 -5
- package/dist/{idVerificationStateMachine-B_F3G-v-.esm.js → idVerificationStateMachine-DVrl68dQ.esm.js} +3 -3
- package/dist/identity-reuse.d.ts +3 -3
- package/dist/identity-reuse.esm.js +6 -6
- package/dist/{identityReuseManager-CNcsh-xr.esm.js → identityReuseManager-DHYlQW3K.esm.js} +3 -3
- package/dist/{identityReuseManager-DVZLgcfm.d.ts → identityReuseManager-DYb7I3jf.d.ts} +36 -36
- package/dist/{identityReuseStateMachine-BrbaZto8.esm.js → identityReuseStateMachine-Dyfa7yzx.esm.js} +3 -3
- package/dist/{index-B1ijI7RD.d.ts → index-B2RUw1Th.d.ts} +169 -169
- package/dist/{index-C3KOkxmU.d.ts → index-B5hPA0Bg.d.ts} +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.esm.js +12 -12
- package/dist/{invokeOnCaptureCallback-Bty7q0sC.esm.js → invokeOnCaptureCallback-ygByVdnn.esm.js} +1 -1
- package/dist/{lib-DmGBvFHu.esm.js → lib-BY67lgbq.esm.js} +1 -1
- package/dist/mandatory-consent.d.ts +7 -7
- package/dist/mandatory-consent.esm.js +6 -6
- package/dist/{mandatoryConsentManager-BUpEBczR.esm.js → mandatoryConsentManager-BTqe3YNU.esm.js} +3 -3
- package/dist/{mandatoryConsentManager-DwmDNt6y.d.ts → mandatoryConsentManager-DBc5NyKN.d.ts} +55 -55
- package/dist/{mandatoryConsentStateMachine-B6hfQFw1.esm.js → mandatoryConsentStateMachine-4yzCCY4e.esm.js} +3 -3
- package/dist/openviduLazy-B8L--0oe.esm.js +3 -0
- package/dist/{openviduLazy-6AQum7Ca.esm.js → openviduLazy-Dh14JNJc.esm.js} +2 -2
- package/dist/{permissionGuards-DUKOJ-Mt.esm.js → permissionGuards-C1ispV96.esm.js} +1 -1
- package/dist/{permissionServices-BjXAT5OT.esm.js → permissionServices-CG3bMSfG.esm.js} +3 -3
- package/dist/phone.d.ts +4 -4
- package/dist/phone.esm.js +8 -8
- package/dist/{phoneManager-Ddl_CeNb.esm.js → phoneManager-B44MT4ro.esm.js} +4 -4
- package/dist/{phoneManager-BgoX1fvQ.d.ts → phoneManager-fPmIBYQK.d.ts} +3 -3
- package/dist/{phoneStateMachine-CrjW4JrA.esm.js → phoneStateMachine-CMht9LLp.esm.js} +5 -5
- package/dist/{qe-signature-C8uvV_-H.esm.js → qe-signature-DCz2roEC.esm.js} +1 -1
- package/dist/qe-signature.d.ts +3 -3
- package/dist/qe-signature.esm.js +7 -7
- package/dist/{recordingService-DCUipzC7.esm.js → recordingService-DwPmv6FZ.esm.js} +16 -131
- package/dist/redirect-to-mobile.d.ts +3 -3
- package/dist/redirect-to-mobile.esm.js +7 -7
- package/dist/{redirectToMobileManager-CQxCClRy.esm.js → redirectToMobileManager-BAzevDYW.esm.js} +4 -4
- package/dist/{redirectToMobileManager-xOasdN0s.d.ts → redirectToMobileManager-BNe3IzC_.d.ts} +2 -2
- package/dist/{redirectToMobileStateMachine-DHqdmBzc.esm.js → redirectToMobileStateMachine-BmwxrN1h.esm.js} +4 -4
- package/dist/{runChildModule-B1uVG8D-.esm.js → runChildModule-CuoHZ1cx.esm.js} +3 -3
- package/dist/selfie.d.ts +13 -12
- package/dist/selfie.esm.js +28 -26
- package/dist/{selfieManager-CeTXxT2U.d.ts → selfieManager-dUbKRzOh.d.ts} +2 -2
- package/dist/{selfieManager-DpFMP4Rk.esm.js → selfieManager-zH9pAVXE.esm.js} +6 -6
- package/dist/{selfieStateMachine-DCHihi8J.esm.js → selfieStateMachine-Dr5sCDgI.esm.js} +4 -4
- package/dist/{session-Ds1d84mn.esm.js → session-BEtpaQ6D.esm.js} +3 -3
- package/dist/session.d.ts +5 -5
- package/dist/session.esm.js +12 -12
- package/dist/{sessionInitializer-Be88b4WX.esm.js → sessionInitializer-D0Ei5Ol7.esm.js} +7 -7
- package/dist/{setup-BtLWJPSp.d.ts → setup-BbkprdVv.d.ts} +1 -1
- package/dist/{setup-BgxDnUDw.esm.js → setup-DotVj7UA.esm.js} +7 -7
- package/dist/signature.d.ts +2 -2
- package/dist/signature.esm.js +5 -5
- package/dist/{signatureStateMachine-CY1u1o6J.esm.js → signatureStateMachine-CpcyA7CM.esm.js} +4 -4
- package/dist/{stats-AwLva7-C.esm.js → stats-SU3Linba.esm.js} +2 -2
- package/dist/stats.esm.js +3 -3
- package/dist/trust-graph.d.ts +3 -3
- package/dist/trust-graph.esm.js +3 -3
- package/dist/{types-BmZR-K77.d.ts → types-Bj9hdFjU.d.ts} +1 -1
- package/dist/{types-DJsgKeW0.d.ts → types-DOUhndhT.d.ts} +2 -2
- package/dist/{types-BI-jIO73.d.ts → types-NuT8ftBV.d.ts} +1 -1
- package/dist/wasm.d.ts +2 -2
- package/dist/wasm.esm.js +12 -12
- package/dist/watchlist-for-business.d.ts +1 -1
- package/dist/watchlist-for-business.esm.js +5 -5
- package/dist/watchlist.d.ts +1 -1
- package/dist/watchlist.esm.js +5 -5
- package/dist/{watchlistForBusinessStateMachine-CGRko-GU.esm.js → watchlistForBusinessStateMachine-DsEq8xwX.esm.js} +3 -3
- package/dist/{watchlistStateMachine-CWVTWVJY.esm.js → watchlistStateMachine-CREpVW-C.esm.js} +3 -3
- package/dist/workflow.d.ts +97 -97
- package/dist/workflow.esm.js +60 -58
- package/package.json +9 -1
- package/dist/openviduLazy-Dge_R911.esm.js +0 -3
- /package/dist/{Actor-Ds20AUDY.d.ts → Actor-Y0_Fj-KL.d.ts} +0 -0
- /package/dist/{BrowserStorageProvider-BrJver0U.esm.js → BrowserStorageProvider-BpJM-gIl.esm.js} +0 -0
- /package/dist/{BrowserTimerProvider-BESs49g_.esm.js → BrowserTimerProvider-DhNc_x02.esm.js} +0 -0
- /package/dist/{ITimerCapability-gIlcIrAX.esm.js → ITimerCapability-CB0I1Uf2.esm.js} +0 -0
- /package/dist/{IpifyProvider-BQKB2PR-.esm.js → IpifyProvider-D4LWD15E.esm.js} +0 -0
- /package/dist/{Manager-Dh6pC-6V.d.ts → Manager-BHn8wH8K.d.ts} +0 -0
- /package/dist/{MotionSensorProvider-D1JWpMLJ.esm.js → MotionSensorProvider-Bx7Mpzt0.esm.js} +0 -0
- /package/dist/{StateMachine-CENvPkCx.d.ts → StateMachine-BC_nGvrc.d.ts} +0 -0
- /package/dist/{WasmUtilProvider-CeyOvhU2.esm.js → WasmUtilProvider-CiEN7Gjn.esm.js} +0 -0
- /package/dist/{api-YxPMtty2.esm.js → api-CESGtpbH.esm.js} +0 -0
- /package/dist/{apiError-76Dulrw9.esm.js → apiError-B-j-gyDx.esm.js} +0 -0
- /package/dist/{camera-P7dse339.esm.js → camera-DJWm3V4g.esm.js} +0 -0
- /package/dist/{camera-D7qYpKeG.d.ts → camera-SRBpPq2X.d.ts} +0 -0
- /package/dist/{chunk-wtC55c3P.esm.js → chunk-CMUKZ2uL.esm.js} +0 -0
- /package/dist/{cpf-COPPtEoQ.esm.js → cpf-BRzggV8G.esm.js} +0 -0
- /package/dist/{dateUtils-CibceEoG.esm.js → dateUtils-AksLQmgV.esm.js} +0 -0
- /package/dist/{flowCompletionService-DOHFSAJ2.d.ts → flowCompletionService-BdR2cGgB.d.ts} +0 -0
- /package/dist/{getBrowser-CMJJeBF8.esm.js → getBrowser-C8DP7oTB.esm.js} +0 -0
- /package/dist/{getDeviceClass-C5yT6K2e.esm.js → getDeviceClass-C0olyNFS.esm.js} +0 -0
- /package/dist/{otp-lOELtCck.esm.js → otp-CGMdUzBC.esm.js} +0 -0
- /package/dist/{otp-Ci7E_eNt.d.ts → otp-DF5A0sFx.d.ts} +0 -0
- /package/dist/{platform-D871crJL.esm.js → platform-SKvEfCBh.esm.js} +0 -0
- /package/dist/{types-CRp-Maxh.esm.js → types-DsnEVMhr.esm.js} +0 -0
- /package/dist/{types-Cojkwi9p.d.ts → types-DvGZI7BF.d.ts} +0 -0
- /package/dist/{types-DI4L4PFE.d.ts → types-ya0LN_MX.d.ts} +0 -0
- /package/dist/{warmup-Bx2GXY3L.d.ts → warmup-Dg8Lh-50.d.ts} +0 -0
- /package/dist/{xstate.esm-CWoFJOio.esm.js → xstate.esm-C9wncMQa.esm.js} +0 -0
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
//#region ../infra/src/media/canvas.ts
|
|
2
|
+
/**
|
|
3
|
+
* Class representing a canvas element for image capture and manipulation.
|
|
4
|
+
*/
|
|
5
|
+
var IncodeCanvas = class IncodeCanvas {
|
|
6
|
+
/**
|
|
7
|
+
* Creates an {@link IncodeCanvas} from a raw {@link ImageData} frame.
|
|
8
|
+
* @param imageData - Frame pixels in RGBA format
|
|
9
|
+
* @returns An {@link IncodeCanvas} containing the provided pixels
|
|
10
|
+
*/
|
|
11
|
+
static fromImageData(imageData) {
|
|
12
|
+
const canvas = document.createElement("canvas");
|
|
13
|
+
canvas.width = imageData.width;
|
|
14
|
+
canvas.height = imageData.height;
|
|
15
|
+
const context = canvas.getContext("2d", { willReadFrequently: true });
|
|
16
|
+
if (!context) return new IncodeCanvas(canvas);
|
|
17
|
+
if ("putImageData" in context) context.putImageData(imageData, 0, 0);
|
|
18
|
+
return new IncodeCanvas(canvas);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Create a new canvas element.
|
|
22
|
+
* @param canvas_ - The canvas element to clone.
|
|
23
|
+
*/
|
|
24
|
+
constructor(canvas_) {
|
|
25
|
+
this.base64Image = null;
|
|
26
|
+
this.blobData = null;
|
|
27
|
+
this.canvas = document.createElement("canvas");
|
|
28
|
+
this.canvas.width = canvas_.width;
|
|
29
|
+
this.canvas.height = canvas_.height;
|
|
30
|
+
const context = this.canvas.getContext("2d");
|
|
31
|
+
if (context) context.drawImage(canvas_, 0, 0);
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Check if the current canvas is valid.
|
|
35
|
+
*/
|
|
36
|
+
checkCanvas() {
|
|
37
|
+
return this.canvas && this.canvas.width > 1 && this.canvas.height > 1;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Disposes of resources, including revoking object URLs to prevent memory leaks.
|
|
41
|
+
*/
|
|
42
|
+
dispose() {
|
|
43
|
+
if (this.blobData?.url) {
|
|
44
|
+
URL.revokeObjectURL(this.blobData.url);
|
|
45
|
+
this.blobData = null;
|
|
46
|
+
}
|
|
47
|
+
this.base64Image = null;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Release the data stored by IncodeCanvas.
|
|
51
|
+
*/
|
|
52
|
+
release() {
|
|
53
|
+
if (!this.checkCanvas()) return;
|
|
54
|
+
this.canvas.width = 1;
|
|
55
|
+
this.canvas.height = 1;
|
|
56
|
+
this.canvas.getContext("2d")?.clearRect(0, 0, 1, 1);
|
|
57
|
+
this.base64Image = null;
|
|
58
|
+
if (this.blobData?.url) URL.revokeObjectURL(this.blobData.url);
|
|
59
|
+
this.blobData = null;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Revokes the object URL if one exists, preventing memory leaks.
|
|
63
|
+
* Use this when you no longer need the preview image URL.
|
|
64
|
+
*/
|
|
65
|
+
revokeObjectURL() {
|
|
66
|
+
if (this.blobData?.url) {
|
|
67
|
+
URL.revokeObjectURL(this.blobData.url);
|
|
68
|
+
this.blobData = {
|
|
69
|
+
...this.blobData,
|
|
70
|
+
url: ""
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Get the width of the canvas.
|
|
76
|
+
*/
|
|
77
|
+
width() {
|
|
78
|
+
if (!this.checkCanvas()) return null;
|
|
79
|
+
return this.canvas.width;
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* Get the height of the canvas.
|
|
83
|
+
*/
|
|
84
|
+
height() {
|
|
85
|
+
if (!this.checkCanvas()) return null;
|
|
86
|
+
return this.canvas.height;
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* Set the width of the canvas.
|
|
90
|
+
*/
|
|
91
|
+
setWidth(width) {
|
|
92
|
+
if (!this.checkCanvas()) return;
|
|
93
|
+
this.canvas.width = width;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Set the height of the canvas.
|
|
97
|
+
*/
|
|
98
|
+
setHeight(height) {
|
|
99
|
+
if (!this.checkCanvas()) return;
|
|
100
|
+
this.canvas.height = height;
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Clone the current canvas.
|
|
104
|
+
*/
|
|
105
|
+
clone() {
|
|
106
|
+
if (!this.checkCanvas()) return null;
|
|
107
|
+
const cloned = new IncodeCanvas(this.canvas);
|
|
108
|
+
cloned.setBase64Image(this.base64Image);
|
|
109
|
+
return cloned;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Deep clone the current IncodeCanvas including blob data.
|
|
113
|
+
*/
|
|
114
|
+
async deepClone() {
|
|
115
|
+
const cloned = this.clone();
|
|
116
|
+
if (!cloned) return null;
|
|
117
|
+
if (this.blobData) await cloned.setBlobData(this.blobData);
|
|
118
|
+
return cloned;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Returns the drawing context on the canvas.
|
|
122
|
+
*/
|
|
123
|
+
getContext(contextId, contextAttributes) {
|
|
124
|
+
if (!this.checkCanvas()) return null;
|
|
125
|
+
const context = this.canvas.getContext(contextId, contextAttributes);
|
|
126
|
+
return context instanceof CanvasRenderingContext2D ? context : null;
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Retrieves the image data from the canvas.
|
|
130
|
+
*/
|
|
131
|
+
getImageData() {
|
|
132
|
+
if (!this.checkCanvas()) return null;
|
|
133
|
+
const context = this.canvas.getContext("2d", { willReadFrequently: true });
|
|
134
|
+
if (!context) return null;
|
|
135
|
+
return context.getImageData(0, 0, this.canvas.width, this.canvas.height);
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Updates the base64 representation of the current canvas image.
|
|
139
|
+
*/
|
|
140
|
+
updateBase64Image(jpegQuality = 1) {
|
|
141
|
+
if (!this.checkCanvas()) return;
|
|
142
|
+
this.base64Image = this.canvas.toDataURL("image/jpeg", jpegQuality);
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Converts the current canvas element to a base64 string.
|
|
146
|
+
*/
|
|
147
|
+
getBase64Image(jpegQuality = 1, includeDataURLPrefix = false) {
|
|
148
|
+
if (!this.checkCanvas()) return null;
|
|
149
|
+
if (this.base64Image === null) this.updateBase64Image(jpegQuality);
|
|
150
|
+
const base64Image = this.base64Image;
|
|
151
|
+
if (base64Image === null) return null;
|
|
152
|
+
if (includeDataURLPrefix) return base64Image;
|
|
153
|
+
const commaIndex = base64Image.indexOf(",");
|
|
154
|
+
if (commaIndex === -1) return base64Image;
|
|
155
|
+
return base64Image.slice(commaIndex + 1);
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Sets the base64 representation of the current canvas image.
|
|
159
|
+
*/
|
|
160
|
+
setBase64Image(base64Image) {
|
|
161
|
+
this.base64Image = base64Image;
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* Updates the Blob representation of the current canvas image.
|
|
165
|
+
*/
|
|
166
|
+
updateBlob(jpegQuality = 1, includeDataURLPrefix = false) {
|
|
167
|
+
if (!this.checkCanvas()) return;
|
|
168
|
+
if (this.base64Image === null) this.updateBase64Image(jpegQuality);
|
|
169
|
+
const base64 = this.getBase64Image(jpegQuality, includeDataURLPrefix);
|
|
170
|
+
if (base64) this.blobData = IncodeCanvas.base64ToBlob(base64);
|
|
171
|
+
}
|
|
172
|
+
/**
|
|
173
|
+
* Converts a base64 string to a Blob and creates a URL for it.
|
|
174
|
+
*/
|
|
175
|
+
static base64ToBlob(base64) {
|
|
176
|
+
try {
|
|
177
|
+
const binary = atob(base64);
|
|
178
|
+
const array = [];
|
|
179
|
+
for (let i = 0; i < binary.length; i++) array.push(binary.charCodeAt(i));
|
|
180
|
+
const blob = new Blob([new Uint8Array(array)]);
|
|
181
|
+
return {
|
|
182
|
+
blob,
|
|
183
|
+
url: URL.createObjectURL(blob)
|
|
184
|
+
};
|
|
185
|
+
} catch (error) {
|
|
186
|
+
console.error("Failed to convert base64 string to Blob:", error);
|
|
187
|
+
}
|
|
188
|
+
return null;
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* Retrieves the Blob data and its URL from the current canvas.
|
|
192
|
+
*/
|
|
193
|
+
getBlobData(jpegQuality = 1, includeDataURLPrefix = false) {
|
|
194
|
+
if (!this.checkCanvas()) return null;
|
|
195
|
+
if (this.blobData === null) this.updateBlob(jpegQuality, includeDataURLPrefix);
|
|
196
|
+
return this.blobData;
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* Sets the Blob data of the current canvas image.
|
|
200
|
+
*/
|
|
201
|
+
async setBlobData(blobData) {
|
|
202
|
+
const blobDataArrayBuffer = await blobData.blob.arrayBuffer();
|
|
203
|
+
this.blobData = {
|
|
204
|
+
blob: new Blob([blobDataArrayBuffer], { type: blobData.blob.type }),
|
|
205
|
+
url: blobData.url
|
|
206
|
+
};
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Returns a resized canvas according to video element size.
|
|
210
|
+
*/
|
|
211
|
+
getResizedCanvas(videoElementWidth, videoElementHeight) {
|
|
212
|
+
if (!this.checkCanvas()) return null;
|
|
213
|
+
const cameraOffsetX = Math.abs(videoElementWidth - window.innerWidth);
|
|
214
|
+
const resized = new IncodeCanvas(document.createElement("canvas"));
|
|
215
|
+
const canvasHeight = this.height();
|
|
216
|
+
if (!canvasHeight) return null;
|
|
217
|
+
const ratio = canvasHeight / videoElementHeight;
|
|
218
|
+
const newWidth = window.innerWidth;
|
|
219
|
+
const newHeight = window.innerHeight;
|
|
220
|
+
resized.setWidth(newWidth);
|
|
221
|
+
resized.setHeight(newHeight);
|
|
222
|
+
const context = resized.getContext("2d");
|
|
223
|
+
if (!context) return null;
|
|
224
|
+
context.drawImage(this.canvas, ratio * cameraOffsetX / 2, 0, ratio * newWidth, ratio * newHeight, 0, 0, newWidth, newHeight);
|
|
225
|
+
return resized;
|
|
226
|
+
}
|
|
227
|
+
};
|
|
228
|
+
|
|
229
|
+
//#endregion
|
|
230
|
+
export { IncodeCanvas as t };
|
package/dist/consent.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./Manager-
|
|
2
|
-
import "./Actor-
|
|
3
|
-
import { a as ConsentActor, c as ConsentConfig, i as createConsentManagerFromActor, n as ConsentState, o as consentMachine, r as createConsentManager, s as ConsentCheckbox, t as ConsentManager } from "./consentManager-
|
|
1
|
+
import "./Manager-BHn8wH8K.js";
|
|
2
|
+
import "./Actor-Y0_Fj-KL.js";
|
|
3
|
+
import { a as ConsentActor, c as ConsentConfig, i as createConsentManagerFromActor, n as ConsentState, o as consentMachine, r as createConsentManager, s as ConsentCheckbox, t as ConsentManager } from "./consentManager-66SjOJ7U.js";
|
|
4
4
|
export { type ConsentActor, type ConsentCheckbox, type ConsentConfig, type ConsentManager, type ConsentState, consentMachine, createConsentManager, createConsentManagerFromActor };
|
package/dist/consent.esm.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "./api-
|
|
2
|
-
import "./events-
|
|
3
|
-
import "./endpoints-
|
|
4
|
-
import "./xstate.esm-
|
|
5
|
-
import { t as consentMachine } from "./consentStateMachine-
|
|
6
|
-
import { n as createConsentManagerFromActor, t as createConsentManager } from "./consentManager-
|
|
1
|
+
import "./api-CESGtpbH.esm.js";
|
|
2
|
+
import "./events-Dvvriq9l.esm.js";
|
|
3
|
+
import "./endpoints-zEf_JIJU.esm.js";
|
|
4
|
+
import "./xstate.esm-C9wncMQa.esm.js";
|
|
5
|
+
import { t as consentMachine } from "./consentStateMachine-CUVp1kKY.esm.js";
|
|
6
|
+
import { n as createConsentManagerFromActor, t as createConsentManager } from "./consentManager-DOufCKTj.esm.js";
|
|
7
7
|
|
|
8
8
|
export { consentMachine, createConsentManager, createConsentManagerFromActor };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as Manager } from "./Manager-
|
|
2
|
-
import { t as ActorRefFrom } from "./Actor-
|
|
3
|
-
import * as
|
|
1
|
+
import { t as Manager } from "./Manager-BHn8wH8K.js";
|
|
2
|
+
import { t as ActorRefFrom } from "./Actor-Y0_Fj-KL.js";
|
|
3
|
+
import * as xstate740 from "xstate";
|
|
4
4
|
|
|
5
5
|
//#region src/modules/consent/types.d.ts
|
|
6
6
|
type ConsentConfig = {
|
|
@@ -37,7 +37,7 @@ type ConsentContext = {
|
|
|
37
37
|
type ConsentInput = {
|
|
38
38
|
config: ConsentConfig;
|
|
39
39
|
};
|
|
40
|
-
declare const consentMachine:
|
|
40
|
+
declare const consentMachine: xstate740.StateMachine<ConsentContext, {
|
|
41
41
|
type: "LOAD";
|
|
42
42
|
} | {
|
|
43
43
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -49,55 +49,55 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
49
49
|
} | {
|
|
50
50
|
type: "RESET";
|
|
51
51
|
}, {
|
|
52
|
-
[x: string]:
|
|
52
|
+
[x: string]: xstate740.ActorRefFromLogic<xstate740.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
53
53
|
consentId: string;
|
|
54
54
|
language?: string;
|
|
55
|
-
},
|
|
55
|
+
}, xstate740.EventObject>> | xstate740.ActorRefFromLogic<xstate740.PromiseActorLogic<void, {
|
|
56
56
|
languageConsentId: string;
|
|
57
57
|
checkboxes: ConsentCheckbox[];
|
|
58
|
-
},
|
|
59
|
-
},
|
|
58
|
+
}, xstate740.EventObject>> | undefined;
|
|
59
|
+
}, xstate740.Values<{
|
|
60
60
|
fetchConsent: {
|
|
61
61
|
src: "fetchConsent";
|
|
62
|
-
logic:
|
|
62
|
+
logic: xstate740.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
63
63
|
consentId: string;
|
|
64
64
|
language?: string;
|
|
65
|
-
},
|
|
65
|
+
}, xstate740.EventObject>;
|
|
66
66
|
id: string | undefined;
|
|
67
67
|
};
|
|
68
68
|
submitConsent: {
|
|
69
69
|
src: "submitConsent";
|
|
70
|
-
logic:
|
|
70
|
+
logic: xstate740.PromiseActorLogic<void, {
|
|
71
71
|
languageConsentId: string;
|
|
72
72
|
checkboxes: ConsentCheckbox[];
|
|
73
|
-
},
|
|
73
|
+
}, xstate740.EventObject>;
|
|
74
74
|
id: string | undefined;
|
|
75
75
|
};
|
|
76
|
-
}>,
|
|
77
|
-
clearError: {
|
|
78
|
-
type: "clearError";
|
|
79
|
-
params: xstate1484.NonReducibleUnknown;
|
|
80
|
-
};
|
|
76
|
+
}>, xstate740.Values<{
|
|
81
77
|
setError: {
|
|
82
78
|
type: "setError";
|
|
83
|
-
params:
|
|
79
|
+
params: xstate740.NonReducibleUnknown;
|
|
80
|
+
};
|
|
81
|
+
clearError: {
|
|
82
|
+
type: "clearError";
|
|
83
|
+
params: xstate740.NonReducibleUnknown;
|
|
84
84
|
};
|
|
85
85
|
resetContext: {
|
|
86
86
|
type: "resetContext";
|
|
87
|
-
params:
|
|
87
|
+
params: xstate740.NonReducibleUnknown;
|
|
88
88
|
};
|
|
89
89
|
setConsentData: {
|
|
90
90
|
type: "setConsentData";
|
|
91
|
-
params:
|
|
91
|
+
params: xstate740.NonReducibleUnknown;
|
|
92
92
|
};
|
|
93
93
|
toggleCheckbox: {
|
|
94
94
|
type: "toggleCheckbox";
|
|
95
|
-
params:
|
|
95
|
+
params: xstate740.NonReducibleUnknown;
|
|
96
96
|
};
|
|
97
97
|
}>, {
|
|
98
98
|
type: "canSubmit";
|
|
99
99
|
params: unknown;
|
|
100
|
-
}, never, "error" | "idle" | "finished" | "loading" | "
|
|
100
|
+
}, never, "error" | "idle" | "finished" | "loading" | "display" | "submitting", string, ConsentInput, xstate740.NonReducibleUnknown, xstate740.EventObject, xstate740.MetaObject, {
|
|
101
101
|
readonly id: "consent";
|
|
102
102
|
readonly initial: "idle";
|
|
103
103
|
readonly context: ({
|
|
@@ -106,73 +106,73 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
106
106
|
spawn: {
|
|
107
107
|
<TSrc extends "fetchConsent" | "submitConsent">(logic: TSrc, ...[options]: ({
|
|
108
108
|
src: "fetchConsent";
|
|
109
|
-
logic:
|
|
109
|
+
logic: xstate740.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
110
110
|
consentId: string;
|
|
111
111
|
language?: string;
|
|
112
|
-
},
|
|
112
|
+
}, xstate740.EventObject>;
|
|
113
113
|
id: string | undefined;
|
|
114
114
|
} extends infer T ? T extends {
|
|
115
115
|
src: "fetchConsent";
|
|
116
|
-
logic:
|
|
116
|
+
logic: xstate740.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
117
117
|
consentId: string;
|
|
118
118
|
language?: string;
|
|
119
|
-
},
|
|
119
|
+
}, xstate740.EventObject>;
|
|
120
120
|
id: string | undefined;
|
|
121
121
|
} ? T extends {
|
|
122
122
|
src: TSrc;
|
|
123
|
-
} ?
|
|
123
|
+
} ? xstate740.ConditionalRequired<[options?: ({
|
|
124
124
|
id?: T["id"] | undefined;
|
|
125
125
|
systemId?: string;
|
|
126
|
-
input?:
|
|
126
|
+
input?: xstate740.InputFrom<T["logic"]> | undefined;
|
|
127
127
|
syncSnapshot?: boolean;
|
|
128
|
-
} & { [K in
|
|
128
|
+
} & { [K in xstate740.RequiredActorOptions<T>]: unknown }) | undefined], xstate740.IsNotNever<xstate740.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
129
129
|
src: "submitConsent";
|
|
130
|
-
logic:
|
|
130
|
+
logic: xstate740.PromiseActorLogic<void, {
|
|
131
131
|
languageConsentId: string;
|
|
132
132
|
checkboxes: ConsentCheckbox[];
|
|
133
|
-
},
|
|
133
|
+
}, xstate740.EventObject>;
|
|
134
134
|
id: string | undefined;
|
|
135
135
|
} extends infer T_1 ? T_1 extends {
|
|
136
136
|
src: "submitConsent";
|
|
137
|
-
logic:
|
|
137
|
+
logic: xstate740.PromiseActorLogic<void, {
|
|
138
138
|
languageConsentId: string;
|
|
139
139
|
checkboxes: ConsentCheckbox[];
|
|
140
|
-
},
|
|
140
|
+
}, xstate740.EventObject>;
|
|
141
141
|
id: string | undefined;
|
|
142
142
|
} ? T_1 extends {
|
|
143
143
|
src: TSrc;
|
|
144
|
-
} ?
|
|
144
|
+
} ? xstate740.ConditionalRequired<[options?: ({
|
|
145
145
|
id?: T_1["id"] | undefined;
|
|
146
146
|
systemId?: string;
|
|
147
|
-
input?:
|
|
147
|
+
input?: xstate740.InputFrom<T_1["logic"]> | undefined;
|
|
148
148
|
syncSnapshot?: boolean;
|
|
149
|
-
} & { [K_1 in
|
|
149
|
+
} & { [K_1 in xstate740.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate740.IsNotNever<xstate740.RequiredActorOptions<T_1>>> : never : never : never)): xstate740.ActorRefFromLogic<xstate740.GetConcreteByKey<xstate740.Values<{
|
|
150
150
|
fetchConsent: {
|
|
151
151
|
src: "fetchConsent";
|
|
152
|
-
logic:
|
|
152
|
+
logic: xstate740.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
153
153
|
consentId: string;
|
|
154
154
|
language?: string;
|
|
155
|
-
},
|
|
155
|
+
}, xstate740.EventObject>;
|
|
156
156
|
id: string | undefined;
|
|
157
157
|
};
|
|
158
158
|
submitConsent: {
|
|
159
159
|
src: "submitConsent";
|
|
160
|
-
logic:
|
|
160
|
+
logic: xstate740.PromiseActorLogic<void, {
|
|
161
161
|
languageConsentId: string;
|
|
162
162
|
checkboxes: ConsentCheckbox[];
|
|
163
|
-
},
|
|
163
|
+
}, xstate740.EventObject>;
|
|
164
164
|
id: string | undefined;
|
|
165
165
|
};
|
|
166
166
|
}>, "src", TSrc>["logic"]>;
|
|
167
|
-
<TLogic extends
|
|
167
|
+
<TLogic extends xstate740.AnyActorLogic>(src: TLogic, ...[options]: xstate740.ConditionalRequired<[options?: ({
|
|
168
168
|
id?: never;
|
|
169
169
|
systemId?: string;
|
|
170
|
-
input?:
|
|
170
|
+
input?: xstate740.InputFrom<TLogic> | undefined;
|
|
171
171
|
syncSnapshot?: boolean;
|
|
172
|
-
} & { [K in
|
|
172
|
+
} & { [K in xstate740.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate740.IsNotNever<xstate740.RequiredLogicInput<TLogic>>>): xstate740.ActorRefFromLogic<TLogic>;
|
|
173
173
|
};
|
|
174
174
|
input: ConsentInput;
|
|
175
|
-
self:
|
|
175
|
+
self: xstate740.ActorRef<xstate740.MachineSnapshot<ConsentContext, {
|
|
176
176
|
type: "LOAD";
|
|
177
177
|
} | {
|
|
178
178
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -183,7 +183,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
183
183
|
type: "RETRY";
|
|
184
184
|
} | {
|
|
185
185
|
type: "RESET";
|
|
186
|
-
}, Record<string,
|
|
186
|
+
}, Record<string, xstate740.AnyActorRef | undefined>, xstate740.StateValue, string, unknown, any, any>, {
|
|
187
187
|
type: "LOAD";
|
|
188
188
|
} | {
|
|
189
189
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -194,7 +194,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
194
194
|
type: "RETRY";
|
|
195
195
|
} | {
|
|
196
196
|
type: "RESET";
|
|
197
|
-
},
|
|
197
|
+
}, xstate740.AnyEventObject>;
|
|
198
198
|
}) => {
|
|
199
199
|
config: ConsentConfig;
|
|
200
200
|
title: string;
|
|
@@ -232,7 +232,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
232
232
|
} | {
|
|
233
233
|
type: "RESET";
|
|
234
234
|
};
|
|
235
|
-
self:
|
|
235
|
+
self: xstate740.ActorRef<xstate740.MachineSnapshot<ConsentContext, {
|
|
236
236
|
type: "LOAD";
|
|
237
237
|
} | {
|
|
238
238
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -243,7 +243,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
243
243
|
type: "RETRY";
|
|
244
244
|
} | {
|
|
245
245
|
type: "RESET";
|
|
246
|
-
}, Record<string,
|
|
246
|
+
}, Record<string, xstate740.AnyActorRef>, xstate740.StateValue, string, unknown, any, any>, {
|
|
247
247
|
type: "LOAD";
|
|
248
248
|
} | {
|
|
249
249
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -254,7 +254,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
254
254
|
type: "RETRY";
|
|
255
255
|
} | {
|
|
256
256
|
type: "RESET";
|
|
257
|
-
},
|
|
257
|
+
}, xstate740.AnyEventObject>;
|
|
258
258
|
}) => {
|
|
259
259
|
consentId: string;
|
|
260
260
|
language: string | undefined;
|
|
@@ -304,7 +304,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
304
304
|
} | {
|
|
305
305
|
type: "RESET";
|
|
306
306
|
};
|
|
307
|
-
self:
|
|
307
|
+
self: xstate740.ActorRef<xstate740.MachineSnapshot<ConsentContext, {
|
|
308
308
|
type: "LOAD";
|
|
309
309
|
} | {
|
|
310
310
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -315,7 +315,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
315
315
|
type: "RETRY";
|
|
316
316
|
} | {
|
|
317
317
|
type: "RESET";
|
|
318
|
-
}, Record<string,
|
|
318
|
+
}, Record<string, xstate740.AnyActorRef>, xstate740.StateValue, string, unknown, any, any>, {
|
|
319
319
|
type: "LOAD";
|
|
320
320
|
} | {
|
|
321
321
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -326,7 +326,7 @@ declare const consentMachine: xstate1484.StateMachine<ConsentContext, {
|
|
|
326
326
|
type: "RETRY";
|
|
327
327
|
} | {
|
|
328
328
|
type: "RESET";
|
|
329
|
-
},
|
|
329
|
+
}, xstate740.AnyEventObject>;
|
|
330
330
|
}) => {
|
|
331
331
|
languageConsentId: string;
|
|
332
332
|
checkboxes: ConsentCheckbox[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-
|
|
2
|
-
import { c as createManager, s as createActor } from "./xstate.esm-
|
|
3
|
-
import { t as consentMachine } from "./consentStateMachine-
|
|
1
|
+
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-Dvvriq9l.esm.js";
|
|
2
|
+
import { c as createManager, s as createActor } from "./xstate.esm-C9wncMQa.esm.js";
|
|
3
|
+
import { t as consentMachine } from "./consentStateMachine-CUVp1kKY.esm.js";
|
|
4
4
|
|
|
5
5
|
//#region src/modules/consent/consentActor.ts
|
|
6
6
|
function createConsentActor(options) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as api } from "./api-
|
|
2
|
-
import { t as endpoints } from "./endpoints-
|
|
3
|
-
import { a as fromPromise, r as assign, t as setup } from "./xstate.esm-
|
|
1
|
+
import { t as api } from "./api-CESGtpbH.esm.js";
|
|
2
|
+
import { t as endpoints } from "./endpoints-zEf_JIJU.esm.js";
|
|
3
|
+
import { a as fromPromise, r as assign, t as setup } from "./xstate.esm-C9wncMQa.esm.js";
|
|
4
4
|
|
|
5
5
|
//#region src/modules/consent/consentServices.ts
|
|
6
6
|
async function fetchCombinedConsent(consentId, language, signal) {
|
package/dist/cpf-ocr.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./Manager-
|
|
2
|
-
import "./Actor-
|
|
3
|
-
import { a as CpfOcrActor, i as createCpfOcrManagerFromActor, n as CpfOcrState, o as cpfOcrMachine, r as createCpfOcrManager, t as CpfOcrManager } from "./cpfOcrManager-
|
|
1
|
+
import "./Manager-BHn8wH8K.js";
|
|
2
|
+
import "./Actor-Y0_Fj-KL.js";
|
|
3
|
+
import { a as CpfOcrActor, i as createCpfOcrManagerFromActor, n as CpfOcrState, o as cpfOcrMachine, r as createCpfOcrManager, t as CpfOcrManager } from "./cpfOcrManager-DVSJov4W.js";
|
|
4
4
|
|
|
5
5
|
//#region src/modules/cpf-ocr/cpfOcrUtils.d.ts
|
|
6
6
|
declare function formatCPF(value: string): string;
|
package/dist/cpf-ocr.esm.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "./api-
|
|
2
|
-
import "./events-
|
|
3
|
-
import "./endpoints-
|
|
4
|
-
import "./xstate.esm-
|
|
5
|
-
import { a as isValidCPF, i as formatCPF, n as createCpfOcrManagerFromActor, r as cpfOcrMachine, t as createCpfOcrManager } from "./cpfOcrManager-
|
|
6
|
-
import "./cpf-
|
|
1
|
+
import "./api-CESGtpbH.esm.js";
|
|
2
|
+
import "./events-Dvvriq9l.esm.js";
|
|
3
|
+
import "./endpoints-zEf_JIJU.esm.js";
|
|
4
|
+
import "./xstate.esm-C9wncMQa.esm.js";
|
|
5
|
+
import { a as isValidCPF, i as formatCPF, n as createCpfOcrManagerFromActor, r as cpfOcrMachine, t as createCpfOcrManager } from "./cpfOcrManager-Bm5OlZSa.esm.js";
|
|
6
|
+
import "./cpf-BRzggV8G.esm.js";
|
|
7
7
|
|
|
8
8
|
export { cpfOcrMachine, createCpfOcrManager, createCpfOcrManagerFromActor, formatCPF, isValidCPF };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as api } from "./api-
|
|
2
|
-
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-
|
|
3
|
-
import { t as endpoints } from "./endpoints-
|
|
4
|
-
import { a as fromPromise, c as createManager, r as assign, s as createActor, t as setup } from "./xstate.esm-
|
|
5
|
-
import { t as validateCPF } from "./cpf-
|
|
1
|
+
import { t as api } from "./api-CESGtpbH.esm.js";
|
|
2
|
+
import { n as eventModuleNames, o as createManagerInstrumentation } from "./events-Dvvriq9l.esm.js";
|
|
3
|
+
import { t as endpoints } from "./endpoints-zEf_JIJU.esm.js";
|
|
4
|
+
import { a as fromPromise, c as createManager, r as assign, s as createActor, t as setup } from "./xstate.esm-C9wncMQa.esm.js";
|
|
5
|
+
import { t as validateCPF } from "./cpf-BRzggV8G.esm.js";
|
|
6
6
|
|
|
7
7
|
//#region src/modules/cpf-ocr/cpfOcrServices.ts
|
|
8
8
|
async function fetchCpfOcrData(signal) {
|