@regulaforensics/react-native-document-reader-api 9.7.696-rc → 9.7.698-nightly
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/RNDocumentReaderApi.podspec +1 -1
- package/android/build.gradle +2 -2
- package/android/src/main/java/com/regula/plugin/documentreader/Config.kt +30 -10
- package/android/src/main/java/com/regula/plugin/documentreader/JSONConstructor.kt +12 -1
- package/android/src/main/java/com/regula/plugin/documentreader/Utils.kt +1 -1
- package/example/package-lock.json +1036 -180
- package/example/package.json +4 -3
- package/index.d.ts +29 -2
- package/index.js +24 -2
- package/ios/RGLWConfig.h +2 -0
- package/ios/RGLWConfig.m +25 -5
- package/ios/RGLWJSONConstructor.h +2 -0
- package/ios/RGLWJSONConstructor.m +12 -0
- package/package.json +1 -1
|
@@ -14,6 +14,6 @@ Pod::Spec.new do |s|
|
|
|
14
14
|
s.source = { :http => 'file:' + __dir__ }
|
|
15
15
|
s.ios.deployment_target = '13.0'
|
|
16
16
|
s.source_files = "ios/*.{h,m}"
|
|
17
|
-
s.dependency '
|
|
17
|
+
s.dependency 'DocumentReaderNightly', '9.7.6771'
|
|
18
18
|
s.dependency 'React'
|
|
19
19
|
end
|
package/android/build.gradle
CHANGED
|
@@ -20,7 +20,7 @@ android {
|
|
|
20
20
|
rootProject.allprojects {
|
|
21
21
|
repositories {
|
|
22
22
|
maven {
|
|
23
|
-
url "https://maven.regulaforensics.com/RegulaDocumentReader/
|
|
23
|
+
url "https://maven.regulaforensics.com/RegulaDocumentReader/Nightly"
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
26
|
}
|
|
@@ -29,7 +29,7 @@ dependencies {
|
|
|
29
29
|
//noinspection GradleDynamicVersion
|
|
30
30
|
implementation 'com.facebook.react:react-native:+'
|
|
31
31
|
//noinspection GradleDependency
|
|
32
|
-
implementation('com.regula.documentreader:api:9.7.
|
|
32
|
+
implementation('com.regula.documentreader:api:9.7.13171') {
|
|
33
33
|
transitive = true
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -16,6 +16,7 @@ import com.regula.documentreader.api.enums.CustomizationScaleType
|
|
|
16
16
|
import com.regula.documentreader.api.enums.CustomizationTiming
|
|
17
17
|
import com.regula.documentreader.api.enums.LogLevel
|
|
18
18
|
import com.regula.documentreader.api.params.AuthenticityParams
|
|
19
|
+
import com.regula.documentreader.api.params.AuthenticityPropertiesParams
|
|
19
20
|
import com.regula.documentreader.api.params.Functionality
|
|
20
21
|
import com.regula.documentreader.api.params.ImageQA
|
|
21
22
|
import com.regula.documentreader.api.params.LivenessParams
|
|
@@ -718,10 +719,15 @@ fun setAuthenticityParams(input: AuthenticityParams, opts: JSONObject) = opts.fo
|
|
|
718
719
|
"checkPhotoComparison" -> input.checkPhotoComparison = v as Boolean
|
|
719
720
|
"checkLetterScreen" -> input.checkLetterScreen = v as Boolean
|
|
720
721
|
"checkSecurityText" -> input.checkSecurityText = v as Boolean
|
|
722
|
+
"checkProperties" -> input.checkProperties = v as Boolean
|
|
721
723
|
"livenessParams" -> {
|
|
722
724
|
if (input.livenessParams == null) input.livenessParams = LivenessParams.defaultParams()
|
|
723
725
|
setLivenessParams(input.livenessParams!!, v as JSONObject)
|
|
724
726
|
}
|
|
727
|
+
"propertiesParams" -> {
|
|
728
|
+
if (input.propertiesParams == null) input.propertiesParams = AuthenticityPropertiesParams.defaultParams()
|
|
729
|
+
setAuthenticityPropertiesParams(input.propertiesParams!!, v as JSONObject)
|
|
730
|
+
}
|
|
725
731
|
}
|
|
726
732
|
}
|
|
727
733
|
|
|
@@ -729,7 +735,7 @@ fun getAuthenticityParams(input: AuthenticityParams?) = input?.let {
|
|
|
729
735
|
mapOf(
|
|
730
736
|
"useLivenessCheck" to it.useLivenessCheck,
|
|
731
737
|
"checkUVLuminiscence" to it.checkUVLuminiscence,
|
|
732
|
-
"checkIRB900" to
|
|
738
|
+
"checkIRB900" to it.checkIRB900,
|
|
733
739
|
"checkImagePatterns" to it.checkImagePatterns,
|
|
734
740
|
"checkFibers" to it.checkFibers,
|
|
735
741
|
"checkExtMRZ" to it.checkExtMRZ,
|
|
@@ -742,7 +748,9 @@ fun getAuthenticityParams(input: AuthenticityParams?) = input?.let {
|
|
|
742
748
|
"checkPhotoComparison" to it.checkPhotoComparison,
|
|
743
749
|
"checkLetterScreen" to it.checkLetterScreen,
|
|
744
750
|
"checkSecurityText" to it.checkSecurityText,
|
|
745
|
-
"
|
|
751
|
+
"checkProperties" to it.checkProperties,
|
|
752
|
+
"livenessParams" to getLivenessParams(it.livenessParams),
|
|
753
|
+
"propertiesParams" to getAuthenticityPropertiesParams(it.propertiesParams),
|
|
746
754
|
).toJson()
|
|
747
755
|
}
|
|
748
756
|
|
|
@@ -761,14 +769,26 @@ fun setLivenessParams(input: LivenessParams, opts: JSONObject) = opts.forEach {
|
|
|
761
769
|
|
|
762
770
|
fun getLivenessParams(input: LivenessParams?) = input?.let {
|
|
763
771
|
mapOf(
|
|
764
|
-
"checkOVI" to
|
|
765
|
-
"checkMLI" to
|
|
766
|
-
"checkHolo" to
|
|
767
|
-
"checkED" to
|
|
768
|
-
"checkBlackAndWhiteCopy" to
|
|
769
|
-
"checkDynaprint" to
|
|
770
|
-
"checkGeometry" to
|
|
771
|
-
"checkBarcodeBackground" to
|
|
772
|
+
"checkOVI" to it.checkOVI,
|
|
773
|
+
"checkMLI" to it.checkMLI,
|
|
774
|
+
"checkHolo" to it.checkHolo,
|
|
775
|
+
"checkED" to it.checkED,
|
|
776
|
+
"checkBlackAndWhiteCopy" to it.checkBlackAndWhiteCopy,
|
|
777
|
+
"checkDynaprint" to it.checkDynaprint,
|
|
778
|
+
"checkGeometry" to it.checkGeometry,
|
|
779
|
+
"checkBarcodeBackground" to it.checkBarcodeBackground,
|
|
780
|
+
).toJson()
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
fun setAuthenticityPropertiesParams(input: AuthenticityPropertiesParams, opts: JSONObject) = opts.forEach { k, v ->
|
|
784
|
+
when (k) {
|
|
785
|
+
"checkHoldersSignature" -> input.checkHoldersSignature = v as Boolean
|
|
786
|
+
}
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
fun getAuthenticityPropertiesParams(input: AuthenticityPropertiesParams?) = input?.let {
|
|
790
|
+
mapOf(
|
|
791
|
+
"checkHoldersSignature" to it.checkHoldersSignature,
|
|
772
792
|
).toJson()
|
|
773
793
|
}
|
|
774
794
|
|
|
@@ -27,6 +27,7 @@ import com.regula.documentreader.api.enums.eRFID_DataFile_Type
|
|
|
27
27
|
import com.regula.documentreader.api.enums.eRPRM_Lights
|
|
28
28
|
import com.regula.documentreader.api.listener.NetworkInterceptorListener
|
|
29
29
|
import com.regula.documentreader.api.params.AuthenticityParams
|
|
30
|
+
import com.regula.documentreader.api.params.AuthenticityPropertiesParams
|
|
30
31
|
import com.regula.documentreader.api.params.BackendProcessingConfig
|
|
31
32
|
import com.regula.documentreader.api.params.BleDeviceConfig
|
|
32
33
|
import com.regula.documentreader.api.params.Bsi
|
|
@@ -378,6 +379,7 @@ fun faceApiParamsFromJSON(input: JSONObject?) = input?.let {
|
|
|
378
379
|
result.search = faceApiSearchParamsFromJSON(it.getJSONObjectOrNull("searchParams"))
|
|
379
380
|
result.proxy = it.getStringOrNull("proxy")
|
|
380
381
|
result.proxyUserPwd = it.getStringOrNull("proxyPassword")
|
|
382
|
+
result.livenessTransactionId = it.getStringOrNull("livenessTransactionId")
|
|
381
383
|
result.proxyType = it.getIntOrNull("proxyType")
|
|
382
384
|
|
|
383
385
|
result
|
|
@@ -392,6 +394,7 @@ fun generateFaceApiParams(input: FaceApiParams?) = input?.let {
|
|
|
392
394
|
"serviceTimeout" to it.serviceTimeout,
|
|
393
395
|
"proxy" to it.proxy,
|
|
394
396
|
"proxyPassword" to it.proxyUserPwd,
|
|
397
|
+
"livenessTransactionId" to it.livenessTransactionId,
|
|
395
398
|
"proxyType" to it.proxyType
|
|
396
399
|
).toJson()
|
|
397
400
|
}
|
|
@@ -464,6 +467,14 @@ fun livenessParamsFromJSON(input: JSONObject): LivenessParams {
|
|
|
464
467
|
|
|
465
468
|
fun generateLivenessParams(input: LivenessParams?) = getLivenessParams(input)
|
|
466
469
|
|
|
470
|
+
fun authenticityPropertiesParamsFromJSON(input: JSONObject): AuthenticityPropertiesParams {
|
|
471
|
+
val result = AuthenticityPropertiesParams.defaultParams()
|
|
472
|
+
setAuthenticityPropertiesParams(result, input)
|
|
473
|
+
return result
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
fun generateAuthenticityPropertiesParams(input: AuthenticityPropertiesParams?) = getAuthenticityPropertiesParams(input)
|
|
477
|
+
|
|
467
478
|
fun eDLDataGroupsFromJSON(input: JSONObject): EDLDataGroups {
|
|
468
479
|
val result = EDLDataGroups()
|
|
469
480
|
setDataGroups(result, input)
|
|
@@ -582,7 +593,7 @@ fun generateImageInputData(input: ImageInputData?) = input?.let {
|
|
|
582
593
|
).toJson()
|
|
583
594
|
}
|
|
584
595
|
|
|
585
|
-
fun pkdCertificateFromJSON(input: JSONObject?) = input?.let {
|
|
596
|
+
fun pkdCertificateFromJSON(input: JSONObject?): PKDCertificate? = input?.let {
|
|
586
597
|
var resourceType = 0
|
|
587
598
|
var binaryData = ByteArray(0)
|
|
588
599
|
|
|
@@ -237,7 +237,7 @@ internal object Convert {
|
|
|
237
237
|
BitmapDrawable(context.resources, Bitmap.createScaledBitmap(bitmap, width, height, false))
|
|
238
238
|
}
|
|
239
239
|
|
|
240
|
-
fun Drawable?.toBase64() = this?.let {
|
|
240
|
+
fun Drawable?.toBase64(): String? = this?.let {
|
|
241
241
|
if (this is BitmapDrawable) if (bitmap != null) return bitmap.toBase64()
|
|
242
242
|
val bitmap: Bitmap = if (intrinsicWidth <= 0 || intrinsicHeight <= 0) Bitmap.createBitmap(1, 1, Bitmap.Config.ARGB_8888) else Bitmap.createBitmap(intrinsicWidth, intrinsicHeight, Bitmap.Config.ARGB_8888)
|
|
243
243
|
val canvas = Canvas(bitmap)
|