idmission-web-sdk 2.1.34 → 2.1.35
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/components/customer_flows/CustomerIdAndBiometricsEnrollment.d.ts +4 -0
- package/dist/components/customer_flows/IdAndFaceValidation.d.ts +4 -0
- package/dist/components/customer_flows/IdValidation.d.ts +4 -0
- package/dist/components/id_capture/IdCaptureStateProvider.d.ts +4 -0
- package/dist/components/id_capture/IdCaptureWizard.d.ts +3 -1
- package/dist/sdk2.cjs.development.js +149 -119
- package/dist/sdk2.cjs.development.js.map +1 -1
- package/dist/sdk2.cjs.production.js +1 -1
- package/dist/sdk2.cjs.production.js.map +1 -1
- package/dist/sdk2.esm.js +149 -119
- package/dist/sdk2.esm.js.map +1 -1
- package/dist/sdk2.umd.development.js +149 -119
- package/dist/sdk2.umd.development.js.map +1 -1
- package/dist/sdk2.umd.production.js +1 -1
- package/dist/sdk2.umd.production.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -118,6 +118,10 @@ export interface CustomerEnrollmentProps extends PropsWithChildren {
|
|
|
118
118
|
selfieCaptureModelLoadTimeoutMs?: number;
|
|
119
119
|
/** Boolean to indicate whether to allow the user to capture the back of the ID card before capturing the front. Defaults to `false`. */
|
|
120
120
|
allowIdCardBackToFrontCapture?: boolean;
|
|
121
|
+
/** Boolean to indicate whether to show the user a dialog to disable the wrong document type guidance after a configurable amount of time. Defaults to `false`. */
|
|
122
|
+
enableOverrideWrongDocumentTypeDialog?: boolean;
|
|
123
|
+
/** Number of milliseconds to wait before showing the user a dialog to disable the wrong document type guidance. Defaults to `8000`. */
|
|
124
|
+
allowOverrideWrongDocumentTypeAfterMs?: number;
|
|
121
125
|
/** Callback function that fires immediately prior to each document upload, giving the client application an opportunity to specify custom asynchronous logic that captures the document contents before it is exchanged for a document token. The document content and metadata are passed in as parameters and a promise resolving to void or false should be returned. If the returned promise resolves to false, the document will not be uploaded. */
|
|
122
126
|
onBeforeDocumentUpload?: OnBeforeDocumentUpload;
|
|
123
127
|
/** Callback function that fires when progress information is available for a document upload. The progress info and metadata are passed in as parameters. */
|
|
@@ -115,6 +115,10 @@ export interface IdAndFaceValidationProps extends PropsWithChildren {
|
|
|
115
115
|
selfieCaptureModelLoadTimeoutMs?: number;
|
|
116
116
|
/** Boolean to indicate whether to allow the user to capture the back of the ID card before capturing the front. Defaults to `false`. */
|
|
117
117
|
allowIdCardBackToFrontCapture?: boolean;
|
|
118
|
+
/** Boolean to indicate whether to show the user a dialog to disable the wrong document type guidance after a configurable amount of time. Defaults to `false`. */
|
|
119
|
+
enableOverrideWrongDocumentTypeDialog?: boolean;
|
|
120
|
+
/** Number of milliseconds to wait before showing the user a dialog to disable the wrong document type guidance. Defaults to `8000`. */
|
|
121
|
+
allowOverrideWrongDocumentTypeAfterMs?: number;
|
|
118
122
|
/** Callback function that fires immediately prior to each document upload, giving the client application an opportunity to specify custom asynchronous logic that captures the document contents before it is exchanged for a document token. The document content and metadata are passed in as parameters and a promise resolving to void or false should be returned. If the returned promise resolves to false, the document will not be uploaded. */
|
|
119
123
|
onBeforeDocumentUpload?: OnBeforeDocumentUpload;
|
|
120
124
|
/** Callback function that fires when progress information is available for a document upload. The progress info and metadata are passed in as parameters. */
|
|
@@ -100,6 +100,10 @@ export interface IdValidationProps extends PropsWithChildren {
|
|
|
100
100
|
forceFallbackMode?: boolean;
|
|
101
101
|
/** Boolean to indicate whether to allow the user to capture the back of the ID card before capturing the front. Defaults to `false`. */
|
|
102
102
|
allowIdCardBackToFrontCapture?: boolean;
|
|
103
|
+
/** Boolean to indicate whether to show the user a dialog to disable the wrong document type guidance after a configurable amount of time. Defaults to `false`. */
|
|
104
|
+
enableOverrideWrongDocumentTypeDialog?: boolean;
|
|
105
|
+
/** Number of milliseconds to wait before showing the user a dialog to disable the wrong document type guidance. Defaults to `8000`. */
|
|
106
|
+
allowOverrideWrongDocumentTypeAfterMs?: number;
|
|
103
107
|
/** Object to allow documents that have been previously captured to be submitted. Valid keys: `idCardFront`, `idCardBack`, `passport`.*/
|
|
104
108
|
precapturedDocuments?: CapturedDocuments;
|
|
105
109
|
/** Callback function that fires immediately prior to each document upload, giving the client application an opportunity to specify custom asynchronous logic that captures the document contents before it is exchanged for a document token. The document content and metadata are passed in as parameters and a promise resolving to void or false should be returned. If the returned promise resolves to false, the document will not be uploaded. */
|
|
@@ -27,6 +27,8 @@ export type IdCaptureState = {
|
|
|
27
27
|
documentTooClose: boolean;
|
|
28
28
|
flipRequired: boolean;
|
|
29
29
|
backDetectedFirst: boolean;
|
|
30
|
+
enableOverrideWrongDocumentTypeDialog: boolean;
|
|
31
|
+
allowOverrideWrongDocumentTypeAfterMs: number;
|
|
30
32
|
allowOverrideFlipRequirement: boolean;
|
|
31
33
|
overrideFlipRequirement: boolean;
|
|
32
34
|
wrongDocumentTypePredictions: number;
|
|
@@ -61,6 +63,8 @@ export type IdCaptureAction = {
|
|
|
61
63
|
captureRequirement: IdCaptureRequirementOption;
|
|
62
64
|
precapturedDocuments?: CapturedDocuments;
|
|
63
65
|
allowIdCardBackToFrontCapture?: boolean;
|
|
66
|
+
enableOverrideWrongDocumentTypeDialog: boolean;
|
|
67
|
+
allowOverrideWrongDocumentTypeAfterMs: number;
|
|
64
68
|
};
|
|
65
69
|
} | {
|
|
66
70
|
type: 'setRequiredDocumentType';
|
|
@@ -65,10 +65,12 @@ export type IdCaptureWizardProps = {
|
|
|
65
65
|
silentFallback?: boolean;
|
|
66
66
|
forceFallbackMode?: boolean;
|
|
67
67
|
allowIdCardBackToFrontCapture?: boolean;
|
|
68
|
+
enableOverrideWrongDocumentTypeDialog?: boolean;
|
|
69
|
+
allowOverrideWrongDocumentTypeAfterMs?: number;
|
|
68
70
|
assets?: IdCaptureWizardAssets;
|
|
69
71
|
classNames?: IdCaptureWizardClassNames;
|
|
70
72
|
colors?: IdCaptureWizardColors;
|
|
71
73
|
verbiage?: IdCaptureWizardVerbiage;
|
|
72
74
|
debugMode?: boolean;
|
|
73
75
|
};
|
|
74
|
-
export declare const IdCaptureWizard: ({ onSuccess, onExitCapture, onUserCancel, loadingOverlayMode, precapturedDocuments, captureRequirement, separateIdCardCaptureSequence, thresholds, skipSuccessScreen, instructions, releaseCameraAccessOnExit, guideType, portraitGuidesOnMobile, rotateLoadingOverlayImageWhenPortrait, silentFallback, forceFallbackMode, allowIdCardBackToFrontCapture, assets, classNames, colors, verbiage, debugMode, }: IdCaptureWizardProps) => ReactElement;
|
|
76
|
+
export declare const IdCaptureWizard: ({ onSuccess, onExitCapture, onUserCancel, loadingOverlayMode, precapturedDocuments, captureRequirement, separateIdCardCaptureSequence, thresholds, skipSuccessScreen, instructions, releaseCameraAccessOnExit, guideType, portraitGuidesOnMobile, rotateLoadingOverlayImageWhenPortrait, silentFallback, forceFallbackMode, allowIdCardBackToFrontCapture, enableOverrideWrongDocumentTypeDialog, allowOverrideWrongDocumentTypeAfterMs, assets, classNames, colors, verbiage, debugMode, }: IdCaptureWizardProps) => ReactElement;
|
|
@@ -234,7 +234,7 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
234
234
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
235
235
|
};
|
|
236
236
|
|
|
237
|
-
var webSdkVersion = '2.1.
|
|
237
|
+
var webSdkVersion = '2.1.35';
|
|
238
238
|
|
|
239
239
|
function getPlatform() {
|
|
240
240
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
@@ -6140,6 +6140,8 @@ var initialState$4 = {
|
|
|
6140
6140
|
documentTooClose: false,
|
|
6141
6141
|
flipRequired: false,
|
|
6142
6142
|
backDetectedFirst: false,
|
|
6143
|
+
enableOverrideWrongDocumentTypeDialog: false,
|
|
6144
|
+
allowOverrideWrongDocumentTypeAfterMs: 8000,
|
|
6143
6145
|
allowOverrideFlipRequirement: false,
|
|
6144
6146
|
overrideFlipRequirement: false,
|
|
6145
6147
|
wrongDocumentTypePredictions: 0,
|
|
@@ -6178,10 +6180,14 @@ var _reducer = function reducer(state, action) {
|
|
|
6178
6180
|
var _c = action.payload,
|
|
6179
6181
|
captureRequirement = _c.captureRequirement,
|
|
6180
6182
|
precapturedDocuments = _c.precapturedDocuments,
|
|
6181
|
-
allowIdCardBackToFrontCapture = _c.allowIdCardBackToFrontCapture
|
|
6183
|
+
allowIdCardBackToFrontCapture = _c.allowIdCardBackToFrontCapture,
|
|
6184
|
+
enableOverrideWrongDocumentTypeDialog = _c.enableOverrideWrongDocumentTypeDialog,
|
|
6185
|
+
allowOverrideWrongDocumentTypeAfterMs = _c.allowOverrideWrongDocumentTypeAfterMs;
|
|
6182
6186
|
var newState = _assign(_assign({}, state), {
|
|
6183
6187
|
captureRequirement: captureRequirement,
|
|
6184
|
-
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture !== null && allowIdCardBackToFrontCapture !== void 0 ? allowIdCardBackToFrontCapture : false
|
|
6188
|
+
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture !== null && allowIdCardBackToFrontCapture !== void 0 ? allowIdCardBackToFrontCapture : false,
|
|
6189
|
+
enableOverrideWrongDocumentTypeDialog: enableOverrideWrongDocumentTypeDialog,
|
|
6190
|
+
allowOverrideWrongDocumentTypeAfterMs: allowOverrideWrongDocumentTypeAfterMs
|
|
6185
6191
|
});
|
|
6186
6192
|
if (captureRequirement === 'idCardBack') newState.requestedDocumentType = 'idCardBack';
|
|
6187
6193
|
if (captureRequirement === 'passport') newState.requestedDocumentType = 'passport';
|
|
@@ -6290,8 +6296,8 @@ var _reducer = function reducer(state, action) {
|
|
|
6290
6296
|
}
|
|
6291
6297
|
}
|
|
6292
6298
|
var hasBeenRunningForLongEnough = !!state.captureStartedAt && new Date().getTime() - state.captureStartedAt.getTime() > 1000;
|
|
6293
|
-
var overrideFlipRequirementThreshold = Math.ceil(
|
|
6294
|
-
var allowOverrideFlipRequirement = hasBeenRunningForLongEnough && !state.overrideFlipRequirement && overrideFlipRequirementThreshold > 0 && (state.allowOverrideFlipRequirement || wrongDocumentTypePredictions >= overrideFlipRequirementThreshold);
|
|
6299
|
+
var overrideFlipRequirementThreshold = Math.ceil(state.allowOverrideWrongDocumentTypeAfterMs / 1000 * frameCaptureRate);
|
|
6300
|
+
var allowOverrideFlipRequirement = state.enableOverrideWrongDocumentTypeDialog && hasBeenRunningForLongEnough && !state.overrideFlipRequirement && overrideFlipRequirementThreshold > 0 && (state.allowOverrideFlipRequirement || wrongDocumentTypePredictions >= overrideFlipRequirementThreshold);
|
|
6295
6301
|
return _assign(_assign({}, state), {
|
|
6296
6302
|
videoWidth: frameWidth,
|
|
6297
6303
|
videoHeight: frameHeight,
|
|
@@ -9650,50 +9656,56 @@ var IdCaptureWizard = function IdCaptureWizard(_a) {
|
|
|
9650
9656
|
forceFallbackMode = _3 === void 0 ? false : _3,
|
|
9651
9657
|
_4 = _a.allowIdCardBackToFrontCapture,
|
|
9652
9658
|
allowIdCardBackToFrontCapture = _4 === void 0 ? false : _4,
|
|
9653
|
-
_5 = _a.
|
|
9654
|
-
|
|
9655
|
-
_6 = _a.
|
|
9656
|
-
|
|
9657
|
-
_7 = _a.
|
|
9658
|
-
|
|
9659
|
-
_8 = _a.
|
|
9660
|
-
|
|
9661
|
-
_9 = _a.
|
|
9662
|
-
|
|
9663
|
-
|
|
9664
|
-
|
|
9665
|
-
|
|
9666
|
-
|
|
9667
|
-
|
|
9668
|
-
|
|
9669
|
-
|
|
9670
|
-
var
|
|
9671
|
-
|
|
9672
|
-
|
|
9673
|
-
|
|
9674
|
-
|
|
9675
|
-
|
|
9676
|
-
|
|
9677
|
-
|
|
9678
|
-
|
|
9679
|
-
|
|
9680
|
-
|
|
9681
|
-
|
|
9682
|
-
|
|
9683
|
-
|
|
9684
|
-
|
|
9685
|
-
|
|
9686
|
-
|
|
9659
|
+
_5 = _a.enableOverrideWrongDocumentTypeDialog,
|
|
9660
|
+
enableOverrideWrongDocumentTypeDialog = _5 === void 0 ? false : _5,
|
|
9661
|
+
_6 = _a.allowOverrideWrongDocumentTypeAfterMs,
|
|
9662
|
+
allowOverrideWrongDocumentTypeAfterMs = _6 === void 0 ? 8000 : _6,
|
|
9663
|
+
_7 = _a.assets,
|
|
9664
|
+
assets = _7 === void 0 ? {} : _7,
|
|
9665
|
+
_8 = _a.classNames,
|
|
9666
|
+
classNames = _8 === void 0 ? {} : _8,
|
|
9667
|
+
_9 = _a.colors,
|
|
9668
|
+
colors = _9 === void 0 ? {} : _9,
|
|
9669
|
+
_10 = _a.verbiage,
|
|
9670
|
+
verbiage = _10 === void 0 ? {} : _10,
|
|
9671
|
+
_11 = _a.debugMode,
|
|
9672
|
+
debugMode = _11 === void 0 ? false : _11;
|
|
9673
|
+
var _12 = useIdCaptureState(),
|
|
9674
|
+
state = _12[0],
|
|
9675
|
+
dispatch = _12[1];
|
|
9676
|
+
var _13 = React.useContext(CameraStateContext),
|
|
9677
|
+
cameraAccessDenied = _13.cameraAccessDenied,
|
|
9678
|
+
requestCameraAccess = _13.requestCameraAccess,
|
|
9679
|
+
releaseCameraAccess = _13.releaseCameraAccess;
|
|
9680
|
+
var _14 = React.useState(false),
|
|
9681
|
+
overlayDismissed = _14[0],
|
|
9682
|
+
setOverlayDismissed = _14[1];
|
|
9683
|
+
var _15 = React.useContext(SubmissionContext),
|
|
9684
|
+
submissionStatus = _15.submissionStatus,
|
|
9685
|
+
setIdFrontImage = _15.setIdFrontImage,
|
|
9686
|
+
setIdBackImage = _15.setIdBackImage,
|
|
9687
|
+
setPassportImage = _15.setPassportImage,
|
|
9688
|
+
logIdFrontCaptureAttempt = _15.logIdFrontCaptureAttempt,
|
|
9689
|
+
logIdBackCaptureAttempt = _15.logIdBackCaptureAttempt;
|
|
9690
|
+
var _16 = React.useContext(IdCaptureModelsContext),
|
|
9691
|
+
start = _16.start,
|
|
9692
|
+
stop = _16.stop,
|
|
9693
|
+
onPredictionMade = _16.onPredictionMade,
|
|
9694
|
+
setRequiredDocumentType = _16.setRequiredDocumentType,
|
|
9695
|
+
modelError = _16.modelError,
|
|
9696
|
+
resetBestFrame = _16.resetBestFrame;
|
|
9687
9697
|
React.useEffect(function () {
|
|
9688
9698
|
dispatch({
|
|
9689
9699
|
type: 'configureWizard',
|
|
9690
9700
|
payload: {
|
|
9691
9701
|
captureRequirement: captureRequirement,
|
|
9692
9702
|
precapturedDocuments: precapturedDocuments,
|
|
9693
|
-
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture
|
|
9703
|
+
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture,
|
|
9704
|
+
enableOverrideWrongDocumentTypeDialog: enableOverrideWrongDocumentTypeDialog,
|
|
9705
|
+
allowOverrideWrongDocumentTypeAfterMs: allowOverrideWrongDocumentTypeAfterMs
|
|
9694
9706
|
}
|
|
9695
9707
|
});
|
|
9696
|
-
}, [allowIdCardBackToFrontCapture, captureRequirement, dispatch, precapturedDocuments]);
|
|
9708
|
+
}, [allowIdCardBackToFrontCapture, allowOverrideWrongDocumentTypeAfterMs, captureRequirement, dispatch, enableOverrideWrongDocumentTypeDialog, precapturedDocuments]);
|
|
9697
9709
|
var documentCount = Object.keys(state.capturedDocuments).length;
|
|
9698
9710
|
React.useEffect(function () {
|
|
9699
9711
|
documentCount && resetBestFrame();
|
|
@@ -9773,9 +9785,9 @@ var IdCaptureWizard = function IdCaptureWizard(_a) {
|
|
|
9773
9785
|
type: 'resetWizard'
|
|
9774
9786
|
});
|
|
9775
9787
|
}, [dispatch]);
|
|
9776
|
-
var
|
|
9777
|
-
attempt =
|
|
9778
|
-
setAttempt =
|
|
9788
|
+
var _17 = React.useState(0),
|
|
9789
|
+
attempt = _17[0],
|
|
9790
|
+
setAttempt = _17[1];
|
|
9779
9791
|
var onExit = React.useCallback(function () {
|
|
9780
9792
|
releaseCameraAccess();
|
|
9781
9793
|
setOverlayDismissed(false);
|
|
@@ -9828,12 +9840,12 @@ var IdCaptureWizard = function IdCaptureWizard(_a) {
|
|
|
9828
9840
|
})
|
|
9829
9841
|
};
|
|
9830
9842
|
var theme = styled.useTheme();
|
|
9831
|
-
var
|
|
9832
|
-
guideRectX =
|
|
9833
|
-
guideRectY =
|
|
9834
|
-
guideRectWidth =
|
|
9835
|
-
guideRectHeight =
|
|
9836
|
-
imageUrl =
|
|
9843
|
+
var _18 = useIdCaptureState()[0],
|
|
9844
|
+
guideRectX = _18.guideRectX,
|
|
9845
|
+
guideRectY = _18.guideRectY,
|
|
9846
|
+
guideRectWidth = _18.guideRectWidth,
|
|
9847
|
+
guideRectHeight = _18.guideRectHeight,
|
|
9848
|
+
imageUrl = _18.imageUrl;
|
|
9837
9849
|
var idCaptureAssets = assets[state.requestedDocumentType];
|
|
9838
9850
|
var idCaptureVerbiage = idCaptureVerbiages[state.requestedDocumentType];
|
|
9839
9851
|
React.useEffect(function () {
|
|
@@ -14168,6 +14180,10 @@ var IdValidation = function IdValidation(_a) {
|
|
|
14168
14180
|
forceFallbackMode = _m === void 0 ? false : _m,
|
|
14169
14181
|
_o = _a.allowIdCardBackToFrontCapture,
|
|
14170
14182
|
allowIdCardBackToFrontCapture = _o === void 0 ? false : _o,
|
|
14183
|
+
_p = _a.enableOverrideWrongDocumentTypeDialog,
|
|
14184
|
+
enableOverrideWrongDocumentTypeDialog = _p === void 0 ? false : _p,
|
|
14185
|
+
_q = _a.allowOverrideWrongDocumentTypeAfterMs,
|
|
14186
|
+
allowOverrideWrongDocumentTypeAfterMs = _q === void 0 ? 8000 : _q,
|
|
14171
14187
|
onBeforeSubmit = _a.onBeforeSubmit,
|
|
14172
14188
|
onBeforeDocumentUpload = _a.onBeforeDocumentUpload,
|
|
14173
14189
|
onDocumentUploadProgress = _a.onDocumentUploadProgress,
|
|
@@ -14181,28 +14197,28 @@ var IdValidation = function IdValidation(_a) {
|
|
|
14181
14197
|
onUserCancel = _a.onUserCancel,
|
|
14182
14198
|
onModelError = _a.onModelError,
|
|
14183
14199
|
onCameraAccessDenied = _a.onCameraAccessDenied,
|
|
14184
|
-
|
|
14185
|
-
theme =
|
|
14186
|
-
|
|
14187
|
-
assets =
|
|
14188
|
-
|
|
14189
|
-
classNames =
|
|
14190
|
-
|
|
14191
|
-
colors =
|
|
14192
|
-
|
|
14193
|
-
verbiage =
|
|
14194
|
-
|
|
14195
|
-
captureSignature =
|
|
14196
|
-
|
|
14197
|
-
captureSignatureVideo =
|
|
14198
|
-
|
|
14199
|
-
captureAdditionalDocuments =
|
|
14200
|
-
|
|
14201
|
-
geolocationEnabled =
|
|
14202
|
-
|
|
14203
|
-
geolocationRequired =
|
|
14204
|
-
|
|
14205
|
-
debugMode =
|
|
14200
|
+
_r = _a.theme,
|
|
14201
|
+
theme = _r === void 0 ? 'default' : _r,
|
|
14202
|
+
_s = _a.assets,
|
|
14203
|
+
assets = _s === void 0 ? {} : _s,
|
|
14204
|
+
_t = _a.classNames,
|
|
14205
|
+
classNames = _t === void 0 ? {} : _t,
|
|
14206
|
+
_u = _a.colors,
|
|
14207
|
+
colors = _u === void 0 ? {} : _u,
|
|
14208
|
+
_v = _a.verbiage,
|
|
14209
|
+
verbiage = _v === void 0 ? {} : _v,
|
|
14210
|
+
_w = _a.captureSignature,
|
|
14211
|
+
captureSignature = _w === void 0 ? false : _w,
|
|
14212
|
+
_x = _a.captureSignatureVideo,
|
|
14213
|
+
captureSignatureVideo = _x === void 0 ? false : _x,
|
|
14214
|
+
_y = _a.captureAdditionalDocuments,
|
|
14215
|
+
captureAdditionalDocuments = _y === void 0 ? [] : _y,
|
|
14216
|
+
_z = _a.geolocationEnabled,
|
|
14217
|
+
geolocationEnabled = _z === void 0 ? true : _z,
|
|
14218
|
+
_0 = _a.geolocationRequired,
|
|
14219
|
+
geolocationRequired = _0 === void 0 ? false : _0,
|
|
14220
|
+
_1 = _a.debugMode,
|
|
14221
|
+
debugMode = _1 === void 0 ? false : _1;
|
|
14206
14222
|
useLanguage(lang);
|
|
14207
14223
|
useDebugLogging(debugMode);
|
|
14208
14224
|
var idCaptureProps = React.useMemo(function () {
|
|
@@ -14223,13 +14239,15 @@ var IdValidation = function IdValidation(_a) {
|
|
|
14223
14239
|
portraitGuidesOnMobile: portraitGuidesOnMobile,
|
|
14224
14240
|
rotateLoadingOverlayImageWhenPortrait: rotateLoadingOverlayImageWhenPortrait,
|
|
14225
14241
|
modelLoadTimeoutMs: modelLoadTimeoutMs,
|
|
14242
|
+
enableOverrideWrongDocumentTypeDialog: enableOverrideWrongDocumentTypeDialog,
|
|
14243
|
+
allowOverrideWrongDocumentTypeAfterMs: allowOverrideWrongDocumentTypeAfterMs,
|
|
14226
14244
|
assets: assets,
|
|
14227
14245
|
classNames: classNames,
|
|
14228
14246
|
colors: colors,
|
|
14229
14247
|
verbiage: verbiage,
|
|
14230
14248
|
debugMode: debugMode
|
|
14231
14249
|
};
|
|
14232
|
-
}, [onExitCapture, onUserCancel, onModelError, precapturedDocuments, idCaptureRequirement, separateIdCardCaptureSequence, idCaptureThresholds, skipSuccessScreen, loadingOverlayMode, forceFallbackMode, allowIdCardBackToFrontCapture, instructions, guideType, portraitGuidesOnMobile, rotateLoadingOverlayImageWhenPortrait, modelLoadTimeoutMs, assets, classNames, colors, verbiage, debugMode]);
|
|
14250
|
+
}, [onExitCapture, onUserCancel, onModelError, precapturedDocuments, idCaptureRequirement, separateIdCardCaptureSequence, idCaptureThresholds, skipSuccessScreen, loadingOverlayMode, forceFallbackMode, allowIdCardBackToFrontCapture, instructions, guideType, portraitGuidesOnMobile, rotateLoadingOverlayImageWhenPortrait, modelLoadTimeoutMs, enableOverrideWrongDocumentTypeDialog, allowOverrideWrongDocumentTypeAfterMs, assets, classNames, colors, verbiage, debugMode]);
|
|
14233
14251
|
var additionalDocumentCaptureProps = React.useMemo(function () {
|
|
14234
14252
|
return {
|
|
14235
14253
|
documents: captureAdditionalDocuments,
|
|
@@ -14475,6 +14493,10 @@ var IdAndFaceValidation = function IdAndFaceValidation(_a) {
|
|
|
14475
14493
|
selfieCaptureModelLoadTimeoutMs = _o === void 0 ? defaultSelfieCaptureModelLoadTimeoutMs : _o,
|
|
14476
14494
|
_p = _a.allowIdCardBackToFrontCapture,
|
|
14477
14495
|
allowIdCardBackToFrontCapture = _p === void 0 ? false : _p,
|
|
14496
|
+
_q = _a.enableOverrideWrongDocumentTypeDialog,
|
|
14497
|
+
enableOverrideWrongDocumentTypeDialog = _q === void 0 ? false : _q,
|
|
14498
|
+
_r = _a.allowOverrideWrongDocumentTypeAfterMs,
|
|
14499
|
+
allowOverrideWrongDocumentTypeAfterMs = _r === void 0 ? 8000 : _r,
|
|
14478
14500
|
onBeforeDocumentUpload = _a.onBeforeDocumentUpload,
|
|
14479
14501
|
onDocumentUploaded = _a.onDocumentUploaded,
|
|
14480
14502
|
onDocumentUploadProgress = _a.onDocumentUploadProgress,
|
|
@@ -14491,28 +14513,28 @@ var IdAndFaceValidation = function IdAndFaceValidation(_a) {
|
|
|
14491
14513
|
onIdCaptureModelError = _a.onIdCaptureModelError,
|
|
14492
14514
|
onSelfieCaptureModelError = _a.onSelfieCaptureModelError,
|
|
14493
14515
|
onCameraAccessDenied = _a.onCameraAccessDenied,
|
|
14494
|
-
|
|
14495
|
-
captureSignature =
|
|
14496
|
-
|
|
14497
|
-
captureSignatureVideo =
|
|
14498
|
-
|
|
14499
|
-
captureAdditionalDocuments =
|
|
14500
|
-
|
|
14501
|
-
theme =
|
|
14502
|
-
|
|
14503
|
-
assets =
|
|
14504
|
-
|
|
14505
|
-
classNames =
|
|
14506
|
-
|
|
14507
|
-
colors =
|
|
14508
|
-
|
|
14509
|
-
verbiage =
|
|
14510
|
-
|
|
14511
|
-
geolocationEnabled =
|
|
14512
|
-
|
|
14513
|
-
geolocationRequired =
|
|
14514
|
-
|
|
14515
|
-
debugMode =
|
|
14516
|
+
_s = _a.captureSignature,
|
|
14517
|
+
captureSignature = _s === void 0 ? false : _s,
|
|
14518
|
+
_t = _a.captureSignatureVideo,
|
|
14519
|
+
captureSignatureVideo = _t === void 0 ? false : _t,
|
|
14520
|
+
_u = _a.captureAdditionalDocuments,
|
|
14521
|
+
captureAdditionalDocuments = _u === void 0 ? [] : _u,
|
|
14522
|
+
_v = _a.theme,
|
|
14523
|
+
theme = _v === void 0 ? 'default' : _v,
|
|
14524
|
+
_w = _a.assets,
|
|
14525
|
+
assets = _w === void 0 ? {} : _w,
|
|
14526
|
+
_x = _a.classNames,
|
|
14527
|
+
classNames = _x === void 0 ? {} : _x,
|
|
14528
|
+
_y = _a.colors,
|
|
14529
|
+
colors = _y === void 0 ? {} : _y,
|
|
14530
|
+
_z = _a.verbiage,
|
|
14531
|
+
verbiage = _z === void 0 ? {} : _z,
|
|
14532
|
+
_0 = _a.geolocationEnabled,
|
|
14533
|
+
geolocationEnabled = _0 === void 0 ? true : _0,
|
|
14534
|
+
_1 = _a.geolocationRequired,
|
|
14535
|
+
geolocationRequired = _1 === void 0 ? false : _1,
|
|
14536
|
+
_2 = _a.debugMode,
|
|
14537
|
+
debugMode = _2 === void 0 ? false : _2;
|
|
14516
14538
|
useLanguage(lang);
|
|
14517
14539
|
useDebugLogging(debugMode);
|
|
14518
14540
|
var idCaptureProps = React.useMemo(function () {
|
|
@@ -14534,10 +14556,12 @@ var IdAndFaceValidation = function IdAndFaceValidation(_a) {
|
|
|
14534
14556
|
rotateLoadingOverlayImageWhenPortrait: idCaptureRotateLoadingOverlayImageWhenPortrait,
|
|
14535
14557
|
modelLoadTimeoutMs: idCaptureModelLoadTimeoutMs,
|
|
14536
14558
|
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture,
|
|
14559
|
+
enableOverrideWrongDocumentTypeDialog: enableOverrideWrongDocumentTypeDialog,
|
|
14560
|
+
allowOverrideWrongDocumentTypeAfterMs: allowOverrideWrongDocumentTypeAfterMs,
|
|
14537
14561
|
skipSuccessScreen: skipSuccessScreen,
|
|
14538
14562
|
debugMode: debugMode
|
|
14539
14563
|
};
|
|
14540
|
-
}, [onExitCapture, onUserCancel, onIdCaptureModelError, assets.idCapture, classNames.idCapture, colors.idCapture, verbiage.idCapture, precapturedDocuments, idCaptureRequirement, idCaptureThresholds, idCaptureLoadingOverlayMode, idCaptureInstructions, idCaptureGuideType, idCapturePortraitGuidesOnMobile, idCaptureRotateLoadingOverlayImageWhenPortrait, idCaptureModelLoadTimeoutMs, allowIdCardBackToFrontCapture, skipSuccessScreen, debugMode]);
|
|
14564
|
+
}, [onExitCapture, onUserCancel, onIdCaptureModelError, assets.idCapture, classNames.idCapture, colors.idCapture, verbiage.idCapture, precapturedDocuments, idCaptureRequirement, idCaptureThresholds, idCaptureLoadingOverlayMode, idCaptureInstructions, idCaptureGuideType, idCapturePortraitGuidesOnMobile, idCaptureRotateLoadingOverlayImageWhenPortrait, idCaptureModelLoadTimeoutMs, allowIdCardBackToFrontCapture, enableOverrideWrongDocumentTypeDialog, allowOverrideWrongDocumentTypeAfterMs, skipSuccessScreen, debugMode]);
|
|
14541
14565
|
var faceLivenessProps = React.useMemo(function () {
|
|
14542
14566
|
return {
|
|
14543
14567
|
loadingOverlayMode: faceLivenessLoadingOverlayMode,
|
|
@@ -14700,6 +14724,10 @@ var CustomerIdAndBiometricsEnrollment = function CustomerIdAndBiometricsEnrollme
|
|
|
14700
14724
|
selfieCaptureModelLoadTimeoutMs = _o === void 0 ? defaultSelfieCaptureModelLoadTimeoutMs : _o,
|
|
14701
14725
|
_p = _a.allowIdCardBackToFrontCapture,
|
|
14702
14726
|
allowIdCardBackToFrontCapture = _p === void 0 ? false : _p,
|
|
14727
|
+
_q = _a.enableOverrideWrongDocumentTypeDialog,
|
|
14728
|
+
enableOverrideWrongDocumentTypeDialog = _q === void 0 ? false : _q,
|
|
14729
|
+
_r = _a.allowOverrideWrongDocumentTypeAfterMs,
|
|
14730
|
+
allowOverrideWrongDocumentTypeAfterMs = _r === void 0 ? 8000 : _r,
|
|
14703
14731
|
onBeforeDocumentUpload = _a.onBeforeDocumentUpload,
|
|
14704
14732
|
onDocumentUploadProgress = _a.onDocumentUploadProgress,
|
|
14705
14733
|
onDocumentUploaded = _a.onDocumentUploaded,
|
|
@@ -14715,28 +14743,28 @@ var CustomerIdAndBiometricsEnrollment = function CustomerIdAndBiometricsEnrollme
|
|
|
14715
14743
|
onIdCaptureModelError = _a.onIdCaptureModelError,
|
|
14716
14744
|
onSelfieCaptureModelError = _a.onSelfieCaptureModelError,
|
|
14717
14745
|
onCameraAccessDenied = _a.onCameraAccessDenied,
|
|
14718
|
-
|
|
14719
|
-
captureSignature =
|
|
14720
|
-
|
|
14721
|
-
captureSignatureVideo =
|
|
14722
|
-
|
|
14723
|
-
captureAdditionalDocuments =
|
|
14724
|
-
|
|
14725
|
-
theme =
|
|
14726
|
-
|
|
14727
|
-
assets =
|
|
14728
|
-
|
|
14729
|
-
classNames =
|
|
14730
|
-
|
|
14731
|
-
colors =
|
|
14732
|
-
|
|
14733
|
-
verbiage =
|
|
14734
|
-
|
|
14735
|
-
geolocationEnabled =
|
|
14736
|
-
|
|
14737
|
-
geolocationRequired =
|
|
14738
|
-
|
|
14739
|
-
debugMode =
|
|
14746
|
+
_s = _a.captureSignature,
|
|
14747
|
+
captureSignature = _s === void 0 ? false : _s,
|
|
14748
|
+
_t = _a.captureSignatureVideo,
|
|
14749
|
+
captureSignatureVideo = _t === void 0 ? false : _t,
|
|
14750
|
+
_u = _a.captureAdditionalDocuments,
|
|
14751
|
+
captureAdditionalDocuments = _u === void 0 ? [] : _u,
|
|
14752
|
+
_v = _a.theme,
|
|
14753
|
+
theme = _v === void 0 ? 'default' : _v,
|
|
14754
|
+
_w = _a.assets,
|
|
14755
|
+
assets = _w === void 0 ? {} : _w,
|
|
14756
|
+
_x = _a.classNames,
|
|
14757
|
+
classNames = _x === void 0 ? {} : _x,
|
|
14758
|
+
_y = _a.colors,
|
|
14759
|
+
colors = _y === void 0 ? {} : _y,
|
|
14760
|
+
_z = _a.verbiage,
|
|
14761
|
+
verbiage = _z === void 0 ? {} : _z,
|
|
14762
|
+
_0 = _a.geolocationEnabled,
|
|
14763
|
+
geolocationEnabled = _0 === void 0 ? true : _0,
|
|
14764
|
+
_1 = _a.geolocationRequired,
|
|
14765
|
+
geolocationRequired = _1 === void 0 ? false : _1,
|
|
14766
|
+
_2 = _a.debugMode,
|
|
14767
|
+
debugMode = _2 === void 0 ? false : _2;
|
|
14740
14768
|
useLanguage(lang);
|
|
14741
14769
|
useDebugLogging(debugMode);
|
|
14742
14770
|
var idCaptureProps = React.useMemo(function () {
|
|
@@ -14754,13 +14782,15 @@ var CustomerIdAndBiometricsEnrollment = function CustomerIdAndBiometricsEnrollme
|
|
|
14754
14782
|
rotateLoadingOverlayImageWhenPortrait: idCaptureRotateLoadingOverlayImageWhenPortrait,
|
|
14755
14783
|
modelLoadTimeoutMs: idCaptureModelLoadTimeoutMs,
|
|
14756
14784
|
allowIdCardBackToFrontCapture: allowIdCardBackToFrontCapture,
|
|
14785
|
+
enableOverrideWrongDocumentTypeDialog: enableOverrideWrongDocumentTypeDialog,
|
|
14786
|
+
allowOverrideWrongDocumentTypeAfterMs: allowOverrideWrongDocumentTypeAfterMs,
|
|
14757
14787
|
onExitCapture: onExitCapture,
|
|
14758
14788
|
onUserCancel: onUserCancel,
|
|
14759
14789
|
onModelError: onIdCaptureModelError,
|
|
14760
14790
|
skipSuccessScreen: skipSuccessScreen,
|
|
14761
14791
|
debugMode: debugMode
|
|
14762
14792
|
};
|
|
14763
|
-
}, [assets.idCapture, classNames.idCapture, colors.idCapture, verbiage.idCapture, idCaptureRequirement, idCaptureThresholds, idCaptureLoadingOverlayMode, idCaptureInstructions, idCaptureGuideType, idCapturePortraitGuidesOnMobile, idCaptureRotateLoadingOverlayImageWhenPortrait, idCaptureModelLoadTimeoutMs, allowIdCardBackToFrontCapture, onExitCapture, onUserCancel, onIdCaptureModelError, skipSuccessScreen, debugMode]);
|
|
14793
|
+
}, [assets.idCapture, classNames.idCapture, colors.idCapture, verbiage.idCapture, idCaptureRequirement, idCaptureThresholds, idCaptureLoadingOverlayMode, idCaptureInstructions, idCaptureGuideType, idCapturePortraitGuidesOnMobile, idCaptureRotateLoadingOverlayImageWhenPortrait, idCaptureModelLoadTimeoutMs, allowIdCardBackToFrontCapture, enableOverrideWrongDocumentTypeDialog, allowOverrideWrongDocumentTypeAfterMs, onExitCapture, onUserCancel, onIdCaptureModelError, skipSuccessScreen, debugMode]);
|
|
14764
14794
|
var faceLivenessProps = React.useMemo(function () {
|
|
14765
14795
|
return {
|
|
14766
14796
|
onExitCapture: onExitCapture,
|