@trustchex/react-native-sdk 1.409.0 → 1.464.0
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/src/main/java/com/trustchex/reactnativesdk/TrustchexSDKModule.kt +2 -8
- package/android/src/main/java/com/trustchex/reactnativesdk/camera/TrustchexCameraView.kt +59 -1
- package/ios/Camera/TrustchexCameraView.swift +9 -1
- package/lib/module/Screens/Debug/NFCScanTestScreen.js +635 -0
- package/lib/module/Screens/Dynamic/ContractAcceptanceScreen.js +1 -4
- package/lib/module/Screens/Dynamic/IdentityDocumentEIDScanningScreen.js +17 -4
- package/lib/module/Screens/Dynamic/LivenessDetectionScreen.js +102 -23
- package/lib/module/Screens/Dynamic/VerbalConsentScreen.js +1079 -0
- package/lib/module/Screens/Dynamic/VideoCallScreen.js +3 -1
- package/lib/module/Screens/Static/ResultScreen.js +128 -22
- package/lib/module/Screens/Static/VerificationSessionCheckScreen.js +8 -0
- package/lib/module/Shared/Animations/recording.json +1 -0
- package/lib/module/Shared/Components/DebugNavigationPanel.js +69 -71
- package/lib/module/Shared/Components/EIDScanner.js +212 -108
- package/lib/module/Shared/Components/IdentityDocumentCamera.flows.js +5 -3
- package/lib/module/Shared/Components/IdentityDocumentCamera.js +53 -36
- package/lib/module/Shared/Components/IdentityDocumentCamera.utils.js +13 -4
- package/lib/module/Shared/Components/NavigationManager.js +24 -16
- package/lib/module/Shared/EIDReader/aesSecureMessagingWrapper.js +51 -0
- package/lib/module/Shared/EIDReader/apduLevelPACECapable.js +3 -0
- package/lib/module/Shared/EIDReader/bacKey.js +16 -2
- package/lib/module/Shared/EIDReader/eidReader.js +354 -13
- package/lib/module/Shared/EIDReader/eidService.js +25 -1
- package/lib/module/Shared/EIDReader/nfcManagerCardService.js +4 -7
- package/lib/module/Shared/EIDReader/paceInfo.js +85 -0
- package/lib/module/Shared/EIDReader/paceKeySpec.js +51 -0
- package/lib/module/Shared/EIDReader/protocol/paceAPDUSender.js +100 -0
- package/lib/module/Shared/EIDReader/protocol/paceProtocol.js +655 -0
- package/lib/module/Shared/EIDReader/protocol/paceResult.js +37 -0
- package/lib/module/Shared/EIDReader/secureMessagingWrapper.js +27 -4
- package/lib/module/Shared/EIDReader/smartcards/commandAPDU.js +2 -1
- package/lib/module/Shared/EIDReader/tlv/tlv.helpers.js +1 -1
- package/lib/module/Shared/EIDReader/tlv/tlv.utils.js +6 -3
- package/lib/module/Shared/EIDReader/utils/aesCrypto.utils.js +189 -0
- package/lib/module/Shared/Libs/analytics.utils.js +4 -0
- package/lib/module/Shared/Libs/contains.js +1 -40
- package/lib/module/Shared/Libs/country-display.utils.js +34 -0
- package/lib/module/Shared/Libs/demo.utils.js +8 -0
- package/lib/module/Shared/Libs/mrz.utils.js +3 -2
- package/lib/module/Shared/Libs/status-bar.utils.js +4 -2
- package/lib/module/Shared/Types/analytics.types.js +2 -0
- package/lib/module/Translation/Resources/en.js +41 -2
- package/lib/module/Translation/Resources/tr.js +41 -2
- package/lib/module/Trustchex.js +54 -20
- package/lib/module/version.js +1 -1
- package/lib/typescript/src/Screens/Debug/NFCScanTestScreen.d.ts +3 -0
- package/lib/typescript/src/Screens/Debug/NFCScanTestScreen.d.ts.map +1 -0
- package/lib/typescript/src/Screens/Dynamic/ContractAcceptanceScreen.d.ts.map +1 -1
- package/lib/typescript/src/Screens/Dynamic/IdentityDocumentEIDScanningScreen.d.ts.map +1 -1
- package/lib/typescript/src/Screens/Dynamic/LivenessDetectionScreen.d.ts.map +1 -1
- package/lib/typescript/src/Screens/Dynamic/VerbalConsentScreen.d.ts +3 -0
- package/lib/typescript/src/Screens/Dynamic/VerbalConsentScreen.d.ts.map +1 -0
- package/lib/typescript/src/Screens/Dynamic/VideoCallScreen.d.ts.map +1 -1
- package/lib/typescript/src/Screens/Static/ResultScreen.d.ts.map +1 -1
- package/lib/typescript/src/Screens/Static/VerificationSessionCheckScreen.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/DebugNavigationPanel.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/EIDScanner.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.flows.d.ts +1 -1
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.flows.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.utils.d.ts +5 -0
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/NavigationManager.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/aesSecureMessagingWrapper.d.ts +18 -0
- package/lib/typescript/src/Shared/EIDReader/aesSecureMessagingWrapper.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/apduLevelPACECapable.d.ts +23 -0
- package/lib/typescript/src/Shared/EIDReader/apduLevelPACECapable.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/bacKey.d.ts +6 -0
- package/lib/typescript/src/Shared/EIDReader/bacKey.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/eidReader.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/eidService.d.ts +9 -0
- package/lib/typescript/src/Shared/EIDReader/eidService.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/nfcManagerCardService.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/paceInfo.d.ts +50 -0
- package/lib/typescript/src/Shared/EIDReader/paceInfo.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/paceKeySpec.d.ts +30 -0
- package/lib/typescript/src/Shared/EIDReader/paceKeySpec.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceAPDUSender.d.ts +17 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceAPDUSender.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceProtocol.d.ts +105 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceProtocol.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceResult.d.ts +24 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceResult.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/secureMessagingWrapper.d.ts +15 -0
- package/lib/typescript/src/Shared/EIDReader/secureMessagingWrapper.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/smartcards/commandAPDU.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/tlv/tlv.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/utils/aesCrypto.utils.d.ts +39 -0
- package/lib/typescript/src/Shared/EIDReader/utils/aesCrypto.utils.d.ts.map +1 -0
- package/lib/typescript/src/Shared/Libs/analytics.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/contains.d.ts +0 -7
- package/lib/typescript/src/Shared/Libs/contains.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/country-display.utils.d.ts +2 -0
- package/lib/typescript/src/Shared/Libs/country-display.utils.d.ts.map +1 -0
- package/lib/typescript/src/Shared/Libs/demo.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/http-client.d.ts +1 -1
- package/lib/typescript/src/Shared/Libs/http-client.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/mrz.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/status-bar.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Types/analytics.types.d.ts +2 -0
- package/lib/typescript/src/Shared/Types/analytics.types.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Types/identificationInfo.d.ts +10 -1
- package/lib/typescript/src/Shared/Types/identificationInfo.d.ts.map +1 -1
- package/lib/typescript/src/Translation/Resources/en.d.ts +40 -1
- package/lib/typescript/src/Translation/Resources/en.d.ts.map +1 -1
- package/lib/typescript/src/Translation/Resources/tr.d.ts +40 -1
- package/lib/typescript/src/Translation/Resources/tr.d.ts.map +1 -1
- package/lib/typescript/src/Trustchex.d.ts.map +1 -1
- package/lib/typescript/src/version.d.ts +1 -1
- package/package.json +7 -4
- package/src/Screens/Debug/NFCScanTestScreen.tsx +692 -0
- package/src/Screens/Dynamic/ContractAcceptanceScreen.tsx +1 -4
- package/src/Screens/Dynamic/IdentityDocumentEIDScanningScreen.tsx +21 -4
- package/src/Screens/Dynamic/LivenessDetectionScreen.tsx +124 -23
- package/src/Screens/Dynamic/VerbalConsentScreen.tsx +1401 -0
- package/src/Screens/Dynamic/VideoCallScreen.tsx +3 -1
- package/src/Screens/Static/ResultScreen.tsx +183 -31
- package/src/Screens/Static/VerificationSessionCheckScreen.tsx +9 -0
- package/src/Shared/Animations/recording.json +1 -0
- package/src/Shared/Components/DebugNavigationPanel.tsx +73 -48
- package/src/Shared/Components/EIDScanner.tsx +222 -111
- package/src/Shared/Components/IdentityDocumentCamera.flows.ts +7 -4
- package/src/Shared/Components/IdentityDocumentCamera.tsx +199 -184
- package/src/Shared/Components/IdentityDocumentCamera.utils.ts +13 -4
- package/src/Shared/Components/NavigationManager.tsx +27 -18
- package/src/Shared/EIDReader/aesSecureMessagingWrapper.ts +69 -0
- package/src/Shared/EIDReader/apduLevelPACECapable.ts +34 -0
- package/src/Shared/EIDReader/bacKey.ts +24 -8
- package/src/Shared/EIDReader/eidReader.ts +398 -12
- package/src/Shared/EIDReader/eidService.ts +49 -1
- package/src/Shared/EIDReader/nfcManagerCardService.ts +4 -6
- package/src/Shared/EIDReader/paceInfo.ts +159 -0
- package/src/Shared/EIDReader/paceKeySpec.ts +56 -0
- package/src/Shared/EIDReader/protocol/paceAPDUSender.ts +163 -0
- package/src/Shared/EIDReader/protocol/paceProtocol.ts +946 -0
- package/src/Shared/EIDReader/protocol/paceResult.ts +62 -0
- package/src/Shared/EIDReader/secureMessagingWrapper.ts +28 -10
- package/src/Shared/EIDReader/smartcards/commandAPDU.ts +2 -1
- package/src/Shared/EIDReader/tlv/tlv.helpers.ts +1 -1
- package/src/Shared/EIDReader/tlv/tlv.utils.ts +8 -5
- package/src/Shared/EIDReader/utils/aesCrypto.utils.ts +217 -0
- package/src/Shared/Libs/analytics.utils.ts +4 -0
- package/src/Shared/Libs/contains.ts +0 -53
- package/src/Shared/Libs/country-display.utils.ts +55 -0
- package/src/Shared/Libs/crypto.utils.ts +2 -2
- package/src/Shared/Libs/demo.utils.ts +10 -0
- package/src/Shared/Libs/http-client.ts +12 -4
- package/src/Shared/Libs/mrz.utils.ts +3 -2
- package/src/Shared/Libs/status-bar.utils.ts +4 -2
- package/src/Shared/Services/VideoSessionService.ts +1 -1
- package/src/Shared/Types/analytics.types.ts +2 -0
- package/src/Shared/Types/identificationInfo.ts +11 -0
- package/src/Translation/Resources/en.ts +63 -3
- package/src/Translation/Resources/tr.ts +62 -3
- package/src/Trustchex.tsx +53 -17
- package/src/version.ts +1 -1
|
@@ -4,28 +4,15 @@ import React, { useCallback, useContext, useState } from 'react';
|
|
|
4
4
|
import { View, Text, TouchableOpacity, StyleSheet, Platform, Switch, ActivityIndicator } from 'react-native';
|
|
5
5
|
import { useNavigation } from '@react-navigation/native';
|
|
6
6
|
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
7
|
+
import { useTranslation } from 'react-i18next';
|
|
7
8
|
import AppContext from "../Contexts/AppContext.js";
|
|
8
9
|
import { getSimulatedDemoData } from "../Libs/demo.utils.js";
|
|
9
10
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
10
11
|
const DEV_BASE_URL = 'https://192.168.0.171:3000';
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
HANDSHAKE: '📝',
|
|
16
|
-
// Icons.handshake - Document for contract signing
|
|
17
|
-
CREDIT_CARD: '🪪',
|
|
18
|
-
// Icons.credit_card - ID card for document scan
|
|
19
|
-
NFC: '💳',
|
|
20
|
-
// Icons.nfc - Contactless card for eID
|
|
21
|
-
FACE: '📸',
|
|
22
|
-
// Icons.face - Camera for face detection
|
|
23
|
-
CHECK_CIRCLE: '📋',
|
|
24
|
-
// Icons.check_circle - Clipboard for results
|
|
25
|
-
BUG_REPORT: '🔧',
|
|
26
|
-
// Icons.bug_report - Wrench for debugging
|
|
27
|
-
PHONE: '💬' // Icons.phone - Message for OTP code
|
|
28
|
-
};
|
|
12
|
+
const DEBUG_VERBAL_CONSENT_TITLE_EN = 'Verbal Consent';
|
|
13
|
+
const DEBUG_VERBAL_CONSENT_TITLE_TR = 'Sözlü Onay';
|
|
14
|
+
const DEBUG_VERBAL_CONSENT_TEXT_EN = 'I confirm my identity and give my explicit consent to the processing of my personal data for digital identity verification. I acknowledge that my biometric data will be used solely for this purpose. I understand that I can withdraw this consent at any time.';
|
|
15
|
+
const DEBUG_VERBAL_CONSENT_TEXT_TR = 'Dijital kimlik doğrulama amacıyla kimliğimi teyit ediyor ve kişisel verilerimin işlenmesine açık rızamı veriyorum. Biyometrik verilerimin yalnızca kimlik doğrulama amacıyla işleneceğini kabul ediyorum. Bu onayı istediğim zaman geri çekebileceğimi biliyorum.';
|
|
29
16
|
const DebugNavigationPanel = () => {
|
|
30
17
|
const [isExpanded, setIsExpanded] = useState(false);
|
|
31
18
|
const [selectedScreen, setSelectedScreen] = useState(null);
|
|
@@ -37,6 +24,10 @@ const DebugNavigationPanel = () => {
|
|
|
37
24
|
const navigation = useNavigation();
|
|
38
25
|
const appContext = useContext(AppContext);
|
|
39
26
|
const insets = useSafeAreaInsets();
|
|
27
|
+
const {
|
|
28
|
+
i18n
|
|
29
|
+
} = useTranslation();
|
|
30
|
+
const isTurkish = (i18n.language || '').toLowerCase().startsWith('tr');
|
|
40
31
|
const setupDemoSession = useCallback((setDebugFlag = false) => {
|
|
41
32
|
appContext.setIsDemoSession?.(true);
|
|
42
33
|
appContext.identificationInfo.sessionId = 'demo-verification-id';
|
|
@@ -81,12 +72,10 @@ const DebugNavigationPanel = () => {
|
|
|
81
72
|
}, [appContext]);
|
|
82
73
|
const screens = [{
|
|
83
74
|
screen: 'VerificationSessionCheckScreen',
|
|
84
|
-
label: 'Session Check'
|
|
85
|
-
icon: ICONS.LOGIN
|
|
75
|
+
label: 'Session Check'
|
|
86
76
|
}, {
|
|
87
77
|
screen: 'OTPVerificationScreen',
|
|
88
78
|
label: 'OTP',
|
|
89
|
-
icon: ICONS.PHONE,
|
|
90
79
|
setupDemo: () => {
|
|
91
80
|
setupDemoSession(true);
|
|
92
81
|
},
|
|
@@ -96,7 +85,6 @@ const DebugNavigationPanel = () => {
|
|
|
96
85
|
}, {
|
|
97
86
|
screen: 'ContractAcceptanceScreen',
|
|
98
87
|
label: 'Consent',
|
|
99
|
-
icon: ICONS.HANDSHAKE,
|
|
100
88
|
hasOptions: true,
|
|
101
89
|
setupDemo: () => {
|
|
102
90
|
setupDemoSession(true);
|
|
@@ -106,10 +94,40 @@ const DebugNavigationPanel = () => {
|
|
|
106
94
|
appContext.currentWorkflowStep = contractStep;
|
|
107
95
|
}
|
|
108
96
|
}
|
|
97
|
+
}, {
|
|
98
|
+
screen: 'VerbalConsentScreen',
|
|
99
|
+
label: 'Verbal Consent',
|
|
100
|
+
hasOptions: true,
|
|
101
|
+
setupDemo: () => {
|
|
102
|
+
setupDemoSession(true);
|
|
103
|
+
const existingStep = appContext.workflowSteps?.find(s => s.type === 'VERBAL_CONSENT');
|
|
104
|
+
const localizedConsentTitle = isTurkish ? DEBUG_VERBAL_CONSENT_TITLE_TR : DEBUG_VERBAL_CONSENT_TITLE_EN;
|
|
105
|
+
const localizedConsentText = isTurkish ? DEBUG_VERBAL_CONSENT_TEXT_TR : DEBUG_VERBAL_CONSENT_TEXT_EN;
|
|
106
|
+
const localizedStep = existingStep ? {
|
|
107
|
+
...existingStep,
|
|
108
|
+
data: {
|
|
109
|
+
...existingStep.data,
|
|
110
|
+
verbalConsentTitle: localizedConsentTitle,
|
|
111
|
+
verbalConsentText: localizedConsentText,
|
|
112
|
+
voiceGuidanceActive: false
|
|
113
|
+
}
|
|
114
|
+
} : {
|
|
115
|
+
type: 'VERBAL_CONSENT',
|
|
116
|
+
required: true,
|
|
117
|
+
data: {
|
|
118
|
+
verbalConsentTitle: localizedConsentTitle,
|
|
119
|
+
verbalConsentText: localizedConsentText,
|
|
120
|
+
voiceGuidanceActive: false
|
|
121
|
+
}
|
|
122
|
+
};
|
|
123
|
+
if (appContext.workflowSteps) {
|
|
124
|
+
appContext.workflowSteps = appContext.workflowSteps.map(step => step.type === 'VERBAL_CONSENT' ? localizedStep : step);
|
|
125
|
+
}
|
|
126
|
+
appContext.currentWorkflowStep = localizedStep;
|
|
127
|
+
}
|
|
109
128
|
}, {
|
|
110
129
|
screen: 'IdentityDocumentScanningScreen',
|
|
111
130
|
label: 'ID Scan',
|
|
112
|
-
icon: ICONS.CREDIT_CARD,
|
|
113
131
|
hasOptions: true,
|
|
114
132
|
hasDocumentTypeOption: true,
|
|
115
133
|
setupDemo: () => {
|
|
@@ -122,7 +140,6 @@ const DebugNavigationPanel = () => {
|
|
|
122
140
|
}, {
|
|
123
141
|
screen: 'IdentityDocumentEIDScanningScreen',
|
|
124
142
|
label: 'eID Scan',
|
|
125
|
-
icon: ICONS.NFC,
|
|
126
143
|
hasOptions: true,
|
|
127
144
|
hasDocumentTypeOption: true,
|
|
128
145
|
setupDemo: () => {
|
|
@@ -135,7 +152,6 @@ const DebugNavigationPanel = () => {
|
|
|
135
152
|
}, {
|
|
136
153
|
screen: 'LivenessDetectionScreen',
|
|
137
154
|
label: 'Liveness',
|
|
138
|
-
icon: ICONS.FACE,
|
|
139
155
|
hasOptions: true,
|
|
140
156
|
setupDemo: () => {
|
|
141
157
|
setupDemoSession(true);
|
|
@@ -147,25 +163,27 @@ const DebugNavigationPanel = () => {
|
|
|
147
163
|
}, {
|
|
148
164
|
screen: 'ResultScreen',
|
|
149
165
|
label: 'Result',
|
|
150
|
-
icon: ICONS.CHECK_CIRCLE,
|
|
151
166
|
setupDemo: () => {
|
|
152
167
|
setupDemoSession();
|
|
153
168
|
}
|
|
154
169
|
}, {
|
|
155
170
|
screen: 'MRZTestScreen',
|
|
156
171
|
label: 'MRZ Test',
|
|
157
|
-
icon: ICONS.BUG_REPORT,
|
|
158
172
|
isDebug: true
|
|
159
173
|
}, {
|
|
160
174
|
screen: 'BarcodeTestScreen',
|
|
161
175
|
label: 'Barcode Test',
|
|
162
|
-
|
|
176
|
+
isDebug: true
|
|
177
|
+
}, {
|
|
178
|
+
screen: 'NFCScanTestScreen',
|
|
179
|
+
label: 'NFC Scan Test',
|
|
163
180
|
isDebug: true
|
|
164
181
|
}];
|
|
165
182
|
const selectScreen = useCallback(screen => {
|
|
166
183
|
if (!screen.hasOptions) {
|
|
167
184
|
if (screen.setupDemo) {
|
|
168
185
|
screen.setupDemo();
|
|
186
|
+
applyVoiceGuidance(voiceGuidanceEnabled);
|
|
169
187
|
}
|
|
170
188
|
navigation.navigate(screen.screen, screen.params);
|
|
171
189
|
setIsExpanded(false);
|
|
@@ -175,7 +193,7 @@ const DebugNavigationPanel = () => {
|
|
|
175
193
|
setVoiceGuidanceEnabled(true);
|
|
176
194
|
setAllowIdCard(true);
|
|
177
195
|
setAllowPassport(true);
|
|
178
|
-
}, [navigation]);
|
|
196
|
+
}, [navigation, voiceGuidanceEnabled, applyVoiceGuidance]);
|
|
179
197
|
const handleVideoCallTest = useCallback(async () => {
|
|
180
198
|
setIsConnectingVideoCall(true);
|
|
181
199
|
setVideoCallError(null);
|
|
@@ -269,14 +287,14 @@ const DebugNavigationPanel = () => {
|
|
|
269
287
|
style: styles.title,
|
|
270
288
|
children: "SDK JUMP TO SCREEN:"
|
|
271
289
|
}), selectedScreen ? /*#__PURE__*/_jsxs(View, {
|
|
272
|
-
children: [/*#__PURE__*/
|
|
290
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
273
291
|
style: styles.optionsTitle,
|
|
274
|
-
children:
|
|
292
|
+
children: selectedScreen.label
|
|
275
293
|
}), /*#__PURE__*/_jsxs(View, {
|
|
276
294
|
style: styles.optionRow,
|
|
277
295
|
children: [/*#__PURE__*/_jsx(Text, {
|
|
278
296
|
style: styles.optionLabel,
|
|
279
|
-
children: "
|
|
297
|
+
children: "Voice Guidance"
|
|
280
298
|
}), /*#__PURE__*/_jsx(Switch, {
|
|
281
299
|
value: voiceGuidanceEnabled,
|
|
282
300
|
onValueChange: setVoiceGuidanceEnabled,
|
|
@@ -291,7 +309,7 @@ const DebugNavigationPanel = () => {
|
|
|
291
309
|
style: styles.optionRow,
|
|
292
310
|
children: [/*#__PURE__*/_jsx(Text, {
|
|
293
311
|
style: styles.optionLabel,
|
|
294
|
-
children: "
|
|
312
|
+
children: "Allow ID Card"
|
|
295
313
|
}), /*#__PURE__*/_jsx(Switch, {
|
|
296
314
|
value: allowIdCard,
|
|
297
315
|
onValueChange: setAllowIdCard,
|
|
@@ -305,7 +323,7 @@ const DebugNavigationPanel = () => {
|
|
|
305
323
|
style: styles.optionRow,
|
|
306
324
|
children: [/*#__PURE__*/_jsx(Text, {
|
|
307
325
|
style: styles.optionLabel,
|
|
308
|
-
children: "
|
|
326
|
+
children: "Allow Passport"
|
|
309
327
|
}), /*#__PURE__*/_jsx(Switch, {
|
|
310
328
|
value: allowPassport,
|
|
311
329
|
onValueChange: setAllowPassport,
|
|
@@ -336,16 +354,13 @@ const DebugNavigationPanel = () => {
|
|
|
336
354
|
})]
|
|
337
355
|
})]
|
|
338
356
|
}) : /*#__PURE__*/_jsxs(_Fragment, {
|
|
339
|
-
children: [screens.filter(s => !s.isDebug).map(screen => /*#__PURE__*/
|
|
357
|
+
children: [screens.filter(s => !s.isDebug).map(screen => /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
340
358
|
style: styles.screenButton,
|
|
341
359
|
onPress: () => selectScreen(screen),
|
|
342
|
-
children:
|
|
343
|
-
style: styles.screenIcon,
|
|
344
|
-
children: screen.icon
|
|
345
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
360
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
346
361
|
style: styles.screenLabel,
|
|
347
362
|
children: screen.label
|
|
348
|
-
})
|
|
363
|
+
})
|
|
349
364
|
}, screen.screen)), /*#__PURE__*/_jsxs(View, {
|
|
350
365
|
style: styles.sectionDivider,
|
|
351
366
|
children: [/*#__PURE__*/_jsx(View, {
|
|
@@ -356,26 +371,20 @@ const DebugNavigationPanel = () => {
|
|
|
356
371
|
}), /*#__PURE__*/_jsx(View, {
|
|
357
372
|
style: styles.sectionDividerLine
|
|
358
373
|
})]
|
|
359
|
-
}), screens.filter(s => s.isDebug).map(screen => /*#__PURE__*/
|
|
374
|
+
}), screens.filter(s => s.isDebug).map(screen => /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
360
375
|
style: styles.debugScreenButton,
|
|
361
376
|
onPress: () => selectScreen(screen),
|
|
362
|
-
children:
|
|
363
|
-
style: styles.screenIcon,
|
|
364
|
-
children: screen.icon
|
|
365
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
377
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
366
378
|
style: styles.debugScreenLabel,
|
|
367
379
|
children: screen.label
|
|
368
|
-
})
|
|
380
|
+
})
|
|
369
381
|
}, screen.screen)), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
370
382
|
style: [styles.videoCallTestButton, isConnectingVideoCall && styles.videoCallTestButtonDisabled],
|
|
371
383
|
onPress: handleVideoCallTest,
|
|
372
384
|
disabled: isConnectingVideoCall,
|
|
373
|
-
children: [isConnectingVideoCall
|
|
385
|
+
children: [isConnectingVideoCall && /*#__PURE__*/_jsx(ActivityIndicator, {
|
|
374
386
|
size: "small",
|
|
375
387
|
color: "#4CAF50"
|
|
376
|
-
}) : /*#__PURE__*/_jsx(Text, {
|
|
377
|
-
style: styles.screenIcon,
|
|
378
|
-
children: "\uD83D\uDCF9"
|
|
379
388
|
}), /*#__PURE__*/_jsx(Text, {
|
|
380
389
|
style: styles.videoCallTestLabel,
|
|
381
390
|
children: isConnectingVideoCall ? 'Connecting...' : 'Video Call Test'
|
|
@@ -394,18 +403,13 @@ const DebugNavigationPanel = () => {
|
|
|
394
403
|
setAllowIdCard(true);
|
|
395
404
|
setAllowPassport(true);
|
|
396
405
|
},
|
|
397
|
-
children: [/*#__PURE__*/
|
|
398
|
-
|
|
399
|
-
children: ICONS.BUG_REPORT
|
|
400
|
-
}), isExpanded && /*#__PURE__*/_jsxs(_Fragment, {
|
|
401
|
-
children: [/*#__PURE__*/_jsx(View, {
|
|
402
|
-
style: styles.spacing
|
|
403
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
406
|
+
children: [isExpanded && /*#__PURE__*/_jsxs(_Fragment, {
|
|
407
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
404
408
|
style: styles.toggleText,
|
|
405
409
|
children: "DEBUG NAV"
|
|
410
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
411
|
+
style: styles.spacing
|
|
406
412
|
})]
|
|
407
|
-
}), /*#__PURE__*/_jsx(View, {
|
|
408
|
-
style: styles.spacing
|
|
409
413
|
}), /*#__PURE__*/_jsx(Text, {
|
|
410
414
|
style: styles.arrow,
|
|
411
415
|
children: isExpanded ? '▼' : '▲'
|
|
@@ -424,9 +428,9 @@ const styles = StyleSheet.create({
|
|
|
424
428
|
flexDirection: 'row',
|
|
425
429
|
alignItems: 'center',
|
|
426
430
|
backgroundColor: '#FF5252',
|
|
427
|
-
paddingHorizontal:
|
|
431
|
+
paddingHorizontal: 10,
|
|
428
432
|
paddingVertical: 10,
|
|
429
|
-
borderRadius:
|
|
433
|
+
borderRadius: 8,
|
|
430
434
|
borderWidth: 2,
|
|
431
435
|
borderColor: 'white',
|
|
432
436
|
...Platform.select({
|
|
@@ -444,9 +448,6 @@ const styles = StyleSheet.create({
|
|
|
444
448
|
}
|
|
445
449
|
})
|
|
446
450
|
},
|
|
447
|
-
bugIcon: {
|
|
448
|
-
fontSize: 24
|
|
449
|
-
},
|
|
450
451
|
spacing: {
|
|
451
452
|
width: 8
|
|
452
453
|
},
|
|
@@ -457,7 +458,10 @@ const styles = StyleSheet.create({
|
|
|
457
458
|
},
|
|
458
459
|
arrow: {
|
|
459
460
|
color: 'white',
|
|
460
|
-
fontSize: 20
|
|
461
|
+
fontSize: 20,
|
|
462
|
+
lineHeight: 20,
|
|
463
|
+
textAlignVertical: 'center',
|
|
464
|
+
includeFontPadding: false
|
|
461
465
|
},
|
|
462
466
|
panel: {
|
|
463
467
|
backgroundColor: 'rgba(0, 0, 0, 0.9)',
|
|
@@ -500,12 +504,6 @@ const styles = StyleSheet.create({
|
|
|
500
504
|
borderRadius: 4,
|
|
501
505
|
marginBottom: 6
|
|
502
506
|
},
|
|
503
|
-
screenIcon: {
|
|
504
|
-
fontSize: 16,
|
|
505
|
-
marginRight: 8,
|
|
506
|
-
width: 20,
|
|
507
|
-
textAlign: 'center'
|
|
508
|
-
},
|
|
509
507
|
screenLabel: {
|
|
510
508
|
color: 'white',
|
|
511
509
|
fontSize: 12,
|