idmission-web-sdk 2.1.42 → 2.1.44

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.
@@ -39,6 +39,8 @@ export type IdCaptureVerbiage = {
39
39
  guidanceNotCenteredText?: CustomerSuppliedVerbiage;
40
40
  guidanceTooCloseText?: CustomerSuppliedVerbiage;
41
41
  guidanceNotDetectedText?: CustomerSuppliedVerbiage;
42
+ guidanceIdCardNotAllowedText?: CustomerSuppliedVerbiage;
43
+ guidancePassportNotAllowedText?: CustomerSuppliedVerbiage;
42
44
  overrideWrongDocumentTypeGuidanceDialog?: OverrideWrongDocumentTypeGuidanceDialogVerbiage;
43
45
  };
44
46
  export type IdCaptureProps = {
@@ -27,6 +27,8 @@ export type IdCaptureState = {
27
27
  documentTooClose: boolean;
28
28
  flipRequired: boolean;
29
29
  backDetectedFirst: boolean;
30
+ idCardDetectedButNotAllowed: boolean;
31
+ passportDetectedButNotAllowed: boolean;
30
32
  enableOverrideWrongDocumentTypeDialog: boolean;
31
33
  allowOverrideWrongDocumentTypeAfterMs: number;
32
34
  allowOverrideWrongDocumentTypeGuidance: boolean;
@@ -1,17 +1,12 @@
1
- import React from 'react';
1
+ import React, { ComponentType } from 'react';
2
2
  import { SignatureData } from '../signature_capture/data';
3
3
  import { CustomerSuppliedVerbiage } from '../../lib/locales';
4
+ import { FaceCaptureGuideOverlayProps } from '../face_liveness/FaceCaptureGuideOverlay';
4
5
  export type VideoSignatureCaptureClassNames = {
5
6
  container?: string;
6
7
  cameraFeed?: string;
7
8
  guidanceMessageContainer?: string;
8
9
  guidanceMessage?: string;
9
- canvasContainer?: string;
10
- canvasInner?: string;
11
- canvas?: string;
12
- buttonsRow?: string;
13
- acceptBtn?: string;
14
- clearBtn?: string;
15
10
  exitCaptureBtn?: string;
16
11
  };
17
12
  export type VideoSignatureCaptureColors = {
@@ -20,16 +15,15 @@ export type VideoSignatureCaptureColors = {
20
15
  };
21
16
  export type VideoSignatureCaptureVerbiage = {
22
17
  guidanceMessageText?: CustomerSuppliedVerbiage;
23
- acceptBtnText?: CustomerSuppliedVerbiage;
24
- clearBtnText?: CustomerSuppliedVerbiage;
25
18
  };
26
19
  export type VideoSignatureCaptureProps = {
27
20
  onVideoCaptured?: (videoData: Blob, signatureData: SignatureData, signatureImageData: string) => void;
28
21
  onFaceNotDetected?: () => void;
29
22
  onExit?: () => void;
23
+ guidesComponent?: ComponentType<FaceCaptureGuideOverlayProps>;
30
24
  classNames?: VideoSignatureCaptureClassNames;
31
25
  colors?: VideoSignatureCaptureColors;
32
26
  verbiage?: VideoSignatureCaptureVerbiage;
33
27
  debugMode?: boolean;
34
28
  };
35
- export declare const VideoSignatureCapture: ({ onVideoCaptured, onFaceNotDetected, onExit, classNames, colors, verbiage: rawVerbiage, debugMode, }: VideoSignatureCaptureProps) => React.ReactElement;
29
+ export declare const VideoSignatureCapture: ({ onVideoCaptured, onFaceNotDetected, onExit, guidesComponent, classNames, colors, verbiage: rawVerbiage, debugMode, }: VideoSignatureCaptureProps) => React.ReactElement;
@@ -0,0 +1,18 @@
1
+ import React, { ReactNode } from 'react';
2
+ import { SignatureData } from '../signature_capture/data';
3
+ import SignatureCanvas from 'react-signature-canvas';
4
+ export type VideoSignatureState = {
5
+ startRecording: () => void;
6
+ stopRecording: () => void;
7
+ signaturePad?: React.RefObject<SignatureCanvas>;
8
+ signatureData: SignatureData | null;
9
+ signatureDataUrl: string | null;
10
+ signatureVideoData: Blob | null;
11
+ signatureVideoUrl: string | null;
12
+ onAcceptClicked: () => Promise<void>;
13
+ };
14
+ export declare const VideoSignatureContext: React.Context<VideoSignatureState>;
15
+ export default function VideoSignatureContextProvider({ children, }: {
16
+ children: ReactNode;
17
+ }): React.JSX.Element;
18
+ export declare function useVideoSignatureContext(): VideoSignatureState;
@@ -0,0 +1,28 @@
1
+ import React from 'react';
2
+ import { FaceGuideStatus } from '../face_liveness/FaceCaptureGuideOverlay';
3
+ export type Action = 'VERIFY_LIVENESS' | 'CAPTURE_SIGNATURE';
4
+ export type VideoSignatureGuidesClassNames = {
5
+ container?: string;
6
+ inner?: string;
7
+ faceGuideContainer?: string;
8
+ faceGuide?: string;
9
+ signaturePadContainer?: string;
10
+ signatureCanvasContainer?: string;
11
+ signatureCanvasInner?: string;
12
+ signatureCanvas?: string;
13
+ signatureButtonsRow?: string;
14
+ clearSignatureBtn?: string;
15
+ acceptSignatureBtn?: string;
16
+ };
17
+ export type VideoSignatureGuidesVerbiage = {
18
+ clearSignatureBtnText?: string;
19
+ acceptSignatureBtnText?: string;
20
+ };
21
+ export default function VideoSignatureGuides({ requestedAction, faceGuideStatus, faceGuideBorderWidth, faceGuideBorderColor, classNames, verbiage: rawVerbiage, }: {
22
+ requestedAction?: Action;
23
+ faceGuideStatus?: FaceGuideStatus;
24
+ faceGuideBorderWidth?: number;
25
+ faceGuideBorderColor?: string;
26
+ classNames?: VideoSignatureGuidesClassNames;
27
+ verbiage?: VideoSignatureGuidesVerbiage;
28
+ }): React.JSX.Element;
@@ -21,7 +21,6 @@ export type VideoSignatureSuccessVerbiage = {
21
21
  doneBtnText?: CustomerSuppliedVerbiage;
22
22
  };
23
23
  export type VideoSignatureSuccessProps = {
24
- videoUrl: string;
25
24
  imageUrl: string;
26
25
  onDoneClick?: () => void;
27
26
  onRetryClick?: () => void;
@@ -29,4 +28,4 @@ export type VideoSignatureSuccessProps = {
29
28
  colors?: VideoSignatureSuccessColors;
30
29
  verbiage?: VideoSignatureSuccessVerbiage;
31
30
  };
32
- export declare const VideoSignatureSuccess: ({ videoUrl, imageUrl, onDoneClick, onRetryClick, classNames, colors, verbiage: rawVerbiage, }: VideoSignatureSuccessProps) => ReactElement;
31
+ export declare const VideoSignatureSuccess: ({ imageUrl, onDoneClick, onRetryClick, classNames, colors, verbiage: rawVerbiage, }: VideoSignatureSuccessProps) => ReactElement;
@@ -33,6 +33,7 @@ export type SubmissionRequest = {
33
33
  idType: 'NSP';
34
34
  idCountry: 'NSP';
35
35
  idState: '';
36
+ idNumber?: string;
36
37
  issueDate?: string;
37
38
  expDate?: string;
38
39
  };
@@ -109,17 +110,18 @@ export type CardData = {
109
110
  nameOnCard?: string;
110
111
  };
111
112
  export type IdData = {
113
+ idNumber?: string;
112
114
  issueDate?: string;
113
115
  expDate?: string;
114
116
  };
115
117
  export type CustomerDataMatchConfig = {
116
118
  /** Boolean flag to indicate whether the server should perform name matching using the `name` value from `personalData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
117
119
  nameMatch?: 'Y' | 'E' | 'N';
118
- /** Boolean flag to indicate whether the server should perform ID number matching using the `idNumber` value from `personalData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
120
+ /** Boolean flag to indicate whether the server should perform ID number matching using the `idNumber` value from `idData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
119
121
  idNumberMatch?: 'Y' | 'E' | 'N';
120
122
  /** Boolean flag to indicate whether the server should perform date of birth matching using the `dob` value from `personalData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
121
123
  dateOfBirthMatch?: 'Y' | 'E' | 'N';
122
- /** Boolean flag to indicate whether the server should perform expiry date matching using the `expDate` value from `personalData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
124
+ /** Boolean flag to indicate whether the server should perform expiry date matching using the `expDate` value from `idData`. Valid values: "Y" (fuzzy match accepting 90% or higher similarity), "E" (only accept exact matches), "N" (do not perform matching). Defaults to "N". */
123
125
  expiryDateMatch?: 'Y' | 'E' | 'N';
124
126
  };
125
127
  export type SubmissionMetadata = {
@@ -26,6 +26,8 @@ declare const _default: {
26
26
  'Document out of focus \u2013 try improving the lighting': string;
27
27
  'ID card front detected - please flip your ID card': string;
28
28
  'ID card back detected - please flip your ID card': string;
29
+ 'ID card detected, please scan a passport instead': string;
30
+ 'Passport detected, please scan an ID card instead': string;
29
31
  'Document detected, hold still...': string;
30
32
  'ID card front detected, hold still...': string;
31
33
  'ID card back detected, hold still...': string;
@@ -34,6 +34,8 @@ export declare const resources: {
34
34
  'Document out of focus \u2013 try improving the lighting': string;
35
35
  'ID card front detected - please flip your ID card': string;
36
36
  'ID card back detected - please flip your ID card': string;
37
+ 'ID card detected, please scan a passport instead': string;
38
+ 'Passport detected, please scan an ID card instead': string;
37
39
  'Document detected, hold still...': string;
38
40
  'ID card front detected, hold still...': string;
39
41
  'ID card back detected, hold still...': string;