Skip to content

Commit 13ec655

Browse files
author
Jenkins
committed
8.3.250
1 parent 7f875e7 commit 13ec655

10 files changed

Lines changed: 29 additions & 27 deletions

File tree

RNDocumentReaderApi.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ Pod::Spec.new do |s|
1414
s.source = { :http => 'file:' + __dir__ }
1515
s.ios.deployment_target = '13.0'
1616
s.source_files = "ios/*.{h,m}"
17-
s.dependency 'DocumentReader', '8.2.5052'
17+
s.dependency 'DocumentReader', '8.3.5094'
1818
s.dependency 'React'
1919
end

android/build.gradle

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,3 @@
1-
buildscript {
2-
repositories {
3-
google()
4-
mavenCentral()
5-
}
6-
7-
dependencies {
8-
classpath "com.android.tools.build:gradle:8.1.1"
9-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.22"
10-
}
11-
}
12-
131
apply plugin: 'com.android.library'
142
apply plugin: 'kotlin-android'
153

@@ -19,11 +7,11 @@ android {
197
namespace 'com.regula.plugin.documentreader'
208
}
219

22-
compileSdk 34
10+
compileSdk 36
2311

2412
defaultConfig {
25-
minSdkVersion 21
26-
targetSdk 34
13+
minSdkVersion 24
14+
targetSdk 36
2715
versionCode 1
2816
versionName "1.0"
2917
}
@@ -41,7 +29,7 @@ dependencies {
4129
//noinspection GradleDynamicVersion
4230
implementation 'com.facebook.react:react-native:+'
4331
//noinspection GradleDependency
44-
implementation('com.regula.documentreader:api:8.2.11804') {
32+
implementation('com.regula.documentreader:api:8.3.11882') {
4533
transitive = true
4634
}
4735
}

android/src/main/java/com/regula/plugin/documentreader/Config.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ fun setFunctionality(config: Functionality, input: JSONObject) = input.forEach {
5858
"btDeviceName" -> editor.setBtDeviceName(v as String)
5959
"zoomFactor" -> editor.setZoomFactor(v.toFloat())
6060
"exposure" -> editor.setExposure(v.toFloat())
61+
"videoRecordingSizeDownscaleFactor" -> editor.setVideoRecordingSizeDownscaleFactor(v.toFloat())
6162
"excludedCamera2Models" -> editor.setExcludedCamera2Models((v as JSONArray).toList())
6263
"cameraSize" -> editor.setCameraSize(cameraSizeFromJSON(v as JSONObject).first, cameraSizeFromJSON(v).second)
6364
}
@@ -92,6 +93,7 @@ fun getFunctionality(input: Functionality) = mapOf(
9293
"btDeviceName" to input.btDeviceName,
9394
"zoomFactor" to input.zoomFactor,
9495
"exposure" to input.exposure,
96+
"videoRecordingSizeDownscaleFactor" to input.videoRecordingSizeDownscaleFactor,
9597
"excludedCamera2Models" to input.excludedCamera2Models.toJson(),
9698
"cameraSize" to generateCameraSize(input.cameraWidth, input.cameraHeight)
9799
).toJson()
@@ -138,6 +140,7 @@ fun setProcessParams(processParams: ProcessParam, opts: JSONObject) = opts.forEa
138140
"strictDLCategoryExpiry" -> processParams.strictDLCategoryExpiry = v as Boolean
139141
"generateAlpha2Codes" -> processParams.generateAlpha2Codes = v as Boolean
140142
"disableAuthResolutionFilter" -> processParams.disableAuthResolutionFilter = v as Boolean
143+
"strictSecurityChecks" -> processParams.strictSecurityChecks = v as Boolean
141144
"measureSystem" -> processParams.measureSystem = v.toInt()
142145
"barcodeParserType" -> processParams.barcodeParserType = v.toInt()
143146
"perspectiveAngle" -> processParams.perspectiveAngle = v.toInt()
@@ -223,6 +226,7 @@ fun getProcessParams(processParams: ProcessParam) = mapOf(
223226
"strictDLCategoryExpiry" to processParams.strictDLCategoryExpiry,
224227
"generateAlpha2Codes" to processParams.generateAlpha2Codes,
225228
"disableAuthResolutionFilter" to processParams.disableAuthResolutionFilter,
229+
"strictSecurityChecks" to processParams.strictSecurityChecks,
226230
"measureSystem" to processParams.measureSystem,
227231
"barcodeParserType" to processParams.barcodeParserType,
228232
"perspectiveAngle" to processParams.perspectiveAngle,

android/src/main/java/com/regula/plugin/documentreader/JSONConstructor.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ fun onlineProcessingConfigFromJSON(input: JSONObject?) = input?.let {
318318
if (it.has("imageCompressionQuality")) builder.setImageCompressionQuality(it.getDouble("imageCompressionQuality").toFloat())
319319
if (it.has("processParams")) builder.setProcessParams(processParamFromJSON(it.getJSONObject("processParams")))
320320
if (it.has("requestHeaders")) {
321-
val listener = NetworkInterceptorListener { input.getJSONObject("requestHeaders").forEach { k, v -> it.setRequestProperty(k, v as String) } }
321+
val listener = NetworkInterceptorListener { self -> input.getJSONObject("requestHeaders").forEach { k, v -> self.setRequestProperty(k, v as String) } }
322322
weakReferencesHolder.add(listener)
323323
builder.setNetworkInterceptorListener(listener)
324324
}
@@ -370,9 +370,9 @@ fun faceApiSearchParamsFromJSON(input: JSONObject?) = input?.let {
370370
if (it.has("threshold") && !it.isNull("threshold")) result.threshold = it.getDouble("threshold").toFloat()
371371
if (it.has("groupIds") && !it.isNull("groupIds")) {
372372
val jsonArrayGroupIds = it.getJSONArray("groupIds")
373-
val groupIds = IntArray(jsonArrayGroupIds.length())
373+
val groupIds = arrayOfNulls<String>(jsonArrayGroupIds.length())
374374
for (i in 0 until jsonArrayGroupIds.length())
375-
groupIds[i] = jsonArrayGroupIds.getInt(i)
375+
groupIds[i] = jsonArrayGroupIds.getString(i)
376376
result.groupIds = groupIds
377377
}
378378

example/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"test": "jest"
1111
},
1212
"dependencies": {
13-
"@regulaforensics/react-native-document-reader-api": "8.2.234",
14-
"@regulaforensics/react-native-document-reader-core-fullauthrfid": "8.2.586",
13+
"@regulaforensics/react-native-document-reader-api": "8.3.250",
14+
"@regulaforensics/react-native-document-reader-core-fullauthrfid": "8.3.788",
1515
"react-native-progress": "5.0.0",
1616
"react-native-radio-buttons-group": "3.0.5",
1717
"@rneui/base": "4.0.0-rc.7",

index.d.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1838,6 +1838,7 @@ export class Functionality {
18381838
btDeviceName?: string
18391839
zoomFactor?: number
18401840
exposure?: number
1841+
videoRecordingSizeDownscaleFactor?: number
18411842
excludedCamera2Models?: string[]
18421843
cameraSize?: CameraSize
18431844
videoSessionPreset?: number
@@ -1875,6 +1876,7 @@ export class Functionality {
18751876
result.btDeviceName = jsonObject["btDeviceName"]
18761877
result.zoomFactor = jsonObject["zoomFactor"]
18771878
result.exposure = jsonObject["exposure"]
1879+
result.videoRecordingSizeDownscaleFactor = jsonObject["videoRecordingSizeDownscaleFactor"]
18781880
result.excludedCamera2Models = []
18791881
if (jsonObject["excludedCamera2Models"] != null) {
18801882
for (const i in jsonObject["excludedCamera2Models"]) {
@@ -1962,7 +1964,7 @@ export class RFIDParams {
19621964
export class FaceApiSearchParams {
19631965
limit?: number
19641966
threshold?: number
1965-
groupIds?: number[]
1967+
groupIds?: string[]
19661968

19671969
static fromJson(jsonObject?: any): FaceApiSearchParams | undefined {
19681970
if (jsonObject == null || jsonObject == undefined) return undefined
@@ -2134,6 +2136,7 @@ export class ProcessParams {
21342136
strictDLCategoryExpiry?: boolean
21352137
generateAlpha2Codes?: boolean
21362138
disableAuthResolutionFilter?: boolean
2139+
strictSecurityChecks?: boolean
21372140
barcodeParserType?: number
21382141
perspectiveAngle?: number
21392142
minDPI?: number
@@ -2215,6 +2218,7 @@ export class ProcessParams {
22152218
result.strictDLCategoryExpiry = jsonObject["strictDLCategoryExpiry"]
22162219
result.generateAlpha2Codes = jsonObject["generateAlpha2Codes"]
22172220
result.disableAuthResolutionFilter = jsonObject["disableAuthResolutionFilter"]
2221+
result.strictSecurityChecks = jsonObject["strictSecurityChecks"]
22182222
result.barcodeParserType = jsonObject["barcodeParserType"]
22192223
result.perspectiveAngle = jsonObject["perspectiveAngle"]
22202224
result.minDPI = jsonObject["minDPI"]
@@ -3601,6 +3605,7 @@ export const eCheckDiagnose = {
36013605
TEXT_COLOR_SHOULD_BE_GREEN: 131,
36023606
TEXT_COLOR_SHOULD_BE_RED: 132,
36033607
TEXT_SHOULD_BE_BLACK: 133,
3608+
SECURITY_TEXT_IS_ABSENT: 134,
36043609
BARCODE_WAS_READ_WITH_ERRORS: 140,
36053610
BARCODE_DATA_FORMAT_ERROR: 141,
36063611
BARCODE_SIZE_PARAMS_ERROR: 142,

index.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1269,6 +1269,7 @@ export class Functionality {
12691269
result.btDeviceName = jsonObject["btDeviceName"]
12701270
result.zoomFactor = jsonObject["zoomFactor"]
12711271
result.exposure = jsonObject["exposure"]
1272+
result.videoRecordingSizeDownscaleFactor = jsonObject["videoRecordingSizeDownscaleFactor"]
12721273
result.excludedCamera2Models = []
12731274
if (jsonObject["excludedCamera2Models"] != null)
12741275
for (const i in jsonObject["excludedCamera2Models"])
@@ -1464,6 +1465,7 @@ export class ProcessParams {
14641465
result.strictDLCategoryExpiry = jsonObject["strictDLCategoryExpiry"]
14651466
result.generateAlpha2Codes = jsonObject["generateAlpha2Codes"]
14661467
result.disableAuthResolutionFilter = jsonObject["disableAuthResolutionFilter"]
1468+
result.strictSecurityChecks = jsonObject["strictSecurityChecks"]
14671469
result.barcodeParserType = jsonObject["barcodeParserType"]
14681470
result.perspectiveAngle = jsonObject["perspectiveAngle"]
14691471
result.minDPI = jsonObject["minDPI"]
@@ -2608,6 +2610,7 @@ export const eCheckDiagnose = {
26082610
TEXT_COLOR_SHOULD_BE_GREEN: 131,
26092611
TEXT_COLOR_SHOULD_BE_RED: 132,
26102612
TEXT_SHOULD_BE_BLACK: 133,
2613+
SECURITY_TEXT_IS_ABSENT: 134,
26112614
BARCODE_WAS_READ_WITH_ERRORS: 140,
26122615
BARCODE_DATA_FORMAT_ERROR: 141,
26132616
BARCODE_SIZE_PARAMS_ERROR: 142,

ios/RGLWConfig.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ +(void)setProcessParams:(NSDictionary*)options :(RGLProcessParams*)processParams
185185
if (options[@"strictDLCategoryExpiry"]) processParams.strictDLCategoryExpiry = options[@"strictDLCategoryExpiry"];
186186
if (options[@"generateAlpha2Codes"]) processParams.generateAlpha2Codes = options[@"generateAlpha2Codes"];
187187
if (options[@"disableAuthResolutionFilter"]) processParams.disableAuthResolutionFilter = options[@"disableAuthResolutionFilter"];
188+
if (options[@"strictSecurityChecks"]) processParams.strictSecurityChecks = options[@"strictSecurityChecks"];
188189

189190
// Int
190191
if([options valueForKey:@"measureSystem"] != nil)
@@ -316,6 +317,7 @@ +(NSDictionary*)getProcessParams:(RGLProcessParams*)processParams {
316317
result[@"strictDLCategoryExpiry"] = processParams.strictDLCategoryExpiry;
317318
result[@"generateAlpha2Codes"] = processParams.generateAlpha2Codes;
318319
result[@"disableAuthResolutionFilter"] = processParams.disableAuthResolutionFilter;
320+
result[@"strictSecurityChecks"] = processParams.strictSecurityChecks;
319321

320322
// Int
321323
result[@"measureSystem"] = [NSNumber numberWithInteger:processParams.measureSystem];

ios/RGLWMain.m

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ +(void)methodCall:(NSString*)method :(NSArray*)args :(RGLWCallback)callback :(RG
6767
@"endBackendTransaction": ^{ [self endBackendTransaction]; },
6868
@"textFieldValueByType": ^{ [self textFieldValueByType :args[0] :args[1] :callback]; },
6969
@"textFieldValueByTypeLcid": ^{ [self textFieldValueByTypeLcid :args[0] :args[1] :args[2] :callback]; },
70-
@"textFieldValueByTypeSource": ^{ [self textFieldValueByTypeSource :args[0] :args[2] :args[3] :callback]; },
70+
@"textFieldValueByTypeSource": ^{ [self textFieldValueByTypeSource :args[0] :args[1] :args[2] :callback]; },
7171
@"textFieldValueByTypeLcidSource": ^{ [self textFieldValueByTypeLcidSource :args[0] :args[1] :args[2] :args[3] :callback]; },
7272
@"textFieldValueByTypeSourceOriginal": ^{ [self textFieldValueByTypeSourceOriginal :args[0] :args[1] :args[2] :args[3] :callback]; },
7373
@"textFieldValueByTypeLcidSourceOriginal": ^{ [self textFieldValueByTypeLcidSourceOriginal :args[0] :args[1] :args[2] :args[3] :args[4] :callback]; },
@@ -339,12 +339,12 @@ - (void)didChangeConnectionState:(RGLBluetooth *)bluetooth state:(RGLBluetoothCo
339339

340340
// set searching timeout
341341
if (state == RGLBluetoothConnectionStateSearching)
342-
[self performSelector:NSSelectorFromString(@"bluetoothDeviceConnectionFailed") withObject:nil afterDelay:7.0];
342+
[[self class] performSelector:NSSelectorFromString(@"bluetoothDeviceConnectionFailed") withObject:nil afterDelay:7.0];
343343

344344
if (state == RGLBluetoothConnectionStateConnected) {
345345
savedCallbackForBluetoothResult(@YES);
346346
savedCallbackForBluetoothResult = nil;
347-
[NSObject cancelPreviousPerformRequestsWithTarget:self selector:NSSelectorFromString(@"bluetoothDeviceConnectionFailed") object:nil];
347+
[NSObject cancelPreviousPerformRequestsWithTarget:[self class] selector:NSSelectorFromString(@"bluetoothDeviceConnectionFailed") object:nil];
348348
}
349349
}
350350

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@regulaforensics/react-native-document-reader-api",
3-
"version": "8.2.234",
3+
"version": "8.3.250",
44
"description": "React Native module for reading and validation of identification documents (API framework)",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)