@incodetech/core 2.1.1-rc.6 → 2.1.1-rc.7
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/BrowserStorageProvider-DaKI3I0m.esm.js +85 -0
- package/dist/ae-signature.d.ts +1 -1
- package/dist/authentication.esm.js +9 -9
- package/dist/{authenticationManager-DuMSpelF.esm.js → authenticationManager-Dwf7TrZC.esm.js} +3 -3
- package/dist/{authenticationStateMachine-CDG0SMYg.esm.js → authenticationStateMachine-BBNa41d5.esm.js} +2 -2
- package/dist/{browserSimulation-CWJhFPZ2.esm.js → browserSimulation-DZwEy9bu.esm.js} +14 -1
- package/dist/certificate-issuance.d.ts +28 -28
- package/dist/consent.d.ts +1 -1
- package/dist/{consentManager-2EPNWwaG.d.ts → consentManager-BvgtYr9W.d.ts} +50 -50
- package/dist/cpf-ocr.d.ts +1 -1
- package/dist/{cpfOcrManager-Bg7WqgVy.d.ts → cpfOcrManager-2eYelPF7.d.ts} +17 -17
- package/dist/{deepsightLoader-CmbuFd4Q.esm.js → deepsightLoader-bisFKMf_.esm.js} +3 -3
- package/dist/{deepsightService-CkZqM1Q2.esm.js → deepsightService-CViys6T4.esm.js} +1 -1
- package/dist/document-capture.d.ts +174 -174
- package/dist/document-upload.d.ts +43 -43
- package/dist/ekyb.esm.js +4 -4
- package/dist/{ekybStateMachine-D5vj8UG_.esm.js → ekybStateMachine-_vaRFELH.esm.js} +1 -1
- package/dist/electronic-signature.d.ts +1 -1
- package/dist/extensibility.d.ts +13 -9
- package/dist/extensibility.esm.js +14 -14
- package/dist/{faceCaptureManagerFactory-B65bYWfD.esm.js → faceCaptureManagerFactory-Cf8m_RNb.esm.js} +1 -1
- package/dist/{faceCaptureSetup-CoQ5A9Il.esm.js → faceCaptureSetup-Gj6XnsY4.esm.js} +2 -2
- package/dist/flow.d.ts +2 -2
- package/dist/flow.esm.js +3 -3
- package/dist/{flowServices-CYMfu_12.esm.js → flowServices-OFgzA7NX.esm.js} +1 -1
- package/dist/home.d.ts +10 -10
- package/dist/id-ocr.d.ts +1 -1
- package/dist/id-verification.d.ts +25 -25
- package/dist/id.esm.js +8 -8
- package/dist/{idCaptureManager-Cq1DSv6P.esm.js → idCaptureManager-BziLyrVE.esm.js} +2 -2
- package/dist/{idCaptureStateMachine-BqjYsLFf.esm.js → idCaptureStateMachine-B7vsPrsl.esm.js} +4 -4
- package/dist/{idOcrManager-CXtyyf3I.d.ts → idOcrManager-BeUOERWK.d.ts} +52 -52
- package/dist/identity-reuse.d.ts +1 -1
- package/dist/{identityReuseManager-BNf21Y6b.d.ts → identityReuseManager-D1C3DNjo.d.ts} +31 -31
- package/dist/{index-CPLWHXKr.d.ts → index-Dzf83PXV.d.ts} +150 -150
- package/dist/index.esm.js +3 -3
- package/dist/mandatory-consent.d.ts +1 -1
- package/dist/{mandatoryConsentManager-s6xcax0K.d.ts → mandatoryConsentManager-BxZjDE9f.d.ts} +50 -50
- package/dist/{onDeviceFaceResults-CAfvpjnC.esm.js → onDeviceFaceResults-BWxOJueW.esm.js} +1 -1
- package/dist/personhood.esm.js +5 -5
- package/dist/qe-signature.d.ts +1 -1
- package/dist/{recordingService-Df_A6oXO.esm.js → recordingService-lBmeVE49.esm.js} +1 -1
- package/dist/selfie.esm.js +9 -9
- package/dist/{selfieManager-CtS5wYEo.esm.js → selfieManager-DsoqRiV2.esm.js} +3 -3
- package/dist/{selfieStateMachine-CiMhj8YP.esm.js → selfieStateMachine-Czcb2so_.esm.js} +2 -2
- package/dist/session.esm.js +2 -2
- package/dist/{sessionInitializer-DfN3wUch.esm.js → sessionInitializer-DdIllyuV.esm.js} +2 -2
- package/dist/{setup-_SH3lJGQ.esm.js → setup-B27YJgm_.esm.js} +1 -1
- package/dist/trust-graph.d.ts +2 -2
- package/dist/video-selfie.d.ts +2 -2
- package/dist/video-selfie.esm.js +5 -5
- package/dist/wasm.esm.js +3 -3
- package/dist/workflow.d.ts +159 -159
- package/dist/workflow.esm.js +11 -11
- package/package.json +1 -1
- package/dist/BrowserStorageProvider-fZsibQTR.esm.js +0 -55
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
//#region ../infra/src/providers/browser/BrowserStorageProvider.ts
|
|
2
|
+
/**
|
|
3
|
+
* Resolves `localStorage`, or `null` when the host makes it unreachable.
|
|
4
|
+
*
|
|
5
|
+
* Two hostile shapes are handled:
|
|
6
|
+
*
|
|
7
|
+
* - the host **deleted the bare global** as a self-XSS mitigation
|
|
8
|
+
* (`delete window.localStorage`) — the identifier no longer resolves, so
|
|
9
|
+
* `typeof` is the only safe way to probe it
|
|
10
|
+
* - a webview **blocks** storage — reading the accessor throws `SecurityError`
|
|
11
|
+
*/
|
|
12
|
+
function resolveLocalStorage() {
|
|
13
|
+
try {
|
|
14
|
+
if (typeof localStorage === "undefined") return null;
|
|
15
|
+
return localStorage;
|
|
16
|
+
} catch {
|
|
17
|
+
return null;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Browser-based storage provider wrapping localStorage.
|
|
22
|
+
* Handles JSON serialization/deserialization automatically.
|
|
23
|
+
*
|
|
24
|
+
* Degrades silently when the host makes localStorage unreachable: reads return
|
|
25
|
+
* `null` and writes are no-ops. Deliberately quiet — hosts that harden against
|
|
26
|
+
* self-XSS by deleting the global would otherwise see a warning on every call.
|
|
27
|
+
*/
|
|
28
|
+
var BrowserStorageProvider = class {
|
|
29
|
+
/**
|
|
30
|
+
* Retrieves a value from localStorage.
|
|
31
|
+
* @param key - The storage key
|
|
32
|
+
* @returns The stored value, or null if not found or storage is unavailable
|
|
33
|
+
* @throws Error if stored value is invalid JSON
|
|
34
|
+
*/
|
|
35
|
+
async get(key) {
|
|
36
|
+
const storage = resolveLocalStorage();
|
|
37
|
+
if (!storage) return null;
|
|
38
|
+
try {
|
|
39
|
+
const item = storage.getItem(key);
|
|
40
|
+
if (item === null) return null;
|
|
41
|
+
return JSON.parse(item);
|
|
42
|
+
} catch (error) {
|
|
43
|
+
if (error instanceof SyntaxError) throw new Error(`Invalid JSON stored at key "${key}": ${error.message}`);
|
|
44
|
+
throw error;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Stores a value in localStorage. No-op when storage is unavailable.
|
|
49
|
+
* @param key - The storage key
|
|
50
|
+
* @param value - The value to store (will be serialized as JSON)
|
|
51
|
+
* @throws Error if value cannot be serialized or quota is exceeded
|
|
52
|
+
*/
|
|
53
|
+
async set(key, value) {
|
|
54
|
+
const storage = resolveLocalStorage();
|
|
55
|
+
if (!storage) return;
|
|
56
|
+
try {
|
|
57
|
+
const serialized = JSON.stringify(value);
|
|
58
|
+
storage.setItem(key, serialized);
|
|
59
|
+
} catch (error) {
|
|
60
|
+
if ((error instanceof DOMException || error.name === "QuotaExceededError") && error.name === "QuotaExceededError") throw new Error(`Storage quota exceeded for key "${key}"`);
|
|
61
|
+
if (error instanceof TypeError) throw new Error(`Failed to serialize value for key "${key}": ${error.message}`);
|
|
62
|
+
throw error;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Removes a value from localStorage. No-op when storage is unavailable.
|
|
67
|
+
* @param key - The storage key to remove
|
|
68
|
+
*/
|
|
69
|
+
async remove(key) {
|
|
70
|
+
const storage = resolveLocalStorage();
|
|
71
|
+
if (!storage) return;
|
|
72
|
+
storage.removeItem(key);
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Clears all values from localStorage. No-op when storage is unavailable.
|
|
76
|
+
*/
|
|
77
|
+
async clear() {
|
|
78
|
+
const storage = resolveLocalStorage();
|
|
79
|
+
if (!storage) return;
|
|
80
|
+
storage.clear();
|
|
81
|
+
}
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
//#endregion
|
|
85
|
+
export { BrowserStorageProvider as t };
|
package/dist/ae-signature.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./StateMachine-D5WO6lHS.js";
|
|
2
2
|
import { t as Manager } from "./Manager-goNPc_h_.js";
|
|
3
3
|
import "./Actor-BwgmOPkb.js";
|
|
4
|
-
import { a as AE_CONSENT_KEYS, c as ConsentKey, g as getDefaultConsentChecks, i as electronicSignatureMachine, l as ElectronicSignatureConfig, m as areAllConsented, n as ElectronicSignatureState, s as ConsentChecks, u as ElectronicSignatureDocument } from "./index-
|
|
4
|
+
import { a as AE_CONSENT_KEYS, c as ConsentKey, g as getDefaultConsentChecks, i as electronicSignatureMachine, l as ElectronicSignatureConfig, m as areAllConsented, n as ElectronicSignatureState, s as ConsentChecks, u as ElectronicSignatureDocument } from "./index-Dzf83PXV.js";
|
|
5
5
|
|
|
6
6
|
//#region src/modules/ae-signature/index.d.ts
|
|
7
7
|
|
|
@@ -3,33 +3,33 @@ import "./api-DsbUi7TO.esm.js";
|
|
|
3
3
|
import "./events-1wxZ97yf.esm.js";
|
|
4
4
|
import "./endpoints-CwrFQfW7.esm.js";
|
|
5
5
|
import "./stats-BVy52wLy.esm.js";
|
|
6
|
-
import "./browserSimulation-
|
|
6
|
+
import "./browserSimulation-DZwEy9bu.esm.js";
|
|
7
7
|
import "./platform-0Ot-bF_a.esm.js";
|
|
8
8
|
import "./getBrowser-1yNcfFZR.esm.js";
|
|
9
9
|
import "./xstate.esm-nY3M5UYm.esm.js";
|
|
10
|
-
import "./faceCaptureSetup-
|
|
10
|
+
import "./faceCaptureSetup-Gj6XnsY4.esm.js";
|
|
11
11
|
import "./wasmDsFlagSync-Ch0mFJNT.esm.js";
|
|
12
12
|
import "./BrowserVisibilityObserverProvider-GBS6XSii.esm.js";
|
|
13
13
|
import "./MotionSensorProvider-D95kOKVK.esm.js";
|
|
14
14
|
import "./permissionServices-BElIOcoJ.esm.js";
|
|
15
15
|
import "./camera-CxxXV0VN.esm.js";
|
|
16
|
-
import "./faceCaptureManagerFactory-
|
|
17
|
-
import "./BrowserStorageProvider-
|
|
18
|
-
import "./onDeviceFaceResults-
|
|
16
|
+
import "./faceCaptureManagerFactory-Cf8m_RNb.esm.js";
|
|
17
|
+
import "./BrowserStorageProvider-DaKI3I0m.esm.js";
|
|
18
|
+
import "./onDeviceFaceResults-BWxOJueW.esm.js";
|
|
19
19
|
import "./ITimerCapability-DJ73P4RK.esm.js";
|
|
20
20
|
import "./canvas-Pi10hG_l.esm.js";
|
|
21
21
|
import "./backCameraStream-ChrMTJv-.esm.js";
|
|
22
22
|
import "./video-ZY92rkel.esm.js";
|
|
23
23
|
import "./getDeviceClass-C-Dg6IsJ.esm.js";
|
|
24
|
-
import "./deepsightService-
|
|
24
|
+
import "./deepsightService-CViys6T4.esm.js";
|
|
25
25
|
import "./getDeviceClass-DIjnTPjR.esm.js";
|
|
26
26
|
import "./types-BKLb3C42.esm.js";
|
|
27
27
|
import "./createFaceAvatar-BZSg2MNo.esm.js";
|
|
28
28
|
import "./StreamCanvasCapture-CAqUdVkM.esm.js";
|
|
29
29
|
import "./permissionGuards-BPZGWaL4.esm.js";
|
|
30
|
-
import "./recordingService-
|
|
30
|
+
import "./recordingService-lBmeVE49.esm.js";
|
|
31
31
|
import "./mediaRecorderOptions-CClCKAiF.esm.js";
|
|
32
|
-
import { t as authenticationMachine } from "./authenticationStateMachine-
|
|
33
|
-
import { r as createAuthenticationActor, t as createAuthenticationManager } from "./authenticationManager-
|
|
32
|
+
import { t as authenticationMachine } from "./authenticationStateMachine-BBNa41d5.esm.js";
|
|
33
|
+
import { r as createAuthenticationActor, t as createAuthenticationManager } from "./authenticationManager-Dwf7TrZC.esm.js";
|
|
34
34
|
|
|
35
35
|
export { authenticationMachine, createAuthenticationActor, createAuthenticationManager };
|
package/dist/{authenticationManager-DuMSpelF.esm.js → authenticationManager-Dwf7TrZC.esm.js}
RENAMED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { t as WasmUtilProvider } from "./WasmUtilProvider-BgzcXBdl.esm.js";
|
|
2
2
|
import { n as eventModuleNames } from "./events-1wxZ97yf.esm.js";
|
|
3
3
|
import { s as createActor } from "./xstate.esm-nY3M5UYm.esm.js";
|
|
4
|
-
import { t as createFaceCaptureManagerFromActor } from "./faceCaptureManagerFactory-
|
|
5
|
-
import { t as BrowserStorageProvider } from "./BrowserStorageProvider-
|
|
6
|
-
import { t as authenticationMachine } from "./authenticationStateMachine-
|
|
4
|
+
import { t as createFaceCaptureManagerFromActor } from "./faceCaptureManagerFactory-Cf8m_RNb.esm.js";
|
|
5
|
+
import { t as BrowserStorageProvider } from "./BrowserStorageProvider-DaKI3I0m.esm.js";
|
|
6
|
+
import { t as authenticationMachine } from "./authenticationStateMachine-BBNa41d5.esm.js";
|
|
7
7
|
|
|
8
8
|
//#region src/modules/authentication/authenticationActor.ts
|
|
9
9
|
function createAuthenticationActor(options) {
|
|
@@ -2,8 +2,8 @@ import { t as api } from "./api-DsbUi7TO.esm.js";
|
|
|
2
2
|
import { t as endpoints } from "./endpoints-CwrFQfW7.esm.js";
|
|
3
3
|
import { t as addDeviceStats } from "./stats-BVy52wLy.esm.js";
|
|
4
4
|
import { a as fromPromise, r as assign } from "./xstate.esm-nY3M5UYm.esm.js";
|
|
5
|
-
import { t as faceCaptureMachine } from "./faceCaptureSetup-
|
|
6
|
-
import { i as prepareOnDeviceFaceUpload, n as isOnDeviceMode, r as postOnDeviceFaceResults, t as defaultPrepareFaceUpload } from "./onDeviceFaceResults-
|
|
5
|
+
import { t as faceCaptureMachine } from "./faceCaptureSetup-Gj6XnsY4.esm.js";
|
|
6
|
+
import { i as prepareOnDeviceFaceUpload, n as isOnDeviceMode, r as postOnDeviceFaceResults, t as defaultPrepareFaceUpload } from "./onDeviceFaceResults-BWxOJueW.esm.js";
|
|
7
7
|
import { t as getDeviceClass } from "./getDeviceClass-DIjnTPjR.esm.js";
|
|
8
8
|
import { t as FACE_ERROR_CODES } from "./types-BKLb3C42.esm.js";
|
|
9
9
|
|
|
@@ -2724,8 +2724,21 @@ var se = class {
|
|
|
2724
2724
|
* Adapter for @thumbmarkjs/thumbmarkjs. Single point of dependency so bundlers
|
|
2725
2725
|
* resolve it from infra's node_modules when building apps that depend on core → infra.
|
|
2726
2726
|
*/
|
|
2727
|
+
/**
|
|
2728
|
+
* `logging` must stay disabled. With it on (the upstream default) `getThumbmark()`
|
|
2729
|
+
* evaluates a bare, unguarded storage read:
|
|
2730
|
+
*
|
|
2731
|
+
* options.logging && !sessionStorage.getItem("_tmjs_l") && Math.random() < 1e-4
|
|
2732
|
+
*
|
|
2733
|
+
* Hosts that delete the bare global as a self-XSS mitigation (`delete
|
|
2734
|
+
* window.sessionStorage`) make that a `ReferenceError`, which would cost us the
|
|
2735
|
+
* device fingerprint. `logging: false` short-circuits the expression before the
|
|
2736
|
+
* read. It also stops upstream's 1-in-10 000 telemetry POST to
|
|
2737
|
+
* api.thumbmarkjs.com. Re-check this when bumping the dependency.
|
|
2738
|
+
*/
|
|
2739
|
+
const THUMBMARK_OPTIONS = { logging: false };
|
|
2727
2740
|
async function getThumbmarkId() {
|
|
2728
|
-
return (await new se().get()).thumbmark;
|
|
2741
|
+
return (await new se(THUMBMARK_OPTIONS).get()).thumbmark;
|
|
2729
2742
|
}
|
|
2730
2743
|
|
|
2731
2744
|
//#endregion
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./StateMachine-D5WO6lHS.js";
|
|
2
2
|
import { t as Manager } from "./Manager-goNPc_h_.js";
|
|
3
3
|
import "./Actor-BwgmOPkb.js";
|
|
4
|
-
import * as
|
|
4
|
+
import * as xstate656 from "xstate";
|
|
5
5
|
|
|
6
6
|
//#region src/modules/certificate-issuance/certificateIssuanceConstants.d.ts
|
|
7
7
|
declare const MIN_PASSWORD_LENGTH = 8;
|
|
@@ -40,7 +40,7 @@ type CertificateIssuanceContext = {
|
|
|
40
40
|
type CertificateIssuanceInput = {
|
|
41
41
|
config: CertificateIssuanceConfig;
|
|
42
42
|
};
|
|
43
|
-
declare const certificateIssuanceMachine:
|
|
43
|
+
declare const certificateIssuanceMachine: xstate656.StateMachine<CertificateIssuanceContext, {
|
|
44
44
|
type: "LOAD";
|
|
45
45
|
} | {
|
|
46
46
|
type: "PASSWORD_CHANGED";
|
|
@@ -54,28 +54,28 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
54
54
|
} | {
|
|
55
55
|
type: "FINISH";
|
|
56
56
|
}, {
|
|
57
|
-
[x: string]:
|
|
57
|
+
[x: string]: xstate656.ActorRefFromLogic<xstate656.PromiseActorLogic<IssueCertificateResponse, {
|
|
58
58
|
password: string;
|
|
59
|
-
},
|
|
59
|
+
}, xstate656.EventObject>> | undefined;
|
|
60
60
|
}, {
|
|
61
61
|
src: "issueCertificate";
|
|
62
|
-
logic:
|
|
62
|
+
logic: xstate656.PromiseActorLogic<IssueCertificateResponse, {
|
|
63
63
|
password: string;
|
|
64
|
-
},
|
|
64
|
+
}, xstate656.EventObject>;
|
|
65
65
|
id: string | undefined;
|
|
66
|
-
},
|
|
66
|
+
}, xstate656.Values<{
|
|
67
67
|
setPassword: {
|
|
68
68
|
type: "setPassword";
|
|
69
|
-
params:
|
|
69
|
+
params: xstate656.NonReducibleUnknown;
|
|
70
70
|
};
|
|
71
71
|
setBlob: {
|
|
72
72
|
type: "setBlob";
|
|
73
|
-
params:
|
|
73
|
+
params: xstate656.NonReducibleUnknown;
|
|
74
74
|
};
|
|
75
75
|
}>, {
|
|
76
76
|
type: "isPasswordValid";
|
|
77
77
|
params: unknown;
|
|
78
|
-
}, never, "error" | "idle" | "processing" | "success" | "finished" | "password" | "downloaded", string, CertificateIssuanceInput,
|
|
78
|
+
}, never, "error" | "idle" | "processing" | "success" | "finished" | "password" | "downloaded", string, CertificateIssuanceInput, xstate656.NonReducibleUnknown, xstate656.EventObject, xstate656.MetaObject, {
|
|
79
79
|
readonly id: "certificateIssuance";
|
|
80
80
|
readonly initial: "idle";
|
|
81
81
|
readonly context: ({
|
|
@@ -84,39 +84,39 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
84
84
|
spawn: {
|
|
85
85
|
<TSrc extends "issueCertificate">(logic: TSrc, ...[options]: {
|
|
86
86
|
src: "issueCertificate";
|
|
87
|
-
logic:
|
|
87
|
+
logic: xstate656.PromiseActorLogic<IssueCertificateResponse, {
|
|
88
88
|
password: string;
|
|
89
|
-
},
|
|
89
|
+
}, xstate656.EventObject>;
|
|
90
90
|
id: string | undefined;
|
|
91
91
|
} extends infer T ? T extends {
|
|
92
92
|
src: "issueCertificate";
|
|
93
|
-
logic:
|
|
93
|
+
logic: xstate656.PromiseActorLogic<IssueCertificateResponse, {
|
|
94
94
|
password: string;
|
|
95
|
-
},
|
|
95
|
+
}, xstate656.EventObject>;
|
|
96
96
|
id: string | undefined;
|
|
97
97
|
} ? T extends {
|
|
98
98
|
src: TSrc;
|
|
99
|
-
} ?
|
|
99
|
+
} ? xstate656.ConditionalRequired<[options?: ({
|
|
100
100
|
id?: T["id"] | undefined;
|
|
101
101
|
systemId?: string;
|
|
102
|
-
input?:
|
|
102
|
+
input?: xstate656.InputFrom<T["logic"]> | undefined;
|
|
103
103
|
syncSnapshot?: boolean;
|
|
104
|
-
} & { [K in
|
|
104
|
+
} & { [K in xstate656.RequiredActorOptions<T>]: unknown }) | undefined], xstate656.IsNotNever<xstate656.RequiredActorOptions<T>>> : never : never : never): xstate656.ActorRefFromLogic<xstate656.GetConcreteByKey<{
|
|
105
105
|
src: "issueCertificate";
|
|
106
|
-
logic:
|
|
106
|
+
logic: xstate656.PromiseActorLogic<IssueCertificateResponse, {
|
|
107
107
|
password: string;
|
|
108
|
-
},
|
|
108
|
+
}, xstate656.EventObject>;
|
|
109
109
|
id: string | undefined;
|
|
110
110
|
}, "src", TSrc>["logic"]>;
|
|
111
|
-
<TLogic extends
|
|
111
|
+
<TLogic extends xstate656.AnyActorLogic>(src: TLogic, ...[options]: xstate656.ConditionalRequired<[options?: ({
|
|
112
112
|
id?: never;
|
|
113
113
|
systemId?: string;
|
|
114
|
-
input?:
|
|
114
|
+
input?: xstate656.InputFrom<TLogic> | undefined;
|
|
115
115
|
syncSnapshot?: boolean;
|
|
116
|
-
} & { [K in
|
|
116
|
+
} & { [K in xstate656.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate656.IsNotNever<xstate656.RequiredLogicInput<TLogic>>>): xstate656.ActorRefFromLogic<TLogic>;
|
|
117
117
|
};
|
|
118
118
|
input: CertificateIssuanceInput;
|
|
119
|
-
self:
|
|
119
|
+
self: xstate656.ActorRef<xstate656.MachineSnapshot<CertificateIssuanceContext, {
|
|
120
120
|
type: "LOAD";
|
|
121
121
|
} | {
|
|
122
122
|
type: "PASSWORD_CHANGED";
|
|
@@ -129,7 +129,7 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
129
129
|
type: "DOWNLOAD_FAILED";
|
|
130
130
|
} | {
|
|
131
131
|
type: "FINISH";
|
|
132
|
-
}, Record<string,
|
|
132
|
+
}, Record<string, xstate656.AnyActorRef | undefined>, xstate656.StateValue, string, unknown, any, any>, {
|
|
133
133
|
type: "LOAD";
|
|
134
134
|
} | {
|
|
135
135
|
type: "PASSWORD_CHANGED";
|
|
@@ -142,7 +142,7 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
142
142
|
type: "DOWNLOAD_FAILED";
|
|
143
143
|
} | {
|
|
144
144
|
type: "FINISH";
|
|
145
|
-
},
|
|
145
|
+
}, xstate656.AnyEventObject>;
|
|
146
146
|
}) => {
|
|
147
147
|
config: CertificateIssuanceConfig;
|
|
148
148
|
password: string;
|
|
@@ -190,7 +190,7 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
190
190
|
} | {
|
|
191
191
|
type: "FINISH";
|
|
192
192
|
};
|
|
193
|
-
self:
|
|
193
|
+
self: xstate656.ActorRef<xstate656.MachineSnapshot<CertificateIssuanceContext, {
|
|
194
194
|
type: "LOAD";
|
|
195
195
|
} | {
|
|
196
196
|
type: "PASSWORD_CHANGED";
|
|
@@ -203,7 +203,7 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
203
203
|
type: "DOWNLOAD_FAILED";
|
|
204
204
|
} | {
|
|
205
205
|
type: "FINISH";
|
|
206
|
-
}, Record<string,
|
|
206
|
+
}, Record<string, xstate656.AnyActorRef>, xstate656.StateValue, string, unknown, any, any>, {
|
|
207
207
|
type: "LOAD";
|
|
208
208
|
} | {
|
|
209
209
|
type: "PASSWORD_CHANGED";
|
|
@@ -216,7 +216,7 @@ declare const certificateIssuanceMachine: xstate1095.StateMachine<CertificateIss
|
|
|
216
216
|
type: "DOWNLOAD_FAILED";
|
|
217
217
|
} | {
|
|
218
218
|
type: "FINISH";
|
|
219
|
-
},
|
|
219
|
+
}, xstate656.AnyEventObject>;
|
|
220
220
|
}) => {
|
|
221
221
|
password: string;
|
|
222
222
|
};
|
package/dist/consent.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./StateMachine-D5WO6lHS.js";
|
|
2
2
|
import "./Manager-goNPc_h_.js";
|
|
3
3
|
import "./Actor-BwgmOPkb.js";
|
|
4
|
-
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-
|
|
4
|
+
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-BvgtYr9W.js";
|
|
5
5
|
export { type ConsentActor, type ConsentCheckbox, type ConsentConfig, type ConsentManager, type ConsentState, consentMachine, createConsentManager, createConsentManagerFromActor };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as Manager } from "./Manager-goNPc_h_.js";
|
|
2
2
|
import { t as ActorRefFrom } from "./Actor-BwgmOPkb.js";
|
|
3
|
-
import * as
|
|
3
|
+
import * as xstate1516 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: xstate1516.StateMachine<ConsentContext, {
|
|
41
41
|
type: "LOAD";
|
|
42
42
|
} | {
|
|
43
43
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -49,55 +49,55 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
49
49
|
} | {
|
|
50
50
|
type: "RESET";
|
|
51
51
|
}, {
|
|
52
|
-
[x: string]:
|
|
52
|
+
[x: string]: xstate1516.ActorRefFromLogic<xstate1516.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
53
53
|
consentId: string;
|
|
54
54
|
language?: string;
|
|
55
|
-
},
|
|
55
|
+
}, xstate1516.EventObject>> | xstate1516.ActorRefFromLogic<xstate1516.PromiseActorLogic<void, {
|
|
56
56
|
languageConsentId: string;
|
|
57
57
|
checkboxes: ConsentCheckbox[];
|
|
58
|
-
},
|
|
59
|
-
},
|
|
58
|
+
}, xstate1516.EventObject>> | undefined;
|
|
59
|
+
}, xstate1516.Values<{
|
|
60
60
|
fetchConsent: {
|
|
61
61
|
src: "fetchConsent";
|
|
62
|
-
logic:
|
|
62
|
+
logic: xstate1516.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
63
63
|
consentId: string;
|
|
64
64
|
language?: string;
|
|
65
|
-
},
|
|
65
|
+
}, xstate1516.EventObject>;
|
|
66
66
|
id: string | undefined;
|
|
67
67
|
};
|
|
68
68
|
submitConsent: {
|
|
69
69
|
src: "submitConsent";
|
|
70
|
-
logic:
|
|
70
|
+
logic: xstate1516.PromiseActorLogic<void, {
|
|
71
71
|
languageConsentId: string;
|
|
72
72
|
checkboxes: ConsentCheckbox[];
|
|
73
|
-
},
|
|
73
|
+
}, xstate1516.EventObject>;
|
|
74
74
|
id: string | undefined;
|
|
75
75
|
};
|
|
76
|
-
}>,
|
|
76
|
+
}>, xstate1516.Values<{
|
|
77
77
|
setError: {
|
|
78
78
|
type: "setError";
|
|
79
|
-
params:
|
|
79
|
+
params: xstate1516.NonReducibleUnknown;
|
|
80
80
|
};
|
|
81
81
|
clearError: {
|
|
82
82
|
type: "clearError";
|
|
83
|
-
params:
|
|
83
|
+
params: xstate1516.NonReducibleUnknown;
|
|
84
|
+
};
|
|
85
|
+
resetContext: {
|
|
86
|
+
type: "resetContext";
|
|
87
|
+
params: xstate1516.NonReducibleUnknown;
|
|
84
88
|
};
|
|
85
89
|
setConsentData: {
|
|
86
90
|
type: "setConsentData";
|
|
87
|
-
params:
|
|
91
|
+
params: xstate1516.NonReducibleUnknown;
|
|
88
92
|
};
|
|
89
93
|
toggleCheckbox: {
|
|
90
94
|
type: "toggleCheckbox";
|
|
91
|
-
params:
|
|
92
|
-
};
|
|
93
|
-
resetContext: {
|
|
94
|
-
type: "resetContext";
|
|
95
|
-
params: xstate1027.NonReducibleUnknown;
|
|
95
|
+
params: xstate1516.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, xstate1516.NonReducibleUnknown, xstate1516.EventObject, xstate1516.MetaObject, {
|
|
101
101
|
readonly id: "consent";
|
|
102
102
|
readonly initial: "idle";
|
|
103
103
|
readonly context: ({
|
|
@@ -106,73 +106,73 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
106
106
|
spawn: {
|
|
107
107
|
<TSrc extends "fetchConsent" | "submitConsent">(logic: TSrc, ...[options]: ({
|
|
108
108
|
src: "fetchConsent";
|
|
109
|
-
logic:
|
|
109
|
+
logic: xstate1516.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
110
110
|
consentId: string;
|
|
111
111
|
language?: string;
|
|
112
|
-
},
|
|
112
|
+
}, xstate1516.EventObject>;
|
|
113
113
|
id: string | undefined;
|
|
114
114
|
} extends infer T ? T extends {
|
|
115
115
|
src: "fetchConsent";
|
|
116
|
-
logic:
|
|
116
|
+
logic: xstate1516.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
117
117
|
consentId: string;
|
|
118
118
|
language?: string;
|
|
119
|
-
},
|
|
119
|
+
}, xstate1516.EventObject>;
|
|
120
120
|
id: string | undefined;
|
|
121
121
|
} ? T extends {
|
|
122
122
|
src: TSrc;
|
|
123
|
-
} ?
|
|
123
|
+
} ? xstate1516.ConditionalRequired<[options?: ({
|
|
124
124
|
id?: T["id"] | undefined;
|
|
125
125
|
systemId?: string;
|
|
126
|
-
input?:
|
|
126
|
+
input?: xstate1516.InputFrom<T["logic"]> | undefined;
|
|
127
127
|
syncSnapshot?: boolean;
|
|
128
|
-
} & { [K in
|
|
128
|
+
} & { [K in xstate1516.RequiredActorOptions<T>]: unknown }) | undefined], xstate1516.IsNotNever<xstate1516.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
129
129
|
src: "submitConsent";
|
|
130
|
-
logic:
|
|
130
|
+
logic: xstate1516.PromiseActorLogic<void, {
|
|
131
131
|
languageConsentId: string;
|
|
132
132
|
checkboxes: ConsentCheckbox[];
|
|
133
|
-
},
|
|
133
|
+
}, xstate1516.EventObject>;
|
|
134
134
|
id: string | undefined;
|
|
135
135
|
} extends infer T_1 ? T_1 extends {
|
|
136
136
|
src: "submitConsent";
|
|
137
|
-
logic:
|
|
137
|
+
logic: xstate1516.PromiseActorLogic<void, {
|
|
138
138
|
languageConsentId: string;
|
|
139
139
|
checkboxes: ConsentCheckbox[];
|
|
140
|
-
},
|
|
140
|
+
}, xstate1516.EventObject>;
|
|
141
141
|
id: string | undefined;
|
|
142
142
|
} ? T_1 extends {
|
|
143
143
|
src: TSrc;
|
|
144
|
-
} ?
|
|
144
|
+
} ? xstate1516.ConditionalRequired<[options?: ({
|
|
145
145
|
id?: T_1["id"] | undefined;
|
|
146
146
|
systemId?: string;
|
|
147
|
-
input?:
|
|
147
|
+
input?: xstate1516.InputFrom<T_1["logic"]> | undefined;
|
|
148
148
|
syncSnapshot?: boolean;
|
|
149
|
-
} & { [K_1 in
|
|
149
|
+
} & { [K_1 in xstate1516.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate1516.IsNotNever<xstate1516.RequiredActorOptions<T_1>>> : never : never : never)): xstate1516.ActorRefFromLogic<xstate1516.GetConcreteByKey<xstate1516.Values<{
|
|
150
150
|
fetchConsent: {
|
|
151
151
|
src: "fetchConsent";
|
|
152
|
-
logic:
|
|
152
|
+
logic: xstate1516.PromiseActorLogic<FetchCombinedConsentResponse, {
|
|
153
153
|
consentId: string;
|
|
154
154
|
language?: string;
|
|
155
|
-
},
|
|
155
|
+
}, xstate1516.EventObject>;
|
|
156
156
|
id: string | undefined;
|
|
157
157
|
};
|
|
158
158
|
submitConsent: {
|
|
159
159
|
src: "submitConsent";
|
|
160
|
-
logic:
|
|
160
|
+
logic: xstate1516.PromiseActorLogic<void, {
|
|
161
161
|
languageConsentId: string;
|
|
162
162
|
checkboxes: ConsentCheckbox[];
|
|
163
|
-
},
|
|
163
|
+
}, xstate1516.EventObject>;
|
|
164
164
|
id: string | undefined;
|
|
165
165
|
};
|
|
166
166
|
}>, "src", TSrc>["logic"]>;
|
|
167
|
-
<TLogic extends
|
|
167
|
+
<TLogic extends xstate1516.AnyActorLogic>(src: TLogic, ...[options]: xstate1516.ConditionalRequired<[options?: ({
|
|
168
168
|
id?: never;
|
|
169
169
|
systemId?: string;
|
|
170
|
-
input?:
|
|
170
|
+
input?: xstate1516.InputFrom<TLogic> | undefined;
|
|
171
171
|
syncSnapshot?: boolean;
|
|
172
|
-
} & { [K in
|
|
172
|
+
} & { [K in xstate1516.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate1516.IsNotNever<xstate1516.RequiredLogicInput<TLogic>>>): xstate1516.ActorRefFromLogic<TLogic>;
|
|
173
173
|
};
|
|
174
174
|
input: ConsentInput;
|
|
175
|
-
self:
|
|
175
|
+
self: xstate1516.ActorRef<xstate1516.MachineSnapshot<ConsentContext, {
|
|
176
176
|
type: "LOAD";
|
|
177
177
|
} | {
|
|
178
178
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -183,7 +183,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
183
183
|
type: "RETRY";
|
|
184
184
|
} | {
|
|
185
185
|
type: "RESET";
|
|
186
|
-
}, Record<string,
|
|
186
|
+
}, Record<string, xstate1516.AnyActorRef | undefined>, xstate1516.StateValue, string, unknown, any, any>, {
|
|
187
187
|
type: "LOAD";
|
|
188
188
|
} | {
|
|
189
189
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -194,7 +194,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
194
194
|
type: "RETRY";
|
|
195
195
|
} | {
|
|
196
196
|
type: "RESET";
|
|
197
|
-
},
|
|
197
|
+
}, xstate1516.AnyEventObject>;
|
|
198
198
|
}) => {
|
|
199
199
|
config: ConsentConfig;
|
|
200
200
|
title: string;
|
|
@@ -232,7 +232,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
232
232
|
} | {
|
|
233
233
|
type: "RESET";
|
|
234
234
|
};
|
|
235
|
-
self:
|
|
235
|
+
self: xstate1516.ActorRef<xstate1516.MachineSnapshot<ConsentContext, {
|
|
236
236
|
type: "LOAD";
|
|
237
237
|
} | {
|
|
238
238
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -243,7 +243,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
243
243
|
type: "RETRY";
|
|
244
244
|
} | {
|
|
245
245
|
type: "RESET";
|
|
246
|
-
}, Record<string,
|
|
246
|
+
}, Record<string, xstate1516.AnyActorRef>, xstate1516.StateValue, string, unknown, any, any>, {
|
|
247
247
|
type: "LOAD";
|
|
248
248
|
} | {
|
|
249
249
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -254,7 +254,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
254
254
|
type: "RETRY";
|
|
255
255
|
} | {
|
|
256
256
|
type: "RESET";
|
|
257
|
-
},
|
|
257
|
+
}, xstate1516.AnyEventObject>;
|
|
258
258
|
}) => {
|
|
259
259
|
consentId: string;
|
|
260
260
|
language: string | undefined;
|
|
@@ -304,7 +304,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
304
304
|
} | {
|
|
305
305
|
type: "RESET";
|
|
306
306
|
};
|
|
307
|
-
self:
|
|
307
|
+
self: xstate1516.ActorRef<xstate1516.MachineSnapshot<ConsentContext, {
|
|
308
308
|
type: "LOAD";
|
|
309
309
|
} | {
|
|
310
310
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -315,7 +315,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
315
315
|
type: "RETRY";
|
|
316
316
|
} | {
|
|
317
317
|
type: "RESET";
|
|
318
|
-
}, Record<string,
|
|
318
|
+
}, Record<string, xstate1516.AnyActorRef>, xstate1516.StateValue, string, unknown, any, any>, {
|
|
319
319
|
type: "LOAD";
|
|
320
320
|
} | {
|
|
321
321
|
type: "TOGGLE_CHECKBOX";
|
|
@@ -326,7 +326,7 @@ declare const consentMachine: xstate1027.StateMachine<ConsentContext, {
|
|
|
326
326
|
type: "RETRY";
|
|
327
327
|
} | {
|
|
328
328
|
type: "RESET";
|
|
329
|
-
},
|
|
329
|
+
}, xstate1516.AnyEventObject>;
|
|
330
330
|
}) => {
|
|
331
331
|
languageConsentId: string;
|
|
332
332
|
checkboxes: ConsentCheckbox[];
|
package/dist/cpf-ocr.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./StateMachine-D5WO6lHS.js";
|
|
2
2
|
import "./Manager-goNPc_h_.js";
|
|
3
3
|
import "./Actor-BwgmOPkb.js";
|
|
4
|
-
import { a as CpfOcrActor, i as createCpfOcrManagerFromActor, n as CpfOcrState, o as cpfOcrMachine, r as createCpfOcrManager, t as CpfOcrManager } from "./cpfOcrManager-
|
|
4
|
+
import { a as CpfOcrActor, i as createCpfOcrManagerFromActor, n as CpfOcrState, o as cpfOcrMachine, r as createCpfOcrManager, t as CpfOcrManager } from "./cpfOcrManager-2eYelPF7.js";
|
|
5
5
|
|
|
6
6
|
//#region src/modules/cpf-ocr/cpfOcrUtils.d.ts
|
|
7
7
|
declare function formatCPF(value: string): string;
|