@incodetech/core 0.0.0-dev-20260409-9829838 → 0.0.0-dev-20260409-0e64d73
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/document-capture.d.ts +73 -73
- package/dist/document-upload.d.ts +43 -43
- package/dist/identity-reuse.d.ts +40 -40
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as Manager } from "./Manager-Bcnemkyi.js";
|
|
2
2
|
import "./Actor-BkPcZGke.js";
|
|
3
3
|
import { t as CameraStream } from "./camera-CgnuDuxy.js";
|
|
4
|
-
import * as
|
|
4
|
+
import * as xstate285 from "xstate";
|
|
5
5
|
|
|
6
6
|
//#region src/modules/document-capture/types.d.ts
|
|
7
7
|
type DocumentType = 'addressStatement' | 'otherDocument1' | 'otherDocument2' | 'otherDocument3' | 'v5cMultiPageLogbook' | 'circulationCard' | 'financeSettlement' | 'carInvoice' | 'capture' | 'processPoaOcr' | 'processLoaOcr' | 'processAsylumSeekerVisaZaf' | 'processBankStatementOCR' | 'processBankCheck' | 'processV5CLogbook' | 'processCarInvoice' | 'processCirculationCard' | 'processFinanceSettlement';
|
|
@@ -84,7 +84,7 @@ type DocumentCaptureInput = {
|
|
|
84
84
|
};
|
|
85
85
|
//#endregion
|
|
86
86
|
//#region src/modules/document-capture/documentCaptureStateMachine.d.ts
|
|
87
|
-
declare const documentCaptureMachine:
|
|
87
|
+
declare const documentCaptureMachine: xstate285.StateMachine<DocumentCaptureContext, {
|
|
88
88
|
type: "CAPTURE";
|
|
89
89
|
} | {
|
|
90
90
|
type: "FILE_SELECTED";
|
|
@@ -113,105 +113,105 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
113
113
|
} | {
|
|
114
114
|
type: "CLOSE";
|
|
115
115
|
}, {
|
|
116
|
-
[x: string]:
|
|
116
|
+
[x: string]: xstate285.ActorRefFromLogic<xstate285.PromiseActorLogic<MediaStream, void, xstate285.EventObject>> | xstate285.ActorRefFromLogic<xstate285.PromiseActorLogic<DocumentUploadResponse, {
|
|
117
117
|
capturedDocument: NonNullable<DocumentCaptureContext["capturedDocument"]>;
|
|
118
118
|
processingType: string;
|
|
119
119
|
onProgress: (progress: number) => void;
|
|
120
|
-
},
|
|
120
|
+
}, xstate285.EventObject>> | xstate285.ActorRefFromLogic<xstate285.PromiseActorLogic<FinalizeDocumentResponse, {
|
|
121
121
|
processingType: string;
|
|
122
|
-
},
|
|
123
|
-
},
|
|
122
|
+
}, xstate285.EventObject>> | undefined;
|
|
123
|
+
}, xstate285.Values<{
|
|
124
124
|
initCamera: {
|
|
125
125
|
src: "initCamera";
|
|
126
|
-
logic:
|
|
126
|
+
logic: xstate285.PromiseActorLogic<MediaStream, void, xstate285.EventObject>;
|
|
127
127
|
id: string | undefined;
|
|
128
128
|
};
|
|
129
129
|
uploadDocument: {
|
|
130
130
|
src: "uploadDocument";
|
|
131
|
-
logic:
|
|
131
|
+
logic: xstate285.PromiseActorLogic<DocumentUploadResponse, {
|
|
132
132
|
capturedDocument: NonNullable<DocumentCaptureContext["capturedDocument"]>;
|
|
133
133
|
processingType: string;
|
|
134
134
|
onProgress: (progress: number) => void;
|
|
135
|
-
},
|
|
135
|
+
}, xstate285.EventObject>;
|
|
136
136
|
id: string | undefined;
|
|
137
137
|
};
|
|
138
138
|
finalizeDocumentRequest: {
|
|
139
139
|
src: "finalizeDocumentRequest";
|
|
140
|
-
logic:
|
|
140
|
+
logic: xstate285.PromiseActorLogic<FinalizeDocumentResponse, {
|
|
141
141
|
processingType: string;
|
|
142
|
-
},
|
|
142
|
+
}, xstate285.EventObject>;
|
|
143
143
|
id: string | undefined;
|
|
144
144
|
};
|
|
145
|
-
}>,
|
|
145
|
+
}>, xstate285.Values<{
|
|
146
146
|
clearError: {
|
|
147
147
|
type: "clearError";
|
|
148
|
-
params:
|
|
148
|
+
params: xstate285.NonReducibleUnknown;
|
|
149
149
|
};
|
|
150
150
|
setStream: {
|
|
151
151
|
type: "setStream";
|
|
152
|
-
params:
|
|
153
|
-
};
|
|
154
|
-
setProgress: {
|
|
155
|
-
type: "setProgress";
|
|
156
|
-
params: xstate349.NonReducibleUnknown;
|
|
157
|
-
};
|
|
158
|
-
stopStream: {
|
|
159
|
-
type: "stopStream";
|
|
160
|
-
params: xstate349.NonReducibleUnknown;
|
|
152
|
+
params: xstate285.NonReducibleUnknown;
|
|
161
153
|
};
|
|
162
154
|
setCapturedDocument: {
|
|
163
155
|
type: "setCapturedDocument";
|
|
164
|
-
params:
|
|
156
|
+
params: xstate285.NonReducibleUnknown;
|
|
165
157
|
};
|
|
166
158
|
setFileTooLargeError: {
|
|
167
159
|
type: "setFileTooLargeError";
|
|
168
|
-
params:
|
|
160
|
+
params: xstate285.NonReducibleUnknown;
|
|
161
|
+
};
|
|
162
|
+
setProgress: {
|
|
163
|
+
type: "setProgress";
|
|
164
|
+
params: xstate285.NonReducibleUnknown;
|
|
169
165
|
};
|
|
170
166
|
setUploadError: {
|
|
171
167
|
type: "setUploadError";
|
|
172
|
-
params:
|
|
168
|
+
params: xstate285.NonReducibleUnknown;
|
|
173
169
|
};
|
|
174
170
|
setFinalizeError: {
|
|
175
171
|
type: "setFinalizeError";
|
|
176
|
-
params:
|
|
172
|
+
params: xstate285.NonReducibleUnknown;
|
|
177
173
|
};
|
|
178
174
|
decrementAttemptsRemaining: {
|
|
179
175
|
type: "decrementAttemptsRemaining";
|
|
180
|
-
params:
|
|
176
|
+
params: xstate285.NonReducibleUnknown;
|
|
181
177
|
};
|
|
182
178
|
setCaptureMethodFile: {
|
|
183
179
|
type: "setCaptureMethodFile";
|
|
184
|
-
params:
|
|
180
|
+
params: xstate285.NonReducibleUnknown;
|
|
185
181
|
};
|
|
186
182
|
setCaptureMethodCamera: {
|
|
187
183
|
type: "setCaptureMethodCamera";
|
|
188
|
-
params:
|
|
184
|
+
params: xstate285.NonReducibleUnknown;
|
|
189
185
|
};
|
|
190
186
|
setCaptureMethodGallery: {
|
|
191
187
|
type: "setCaptureMethodGallery";
|
|
192
|
-
params:
|
|
188
|
+
params: xstate285.NonReducibleUnknown;
|
|
193
189
|
};
|
|
194
190
|
clearCapturedDocument: {
|
|
195
191
|
type: "clearCapturedDocument";
|
|
196
|
-
params:
|
|
192
|
+
params: xstate285.NonReducibleUnknown;
|
|
197
193
|
};
|
|
198
194
|
clearCapturedDocumentGalleryRetake: {
|
|
199
195
|
type: "clearCapturedDocumentGalleryRetake";
|
|
200
|
-
params:
|
|
196
|
+
params: xstate285.NonReducibleUnknown;
|
|
201
197
|
};
|
|
202
198
|
setNextPageType: {
|
|
203
199
|
type: "setNextPageType";
|
|
204
|
-
params:
|
|
200
|
+
params: xstate285.NonReducibleUnknown;
|
|
205
201
|
};
|
|
206
202
|
clearForNextPage: {
|
|
207
203
|
type: "clearForNextPage";
|
|
208
|
-
params:
|
|
204
|
+
params: xstate285.NonReducibleUnknown;
|
|
209
205
|
};
|
|
210
206
|
resetProgress: {
|
|
211
207
|
type: "resetProgress";
|
|
212
|
-
params:
|
|
208
|
+
params: xstate285.NonReducibleUnknown;
|
|
209
|
+
};
|
|
210
|
+
stopStream: {
|
|
211
|
+
type: "stopStream";
|
|
212
|
+
params: xstate285.NonReducibleUnknown;
|
|
213
213
|
};
|
|
214
|
-
}>,
|
|
214
|
+
}>, xstate285.Values<{
|
|
215
215
|
allowSkip: {
|
|
216
216
|
type: "allowSkip";
|
|
217
217
|
params: unknown;
|
|
@@ -272,7 +272,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
272
272
|
type: "fileSizeOkForNonGallery";
|
|
273
273
|
params: unknown;
|
|
274
274
|
};
|
|
275
|
-
}>, never, "finished" | "closed" | "initCamera" | "
|
|
275
|
+
}>, never, "finished" | "closed" | "initCamera" | "tutorial" | "capturing" | "preview" | "failure" | "uploading" | "success" | "nextPage" | "finalizing", string, DocumentCaptureInput, xstate285.NonReducibleUnknown, xstate285.EventObject, xstate285.MetaObject, {
|
|
276
276
|
readonly id: "documentCapture";
|
|
277
277
|
readonly initial: "tutorial";
|
|
278
278
|
readonly context: ({
|
|
@@ -281,93 +281,93 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
281
281
|
spawn: {
|
|
282
282
|
<TSrc extends "initCamera" | "uploadDocument" | "finalizeDocumentRequest">(logic: TSrc, ...[options]: ({
|
|
283
283
|
src: "initCamera";
|
|
284
|
-
logic:
|
|
284
|
+
logic: xstate285.PromiseActorLogic<MediaStream, void, xstate285.EventObject>;
|
|
285
285
|
id: string | undefined;
|
|
286
286
|
} extends infer T ? T extends {
|
|
287
287
|
src: "initCamera";
|
|
288
|
-
logic:
|
|
288
|
+
logic: xstate285.PromiseActorLogic<MediaStream, void, xstate285.EventObject>;
|
|
289
289
|
id: string | undefined;
|
|
290
290
|
} ? T extends {
|
|
291
291
|
src: TSrc;
|
|
292
|
-
} ?
|
|
292
|
+
} ? xstate285.ConditionalRequired<[options?: ({
|
|
293
293
|
id?: T["id"] | undefined;
|
|
294
294
|
systemId?: string;
|
|
295
|
-
input?:
|
|
295
|
+
input?: xstate285.InputFrom<T["logic"]> | undefined;
|
|
296
296
|
syncSnapshot?: boolean;
|
|
297
|
-
} & { [K in
|
|
297
|
+
} & { [K in xstate285.RequiredActorOptions<T>]: unknown }) | undefined], xstate285.IsNotNever<xstate285.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
298
298
|
src: "uploadDocument";
|
|
299
|
-
logic:
|
|
299
|
+
logic: xstate285.PromiseActorLogic<DocumentUploadResponse, {
|
|
300
300
|
capturedDocument: NonNullable<DocumentCaptureContext["capturedDocument"]>;
|
|
301
301
|
processingType: string;
|
|
302
302
|
onProgress: (progress: number) => void;
|
|
303
|
-
},
|
|
303
|
+
}, xstate285.EventObject>;
|
|
304
304
|
id: string | undefined;
|
|
305
305
|
} extends infer T_1 ? T_1 extends {
|
|
306
306
|
src: "uploadDocument";
|
|
307
|
-
logic:
|
|
307
|
+
logic: xstate285.PromiseActorLogic<DocumentUploadResponse, {
|
|
308
308
|
capturedDocument: NonNullable<DocumentCaptureContext["capturedDocument"]>;
|
|
309
309
|
processingType: string;
|
|
310
310
|
onProgress: (progress: number) => void;
|
|
311
|
-
},
|
|
311
|
+
}, xstate285.EventObject>;
|
|
312
312
|
id: string | undefined;
|
|
313
313
|
} ? T_1 extends {
|
|
314
314
|
src: TSrc;
|
|
315
|
-
} ?
|
|
315
|
+
} ? xstate285.ConditionalRequired<[options?: ({
|
|
316
316
|
id?: T_1["id"] | undefined;
|
|
317
317
|
systemId?: string;
|
|
318
|
-
input?:
|
|
318
|
+
input?: xstate285.InputFrom<T_1["logic"]> | undefined;
|
|
319
319
|
syncSnapshot?: boolean;
|
|
320
|
-
} & { [K_1 in
|
|
320
|
+
} & { [K_1 in xstate285.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate285.IsNotNever<xstate285.RequiredActorOptions<T_1>>> : never : never : never) | ({
|
|
321
321
|
src: "finalizeDocumentRequest";
|
|
322
|
-
logic:
|
|
322
|
+
logic: xstate285.PromiseActorLogic<FinalizeDocumentResponse, {
|
|
323
323
|
processingType: string;
|
|
324
|
-
},
|
|
324
|
+
}, xstate285.EventObject>;
|
|
325
325
|
id: string | undefined;
|
|
326
326
|
} extends infer T_2 ? T_2 extends {
|
|
327
327
|
src: "finalizeDocumentRequest";
|
|
328
|
-
logic:
|
|
328
|
+
logic: xstate285.PromiseActorLogic<FinalizeDocumentResponse, {
|
|
329
329
|
processingType: string;
|
|
330
|
-
},
|
|
330
|
+
}, xstate285.EventObject>;
|
|
331
331
|
id: string | undefined;
|
|
332
332
|
} ? T_2 extends {
|
|
333
333
|
src: TSrc;
|
|
334
|
-
} ?
|
|
334
|
+
} ? xstate285.ConditionalRequired<[options?: ({
|
|
335
335
|
id?: T_2["id"] | undefined;
|
|
336
336
|
systemId?: string;
|
|
337
|
-
input?:
|
|
337
|
+
input?: xstate285.InputFrom<T_2["logic"]> | undefined;
|
|
338
338
|
syncSnapshot?: boolean;
|
|
339
|
-
} & { [K_2 in
|
|
339
|
+
} & { [K_2 in xstate285.RequiredActorOptions<T_2>]: unknown }) | undefined], xstate285.IsNotNever<xstate285.RequiredActorOptions<T_2>>> : never : never : never)): xstate285.ActorRefFromLogic<xstate285.GetConcreteByKey<xstate285.Values<{
|
|
340
340
|
initCamera: {
|
|
341
341
|
src: "initCamera";
|
|
342
|
-
logic:
|
|
342
|
+
logic: xstate285.PromiseActorLogic<MediaStream, void, xstate285.EventObject>;
|
|
343
343
|
id: string | undefined;
|
|
344
344
|
};
|
|
345
345
|
uploadDocument: {
|
|
346
346
|
src: "uploadDocument";
|
|
347
|
-
logic:
|
|
347
|
+
logic: xstate285.PromiseActorLogic<DocumentUploadResponse, {
|
|
348
348
|
capturedDocument: NonNullable<DocumentCaptureContext["capturedDocument"]>;
|
|
349
349
|
processingType: string;
|
|
350
350
|
onProgress: (progress: number) => void;
|
|
351
|
-
},
|
|
351
|
+
}, xstate285.EventObject>;
|
|
352
352
|
id: string | undefined;
|
|
353
353
|
};
|
|
354
354
|
finalizeDocumentRequest: {
|
|
355
355
|
src: "finalizeDocumentRequest";
|
|
356
|
-
logic:
|
|
356
|
+
logic: xstate285.PromiseActorLogic<FinalizeDocumentResponse, {
|
|
357
357
|
processingType: string;
|
|
358
|
-
},
|
|
358
|
+
}, xstate285.EventObject>;
|
|
359
359
|
id: string | undefined;
|
|
360
360
|
};
|
|
361
361
|
}>, "src", TSrc>["logic"]>;
|
|
362
|
-
<TLogic extends
|
|
362
|
+
<TLogic extends xstate285.AnyActorLogic>(src: TLogic, ...[options]: xstate285.ConditionalRequired<[options?: ({
|
|
363
363
|
id?: never;
|
|
364
364
|
systemId?: string;
|
|
365
|
-
input?:
|
|
365
|
+
input?: xstate285.InputFrom<TLogic> | undefined;
|
|
366
366
|
syncSnapshot?: boolean;
|
|
367
|
-
} & { [K in
|
|
367
|
+
} & { [K in xstate285.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate285.IsNotNever<xstate285.RequiredLogicInput<TLogic>>>): xstate285.ActorRefFromLogic<TLogic>;
|
|
368
368
|
};
|
|
369
369
|
input: DocumentCaptureInput;
|
|
370
|
-
self:
|
|
370
|
+
self: xstate285.ActorRef<xstate285.MachineSnapshot<DocumentCaptureContext, {
|
|
371
371
|
type: "CAPTURE";
|
|
372
372
|
} | {
|
|
373
373
|
type: "FILE_SELECTED";
|
|
@@ -395,7 +395,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
395
395
|
type: "SKIP";
|
|
396
396
|
} | {
|
|
397
397
|
type: "CLOSE";
|
|
398
|
-
}, Record<string,
|
|
398
|
+
}, Record<string, xstate285.AnyActorRef | undefined>, xstate285.StateValue, string, unknown, any, any>, {
|
|
399
399
|
type: "CAPTURE";
|
|
400
400
|
} | {
|
|
401
401
|
type: "FILE_SELECTED";
|
|
@@ -423,7 +423,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
423
423
|
type: "SKIP";
|
|
424
424
|
} | {
|
|
425
425
|
type: "CLOSE";
|
|
426
|
-
},
|
|
426
|
+
}, xstate285.AnyEventObject>;
|
|
427
427
|
}) => {
|
|
428
428
|
config: {
|
|
429
429
|
processingType: DocumentType;
|
|
@@ -574,7 +574,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
574
574
|
} | {
|
|
575
575
|
type: "CLOSE";
|
|
576
576
|
};
|
|
577
|
-
self:
|
|
577
|
+
self: xstate285.ActorRef<xstate285.MachineSnapshot<DocumentCaptureContext, {
|
|
578
578
|
type: "CAPTURE";
|
|
579
579
|
} | {
|
|
580
580
|
type: "FILE_SELECTED";
|
|
@@ -602,7 +602,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
602
602
|
type: "SKIP";
|
|
603
603
|
} | {
|
|
604
604
|
type: "CLOSE";
|
|
605
|
-
}, Record<string,
|
|
605
|
+
}, Record<string, xstate285.AnyActorRef>, xstate285.StateValue, string, unknown, any, any>, {
|
|
606
606
|
type: "CAPTURE";
|
|
607
607
|
} | {
|
|
608
608
|
type: "FILE_SELECTED";
|
|
@@ -630,7 +630,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
630
630
|
type: "SKIP";
|
|
631
631
|
} | {
|
|
632
632
|
type: "CLOSE";
|
|
633
|
-
},
|
|
633
|
+
}, xstate285.AnyEventObject>;
|
|
634
634
|
}) => {
|
|
635
635
|
capturedDocument: CapturedDocument;
|
|
636
636
|
processingType: DocumentType;
|
|
@@ -725,7 +725,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
725
725
|
} | {
|
|
726
726
|
type: "CLOSE";
|
|
727
727
|
};
|
|
728
|
-
self:
|
|
728
|
+
self: xstate285.ActorRef<xstate285.MachineSnapshot<DocumentCaptureContext, {
|
|
729
729
|
type: "CAPTURE";
|
|
730
730
|
} | {
|
|
731
731
|
type: "FILE_SELECTED";
|
|
@@ -753,7 +753,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
753
753
|
type: "SKIP";
|
|
754
754
|
} | {
|
|
755
755
|
type: "CLOSE";
|
|
756
|
-
}, Record<string,
|
|
756
|
+
}, Record<string, xstate285.AnyActorRef>, xstate285.StateValue, string, unknown, any, any>, {
|
|
757
757
|
type: "CAPTURE";
|
|
758
758
|
} | {
|
|
759
759
|
type: "FILE_SELECTED";
|
|
@@ -781,7 +781,7 @@ declare const documentCaptureMachine: xstate349.StateMachine<DocumentCaptureCont
|
|
|
781
781
|
type: "SKIP";
|
|
782
782
|
} | {
|
|
783
783
|
type: "CLOSE";
|
|
784
|
-
},
|
|
784
|
+
}, xstate285.AnyEventObject>;
|
|
785
785
|
}) => {
|
|
786
786
|
processingType: DocumentType;
|
|
787
787
|
};
|
|
@@ -2,10 +2,10 @@ import { t as Manager } from "./Manager-Bcnemkyi.js";
|
|
|
2
2
|
import "./Actor-BkPcZGke.js";
|
|
3
3
|
import "./camera-CgnuDuxy.js";
|
|
4
4
|
import { n as DocumentUploadContext, r as DocumentUploadInput, t as DocumentUploadConfig } from "./types-CdlQrTiZ.js";
|
|
5
|
-
import * as
|
|
5
|
+
import * as xstate382 from "xstate";
|
|
6
6
|
|
|
7
7
|
//#region src/modules/document-upload/documentUploadStateMachine.d.ts
|
|
8
|
-
declare const documentUploadMachine:
|
|
8
|
+
declare const documentUploadMachine: xstate382.StateMachine<DocumentUploadContext, {
|
|
9
9
|
type: "START";
|
|
10
10
|
} | {
|
|
11
11
|
type: "CAPTURE";
|
|
@@ -18,52 +18,52 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
18
18
|
} | {
|
|
19
19
|
type: "CLOSE";
|
|
20
20
|
}, {
|
|
21
|
-
[x: string]:
|
|
21
|
+
[x: string]: xstate382.ActorRefFromLogic<xstate382.PromiseActorLogic<MediaStream, void, xstate382.EventObject>> | xstate382.ActorRefFromLogic<xstate382.PromiseActorLogic<void, {
|
|
22
22
|
imageBase64: string;
|
|
23
23
|
documentType: string;
|
|
24
24
|
onProgress: (progress: number) => void;
|
|
25
|
-
},
|
|
26
|
-
},
|
|
25
|
+
}, xstate382.EventObject>> | undefined;
|
|
26
|
+
}, xstate382.Values<{
|
|
27
27
|
initCamera: {
|
|
28
28
|
src: "initCamera";
|
|
29
|
-
logic:
|
|
29
|
+
logic: xstate382.PromiseActorLogic<MediaStream, void, xstate382.EventObject>;
|
|
30
30
|
id: string | undefined;
|
|
31
31
|
};
|
|
32
32
|
uploadDocument: {
|
|
33
33
|
src: "uploadDocument";
|
|
34
|
-
logic:
|
|
34
|
+
logic: xstate382.PromiseActorLogic<void, {
|
|
35
35
|
imageBase64: string;
|
|
36
36
|
documentType: string;
|
|
37
37
|
onProgress: (progress: number) => void;
|
|
38
|
-
},
|
|
38
|
+
}, xstate382.EventObject>;
|
|
39
39
|
id: string | undefined;
|
|
40
40
|
};
|
|
41
|
-
}>,
|
|
41
|
+
}>, xstate382.Values<{
|
|
42
42
|
setError: {
|
|
43
43
|
type: "setError";
|
|
44
|
-
params:
|
|
44
|
+
params: xstate382.NonReducibleUnknown;
|
|
45
45
|
};
|
|
46
46
|
clearError: {
|
|
47
47
|
type: "clearError";
|
|
48
|
-
params:
|
|
48
|
+
params: xstate382.NonReducibleUnknown;
|
|
49
49
|
};
|
|
50
50
|
setStream: {
|
|
51
51
|
type: "setStream";
|
|
52
|
-
params:
|
|
53
|
-
};
|
|
54
|
-
setImageAndClearError: {
|
|
55
|
-
type: "setImageAndClearError";
|
|
56
|
-
params: xstate285.NonReducibleUnknown;
|
|
52
|
+
params: xstate382.NonReducibleUnknown;
|
|
57
53
|
};
|
|
58
54
|
setProgress: {
|
|
59
55
|
type: "setProgress";
|
|
60
|
-
params:
|
|
56
|
+
params: xstate382.NonReducibleUnknown;
|
|
61
57
|
};
|
|
62
58
|
stopStream: {
|
|
63
59
|
type: "stopStream";
|
|
64
|
-
params:
|
|
60
|
+
params: xstate382.NonReducibleUnknown;
|
|
61
|
+
};
|
|
62
|
+
setImageAndClearError: {
|
|
63
|
+
type: "setImageAndClearError";
|
|
64
|
+
params: xstate382.NonReducibleUnknown;
|
|
65
65
|
};
|
|
66
|
-
}>, never, never, "error" | "idle" | "finished" | "closed" | "initCamera" | "capturing" | "uploading", string, DocumentUploadInput,
|
|
66
|
+
}>, never, never, "error" | "idle" | "finished" | "closed" | "initCamera" | "capturing" | "uploading", string, DocumentUploadInput, xstate382.NonReducibleUnknown, xstate382.EventObject, xstate382.MetaObject, {
|
|
67
67
|
readonly id: "documentUpload";
|
|
68
68
|
readonly initial: "idle";
|
|
69
69
|
readonly context: ({
|
|
@@ -72,67 +72,67 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
72
72
|
spawn: {
|
|
73
73
|
<TSrc extends "initCamera" | "uploadDocument">(logic: TSrc, ...[options]: ({
|
|
74
74
|
src: "initCamera";
|
|
75
|
-
logic:
|
|
75
|
+
logic: xstate382.PromiseActorLogic<MediaStream, void, xstate382.EventObject>;
|
|
76
76
|
id: string | undefined;
|
|
77
77
|
} extends infer T ? T extends {
|
|
78
78
|
src: "initCamera";
|
|
79
|
-
logic:
|
|
79
|
+
logic: xstate382.PromiseActorLogic<MediaStream, void, xstate382.EventObject>;
|
|
80
80
|
id: string | undefined;
|
|
81
81
|
} ? T extends {
|
|
82
82
|
src: TSrc;
|
|
83
|
-
} ?
|
|
83
|
+
} ? xstate382.ConditionalRequired<[options?: ({
|
|
84
84
|
id?: T["id"] | undefined;
|
|
85
85
|
systemId?: string;
|
|
86
|
-
input?:
|
|
86
|
+
input?: xstate382.InputFrom<T["logic"]> | undefined;
|
|
87
87
|
syncSnapshot?: boolean;
|
|
88
|
-
} & { [K in
|
|
88
|
+
} & { [K in xstate382.RequiredActorOptions<T>]: unknown }) | undefined], xstate382.IsNotNever<xstate382.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
89
89
|
src: "uploadDocument";
|
|
90
|
-
logic:
|
|
90
|
+
logic: xstate382.PromiseActorLogic<void, {
|
|
91
91
|
imageBase64: string;
|
|
92
92
|
documentType: string;
|
|
93
93
|
onProgress: (progress: number) => void;
|
|
94
|
-
},
|
|
94
|
+
}, xstate382.EventObject>;
|
|
95
95
|
id: string | undefined;
|
|
96
96
|
} extends infer T_1 ? T_1 extends {
|
|
97
97
|
src: "uploadDocument";
|
|
98
|
-
logic:
|
|
98
|
+
logic: xstate382.PromiseActorLogic<void, {
|
|
99
99
|
imageBase64: string;
|
|
100
100
|
documentType: string;
|
|
101
101
|
onProgress: (progress: number) => void;
|
|
102
|
-
},
|
|
102
|
+
}, xstate382.EventObject>;
|
|
103
103
|
id: string | undefined;
|
|
104
104
|
} ? T_1 extends {
|
|
105
105
|
src: TSrc;
|
|
106
|
-
} ?
|
|
106
|
+
} ? xstate382.ConditionalRequired<[options?: ({
|
|
107
107
|
id?: T_1["id"] | undefined;
|
|
108
108
|
systemId?: string;
|
|
109
|
-
input?:
|
|
109
|
+
input?: xstate382.InputFrom<T_1["logic"]> | undefined;
|
|
110
110
|
syncSnapshot?: boolean;
|
|
111
|
-
} & { [K_1 in
|
|
111
|
+
} & { [K_1 in xstate382.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate382.IsNotNever<xstate382.RequiredActorOptions<T_1>>> : never : never : never)): xstate382.ActorRefFromLogic<xstate382.GetConcreteByKey<xstate382.Values<{
|
|
112
112
|
initCamera: {
|
|
113
113
|
src: "initCamera";
|
|
114
|
-
logic:
|
|
114
|
+
logic: xstate382.PromiseActorLogic<MediaStream, void, xstate382.EventObject>;
|
|
115
115
|
id: string | undefined;
|
|
116
116
|
};
|
|
117
117
|
uploadDocument: {
|
|
118
118
|
src: "uploadDocument";
|
|
119
|
-
logic:
|
|
119
|
+
logic: xstate382.PromiseActorLogic<void, {
|
|
120
120
|
imageBase64: string;
|
|
121
121
|
documentType: string;
|
|
122
122
|
onProgress: (progress: number) => void;
|
|
123
|
-
},
|
|
123
|
+
}, xstate382.EventObject>;
|
|
124
124
|
id: string | undefined;
|
|
125
125
|
};
|
|
126
126
|
}>, "src", TSrc>["logic"]>;
|
|
127
|
-
<TLogic extends
|
|
127
|
+
<TLogic extends xstate382.AnyActorLogic>(src: TLogic, ...[options]: xstate382.ConditionalRequired<[options?: ({
|
|
128
128
|
id?: never;
|
|
129
129
|
systemId?: string;
|
|
130
|
-
input?:
|
|
130
|
+
input?: xstate382.InputFrom<TLogic> | undefined;
|
|
131
131
|
syncSnapshot?: boolean;
|
|
132
|
-
} & { [K in
|
|
132
|
+
} & { [K in xstate382.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate382.IsNotNever<xstate382.RequiredLogicInput<TLogic>>>): xstate382.ActorRefFromLogic<TLogic>;
|
|
133
133
|
};
|
|
134
134
|
input: DocumentUploadInput;
|
|
135
|
-
self:
|
|
135
|
+
self: xstate382.ActorRef<xstate382.MachineSnapshot<DocumentUploadContext, {
|
|
136
136
|
type: "START";
|
|
137
137
|
} | {
|
|
138
138
|
type: "CAPTURE";
|
|
@@ -144,7 +144,7 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
144
144
|
type: "RETRY";
|
|
145
145
|
} | {
|
|
146
146
|
type: "CLOSE";
|
|
147
|
-
}, Record<string,
|
|
147
|
+
}, Record<string, xstate382.AnyActorRef | undefined>, xstate382.StateValue, string, unknown, any, any>, {
|
|
148
148
|
type: "START";
|
|
149
149
|
} | {
|
|
150
150
|
type: "CAPTURE";
|
|
@@ -156,7 +156,7 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
156
156
|
type: "RETRY";
|
|
157
157
|
} | {
|
|
158
158
|
type: "CLOSE";
|
|
159
|
-
},
|
|
159
|
+
}, xstate382.AnyEventObject>;
|
|
160
160
|
}) => {
|
|
161
161
|
config: DocumentUploadConfig;
|
|
162
162
|
stream: undefined;
|
|
@@ -226,7 +226,7 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
226
226
|
} | {
|
|
227
227
|
type: "CLOSE";
|
|
228
228
|
};
|
|
229
|
-
self:
|
|
229
|
+
self: xstate382.ActorRef<xstate382.MachineSnapshot<DocumentUploadContext, {
|
|
230
230
|
type: "START";
|
|
231
231
|
} | {
|
|
232
232
|
type: "CAPTURE";
|
|
@@ -238,7 +238,7 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
238
238
|
type: "RETRY";
|
|
239
239
|
} | {
|
|
240
240
|
type: "CLOSE";
|
|
241
|
-
}, Record<string,
|
|
241
|
+
}, Record<string, xstate382.AnyActorRef>, xstate382.StateValue, string, unknown, any, any>, {
|
|
242
242
|
type: "START";
|
|
243
243
|
} | {
|
|
244
244
|
type: "CAPTURE";
|
|
@@ -250,7 +250,7 @@ declare const documentUploadMachine: xstate285.StateMachine<DocumentUploadContex
|
|
|
250
250
|
type: "RETRY";
|
|
251
251
|
} | {
|
|
252
252
|
type: "CLOSE";
|
|
253
|
-
},
|
|
253
|
+
}, xstate382.AnyEventObject>;
|
|
254
254
|
}) => {
|
|
255
255
|
imageBase64: string;
|
|
256
256
|
documentType: string;
|
package/dist/identity-reuse.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as Manager } from "./Manager-Bcnemkyi.js";
|
|
2
2
|
import { t as ActorRefFrom } from "./Actor-BkPcZGke.js";
|
|
3
|
-
import * as
|
|
3
|
+
import * as xstate735 from "xstate";
|
|
4
4
|
|
|
5
5
|
//#region src/modules/identity-reuse/types.d.ts
|
|
6
6
|
|
|
@@ -32,7 +32,7 @@ type IdentityReuseContext = {
|
|
|
32
32
|
type IdentityReuseInput = {
|
|
33
33
|
config: IdentityReuseConfig;
|
|
34
34
|
};
|
|
35
|
-
declare const identityReuseMachine:
|
|
35
|
+
declare const identityReuseMachine: xstate735.StateMachine<IdentityReuseContext, {
|
|
36
36
|
type: "LOAD";
|
|
37
37
|
} | {
|
|
38
38
|
type: "START_SELECTION";
|
|
@@ -48,49 +48,49 @@ declare const identityReuseMachine: xstate446.StateMachine<IdentityReuseContext,
|
|
|
48
48
|
} | {
|
|
49
49
|
type: "RETRY";
|
|
50
50
|
}, {
|
|
51
|
-
[x: string]:
|
|
52
|
-
},
|
|
51
|
+
[x: string]: xstate735.ActorRefFromLogic<xstate735.PromiseActorLogic<FetchCandidatesResponse, void, xstate735.EventObject>> | xstate735.ActorRefFromLogic<xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>> | undefined;
|
|
52
|
+
}, xstate735.Values<{
|
|
53
53
|
fetchCandidates: {
|
|
54
54
|
src: "fetchCandidates";
|
|
55
|
-
logic:
|
|
55
|
+
logic: xstate735.PromiseActorLogic<FetchCandidatesResponse, void, xstate735.EventObject>;
|
|
56
56
|
id: string | undefined;
|
|
57
57
|
};
|
|
58
58
|
submitContinue: {
|
|
59
59
|
src: "submitContinue";
|
|
60
|
-
logic:
|
|
60
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
61
61
|
id: string | undefined;
|
|
62
62
|
};
|
|
63
63
|
submitSkip: {
|
|
64
64
|
src: "submitSkip";
|
|
65
|
-
logic:
|
|
65
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
66
66
|
id: string | undefined;
|
|
67
67
|
};
|
|
68
|
-
}>,
|
|
68
|
+
}>, xstate735.Values<{
|
|
69
69
|
setError: {
|
|
70
70
|
type: "setError";
|
|
71
|
-
params:
|
|
71
|
+
params: xstate735.NonReducibleUnknown;
|
|
72
72
|
};
|
|
73
73
|
clearError: {
|
|
74
74
|
type: "clearError";
|
|
75
|
-
params:
|
|
75
|
+
params: xstate735.NonReducibleUnknown;
|
|
76
76
|
};
|
|
77
77
|
setCandidates: {
|
|
78
78
|
type: "setCandidates";
|
|
79
|
-
params:
|
|
79
|
+
params: xstate735.NonReducibleUnknown;
|
|
80
80
|
};
|
|
81
81
|
setSelectedCandidate: {
|
|
82
82
|
type: "setSelectedCandidate";
|
|
83
|
-
params:
|
|
83
|
+
params: xstate735.NonReducibleUnknown;
|
|
84
84
|
};
|
|
85
85
|
autoSelectSingleCandidate: {
|
|
86
86
|
type: "autoSelectSingleCandidate";
|
|
87
|
-
params:
|
|
87
|
+
params: xstate735.NonReducibleUnknown;
|
|
88
88
|
};
|
|
89
89
|
clearSelection: {
|
|
90
90
|
type: "clearSelection";
|
|
91
|
-
params:
|
|
91
|
+
params: xstate735.NonReducibleUnknown;
|
|
92
92
|
};
|
|
93
|
-
}>,
|
|
93
|
+
}>, xstate735.Values<{
|
|
94
94
|
hasMultipleCandidates: {
|
|
95
95
|
type: "hasMultipleCandidates";
|
|
96
96
|
params: unknown;
|
|
@@ -105,7 +105,7 @@ declare const identityReuseMachine: xstate446.StateMachine<IdentityReuseContext,
|
|
|
105
105
|
};
|
|
106
106
|
}>, never, "error" | "idle" | "loading" | "finished" | "submitContinue" | "submitSkip" | "oneCandidateFound" | "noCandidatesFound" | {
|
|
107
107
|
multiCandidatesFound: "noCandidateSelected" | "choosingCandidate" | "candidateSelected";
|
|
108
|
-
}, string, IdentityReuseInput,
|
|
108
|
+
}, string, IdentityReuseInput, xstate735.NonReducibleUnknown, xstate735.EventObject, xstate735.MetaObject, {
|
|
109
109
|
readonly id: "identityReuse";
|
|
110
110
|
readonly initial: "idle";
|
|
111
111
|
readonly context: ({
|
|
@@ -114,75 +114,75 @@ declare const identityReuseMachine: xstate446.StateMachine<IdentityReuseContext,
|
|
|
114
114
|
spawn: {
|
|
115
115
|
<TSrc extends "fetchCandidates" | "submitContinue" | "submitSkip">(logic: TSrc, ...[options]: ({
|
|
116
116
|
src: "fetchCandidates";
|
|
117
|
-
logic:
|
|
117
|
+
logic: xstate735.PromiseActorLogic<FetchCandidatesResponse, void, xstate735.EventObject>;
|
|
118
118
|
id: string | undefined;
|
|
119
119
|
} extends infer T ? T extends {
|
|
120
120
|
src: "fetchCandidates";
|
|
121
|
-
logic:
|
|
121
|
+
logic: xstate735.PromiseActorLogic<FetchCandidatesResponse, void, xstate735.EventObject>;
|
|
122
122
|
id: string | undefined;
|
|
123
123
|
} ? T extends {
|
|
124
124
|
src: TSrc;
|
|
125
|
-
} ?
|
|
125
|
+
} ? xstate735.ConditionalRequired<[options?: ({
|
|
126
126
|
id?: T["id"] | undefined;
|
|
127
127
|
systemId?: string;
|
|
128
|
-
input?:
|
|
128
|
+
input?: xstate735.InputFrom<T["logic"]> | undefined;
|
|
129
129
|
syncSnapshot?: boolean;
|
|
130
|
-
} & { [K in
|
|
130
|
+
} & { [K in xstate735.RequiredActorOptions<T>]: unknown }) | undefined], xstate735.IsNotNever<xstate735.RequiredActorOptions<T>>> : never : never : never) | ({
|
|
131
131
|
src: "submitContinue";
|
|
132
|
-
logic:
|
|
132
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
133
133
|
id: string | undefined;
|
|
134
134
|
} extends infer T_1 ? T_1 extends {
|
|
135
135
|
src: "submitContinue";
|
|
136
|
-
logic:
|
|
136
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
137
137
|
id: string | undefined;
|
|
138
138
|
} ? T_1 extends {
|
|
139
139
|
src: TSrc;
|
|
140
|
-
} ?
|
|
140
|
+
} ? xstate735.ConditionalRequired<[options?: ({
|
|
141
141
|
id?: T_1["id"] | undefined;
|
|
142
142
|
systemId?: string;
|
|
143
|
-
input?:
|
|
143
|
+
input?: xstate735.InputFrom<T_1["logic"]> | undefined;
|
|
144
144
|
syncSnapshot?: boolean;
|
|
145
|
-
} & { [K_1 in
|
|
145
|
+
} & { [K_1 in xstate735.RequiredActorOptions<T_1>]: unknown }) | undefined], xstate735.IsNotNever<xstate735.RequiredActorOptions<T_1>>> : never : never : never) | ({
|
|
146
146
|
src: "submitSkip";
|
|
147
|
-
logic:
|
|
147
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
148
148
|
id: string | undefined;
|
|
149
149
|
} extends infer T_2 ? T_2 extends {
|
|
150
150
|
src: "submitSkip";
|
|
151
|
-
logic:
|
|
151
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
152
152
|
id: string | undefined;
|
|
153
153
|
} ? T_2 extends {
|
|
154
154
|
src: TSrc;
|
|
155
|
-
} ?
|
|
155
|
+
} ? xstate735.ConditionalRequired<[options?: ({
|
|
156
156
|
id?: T_2["id"] | undefined;
|
|
157
157
|
systemId?: string;
|
|
158
|
-
input?:
|
|
158
|
+
input?: xstate735.InputFrom<T_2["logic"]> | undefined;
|
|
159
159
|
syncSnapshot?: boolean;
|
|
160
|
-
} & { [K_2 in
|
|
160
|
+
} & { [K_2 in xstate735.RequiredActorOptions<T_2>]: unknown }) | undefined], xstate735.IsNotNever<xstate735.RequiredActorOptions<T_2>>> : never : never : never)): xstate735.ActorRefFromLogic<xstate735.GetConcreteByKey<xstate735.Values<{
|
|
161
161
|
fetchCandidates: {
|
|
162
162
|
src: "fetchCandidates";
|
|
163
|
-
logic:
|
|
163
|
+
logic: xstate735.PromiseActorLogic<FetchCandidatesResponse, void, xstate735.EventObject>;
|
|
164
164
|
id: string | undefined;
|
|
165
165
|
};
|
|
166
166
|
submitContinue: {
|
|
167
167
|
src: "submitContinue";
|
|
168
|
-
logic:
|
|
168
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
169
169
|
id: string | undefined;
|
|
170
170
|
};
|
|
171
171
|
submitSkip: {
|
|
172
172
|
src: "submitSkip";
|
|
173
|
-
logic:
|
|
173
|
+
logic: xstate735.PromiseActorLogic<SubmitResponse, void, xstate735.EventObject>;
|
|
174
174
|
id: string | undefined;
|
|
175
175
|
};
|
|
176
176
|
}>, "src", TSrc>["logic"]>;
|
|
177
|
-
<TLogic extends
|
|
177
|
+
<TLogic extends xstate735.AnyActorLogic>(src: TLogic, ...[options]: xstate735.ConditionalRequired<[options?: ({
|
|
178
178
|
id?: never;
|
|
179
179
|
systemId?: string;
|
|
180
|
-
input?:
|
|
180
|
+
input?: xstate735.InputFrom<TLogic> | undefined;
|
|
181
181
|
syncSnapshot?: boolean;
|
|
182
|
-
} & { [K in
|
|
182
|
+
} & { [K in xstate735.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate735.IsNotNever<xstate735.RequiredLogicInput<TLogic>>>): xstate735.ActorRefFromLogic<TLogic>;
|
|
183
183
|
};
|
|
184
184
|
input: IdentityReuseInput;
|
|
185
|
-
self:
|
|
185
|
+
self: xstate735.ActorRef<xstate735.MachineSnapshot<IdentityReuseContext, {
|
|
186
186
|
type: "LOAD";
|
|
187
187
|
} | {
|
|
188
188
|
type: "START_SELECTION";
|
|
@@ -197,7 +197,7 @@ declare const identityReuseMachine: xstate446.StateMachine<IdentityReuseContext,
|
|
|
197
197
|
type: "SKIP";
|
|
198
198
|
} | {
|
|
199
199
|
type: "RETRY";
|
|
200
|
-
}, Record<string,
|
|
200
|
+
}, Record<string, xstate735.AnyActorRef | undefined>, xstate735.StateValue, string, unknown, any, any>, {
|
|
201
201
|
type: "LOAD";
|
|
202
202
|
} | {
|
|
203
203
|
type: "START_SELECTION";
|
|
@@ -212,7 +212,7 @@ declare const identityReuseMachine: xstate446.StateMachine<IdentityReuseContext,
|
|
|
212
212
|
type: "SKIP";
|
|
213
213
|
} | {
|
|
214
214
|
type: "RETRY";
|
|
215
|
-
},
|
|
215
|
+
}, xstate735.AnyEventObject>;
|
|
216
216
|
}) => {
|
|
217
217
|
config: IdentityReuseConfig;
|
|
218
218
|
currentOrganizationName: undefined;
|