@ekyc_qoobiss/qbs-ect-cmp 3.6.14 → 3.6.16
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/cjs/{Stream-097bd1e9.js → agreement-check_19.cjs.entry.js} +5238 -529
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/qbs-ect-cmp.cjs.js +1 -1
- package/dist/cjs/random-actions.cjs.entry.js +22 -0
- package/dist/cjs/store-ab631a7a.js +415 -0
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/common/capture-error/capture-error.js +6 -1
- package/dist/collection/components/common/id-back-capture/id-back-capture.js +2 -4
- package/dist/collection/components/common/id-capture/id-capture.js +2 -4
- package/dist/collection/components/common/id-tilt/id-tilt.js +3 -5
- package/dist/collection/components/common/random-actions/random-actions.js +20 -0
- package/dist/collection/components/common/selfie-capture/selfie-capture.js +3 -27
- package/dist/collection/components/common/selfie-tilt/selfie-tilt.css +7 -0
- package/dist/collection/components/common/selfie-tilt/selfie-tilt.js +212 -0
- package/dist/collection/components/flow/process-id/process-id.js +31 -28
- package/dist/collection/components/flow/user-liveness/user-liveness.js +87 -40
- package/dist/collection/helpers/Stream.js +1 -1
- package/dist/collection/libs/FaceML5Detector/FaceML5Detector.js +18 -15
- package/dist/collection/models/CaptureFlow.js +17 -9
- package/dist/collection/models/FlowSteps.js +3 -6
- package/dist/esm/{Stream-d1fb2210.js → agreement-check_19.entry.js} +5131 -420
- package/dist/esm/loader.js +1 -1
- package/dist/esm/qbs-ect-cmp.js +1 -1
- package/dist/esm/random-actions.entry.js +18 -0
- package/dist/esm/store-b5192087.js +399 -0
- package/dist/qbs-ect-cmp/{p-73a2e58b.js → p-094ad8f3.entry.js} +26 -26
- package/dist/qbs-ect-cmp/p-927cd530.entry.js +1 -0
- package/dist/qbs-ect-cmp/p-a6506178.js +1 -0
- package/dist/qbs-ect-cmp/qbs-ect-cmp.esm.js +1 -1
- package/dist/types/components/common/capture-error/capture-error.d.ts +3 -1
- package/dist/types/components/common/random-actions/random-actions.d.ts +7 -0
- package/dist/types/components/common/selfie-capture/selfie-capture.d.ts +0 -1
- package/dist/types/components/common/selfie-tilt/selfie-tilt.d.ts +30 -0
- package/dist/types/components/flow/user-liveness/user-liveness.d.ts +4 -4
- package/dist/types/components.d.ts +33 -37
- package/dist/types/libs/FaceML5Detector/FaceML5Detector.d.ts +3 -2
- package/dist/types/models/CaptureFlow.d.ts +8 -1
- package/dist/types/models/FlowSteps.d.ts +3 -6
- package/package.json +1 -1
- package/dist/cjs/agreement-check_18.cjs.entry.js +0 -4971
- package/dist/cjs/id-double-side.cjs.entry.js +0 -208
- package/dist/cjs/id-single-side.cjs.entry.js +0 -147
- package/dist/collection/components/flow/id-double-side/id-double-side.js +0 -285
- package/dist/collection/components/flow/id-single-side/id-single-side.css +0 -0
- package/dist/collection/components/flow/id-single-side/id-single-side.js +0 -216
- package/dist/esm/agreement-check_18.entry.js +0 -4950
- package/dist/esm/id-double-side.entry.js +0 -204
- package/dist/esm/id-single-side.entry.js +0 -143
- package/dist/qbs-ect-cmp/p-04e51eac.entry.js +0 -1
- package/dist/qbs-ect-cmp/p-deea462b.entry.js +0 -1
- package/dist/qbs-ect-cmp/p-f84883f8.entry.js +0 -1
- package/dist/types/components/flow/id-double-side/id-double-side.d.ts +0 -29
- package/dist/types/components/flow/id-single-side/id-single-side.d.ts +0 -24
- /package/dist/collection/components/{flow/id-double-side/id-double-side.css → common/random-actions/random-actions.css} +0 -0
|
@@ -9,6 +9,7 @@ import face_green_svg from '../../assets/canvas-masks/face_green.svg';
|
|
|
9
9
|
import { GlobalValues } from '../../helpers/textValues';
|
|
10
10
|
import store from '../../helpers/store';
|
|
11
11
|
import { delay } from '../../utils/utils';
|
|
12
|
+
import { VerificationMode } from '../../models/IVerificationMode';
|
|
12
13
|
export class FaceML5Detector {
|
|
13
14
|
static getInstance(stream, isMobile) {
|
|
14
15
|
if (!FaceML5Detector.instance) {
|
|
@@ -25,7 +26,7 @@ export class FaceML5Detector {
|
|
|
25
26
|
this.requestedFacePose = null;
|
|
26
27
|
this.presentedFacePose = null;
|
|
27
28
|
this.validFacePose = false;
|
|
28
|
-
this.
|
|
29
|
+
this.checkPose = false;
|
|
29
30
|
this.MAX_NUMBER_FACES = 1;
|
|
30
31
|
this.MIN_FACE_SCORE = 0.65;
|
|
31
32
|
// private readonly MIN_FACE_SIZE_FOR_MOBILE = 200;
|
|
@@ -43,9 +44,10 @@ export class FaceML5Detector {
|
|
|
43
44
|
this.canvasElement = canvasElement;
|
|
44
45
|
// this.component = component;
|
|
45
46
|
}
|
|
46
|
-
initDetector() {
|
|
47
|
+
initDetector(mode) {
|
|
47
48
|
this.initTime = Date.now();
|
|
48
49
|
this.continue = true;
|
|
50
|
+
this.checkPose = mode == VerificationMode.Tilt;
|
|
49
51
|
this.width = this.videoElement.videoWidth;
|
|
50
52
|
this.height = this.videoElement.videoHeight;
|
|
51
53
|
// this.videoRatio = getVideoRatio(this.videoElement);
|
|
@@ -53,7 +55,7 @@ export class FaceML5Detector {
|
|
|
53
55
|
delay(2000).then(() => this.detectFaces());
|
|
54
56
|
}
|
|
55
57
|
detectFaces() {
|
|
56
|
-
if (this.
|
|
58
|
+
if (this.validFaceFound) {
|
|
57
59
|
if (this.start == null)
|
|
58
60
|
this.start = Date.now();
|
|
59
61
|
if (Date.now() > this.start + 3000) {
|
|
@@ -79,17 +81,19 @@ export class FaceML5Detector {
|
|
|
79
81
|
return;
|
|
80
82
|
}
|
|
81
83
|
if (results.length > 0) {
|
|
82
|
-
if (this.
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
84
|
+
if (this.checkPose) {
|
|
85
|
+
this.requestedFacePose = this.stream.requestFacePose();
|
|
86
|
+
await this.checkFacePose(results);
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
if (this.isSingleFace(results) && this.checkProbability(results) && this.checkFaceSize(results) && this.checkFaceIndent(results)) {
|
|
90
|
+
if (!this.validFaceFound) {
|
|
91
|
+
this.validFaceFound = true;
|
|
92
|
+
this.stream.autoCapturing();
|
|
93
|
+
// this.frontFace = new FaceLandmarks(results[0], this.width, this.height);
|
|
94
|
+
await this.drawFrame('green');
|
|
95
|
+
await delay(GlobalValues.VideoLenght);
|
|
96
|
+
}
|
|
93
97
|
}
|
|
94
98
|
}
|
|
95
99
|
}
|
|
@@ -210,7 +214,6 @@ export class FaceML5Detector {
|
|
|
210
214
|
if (this.requestedFacePose !== null) {
|
|
211
215
|
await delay(3000);
|
|
212
216
|
this.validFacePose = true;
|
|
213
|
-
this.validFaceFoundAgain = true;
|
|
214
217
|
await this.drawFrame('green', true);
|
|
215
218
|
}
|
|
216
219
|
}
|
|
@@ -4,17 +4,25 @@ export var CaptureUploadTypes;
|
|
|
4
4
|
CaptureUploadTypes["IdBack"] = "IdBack";
|
|
5
5
|
CaptureUploadTypes["IdFrontVideo"] = "IdFrontVideo";
|
|
6
6
|
CaptureUploadTypes["IdBackVideo"] = "IdBackVideo";
|
|
7
|
+
CaptureUploadTypes["Selfie"] = "Selfie";
|
|
7
8
|
CaptureUploadTypes["SelfieVideo"] = "SelfieVideo";
|
|
8
9
|
CaptureUploadTypes["SelfieGestureVideo"] = "SelfieGestureVideo";
|
|
9
10
|
CaptureUploadTypes["TiltVideo"] = "TiltVideo";
|
|
10
11
|
CaptureUploadTypes["None"] = "None";
|
|
11
12
|
})(CaptureUploadTypes || (CaptureUploadTypes = {}));
|
|
12
|
-
export var
|
|
13
|
-
(function (
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
})(
|
|
13
|
+
export var IdCaptureFlowStatus;
|
|
14
|
+
(function (IdCaptureFlowStatus) {
|
|
15
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["HowToFront"] = 0] = "HowToFront";
|
|
16
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["IdFront"] = 1] = "IdFront";
|
|
17
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["HowToBack"] = 2] = "HowToBack";
|
|
18
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["IdBack"] = 3] = "IdBack";
|
|
19
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["Tilt"] = 4] = "Tilt";
|
|
20
|
+
IdCaptureFlowStatus[IdCaptureFlowStatus["End"] = 5] = "End";
|
|
21
|
+
})(IdCaptureFlowStatus || (IdCaptureFlowStatus = {}));
|
|
22
|
+
export var SelfieFlowStatus;
|
|
23
|
+
(function (SelfieFlowStatus) {
|
|
24
|
+
SelfieFlowStatus[SelfieFlowStatus["HowToSelfie"] = 0] = "HowToSelfie";
|
|
25
|
+
SelfieFlowStatus[SelfieFlowStatus["Selfie"] = 1] = "Selfie";
|
|
26
|
+
SelfieFlowStatus[SelfieFlowStatus["Gesture"] = 2] = "Gesture";
|
|
27
|
+
SelfieFlowStatus[SelfieFlowStatus["End"] = 3] = "End";
|
|
28
|
+
})(SelfieFlowStatus || (SelfieFlowStatus = {}));
|
|
@@ -8,20 +8,17 @@ export var FlowSteps;
|
|
|
8
8
|
FlowSteps[FlowSteps["OtpCheck"] = 'otp-check'] = "OtpCheck";
|
|
9
9
|
FlowSteps[FlowSteps["CiFront"] = 'ci-front'] = "CiFront";
|
|
10
10
|
FlowSteps[FlowSteps["CiFrontHowTo"] = 'ci-front-how-to'] = "CiFrontHowTo";
|
|
11
|
-
FlowSteps[FlowSteps["CiFrontHoldAnimation"] = 'ci-front-hold-animation'] = "CiFrontHoldAnimation";
|
|
12
|
-
FlowSteps[FlowSteps["CiFrontTiltAnimation"] = 'ci-front-tilt-animation'] = "CiFrontTiltAnimation";
|
|
13
11
|
FlowSteps[FlowSteps["CiFrontCapture"] = 'ci-front-capture'] = "CiFrontCapture";
|
|
14
12
|
FlowSteps[FlowSteps["CiBack"] = 'ci-back'] = "CiBack";
|
|
15
13
|
FlowSteps[FlowSteps["CiBackHowTo"] = 'ci-back-how-to'] = "CiBackHowTo";
|
|
16
|
-
FlowSteps[FlowSteps["CiBackHoldAnimation"] = 'ci-back-hold-animation'] = "CiBackHoldAnimation";
|
|
17
|
-
FlowSteps[FlowSteps["CiBackTiltAnimation"] = 'ci-back-tilt-animation'] = "CiBackTiltAnimation";
|
|
18
14
|
FlowSteps[FlowSteps["CiBackCapture"] = 'ci-back-capture'] = "CiBackCapture";
|
|
19
15
|
FlowSteps[FlowSteps["CiTilt"] = 'ci-tilt'] = "CiTilt";
|
|
16
|
+
FlowSteps[FlowSteps["CiError"] = 'ci-error'] = "CiError";
|
|
20
17
|
FlowSteps[FlowSteps["SelfieHowTo"] = 'selfie-how-to'] = "SelfieHowTo";
|
|
21
|
-
FlowSteps[FlowSteps["
|
|
22
|
-
FlowSteps[FlowSteps["SelfieTiltAnimation"] = 'selfie-tilt-animation'] = "SelfieTiltAnimation";
|
|
18
|
+
FlowSteps[FlowSteps["SelfieTilt"] = 'selfie-tilt'] = "SelfieTilt";
|
|
23
19
|
FlowSteps[FlowSteps["SelfieCapture"] = 'selfie-capture'] = "SelfieCapture";
|
|
24
20
|
FlowSteps[FlowSteps["Selfie"] = 'selfie'] = "Selfie";
|
|
21
|
+
FlowSteps[FlowSteps["SelfieError"] = 'selfie-error'] = "SelfieError";
|
|
25
22
|
FlowSteps[FlowSteps["End"] = 'end'] = "End";
|
|
26
23
|
FlowSteps[FlowSteps["CameraError"] = 'camera-error'] = "CameraError";
|
|
27
24
|
})(FlowSteps || (FlowSteps = {}));
|