idmission-web-sdk 1.0.313 → 1.0.315
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/camera/CameraProvider.d.ts +2 -0
- package/dist/components/submission/SubmissionProvider.d.ts +4 -0
- package/dist/components/video_id/IdVideoCapture.d.ts +1 -1
- package/dist/components/video_id/IdVideoCaptureSuccess.d.ts +2 -1
- package/dist/contexts/SubmissionContext.d.ts +2 -0
- package/dist/lib/camera/Camera.d.ts +5 -0
- package/dist/lib/camera/useVideoRecorder.d.ts +8 -4
- package/dist/sdk2.cjs.development.js +323 -148
- 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 +323 -148
- package/dist/sdk2.esm.js.map +1 -1
- package/dist/sdk2.umd.development.js +323 -148
- 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/stories/CustomerFlows/DocumentCapture.stories.d.ts +16 -0
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -13,6 +13,8 @@ export type CameraState = {
|
|
|
13
13
|
iphoneContinuityCameraAllowed: boolean;
|
|
14
14
|
setIphoneContinuityCameraAllowed: (value: boolean) => void;
|
|
15
15
|
takePhoto: () => Promise<Blob | null>;
|
|
16
|
+
audioStream: MediaStream | null;
|
|
17
|
+
microphoneReady: boolean;
|
|
16
18
|
};
|
|
17
19
|
export declare const CameraStateContext: React.Context<CameraState>;
|
|
18
20
|
export type CameraProviderProps = {
|
|
@@ -21,6 +21,8 @@ export type SubmissionState = {
|
|
|
21
21
|
idCaptureVideoUrl: string | null;
|
|
22
22
|
idCaptureVideoIdFrontImage: string | null;
|
|
23
23
|
idCaptureVideoIdBackImage: string | null;
|
|
24
|
+
idCaptureVideoAudioUrl: string | null;
|
|
25
|
+
idCaptureVideoAudioStartsAt: number | null;
|
|
24
26
|
additionalDocuments: UploadedDocument[] | null;
|
|
25
27
|
setIdFrontImage: (image: string) => void;
|
|
26
28
|
setIdBackImage: (image: string) => void;
|
|
@@ -31,6 +33,8 @@ export type SubmissionState = {
|
|
|
31
33
|
setIdCaptureVideoUrl: (videoDataUrl: string) => void;
|
|
32
34
|
setIdCaptureVideoIdFrontImage: (image: string) => void;
|
|
33
35
|
setIdCaptureVideoIdBackImage: (image: string) => void;
|
|
36
|
+
setIdCaptureVideoAudioUrl: (videoDataUrl: string) => void;
|
|
37
|
+
setIdCaptureVideoAudioStartsAt: (value: number) => void;
|
|
34
38
|
setAdditionalDocuments: (uploadedDocuments: UploadedDocument[]) => void;
|
|
35
39
|
uploadDocument: (blob: Blob) => Promise<string>;
|
|
36
40
|
logIdFrontCaptureAttempt: (attempt: CaptureAttemptMetadata) => void;
|
|
@@ -32,7 +32,7 @@ export type IdVideoCaptureVerbiage = {
|
|
|
32
32
|
captureBtnText?: CustomerSuppliedVerbiage;
|
|
33
33
|
};
|
|
34
34
|
export type IdVideoCaptureProps = {
|
|
35
|
-
onComplete?: (videoUrl: string) => void;
|
|
35
|
+
onComplete?: (videoUrl: string, audioUrl: string | null) => void;
|
|
36
36
|
onIdFrontImageCaptured?: (imageUrl: string) => void;
|
|
37
37
|
onIdBackImageCaptured?: (imageUrl: string) => void;
|
|
38
38
|
onFaceNotDetected?: () => void;
|
|
@@ -24,6 +24,7 @@ export type IdVideoCaptureSuccessVerbiage = {
|
|
|
24
24
|
};
|
|
25
25
|
export type IdVideoCaptureSuccessProps = {
|
|
26
26
|
videoUrl: string;
|
|
27
|
+
audioUrl: string | null;
|
|
27
28
|
idFrontImageUrl: string;
|
|
28
29
|
idBackImageUrl?: string;
|
|
29
30
|
onDoneClick?: () => void;
|
|
@@ -32,4 +33,4 @@ export type IdVideoCaptureSuccessProps = {
|
|
|
32
33
|
colors?: IdVideoCaptureSuccessColors;
|
|
33
34
|
verbiage?: IdVideoCaptureSuccessVerbiage;
|
|
34
35
|
};
|
|
35
|
-
export declare const IdVideoCaptureSuccess: ({ videoUrl, idFrontImageUrl, idBackImageUrl, onDoneClick, onRetryClick, classNames, colors, verbiage: rawVerbiage, }: IdVideoCaptureSuccessProps) => ReactElement;
|
|
36
|
+
export declare const IdVideoCaptureSuccess: ({ videoUrl, audioUrl, idFrontImageUrl, idBackImageUrl, onDoneClick, onRetryClick, classNames, colors, verbiage: rawVerbiage, }: IdVideoCaptureSuccessProps) => ReactElement;
|
|
@@ -24,6 +24,7 @@ export type FacingMode = 'user' | 'environment' | 'left' | 'right';
|
|
|
24
24
|
export declare function listAvailableCameras(facingMode?: FacingMode, requestMicAccess?: boolean): Promise<MediaDeviceInfo[]>;
|
|
25
25
|
export declare function obtainCameraAccess(stream: MediaStream, deviceLabel: string, video?: HTMLVideoElement | null): Camera;
|
|
26
26
|
export declare function releaseCameraAccess(): void;
|
|
27
|
+
export declare function releaseMicrophoneAccess(): void;
|
|
27
28
|
export declare const useHighestResCaptureDevice: ({ preferFrontFacingCamera, preferContinuityCamera, requestMicrophoneAccess, maxVideoWidth, maxFps, debugMode, }?: {
|
|
28
29
|
preferFrontFacingCamera: boolean;
|
|
29
30
|
preferContinuityCamera: boolean;
|
|
@@ -45,6 +46,10 @@ export declare const useHighestResCaptureDevice: ({ preferFrontFacingCamera, pre
|
|
|
45
46
|
iphoneContinuityCameraAllowed: boolean;
|
|
46
47
|
setIphoneContinuityCameraAllowed: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
47
48
|
takePhoto: () => Promise<Blob | null>;
|
|
49
|
+
audioStream: MediaStream | null;
|
|
50
|
+
microphoneReady: boolean;
|
|
51
|
+
microphoneAccessDenied: boolean;
|
|
52
|
+
retryMicrophoneAccess: () => void;
|
|
48
53
|
};
|
|
49
54
|
export declare const useDualResCaptureDevice: () => {
|
|
50
55
|
minVideoRef: import("react").MutableRefObject<HTMLVideoElement | null>;
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { Camera } from './Camera';
|
|
2
|
-
export declare const useVideoRecorder: (camera: Camera | null) => {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
export declare const useVideoRecorder: (camera: Camera | null, audioStream?: MediaStream | null) => {
|
|
3
|
+
isRecordingVideo: boolean;
|
|
4
|
+
isRecordingAudio: boolean;
|
|
5
|
+
startRecordingVideo: () => void;
|
|
6
|
+
startRecordingAudio: () => void;
|
|
7
|
+
stopRecordingVideo: () => void;
|
|
8
|
+
stopRecordingAudio: () => void;
|
|
6
9
|
videoUrl: string | null;
|
|
10
|
+
audioUrl: string | null;
|
|
7
11
|
};
|