@idscan/idvc2 2.4.17 → 2.5.1
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/README.md +16 -1
- package/dist/css/idvc.css +1 -1
- package/dist/idvc.js +1684 -2
- package/dist/index.html +3 -4
- package/dist/js/defaultConfig.ts +0 -8
- package/dist/js/environment/langs.js +1 -1
- package/dist/js/environment/networkNames.json +5 -16
- package/dist/js/environment/stepsDescription.ts +2 -23
- package/dist/networks/156-9239-chunk.js +1 -0
- package/dist/networks/190-77ed-chunk.js +1 -0
- package/dist/networks/77-9e2f-chunk.js +1 -0
- package/dist/networks/Face-e375-chunk.js +1 -0
- package/dist/networks/MRZ-d498-chunk.js +1 -0
- package/dist/networks/PDF-78d2-chunk.js +1 -0
- package/dist/networks/ZXing-5410-chunk.js +1 -0
- package/dist/networks/angle03032023.onnx +0 -0
- package/dist/networks/classLocal03032023.onnx +0 -0
- package/dist/networks/faceDetection03032023.onnx +0 -0
- package/dist/networks/faceLandmark03032023.onnx +0 -0
- package/dist/networks/mrz03032023.onnx +0 -0
- package/dist/networks/ort-wasm-simd-threaded.wasm +0 -0
- package/dist/networks/ort-wasm-simd.wasm +0 -0
- package/dist/networks/ort-wasm-threaded.wasm +0 -0
- package/dist/networks/ort-wasm.wasm +0 -0
- package/package.json +24 -47
- package/dist/idvc.js.LICENSE.txt +0 -219
- package/dist/js/geometry.d.ts +0 -8
- package/dist/js/image.d.ts +0 -5
- package/dist/js/index.d.ts +0 -9
- package/dist/js/loop.d.ts +0 -21
- package/dist/js/mrz.d.ts +0 -105
- package/dist/networks/130-3968-chunk.js +0 -1
- package/dist/networks/215-cb9e-chunk.js +0 -1
- package/dist/networks/400-3816-chunk.js +0 -1
- package/dist/networks/716-d3a2-chunk.js +0 -1
- package/dist/networks/Face-4ffb-chunk.js +0 -1
- package/dist/networks/MRZ-d77b-chunk.js +0 -1
- package/dist/networks/PDF-89f3-chunk.js +0 -1
- package/dist/networks/ZXing-e76f-chunk.js +0 -1
- package/dist/networks/angles20210831.bin +0 -0
- package/dist/networks/angles20210831.json +0 -1
- package/dist/networks/asyncLoader-4593-chunk.js +0 -1
- package/dist/networks/cdnLoader-bdbc-chunk.js +0 -1
- package/dist/networks/classLocal20220112.bin +0 -0
- package/dist/networks/classLocal20220112.json +0 -1
- package/dist/networks/detectormodel20220817.bin +0 -0
- package/dist/networks/detectormodel20220817.json +0 -1
- package/dist/networks/facemesh20210831.bin +0 -0
- package/dist/networks/facemesh20210831.json +0 -1
- package/dist/networks/landmarkmodel20220817.bin +0 -0
- package/dist/networks/landmarkmodel20220817.json +0 -1
- package/dist/networks/mrz20220531.bin +0 -0
- package/dist/networks/mrz20220531.json +0 -1953
- package/dist/types/assets/images/barcode.d.ts +0 -2
- package/dist/types/assets/images/face.d.ts +0 -2
- package/dist/types/assets/images/front.d.ts +0 -2
- package/dist/types/assets/images/mrz.d.ts +0 -2
- package/dist/types/assets/images/pdf.d.ts +0 -2
- package/dist/types/bl.d.ts +0 -15
- package/dist/types/constatnts/camera.d.ts +0 -7
- package/dist/types/constatnts/imageProcessing.d.ts +0 -3
- package/dist/types/context.d.ts +0 -119
- package/dist/types/controllers/LoggerController.d.ts +0 -13
- package/dist/types/controllers/ModuleController.d.ts +0 -57
- package/dist/types/core/LicenseVerificationWasmCore.d.ts +0 -2
- package/dist/types/core/Logger.d.ts +0 -10
- package/dist/types/core/blurCore.d.ts +0 -2
- package/dist/types/core/libheif2.d.ts +0 -2
- package/dist/types/core/libmrzdecode.d.ts +0 -2
- package/dist/types/core/libpdf417.d.ts +0 -2
- package/dist/types/core/wasmpico.d.ts +0 -2
- package/dist/types/core/zxing_reader.d.ts +0 -2
- package/dist/types/custom_tfjs/custom_ops_for_converter.d.ts +0 -28
- package/dist/types/custom_tfjs/custom_tfjs.d.ts +0 -3
- package/dist/types/custom_tfjs/custom_tfjs_core.d.ts +0 -1
- package/dist/types/defaultConfig.d.ts +0 -56
- package/dist/types/environment/designations.d.ts +0 -5
- package/dist/types/environment/documentTypes.d.ts +0 -26
- package/dist/types/environment/langs.d.ts +0 -88
- package/dist/types/environment/loopResult.d.ts +0 -8
- package/dist/types/environment/realFaceModes.d.ts +0 -22
- package/dist/types/environment/stepsDescription.d.ts +0 -71
- package/dist/types/environment/triangulation.d.ts +0 -18
- package/dist/types/helpers/canvas.d.ts +0 -22
- package/dist/types/helpers/color.d.ts +0 -8
- package/dist/types/helpers/dataManipulation.d.ts +0 -27
- package/dist/types/helpers/detectLanguage.d.ts +0 -3
- package/dist/types/helpers/eventListeners.d.ts +0 -14
- package/dist/types/helpers/geometry.d.ts +0 -27
- package/dist/types/helpers/html.d.ts +0 -26
- package/dist/types/helpers/image.d.ts +0 -32
- package/dist/types/helpers/imageprocessing.d.ts +0 -11
- package/dist/types/helpers/licenceKeyError.d.ts +0 -6
- package/dist/types/helpers/logger.d.ts +0 -8
- package/dist/types/helpers/manualUpload.d.ts +0 -7
- package/dist/types/helpers/math.d.ts +0 -37
- package/dist/types/helpers/mobileChecker.d.ts +0 -15
- package/dist/types/helpers/numbers.d.ts +0 -2
- package/dist/types/helpers/step-background.d.ts +0 -2
- package/dist/types/helpers/strings.d.ts +0 -9
- package/dist/types/helpers/time.d.ts +0 -11
- package/dist/types/helpers/ts/common.d.ts +0 -3
- package/dist/types/helpers/updateSelecetTypes.d.ts +0 -2
- package/dist/types/helpers/validators.d.ts +0 -44
- package/dist/types/helpers/windowTensorFlow.d.ts +0 -7
- package/dist/types/idvc.d.ts +0 -19
- package/dist/types/initialize.d.ts +0 -11
- package/dist/types/loader/asyncLoader.d.ts +0 -2
- package/dist/types/loader/cdn/cdnFace.d.ts +0 -2
- package/dist/types/loader/cdn/cdnMRZ.d.ts +0 -4
- package/dist/types/loader/cdn/cdnPDF.d.ts +0 -4
- package/dist/types/loader/cdnLoader.d.ts +0 -2
- package/dist/types/loader/loadTf.d.ts +0 -2
- package/dist/types/loader/loaderFace.d.ts +0 -2
- package/dist/types/loader/loaderMRZ.d.ts +0 -4
- package/dist/types/loader/loaderMeshFace.d.ts +0 -3
- package/dist/types/loader/loaderPDF.d.ts +0 -3
- package/dist/types/loader/loaderSelect.d.ts +0 -2
- package/dist/types/loader/loaderUploadMode.d.ts +0 -1
- package/dist/types/loader/loaderZXing.d.ts +0 -2
- package/dist/types/loader/meshfaceConfig.d.ts +0 -3
- package/dist/types/loader/syncLoader.d.ts +0 -63
- package/dist/types/loop.d.ts +0 -13
- package/dist/types/loopControl.d.ts +0 -10
- package/dist/types/modules/BarcodeModule.d.ts +0 -28
- package/dist/types/modules/Config.d.ts +0 -131
- package/dist/types/modules/Face.d.ts +0 -61
- package/dist/types/modules/FrontProcessing.d.ts +0 -7
- package/dist/types/modules/MeshFace.d.ts +0 -52
- package/dist/types/modules/MetaData.d.ts +0 -10
- package/dist/types/modules/MrzModule.d.ts +0 -114
- package/dist/types/modules/PdfModule.d.ts +0 -79
- package/dist/types/modules/SimpleFace.d.ts +0 -18
- package/dist/types/modules/Step.d.ts +0 -65
- package/dist/types/modules/blur.d.ts +0 -4
- package/dist/types/modules/browwserCompatibilities.d.ts +0 -6
- package/dist/types/modules/camera.d.ts +0 -14
- package/dist/types/modules/cameraManager.d.ts +0 -9
- package/dist/types/modules/fileType.d.ts +0 -1
- package/dist/types/modules/frameQuality.d.ts +0 -10
- package/dist/types/modules/heic.d.ts +0 -11
- package/dist/types/modules/image.d.ts +0 -13
- package/dist/types/modules/initErrorHandler.d.ts +0 -10
- package/dist/types/modules/licenseKeyChecker.d.ts +0 -1
- package/dist/types/modules/manualUpload.d.ts +0 -7
- package/dist/types/modules/manualUploadProcessing.d.ts +0 -30
- package/dist/types/modules/mediaDevices.d.ts +0 -2
- package/dist/types/modules/moduleInitializer.d.ts +0 -8
- package/dist/types/modules/step-functions/face.d.ts +0 -2
- package/dist/types/modules/step-result-processing/barcode.d.ts +0 -2
- package/dist/types/modules/step-result-processing/common.d.ts +0 -1
- package/dist/types/modules/step-result-processing/mrz.d.ts +0 -2
- package/dist/types/modules/step-result-processing/pdf.d.ts +0 -2
- package/dist/types/modules/step-result-processing/simpleFace.d.ts +0 -2
- package/dist/types/modules/step-result-processing/volumeFace.d.ts +0 -3
- package/dist/types/modules/stepFunctions.d.ts +0 -5
- package/dist/types/modules/stepResultProcessing.d.ts +0 -9
- package/dist/types/modules/ui/Flashlight.d.ts +0 -17
- package/dist/types/modules/ui/MaskCapture.d.ts +0 -52
- package/dist/types/modules/ui/MessageBox.d.ts +0 -19
- package/dist/types/modules/ui/Modal.d.ts +0 -20
- package/dist/types/modules/ui/SelectDocumentType.d.ts +0 -45
- package/dist/types/modules/ui/forceCaptruringBtn.d.ts +0 -12
- package/dist/types/modules/ui/hints.d.ts +0 -17
- package/dist/types/modules/ui/limitations.d.ts +0 -2
- package/dist/types/modules/ui/manualSwitchBtn.d.ts +0 -30
- package/dist/types/modules/ui/spinner.d.ts +0 -13
- package/dist/types/modules/ui/swiper.d.ts +0 -3
- package/dist/types/modules/uploader.d.ts +0 -59
- package/dist/types/modules/validation/ValidateBool.d.ts +0 -5
- package/dist/types/modules/validation/ValidateDocumentTypes.d.ts +0 -20
- package/dist/types/modules/validation/ValidateElement.d.ts +0 -5
- package/dist/types/modules/validation/ValidateFunction.d.ts +0 -5
- package/dist/types/modules/validation/ValidateNumber.d.ts +0 -5
- package/dist/types/modules/validation/ValidateString.d.ts +0 -5
- package/dist/types/modules/validation/ValidateStringInArray.d.ts +0 -12
- package/dist/types/modules/validation/showValidationError.d.ts +0 -2
- package/dist/types/modules/validation/validatorFactory.d.ts +0 -10
- package/dist/types/modules/validator.d.ts +0 -10
- package/dist/types/neural models/07072019/exits.d.ts +0 -2
- package/dist/types/neural models/08072019/exits.d.ts +0 -2
- package/dist/types/neural models/09072019/exits.d.ts +0 -2
- package/dist/types/neural models/10072019/exits.d.ts +0 -2
- package/dist/types/neural models/10072019/labels.d.ts +0 -541
- package/dist/types/neural models/angles/exits.d.ts +0 -2
- package/dist/types/neural models/classLocal/exits.d.ts +0 -2
- package/dist/types/neural models/classLocalModel.d.ts +0 -9
- package/dist/types/neural models/keras/exits.d.ts +0 -2
- package/dist/types/neural models/model.d.ts +0 -18
- package/dist/types/neural models/mrz/exits.d.ts +0 -2
- package/dist/types/neural models/mrzModel.d.ts +0 -10
- package/dist/types/neural models/neuralModel.d.ts +0 -20
- package/dist/types/neural models/stick/exits.d.ts +0 -2
- package/dist/types/stepProcessing.d.ts +0 -27
- package/dist/types/types/enums/realFace.d.ts +0 -5
- package/dist/types/types/modules/camera.enum.d.ts +0 -18
- package/dist/types/ui.d.ts +0 -117
- package/dist/types/util.d.ts +0 -34
- package/dist/types/workers/blurWorker.d.ts +0 -1
- package/dist/types/workers/bubbleWorker.d.ts +0 -1
- package/dist/types/workers/loadNetworksWorker.d.ts +0 -0
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
export type StepType = 'mrz' | 'front' | 'pdf' | 'face' | 'barcode' | 'photo';
|
|
2
|
-
declare const _default: {
|
|
3
|
-
auto: {
|
|
4
|
-
id: number;
|
|
5
|
-
camera: string;
|
|
6
|
-
name: string;
|
|
7
|
-
time: number;
|
|
8
|
-
max: number;
|
|
9
|
-
core: string[];
|
|
10
|
-
description: string;
|
|
11
|
-
};
|
|
12
|
-
mrz: {
|
|
13
|
-
id: number;
|
|
14
|
-
camera: string;
|
|
15
|
-
name: string;
|
|
16
|
-
time: number;
|
|
17
|
-
core: string[];
|
|
18
|
-
description: string;
|
|
19
|
-
};
|
|
20
|
-
front: {
|
|
21
|
-
id: number;
|
|
22
|
-
camera: string;
|
|
23
|
-
name: string;
|
|
24
|
-
time: number;
|
|
25
|
-
max: number;
|
|
26
|
-
core: string[];
|
|
27
|
-
description: string;
|
|
28
|
-
};
|
|
29
|
-
pdf: {
|
|
30
|
-
id: number;
|
|
31
|
-
camera: string;
|
|
32
|
-
name: string;
|
|
33
|
-
time: number;
|
|
34
|
-
core: string[];
|
|
35
|
-
description: string;
|
|
36
|
-
};
|
|
37
|
-
back: {
|
|
38
|
-
id: number;
|
|
39
|
-
camera: string;
|
|
40
|
-
name: string;
|
|
41
|
-
time: number;
|
|
42
|
-
core: string[];
|
|
43
|
-
description: string;
|
|
44
|
-
};
|
|
45
|
-
face: {
|
|
46
|
-
id: number;
|
|
47
|
-
camera: string;
|
|
48
|
-
name: string;
|
|
49
|
-
time: number;
|
|
50
|
-
max: number;
|
|
51
|
-
core: string[];
|
|
52
|
-
description: string;
|
|
53
|
-
};
|
|
54
|
-
barcode: {
|
|
55
|
-
id: number;
|
|
56
|
-
camera: string;
|
|
57
|
-
name: string;
|
|
58
|
-
time: number;
|
|
59
|
-
core: string[];
|
|
60
|
-
description: string;
|
|
61
|
-
};
|
|
62
|
-
photo: {
|
|
63
|
-
id: number;
|
|
64
|
-
camera: string;
|
|
65
|
-
name: string;
|
|
66
|
-
time: number;
|
|
67
|
-
core: any[];
|
|
68
|
-
description: string;
|
|
69
|
-
};
|
|
70
|
-
};
|
|
71
|
-
export default _default;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2020 Google LLC. All Rights Reserved.
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* https://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
* =============================================================================
|
|
16
|
-
*/
|
|
17
|
-
export declare const TRIANGULATION: number[];
|
|
18
|
-
export default TRIANGULATION;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
type Point = [number, number];
|
|
2
|
-
type DrawPath = (ctx: CanvasRenderingContext2D, points: Point[], closePath: boolean, color: string, lineWidth?: boolean | number) => void;
|
|
3
|
-
type GetIDataFromCenter = (offsetVertical: number, offsetHorizontal: number) => ImageData;
|
|
4
|
-
export declare function getOrigData(): ImageData;
|
|
5
|
-
export declare function getResizedData(): ImageData;
|
|
6
|
-
/**
|
|
7
|
-
* returns ImageData of image offsets from center
|
|
8
|
-
* @param {number} offsetVertical
|
|
9
|
-
* @param {number} offsetHorizontal
|
|
10
|
-
* @return ImageData
|
|
11
|
-
*/
|
|
12
|
-
export declare const getIDataFromCenter: GetIDataFromCenter;
|
|
13
|
-
export declare const getBase64Data: () => string;
|
|
14
|
-
export declare const drawImageOnTestCanvas: (idata: ImageData, elId?: string) => CanvasRenderingContext2D | null;
|
|
15
|
-
export declare const drawPath: DrawPath;
|
|
16
|
-
declare const _default: {
|
|
17
|
-
getOrigData: typeof getOrigData;
|
|
18
|
-
getResizedData: typeof getResizedData;
|
|
19
|
-
getBase64Data: () => string;
|
|
20
|
-
drawPath: DrawPath;
|
|
21
|
-
};
|
|
22
|
-
export default _default;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export interface Color {
|
|
2
|
-
rgbaToGrayscale(pixels: Uint8Array | number[], rgba: number[], nrows: number, ncols: number): void;
|
|
3
|
-
}
|
|
4
|
-
export type ImageDataToBgr = (iData: ImageData) => number[];
|
|
5
|
-
export declare const rgbaToGrayscale: (pixels: Uint8Array | number[], rgba: number[], nrows: number, ncols: number) => void;
|
|
6
|
-
export declare const imageDataToBgr: ImageDataToBgr;
|
|
7
|
-
declare const _default: Color;
|
|
8
|
-
export default _default;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
interface Entity {
|
|
2
|
-
value: string;
|
|
3
|
-
name: string;
|
|
4
|
-
status: 'valid' | 'invalid';
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* convert mrz parsed data to html represent
|
|
8
|
-
* @param {Array} data - mrz parsed data
|
|
9
|
-
*/
|
|
10
|
-
export declare const mrzToHtml: (data: Entity[]) => HTMLElement;
|
|
11
|
-
/**
|
|
12
|
-
* convert pdf parsed data to html represent
|
|
13
|
-
* @param {Array} data - pdf parsed data
|
|
14
|
-
*/
|
|
15
|
-
export declare const pdfToHtml: (data: Entity[]) => HTMLElement;
|
|
16
|
-
/**
|
|
17
|
-
* convert barcode parsed data to html represent
|
|
18
|
-
* @param {String} data - barcode parsed data
|
|
19
|
-
*/
|
|
20
|
-
export declare const barcodeToHtml: (data: string) => HTMLElement;
|
|
21
|
-
/**
|
|
22
|
-
*
|
|
23
|
-
* @param {*} data - data to represent in HTML
|
|
24
|
-
* @param {String} type - type of parsed data maybe mrz|pdf|barcode
|
|
25
|
-
*/
|
|
26
|
-
declare const jsonToHtml: (data: string | Entity[], type: 'mrz' | 'pdf' | 'barcode') => false | HTMLElement;
|
|
27
|
-
export default jsonToHtml;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
type BLTemp2 = {
|
|
2
|
-
postInit: () => Promise<void>;
|
|
3
|
-
mount: (() => Promise<void>) | (() => void);
|
|
4
|
-
start: (() => Promise<void>) | (() => void);
|
|
5
|
-
changeDocumentType: (() => void) | (() => void);
|
|
6
|
-
resetAllSteps: (() => any) | (() => Promise<void>);
|
|
7
|
-
loadModules?: () => Promise<void>;
|
|
8
|
-
hereGoes?: () => Promise<void>;
|
|
9
|
-
reloadComponent: (config: any) => void;
|
|
10
|
-
showSpinner: (val: any) => void;
|
|
11
|
-
};
|
|
12
|
-
declare const addEventListeners: (bl: BLTemp2) => void;
|
|
13
|
-
export declare const clearIsListenersSet: () => void;
|
|
14
|
-
export default addEventListeners;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
export type Point = [number, number];
|
|
2
|
-
export interface ICoord {
|
|
3
|
-
x: number;
|
|
4
|
-
y: number;
|
|
5
|
-
}
|
|
6
|
-
export interface Geometry {
|
|
7
|
-
distanceBetweenPoints(p1: Point, p2: Point): number;
|
|
8
|
-
distanceBetweenPointsXoR(p1: Point, p2: Point): number;
|
|
9
|
-
sizeByTwoPoints(p1: Point, p2: Point): number;
|
|
10
|
-
rectCenter(start: Point, end: Point): Point;
|
|
11
|
-
angleBetweenTwoVectors(vector1: number[], vector2: number[]): number;
|
|
12
|
-
triangleArea(a: number, b: number, c: number): number;
|
|
13
|
-
}
|
|
14
|
-
/**
|
|
15
|
-
* calculates distance between two points
|
|
16
|
-
* @param {Number[]} p1 - first coord [x1, y1]
|
|
17
|
-
* @param {Number[]} p2 - second coord [x2, y2]
|
|
18
|
-
* @return {number}
|
|
19
|
-
*/
|
|
20
|
-
export declare const distanceBetweenPoints: (p1: Point, p2: Point) => number;
|
|
21
|
-
export declare const sizeByTwoPoints: (p1: Point, p2: Point) => number;
|
|
22
|
-
export declare const rectCenter: (start: Point, end: Point) => Point;
|
|
23
|
-
export declare const angleBetweenTwoVectors: (vector1: number[], vector2: number[]) => number;
|
|
24
|
-
export declare const distanceBetweenPointsXoR: (p1: Point, p2: Point) => number;
|
|
25
|
-
export declare const triangleArea: (a: number, b: number, c: number) => number;
|
|
26
|
-
declare const geometry: Geometry;
|
|
27
|
-
export default geometry;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
interface AttributeCollection {
|
|
2
|
-
[name: string]: string | boolean;
|
|
3
|
-
}
|
|
4
|
-
type CreateElement = (tagName?: string, params?: AttributeCollection | null, classNames?: string[], parent?: HTMLElement | null, children?: HTMLElement[]) => HTMLElement;
|
|
5
|
-
/**
|
|
6
|
-
* create and return HTMLElement
|
|
7
|
-
* @param { String } tagName - default 'div'
|
|
8
|
-
* @param { AttributeCollection | null } params
|
|
9
|
-
* @param { Array<String> } classNames - array of class names
|
|
10
|
-
* @param { HTMLElement } parent - element to which needs append created element
|
|
11
|
-
* @param { Array<HTMLElement> } children - elements which will appended to created element
|
|
12
|
-
* @returns { HTMLElement } - created element
|
|
13
|
-
*/
|
|
14
|
-
export declare const createElement: CreateElement;
|
|
15
|
-
/**
|
|
16
|
-
* creates a script tag
|
|
17
|
-
* @param {string} scriptUrl - url to remote script
|
|
18
|
-
* @param {'module'} type - create script as module
|
|
19
|
-
* @return {Promise<unknown>}
|
|
20
|
-
*/
|
|
21
|
-
export declare const loadScript: (scriptUrl: string) => Promise<unknown>;
|
|
22
|
-
declare const _default: {
|
|
23
|
-
createElement: CreateElement;
|
|
24
|
-
loadScript: (scriptUrl: string) => Promise<unknown>;
|
|
25
|
-
};
|
|
26
|
-
export default _default;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
export type Base64Image = string;
|
|
2
|
-
export type RGBAColor = string;
|
|
3
|
-
type PixelPosition = number;
|
|
4
|
-
type Segmentize = (binarizedImg: Uint8ClampedArray, width: number) => Set<PixelPosition>[];
|
|
5
|
-
type Binarize = (img: ImageData, threshold?: number) => Uint8ClampedArray;
|
|
6
|
-
type GetResizedSizes = (size: number, baseSize: IBaseSize) => ISize;
|
|
7
|
-
export interface IOffset {
|
|
8
|
-
top: number;
|
|
9
|
-
left: number;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* { width: number, height: number }
|
|
13
|
-
*/
|
|
14
|
-
export interface ISize {
|
|
15
|
-
width: number;
|
|
16
|
-
height: number;
|
|
17
|
-
}
|
|
18
|
-
interface IBaseSize {
|
|
19
|
-
baseWidth: number;
|
|
20
|
-
baseHeight: number;
|
|
21
|
-
}
|
|
22
|
-
export declare const getResizedSizes: GetResizedSizes;
|
|
23
|
-
export declare const generateFaceColorFromAngle: (angle: number) => RGBAColor;
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @param {ImageData} iData
|
|
27
|
-
* @param {number} threshold
|
|
28
|
-
* @return number[] - black and whited array;
|
|
29
|
-
*/
|
|
30
|
-
export declare const binarize: Binarize;
|
|
31
|
-
export declare const segmentize2: Segmentize;
|
|
32
|
-
export {};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { ILoopResult } from '../environment/loopResult';
|
|
2
|
-
declare const _default: {
|
|
3
|
-
processImage4: () => {
|
|
4
|
-
status: boolean;
|
|
5
|
-
cancel: boolean;
|
|
6
|
-
touch: boolean;
|
|
7
|
-
image: ImageData;
|
|
8
|
-
};
|
|
9
|
-
processImage5: (sideDetect?: boolean) => ILoopResult;
|
|
10
|
-
};
|
|
11
|
-
export default _default;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
export declare const resizeImageForStepProcessing: (data: any) => Promise<ImageData>;
|
|
2
|
-
declare const _default: {
|
|
3
|
-
getSmallImage: (data: string) => Promise<ImageData>;
|
|
4
|
-
setCurrentImage: (data: any) => Promise<void>;
|
|
5
|
-
fixOrientation: (image: HTMLImageElement) => Promise<ImageData>;
|
|
6
|
-
};
|
|
7
|
-
export default _default;
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Compute the mean value of values or a list with values.
|
|
3
|
-
* @param {number[]|number} args - (a, b, c) or []
|
|
4
|
-
* @returns {number}
|
|
5
|
-
*/
|
|
6
|
-
export declare const mean: (...args: number[] | [
|
|
7
|
-
number[]
|
|
8
|
-
]) => number;
|
|
9
|
-
type NormalizationFunctionNames = 'unbiased' | 'biased' | 'uncorrected';
|
|
10
|
-
export declare const normalizationFunction: {
|
|
11
|
-
unbiased: (arr: number[]) => number;
|
|
12
|
-
biased: (arr: number[]) => number;
|
|
13
|
-
uncorrected: (arr: number[]) => number;
|
|
14
|
-
};
|
|
15
|
-
/**
|
|
16
|
-
* calculate standard deviation or return -1
|
|
17
|
-
* @param {Number[]} vals
|
|
18
|
-
* @param {'unbiased'|'biased'|'uncorrected'} normalization - 'unbiased' - divide by n - 1,
|
|
19
|
-
* 'uncorrected' - divide by n,
|
|
20
|
-
* 'biased' - divide by n + 1. default 'unbiased'.
|
|
21
|
-
* @param {number} fixed - how many digits after the decimal.
|
|
22
|
-
* @return number -1 if input values are wrong
|
|
23
|
-
*/
|
|
24
|
-
export declare const STD: (vals: number[], normalization?: NormalizationFunctionNames, fixed?: number) => number;
|
|
25
|
-
/**
|
|
26
|
-
* get random integer number from range, included min and max
|
|
27
|
-
* @param {number} min
|
|
28
|
-
* @param {number} max
|
|
29
|
-
* @return {number}
|
|
30
|
-
*/
|
|
31
|
-
export declare const randomIntFromInterval: (min: number, max: number) => number;
|
|
32
|
-
declare const _default: {
|
|
33
|
-
randomIntFromInterval: (min: number, max: number) => number;
|
|
34
|
-
mean: (...args: number[] | [number[]]) => number;
|
|
35
|
-
STD: (vals: number[], normalization?: NormalizationFunctionNames, fixed?: number) => number;
|
|
36
|
-
};
|
|
37
|
-
export default _default;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export declare const isiOS: () => boolean;
|
|
2
|
-
export declare const checkTouchPoints: () => boolean;
|
|
3
|
-
export declare const checkIsTouchScreen: () => boolean;
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
* @param {Number} maxWidth - preferable max width device
|
|
7
|
-
*/
|
|
8
|
-
export declare const isMobile: () => {
|
|
9
|
-
isMobileUserAgent: () => boolean;
|
|
10
|
-
isTouchable: () => boolean;
|
|
11
|
-
isTouchScreen: () => boolean;
|
|
12
|
-
isSurface: () => boolean;
|
|
13
|
-
};
|
|
14
|
-
declare const checkIfMobile: () => boolean;
|
|
15
|
-
export default checkIfMobile;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Base64Image } from './image';
|
|
2
|
-
export declare const encodeMeta: (metadata: any) => string;
|
|
3
|
-
export declare const decodeMeta: (str: string) => any;
|
|
4
|
-
export declare const base64ToArrayBuffer: (base64: string) => Uint8Array;
|
|
5
|
-
export declare const getDataFromBase64Img: (imgString: Base64Image) => string;
|
|
6
|
-
export declare const splitWordByUpperLetters: (word: string) => string[];
|
|
7
|
-
export declare const normalizeCamelCase: (word: string) => string;
|
|
8
|
-
export declare const removeHtmlEntities: (str: string) => string;
|
|
9
|
-
export declare const normalizeString: (str: string) => string;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {number} ms
|
|
4
|
-
* @returns {Promise<>}
|
|
5
|
-
*/
|
|
6
|
-
export declare const timeout: (ms: number) => Promise<unknown>;
|
|
7
|
-
export declare const nextFrame: (fn?: () => Promise<any> | void) => Promise<unknown>;
|
|
8
|
-
declare const _default: {
|
|
9
|
-
timeout: (ms: number) => Promise<unknown>;
|
|
10
|
-
};
|
|
11
|
-
export default _default;
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* check value to be boolean
|
|
3
|
-
* @param val
|
|
4
|
-
* @return {boolean}
|
|
5
|
-
*/
|
|
6
|
-
export declare const isValidBool: (val: any) => boolean;
|
|
7
|
-
/**
|
|
8
|
-
* check value to be object
|
|
9
|
-
* @param val
|
|
10
|
-
* @return {boolean}
|
|
11
|
-
*/
|
|
12
|
-
export declare const isValidObject: (val: any) => boolean;
|
|
13
|
-
/**
|
|
14
|
-
* check value to be function
|
|
15
|
-
* @param val
|
|
16
|
-
* @return {boolean}
|
|
17
|
-
*/
|
|
18
|
-
export declare const isValidFunction: (val: any) => boolean;
|
|
19
|
-
/**
|
|
20
|
-
* check value to be string
|
|
21
|
-
* @param val
|
|
22
|
-
* @return {boolean}
|
|
23
|
-
*/
|
|
24
|
-
export declare const isValidString: (val: any) => boolean;
|
|
25
|
-
/**
|
|
26
|
-
* check value to be finite number
|
|
27
|
-
* @param val
|
|
28
|
-
* @return {boolean}
|
|
29
|
-
*/
|
|
30
|
-
export declare const isValidNumber: (val: any) => boolean;
|
|
31
|
-
/**
|
|
32
|
-
* validates string in given array and set its value
|
|
33
|
-
* @param {String[]} availableValues - array of available values
|
|
34
|
-
* @param {String} valueToSet - value that should be set
|
|
35
|
-
*/
|
|
36
|
-
export declare const isValidDistinctStringInArray: (availableValues: string[], valueToSet: string) => boolean;
|
|
37
|
-
declare const _default: {
|
|
38
|
-
isValidBool: (val: any) => boolean;
|
|
39
|
-
isValidFunction: (val: any) => boolean;
|
|
40
|
-
isValidString: (val: any) => boolean;
|
|
41
|
-
isValidNumber: (val: any) => boolean;
|
|
42
|
-
isValidDistinctStringInArray: (availableValues: string[], valueToSet: string) => boolean;
|
|
43
|
-
};
|
|
44
|
-
export default _default;
|
package/dist/types/idvc.d.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import './assets/scss/index.scss';
|
|
2
|
-
import { IConfig } from './modules/Config';
|
|
3
|
-
import { SupportedLanguage } from './environment/langs';
|
|
4
|
-
import { IDocumentTypeConfig } from './modules/validator';
|
|
5
|
-
declare class VideoCapturing {
|
|
6
|
-
constructor(config: IConfig);
|
|
7
|
-
private init;
|
|
8
|
-
/**
|
|
9
|
-
*
|
|
10
|
-
* @param language
|
|
11
|
-
*/
|
|
12
|
-
changeLanguage(language: SupportedLanguage): void;
|
|
13
|
-
get version(): string;
|
|
14
|
-
resetAllSteps(): void;
|
|
15
|
-
reloadComponent(newConfig: Partial<IConfig>): void;
|
|
16
|
-
updateDocumentTypes(documentTypes: IDocumentTypeConfig): void;
|
|
17
|
-
showSpinner(val: any): void;
|
|
18
|
-
}
|
|
19
|
-
export default VideoCapturing;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export declare const typesInit: () => void;
|
|
2
|
-
declare const _default: {
|
|
3
|
-
typesInit: () => void;
|
|
4
|
-
checkCompatibility: () => void;
|
|
5
|
-
start: () => void;
|
|
6
|
-
isCameraRequired: () => any;
|
|
7
|
-
isUploaderRequired: () => any;
|
|
8
|
-
isCameraNeeded: () => any;
|
|
9
|
-
detectAndSetBrowser: () => void;
|
|
10
|
-
};
|
|
11
|
-
export default _default;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const loadNetworksUploadMode: () => Promise<void>;
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { StepType } from '../environment/stepsDescription';
|
|
2
|
-
import Step from '../modules/Step';
|
|
3
|
-
type TFCore = (steps: Step[]) => Promise<void>;
|
|
4
|
-
type FaceCore = () => Promise<{
|
|
5
|
-
face: null | any;
|
|
6
|
-
}>;
|
|
7
|
-
type MrzCore = () => Promise<{
|
|
8
|
-
mrz: any;
|
|
9
|
-
}>;
|
|
10
|
-
type PdfCore = () => Promise<{
|
|
11
|
-
pdf: any;
|
|
12
|
-
}>;
|
|
13
|
-
type BarcodeCore = () => Promise<{
|
|
14
|
-
barcode: any;
|
|
15
|
-
}>;
|
|
16
|
-
type HeicCore = () => Promise<{
|
|
17
|
-
heic: any;
|
|
18
|
-
}>;
|
|
19
|
-
type BlurCore = () => Promise<{
|
|
20
|
-
blur: any;
|
|
21
|
-
}>;
|
|
22
|
-
type CoreFunctions = {
|
|
23
|
-
tf: TFCore;
|
|
24
|
-
face: FaceCore;
|
|
25
|
-
mrz: MrzCore;
|
|
26
|
-
pdf: PdfCore;
|
|
27
|
-
barcode: BarcodeCore;
|
|
28
|
-
heic: HeicCore;
|
|
29
|
-
blur: BlurCore;
|
|
30
|
-
};
|
|
31
|
-
type CoreName = StepType | 'heic' | 'blur';
|
|
32
|
-
export declare const loadAnglesModel: () => Promise<void>;
|
|
33
|
-
export declare const loadClassLocalModel: () => Promise<void>;
|
|
34
|
-
/**
|
|
35
|
-
*
|
|
36
|
-
* @param {StepConfig[]} steps
|
|
37
|
-
* @return {Promise<void>}
|
|
38
|
-
*/
|
|
39
|
-
export declare const tfCore: TFCore;
|
|
40
|
-
export declare const faceCore: FaceCore;
|
|
41
|
-
export declare const mrzCore: MrzCore;
|
|
42
|
-
export declare const pdfCore: PdfCore;
|
|
43
|
-
export declare const heicCore: HeicCore;
|
|
44
|
-
export declare const barcodeCore: BarcodeCore;
|
|
45
|
-
export declare const blurCore: BlurCore;
|
|
46
|
-
export declare const faceMeshCore: () => Promise<void>;
|
|
47
|
-
export declare const faceModuleLoader: (core: any) => Promise<void>;
|
|
48
|
-
export declare const mrzModuleLoad: (core: any) => Promise<void>;
|
|
49
|
-
export declare const pdfModuleLoad: (core: any) => Promise<void>;
|
|
50
|
-
export declare const barcodeModule: (core: any) => Promise<void>;
|
|
51
|
-
export declare const heicModule: (core: any) => Promise<void>;
|
|
52
|
-
export declare const blurModule: (core: any) => Promise<void>;
|
|
53
|
-
export declare const coreFunctions: CoreFunctions;
|
|
54
|
-
export declare const loadCores: (coreNames: CoreName[], steps: Step[]) => Array<Promise<any> | false>;
|
|
55
|
-
export declare const coreObjectSimplify: (coreObject: any) => {
|
|
56
|
-
name: string;
|
|
57
|
-
core: any;
|
|
58
|
-
}[];
|
|
59
|
-
export declare const initModule: (coreObject: any) => any;
|
|
60
|
-
export declare const loadModules: (cores: any[]) => any[];
|
|
61
|
-
export declare const coreNamesFromSteps: (steps: Step[]) => StepType[];
|
|
62
|
-
export declare const syncLoader: (steps?: Step[], useUI?: boolean) => Promise<void>;
|
|
63
|
-
export default syncLoader;
|
package/dist/types/loop.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { IMRZLocation } from './modules/manualUploadProcessing';
|
|
2
|
-
import { Cancel } from './types/loop';
|
|
3
|
-
export interface IMrzCoords {
|
|
4
|
-
locations: IMRZLocation;
|
|
5
|
-
color: 'green' | 'yellow';
|
|
6
|
-
}
|
|
7
|
-
export declare const loop: () => Promise<false>;
|
|
8
|
-
declare const _default: {
|
|
9
|
-
loop: () => Promise<false>;
|
|
10
|
-
stopProccesing: () => void;
|
|
11
|
-
cancel: Cancel;
|
|
12
|
-
};
|
|
13
|
-
export default _default;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export declare const setIsStarted: (val: boolean) => void;
|
|
2
|
-
export declare const stop: () => void;
|
|
3
|
-
export declare const setVisibleVideo: () => Promise<void>;
|
|
4
|
-
export declare const start: () => Promise<void>;
|
|
5
|
-
declare const _default: {
|
|
6
|
-
start: () => Promise<void>;
|
|
7
|
-
stop: () => void;
|
|
8
|
-
setIsStarted: (val: boolean) => void;
|
|
9
|
-
};
|
|
10
|
-
export default _default;
|