scandit-react-native-datacapture-id 8.0.0 → 8.1.0-beta.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/android/build.gradle +1 -1
- package/dist/dts/IdCaptureView.d.ts +2 -1
- package/dist/dts/native/IdNativeCallerProvider.d.ts +5 -0
- package/dist/id.js +131 -118
- package/dist/id.js.map +1 -1
- package/dist/index.js +50 -51
- package/dist/index.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/ios/Sources/ScanditDataCaptureId.swift +34 -11
- package/package.json +6 -7
- package/scandit-react-native-datacapture-id.podspec +1 -1
package/dist/index.js
CHANGED
|
@@ -1,26 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { FrameSourceState, CameraPosition, DataCaptureView, createRNNativeCaller, initCoreDefaults } from 'scandit-react-native-datacapture-core';
|
|
3
|
-
import { NativeModules, AppState } from 'react-native';
|
|
4
|
-
import { IdCapture, IdCaptureSettings, IdCaptureOverlay, loadIdDefaults } from './id.js';
|
|
1
|
+
import { IdCapture, IdCaptureSettings, IdCaptureOverlay, registerIdProxies, loadIdDefaults, ID_PROXY_TYPE_NAMES } from './id.js';
|
|
5
2
|
export { AamvaBarcodeVerificationResult, AamvaBarcodeVerificationStatus, BarcodeResult, CapturedId, CapturedSides, DataConsistencyCheck, DataConsistencyResult, DateResult, DriverLicense, DrivingLicenseCategory, DrivingLicenseDetails, Duration, FullDocumentScanner, HealthInsuranceCard, IdAnonymizationMode, IdCapture, IdCaptureController, IdCaptureDocumentType, IdCaptureFeedback, IdCaptureListenerController, IdCaptureListenerEvents, IdCaptureOverlay, IdCaptureRegion, IdCaptureScanner, IdCaptureSettings, IdCard, IdFieldType, IdImageType, IdImages, IdLayoutLineStyle, IdLayoutStyle, IdSide, MRZResult, MobileDocumentDataElement, MobileDocumentOCRResult, MobileDocumentResult, MobileDocumentScanner, Passport, ProfessionalDrivingPermit, RegionSpecific, RegionSpecificSubtype, RejectionReason, ResidencePermit, Sex, SingleSideScanner, TextHintPosition, UsRealIdStatus, VIZResult, VehicleRestriction, VerificationResult, VisaIcao } from './id.js';
|
|
3
|
+
import { AppState, NativeModules } from 'react-native';
|
|
4
|
+
import { getNativeModule, FrameSourceState, CameraPosition, DataCaptureView, initCoreDefaults, createRNNativeCaller } from 'scandit-react-native-datacapture-core';
|
|
6
5
|
import React, { forwardRef, useImperativeHandle, useState, useMemo, useCallback, useEffect, useRef } from 'react';
|
|
6
|
+
import { CameraOwnershipHelper } from 'scandit-react-native-datacapture-core/dist/core';
|
|
7
|
+
|
|
8
|
+
class RNIdNativeCallerProvider {
|
|
9
|
+
getNativeCaller(proxyType) {
|
|
10
|
+
if (!ID_PROXY_TYPE_NAMES.includes(proxyType)) {
|
|
11
|
+
throw new Error(`No native module mapped for proxy type: ${proxyType}`);
|
|
12
|
+
}
|
|
13
|
+
return createRNNativeCaller(NativeModules.ScanditDataCaptureId);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
7
16
|
|
|
8
17
|
function initIdProxy() {
|
|
9
|
-
|
|
10
|
-
const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);
|
|
11
|
-
return createNativeProxy(caller);
|
|
12
|
-
});
|
|
13
|
-
FactoryMaker.bindLazyInstance('IdCaptureListenerProxy', () => {
|
|
14
|
-
const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);
|
|
15
|
-
return createNativeProxy(caller);
|
|
16
|
-
});
|
|
17
|
-
FactoryMaker.bindLazyInstance('IdCaptureOverlayProxy', () => {
|
|
18
|
-
const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);
|
|
19
|
-
return createNativeProxy(caller);
|
|
20
|
-
});
|
|
18
|
+
registerIdProxies(new RNIdNativeCallerProvider());
|
|
21
19
|
}
|
|
22
20
|
|
|
23
|
-
const dataCaptureId =
|
|
21
|
+
const dataCaptureId = getNativeModule('ScanditDataCaptureId');
|
|
24
22
|
function initIdDefaults() {
|
|
25
23
|
initCoreDefaults();
|
|
26
24
|
loadIdDefaults(dataCaptureId.Defaults);
|
|
@@ -30,11 +28,9 @@ function initIdDefaults() {
|
|
|
30
28
|
const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
31
29
|
useImperativeHandle(ref, () => ({
|
|
32
30
|
reset() {
|
|
33
|
-
getMode().reset();
|
|
31
|
+
void getMode().reset();
|
|
34
32
|
},
|
|
35
|
-
}),
|
|
36
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
37
|
-
[]);
|
|
33
|
+
}), []);
|
|
38
34
|
/* STATE VARIABLES */
|
|
39
35
|
const [isEnabledState, setIsEnabledState] = useState(false);
|
|
40
36
|
const [frameSourceState, setFrameSourceState] = useState(FrameSourceState.Off);
|
|
@@ -50,7 +46,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
50
46
|
return idCaptureModeRef.current;
|
|
51
47
|
}
|
|
52
48
|
idCaptureModeRef.current = new IdCapture(props.idCaptureSettings || new IdCaptureSettings());
|
|
53
|
-
idCaptureModeRef.current
|
|
49
|
+
idCaptureModeRef.current['parentId'] = viewId;
|
|
54
50
|
return idCaptureModeRef.current;
|
|
55
51
|
}, [props.idCaptureSettings, viewId]);
|
|
56
52
|
useEffect(() => {
|
|
@@ -58,7 +54,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
58
54
|
}, [isEnabledState, getMode]);
|
|
59
55
|
useEffect(() => {
|
|
60
56
|
const position = props.desiredCameraPosition || CameraPosition.WorldFacing;
|
|
61
|
-
CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {
|
|
57
|
+
void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {
|
|
62
58
|
await camera.switchToDesiredState(frameSourceState);
|
|
63
59
|
});
|
|
64
60
|
}, [frameSourceState, props.desiredCameraPosition, cameraOwner]);
|
|
@@ -95,7 +91,6 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
95
91
|
subscription.remove();
|
|
96
92
|
doDestroy();
|
|
97
93
|
};
|
|
98
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
99
94
|
}, []);
|
|
100
95
|
const setupCamera = useCallback(async () => {
|
|
101
96
|
const position = props.desiredCameraPosition || CameraPosition.WorldFacing;
|
|
@@ -113,14 +108,14 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
113
108
|
if (componentIsSetUp.current)
|
|
114
109
|
return;
|
|
115
110
|
componentIsSetUp.current = true;
|
|
116
|
-
/* Setup camera with ownership -
|
|
117
|
-
setupCamera();
|
|
118
|
-
/* Only proceed after camera is ready */
|
|
119
|
-
props.context.removeAllModes();
|
|
120
|
-
props.context.addMode(getMode());
|
|
111
|
+
/* Setup camera with ownership - Fire-and-forget */
|
|
112
|
+
void setupCamera();
|
|
113
|
+
/* Only proceed after camera is ready - these operations are async but errors are handled internally */
|
|
114
|
+
void props.context.removeAllModes();
|
|
115
|
+
void props.context.addMode(getMode());
|
|
121
116
|
/* Adding ID Capture Overlay */
|
|
122
117
|
if (viewRef.current) {
|
|
123
|
-
viewRef.current.addOverlay(getIdCaptureOverlay());
|
|
118
|
+
void viewRef.current.addOverlay(getIdCaptureOverlay());
|
|
124
119
|
}
|
|
125
120
|
}, [setupCamera, props.context, getMode, getIdCaptureOverlay]);
|
|
126
121
|
const doDestroy = () => {
|
|
@@ -146,15 +141,18 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
146
141
|
}
|
|
147
142
|
/* Cleaning Data Capture Context */
|
|
148
143
|
if (idCaptureModeRef.current) {
|
|
149
|
-
props.context.removeMode(idCaptureModeRef.current);
|
|
144
|
+
void props.context.removeMode(idCaptureModeRef.current);
|
|
150
145
|
}
|
|
151
146
|
/* Cleaning Overlays */
|
|
152
147
|
if (viewRef.current) {
|
|
153
|
-
viewRef.current
|
|
148
|
+
viewRef.current['view']?.overlays?.forEach((overlay) => {
|
|
149
|
+
void viewRef.current?.['view']?.removeOverlay(overlay);
|
|
150
|
+
});
|
|
154
151
|
}
|
|
155
|
-
/* Turn off camera and release ownership */
|
|
152
|
+
/* Turn off camera and release ownership - Fire-and-forget cleanup */
|
|
156
153
|
const position = props.desiredCameraPosition || CameraPosition.WorldFacing;
|
|
157
|
-
|
|
154
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
|
|
155
|
+
void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {
|
|
158
156
|
await camera.switchToDesiredState(FrameSourceState.Off);
|
|
159
157
|
await props.context.setFrameSource(null);
|
|
160
158
|
}).finally(() => {
|
|
@@ -165,7 +163,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
165
163
|
/* ID CAPTURE MODE */
|
|
166
164
|
useEffect(() => {
|
|
167
165
|
if (props.idCaptureSettings) {
|
|
168
|
-
getMode().applySettings(props.idCaptureSettings);
|
|
166
|
+
void getMode().applySettings(props.idCaptureSettings);
|
|
169
167
|
}
|
|
170
168
|
}, [props.idCaptureSettings, getMode]);
|
|
171
169
|
useEffect(() => {
|
|
@@ -180,7 +178,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
180
178
|
}, [props.didCaptureId, props.didRejectId]);
|
|
181
179
|
// Add/remove listener only when needed
|
|
182
180
|
useEffect(() => {
|
|
183
|
-
|
|
181
|
+
void (async () => {
|
|
184
182
|
const shouldHaveListener = props.didCaptureId || props.didRejectId;
|
|
185
183
|
const hasListener = listenerRef.current !== null;
|
|
186
184
|
if (shouldHaveListener && !hasListener) {
|
|
@@ -196,8 +194,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
196
194
|
await getMode().removeListener(listenerRef.current);
|
|
197
195
|
listenerRef.current = null;
|
|
198
196
|
}
|
|
199
|
-
};
|
|
200
|
-
setupListeners();
|
|
197
|
+
})();
|
|
201
198
|
}, [props.didCaptureId, props.didRejectId, getMode, listenerRef, callbacksRef]);
|
|
202
199
|
/* OVERLAYS */
|
|
203
200
|
useEffect(() => {
|
|
@@ -217,7 +214,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
217
214
|
return; // Don't run until camera is ready
|
|
218
215
|
const position = props.desiredCameraPosition || CameraPosition.WorldFacing;
|
|
219
216
|
const settings = props.cameraSettings || IdCapture.createRecommendedCameraSettings();
|
|
220
|
-
CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {
|
|
217
|
+
void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {
|
|
221
218
|
await camera.applySettings(settings);
|
|
222
219
|
});
|
|
223
220
|
}, [props.cameraSettings, props.desiredCameraPosition, cameraOwner, isCameraSetup]);
|
|
@@ -227,7 +224,9 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
227
224
|
}
|
|
228
225
|
}, [props.desiredCameraState]);
|
|
229
226
|
useEffect(() => {
|
|
230
|
-
if (props.desiredCameraPosition)
|
|
227
|
+
if (!props.desiredCameraPosition)
|
|
228
|
+
return;
|
|
229
|
+
void (async () => {
|
|
231
230
|
// Handle camera position change with ownership
|
|
232
231
|
const currentOwnedPosition = CameraOwnershipHelper.getOwnedPosition(cameraOwner);
|
|
233
232
|
const newPosition = props.desiredCameraPosition;
|
|
@@ -235,22 +234,22 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
235
234
|
// Release old camera ownership
|
|
236
235
|
CameraOwnershipHelper.releaseOwnership(currentOwnedPosition, cameraOwner);
|
|
237
236
|
// Set up new camera
|
|
238
|
-
setupCamera();
|
|
237
|
+
await setupCamera();
|
|
239
238
|
}
|
|
240
239
|
else if (!currentOwnedPosition) {
|
|
241
240
|
// No camera owned yet, set up new camera
|
|
242
|
-
setupCamera();
|
|
241
|
+
await setupCamera();
|
|
243
242
|
}
|
|
244
|
-
}
|
|
243
|
+
})();
|
|
245
244
|
}, [props.desiredCameraPosition, cameraOwner, setupCamera]);
|
|
246
245
|
/* CONTROLS */
|
|
247
246
|
useEffect(() => {
|
|
248
|
-
if (props.desiredTorchState)
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
}
|
|
247
|
+
if (!props.desiredTorchState)
|
|
248
|
+
return;
|
|
249
|
+
const position = props.desiredCameraPosition || CameraPosition.WorldFacing;
|
|
250
|
+
void CameraOwnershipHelper.withCameraWhenAvailable(position, cameraOwner, camera => {
|
|
251
|
+
camera.desiredTorchState = props.desiredTorchState;
|
|
252
|
+
});
|
|
254
253
|
}, [props.desiredTorchState, props.desiredCameraPosition, cameraOwner]);
|
|
255
254
|
useEffect(() => {
|
|
256
255
|
if (!viewRef.current)
|
|
@@ -261,7 +260,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
261
260
|
if (!props.torchSwitchControl)
|
|
262
261
|
return;
|
|
263
262
|
torchSwitchControl.current = props.torchSwitchControl;
|
|
264
|
-
viewRef.current.addControl(torchSwitchControl.current);
|
|
263
|
+
void viewRef.current.addControl(torchSwitchControl.current);
|
|
265
264
|
}, [props.torchSwitchControl]);
|
|
266
265
|
useEffect(() => {
|
|
267
266
|
if (!viewRef.current)
|
|
@@ -272,7 +271,7 @@ const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {
|
|
|
272
271
|
if (!props.zoomSwitchControl)
|
|
273
272
|
return;
|
|
274
273
|
zoomSwitchControl.current = props.zoomSwitchControl;
|
|
275
|
-
viewRef.current.addControl(zoomSwitchControl.current);
|
|
274
|
+
void viewRef.current.addControl(zoomSwitchControl.current);
|
|
276
275
|
}, [props.zoomSwitchControl]);
|
|
277
276
|
/* MISC */
|
|
278
277
|
useEffect(() => {
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../ts/native/initProxy.ts","../ts/private/initDefaults.ts","../ts/IdCaptureView.tsx","../ts/index.ts"],"sourcesContent":["import { createNativeProxy, FactoryMaker } from 'scandit-datacapture-frameworks-core';\nimport { createRNNativeCaller } from 'scandit-react-native-datacapture-core';\nimport { NativeModules } from 'react-native';\nexport function initIdProxy() {\n FactoryMaker.bindLazyInstance('IdCaptureProxy', () => {\n const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);\n return createNativeProxy(caller);\n });\n FactoryMaker.bindLazyInstance('IdCaptureListenerProxy', () => {\n const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);\n return createNativeProxy(caller);\n });\n FactoryMaker.bindLazyInstance('IdCaptureOverlayProxy', () => {\n const caller = createRNNativeCaller(NativeModules.ScanditDataCaptureId);\n return createNativeProxy(caller);\n });\n}\n//# sourceMappingURL=initProxy.js.map","import { NativeModules } from 'react-native';\nimport { initCoreDefaults } from 'scandit-react-native-datacapture-core';\nimport { loadIdDefaults } from 'scandit-datacapture-frameworks-id';\nconst dataCaptureId = NativeModules.ScanditDataCaptureId;\nexport function initIdDefaults() {\n initCoreDefaults();\n loadIdDefaults(dataCaptureId.Defaults);\n}\n//# sourceMappingURL=initDefaults.js.map","import React, { useEffect, useRef, useState, forwardRef, useImperativeHandle, useMemo, useCallback } from 'react';\nimport { AppState } from 'react-native';\nimport { CameraPosition, DataCaptureView, FrameSourceState, } from 'scandit-react-native-datacapture-core';\nimport { IdCapture, IdCaptureOverlay, IdCaptureSettings, } from 'scandit-datacapture-frameworks-id';\nimport { CameraOwnershipHelper } from 'scandit-datacapture-frameworks-core';\n// tslint:disable-next-line\nexport const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {\n useImperativeHandle(ref, () => ({\n reset() {\n getMode().reset();\n },\n }), \n // eslint-disable-next-line react-hooks/exhaustive-deps\n []);\n /* STATE VARIABLES */\n const [isEnabledState, setIsEnabledState] = useState(false);\n const [frameSourceState, setFrameSourceState] = useState(FrameSourceState.Off);\n const [viewId] = useState(() => Math.floor(Math.random() * 1000000));\n const [isCameraSetup, setIsCameraSetup] = useState(false);\n // Create camera owner using viewId\n const cameraOwner = useMemo(() => ({\n id: `id-capture-view-${viewId}`,\n }), [viewId]);\n /* STATE HANDLERS */\n const getMode = useCallback(() => {\n if (idCaptureModeRef.current !== null) {\n return idCaptureModeRef.current;\n }\n idCaptureModeRef.current = new IdCapture(props.idCaptureSettings || new IdCaptureSettings());\n idCaptureModeRef.current.parentId = viewId;\n return idCaptureModeRef.current;\n }, [props.idCaptureSettings, viewId]);\n useEffect(() => {\n getMode().isEnabled = isEnabledState;\n }, [isEnabledState, getMode]);\n useEffect(() => {\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.switchToDesiredState(frameSourceState);\n });\n }, [frameSourceState, props.desiredCameraPosition, cameraOwner]);\n const viewRef = useRef(null);\n const componentIsSetUp = useRef(false);\n const idCaptureModeRef = useRef(null);\n const idCaptureOverlayRef = useRef(null);\n const getIdCaptureOverlay = useCallback(() => {\n if (idCaptureOverlayRef.current !== null) {\n return idCaptureOverlayRef.current;\n }\n idCaptureOverlayRef.current = new IdCaptureOverlay(getMode());\n return idCaptureOverlayRef.current;\n }, [getMode]);\n // Remove getCamera function as we'll use CameraOwnershipHelper\n const torchSwitchControl = useRef(null);\n const zoomSwitchControl = useRef(null);\n const appState = useRef(AppState.currentState);\n /* SETUP */\n useEffect(() => {\n doSetup();\n const subscription = AppState.addEventListener('change', nextAppState => {\n if (appState.current.match(/inactive|background/) && nextAppState === 'active') {\n setIsEnabledState(props.isEnabled);\n setFrameSourceState(props.desiredCameraState || FrameSourceState.On);\n }\n else {\n setIsEnabledState(false);\n setFrameSourceState(FrameSourceState.Off);\n }\n appState.current = nextAppState;\n });\n return () => {\n subscription.remove();\n doDestroy();\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n const setupCamera = useCallback(async () => {\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n // Request ownership and set up camera\n await CameraOwnershipHelper.withCameraWhenAvailable(position, cameraOwner, async (camera) => {\n const settings = props.cameraSettings || IdCapture.createRecommendedCameraSettings();\n await camera.applySettings(settings);\n await props.context.setFrameSource(camera);\n await camera.switchToDesiredState(props.desiredCameraState || FrameSourceState.On);\n // Mark camera as set up\n setIsCameraSetup(true);\n });\n }, [props.desiredCameraPosition, cameraOwner, props.cameraSettings, props.context, props.desiredCameraState]);\n const doSetup = useCallback(() => {\n if (componentIsSetUp.current)\n return;\n componentIsSetUp.current = true;\n /* Setup camera with ownership - WAIT for completion */\n setupCamera();\n /* Only proceed after camera is ready */\n props.context.removeAllModes();\n props.context.addMode(getMode());\n /* Adding ID Capture Overlay */\n if (viewRef.current) {\n viewRef.current.addOverlay(getIdCaptureOverlay());\n }\n }, [setupCamera, props.context, getMode, getIdCaptureOverlay]);\n const doDestroy = () => {\n doCleanup();\n idCaptureModeRef.current = null;\n torchSwitchControl.current = null;\n zoomSwitchControl.current = null;\n idCaptureOverlayRef.current = null;\n };\n const doCleanup = useCallback(() => {\n if (!componentIsSetUp.current)\n return;\n componentIsSetUp.current = false;\n // Reset camera setup state\n setIsCameraSetup(false);\n /* Remove the torch control */\n if (torchSwitchControl.current) {\n viewRef.current?.removeControl(torchSwitchControl.current);\n }\n /* Remove the zoom control */\n if (zoomSwitchControl.current) {\n viewRef.current?.removeControl(zoomSwitchControl.current);\n }\n /* Cleaning Data Capture Context */\n if (idCaptureModeRef.current) {\n props.context.removeMode(idCaptureModeRef.current);\n }\n /* Cleaning Overlays */\n if (viewRef.current) {\n viewRef.current.view?.overlays?.forEach((overlay) => viewRef.current?.view?.removeOverlay(overlay));\n }\n /* Turn off camera and release ownership */\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.switchToDesiredState(FrameSourceState.Off);\n await props.context.setFrameSource(null);\n }).finally(() => {\n // Release camera ownership\n CameraOwnershipHelper.releaseOwnership(position, cameraOwner);\n });\n }, [props.desiredCameraPosition, cameraOwner, props.context]);\n /* ID CAPTURE MODE */\n useEffect(() => {\n if (props.idCaptureSettings) {\n getMode().applySettings(props.idCaptureSettings);\n }\n }, [props.idCaptureSettings, getMode]);\n useEffect(() => {\n setIsEnabledState(props.isEnabled);\n setFrameSourceState(props.desiredCameraState || FrameSourceState.On);\n }, [props.isEnabled, props.desiredCameraState]);\n const listenerRef = useRef(null);\n const callbacksRef = useRef({ didCaptureId: props.didCaptureId, didRejectId: props.didRejectId });\n // Update callback references when props change\n useEffect(() => {\n callbacksRef.current = { didCaptureId: props.didCaptureId, didRejectId: props.didRejectId };\n }, [props.didCaptureId, props.didRejectId]);\n // Add/remove listener only when needed\n useEffect(() => {\n const setupListeners = async () => {\n const shouldHaveListener = props.didCaptureId || props.didRejectId;\n const hasListener = listenerRef.current !== null;\n if (shouldHaveListener && !hasListener) {\n // Add listener\n listenerRef.current = {\n didCaptureId: (idCapture, capturedId) => callbacksRef.current.didCaptureId?.(idCapture, capturedId),\n didRejectId: (idCapture, rejectedId, reason) => callbacksRef.current.didRejectId?.(idCapture, rejectedId, reason),\n };\n await getMode().addListener(listenerRef.current);\n }\n else if (!shouldHaveListener && hasListener && listenerRef.current) {\n // Remove listener\n await getMode().removeListener(listenerRef.current);\n listenerRef.current = null;\n }\n };\n setupListeners();\n }, [props.didCaptureId, props.didRejectId, getMode, listenerRef, callbacksRef]);\n /* OVERLAYS */\n useEffect(() => {\n if (props.capturedBrush) {\n getIdCaptureOverlay().capturedBrush = props.capturedBrush;\n }\n if (props.rejectedBrush) {\n getIdCaptureOverlay().rejectedBrush = props.rejectedBrush;\n }\n if (props.localizedBrush) {\n getIdCaptureOverlay().localizedBrush = props.localizedBrush;\n }\n }, [props.capturedBrush, props.rejectedBrush, props.localizedBrush, getIdCaptureOverlay]);\n /* CAMERA */\n useEffect(() => {\n if (!isCameraSetup)\n return; // Don't run until camera is ready\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n const settings = props.cameraSettings || IdCapture.createRecommendedCameraSettings();\n CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.applySettings(settings);\n });\n }, [props.cameraSettings, props.desiredCameraPosition, cameraOwner, isCameraSetup]);\n useEffect(() => {\n if (props.desiredCameraState) {\n setFrameSourceState(props.desiredCameraState);\n }\n }, [props.desiredCameraState]);\n useEffect(() => {\n if (props.desiredCameraPosition) {\n // Handle camera position change with ownership\n const currentOwnedPosition = CameraOwnershipHelper.getOwnedPosition(cameraOwner);\n const newPosition = props.desiredCameraPosition;\n if (currentOwnedPosition && currentOwnedPosition !== newPosition) {\n // Release old camera ownership\n CameraOwnershipHelper.releaseOwnership(currentOwnedPosition, cameraOwner);\n // Set up new camera\n setupCamera();\n }\n else if (!currentOwnedPosition) {\n // No camera owned yet, set up new camera\n setupCamera();\n }\n }\n }, [props.desiredCameraPosition, cameraOwner, setupCamera]);\n /* CONTROLS */\n useEffect(() => {\n if (props.desiredTorchState) {\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n CameraOwnershipHelper.withCameraWhenAvailable(position, cameraOwner, async (camera) => {\n camera.desiredTorchState = props.desiredTorchState;\n });\n }\n }, [props.desiredTorchState, props.desiredCameraPosition, cameraOwner]);\n useEffect(() => {\n if (!viewRef.current)\n return;\n if (torchSwitchControl.current) {\n viewRef.current?.removeControl(torchSwitchControl.current);\n }\n if (!props.torchSwitchControl)\n return;\n torchSwitchControl.current = props.torchSwitchControl;\n viewRef.current.addControl(torchSwitchControl.current);\n }, [props.torchSwitchControl]);\n useEffect(() => {\n if (!viewRef.current)\n return;\n if (zoomSwitchControl.current) {\n viewRef.current?.removeControl(zoomSwitchControl.current);\n }\n if (!props.zoomSwitchControl)\n return;\n zoomSwitchControl.current = props.zoomSwitchControl;\n viewRef.current.addControl(zoomSwitchControl.current);\n }, [props.zoomSwitchControl]);\n /* MISC */\n useEffect(() => {\n if (props.feedback) {\n getMode().feedback = props.feedback;\n }\n }, [props.feedback, getMode]);\n useEffect(() => {\n if (!props.navigation)\n return;\n try {\n const unsubscribeFromFocus = props.navigation.addListener('focus', () => {\n doSetup();\n });\n const unsubscribeFromBlur = props.navigation.addListener('blur', () => {\n doCleanup();\n });\n return () => {\n unsubscribeFromFocus();\n unsubscribeFromBlur();\n };\n }\n catch (e) {\n // tslint:disable-next-line:no-console\n console.error(e);\n }\n }, [props.navigation, doSetup, doCleanup]);\n return React.createElement(DataCaptureView, { context: props.context, parentId: viewId, style: { flex: 1 }, ref: viewRef });\n});\n//# sourceMappingURL=IdCaptureView.js.map","import { initIdProxy } from './native/initProxy';\nimport { initIdDefaults } from './private/initDefaults';\ninitIdDefaults();\ninitIdProxy();\n// Core ID Types\nexport { DateResult } from 'scandit-datacapture-frameworks-id';\nexport { IdAnonymizationMode } from 'scandit-datacapture-frameworks-id';\nexport { IdFieldType } from 'scandit-datacapture-frameworks-id';\nexport { IdImageType } from 'scandit-datacapture-frameworks-id';\nexport { CapturedSides } from 'scandit-datacapture-frameworks-id';\nexport { TextHintPosition } from 'scandit-datacapture-frameworks-id';\nexport { BarcodeResult } from 'scandit-datacapture-frameworks-id';\nexport { Duration } from 'scandit-datacapture-frameworks-id';\nexport { IdImages } from 'scandit-datacapture-frameworks-id';\nexport { IdSide } from 'scandit-datacapture-frameworks-id';\nexport { Sex } from 'scandit-datacapture-frameworks-id';\nexport { UsRealIdStatus } from 'scandit-datacapture-frameworks-id';\n// Captured ID Data\nexport { CapturedId } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentOCRResult } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentResult } from 'scandit-datacapture-frameworks-id';\nexport { MRZResult } from 'scandit-datacapture-frameworks-id';\nexport { VIZResult } from 'scandit-datacapture-frameworks-id';\n// ID Capture\nexport { IdCapture } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureFeedback } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureOverlay } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureSettings } from 'scandit-datacapture-frameworks-id';\nexport { IdLayoutLineStyle } from 'scandit-datacapture-frameworks-id';\nexport { IdLayoutStyle } from 'scandit-datacapture-frameworks-id';\nexport { RejectionReason } from 'scandit-datacapture-frameworks-id';\n// Document Types\nexport { IdCaptureDocumentType } from 'scandit-datacapture-frameworks-id';\nexport { DriverLicense } from 'scandit-datacapture-frameworks-id';\nexport { HealthInsuranceCard } from 'scandit-datacapture-frameworks-id';\nexport { IdCard } from 'scandit-datacapture-frameworks-id';\nexport { Passport } from 'scandit-datacapture-frameworks-id';\nexport { RegionSpecific } from 'scandit-datacapture-frameworks-id';\nexport { ResidencePermit } from 'scandit-datacapture-frameworks-id';\nexport { VisaIcao } from 'scandit-datacapture-frameworks-id';\n// Scanners & Regions\nexport { IdCaptureScanner } from 'scandit-datacapture-frameworks-id';\nexport { SingleSideScanner } from 'scandit-datacapture-frameworks-id';\nexport { FullDocumentScanner } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentScanner } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentDataElement } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureRegion } from 'scandit-datacapture-frameworks-id';\nexport { RegionSpecificSubtype } from 'scandit-datacapture-frameworks-id';\n// Verification & Validation\nexport { AamvaBarcodeVerificationResult } from 'scandit-datacapture-frameworks-id';\nexport { AamvaBarcodeVerificationStatus } from 'scandit-datacapture-frameworks-id';\nexport { DataConsistencyResult } from 'scandit-datacapture-frameworks-id';\nexport { DataConsistencyCheck } from 'scandit-datacapture-frameworks-id';\nexport { VerificationResult } from 'scandit-datacapture-frameworks-id';\n// Driving License Details\nexport { ProfessionalDrivingPermit } from 'scandit-datacapture-frameworks-id';\nexport { VehicleRestriction } from 'scandit-datacapture-frameworks-id';\nexport { DrivingLicenseCategory } from 'scandit-datacapture-frameworks-id';\nexport { DrivingLicenseDetails } from 'scandit-datacapture-frameworks-id';\n// Internal Controllers, Proxies & Events\nexport { IdCaptureController } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureListenerController } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureListenerEvents } from 'scandit-datacapture-frameworks-id';\n// React Native Components\nexport * from './IdCaptureView';\n//# sourceMappingURL=index.js.map"],"names":[],"mappings":";;;;;;;AAGO,SAAS,WAAW,GAAG;AAC9B,IAAI,YAAY,CAAC,gBAAgB,CAAC,gBAAgB,EAAE,MAAM;AAC1D,QAAQ,MAAM,MAAM,GAAG,oBAAoB,CAAC,aAAa,CAAC,oBAAoB,CAAC,CAAC;AAChF,QAAQ,OAAO,iBAAiB,CAAC,MAAM,CAAC,CAAC;AACzC,KAAK,CAAC,CAAC;AACP,IAAI,YAAY,CAAC,gBAAgB,CAAC,wBAAwB,EAAE,MAAM;AAClE,QAAQ,MAAM,MAAM,GAAG,oBAAoB,CAAC,aAAa,CAAC,oBAAoB,CAAC,CAAC;AAChF,QAAQ,OAAO,iBAAiB,CAAC,MAAM,CAAC,CAAC;AACzC,KAAK,CAAC,CAAC;AACP,IAAI,YAAY,CAAC,gBAAgB,CAAC,uBAAuB,EAAE,MAAM;AACjE,QAAQ,MAAM,MAAM,GAAG,oBAAoB,CAAC,aAAa,CAAC,oBAAoB,CAAC,CAAC;AAChF,QAAQ,OAAO,iBAAiB,CAAC,MAAM,CAAC,CAAC;AACzC,KAAK,CAAC,CAAC;AACP;;ACbA,MAAM,aAAa,GAAG,aAAa,CAAC,oBAAoB,CAAC;AAClD,SAAS,cAAc,GAAG;AACjC,IAAI,gBAAgB,EAAE,CAAC;AACvB,IAAI,cAAc,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;AAC3C;;ACFA;AACY,MAAC,aAAa,GAAG,UAAU,CAAC,SAAS,aAAa,CAAC,KAAK,EAAE,GAAG,EAAE;AAC3E,IAAI,mBAAmB,CAAC,GAAG,EAAE,OAAO;AACpC,QAAQ,KAAK,GAAG;AAChB,YAAY,OAAO,EAAE,CAAC,KAAK,EAAE,CAAC;AAC9B,SAAS;AACT,KAAK,CAAC;AACN;AACA,IAAI,EAAE,CAAC,CAAC;AACR;AACA,IAAI,MAAM,CAAC,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AAC,EAAE;AAClB;AACA,YAAY,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AAC7B,SAAS;AACT,KAAK,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC;AAC/C,IAAI,OAAO,KAAK,CAAC,aAAa,CAAC,eAAe,EAAE,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,GAAG,EAAE,OAAO,EAAE,CAAC,CAAC;AAChI,CAAC;;ACtRD,cAAc,EAAE,CAAC;AACjB,WAAW,EAAE;;;;"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../ts/native/IdNativeCallerProvider.ts","../ts/native/initProxy.ts","../ts/private/initDefaults.ts","../ts/IdCaptureView.tsx","../ts/index.ts"],"sourcesContent":["import { NativeModules } from 'react-native';\nimport { ID_PROXY_TYPE_NAMES } from 'scandit-datacapture-frameworks-id';\nimport { createRNNativeCaller } from 'scandit-react-native-datacapture-core';\nexport class RNIdNativeCallerProvider {\n getNativeCaller(proxyType) {\n if (!ID_PROXY_TYPE_NAMES.includes(proxyType)) {\n throw new Error(`No native module mapped for proxy type: ${proxyType}`);\n }\n return createRNNativeCaller(NativeModules.ScanditDataCaptureId);\n }\n}\n//# sourceMappingURL=IdNativeCallerProvider.js.map","import { registerIdProxies } from 'scandit-datacapture-frameworks-id';\nimport { RNIdNativeCallerProvider } from './IdNativeCallerProvider';\nexport function initIdProxy() {\n registerIdProxies(new RNIdNativeCallerProvider());\n}\n//# sourceMappingURL=initProxy.js.map","import { initCoreDefaults } from 'scandit-react-native-datacapture-core';\nimport { loadIdDefaults } from 'scandit-datacapture-frameworks-id';\nimport { getNativeModule } from 'scandit-react-native-datacapture-core';\nconst dataCaptureId = getNativeModule('ScanditDataCaptureId');\nexport function initIdDefaults() {\n initCoreDefaults();\n loadIdDefaults(dataCaptureId.Defaults);\n}\n//# sourceMappingURL=initDefaults.js.map","import React, { useEffect, useRef, useState, forwardRef, useImperativeHandle, useMemo, useCallback } from 'react';\nimport { AppState } from 'react-native';\nimport { CameraPosition, DataCaptureView, FrameSourceState, } from 'scandit-react-native-datacapture-core';\nimport { IdCapture, IdCaptureOverlay, IdCaptureSettings, } from 'scandit-datacapture-frameworks-id';\nimport { CameraOwnershipHelper } from 'scandit-datacapture-frameworks-core';\n// tslint:disable-next-line\nexport const IdCaptureView = forwardRef(function IdCaptureView(props, ref) {\n useImperativeHandle(ref, () => ({\n reset() {\n void getMode().reset();\n },\n }), []);\n /* STATE VARIABLES */\n const [isEnabledState, setIsEnabledState] = useState(false);\n const [frameSourceState, setFrameSourceState] = useState(FrameSourceState.Off);\n const [viewId] = useState(() => Math.floor(Math.random() * 1000000));\n const [isCameraSetup, setIsCameraSetup] = useState(false);\n // Create camera owner using viewId\n const cameraOwner = useMemo(() => ({\n id: `id-capture-view-${viewId}`,\n }), [viewId]);\n /* STATE HANDLERS */\n const getMode = useCallback(() => {\n if (idCaptureModeRef.current !== null) {\n return idCaptureModeRef.current;\n }\n idCaptureModeRef.current = new IdCapture(props.idCaptureSettings || new IdCaptureSettings());\n idCaptureModeRef.current['parentId'] = viewId;\n return idCaptureModeRef.current;\n }, [props.idCaptureSettings, viewId]);\n useEffect(() => {\n getMode().isEnabled = isEnabledState;\n }, [isEnabledState, getMode]);\n useEffect(() => {\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.switchToDesiredState(frameSourceState);\n });\n }, [frameSourceState, props.desiredCameraPosition, cameraOwner]);\n const viewRef = useRef(null);\n const componentIsSetUp = useRef(false);\n const idCaptureModeRef = useRef(null);\n const idCaptureOverlayRef = useRef(null);\n const getIdCaptureOverlay = useCallback(() => {\n if (idCaptureOverlayRef.current !== null) {\n return idCaptureOverlayRef.current;\n }\n idCaptureOverlayRef.current = new IdCaptureOverlay(getMode());\n return idCaptureOverlayRef.current;\n }, [getMode]);\n // Remove getCamera function as we'll use CameraOwnershipHelper\n const torchSwitchControl = useRef(null);\n const zoomSwitchControl = useRef(null);\n const appState = useRef(AppState.currentState);\n /* SETUP */\n useEffect(() => {\n doSetup();\n const subscription = AppState.addEventListener('change', nextAppState => {\n if (appState.current.match(/inactive|background/) && nextAppState === 'active') {\n setIsEnabledState(props.isEnabled);\n setFrameSourceState(props.desiredCameraState || FrameSourceState.On);\n }\n else {\n setIsEnabledState(false);\n setFrameSourceState(FrameSourceState.Off);\n }\n appState.current = nextAppState;\n });\n return () => {\n subscription.remove();\n doDestroy();\n };\n }, []);\n const setupCamera = useCallback(async () => {\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n // Request ownership and set up camera\n await CameraOwnershipHelper.withCameraWhenAvailable(position, cameraOwner, async (camera) => {\n const settings = props.cameraSettings || IdCapture.createRecommendedCameraSettings();\n await camera.applySettings(settings);\n await props.context.setFrameSource(camera);\n await camera.switchToDesiredState(props.desiredCameraState || FrameSourceState.On);\n // Mark camera as set up\n setIsCameraSetup(true);\n });\n }, [props.desiredCameraPosition, cameraOwner, props.cameraSettings, props.context, props.desiredCameraState]);\n const doSetup = useCallback(() => {\n if (componentIsSetUp.current)\n return;\n componentIsSetUp.current = true;\n /* Setup camera with ownership - Fire-and-forget */\n void setupCamera();\n /* Only proceed after camera is ready - these operations are async but errors are handled internally */\n void props.context.removeAllModes();\n void props.context.addMode(getMode());\n /* Adding ID Capture Overlay */\n if (viewRef.current) {\n void viewRef.current.addOverlay(getIdCaptureOverlay());\n }\n }, [setupCamera, props.context, getMode, getIdCaptureOverlay]);\n const doDestroy = () => {\n doCleanup();\n idCaptureModeRef.current = null;\n torchSwitchControl.current = null;\n zoomSwitchControl.current = null;\n idCaptureOverlayRef.current = null;\n };\n const doCleanup = useCallback(() => {\n if (!componentIsSetUp.current)\n return;\n componentIsSetUp.current = false;\n // Reset camera setup state\n setIsCameraSetup(false);\n /* Remove the torch control */\n if (torchSwitchControl.current) {\n viewRef.current?.removeControl(torchSwitchControl.current);\n }\n /* Remove the zoom control */\n if (zoomSwitchControl.current) {\n viewRef.current?.removeControl(zoomSwitchControl.current);\n }\n /* Cleaning Data Capture Context */\n if (idCaptureModeRef.current) {\n void props.context.removeMode(idCaptureModeRef.current);\n }\n /* Cleaning Overlays */\n if (viewRef.current) {\n viewRef.current['view']?.overlays?.forEach((overlay) => {\n void viewRef.current?.['view']?.removeOverlay(overlay);\n });\n }\n /* Turn off camera and release ownership - Fire-and-forget cleanup */\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call\n void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.switchToDesiredState(FrameSourceState.Off);\n await props.context.setFrameSource(null);\n }).finally(() => {\n // Release camera ownership\n CameraOwnershipHelper.releaseOwnership(position, cameraOwner);\n });\n }, [props.desiredCameraPosition, cameraOwner, props.context]);\n /* ID CAPTURE MODE */\n useEffect(() => {\n if (props.idCaptureSettings) {\n void getMode().applySettings(props.idCaptureSettings);\n }\n }, [props.idCaptureSettings, getMode]);\n useEffect(() => {\n setIsEnabledState(props.isEnabled);\n setFrameSourceState(props.desiredCameraState || FrameSourceState.On);\n }, [props.isEnabled, props.desiredCameraState]);\n const listenerRef = useRef(null);\n const callbacksRef = useRef({ didCaptureId: props.didCaptureId, didRejectId: props.didRejectId });\n // Update callback references when props change\n useEffect(() => {\n callbacksRef.current = { didCaptureId: props.didCaptureId, didRejectId: props.didRejectId };\n }, [props.didCaptureId, props.didRejectId]);\n // Add/remove listener only when needed\n useEffect(() => {\n void (async () => {\n const shouldHaveListener = props.didCaptureId || props.didRejectId;\n const hasListener = listenerRef.current !== null;\n if (shouldHaveListener && !hasListener) {\n // Add listener\n listenerRef.current = {\n didCaptureId: (idCapture, capturedId) => callbacksRef.current.didCaptureId?.(idCapture, capturedId),\n didRejectId: (idCapture, rejectedId, reason) => callbacksRef.current.didRejectId?.(idCapture, rejectedId, reason),\n };\n await getMode().addListener(listenerRef.current);\n }\n else if (!shouldHaveListener && hasListener && listenerRef.current) {\n // Remove listener\n await getMode().removeListener(listenerRef.current);\n listenerRef.current = null;\n }\n })();\n }, [props.didCaptureId, props.didRejectId, getMode, listenerRef, callbacksRef]);\n /* OVERLAYS */\n useEffect(() => {\n if (props.capturedBrush) {\n getIdCaptureOverlay().capturedBrush = props.capturedBrush;\n }\n if (props.rejectedBrush) {\n getIdCaptureOverlay().rejectedBrush = props.rejectedBrush;\n }\n if (props.localizedBrush) {\n getIdCaptureOverlay().localizedBrush = props.localizedBrush;\n }\n }, [props.capturedBrush, props.rejectedBrush, props.localizedBrush, getIdCaptureOverlay]);\n /* CAMERA */\n useEffect(() => {\n if (!isCameraSetup)\n return; // Don't run until camera is ready\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n const settings = props.cameraSettings || IdCapture.createRecommendedCameraSettings();\n void CameraOwnershipHelper.withCamera(position, cameraOwner, async (camera) => {\n await camera.applySettings(settings);\n });\n }, [props.cameraSettings, props.desiredCameraPosition, cameraOwner, isCameraSetup]);\n useEffect(() => {\n if (props.desiredCameraState) {\n setFrameSourceState(props.desiredCameraState);\n }\n }, [props.desiredCameraState]);\n useEffect(() => {\n if (!props.desiredCameraPosition)\n return;\n void (async () => {\n // Handle camera position change with ownership\n const currentOwnedPosition = CameraOwnershipHelper.getOwnedPosition(cameraOwner);\n const newPosition = props.desiredCameraPosition;\n if (currentOwnedPosition && currentOwnedPosition !== newPosition) {\n // Release old camera ownership\n CameraOwnershipHelper.releaseOwnership(currentOwnedPosition, cameraOwner);\n // Set up new camera\n await setupCamera();\n }\n else if (!currentOwnedPosition) {\n // No camera owned yet, set up new camera\n await setupCamera();\n }\n })();\n }, [props.desiredCameraPosition, cameraOwner, setupCamera]);\n /* CONTROLS */\n useEffect(() => {\n if (!props.desiredTorchState)\n return;\n const position = props.desiredCameraPosition || CameraPosition.WorldFacing;\n void CameraOwnershipHelper.withCameraWhenAvailable(position, cameraOwner, camera => {\n camera.desiredTorchState = props.desiredTorchState;\n });\n }, [props.desiredTorchState, props.desiredCameraPosition, cameraOwner]);\n useEffect(() => {\n if (!viewRef.current)\n return;\n if (torchSwitchControl.current) {\n viewRef.current?.removeControl(torchSwitchControl.current);\n }\n if (!props.torchSwitchControl)\n return;\n torchSwitchControl.current = props.torchSwitchControl;\n void viewRef.current.addControl(torchSwitchControl.current);\n }, [props.torchSwitchControl]);\n useEffect(() => {\n if (!viewRef.current)\n return;\n if (zoomSwitchControl.current) {\n viewRef.current?.removeControl(zoomSwitchControl.current);\n }\n if (!props.zoomSwitchControl)\n return;\n zoomSwitchControl.current = props.zoomSwitchControl;\n void viewRef.current.addControl(zoomSwitchControl.current);\n }, [props.zoomSwitchControl]);\n /* MISC */\n useEffect(() => {\n if (props.feedback) {\n getMode().feedback = props.feedback;\n }\n }, [props.feedback, getMode]);\n useEffect(() => {\n if (!props.navigation)\n return;\n try {\n const unsubscribeFromFocus = props.navigation.addListener('focus', () => {\n doSetup();\n });\n const unsubscribeFromBlur = props.navigation.addListener('blur', () => {\n doCleanup();\n });\n return () => {\n unsubscribeFromFocus();\n unsubscribeFromBlur();\n };\n }\n catch (e) {\n // tslint:disable-next-line:no-console\n console.error(e);\n }\n }, [props.navigation, doSetup, doCleanup]);\n return React.createElement(DataCaptureView, { context: props.context, parentId: viewId, style: { flex: 1 }, ref: viewRef });\n});\n//# sourceMappingURL=IdCaptureView.js.map","import { initIdProxy } from './native/initProxy';\nimport { initIdDefaults } from './private/initDefaults';\ninitIdDefaults();\ninitIdProxy();\n// Core ID Types\nexport { DateResult } from 'scandit-datacapture-frameworks-id';\nexport { IdAnonymizationMode } from 'scandit-datacapture-frameworks-id';\nexport { IdFieldType } from 'scandit-datacapture-frameworks-id';\nexport { IdImageType } from 'scandit-datacapture-frameworks-id';\nexport { CapturedSides } from 'scandit-datacapture-frameworks-id';\nexport { TextHintPosition } from 'scandit-datacapture-frameworks-id';\nexport { BarcodeResult } from 'scandit-datacapture-frameworks-id';\nexport { Duration } from 'scandit-datacapture-frameworks-id';\nexport { IdImages } from 'scandit-datacapture-frameworks-id';\nexport { IdSide } from 'scandit-datacapture-frameworks-id';\nexport { Sex } from 'scandit-datacapture-frameworks-id';\nexport { UsRealIdStatus } from 'scandit-datacapture-frameworks-id';\n// Captured ID Data\nexport { CapturedId } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentOCRResult } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentResult } from 'scandit-datacapture-frameworks-id';\nexport { MRZResult } from 'scandit-datacapture-frameworks-id';\nexport { VIZResult } from 'scandit-datacapture-frameworks-id';\n// ID Capture\nexport { IdCapture } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureFeedback } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureOverlay } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureSettings } from 'scandit-datacapture-frameworks-id';\nexport { IdLayoutLineStyle } from 'scandit-datacapture-frameworks-id';\nexport { IdLayoutStyle } from 'scandit-datacapture-frameworks-id';\nexport { RejectionReason } from 'scandit-datacapture-frameworks-id';\n// Document Types\nexport { IdCaptureDocumentType } from 'scandit-datacapture-frameworks-id';\nexport { DriverLicense } from 'scandit-datacapture-frameworks-id';\nexport { HealthInsuranceCard } from 'scandit-datacapture-frameworks-id';\nexport { IdCard } from 'scandit-datacapture-frameworks-id';\nexport { Passport } from 'scandit-datacapture-frameworks-id';\nexport { RegionSpecific } from 'scandit-datacapture-frameworks-id';\nexport { ResidencePermit } from 'scandit-datacapture-frameworks-id';\nexport { VisaIcao } from 'scandit-datacapture-frameworks-id';\n// Scanners & Regions\nexport { IdCaptureScanner } from 'scandit-datacapture-frameworks-id';\nexport { SingleSideScanner } from 'scandit-datacapture-frameworks-id';\nexport { FullDocumentScanner } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentScanner } from 'scandit-datacapture-frameworks-id';\nexport { MobileDocumentDataElement } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureRegion } from 'scandit-datacapture-frameworks-id';\nexport { RegionSpecificSubtype } from 'scandit-datacapture-frameworks-id';\n// Verification & Validation\nexport { AamvaBarcodeVerificationResult } from 'scandit-datacapture-frameworks-id';\nexport { AamvaBarcodeVerificationStatus } from 'scandit-datacapture-frameworks-id';\nexport { DataConsistencyResult } from 'scandit-datacapture-frameworks-id';\nexport { DataConsistencyCheck } from 'scandit-datacapture-frameworks-id';\nexport { VerificationResult } from 'scandit-datacapture-frameworks-id';\n// Driving License Details\nexport { ProfessionalDrivingPermit } from 'scandit-datacapture-frameworks-id';\nexport { VehicleRestriction } from 'scandit-datacapture-frameworks-id';\nexport { DrivingLicenseCategory } from 'scandit-datacapture-frameworks-id';\nexport { DrivingLicenseDetails } from 'scandit-datacapture-frameworks-id';\n// Internal Controllers, Proxies & Events\nexport { IdCaptureController } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureListenerController } from 'scandit-datacapture-frameworks-id';\nexport { IdCaptureListenerEvents } from 'scandit-datacapture-frameworks-id';\n// React Native Components\nexport * from './IdCaptureView';\n//# sourceMappingURL=index.js.map"],"names":[],"mappings":";;;;;;;AAGO,MAAM,wBAAwB,CAAC;AACtC,IAAI,eAAe,CAAC,SAAS,EAAE;AAC/B,QAAQ,IAAI,CAAC,mBAAmB,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE;AACtD,YAAY,MAAM,IAAI,KAAK,CAAC,CAAC,wCAAwC,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC;AACpF,SAAS;AACT,QAAQ,OAAO,oBAAoB,CAAC,aAAa,CAAC,oBAAoB,CAAC,CAAC;AACxE,KAAK;AACL;;ACRO,SAAS,WAAW,GAAG;AAC9B,IAAI,iBAAiB,CAAC,IAAI,wBAAwB,EAAE,CAAC,CAAC;AACtD;;ACDA,MAAM,aAAa,GAAG,eAAe,CAAC,sBAAsB,CAAC,CAAC;AACvD,SAAS,cAAc,GA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