@trustchex/react-native-sdk 1.486.0 → 1.488.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/lib/module/Shared/Components/EIDScanner.js +97 -37
- package/lib/module/Shared/Components/IdentityDocumentCamera.constants.js +9 -1
- package/lib/module/Shared/EIDReader/cardFileInputStream.js +25 -2
- package/lib/module/Shared/EIDReader/defaultFileSystem.js +56 -6
- package/lib/module/Shared/EIDReader/eidReader.js +124 -14
- package/lib/module/Shared/EIDReader/lds/icao/dg11File.js +23 -6
- package/lib/module/Shared/EIDReader/nfcManagerCardService.js +79 -9
- package/lib/module/Shared/EIDReader/protocol/paceDH.js +101 -0
- package/lib/module/Shared/EIDReader/protocol/paceErrors.js +34 -0
- package/lib/module/Shared/EIDReader/protocol/paceProtocol.js +53 -4
- package/lib/module/Shared/EIDReader/protocol/readBinaryAPDUSender.js +7 -3
- package/lib/module/Shared/Libs/country-display.utils.js +13 -1
- package/lib/module/Shared/Libs/diagnosticReport.js +24 -1
- package/lib/module/Shared/Libs/diagnostics.js +30 -8
- package/lib/module/Shared/Libs/mrz.utils.js +172 -25
- package/lib/module/Shared/Libs/mrzFrameAggregator.js +29 -1
- package/lib/module/Shared/Libs/mrzTransliteration.js +14 -1
- package/lib/module/Translation/Resources/en.js +12 -0
- package/lib/module/Translation/Resources/tr.js +12 -0
- package/lib/module/version.js +1 -1
- package/lib/typescript/src/Shared/Components/EIDScanner.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Components/IdentityDocumentCamera.constants.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/cardFileInputStream.d.ts +3 -0
- package/lib/typescript/src/Shared/EIDReader/cardFileInputStream.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/defaultFileSystem.d.ts +4 -0
- package/lib/typescript/src/Shared/EIDReader/defaultFileSystem.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/eidReader.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/lds/icao/dg11File.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/nfcManagerCardService.d.ts +9 -1
- package/lib/typescript/src/Shared/EIDReader/nfcManagerCardService.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/protocol/paceDH.d.ts +56 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceDH.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceErrors.d.ts +26 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceErrors.d.ts.map +1 -0
- package/lib/typescript/src/Shared/EIDReader/protocol/paceProtocol.d.ts.map +1 -1
- package/lib/typescript/src/Shared/EIDReader/protocol/readBinaryAPDUSender.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/country-display.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/diagnosticReport.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/diagnostics.d.ts +9 -1
- package/lib/typescript/src/Shared/Libs/diagnostics.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/mrz.utils.d.ts +1 -0
- package/lib/typescript/src/Shared/Libs/mrz.utils.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/mrzFrameAggregator.d.ts.map +1 -1
- package/lib/typescript/src/Shared/Libs/mrzTransliteration.d.ts.map +1 -1
- package/lib/typescript/src/Translation/Resources/en.d.ts +12 -0
- package/lib/typescript/src/Translation/Resources/en.d.ts.map +1 -1
- package/lib/typescript/src/Translation/Resources/tr.d.ts +12 -0
- package/lib/typescript/src/Translation/Resources/tr.d.ts.map +1 -1
- package/lib/typescript/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/Shared/Components/EIDScanner.tsx +149 -68
- package/src/Shared/Components/IdentityDocumentCamera.constants.ts +9 -1
- package/src/Shared/EIDReader/cardFileInputStream.ts +30 -6
- package/src/Shared/EIDReader/defaultFileSystem.ts +75 -17
- package/src/Shared/EIDReader/eidReader.ts +154 -21
- package/src/Shared/EIDReader/lds/icao/dg11File.ts +28 -13
- package/src/Shared/EIDReader/nfcManagerCardService.ts +91 -13
- package/src/Shared/EIDReader/protocol/paceDH.ts +183 -0
- package/src/Shared/EIDReader/protocol/paceErrors.ts +41 -0
- package/src/Shared/EIDReader/protocol/paceProtocol.ts +72 -6
- package/src/Shared/EIDReader/protocol/readBinaryAPDUSender.ts +7 -4
- package/src/Shared/Libs/country-display.utils.ts +12 -1
- package/src/Shared/Libs/diagnosticReport.ts +32 -1
- package/src/Shared/Libs/diagnostics.ts +38 -14
- package/src/Shared/Libs/mrz.utils.ts +193 -28
- package/src/Shared/Libs/mrzFrameAggregator.ts +38 -3
- package/src/Shared/Libs/mrzTransliteration.ts +16 -3
- package/src/Translation/Resources/en.ts +19 -0
- package/src/Translation/Resources/tr.ts +19 -0
- package/src/version.ts +1 -1
|
@@ -94,12 +94,25 @@ export function buildDocumentName(
|
|
|
94
94
|
dg11First?: string | null,
|
|
95
95
|
dg11Last?: string | null
|
|
96
96
|
): DocumentName {
|
|
97
|
-
|
|
97
|
+
// Prefer DG11 (the chip's printed name in UTF-8) ONLY when it carries a proper
|
|
98
|
+
// two-part split — both a surname AND a given name. That is the authoritative
|
|
99
|
+
// correction for chips whose DG1 MRZ name lacks a `<<` separator (e.g. Turkish
|
|
100
|
+
// PACE passports), where the raw MRZ would otherwise put the full name into
|
|
101
|
+
// the surname.
|
|
102
|
+
//
|
|
103
|
+
// A one-sided DG11 result (only surname, or only given name) is NOT reliable —
|
|
104
|
+
// it usually means DG11 had no clear separator, so we don't know which part it
|
|
105
|
+
// is. Back-filling the missing side from the raw MRZ caused the given name to
|
|
106
|
+
// be duplicated into both fields, so we now fall through to the MRZ-based
|
|
107
|
+
// split instead, which is more trustworthy than mixing the two sources.
|
|
108
|
+
const hasFirst = (dg11First ?? '') !== '';
|
|
109
|
+
const hasLast = (dg11Last ?? '') !== '';
|
|
110
|
+
if (hasFirst && hasLast) {
|
|
98
111
|
return {
|
|
99
112
|
rawFirst,
|
|
100
113
|
rawLast,
|
|
101
|
-
displayFirst: dg11First,
|
|
102
|
-
displayLast: dg11Last,
|
|
114
|
+
displayFirst: dg11First as string,
|
|
115
|
+
displayLast: dg11Last as string,
|
|
103
116
|
source: 'dg11',
|
|
104
117
|
};
|
|
105
118
|
}
|
|
@@ -59,6 +59,13 @@ export default {
|
|
|
59
59
|
'This opens a draft with your scan data, document images and technical details so support can help resolve a scanning issue. Review it before sending.',
|
|
60
60
|
'diagnosticReport.continue': 'Continue',
|
|
61
61
|
'diagnosticReport.cancel': 'Cancel',
|
|
62
|
+
'diagnosticReport.shareFailedTitle': "Couldn't open the share sheet",
|
|
63
|
+
'diagnosticReport.shareFailedBody':
|
|
64
|
+
"We couldn't attach the report to share. Send it securely to support instead?",
|
|
65
|
+
'diagnosticReport.uploadAction': 'Send to support',
|
|
66
|
+
'diagnosticReport.uploadSuccess': 'Diagnostic report sent to support.',
|
|
67
|
+
'diagnosticReport.uploadFailed':
|
|
68
|
+
"Couldn't send the report. Please try again later.",
|
|
62
69
|
'livenessDetectionScreen.guideHeader': 'Face Verification',
|
|
63
70
|
'livenessDetectionScreen.guideText':
|
|
64
71
|
'Please ensure the following for best results:',
|
|
@@ -92,6 +99,18 @@ export default {
|
|
|
92
99
|
'When prompted, hold your document flat against the back of your device near the NFC antenna.',
|
|
93
100
|
'eidScannerScreen.invalidMRZFields':
|
|
94
101
|
'Document information could not be read. Please try again.',
|
|
102
|
+
'eidScannerScreen.error': 'Error',
|
|
103
|
+
'eidScannerScreen.errorCode': 'Error code',
|
|
104
|
+
'eidScannerScreen.nfcGenericError':
|
|
105
|
+
'Something went wrong while reading your document. Please try again. If the problem continues, contact support with the code below.',
|
|
106
|
+
'eidScannerScreen.nfcReadFailed':
|
|
107
|
+
'Could not read the chip. Hold the document flat against the back of your device and keep it still, then try again.',
|
|
108
|
+
'eidScannerScreen.nfcAuthFailed':
|
|
109
|
+
'Could not establish a secure connection to the chip. Make sure the document number, date of birth and expiry date are correct, then try again.',
|
|
110
|
+
'eidScannerScreen.nfcTagLost':
|
|
111
|
+
'Connection to the document was lost. Keep the document still against the device and try again.',
|
|
112
|
+
'eidScannerScreen.nfcTimeout':
|
|
113
|
+
'Reading the chip timed out. Hold the document steady against the device and try again.',
|
|
95
114
|
'eidScannerScreen.faceImageNotFound': 'Photo data not found on document.',
|
|
96
115
|
'eidScannerScreen.documentCode': 'Document Type',
|
|
97
116
|
'eidScannerScreen.nationality': 'Nationality',
|
|
@@ -59,6 +59,13 @@ export default {
|
|
|
59
59
|
'Bu işlem; tarama verilerinizi, belge görüntülerinizi ve teknik ayrıntıları içeren bir taslak açar; böylece destek ekibi tarama sorununu çözebilir. Göndermeden önce gözden geçirin.',
|
|
60
60
|
'diagnosticReport.continue': 'Devam et',
|
|
61
61
|
'diagnosticReport.cancel': 'İptal',
|
|
62
|
+
'diagnosticReport.shareFailedTitle': 'Paylaşım ekranı açılamadı',
|
|
63
|
+
'diagnosticReport.shareFailedBody':
|
|
64
|
+
'Raporu paylaşmak için ekleyemedik. Bunun yerine destek ekibine güvenli şekilde gönderelim mi?',
|
|
65
|
+
'diagnosticReport.uploadAction': 'Desteğe gönder',
|
|
66
|
+
'diagnosticReport.uploadSuccess': 'Tanılama raporu destek ekibine gönderildi.',
|
|
67
|
+
'diagnosticReport.uploadFailed':
|
|
68
|
+
'Rapor gönderilemedi. Lütfen daha sonra tekrar deneyin.',
|
|
62
69
|
'livenessDetectionScreen.guideHeader': 'Yüz Doğrulaması',
|
|
63
70
|
'livenessDetectionScreen.guideText':
|
|
64
71
|
'En iyi sonuç için lütfen şunları sağlayın:',
|
|
@@ -92,6 +99,18 @@ export default {
|
|
|
92
99
|
'İstendiğinde, belgenizi cihazınızın arka tarafındaki NFC antenine düz bir şekilde yaklaştırın.',
|
|
93
100
|
'eidScannerScreen.invalidMRZFields':
|
|
94
101
|
'Belge bilgileri okunamadı. Lütfen tekrar deneyin.',
|
|
102
|
+
'eidScannerScreen.error': 'Hata',
|
|
103
|
+
'eidScannerScreen.errorCode': 'Hata kodu',
|
|
104
|
+
'eidScannerScreen.nfcGenericError':
|
|
105
|
+
'Belgeniz okunurken bir sorun oluştu. Lütfen tekrar deneyin. Sorun devam ederse aşağıdaki kod ile destek ekibimize başvurun.',
|
|
106
|
+
'eidScannerScreen.nfcReadFailed':
|
|
107
|
+
'Çip okunamadı. Belgeyi cihazınızın arkasına düz şekilde yaslayıp sabit tutun ve tekrar deneyin.',
|
|
108
|
+
'eidScannerScreen.nfcAuthFailed':
|
|
109
|
+
'Çip ile güvenli bağlantı kurulamadı. Belge numarası, doğum tarihi ve son geçerlilik tarihinin doğru olduğundan emin olup tekrar deneyin.',
|
|
110
|
+
'eidScannerScreen.nfcTagLost':
|
|
111
|
+
'Belge ile bağlantı kesildi. Belgeyi cihaza sabit tutun ve tekrar deneyin.',
|
|
112
|
+
'eidScannerScreen.nfcTimeout':
|
|
113
|
+
'Çip okuması zaman aşımına uğradı. Belgeyi cihaza sabit tutup tekrar deneyin.',
|
|
95
114
|
'eidScannerScreen.faceImageNotFound': 'Belgede fotoğraf verisi bulunamadı.',
|
|
96
115
|
'eidScannerScreen.documentCode': 'Belge Türü',
|
|
97
116
|
'eidScannerScreen.nationality': 'Uyruk',
|
package/src/version.ts
CHANGED