@regulaforensics/vp-frontend-document-components 7.6.2172-rc → 7.6.2176-nightly
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/index.d.ts +49 -22
- package/dist/main.iife.js +24 -24
- package/dist/main.js +10389 -10403
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -70,7 +70,7 @@ export declare enum CaptureMode {
|
|
|
70
70
|
export declare type CaptureType = Array<Omit<CaptureFrameType, 'imageData'>>;
|
|
71
71
|
|
|
72
72
|
export declare interface CurrentPage {
|
|
73
|
-
data:
|
|
73
|
+
data: DocumentReaderResponseType | null;
|
|
74
74
|
startNextPage: () => Promise<void>;
|
|
75
75
|
finishRecognition: () => void;
|
|
76
76
|
}
|
|
@@ -112,12 +112,12 @@ export declare class DocumentReaderCaptureWebComponent extends HTMLElement {
|
|
|
112
112
|
private _translations;
|
|
113
113
|
private _settings;
|
|
114
114
|
constructor();
|
|
115
|
-
static get observedAttributes(): CameraSnapshotAttributes
|
|
115
|
+
static get observedAttributes(): Array<CameraSnapshotAttributes>;
|
|
116
116
|
private onEvent;
|
|
117
117
|
attributeChangedCallback(name: CameraSnapshotAttributes): void;
|
|
118
118
|
connectedCallback(): void;
|
|
119
|
-
set translations(dictionary:
|
|
120
|
-
get translations():
|
|
119
|
+
set translations(dictionary: DocumentDictionaries | null);
|
|
120
|
+
get translations(): DocumentDictionaries | null;
|
|
121
121
|
set settings(params: CameraSnapshotSettings);
|
|
122
122
|
get settings(): CameraSnapshotSettings;
|
|
123
123
|
private render;
|
|
@@ -147,8 +147,8 @@ export declare class DocumentReaderProcessor {
|
|
|
147
147
|
isInitialized: boolean;
|
|
148
148
|
videoElement: HTMLVideoElement | null;
|
|
149
149
|
constructor(videoElement?: HTMLVideoElement);
|
|
150
|
-
get recognizeListener():
|
|
151
|
-
set recognizeListener(listener:
|
|
150
|
+
get recognizeListener(): RecognizeListener | null;
|
|
151
|
+
set recognizeListener(listener: RecognizeListener | null);
|
|
152
152
|
get streamParam(): Partial<StreamParams>;
|
|
153
153
|
set streamParam(params: Partial<StreamParams>);
|
|
154
154
|
get recognizerProcessParam(): ProcessingRequest;
|
|
@@ -164,8 +164,8 @@ export declare class DocumentReaderProcessor {
|
|
|
164
164
|
private startNewPage;
|
|
165
165
|
private startNewDocument;
|
|
166
166
|
switchCamera(): Promise<void>;
|
|
167
|
-
startRecognition(responseListener?: ResponseListener): Promise<
|
|
168
|
-
processImage(images: FileList | Array<Blob>): Promise<
|
|
167
|
+
startRecognition(responseListener?: ResponseListener): Promise<DocumentReaderResponseType | null>;
|
|
168
|
+
processImage(images: FileList | Array<Blob>): Promise<DocumentReaderResponseType>;
|
|
169
169
|
stopRecognition(): void;
|
|
170
170
|
initialize(license?: {
|
|
171
171
|
license: string | undefined;
|
|
@@ -235,9 +235,9 @@ export declare class DocumentReaderService {
|
|
|
235
235
|
license: string | undefined;
|
|
236
236
|
}): Promise<License>;
|
|
237
237
|
private doProcess;
|
|
238
|
-
processImageBase64(base64ImagesArray: Array<string>, params: ProcessingRequest): Promise<
|
|
239
|
-
process(imageDataArray: Array<ImageData>, params?: ProcessingRequest): Promise<
|
|
240
|
-
processImage(imageDataArray: Array<ImageData> | Array<ArrayBuffer>, params?: ProcessingRequest): Promise<
|
|
238
|
+
processImageBase64(base64ImagesArray: Array<string>, params: ProcessingRequest): Promise<DocumentReaderResponseType>;
|
|
239
|
+
process(imageDataArray: Array<ImageData>, params?: ProcessingRequest): Promise<DocumentReaderResponseType>;
|
|
240
|
+
processImage(imageDataArray: Array<ImageData> | Array<ArrayBuffer>, params?: ProcessingRequest): Promise<DocumentReaderResponseType>;
|
|
241
241
|
startNewPage(): Promise<void>;
|
|
242
242
|
startNewDocument(metadata?: Record<string, any>): Promise<NewTransaction>;
|
|
243
243
|
createBackendTransaction(metadata?: Record<string, any>): Promise<NewTransaction>;
|
|
@@ -288,12 +288,12 @@ export declare class DocumentReaderWebComponent extends HTMLElement {
|
|
|
288
288
|
private _translations;
|
|
289
289
|
private _settings;
|
|
290
290
|
constructor();
|
|
291
|
-
static get observedAttributes(): DocumentReaderAttributes
|
|
291
|
+
static get observedAttributes(): Array<DocumentReaderAttributes>;
|
|
292
292
|
private onEvent;
|
|
293
293
|
attributeChangedCallback(name: DocumentReaderAttributes): void;
|
|
294
294
|
connectedCallback(): void;
|
|
295
|
-
set translations(dictionary:
|
|
296
|
-
get translations():
|
|
295
|
+
set translations(dictionary: DocumentDictionaries | null);
|
|
296
|
+
get translations(): DocumentDictionaries | null;
|
|
297
297
|
set settings(params: DocumentReaderSettings);
|
|
298
298
|
get settings(): DocumentReaderSettings;
|
|
299
299
|
private render;
|
|
@@ -518,7 +518,7 @@ export declare interface ProcessRejectResponse extends ProcessResponse {
|
|
|
518
518
|
reject_reason: number;
|
|
519
519
|
}
|
|
520
520
|
|
|
521
|
-
declare type RecognizeListener = (data:
|
|
521
|
+
declare type RecognizeListener = (data: DocumentReaderResponseType | ProcessRejectResponse) => void;
|
|
522
522
|
|
|
523
523
|
export declare type Resolution = Partial<WidthAndHeight>;
|
|
524
524
|
|
|
@@ -607,24 +607,51 @@ export * from "@regulaforensics/document-reader-webclient";
|
|
|
607
607
|
export { }
|
|
608
608
|
|
|
609
609
|
|
|
610
|
+
|
|
610
611
|
declare global {
|
|
612
|
+
const UI_COMPONENTS_VERSION: string;
|
|
613
|
+
const DOC_WASM_S3_PATH: string;
|
|
614
|
+
const DOCUMENT_API: string;
|
|
615
|
+
const LICENSE: string | undefined;
|
|
616
|
+
|
|
617
|
+
namespace React.JSX {
|
|
618
|
+
interface IntrinsicElements {
|
|
619
|
+
'document-reader': React.DetailedHTMLProps<
|
|
620
|
+
IDocumentReader & React.HTMLAttributes<DocumentReaderWebComponent>,
|
|
621
|
+
DocumentReaderWebComponent
|
|
622
|
+
>;
|
|
623
|
+
'camera-snapshot': React.DetailedHTMLProps<
|
|
624
|
+
ICameraSnapshot & React.HTMLAttributes<DocumentReaderCaptureWebComponent>,
|
|
625
|
+
DocumentReaderCaptureWebComponent
|
|
626
|
+
>;
|
|
627
|
+
'fullscreen-container': React.DetailedHTMLProps<
|
|
628
|
+
React.HTMLAttributes<FullScreenContainer>,
|
|
629
|
+
FullScreenContainer
|
|
630
|
+
>;
|
|
631
|
+
}
|
|
632
|
+
}
|
|
633
|
+
|
|
611
634
|
interface HTMLElementEventMap {
|
|
612
635
|
'document-reader': CustomEvent<DocumentReaderDetailType | TransactionEvent>;
|
|
613
636
|
'camera-snapshot': CustomEvent<CameraSnapshotDetailType>;
|
|
614
637
|
}
|
|
638
|
+
|
|
615
639
|
interface Window {
|
|
616
640
|
RegulaDocumentSDK: DocumentReaderService;
|
|
617
641
|
}
|
|
618
642
|
}
|
|
619
643
|
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
var URL: string;
|
|
644
|
+
declare global {
|
|
645
|
+
const VERSION: string;
|
|
646
|
+
const ENV: string;
|
|
624
647
|
}
|
|
625
648
|
|
|
649
|
+
declare module 'react' {
|
|
650
|
+
interface HTMLAttributes<T> extends AriaAttributes, DOMAttributes<T> {
|
|
651
|
+
part?: string;
|
|
652
|
+
}
|
|
626
653
|
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
654
|
+
interface SVGAttributes<T> extends AriaAttributes, DOMAttributes<T> {
|
|
655
|
+
part?: string;
|
|
656
|
+
}
|
|
630
657
|
}
|