@regulaforensics/idv 3.4.84-beta → 9.3.87-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/RNIDV.podspec +2 -2
- package/android/build.gradle +2 -2
- package/android/cordova.gradle +2 -2
- package/examples/capacitor/package.json +7 -7
- package/examples/ionic/package-lock.json +339 -71
- package/examples/ionic/package.json +7 -7
- package/examples/react_native/package.json +7 -7
- package/ios/CDVIDV.swift +18 -26
- package/ios/Main.swift +1 -1
- package/ios/RNIDV.m +1 -1
- package/ios/RNIDV.swift +13 -23
- package/ios/Utils.swift +10 -0
- package/package.json +1 -1
- package/plugin.xml +2 -2
- package/test/package-lock.json +1 -1
- package/www/capacitor/index.js +8 -21
- package/www/capacitor/internal/bridge.js +6 -0
- package/www/cordova.js +20 -26
- package/www/react-native/index.js +8 -21
- package/www/react-native/internal/bridge.js +6 -0
package/RNIDV.podspec
CHANGED
|
@@ -5,7 +5,7 @@ source = File.join(__dir__, 'ios')
|
|
|
5
5
|
|
|
6
6
|
Pod::Spec.new do |s|
|
|
7
7
|
s.name = 'RNIDV'
|
|
8
|
-
s.version = '3.
|
|
8
|
+
s.version = '9.3.87-nightly'
|
|
9
9
|
s.summary = package['description']
|
|
10
10
|
s.license = package['license']
|
|
11
11
|
|
|
@@ -16,6 +16,6 @@ Pod::Spec.new do |s|
|
|
|
16
16
|
s.ios.deployment_target = '14.0'
|
|
17
17
|
s.source_files = [ 'ios/**/*.swift', 'ios/**/RN*.m' ]
|
|
18
18
|
s.exclude_files = [ 'ios/CDVIDV.swift' ]
|
|
19
|
-
s.dependency '
|
|
19
|
+
s.dependency 'IDVSDKNightly', '0.1.184'
|
|
20
20
|
s.dependency 'React'
|
|
21
21
|
end
|
package/android/build.gradle
CHANGED
|
@@ -18,14 +18,14 @@ android {
|
|
|
18
18
|
rootProject.allprojects {
|
|
19
19
|
repositories {
|
|
20
20
|
maven {
|
|
21
|
-
url "https://maven.regulaforensics.com/RegulaDocumentReader"
|
|
21
|
+
url "https://maven.regulaforensics.com/RegulaDocumentReader/Nightly"
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
dependencies {
|
|
27
27
|
implementation 'com.facebook.react:react-native:+'
|
|
28
|
-
implementation('com.regula.idv:api:3.
|
|
28
|
+
implementation('com.regula.idv:api:3.2.1') {
|
|
29
29
|
transitive = true
|
|
30
30
|
}
|
|
31
31
|
}
|
package/android/cordova.gradle
CHANGED
|
@@ -9,12 +9,12 @@ android {
|
|
|
9
9
|
|
|
10
10
|
repositories {
|
|
11
11
|
maven {
|
|
12
|
-
url "https://maven.regulaforensics.com/RegulaDocumentReader"
|
|
12
|
+
url "https://maven.regulaforensics.com/RegulaDocumentReader/Nightly"
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
dependencies {
|
|
17
|
-
implementation('com.regula.idv:api:3.
|
|
17
|
+
implementation('com.regula.idv:api:3.2.1') {
|
|
18
18
|
transitive = true
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
"android": "scripts/android.sh"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
|
-
"@regulaforensics/idv": "3.
|
|
10
|
-
"@regulaforensics/document-reader": "9.
|
|
11
|
-
"@regulaforensics/face-sdk": "8.
|
|
12
|
-
"@regulaforensics/document-reader-core-fullauthrfid": "9.
|
|
13
|
-
"@regulaforensics/face-core-basic": "8.
|
|
14
|
-
"@regulaforensics/idv-module-document-reader": "3.
|
|
15
|
-
"@regulaforensics/idv-module-face": "3.
|
|
9
|
+
"@regulaforensics/idv": "9.3.87-nightly",
|
|
10
|
+
"@regulaforensics/document-reader": "9.3.691-nightly",
|
|
11
|
+
"@regulaforensics/face-sdk": "8.2.881-nightly",
|
|
12
|
+
"@regulaforensics/document-reader-core-fullauthrfid": "9.3.1774-nightly",
|
|
13
|
+
"@regulaforensics/face-core-basic": "8.2.473-nightly",
|
|
14
|
+
"@regulaforensics/idv-module-document-reader": "9.3.64-nightly",
|
|
15
|
+
"@regulaforensics/idv-module-face": "9.3.65-nightly",
|
|
16
16
|
"@capacitor/cli": "^8.0.0",
|
|
17
17
|
"@capacitor/core": "^8.0.0",
|
|
18
18
|
"@capacitor/app": "^8.0.0",
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
"packages": {
|
|
6
6
|
"": {
|
|
7
7
|
"name": "idv",
|
|
8
|
+
"hasInstallScript": true,
|
|
8
9
|
"dependencies": {
|
|
9
10
|
"@angular-devkit/build-angular": "^21.1.4",
|
|
10
11
|
"@angular/cli": "^21.1.4",
|
|
@@ -20,12 +21,13 @@
|
|
|
20
21
|
"@regulaforensics/document-reader-core-fullauthrfid": "9.2.1513",
|
|
21
22
|
"@regulaforensics/face-core-basic": "8.1.422",
|
|
22
23
|
"@regulaforensics/face-sdk": "8.1.796",
|
|
23
|
-
"@regulaforensics/idv": "3.4.
|
|
24
|
+
"@regulaforensics/idv": "3.4.84-beta",
|
|
24
25
|
"@regulaforensics/idv-module-document-reader": "3.4.54-beta",
|
|
25
26
|
"@regulaforensics/idv-module-face": "3.4.55-beta",
|
|
26
27
|
"cordova-android": "^14.0.1",
|
|
27
28
|
"cordova-ios": "^8.0.0",
|
|
28
|
-
"cordova-plugin-ionic-webview": "^5.0.1"
|
|
29
|
+
"cordova-plugin-ionic-webview": "^5.0.1",
|
|
30
|
+
"patch-package": "^8.0.1"
|
|
29
31
|
}
|
|
30
32
|
},
|
|
31
33
|
"node_modules/@algolia/abtesting": {
|
|
@@ -3553,23 +3555,6 @@
|
|
|
3553
3555
|
"yarn": ">= 1.13.0"
|
|
3554
3556
|
}
|
|
3555
3557
|
},
|
|
3556
|
-
"node_modules/@ionic/cordova-builders/node_modules/@angular/common": {
|
|
3557
|
-
"version": "20.3.16",
|
|
3558
|
-
"resolved": "https://registry.npmjs.org/@angular/common/-/common-20.3.16.tgz",
|
|
3559
|
-
"integrity": "sha512-GRAziNlntwdnJy3F+8zCOvDdy7id0gITjDnM6P9+n2lXvtDuBLGJKU3DWBbvxcCjtD6JK/g/rEX5fbCxbUHkQQ==",
|
|
3560
|
-
"extraneous": true,
|
|
3561
|
-
"license": "MIT",
|
|
3562
|
-
"dependencies": {
|
|
3563
|
-
"tslib": "^2.3.0"
|
|
3564
|
-
},
|
|
3565
|
-
"engines": {
|
|
3566
|
-
"node": "^20.19.0 || ^22.12.0 || >=24.0.0"
|
|
3567
|
-
},
|
|
3568
|
-
"peerDependencies": {
|
|
3569
|
-
"@angular/core": "20.3.16",
|
|
3570
|
-
"rxjs": "^6.5.3 || ^7.4.0"
|
|
3571
|
-
}
|
|
3572
|
-
},
|
|
3573
3558
|
"node_modules/@ionic/cordova-builders/node_modules/@angular/compiler": {
|
|
3574
3559
|
"version": "20.3.16",
|
|
3575
3560
|
"resolved": "https://registry.npmjs.org/@angular/compiler/-/compiler-20.3.16.tgz",
|
|
@@ -3616,55 +3601,6 @@
|
|
|
3616
3601
|
}
|
|
3617
3602
|
}
|
|
3618
3603
|
},
|
|
3619
|
-
"node_modules/@ionic/cordova-builders/node_modules/@angular/core": {
|
|
3620
|
-
"version": "20.3.16",
|
|
3621
|
-
"resolved": "https://registry.npmjs.org/@angular/core/-/core-20.3.16.tgz",
|
|
3622
|
-
"integrity": "sha512-KSFPKvOmWWLCJBbEO+CuRUXfecX2FRuO0jNi9c54ptXMOPHlK1lIojUnyXmMNzjdHgRug8ci9qDuftvC2B7MKg==",
|
|
3623
|
-
"extraneous": true,
|
|
3624
|
-
"license": "MIT",
|
|
3625
|
-
"dependencies": {
|
|
3626
|
-
"tslib": "^2.3.0"
|
|
3627
|
-
},
|
|
3628
|
-
"engines": {
|
|
3629
|
-
"node": "^20.19.0 || ^22.12.0 || >=24.0.0"
|
|
3630
|
-
},
|
|
3631
|
-
"peerDependencies": {
|
|
3632
|
-
"@angular/compiler": "20.3.16",
|
|
3633
|
-
"rxjs": "^6.5.3 || ^7.4.0",
|
|
3634
|
-
"zone.js": "~0.15.0"
|
|
3635
|
-
},
|
|
3636
|
-
"peerDependenciesMeta": {
|
|
3637
|
-
"@angular/compiler": {
|
|
3638
|
-
"optional": true
|
|
3639
|
-
},
|
|
3640
|
-
"zone.js": {
|
|
3641
|
-
"optional": true
|
|
3642
|
-
}
|
|
3643
|
-
}
|
|
3644
|
-
},
|
|
3645
|
-
"node_modules/@ionic/cordova-builders/node_modules/@angular/platform-browser": {
|
|
3646
|
-
"version": "20.3.16",
|
|
3647
|
-
"resolved": "https://registry.npmjs.org/@angular/platform-browser/-/platform-browser-20.3.16.tgz",
|
|
3648
|
-
"integrity": "sha512-YsrLS6vyS77i4pVHg4gdSBW74qvzHjpQRTVQ5Lv/OxIjJdYYYkMmjNalCNgy1ZuyY6CaLIB11ccxhrNnxfKGOQ==",
|
|
3649
|
-
"extraneous": true,
|
|
3650
|
-
"license": "MIT",
|
|
3651
|
-
"dependencies": {
|
|
3652
|
-
"tslib": "^2.3.0"
|
|
3653
|
-
},
|
|
3654
|
-
"engines": {
|
|
3655
|
-
"node": "^20.19.0 || ^22.12.0 || >=24.0.0"
|
|
3656
|
-
},
|
|
3657
|
-
"peerDependencies": {
|
|
3658
|
-
"@angular/animations": "20.3.16",
|
|
3659
|
-
"@angular/common": "20.3.16",
|
|
3660
|
-
"@angular/core": "20.3.16"
|
|
3661
|
-
},
|
|
3662
|
-
"peerDependenciesMeta": {
|
|
3663
|
-
"@angular/animations": {
|
|
3664
|
-
"optional": true
|
|
3665
|
-
}
|
|
3666
|
-
}
|
|
3667
|
-
},
|
|
3668
3604
|
"node_modules/@ionic/cordova-builders/node_modules/@babel/core": {
|
|
3669
3605
|
"version": "7.28.3",
|
|
3670
3606
|
"resolved": "https://registry.npmjs.org/@babel/core/-/core-7.28.3.tgz",
|
|
@@ -7147,9 +7083,9 @@
|
|
|
7147
7083
|
"license": "commercial"
|
|
7148
7084
|
},
|
|
7149
7085
|
"node_modules/@regulaforensics/idv": {
|
|
7150
|
-
"version": "3.4.
|
|
7151
|
-
"resolved": "https://registry.npmjs.org/@regulaforensics/idv/-/idv-3.4.
|
|
7152
|
-
"integrity": "sha512-
|
|
7086
|
+
"version": "3.4.84-beta",
|
|
7087
|
+
"resolved": "https://registry.npmjs.org/@regulaforensics/idv/-/idv-3.4.84-beta.tgz",
|
|
7088
|
+
"integrity": "sha512-FyhK4l8FxYidrz8V8unWYzlSDWakK2T+wFInhcrmOrsCWWOZPEkCEoEUkKqoMRFBUpg7HB6OxY79U+z2dHDb9w==",
|
|
7153
7089
|
"license": "commercial"
|
|
7154
7090
|
},
|
|
7155
7091
|
"node_modules/@regulaforensics/idv-module-document-reader": {
|
|
@@ -8907,6 +8843,24 @@
|
|
|
8907
8843
|
"node": "20 || >=22"
|
|
8908
8844
|
}
|
|
8909
8845
|
},
|
|
8846
|
+
"node_modules/call-bind": {
|
|
8847
|
+
"version": "1.0.8",
|
|
8848
|
+
"resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz",
|
|
8849
|
+
"integrity": "sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==",
|
|
8850
|
+
"license": "MIT",
|
|
8851
|
+
"dependencies": {
|
|
8852
|
+
"call-bind-apply-helpers": "^1.0.0",
|
|
8853
|
+
"es-define-property": "^1.0.0",
|
|
8854
|
+
"get-intrinsic": "^1.2.4",
|
|
8855
|
+
"set-function-length": "^1.2.2"
|
|
8856
|
+
},
|
|
8857
|
+
"engines": {
|
|
8858
|
+
"node": ">= 0.4"
|
|
8859
|
+
},
|
|
8860
|
+
"funding": {
|
|
8861
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
8862
|
+
}
|
|
8863
|
+
},
|
|
8910
8864
|
"node_modules/call-bind-apply-helpers": {
|
|
8911
8865
|
"version": "1.0.2",
|
|
8912
8866
|
"resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz",
|
|
@@ -9086,6 +9040,21 @@
|
|
|
9086
9040
|
"node": ">=6.0"
|
|
9087
9041
|
}
|
|
9088
9042
|
},
|
|
9043
|
+
"node_modules/ci-info": {
|
|
9044
|
+
"version": "3.9.0",
|
|
9045
|
+
"resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz",
|
|
9046
|
+
"integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==",
|
|
9047
|
+
"funding": [
|
|
9048
|
+
{
|
|
9049
|
+
"type": "github",
|
|
9050
|
+
"url": "https://github.com/sponsors/sibiraj-s"
|
|
9051
|
+
}
|
|
9052
|
+
],
|
|
9053
|
+
"license": "MIT",
|
|
9054
|
+
"engines": {
|
|
9055
|
+
"node": ">=8"
|
|
9056
|
+
}
|
|
9057
|
+
},
|
|
9089
9058
|
"node_modules/cli-cursor": {
|
|
9090
9059
|
"version": "5.0.0",
|
|
9091
9060
|
"resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-5.0.0.tgz",
|
|
@@ -9769,6 +9738,23 @@
|
|
|
9769
9738
|
"url": "https://github.com/sponsors/sindresorhus"
|
|
9770
9739
|
}
|
|
9771
9740
|
},
|
|
9741
|
+
"node_modules/define-data-property": {
|
|
9742
|
+
"version": "1.1.4",
|
|
9743
|
+
"resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz",
|
|
9744
|
+
"integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==",
|
|
9745
|
+
"license": "MIT",
|
|
9746
|
+
"dependencies": {
|
|
9747
|
+
"es-define-property": "^1.0.0",
|
|
9748
|
+
"es-errors": "^1.3.0",
|
|
9749
|
+
"gopd": "^1.0.1"
|
|
9750
|
+
},
|
|
9751
|
+
"engines": {
|
|
9752
|
+
"node": ">= 0.4"
|
|
9753
|
+
},
|
|
9754
|
+
"funding": {
|
|
9755
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
9756
|
+
}
|
|
9757
|
+
},
|
|
9772
9758
|
"node_modules/define-lazy-prop": {
|
|
9773
9759
|
"version": "3.0.0",
|
|
9774
9760
|
"resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-3.0.0.tgz",
|
|
@@ -10533,6 +10519,15 @@
|
|
|
10533
10519
|
"url": "https://github.com/sponsors/sindresorhus"
|
|
10534
10520
|
}
|
|
10535
10521
|
},
|
|
10522
|
+
"node_modules/find-yarn-workspace-root": {
|
|
10523
|
+
"version": "2.0.0",
|
|
10524
|
+
"resolved": "https://registry.npmjs.org/find-yarn-workspace-root/-/find-yarn-workspace-root-2.0.0.tgz",
|
|
10525
|
+
"integrity": "sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ==",
|
|
10526
|
+
"license": "Apache-2.0",
|
|
10527
|
+
"dependencies": {
|
|
10528
|
+
"micromatch": "^4.0.2"
|
|
10529
|
+
}
|
|
10530
|
+
},
|
|
10536
10531
|
"node_modules/flat": {
|
|
10537
10532
|
"version": "5.0.2",
|
|
10538
10533
|
"resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz",
|
|
@@ -10593,6 +10588,20 @@
|
|
|
10593
10588
|
"node": ">= 0.8"
|
|
10594
10589
|
}
|
|
10595
10590
|
},
|
|
10591
|
+
"node_modules/fs-extra": {
|
|
10592
|
+
"version": "10.1.0",
|
|
10593
|
+
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
|
|
10594
|
+
"integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
|
|
10595
|
+
"license": "MIT",
|
|
10596
|
+
"dependencies": {
|
|
10597
|
+
"graceful-fs": "^4.2.0",
|
|
10598
|
+
"jsonfile": "^6.0.1",
|
|
10599
|
+
"universalify": "^2.0.0"
|
|
10600
|
+
},
|
|
10601
|
+
"engines": {
|
|
10602
|
+
"node": ">=12"
|
|
10603
|
+
}
|
|
10604
|
+
},
|
|
10596
10605
|
"node_modules/fs-minipass": {
|
|
10597
10606
|
"version": "3.0.3",
|
|
10598
10607
|
"resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-3.0.3.tgz",
|
|
@@ -10811,6 +10820,18 @@
|
|
|
10811
10820
|
"node": ">=8"
|
|
10812
10821
|
}
|
|
10813
10822
|
},
|
|
10823
|
+
"node_modules/has-property-descriptors": {
|
|
10824
|
+
"version": "1.0.2",
|
|
10825
|
+
"resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz",
|
|
10826
|
+
"integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==",
|
|
10827
|
+
"license": "MIT",
|
|
10828
|
+
"dependencies": {
|
|
10829
|
+
"es-define-property": "^1.0.0"
|
|
10830
|
+
},
|
|
10831
|
+
"funding": {
|
|
10832
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
10833
|
+
}
|
|
10834
|
+
},
|
|
10814
10835
|
"node_modules/has-symbols": {
|
|
10815
10836
|
"version": "1.1.0",
|
|
10816
10837
|
"resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz",
|
|
@@ -11546,6 +11567,31 @@
|
|
|
11546
11567
|
"integrity": "sha512-fQhoXdcvc3V28x7C7BMs4P5+kNlgUURe2jmUT1T//oBRMDrqy1QPelJimwZGo7Hg9VPV3EQV5Bnq4hbFy2vetA==",
|
|
11547
11568
|
"license": "BSD-2-Clause"
|
|
11548
11569
|
},
|
|
11570
|
+
"node_modules/json-stable-stringify": {
|
|
11571
|
+
"version": "1.3.0",
|
|
11572
|
+
"resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.3.0.tgz",
|
|
11573
|
+
"integrity": "sha512-qtYiSSFlwot9XHtF9bD9c7rwKjr+RecWT//ZnPvSmEjpV5mmPOCN4j8UjY5hbjNkOwZ/jQv3J6R1/pL7RwgMsg==",
|
|
11574
|
+
"license": "MIT",
|
|
11575
|
+
"dependencies": {
|
|
11576
|
+
"call-bind": "^1.0.8",
|
|
11577
|
+
"call-bound": "^1.0.4",
|
|
11578
|
+
"isarray": "^2.0.5",
|
|
11579
|
+
"jsonify": "^0.0.1",
|
|
11580
|
+
"object-keys": "^1.1.1"
|
|
11581
|
+
},
|
|
11582
|
+
"engines": {
|
|
11583
|
+
"node": ">= 0.4"
|
|
11584
|
+
},
|
|
11585
|
+
"funding": {
|
|
11586
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
11587
|
+
}
|
|
11588
|
+
},
|
|
11589
|
+
"node_modules/json-stable-stringify/node_modules/isarray": {
|
|
11590
|
+
"version": "2.0.5",
|
|
11591
|
+
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz",
|
|
11592
|
+
"integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==",
|
|
11593
|
+
"license": "MIT"
|
|
11594
|
+
},
|
|
11549
11595
|
"node_modules/json5": {
|
|
11550
11596
|
"version": "2.2.3",
|
|
11551
11597
|
"resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz",
|
|
@@ -11564,6 +11610,27 @@
|
|
|
11564
11610
|
"integrity": "sha512-HUgH65KyejrUFPvHFPbqOY0rsFip3Bo5wb4ngvdi1EpCYWUQDC5V+Y7mZws+DLkr4M//zQJoanu1SP+87Dv1oQ==",
|
|
11565
11611
|
"license": "MIT"
|
|
11566
11612
|
},
|
|
11613
|
+
"node_modules/jsonfile": {
|
|
11614
|
+
"version": "6.2.0",
|
|
11615
|
+
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.2.0.tgz",
|
|
11616
|
+
"integrity": "sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==",
|
|
11617
|
+
"license": "MIT",
|
|
11618
|
+
"dependencies": {
|
|
11619
|
+
"universalify": "^2.0.0"
|
|
11620
|
+
},
|
|
11621
|
+
"optionalDependencies": {
|
|
11622
|
+
"graceful-fs": "^4.1.6"
|
|
11623
|
+
}
|
|
11624
|
+
},
|
|
11625
|
+
"node_modules/jsonify": {
|
|
11626
|
+
"version": "0.0.1",
|
|
11627
|
+
"resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.1.tgz",
|
|
11628
|
+
"integrity": "sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==",
|
|
11629
|
+
"license": "Public Domain",
|
|
11630
|
+
"funding": {
|
|
11631
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
11632
|
+
}
|
|
11633
|
+
},
|
|
11567
11634
|
"node_modules/jsonparse": {
|
|
11568
11635
|
"version": "1.3.1",
|
|
11569
11636
|
"resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz",
|
|
@@ -11591,6 +11658,15 @@
|
|
|
11591
11658
|
"node": ">=0.10.0"
|
|
11592
11659
|
}
|
|
11593
11660
|
},
|
|
11661
|
+
"node_modules/klaw-sync": {
|
|
11662
|
+
"version": "6.0.0",
|
|
11663
|
+
"resolved": "https://registry.npmjs.org/klaw-sync/-/klaw-sync-6.0.0.tgz",
|
|
11664
|
+
"integrity": "sha512-nIeuVSzdCCs6TDPTqI8w1Yre34sSq7AkZ4B3sfOBbI2CgVSB4Du4aLQijFU2+lhAFCwt9+42Hel6lQNIv6AntQ==",
|
|
11665
|
+
"license": "MIT",
|
|
11666
|
+
"dependencies": {
|
|
11667
|
+
"graceful-fs": "^4.1.11"
|
|
11668
|
+
}
|
|
11669
|
+
},
|
|
11594
11670
|
"node_modules/launch-editor": {
|
|
11595
11671
|
"version": "2.13.0",
|
|
11596
11672
|
"resolved": "https://registry.npmjs.org/launch-editor/-/launch-editor-2.13.0.tgz",
|
|
@@ -12165,6 +12241,15 @@
|
|
|
12165
12241
|
"url": "https://github.com/sponsors/isaacs"
|
|
12166
12242
|
}
|
|
12167
12243
|
},
|
|
12244
|
+
"node_modules/minimist": {
|
|
12245
|
+
"version": "1.2.8",
|
|
12246
|
+
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz",
|
|
12247
|
+
"integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==",
|
|
12248
|
+
"license": "MIT",
|
|
12249
|
+
"funding": {
|
|
12250
|
+
"url": "https://github.com/sponsors/ljharb"
|
|
12251
|
+
}
|
|
12252
|
+
},
|
|
12168
12253
|
"node_modules/minipass": {
|
|
12169
12254
|
"version": "7.1.3",
|
|
12170
12255
|
"resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.3.tgz",
|
|
@@ -12711,6 +12796,15 @@
|
|
|
12711
12796
|
"url": "https://github.com/sponsors/ljharb"
|
|
12712
12797
|
}
|
|
12713
12798
|
},
|
|
12799
|
+
"node_modules/object-keys": {
|
|
12800
|
+
"version": "1.1.1",
|
|
12801
|
+
"resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
|
|
12802
|
+
"integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",
|
|
12803
|
+
"license": "MIT",
|
|
12804
|
+
"engines": {
|
|
12805
|
+
"node": ">= 0.4"
|
|
12806
|
+
}
|
|
12807
|
+
},
|
|
12714
12808
|
"node_modules/objectorarray": {
|
|
12715
12809
|
"version": "1.0.5",
|
|
12716
12810
|
"resolved": "https://registry.npmjs.org/objectorarray/-/objectorarray-1.0.5.tgz",
|
|
@@ -13112,6 +13206,130 @@
|
|
|
13112
13206
|
"node": ">= 0.8"
|
|
13113
13207
|
}
|
|
13114
13208
|
},
|
|
13209
|
+
"node_modules/patch-package": {
|
|
13210
|
+
"version": "8.0.1",
|
|
13211
|
+
"resolved": "https://registry.npmjs.org/patch-package/-/patch-package-8.0.1.tgz",
|
|
13212
|
+
"integrity": "sha512-VsKRIA8f5uqHQ7NGhwIna6Bx6D9s/1iXlA1hthBVBEbkq+t4kXD0HHt+rJhf/Z+Ci0F/HCB2hvn0qLdLG+Qxlw==",
|
|
13213
|
+
"license": "MIT",
|
|
13214
|
+
"dependencies": {
|
|
13215
|
+
"@yarnpkg/lockfile": "^1.1.0",
|
|
13216
|
+
"chalk": "^4.1.2",
|
|
13217
|
+
"ci-info": "^3.7.0",
|
|
13218
|
+
"cross-spawn": "^7.0.3",
|
|
13219
|
+
"find-yarn-workspace-root": "^2.0.0",
|
|
13220
|
+
"fs-extra": "^10.0.0",
|
|
13221
|
+
"json-stable-stringify": "^1.0.2",
|
|
13222
|
+
"klaw-sync": "^6.0.0",
|
|
13223
|
+
"minimist": "^1.2.6",
|
|
13224
|
+
"open": "^7.4.2",
|
|
13225
|
+
"semver": "^7.5.3",
|
|
13226
|
+
"slash": "^2.0.0",
|
|
13227
|
+
"tmp": "^0.2.4",
|
|
13228
|
+
"yaml": "^2.2.2"
|
|
13229
|
+
},
|
|
13230
|
+
"bin": {
|
|
13231
|
+
"patch-package": "index.js"
|
|
13232
|
+
},
|
|
13233
|
+
"engines": {
|
|
13234
|
+
"node": ">=14",
|
|
13235
|
+
"npm": ">5"
|
|
13236
|
+
}
|
|
13237
|
+
},
|
|
13238
|
+
"node_modules/patch-package/node_modules/ansi-styles": {
|
|
13239
|
+
"version": "4.3.0",
|
|
13240
|
+
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
|
|
13241
|
+
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
|
|
13242
|
+
"license": "MIT",
|
|
13243
|
+
"dependencies": {
|
|
13244
|
+
"color-convert": "^2.0.1"
|
|
13245
|
+
},
|
|
13246
|
+
"engines": {
|
|
13247
|
+
"node": ">=8"
|
|
13248
|
+
},
|
|
13249
|
+
"funding": {
|
|
13250
|
+
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
|
|
13251
|
+
}
|
|
13252
|
+
},
|
|
13253
|
+
"node_modules/patch-package/node_modules/chalk": {
|
|
13254
|
+
"version": "4.1.2",
|
|
13255
|
+
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
|
|
13256
|
+
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
|
|
13257
|
+
"license": "MIT",
|
|
13258
|
+
"dependencies": {
|
|
13259
|
+
"ansi-styles": "^4.1.0",
|
|
13260
|
+
"supports-color": "^7.1.0"
|
|
13261
|
+
},
|
|
13262
|
+
"engines": {
|
|
13263
|
+
"node": ">=10"
|
|
13264
|
+
},
|
|
13265
|
+
"funding": {
|
|
13266
|
+
"url": "https://github.com/chalk/chalk?sponsor=1"
|
|
13267
|
+
}
|
|
13268
|
+
},
|
|
13269
|
+
"node_modules/patch-package/node_modules/is-docker": {
|
|
13270
|
+
"version": "2.2.1",
|
|
13271
|
+
"resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz",
|
|
13272
|
+
"integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==",
|
|
13273
|
+
"license": "MIT",
|
|
13274
|
+
"bin": {
|
|
13275
|
+
"is-docker": "cli.js"
|
|
13276
|
+
},
|
|
13277
|
+
"engines": {
|
|
13278
|
+
"node": ">=8"
|
|
13279
|
+
},
|
|
13280
|
+
"funding": {
|
|
13281
|
+
"url": "https://github.com/sponsors/sindresorhus"
|
|
13282
|
+
}
|
|
13283
|
+
},
|
|
13284
|
+
"node_modules/patch-package/node_modules/is-wsl": {
|
|
13285
|
+
"version": "2.2.0",
|
|
13286
|
+
"resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz",
|
|
13287
|
+
"integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==",
|
|
13288
|
+
"license": "MIT",
|
|
13289
|
+
"dependencies": {
|
|
13290
|
+
"is-docker": "^2.0.0"
|
|
13291
|
+
},
|
|
13292
|
+
"engines": {
|
|
13293
|
+
"node": ">=8"
|
|
13294
|
+
}
|
|
13295
|
+
},
|
|
13296
|
+
"node_modules/patch-package/node_modules/open": {
|
|
13297
|
+
"version": "7.4.2",
|
|
13298
|
+
"resolved": "https://registry.npmjs.org/open/-/open-7.4.2.tgz",
|
|
13299
|
+
"integrity": "sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==",
|
|
13300
|
+
"license": "MIT",
|
|
13301
|
+
"dependencies": {
|
|
13302
|
+
"is-docker": "^2.0.0",
|
|
13303
|
+
"is-wsl": "^2.1.1"
|
|
13304
|
+
},
|
|
13305
|
+
"engines": {
|
|
13306
|
+
"node": ">=8"
|
|
13307
|
+
},
|
|
13308
|
+
"funding": {
|
|
13309
|
+
"url": "https://github.com/sponsors/sindresorhus"
|
|
13310
|
+
}
|
|
13311
|
+
},
|
|
13312
|
+
"node_modules/patch-package/node_modules/slash": {
|
|
13313
|
+
"version": "2.0.0",
|
|
13314
|
+
"resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz",
|
|
13315
|
+
"integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==",
|
|
13316
|
+
"license": "MIT",
|
|
13317
|
+
"engines": {
|
|
13318
|
+
"node": ">=6"
|
|
13319
|
+
}
|
|
13320
|
+
},
|
|
13321
|
+
"node_modules/patch-package/node_modules/supports-color": {
|
|
13322
|
+
"version": "7.2.0",
|
|
13323
|
+
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
|
|
13324
|
+
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
|
|
13325
|
+
"license": "MIT",
|
|
13326
|
+
"dependencies": {
|
|
13327
|
+
"has-flag": "^4.0.0"
|
|
13328
|
+
},
|
|
13329
|
+
"engines": {
|
|
13330
|
+
"node": ">=8"
|
|
13331
|
+
}
|
|
13332
|
+
},
|
|
13115
13333
|
"node_modules/path-exists": {
|
|
13116
13334
|
"version": "4.0.0",
|
|
13117
13335
|
"resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
|
|
@@ -14374,6 +14592,23 @@
|
|
|
14374
14592
|
"url": "https://opencollective.com/express"
|
|
14375
14593
|
}
|
|
14376
14594
|
},
|
|
14595
|
+
"node_modules/set-function-length": {
|
|
14596
|
+
"version": "1.2.2",
|
|
14597
|
+
"resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz",
|
|
14598
|
+
"integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==",
|
|
14599
|
+
"license": "MIT",
|
|
14600
|
+
"dependencies": {
|
|
14601
|
+
"define-data-property": "^1.1.4",
|
|
14602
|
+
"es-errors": "^1.3.0",
|
|
14603
|
+
"function-bind": "^1.1.2",
|
|
14604
|
+
"get-intrinsic": "^1.2.4",
|
|
14605
|
+
"gopd": "^1.0.1",
|
|
14606
|
+
"has-property-descriptors": "^1.0.2"
|
|
14607
|
+
},
|
|
14608
|
+
"engines": {
|
|
14609
|
+
"node": ">= 0.4"
|
|
14610
|
+
}
|
|
14611
|
+
},
|
|
14377
14612
|
"node_modules/setprototypeof": {
|
|
14378
14613
|
"version": "1.2.0",
|
|
14379
14614
|
"resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz",
|
|
@@ -15020,6 +15255,15 @@
|
|
|
15020
15255
|
"url": "https://github.com/sponsors/SuperchupuDev"
|
|
15021
15256
|
}
|
|
15022
15257
|
},
|
|
15258
|
+
"node_modules/tmp": {
|
|
15259
|
+
"version": "0.2.5",
|
|
15260
|
+
"resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.5.tgz",
|
|
15261
|
+
"integrity": "sha512-voyz6MApa1rQGUxT3E+BK7/ROe8itEx7vD8/HEvt4xwXucvQ5G5oeEiHkmHZJuBO21RpOf+YYm9MOivj709jow==",
|
|
15262
|
+
"license": "MIT",
|
|
15263
|
+
"engines": {
|
|
15264
|
+
"node": ">=14.14"
|
|
15265
|
+
}
|
|
15266
|
+
},
|
|
15023
15267
|
"node_modules/to-regex-range": {
|
|
15024
15268
|
"version": "5.0.1",
|
|
15025
15269
|
"resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
|
|
@@ -15211,6 +15455,15 @@
|
|
|
15211
15455
|
"node": "^20.17.0 || >=22.9.0"
|
|
15212
15456
|
}
|
|
15213
15457
|
},
|
|
15458
|
+
"node_modules/universalify": {
|
|
15459
|
+
"version": "2.0.1",
|
|
15460
|
+
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
15461
|
+
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
15462
|
+
"license": "MIT",
|
|
15463
|
+
"engines": {
|
|
15464
|
+
"node": ">= 10.0.0"
|
|
15465
|
+
}
|
|
15466
|
+
},
|
|
15214
15467
|
"node_modules/unpipe": {
|
|
15215
15468
|
"version": "1.0.0",
|
|
15216
15469
|
"resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz",
|
|
@@ -16299,6 +16552,21 @@
|
|
|
16299
16552
|
"integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==",
|
|
16300
16553
|
"license": "ISC"
|
|
16301
16554
|
},
|
|
16555
|
+
"node_modules/yaml": {
|
|
16556
|
+
"version": "2.8.2",
|
|
16557
|
+
"resolved": "https://registry.npmjs.org/yaml/-/yaml-2.8.2.tgz",
|
|
16558
|
+
"integrity": "sha512-mplynKqc1C2hTVYxd0PU2xQAc22TI1vShAYGksCCfxbn/dFwnHTNi1bvYsBTkhdUNtGIf5xNOg938rrSSYvS9A==",
|
|
16559
|
+
"license": "ISC",
|
|
16560
|
+
"bin": {
|
|
16561
|
+
"yaml": "bin.mjs"
|
|
16562
|
+
},
|
|
16563
|
+
"engines": {
|
|
16564
|
+
"node": ">= 14.6"
|
|
16565
|
+
},
|
|
16566
|
+
"funding": {
|
|
16567
|
+
"url": "https://github.com/sponsors/eemeli"
|
|
16568
|
+
}
|
|
16569
|
+
},
|
|
16302
16570
|
"node_modules/yargs": {
|
|
16303
16571
|
"version": "18.0.0",
|
|
16304
16572
|
"resolved": "https://registry.npmjs.org/yargs/-/yargs-18.0.0.tgz",
|
|
@@ -17,13 +17,13 @@
|
|
|
17
17
|
"@angular/router": "^21.1.5",
|
|
18
18
|
"@ionic/angular": "^8.7.17",
|
|
19
19
|
"@ionic/cordova-builders": "^12.3.0",
|
|
20
|
-
"@regulaforensics/document-reader": "9.
|
|
21
|
-
"@regulaforensics/face-sdk": "8.
|
|
22
|
-
"@regulaforensics/document-reader-core-fullauthrfid": "9.
|
|
23
|
-
"@regulaforensics/face-core-basic": "8.
|
|
24
|
-
"@regulaforensics/idv": "3.
|
|
25
|
-
"@regulaforensics/idv-module-document-reader": "3.
|
|
26
|
-
"@regulaforensics/idv-module-face": "3.
|
|
20
|
+
"@regulaforensics/document-reader": "9.3.691-nightly",
|
|
21
|
+
"@regulaforensics/face-sdk": "8.2.881-nightly",
|
|
22
|
+
"@regulaforensics/document-reader-core-fullauthrfid": "9.3.1774-nightly",
|
|
23
|
+
"@regulaforensics/face-core-basic": "8.2.473-nightly",
|
|
24
|
+
"@regulaforensics/idv": "9.3.87-nightly",
|
|
25
|
+
"@regulaforensics/idv-module-document-reader": "9.3.64-nightly",
|
|
26
|
+
"@regulaforensics/idv-module-face": "9.3.65-nightly",
|
|
27
27
|
"cordova-android": "^14.0.1",
|
|
28
28
|
"cordova-ios": "^8.0.0",
|
|
29
29
|
"cordova-plugin-ionic-webview": "^5.0.1",
|
|
@@ -8,13 +8,13 @@
|
|
|
8
8
|
"start": "expo start"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@regulaforensics/idv": "3.
|
|
12
|
-
"@regulaforensics/document-reader": "9.
|
|
13
|
-
"@regulaforensics/face-sdk": "8.
|
|
14
|
-
"@regulaforensics/document-reader-core-fullauthrfid": "9.
|
|
15
|
-
"@regulaforensics/face-core-basic": "8.
|
|
16
|
-
"@regulaforensics/idv-module-document-reader": "3.
|
|
17
|
-
"@regulaforensics/idv-module-face": "3.
|
|
11
|
+
"@regulaforensics/idv": "9.3.87-nightly",
|
|
12
|
+
"@regulaforensics/document-reader": "9.3.691-nightly",
|
|
13
|
+
"@regulaforensics/face-sdk": "8.2.881-nightly",
|
|
14
|
+
"@regulaforensics/document-reader-core-fullauthrfid": "9.3.1774-nightly",
|
|
15
|
+
"@regulaforensics/face-core-basic": "8.2.473-nightly",
|
|
16
|
+
"@regulaforensics/idv-module-document-reader": "9.3.64-nightly",
|
|
17
|
+
"@regulaforensics/idv-module-face": "9.3.65-nightly",
|
|
18
18
|
"react-native": "^0.81.4",
|
|
19
19
|
"react-native-webview": "^13.16.0",
|
|
20
20
|
"@react-native/metro-config": "^0.81.1",
|
package/ios/CDVIDV.swift
CHANGED
|
@@ -1,29 +1,3 @@
|
|
|
1
|
-
var eventCallbackIds: [String: String] = [:]
|
|
2
|
-
private var args: [Any?] = []
|
|
3
|
-
private var this: CDVIDV?
|
|
4
|
-
|
|
5
|
-
func sendEvent(_ event: String, _ data: Any? = "") {
|
|
6
|
-
var callbackId = event
|
|
7
|
-
let eventId = eventCallbackIds[event]
|
|
8
|
-
if eventId != nil { callbackId = eventId! }
|
|
9
|
-
|
|
10
|
-
var sendable = data.toSendable()
|
|
11
|
-
if sendable is NSNull { sendable = "" }
|
|
12
|
-
let result = CDVPluginResult(status: CDVCommandStatus.ok, messageAs: sendable as! String)
|
|
13
|
-
result.setKeepCallbackAs(true)
|
|
14
|
-
|
|
15
|
-
this!.commandDelegate.send(result, callbackId: callbackId)
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
func args<T>(_ index: Int) -> T {
|
|
19
|
-
return args[index] as! T
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
func argsNullable<T>(_ index: Int) -> T? {
|
|
23
|
-
if (args[index] is NSNull) { return nil }
|
|
24
|
-
return args[index] as! T?
|
|
25
|
-
}
|
|
26
|
-
|
|
27
1
|
@objc(CDVIDV)
|
|
28
2
|
class CDVIDV: CDVPlugin {
|
|
29
3
|
@objc(exec:)
|
|
@@ -41,6 +15,24 @@ class CDVIDV: CDVPlugin {
|
|
|
41
15
|
}
|
|
42
16
|
}
|
|
43
17
|
|
|
18
|
+
var this: CDVIDV?
|
|
19
|
+
var eventCallbackIds: [String: String] = [:]
|
|
20
|
+
func sendEvent(_ event: String, _ data: Any? = "") {
|
|
21
|
+
var callbackId = event
|
|
22
|
+
let eventId = eventCallbackIds[event]
|
|
23
|
+
if eventId != nil { callbackId = eventId! }
|
|
24
|
+
|
|
25
|
+
// In this section unreasonable casts and optionals are made to
|
|
26
|
+
// ensure that this code works with both cordova-ios@7 and cordova-ios@8.
|
|
27
|
+
var sendable = data.toSendable()
|
|
28
|
+
if sendable is NSNull { sendable = "" }
|
|
29
|
+
let message = sendable as! String
|
|
30
|
+
let result: CDVPluginResult? = CDVPluginResult(status: CDVCommandStatus.ok, messageAs: message)
|
|
31
|
+
result!.setKeepCallbackAs(true)
|
|
32
|
+
|
|
33
|
+
this!.commandDelegate.send(result!, callbackId: callbackId)
|
|
34
|
+
}
|
|
35
|
+
|
|
44
36
|
let rootViewController: () -> UIViewController? = {
|
|
45
37
|
return UIApplication.shared.connectedScenes
|
|
46
38
|
.compactMap { $0 as? UIWindowScene }
|
package/ios/Main.swift
CHANGED
|
@@ -6,7 +6,7 @@ let didStartRestoreSessionEvent = "didStartRestoreSessionEvent"
|
|
|
6
6
|
let didContinueRemoteSessionEvent = "didContinueRemoteSessionEvent"
|
|
7
7
|
|
|
8
8
|
func methodCall(_ method: String, _ callback: @escaping Callback) {
|
|
9
|
-
switch
|
|
9
|
+
switch method {
|
|
10
10
|
case("setSessionRestoreMode"): IDV.shared.sessionRestoreMode = SessionRestoreMode(rawValue: args(0))!
|
|
11
11
|
case("getCurrentSessionId"): callback(IDV.shared.currentSessionId)
|
|
12
12
|
case("initialize"): initialize(callback)
|
package/ios/RNIDV.m
CHANGED
package/ios/RNIDV.swift
CHANGED
|
@@ -1,26 +1,5 @@
|
|
|
1
1
|
import React
|
|
2
2
|
|
|
3
|
-
func sendEvent(_ event: String, _ data: Any? = nil) {
|
|
4
|
-
guard let plugin = this, hasListeners else { return }
|
|
5
|
-
DispatchQueue.main.async {
|
|
6
|
-
plugin.sendEvent(withName: event, body: data.toSendable())
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
func args<T>(_ index: Int) -> T {
|
|
11
|
-
return mArgs[index] as! T
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
func argsNullable<T>(_ index: Int) -> T? {
|
|
15
|
-
if (mArgs[index] is NSNull) { return nil }
|
|
16
|
-
return mArgs[index] as! T?
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
private var firedCallbacks: [RCTResponseSenderBlock] = []
|
|
20
|
-
private var hasListeners: Bool = false
|
|
21
|
-
private var this: RNIDV?
|
|
22
|
-
private var mArgs: [Any?] = []
|
|
23
|
-
|
|
24
3
|
@objc(RNIDV)
|
|
25
4
|
public class RNIDV: RCTEventEmitter {
|
|
26
5
|
override public func startObserving() { hasListeners = true }
|
|
@@ -33,9 +12,9 @@ public class RNIDV: RCTEventEmitter {
|
|
|
33
12
|
}
|
|
34
13
|
|
|
35
14
|
@objc
|
|
36
|
-
func exec(_ method: String,
|
|
15
|
+
func exec(_ method: String, newArgs: [Any], resolve: @escaping RCTPromiseResolveBlock, reject: @escaping RCTPromiseRejectBlock) {
|
|
37
16
|
this = self
|
|
38
|
-
|
|
17
|
+
args = newArgs
|
|
39
18
|
methodCall(method, { data in
|
|
40
19
|
if firedCallbacks.contains(where: { ($0 as AnyObject) === (resolve as AnyObject) }) { return }
|
|
41
20
|
firedCallbacks.append(resolve)
|
|
@@ -44,4 +23,15 @@ public class RNIDV: RCTEventEmitter {
|
|
|
44
23
|
}
|
|
45
24
|
}
|
|
46
25
|
|
|
26
|
+
private var firedCallbacks: [RCTResponseSenderBlock] = []
|
|
27
|
+
private var hasListeners: Bool = false
|
|
28
|
+
private var this: RNIDV?
|
|
29
|
+
|
|
30
|
+
func sendEvent(_ event: String, _ data: Any? = nil) {
|
|
31
|
+
guard let plugin = this, hasListeners else { return }
|
|
32
|
+
DispatchQueue.main.async {
|
|
33
|
+
plugin.sendEvent(withName: event, body: data.toSendable())
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
47
37
|
let rootViewController: () -> UIViewController? = { return RCTPresentedViewController() }
|
package/ios/Utils.swift
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
public typealias Callback = (Any?) -> Void
|
|
2
2
|
|
|
3
|
+
var args: [Any?] = []
|
|
4
|
+
func args<T>(_ index: Int) -> T {
|
|
5
|
+
return args[index] as! T
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
func argsNullable<T>(_ index: Int) -> T? {
|
|
9
|
+
if args[index] is NSNull { return nil }
|
|
10
|
+
return args[index] as! T?
|
|
11
|
+
}
|
|
12
|
+
|
|
3
13
|
extension Any? {
|
|
4
14
|
func toSendable() -> Any {
|
|
5
15
|
guard let self else { return NSNull() }
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@regulaforensics/idv",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "9.3.87-nightly",
|
|
4
4
|
"description": "This is an npm module for Regula IDV, which unifies access to all Regula products. This plugin makes possible to use it with react-native, cordova and capacitor applications. Supports Android and iOS.",
|
|
5
5
|
"main": "www/react-native/index.js",
|
|
6
6
|
"module": "www/capacitor/index.js",
|
package/plugin.xml
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<?xml version='1.0' encoding='utf-8'?>
|
|
2
|
-
<plugin id="@regulaforensics/idv" version="3.
|
|
2
|
+
<plugin id="@regulaforensics/idv" version="9.3.87-nightly" xmlns="http://apache.org/cordova/ns/plugins/1.0">
|
|
3
3
|
<name>IDV</name>
|
|
4
4
|
<description>Cordova plugin for Regula IDV</description>
|
|
5
5
|
<license>commercial</license>
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
<source url="https://github.com/CocoaPods/Specs.git" />
|
|
27
27
|
</config>
|
|
28
28
|
<pods>
|
|
29
|
-
<pod name="
|
|
29
|
+
<pod name="IDVSDKNightly" spec="0.1.184" />
|
|
30
30
|
</pods>
|
|
31
31
|
</podspec>
|
|
32
32
|
</platform>
|
package/test/package-lock.json
CHANGED
package/www/capacitor/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { exec, setDidStartSessionCompletion, setDidEndSessionCompletion, setDidStartRestoreSessionCompletion, setDidContinueRemoteSessionCompletion } from './internal/bridge'
|
|
1
|
+
import { exec, serializeInterface, setDidStartSessionCompletion, setDidEndSessionCompletion, setDidStartRestoreSessionCompletion, setDidContinueRemoteSessionCompletion } from './internal/bridge'
|
|
2
2
|
|
|
3
3
|
import { TokenConnectionConfig } from './config/token_connection_config'
|
|
4
4
|
import { CredentialsConnectionConfig } from './config/credentials_connection_config'
|
|
@@ -44,32 +44,27 @@ export class IDV {
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
async configureWithToken(config) {
|
|
47
|
-
|
|
48
|
-
const response = await exec('configureWithToken', [config?.toJson()])
|
|
47
|
+
const response = await exec('configureWithToken', [serializeInterface(config, TokenConnectionConfig)])
|
|
49
48
|
return completionFromResponse(response, success => success?.map(item => String(item)))
|
|
50
49
|
}
|
|
51
50
|
|
|
52
51
|
async configureWithCredentials(config) {
|
|
53
|
-
|
|
54
|
-
const response = await exec('configureWithCredentials', [config?.toJson()])
|
|
52
|
+
const response = await exec('configureWithCredentials', [serializeInterface(config, CredentialsConnectionConfig)])
|
|
55
53
|
return completionFromResponse(response)
|
|
56
54
|
}
|
|
57
55
|
|
|
58
56
|
async configureWithApiKey(config) {
|
|
59
|
-
|
|
60
|
-
const response = await exec('configureWithApiKey', [config?.toJson()])
|
|
57
|
+
const response = await exec('configureWithApiKey', [serializeInterface(config, ApiKeyConnectionConfig)])
|
|
61
58
|
return completionFromResponse(response)
|
|
62
59
|
}
|
|
63
60
|
|
|
64
61
|
async prepareWorkflow(config) {
|
|
65
|
-
|
|
66
|
-
const response = await exec('prepareWorkflow', [config?.toJson()])
|
|
62
|
+
const response = await exec('prepareWorkflow', [serializeInterface(config, PrepareWorkflowConfig)])
|
|
67
63
|
return completionFromResponse(response, json => Workflow.fromJson(json))
|
|
68
64
|
}
|
|
69
65
|
|
|
70
66
|
async startWorkflow(config) {
|
|
71
|
-
|
|
72
|
-
const response = await exec('startWorkflow', [config?.toJson()])
|
|
67
|
+
const response = await exec('startWorkflow', [serializeInterface(config, StartWorkflowConfig)])
|
|
73
68
|
return completionFromResponse(response, json => WorkflowResult.fromJson(json))
|
|
74
69
|
}
|
|
75
70
|
|
|
@@ -86,14 +81,12 @@ export class IDV {
|
|
|
86
81
|
}
|
|
87
82
|
|
|
88
83
|
async startSession(config) {
|
|
89
|
-
|
|
90
|
-
const response = await exec('startSession', [config.toJson()])
|
|
84
|
+
const response = await exec('startSession', [serializeInterface(config, StartSessionConfig)])
|
|
91
85
|
return completionFromResponse(response)
|
|
92
86
|
}
|
|
93
87
|
|
|
94
88
|
async sendData(config) {
|
|
95
|
-
|
|
96
|
-
const response = await exec('sendData', [config.toJson()])
|
|
89
|
+
const response = await exec('sendData', [serializeInterface(config, SendDataConfig)])
|
|
97
90
|
return completionFromResponse(response)
|
|
98
91
|
}
|
|
99
92
|
}
|
|
@@ -110,9 +103,3 @@ function completionFromResponse(response, transform) {
|
|
|
110
103
|
if (transform != null && success != null) success = transform(success)
|
|
111
104
|
return [success, error]
|
|
112
105
|
}
|
|
113
|
-
|
|
114
|
-
function ensureInstance(value, ctor) {
|
|
115
|
-
if (value == null) return null
|
|
116
|
-
if (value instanceof ctor) return value
|
|
117
|
-
return new ctor(value)
|
|
118
|
-
}
|
|
@@ -7,6 +7,12 @@ export async function exec(name, params) {
|
|
|
7
7
|
return RNIDV.exec(name, params)
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
+
export function serializeInterface(value, ctor) {
|
|
11
|
+
if (value == null) return null
|
|
12
|
+
if (value instanceof ctor) return value.toJson()
|
|
13
|
+
return (new ctor(value)).toJson()
|
|
14
|
+
}
|
|
15
|
+
|
|
10
16
|
function setEvent(id, completion, transform) {
|
|
11
17
|
eventManager.removeAllListeners(id)
|
|
12
18
|
if (transform === undefined) transform = func => func
|
package/www/cordova.js
CHANGED
|
@@ -289,6 +289,7 @@ class TokenConnectionConfig {
|
|
|
289
289
|
__webpack_require__.r(__webpack_exports__);
|
|
290
290
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
291
291
|
/* harmony export */ exec: () => (/* binding */ exec),
|
|
292
|
+
/* harmony export */ serializeInterface: () => (/* binding */ serializeInterface),
|
|
292
293
|
/* harmony export */ setDidContinueRemoteSessionCompletion: () => (/* binding */ setDidContinueRemoteSessionCompletion),
|
|
293
294
|
/* harmony export */ setDidEndSessionCompletion: () => (/* binding */ setDidEndSessionCompletion),
|
|
294
295
|
/* harmony export */ setDidStartRestoreSessionCompletion: () => (/* binding */ setDidStartRestoreSessionCompletion),
|
|
@@ -304,6 +305,12 @@ async function exec(name, params) {
|
|
|
304
305
|
return RNIDV.exec(name, params)
|
|
305
306
|
}
|
|
306
307
|
|
|
308
|
+
function serializeInterface(value, ctor) {
|
|
309
|
+
if (value == null) return null
|
|
310
|
+
if (value instanceof ctor) return value.toJson()
|
|
311
|
+
return (new ctor(value)).toJson()
|
|
312
|
+
}
|
|
313
|
+
|
|
307
314
|
function setEvent(id, completion, transform) {
|
|
308
315
|
eventManager.removeAllListeners(id)
|
|
309
316
|
if (transform === undefined) transform = func => func
|
|
@@ -483,12 +490,6 @@ class WorkflowStep {
|
|
|
483
490
|
/******/ if (cachedModule !== undefined) {
|
|
484
491
|
/******/ return cachedModule.exports;
|
|
485
492
|
/******/ }
|
|
486
|
-
/******/ // Check if module exists (development only)
|
|
487
|
-
/******/ if (__webpack_modules__[moduleId] === undefined) {
|
|
488
|
-
/******/ var e = new Error("Cannot find module '" + moduleId + "'");
|
|
489
|
-
/******/ e.code = 'MODULE_NOT_FOUND';
|
|
490
|
-
/******/ throw e;
|
|
491
|
-
/******/ }
|
|
492
493
|
/******/ // Create a new module (and put it into the cache)
|
|
493
494
|
/******/ var module = __webpack_module_cache__[moduleId] = {
|
|
494
495
|
/******/ // no module.id needed
|
|
@@ -497,6 +498,12 @@ class WorkflowStep {
|
|
|
497
498
|
/******/ };
|
|
498
499
|
/******/
|
|
499
500
|
/******/ // Execute the module function
|
|
501
|
+
/******/ if (!(moduleId in __webpack_modules__)) {
|
|
502
|
+
/******/ delete __webpack_module_cache__[moduleId];
|
|
503
|
+
/******/ var e = new Error("Cannot find module '" + moduleId + "'");
|
|
504
|
+
/******/ e.code = 'MODULE_NOT_FOUND';
|
|
505
|
+
/******/ throw e;
|
|
506
|
+
/******/ }
|
|
500
507
|
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
|
501
508
|
/******/
|
|
502
509
|
/******/ // Return the exports of the module
|
|
@@ -611,32 +618,27 @@ class IDV {
|
|
|
611
618
|
}
|
|
612
619
|
|
|
613
620
|
async configureWithToken(config) {
|
|
614
|
-
|
|
615
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithToken', [config?.toJson()])
|
|
621
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithToken', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_token_connection_config__WEBPACK_IMPORTED_MODULE_1__.TokenConnectionConfig)])
|
|
616
622
|
return completionFromResponse(response, success => success?.map(item => String(item)))
|
|
617
623
|
}
|
|
618
624
|
|
|
619
625
|
async configureWithCredentials(config) {
|
|
620
|
-
|
|
621
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithCredentials', [config?.toJson()])
|
|
626
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithCredentials', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_credentials_connection_config__WEBPACK_IMPORTED_MODULE_2__.CredentialsConnectionConfig)])
|
|
622
627
|
return completionFromResponse(response)
|
|
623
628
|
}
|
|
624
629
|
|
|
625
630
|
async configureWithApiKey(config) {
|
|
626
|
-
|
|
627
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithApiKey', [config?.toJson()])
|
|
631
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('configureWithApiKey', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_api_key_connection_config__WEBPACK_IMPORTED_MODULE_3__.ApiKeyConnectionConfig)])
|
|
628
632
|
return completionFromResponse(response)
|
|
629
633
|
}
|
|
630
634
|
|
|
631
635
|
async prepareWorkflow(config) {
|
|
632
|
-
|
|
633
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('prepareWorkflow', [config?.toJson()])
|
|
636
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('prepareWorkflow', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_prepare_workflow_config__WEBPACK_IMPORTED_MODULE_4__.PrepareWorkflowConfig)])
|
|
634
637
|
return completionFromResponse(response, json => _model_workflow__WEBPACK_IMPORTED_MODULE_8__.Workflow.fromJson(json))
|
|
635
638
|
}
|
|
636
639
|
|
|
637
640
|
async startWorkflow(config) {
|
|
638
|
-
|
|
639
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('startWorkflow', [config?.toJson()])
|
|
641
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('startWorkflow', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_start_workflow_config__WEBPACK_IMPORTED_MODULE_5__.StartWorkflowConfig)])
|
|
640
642
|
return completionFromResponse(response, json => _model_workflow_result__WEBPACK_IMPORTED_MODULE_9__.WorkflowResult.fromJson(json))
|
|
641
643
|
}
|
|
642
644
|
|
|
@@ -653,14 +655,12 @@ class IDV {
|
|
|
653
655
|
}
|
|
654
656
|
|
|
655
657
|
async startSession(config) {
|
|
656
|
-
|
|
657
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('startSession', [config.toJson()])
|
|
658
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('startSession', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_start_session_config__WEBPACK_IMPORTED_MODULE_6__.StartSessionConfig)])
|
|
658
659
|
return completionFromResponse(response)
|
|
659
660
|
}
|
|
660
661
|
|
|
661
662
|
async sendData(config) {
|
|
662
|
-
|
|
663
|
-
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('sendData', [config.toJson()])
|
|
663
|
+
const response = await (0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.exec)('sendData', [(0,_internal_bridge__WEBPACK_IMPORTED_MODULE_0__.serializeInterface)(config, _config_send_data_config__WEBPACK_IMPORTED_MODULE_7__.SendDataConfig)])
|
|
664
664
|
return completionFromResponse(response)
|
|
665
665
|
}
|
|
666
666
|
}
|
|
@@ -678,12 +678,6 @@ function completionFromResponse(response, transform) {
|
|
|
678
678
|
return [success, error]
|
|
679
679
|
}
|
|
680
680
|
|
|
681
|
-
function ensureInstance(value, ctor) {
|
|
682
|
-
if (value == null) return null
|
|
683
|
-
if (value instanceof ctor) return value
|
|
684
|
-
return new ctor(value)
|
|
685
|
-
}
|
|
686
|
-
|
|
687
681
|
})();
|
|
688
682
|
|
|
689
683
|
var __webpack_export_target__ = exports;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { exec, setDidStartSessionCompletion, setDidEndSessionCompletion, setDidStartRestoreSessionCompletion, setDidContinueRemoteSessionCompletion } from './internal/bridge'
|
|
1
|
+
import { exec, serializeInterface, setDidStartSessionCompletion, setDidEndSessionCompletion, setDidStartRestoreSessionCompletion, setDidContinueRemoteSessionCompletion } from './internal/bridge'
|
|
2
2
|
|
|
3
3
|
import { TokenConnectionConfig } from './config/token_connection_config'
|
|
4
4
|
import { CredentialsConnectionConfig } from './config/credentials_connection_config'
|
|
@@ -44,32 +44,27 @@ export class IDV {
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
async configureWithToken(config) {
|
|
47
|
-
|
|
48
|
-
const response = await exec('configureWithToken', [config?.toJson()])
|
|
47
|
+
const response = await exec('configureWithToken', [serializeInterface(config, TokenConnectionConfig)])
|
|
49
48
|
return completionFromResponse(response, success => success?.map(item => String(item)))
|
|
50
49
|
}
|
|
51
50
|
|
|
52
51
|
async configureWithCredentials(config) {
|
|
53
|
-
|
|
54
|
-
const response = await exec('configureWithCredentials', [config?.toJson()])
|
|
52
|
+
const response = await exec('configureWithCredentials', [serializeInterface(config, CredentialsConnectionConfig)])
|
|
55
53
|
return completionFromResponse(response)
|
|
56
54
|
}
|
|
57
55
|
|
|
58
56
|
async configureWithApiKey(config) {
|
|
59
|
-
|
|
60
|
-
const response = await exec('configureWithApiKey', [config?.toJson()])
|
|
57
|
+
const response = await exec('configureWithApiKey', [serializeInterface(config, ApiKeyConnectionConfig)])
|
|
61
58
|
return completionFromResponse(response)
|
|
62
59
|
}
|
|
63
60
|
|
|
64
61
|
async prepareWorkflow(config) {
|
|
65
|
-
|
|
66
|
-
const response = await exec('prepareWorkflow', [config?.toJson()])
|
|
62
|
+
const response = await exec('prepareWorkflow', [serializeInterface(config, PrepareWorkflowConfig)])
|
|
67
63
|
return completionFromResponse(response, json => Workflow.fromJson(json))
|
|
68
64
|
}
|
|
69
65
|
|
|
70
66
|
async startWorkflow(config) {
|
|
71
|
-
|
|
72
|
-
const response = await exec('startWorkflow', [config?.toJson()])
|
|
67
|
+
const response = await exec('startWorkflow', [serializeInterface(config, StartWorkflowConfig)])
|
|
73
68
|
return completionFromResponse(response, json => WorkflowResult.fromJson(json))
|
|
74
69
|
}
|
|
75
70
|
|
|
@@ -86,14 +81,12 @@ export class IDV {
|
|
|
86
81
|
}
|
|
87
82
|
|
|
88
83
|
async startSession(config) {
|
|
89
|
-
|
|
90
|
-
const response = await exec('startSession', [config.toJson()])
|
|
84
|
+
const response = await exec('startSession', [serializeInterface(config, StartSessionConfig)])
|
|
91
85
|
return completionFromResponse(response)
|
|
92
86
|
}
|
|
93
87
|
|
|
94
88
|
async sendData(config) {
|
|
95
|
-
|
|
96
|
-
const response = await exec('sendData', [config.toJson()])
|
|
89
|
+
const response = await exec('sendData', [serializeInterface(config, SendDataConfig)])
|
|
97
90
|
return completionFromResponse(response)
|
|
98
91
|
}
|
|
99
92
|
}
|
|
@@ -110,9 +103,3 @@ function completionFromResponse(response, transform) {
|
|
|
110
103
|
if (transform != null && success != null) success = transform(success)
|
|
111
104
|
return [success, error]
|
|
112
105
|
}
|
|
113
|
-
|
|
114
|
-
function ensureInstance(value, ctor) {
|
|
115
|
-
if (value == null) return null
|
|
116
|
-
if (value instanceof ctor) return value
|
|
117
|
-
return new ctor(value)
|
|
118
|
-
}
|
|
@@ -7,6 +7,12 @@ export async function exec(name, params) {
|
|
|
7
7
|
return RNIDV.exec(name, params)
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
+
export function serializeInterface(value, ctor) {
|
|
11
|
+
if (value == null) return null
|
|
12
|
+
if (value instanceof ctor) return value.toJson()
|
|
13
|
+
return (new ctor(value)).toJson()
|
|
14
|
+
}
|
|
15
|
+
|
|
10
16
|
function setEvent(id, completion, transform) {
|
|
11
17
|
eventManager.removeAllListeners(id)
|
|
12
18
|
if (transform === undefined) transform = func => func
|