@incodetech/core 0.0.0-dev-20260702-cc2ced08 → 0.0.0-dev-20260702-a1566880
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/{3dAvatarProvider-3yqmC0fd.esm.js → 3dAvatarProvider-CVwSAzDw.esm.js} +1 -1
- package/dist/{Face2DProvider-C-fAuV-p.esm.js → Face2DProvider-BuWoUgFl.esm.js} +1 -1
- package/dist/{FaceDetectionProvider-B4SVWfK7.d.ts → FaceDetectionProvider-C723Vh4J.d.ts} +2 -2
- package/dist/{IWasmUtilCapability-Dpg64Qr2.d.ts → IWasmUtilCapability-DCe8akKn.d.ts} +2 -2
- package/dist/{OpenViduRecordingProvider-DmA__QfK.esm.js → OpenViduRecordingProvider-CK6A5kiU.esm.js} +1 -1
- package/dist/{StreamCanvasCapture-BqaiJxNa.d.ts → StreamCanvasCapture-DHDxv6hH.d.ts} +2 -2
- package/dist/ae-signature.d.ts +3 -3
- package/dist/antifraud.d.ts +3 -3
- package/dist/{antifraudManager-DcraYd6r.d.ts → antifraudManager-0tq22vID.d.ts} +2 -2
- package/dist/authentication.d.ts +18 -18
- package/dist/authentication.esm.js +7 -7
- package/dist/{authenticationManager-BVM5Czih.esm.js → authenticationManager-C3fe4lGI.esm.js} +2 -2
- package/dist/{authenticationManager-BwUutUMI.d.ts → authenticationManager-DYeRtXSb.d.ts} +3 -3
- package/dist/{authenticationStateMachine-BUb8hzFa.esm.js → authenticationStateMachine-CYois9xB.esm.js} +2 -2
- package/dist/avatar.d.ts +2 -2
- package/dist/avatar.esm.js +1 -1
- package/dist/camera.d.ts +1 -1
- package/dist/certificate-issuance.d.ts +30 -30
- package/dist/consent.d.ts +3 -3
- package/dist/{consentManager-BvDJp7BI.d.ts → consentManager-CMa6xRhY.d.ts} +49 -49
- package/dist/cpf-ocr.d.ts +3 -3
- package/dist/{cpfOcrManager-CLrn17Kf.d.ts → cpfOcrManager-D7VCqCRS.d.ts} +19 -19
- package/dist/{createFaceAvatar-CiNyvRNO.esm.js → createFaceAvatar-97WdPBmX.esm.js} +3 -3
- package/dist/{createFaceAvatar-tloe__L_.d.ts → createFaceAvatar-DNMSIcRb.d.ts} +1 -1
- package/dist/cross-document-data-match.d.ts +1 -1
- package/dist/curp-validation.d.ts +9 -9
- package/dist/{curpValidationManager-Bd_J27C3.d.ts → curpValidationManager-DcnaKhq7.d.ts} +3 -3
- package/dist/custom-fields.d.ts +2 -2
- package/dist/custom-watchlist.d.ts +1 -1
- package/dist/document-capture.d.ts +178 -178
- package/dist/document-upload.d.ts +50 -50
- package/dist/dynamic-forms.d.ts +2 -2
- package/dist/ekyb.d.ts +8 -8
- package/dist/ekyb.esm.js +4 -4
- package/dist/{ekybStateMachine-BzMz39iQ.esm.js → ekybStateMachine-DP7isX-i.esm.js} +1 -1
- package/dist/ekyc.d.ts +3 -3
- package/dist/electronic-signature.d.ts +3 -3
- package/dist/email.d.ts +4 -4
- package/dist/{emailManager-DB7-HTVr.d.ts → emailManager-D5kHN_Zj.d.ts} +3 -3
- package/dist/extensibility.d.ts +33 -32
- package/dist/extensibility.esm.js +18 -16
- package/dist/face-match.d.ts +1 -1
- package/dist/face-match.esm.js +1 -1
- package/dist/{faceCaptureManagerFactory-BbFl762r.esm.js → faceCaptureManagerFactory-D65wC0Oy.esm.js} +1 -1
- package/dist/{faceCaptureManagerFactory-CyZP_Q9V.d.ts → faceCaptureManagerFactory-D6uM60D6.d.ts} +12 -12
- package/dist/{faceCaptureSetup-CIkrBLYz.esm.js → faceCaptureSetup-DRgLc1RU.esm.js} +3 -3
- package/dist/field-comparison.d.ts +3 -3
- package/dist/{fieldComparisonManager-CjIY3Y1d.d.ts → fieldComparisonManager-brjMzIRO.d.ts} +2 -2
- package/dist/fiscal-qr.d.ts +4 -4
- package/dist/fiscal-qr.esm.js +1 -1
- package/dist/flow-events.d.ts +8 -8
- package/dist/flow.d.ts +13 -13
- package/dist/flow.esm.js +5 -5
- package/dist/{flowServices-DsAOXwDS.esm.js → flowServices-DhmBfwaK.esm.js} +1 -1
- package/dist/geolocation.d.ts +2 -2
- package/dist/geolocation.esm.js +1 -1
- package/dist/government-validation.d.ts +3 -3
- package/dist/government-validation.esm.js +1 -1
- package/dist/home.d.ts +17 -17
- package/dist/http.esm.js +1 -1
- package/dist/id-ocr.d.ts +3 -625
- package/dist/id-ocr.esm.js +5 -82
- package/dist/id-verification.d.ts +27 -27
- package/dist/id-verification.esm.js +1 -1
- package/dist/id.d.ts +15 -15
- package/dist/id.esm.js +7 -7
- package/dist/{idCaptureManager-TBCF4TGa.esm.js → idCaptureManager-C3WMK4_f.esm.js} +1 -1
- package/dist/{idCaptureManager-fvEYwU_l.d.ts → idCaptureManager-D9RZ93td.d.ts} +11 -11
- package/dist/{idCaptureStateMachine-K6LgInsG.esm.js → idCaptureStateMachine-Dr676DwS.esm.js} +5 -5
- package/dist/idOcrManager-D_RlFzxU.esm.js +92 -0
- package/dist/idOcrManager-DuKkC_F0.d.ts +641 -0
- package/dist/identity-reuse.d.ts +3 -3
- package/dist/{identityReuseManager-DHveeduR.d.ts → identityReuseManager-jK7-qoNl.d.ts} +33 -33
- package/dist/{index-CpQYJA2K.d.ts → index-Cd55zTCb.d.ts} +2 -2
- package/dist/{index-BR5R9zI_.d.ts → index-hyzrMFYW.d.ts} +169 -169
- package/dist/index.d.ts +3 -3
- package/dist/index.esm.js +3 -3
- package/dist/mandatory-consent.d.ts +9 -9
- package/dist/{mandatoryConsentManager-BMFzCwXR.d.ts → mandatoryConsentManager-sgRmypIp.d.ts} +53 -53
- package/dist/{onDeviceFaceResults-DlErdHcT.esm.js → onDeviceFaceResults-IJDRqtYI.esm.js} +2 -2
- package/dist/openviduLazy-jPgABwrt.esm.js +3 -0
- package/dist/{openviduLazy-BXDnVFe2.esm.js → openviduLazy-wEojM41w.esm.js} +1 -1
- package/dist/personhood.d.ts +15 -15
- package/dist/personhood.esm.js +1 -1
- package/dist/phone.d.ts +4 -4
- package/dist/{phoneManager-DWBrSRZq.d.ts → phoneManager-DPDc0FVX.d.ts} +3 -3
- package/dist/qe-signature.d.ts +3 -3
- package/dist/qe-signature.esm.js +1 -1
- package/dist/{recordingService-D8zRQbVb.esm.js → recordingService-4pOlb2SG.esm.js} +3 -3
- package/dist/redirect-to-mobile.d.ts +3 -3
- package/dist/redirect-to-mobile.esm.js +2 -2
- package/dist/{redirectToMobileManager-DIc_xDDn.esm.js → redirectToMobileManager-Be0DwbuH.esm.js} +1 -1
- package/dist/{redirectToMobileManager-slUK-Ttt.d.ts → redirectToMobileManager-f6wLXbkN.d.ts} +2 -2
- package/dist/selfie.d.ts +18 -18
- package/dist/selfie.esm.js +8 -8
- package/dist/{selfieManager-CjFFQTKK.esm.js → selfieManager-By-EP_q4.esm.js} +2 -2
- package/dist/{selfieManager-CARwc0rJ.d.ts → selfieManager-CQuIQApd.d.ts} +3 -3
- package/dist/{selfieStateMachine-2UJDOv3d.esm.js → selfieStateMachine-Dn3Vh_z_.esm.js} +2 -2
- package/dist/session.d.ts +7 -7
- package/dist/session.esm.js +3 -3
- package/dist/{sessionInitializer-C0YhqeiX.esm.js → sessionInitializer-COrA-YBy.esm.js} +2 -2
- package/dist/{setup-B0dyRJVg.d.ts → setup-Da51UnII.d.ts} +2 -2
- package/dist/{setup-3W6rhIxJ.esm.js → setup-q7YrDt0W.esm.js} +2 -2
- package/dist/signature.d.ts +2 -2
- package/dist/signature.esm.js +1 -1
- package/dist/{tri-D6YWLiyE.esm.js → tri-QAWxUCoY.esm.js} +1 -1
- package/dist/tri.d.ts +1 -1
- package/dist/{tri.esm-Q8X11Udu.esm.js → tri.esm-B47NPJjh.esm.js} +1 -1
- package/dist/tri.esm.js +1 -1
- package/dist/trust-graph.d.ts +3 -3
- package/dist/{types-B4nBoeCd.d.ts → types-BBSIY1G3.d.ts} +3 -3
- package/dist/{types-Bl8JJxqM.d.ts → types-B_YCuHZx.d.ts} +1 -1
- package/dist/{types-BoOrY6Kj.d.ts → types-Cyi3gwPK.d.ts} +2 -2
- package/dist/{types-DHIl-AtE.d.ts → types-DW6z_vgY.d.ts} +1 -1
- package/dist/video-selfie.d.ts +12 -12
- package/dist/video-selfie.esm.js +4 -4
- package/dist/wasm.d.ts +3 -3
- package/dist/wasm.esm.js +3 -3
- package/dist/watchlist-for-business.d.ts +1 -1
- package/dist/watchlist-for-business.esm.js +1 -1
- package/dist/watchlist.d.ts +1 -1
- package/dist/watchlist.esm.js +1 -1
- package/dist/workflow.d.ts +115 -115
- package/dist/workflow.esm.js +23 -23
- package/package.json +1 -1
- package/dist/openviduLazy-lAZzee_g.esm.js +0 -3
- /package/dist/{Actor-Du_LU0S4.d.ts → Actor-DYjXVMQm.d.ts} +0 -0
- /package/dist/{IVisibilityObserverCapability-D8EjWdOj.d.ts → IVisibilityObserverCapability-BxPj7hsu.d.ts} +0 -0
- /package/dist/{Manager-BUc6OqO5.d.ts → Manager-BylDhZIB.d.ts} +0 -0
- /package/dist/{PrivacyLensProvider-D3KyqFh7.esm.js → PrivacyLensProvider-CZnkF34Z.esm.js} +0 -0
- /package/dist/{browser-DlFgHpoC-D0saHs_w.esm.js → browser-DlFgHpoC-BieMg30k.esm.js} +0 -0
- /package/dist/{camera-DtXTDZWt.d.ts → camera-CWO06Lu5.d.ts} +0 -0
- /package/dist/{canvas-Dcq7XIdx.d.ts → canvas-pLrXU1id.d.ts} +0 -0
- /package/dist/{deepsightLoader-C2P7w1dA.esm.js → deepsightLoader-BrK1yV0-.esm.js} +0 -0
- /package/dist/{deepsightService-DMGqYUMO.d.ts → deepsightService-6J67NoN9.d.ts} +0 -0
- /package/dist/{faceMatchStateMachine-CDx5ZRhv.esm.js → faceMatchStateMachine-BLL5aQX6.esm.js} +0 -0
- /package/dist/{flowCompletionService-BqDrPtNh.esm.js → flowCompletionService-C4ciNLxe.esm.js} +0 -0
- /package/dist/{flowCompletionService-CY9Cb5V1.d.ts → flowCompletionService-DWsYur5b.d.ts} +0 -0
- /package/dist/{geolocationStateMachine-BYfOOOG0.esm.js → geolocationStateMachine-Vs5GfQ8l.esm.js} +0 -0
- /package/dist/{governmentValidationStateMachine-yCQaD7zl.esm.js → governmentValidationStateMachine-EKSIq4v9.esm.js} +0 -0
- /package/dist/{http-C6s60xSe.esm.js → http-CBbBcnBa.esm.js} +0 -0
- /package/dist/{idOcrStateMachine-6vUdYjRV.esm.js → idOcrStateMachine-DLz_gexF.esm.js} +0 -0
- /package/dist/{idVerificationStateMachine-cT7LtSYe.esm.js → idVerificationStateMachine-BOz1v4AY.esm.js} +0 -0
- /package/dist/{index-CCG6MnCO.d.ts → index-BAyZ8_iI.d.ts} +0 -0
- /package/dist/{invokeOnCaptureCallback-DrpXOwkG.esm.js → invokeOnCaptureCallback-uZ42DiUz.esm.js} +0 -0
- /package/dist/{lib-TRTXfron.esm.js → lib-Bjd6nOLG.esm.js} +0 -0
- /package/dist/{mediapipeShared-yKDdOf_V.esm.js → mediapipeShared-Bcmkzs3x.esm.js} +0 -0
- /package/dist/{otp-DyNGp0Po.d.ts → otp-DZSnImi6.d.ts} +0 -0
- /package/dist/{qe-signature-D5gwX-fY.esm.js → qe-signature-mU2bJh-u.esm.js} +0 -0
- /package/dist/{redirectToMobileStateMachine-H-iEztA6.esm.js → redirectToMobileStateMachine-DaZBdvQA.esm.js} +0 -0
- /package/dist/{runChildModule-Wr_2wB1m.esm.js → runChildModule-D-rDy5jB.esm.js} +0 -0
- /package/dist/{signatureStateMachine-c-HlL0-y.esm.js → signatureStateMachine-DWob8P45.esm.js} +0 -0
- /package/dist/{types-CYK29a4w.d.ts → types-BOiKESZY.d.ts} +0 -0
- /package/dist/{types-BXkFotpx.d.ts → types-CTnn7kUK.d.ts} +0 -0
- /package/dist/{warmup-DzJ0I4Kv.d.ts → warmup-CZ80odyW.d.ts} +0 -0
- /package/dist/{watchlistForBusinessStateMachine-DNaxGviI.esm.js → watchlistForBusinessStateMachine-Do3drRT5.esm.js} +0 -0
- /package/dist/{watchlistStateMachine-DPLVxv_x.esm.js → watchlistStateMachine-D6A4O5rK.esm.js} +0 -0
package/dist/id-ocr.d.ts
CHANGED
|
@@ -1,629 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./Actor-
|
|
3
|
-
import
|
|
1
|
+
import "./Manager-BylDhZIB.js";
|
|
2
|
+
import "./Actor-DYjXVMQm.js";
|
|
3
|
+
import { c as IdOcrConfig, d as UpdateOcrDataParams, f as ValidationRule, l as OcrData, n as IdOcrState, o as IdOcrOcrDocument, r as createIdOcrManager, s as idOcrStateMachine, t as IdOcrManager, u as OcrFieldConfig } from "./idOcrManager-DuKkC_F0.js";
|
|
4
4
|
|
|
5
|
-
//#region src/modules/id-ocr/types.d.ts
|
|
6
|
-
type IdOcrConfig = {
|
|
7
|
-
/** Allows user to edit OCR information @default false */
|
|
8
|
-
editableOcr?: boolean;
|
|
9
|
-
/**
|
|
10
|
-
* When true (from flow/onboarding), after the first ID OCR step completes the
|
|
11
|
-
* machine loads and optionally edits OCR for the second captured ID.
|
|
12
|
-
*/
|
|
13
|
-
secondId?: boolean;
|
|
14
|
-
/**
|
|
15
|
-
* Session flow id (injected by orchestrated flow UI). When listed in `CPFFlowIds`
|
|
16
|
-
* (`idOcrConsts`), only the CPF field is shown and validated; it maps to `documentNumber` on OCR.
|
|
17
|
-
*/
|
|
18
|
-
flowId?: string;
|
|
19
|
-
};
|
|
20
|
-
type NameBean = {
|
|
21
|
-
fullName?: string;
|
|
22
|
-
firstName?: string;
|
|
23
|
-
middleName?: string;
|
|
24
|
-
givenName?: string;
|
|
25
|
-
nameSuffix?: string;
|
|
26
|
-
paternalLastName?: string;
|
|
27
|
-
maternalLastName?: string;
|
|
28
|
-
lastNameMrz?: string;
|
|
29
|
-
};
|
|
30
|
-
type AddressBean = {
|
|
31
|
-
street?: string;
|
|
32
|
-
colony?: string;
|
|
33
|
-
postalCode?: string;
|
|
34
|
-
city?: string;
|
|
35
|
-
state?: string;
|
|
36
|
-
label?: string;
|
|
37
|
-
confidentGeolocation?: boolean;
|
|
38
|
-
};
|
|
39
|
-
type AddressStatements = {
|
|
40
|
-
_id: string;
|
|
41
|
-
dateType: string;
|
|
42
|
-
addressStatementTimestamp: number;
|
|
43
|
-
};
|
|
44
|
-
type OcrData = {
|
|
45
|
-
name: NameBean;
|
|
46
|
-
givenName?: string;
|
|
47
|
-
firstName?: string;
|
|
48
|
-
middleName?: string;
|
|
49
|
-
nameSuffix?: string;
|
|
50
|
-
mothersSurname?: string;
|
|
51
|
-
fathersSurname?: string;
|
|
52
|
-
nickName?: string;
|
|
53
|
-
address?: string;
|
|
54
|
-
street?: string;
|
|
55
|
-
colony?: string;
|
|
56
|
-
postalCode?: string;
|
|
57
|
-
city?: string;
|
|
58
|
-
state?: string;
|
|
59
|
-
stateCode?: string;
|
|
60
|
-
countryCode?: string;
|
|
61
|
-
addressFields?: AddressBean;
|
|
62
|
-
fullAddress?: boolean;
|
|
63
|
-
invalidAddress?: boolean;
|
|
64
|
-
checkedAddress?: string;
|
|
65
|
-
checkedAddressBean?: AddressBean;
|
|
66
|
-
exteriorNumber?: string;
|
|
67
|
-
interiorNumber?: string;
|
|
68
|
-
addressFromStatement?: string;
|
|
69
|
-
addressFieldsFromStatement?: AddressBean;
|
|
70
|
-
invalidAddressFromStatement?: boolean;
|
|
71
|
-
addressStatementEmissionDate?: number;
|
|
72
|
-
documentType?: string;
|
|
73
|
-
addressStatementTimestamps?: AddressStatements[];
|
|
74
|
-
poaName?: string;
|
|
75
|
-
typeOfId?: string;
|
|
76
|
-
documentFrontSubtype?: string;
|
|
77
|
-
documentBackSubtype?: string;
|
|
78
|
-
birthDate?: number | string;
|
|
79
|
-
gender?: string;
|
|
80
|
-
claveDeElector?: string;
|
|
81
|
-
curp?: string;
|
|
82
|
-
numeroEmisionCredencial?: string;
|
|
83
|
-
cic?: string;
|
|
84
|
-
ocr?: string;
|
|
85
|
-
documentNumber?: string;
|
|
86
|
-
personalNumber?: string;
|
|
87
|
-
refNumber?: string;
|
|
88
|
-
nue?: string;
|
|
89
|
-
externalId?: string;
|
|
90
|
-
issuedAt?: string;
|
|
91
|
-
expireAt?: string;
|
|
92
|
-
expirationDate?: number;
|
|
93
|
-
issueDate?: number;
|
|
94
|
-
registrationDate?: number;
|
|
95
|
-
issuingCountry?: string;
|
|
96
|
-
issuingState?: string;
|
|
97
|
-
birthPlace?: string;
|
|
98
|
-
issuingAuthority?: string;
|
|
99
|
-
height?: string;
|
|
100
|
-
weight?: string;
|
|
101
|
-
eyeColor?: string;
|
|
102
|
-
hairColor?: string;
|
|
103
|
-
bloodType?: string;
|
|
104
|
-
maritalStatus?: string;
|
|
105
|
-
nationality?: string;
|
|
106
|
-
nationalityMrz?: string;
|
|
107
|
-
classes?: string;
|
|
108
|
-
cond?: string;
|
|
109
|
-
mentions?: string;
|
|
110
|
-
restrictions?: string;
|
|
111
|
-
mrz1?: string;
|
|
112
|
-
mrz2?: string;
|
|
113
|
-
mrz3?: string;
|
|
114
|
-
fullNameMrz?: string;
|
|
115
|
-
documentNumberCheckDigit?: string;
|
|
116
|
-
dateOfBirthCheckDigit?: string;
|
|
117
|
-
expirationDateCheckDigit?: string;
|
|
118
|
-
fathersName?: string;
|
|
119
|
-
mothersName?: string;
|
|
120
|
-
federalRevenueNumber?: string;
|
|
121
|
-
originDocumentId?: string;
|
|
122
|
-
driversLicenseCategory?: string;
|
|
123
|
-
controlNumber?: string;
|
|
124
|
-
renach?: string;
|
|
125
|
-
ocrReliabilityConfidence?: number;
|
|
126
|
-
ocrDataConfidence?: unknown;
|
|
127
|
-
};
|
|
128
|
-
type UpdateOcrDataParams = {
|
|
129
|
-
address?: string;
|
|
130
|
-
documentNumber?: string;
|
|
131
|
-
name?: string;
|
|
132
|
-
firstName?: string;
|
|
133
|
-
lastName?: string;
|
|
134
|
-
paternalLastName?: string;
|
|
135
|
-
maternalLastName?: string;
|
|
136
|
-
personalNumber?: string;
|
|
137
|
-
curp?: string;
|
|
138
|
-
email?: string;
|
|
139
|
-
birthDate?: string;
|
|
140
|
-
expireAt?: string;
|
|
141
|
-
gender?: string;
|
|
142
|
-
issuingCountry?: string;
|
|
143
|
-
};
|
|
144
|
-
type ValidationRule = {
|
|
145
|
-
type: 'required';
|
|
146
|
-
} | {
|
|
147
|
-
type: 'minAge';
|
|
148
|
-
years: number;
|
|
149
|
-
} | {
|
|
150
|
-
type: 'cpf';
|
|
151
|
-
};
|
|
152
|
-
type OcrFieldConfig = {
|
|
153
|
-
key: keyof UpdateOcrDataParams;
|
|
154
|
-
labelKey: string;
|
|
155
|
-
type: 'text' | 'date' | 'radio';
|
|
156
|
-
options?: {
|
|
157
|
-
label: string;
|
|
158
|
-
value: string;
|
|
159
|
-
}[];
|
|
160
|
-
validation?: ValidationRule[];
|
|
161
|
-
required: boolean;
|
|
162
|
-
};
|
|
163
|
-
type UpdateOcrResponse = {
|
|
164
|
-
success: boolean;
|
|
165
|
-
};
|
|
166
|
-
//#endregion
|
|
167
|
-
//#region src/modules/id-ocr/idOcrStateMachine.d.ts
|
|
168
|
-
type IdOcrOcrDocument = 'first' | 'second';
|
|
169
|
-
type IdOcrContext = {
|
|
170
|
-
config: IdOcrConfig;
|
|
171
|
-
error?: string;
|
|
172
|
-
formData: UpdateOcrDataParams;
|
|
173
|
-
editedFields: UpdateOcrDataParams;
|
|
174
|
-
activeOcrDocument: IdOcrOcrDocument;
|
|
175
|
-
validationErrors?: Partial<Record<keyof UpdateOcrDataParams, string>>;
|
|
176
|
-
};
|
|
177
|
-
type IdOcrInput = {
|
|
178
|
-
config: IdOcrConfig;
|
|
179
|
-
};
|
|
180
|
-
declare const idOcrStateMachine: xstate1443.StateMachine<IdOcrContext, {
|
|
181
|
-
type: "LOAD";
|
|
182
|
-
} | {
|
|
183
|
-
type: "DATA_CHANGED";
|
|
184
|
-
field: keyof UpdateOcrDataParams;
|
|
185
|
-
value: string;
|
|
186
|
-
} | {
|
|
187
|
-
type: "VALIDATE_FIELD";
|
|
188
|
-
field: keyof UpdateOcrDataParams;
|
|
189
|
-
} | {
|
|
190
|
-
type: "CONTINUE";
|
|
191
|
-
} | {
|
|
192
|
-
type: "RETRY";
|
|
193
|
-
}, {
|
|
194
|
-
[x: string]: xstate1443.ActorRefFromLogic<xstate1443.PromiseActorLogic<OcrData, {
|
|
195
|
-
isSecondId: boolean;
|
|
196
|
-
}, xstate1443.EventObject>> | xstate1443.ActorRefFromLogic<xstate1443.PromiseActorLogic<UpdateOcrResponse, {
|
|
197
|
-
params: UpdateOcrDataParams;
|
|
198
|
-
isSecondId: boolean;
|
|
199
|
-
}, xstate1443.EventObject>> | undefined;
|
|
200
|
-
}, xstate1443.Values<{
|
|
201
|
-
getOcrData: {
|
|
202
|
-
src: "getOcrData";
|
|
203
|
-
logic: xstate1443.PromiseActorLogic<OcrData, {
|
|
204
|
-
isSecondId: boolean;
|
|
205
|
-
}, xstate1443.EventObject>;
|
|
206
|
-
id: string | undefined;
|
|
207
|
-
};
|
|
208
|
-
updateOcrData: {
|
|
209
|
-
src: "updateOcrData";
|
|
210
|
-
logic: xstate1443.PromiseActorLogic<UpdateOcrResponse, {
|
|
211
|
-
params: UpdateOcrDataParams;
|
|
212
|
-
isSecondId: boolean;
|
|
213
|
-
}, xstate1443.EventObject>;
|
|
214
|
-
id: string | undefined;
|
|
215
|
-
};
|
|
216
|
-
}>, xstate1443.Values<{
|
|
217
|
-
setError: {
|
|
218
|
-
type: "setError";
|
|
219
|
-
params: xstate1443.NonReducibleUnknown;
|
|
220
|
-
};
|
|
221
|
-
setInitialData: {
|
|
222
|
-
type: "setInitialData";
|
|
223
|
-
params: xstate1443.NonReducibleUnknown;
|
|
224
|
-
};
|
|
225
|
-
updateField: {
|
|
226
|
-
type: "updateField";
|
|
227
|
-
params: xstate1443.NonReducibleUnknown;
|
|
228
|
-
};
|
|
229
|
-
clearFieldValidationError: {
|
|
230
|
-
type: "clearFieldValidationError";
|
|
231
|
-
params: xstate1443.NonReducibleUnknown;
|
|
232
|
-
};
|
|
233
|
-
setOcrValidationErrors: {
|
|
234
|
-
type: "setOcrValidationErrors";
|
|
235
|
-
params: xstate1443.NonReducibleUnknown;
|
|
236
|
-
};
|
|
237
|
-
validateFormField: {
|
|
238
|
-
type: "validateFormField";
|
|
239
|
-
params: xstate1443.NonReducibleUnknown;
|
|
240
|
-
};
|
|
241
|
-
beginSecondIdOcrPhase: {
|
|
242
|
-
type: "beginSecondIdOcrPhase";
|
|
243
|
-
params: xstate1443.NonReducibleUnknown;
|
|
244
|
-
};
|
|
245
|
-
resetForRetry: {
|
|
246
|
-
type: "resetForRetry";
|
|
247
|
-
params: xstate1443.NonReducibleUnknown;
|
|
248
|
-
};
|
|
249
|
-
computeValidationResult: {
|
|
250
|
-
type: "computeValidationResult";
|
|
251
|
-
params: xstate1443.NonReducibleUnknown;
|
|
252
|
-
};
|
|
253
|
-
}>, xstate1443.Values<{
|
|
254
|
-
isOcrEditable: {
|
|
255
|
-
type: "isOcrEditable";
|
|
256
|
-
params: unknown;
|
|
257
|
-
};
|
|
258
|
-
shouldLoadSecondOcrAfterFirst: {
|
|
259
|
-
type: "shouldLoadSecondOcrAfterFirst";
|
|
260
|
-
params: unknown;
|
|
261
|
-
};
|
|
262
|
-
isOcrFormValid: {
|
|
263
|
-
type: "isOcrFormValid";
|
|
264
|
-
params: unknown;
|
|
265
|
-
};
|
|
266
|
-
shouldSubmit: {
|
|
267
|
-
type: "shouldSubmit";
|
|
268
|
-
params: unknown;
|
|
269
|
-
};
|
|
270
|
-
shouldProceedWithoutSubmitToSecondId: {
|
|
271
|
-
type: "shouldProceedWithoutSubmitToSecondId";
|
|
272
|
-
params: unknown;
|
|
273
|
-
};
|
|
274
|
-
}>, never, "error" | "idle" | "success" | "finished" | "loading" | "inputting" | "submitting" | "readonly" | "validatingContinue", string, IdOcrInput, xstate1443.NonReducibleUnknown, xstate1443.EventObject, xstate1443.MetaObject, {
|
|
275
|
-
readonly id: "idOcr";
|
|
276
|
-
readonly initial: "idle";
|
|
277
|
-
readonly context: ({
|
|
278
|
-
input
|
|
279
|
-
}: {
|
|
280
|
-
spawn: {
|
|
281
|
-
<TSrc extends "getOcrData" | "updateOcrData">(logic: TSrc, ...[options]: ({
|
|
282
|
-
src: "getOcrData";
|
|
283
|
-
logic: xstate1443.PromiseActorLogic<OcrData, {
|
|
284
|
-
isSecondId: boolean;
|
|
285
|
-
}, xstate1443.EventObject>;
|
|
286
|
-
id: string | undefined;
|
|
287
|
-
} extends infer T ? T extends {
|
|
288
|
-
src: "getOcrData";
|
|
289
|
-
logic: xstate1443.PromiseActorLogic<OcrData, {
|
|
290
|
-
isSecondId: boolean;
|
|
291
|
-
}, xstate1443.EventObject>;
|
|
292
|
-
id: string | undefined;
|
|
293
|
-
} ? T extends {
|
|
294
|
-
src: TSrc;
|
|
295
|
-
} ? xstate1443.ConditionalRequired<[options?: ({
|
|
296
|
-
id?: T["id"] | undefined;
|
|
297
|
-
systemId?: string;
|
|
298
|
-
input?: xstate1443.InputFrom<T["logic"]> | undefined;
|
|
299
|
-
syncSnapshot?: boolean;
|
|
300
|
-
} & { [K in xstate1443.RequiredActorOptions<T>]: unknown }) | undefined], xstate1443.IsNotNever<xstate1443.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
301
|
-
src: "updateOcrData";
|
|
302
|
-
logic: xstate1443.PromiseActorLogic<UpdateOcrResponse, {
|
|
303
|
-
params: UpdateOcrDataParams;
|
|
304
|
-
isSecondId: boolean;
|
|
305
|
-
}, xstate1443.EventObject>;
|
|
306
|
-
id: string | undefined;
|
|
307
|
-
} extends infer T_1 ? T_1 extends {
|
|
308
|
-
src: "updateOcrData";
|
|
309
|
-
logic: xstate1443.PromiseActorLogic<UpdateOcrResponse, {
|
|
310
|
-
params: UpdateOcrDataParams;
|
|
311
|
-
isSecondId: boolean;
|
|
312
|
-
}, xstate1443.EventObject>;
|
|
313
|
-
id: string | undefined;
|
|
314
|
-
} ? T_1 extends {
|
|
315
|
-
src: TSrc;
|
|
316
|
-
} ? xstate1443.ConditionalRequired<[options?: ({
|
|
317
|
-
id?: T_1["id"] | undefined;
|
|
318
|
-
systemId?: string;
|
|
319
|
-
input?: xstate1443.InputFrom<T_1["logic"]> | undefined;
|
|
320
|
-
syncSnapshot?: boolean;
|
|
321
|
-
} & { [K_1 in xstate1443.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate1443.IsNotNever<xstate1443.RequiredActorOptions<T_1>>> : never : never : never)): xstate1443.ActorRefFromLogic<xstate1443.GetConcreteByKey<xstate1443.Values<{
|
|
322
|
-
getOcrData: {
|
|
323
|
-
src: "getOcrData";
|
|
324
|
-
logic: xstate1443.PromiseActorLogic<OcrData, {
|
|
325
|
-
isSecondId: boolean;
|
|
326
|
-
}, xstate1443.EventObject>;
|
|
327
|
-
id: string | undefined;
|
|
328
|
-
};
|
|
329
|
-
updateOcrData: {
|
|
330
|
-
src: "updateOcrData";
|
|
331
|
-
logic: xstate1443.PromiseActorLogic<UpdateOcrResponse, {
|
|
332
|
-
params: UpdateOcrDataParams;
|
|
333
|
-
isSecondId: boolean;
|
|
334
|
-
}, xstate1443.EventObject>;
|
|
335
|
-
id: string | undefined;
|
|
336
|
-
};
|
|
337
|
-
}>, "src", TSrc>["logic"]>;
|
|
338
|
-
<TLogic extends xstate1443.AnyActorLogic>(src: TLogic, ...[options]: xstate1443.ConditionalRequired<[options?: ({
|
|
339
|
-
id?: never;
|
|
340
|
-
systemId?: string;
|
|
341
|
-
input?: xstate1443.InputFrom<TLogic> | undefined;
|
|
342
|
-
syncSnapshot?: boolean;
|
|
343
|
-
} & { [K in xstate1443.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate1443.IsNotNever<xstate1443.RequiredLogicInput<TLogic>>>): xstate1443.ActorRefFromLogic<TLogic>;
|
|
344
|
-
};
|
|
345
|
-
input: IdOcrInput;
|
|
346
|
-
self: xstate1443.ActorRef<xstate1443.MachineSnapshot<IdOcrContext, {
|
|
347
|
-
type: "LOAD";
|
|
348
|
-
} | {
|
|
349
|
-
type: "DATA_CHANGED";
|
|
350
|
-
field: keyof UpdateOcrDataParams;
|
|
351
|
-
value: string;
|
|
352
|
-
} | {
|
|
353
|
-
type: "VALIDATE_FIELD";
|
|
354
|
-
field: keyof UpdateOcrDataParams;
|
|
355
|
-
} | {
|
|
356
|
-
type: "CONTINUE";
|
|
357
|
-
} | {
|
|
358
|
-
type: "RETRY";
|
|
359
|
-
}, Record<string, xstate1443.AnyActorRef | undefined>, xstate1443.StateValue, string, unknown, any, any>, {
|
|
360
|
-
type: "LOAD";
|
|
361
|
-
} | {
|
|
362
|
-
type: "DATA_CHANGED";
|
|
363
|
-
field: keyof UpdateOcrDataParams;
|
|
364
|
-
value: string;
|
|
365
|
-
} | {
|
|
366
|
-
type: "VALIDATE_FIELD";
|
|
367
|
-
field: keyof UpdateOcrDataParams;
|
|
368
|
-
} | {
|
|
369
|
-
type: "CONTINUE";
|
|
370
|
-
} | {
|
|
371
|
-
type: "RETRY";
|
|
372
|
-
}, xstate1443.AnyEventObject>;
|
|
373
|
-
}) => {
|
|
374
|
-
config: IdOcrConfig;
|
|
375
|
-
formData: UpdateOcrDataParams;
|
|
376
|
-
editedFields: {};
|
|
377
|
-
activeOcrDocument: IdOcrOcrDocument;
|
|
378
|
-
};
|
|
379
|
-
readonly states: {
|
|
380
|
-
readonly idle: {
|
|
381
|
-
readonly on: {
|
|
382
|
-
readonly LOAD: readonly [{
|
|
383
|
-
readonly target: "loading";
|
|
384
|
-
}];
|
|
385
|
-
};
|
|
386
|
-
};
|
|
387
|
-
readonly loading: {
|
|
388
|
-
readonly invoke: {
|
|
389
|
-
readonly src: "getOcrData";
|
|
390
|
-
readonly input: ({
|
|
391
|
-
context
|
|
392
|
-
}: {
|
|
393
|
-
context: IdOcrContext;
|
|
394
|
-
event: {
|
|
395
|
-
type: "LOAD";
|
|
396
|
-
} | {
|
|
397
|
-
type: "DATA_CHANGED";
|
|
398
|
-
field: keyof UpdateOcrDataParams;
|
|
399
|
-
value: string;
|
|
400
|
-
} | {
|
|
401
|
-
type: "VALIDATE_FIELD";
|
|
402
|
-
field: keyof UpdateOcrDataParams;
|
|
403
|
-
} | {
|
|
404
|
-
type: "CONTINUE";
|
|
405
|
-
} | {
|
|
406
|
-
type: "RETRY";
|
|
407
|
-
};
|
|
408
|
-
self: xstate1443.ActorRef<xstate1443.MachineSnapshot<IdOcrContext, {
|
|
409
|
-
type: "LOAD";
|
|
410
|
-
} | {
|
|
411
|
-
type: "DATA_CHANGED";
|
|
412
|
-
field: keyof UpdateOcrDataParams;
|
|
413
|
-
value: string;
|
|
414
|
-
} | {
|
|
415
|
-
type: "VALIDATE_FIELD";
|
|
416
|
-
field: keyof UpdateOcrDataParams;
|
|
417
|
-
} | {
|
|
418
|
-
type: "CONTINUE";
|
|
419
|
-
} | {
|
|
420
|
-
type: "RETRY";
|
|
421
|
-
}, Record<string, xstate1443.AnyActorRef>, xstate1443.StateValue, string, unknown, any, any>, {
|
|
422
|
-
type: "LOAD";
|
|
423
|
-
} | {
|
|
424
|
-
type: "DATA_CHANGED";
|
|
425
|
-
field: keyof UpdateOcrDataParams;
|
|
426
|
-
value: string;
|
|
427
|
-
} | {
|
|
428
|
-
type: "VALIDATE_FIELD";
|
|
429
|
-
field: keyof UpdateOcrDataParams;
|
|
430
|
-
} | {
|
|
431
|
-
type: "CONTINUE";
|
|
432
|
-
} | {
|
|
433
|
-
type: "RETRY";
|
|
434
|
-
}, xstate1443.AnyEventObject>;
|
|
435
|
-
}) => {
|
|
436
|
-
isSecondId: boolean;
|
|
437
|
-
};
|
|
438
|
-
readonly onDone: readonly [{
|
|
439
|
-
readonly target: "inputting";
|
|
440
|
-
readonly guard: "isOcrEditable";
|
|
441
|
-
readonly actions: "setInitialData";
|
|
442
|
-
}, {
|
|
443
|
-
readonly target: "readonly";
|
|
444
|
-
readonly actions: "setInitialData";
|
|
445
|
-
}];
|
|
446
|
-
readonly onError: {
|
|
447
|
-
readonly target: "error";
|
|
448
|
-
readonly actions: "setError";
|
|
449
|
-
};
|
|
450
|
-
};
|
|
451
|
-
};
|
|
452
|
-
readonly readonly: {
|
|
453
|
-
readonly on: {
|
|
454
|
-
readonly CONTINUE: readonly [{
|
|
455
|
-
readonly target: "loading";
|
|
456
|
-
readonly guard: "shouldLoadSecondOcrAfterFirst";
|
|
457
|
-
readonly actions: "beginSecondIdOcrPhase";
|
|
458
|
-
}, {
|
|
459
|
-
readonly target: "success";
|
|
460
|
-
}];
|
|
461
|
-
};
|
|
462
|
-
};
|
|
463
|
-
readonly inputting: {
|
|
464
|
-
readonly on: {
|
|
465
|
-
readonly DATA_CHANGED: {
|
|
466
|
-
readonly actions: readonly ["updateField", "clearFieldValidationError"];
|
|
467
|
-
};
|
|
468
|
-
readonly VALIDATE_FIELD: {
|
|
469
|
-
readonly actions: "validateFormField";
|
|
470
|
-
};
|
|
471
|
-
readonly CONTINUE: {
|
|
472
|
-
readonly target: "validatingContinue";
|
|
473
|
-
};
|
|
474
|
-
};
|
|
475
|
-
};
|
|
476
|
-
readonly validatingContinue: {
|
|
477
|
-
readonly entry: "computeValidationResult";
|
|
478
|
-
readonly always: readonly [{
|
|
479
|
-
readonly guard: "shouldSubmit";
|
|
480
|
-
readonly target: "submitting";
|
|
481
|
-
}, {
|
|
482
|
-
readonly guard: "shouldProceedWithoutSubmitToSecondId";
|
|
483
|
-
readonly target: "loading";
|
|
484
|
-
readonly actions: "beginSecondIdOcrPhase";
|
|
485
|
-
}, {
|
|
486
|
-
readonly guard: "isOcrFormValid";
|
|
487
|
-
readonly target: "success";
|
|
488
|
-
}, {
|
|
489
|
-
readonly target: "inputting";
|
|
490
|
-
}];
|
|
491
|
-
};
|
|
492
|
-
readonly submitting: {
|
|
493
|
-
readonly invoke: {
|
|
494
|
-
readonly src: "updateOcrData";
|
|
495
|
-
readonly input: ({
|
|
496
|
-
context
|
|
497
|
-
}: {
|
|
498
|
-
context: IdOcrContext;
|
|
499
|
-
event: {
|
|
500
|
-
type: "LOAD";
|
|
501
|
-
} | {
|
|
502
|
-
type: "DATA_CHANGED";
|
|
503
|
-
field: keyof UpdateOcrDataParams;
|
|
504
|
-
value: string;
|
|
505
|
-
} | {
|
|
506
|
-
type: "VALIDATE_FIELD";
|
|
507
|
-
field: keyof UpdateOcrDataParams;
|
|
508
|
-
} | {
|
|
509
|
-
type: "CONTINUE";
|
|
510
|
-
} | {
|
|
511
|
-
type: "RETRY";
|
|
512
|
-
};
|
|
513
|
-
self: xstate1443.ActorRef<xstate1443.MachineSnapshot<IdOcrContext, {
|
|
514
|
-
type: "LOAD";
|
|
515
|
-
} | {
|
|
516
|
-
type: "DATA_CHANGED";
|
|
517
|
-
field: keyof UpdateOcrDataParams;
|
|
518
|
-
value: string;
|
|
519
|
-
} | {
|
|
520
|
-
type: "VALIDATE_FIELD";
|
|
521
|
-
field: keyof UpdateOcrDataParams;
|
|
522
|
-
} | {
|
|
523
|
-
type: "CONTINUE";
|
|
524
|
-
} | {
|
|
525
|
-
type: "RETRY";
|
|
526
|
-
}, Record<string, xstate1443.AnyActorRef>, xstate1443.StateValue, string, unknown, any, any>, {
|
|
527
|
-
type: "LOAD";
|
|
528
|
-
} | {
|
|
529
|
-
type: "DATA_CHANGED";
|
|
530
|
-
field: keyof UpdateOcrDataParams;
|
|
531
|
-
value: string;
|
|
532
|
-
} | {
|
|
533
|
-
type: "VALIDATE_FIELD";
|
|
534
|
-
field: keyof UpdateOcrDataParams;
|
|
535
|
-
} | {
|
|
536
|
-
type: "CONTINUE";
|
|
537
|
-
} | {
|
|
538
|
-
type: "RETRY";
|
|
539
|
-
}, xstate1443.AnyEventObject>;
|
|
540
|
-
}) => {
|
|
541
|
-
params: UpdateOcrDataParams;
|
|
542
|
-
isSecondId: boolean;
|
|
543
|
-
};
|
|
544
|
-
readonly onDone: readonly [{
|
|
545
|
-
readonly target: "loading";
|
|
546
|
-
readonly guard: "shouldLoadSecondOcrAfterFirst";
|
|
547
|
-
readonly actions: "beginSecondIdOcrPhase";
|
|
548
|
-
}, {
|
|
549
|
-
readonly target: "success";
|
|
550
|
-
}];
|
|
551
|
-
readonly onError: {
|
|
552
|
-
readonly target: "error";
|
|
553
|
-
readonly actions: "setError";
|
|
554
|
-
};
|
|
555
|
-
};
|
|
556
|
-
};
|
|
557
|
-
readonly error: {
|
|
558
|
-
readonly on: {
|
|
559
|
-
readonly RETRY: {
|
|
560
|
-
readonly target: "loading";
|
|
561
|
-
readonly actions: "resetForRetry";
|
|
562
|
-
};
|
|
563
|
-
};
|
|
564
|
-
};
|
|
565
|
-
readonly success: {
|
|
566
|
-
readonly after: {
|
|
567
|
-
readonly 3000: "finished";
|
|
568
|
-
};
|
|
569
|
-
};
|
|
570
|
-
readonly finished: {
|
|
571
|
-
readonly type: "final";
|
|
572
|
-
};
|
|
573
|
-
};
|
|
574
|
-
}>;
|
|
575
|
-
//#endregion
|
|
576
|
-
//#region src/modules/id-ocr/idOcrActor.d.ts
|
|
577
|
-
type CreateIdOcrActorOptions = {
|
|
578
|
-
config: IdOcrConfig;
|
|
579
|
-
};
|
|
580
|
-
//#endregion
|
|
581
|
-
//#region src/modules/id-ocr/idOcrManager.d.ts
|
|
582
|
-
type IdOcrIdleState = {
|
|
583
|
-
status: 'idle';
|
|
584
|
-
};
|
|
585
|
-
type IdOcrLoadingState = {
|
|
586
|
-
status: 'loading';
|
|
587
|
-
ocrDocument: IdOcrOcrDocument;
|
|
588
|
-
};
|
|
589
|
-
type IdOcrReadonlyState = {
|
|
590
|
-
status: 'readonly';
|
|
591
|
-
formData: UpdateOcrDataParams;
|
|
592
|
-
editableOcr: boolean;
|
|
593
|
-
ocrDocument: IdOcrOcrDocument;
|
|
594
|
-
};
|
|
595
|
-
type IdOcrInputtingState = {
|
|
596
|
-
status: 'inputting';
|
|
597
|
-
formData: UpdateOcrDataParams;
|
|
598
|
-
editedFields: UpdateOcrDataParams;
|
|
599
|
-
editableOcr: boolean;
|
|
600
|
-
ocrDocument: IdOcrOcrDocument;
|
|
601
|
-
validationErrors?: Partial<Record<keyof UpdateOcrDataParams, string>>;
|
|
602
|
-
};
|
|
603
|
-
type IdOcrSubmittingState = {
|
|
604
|
-
status: 'submitting';
|
|
605
|
-
ocrDocument: IdOcrOcrDocument;
|
|
606
|
-
};
|
|
607
|
-
type IdOcrFinishedState = {
|
|
608
|
-
status: 'finished';
|
|
609
|
-
};
|
|
610
|
-
type IdOcrErrorState = {
|
|
611
|
-
status: 'error';
|
|
612
|
-
error: string;
|
|
613
|
-
};
|
|
614
|
-
type IdOcrSuccessState = {
|
|
615
|
-
status: 'success';
|
|
616
|
-
};
|
|
617
|
-
type IdOcrState = IdOcrIdleState | IdOcrLoadingState | IdOcrReadonlyState | IdOcrInputtingState | IdOcrSubmittingState | IdOcrFinishedState | IdOcrErrorState | IdOcrSuccessState;
|
|
618
|
-
declare function createIdOcrManager(options: CreateIdOcrActorOptions): Manager<IdOcrState> & {
|
|
619
|
-
load(): void;
|
|
620
|
-
setField(field: keyof UpdateOcrDataParams, value: string): void;
|
|
621
|
-
validateField(field: keyof UpdateOcrDataParams): void;
|
|
622
|
-
continue(): void;
|
|
623
|
-
retry(): void;
|
|
624
|
-
};
|
|
625
|
-
type IdOcrManager = ReturnType<typeof createIdOcrManager>;
|
|
626
|
-
//#endregion
|
|
627
5
|
//#region src/modules/id-ocr/idOcrFields.d.ts
|
|
628
6
|
declare const OCR_FIELDS: OcrFieldConfig[];
|
|
629
7
|
declare const getOcrFields: (config: Pick<IdOcrConfig, "flowId">) => OcrFieldConfig[];
|