@regulaforensics/face-sdk 8.4.1399-rc → 8.4.1403-beta

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.
Files changed (75) hide show
  1. package/Package.swift +27 -0
  2. package/README.md +3 -0
  3. package/android/CDVFaceSDK.kt +4 -3
  4. package/android/build.gradle.kts +37 -0
  5. package/android/cordova.gradle.kts +17 -0
  6. package/android/src/main/kotlin/com/regula/plugin/{facesdk → face/sdk}/Config.kt +1 -1
  7. package/android/src/main/kotlin/com/regula/plugin/{facesdk → face/sdk}/Implementation.kt +2 -2
  8. package/android/src/main/kotlin/com/regula/plugin/{facesdk → face/sdk}/JSONConstructor.kt +4 -4
  9. package/android/src/main/kotlin/com/regula/plugin/{facesdk → face/sdk}/RNFaceApiModule.kt +1 -1
  10. package/android/src/main/kotlin/com/regula/plugin/{facesdk → face/sdk}/Utils.kt +2 -2
  11. package/app.plugin.js +10 -7
  12. package/examples/capacitor/README.md +2 -0
  13. package/examples/capacitor/android/app/build.gradle +1 -10
  14. package/examples/capacitor/android/app/src/main/AndroidManifest.xml +9 -0
  15. package/examples/capacitor/android/app/src/main/res/xml/file_paths.xml +5 -0
  16. package/examples/capacitor/android/build.gradle +12 -3
  17. package/examples/capacitor/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  18. package/examples/capacitor/android/gradle/wrapper/gradle-wrapper.properties +1 -1
  19. package/examples/capacitor/android/gradle.properties +4 -0
  20. package/examples/capacitor/android/gradlew +4 -7
  21. package/examples/capacitor/android/gradlew.bat +82 -94
  22. package/examples/capacitor/android/variables.gradle +13 -9
  23. package/examples/capacitor/capacitor.config.json +15 -0
  24. package/examples/capacitor/index.tsx +15 -23
  25. package/examples/capacitor/ios/App/App/AppDelegate.swift +5 -40
  26. package/examples/capacitor/ios/App/App/Info.plist +18 -2
  27. package/examples/capacitor/ios/App/App/SceneDelegate.swift +23 -0
  28. package/examples/capacitor/ios/App/App.xcodeproj/project.pbxproj +25 -85
  29. package/examples/capacitor/ios/App/CapApp-SPM/Sources/CapApp-SPM/CapApp-SPM.swift +1 -0
  30. package/examples/capacitor/package-lock.json +1075 -1935
  31. package/examples/capacitor/package.json +14 -19
  32. package/examples/capacitor/scripts/android.sh +5 -8
  33. package/examples/capacitor/scripts/ios.sh +5 -7
  34. package/examples/capacitor/scripts/setup.sh +2 -6
  35. package/examples/capacitor/src/main.css +5 -1
  36. package/examples/capacitor/vite.config.ts +0 -12
  37. package/examples/ionic/README.md +2 -0
  38. package/examples/ionic/config.xml +1 -1
  39. package/examples/ionic/index.tsx +8 -3
  40. package/examples/ionic/package-lock.json +6445 -12138
  41. package/examples/ionic/package.json +23 -27
  42. package/examples/ionic/scripts/android.sh +0 -2
  43. package/examples/ionic/scripts/ios.sh +0 -2
  44. package/examples/ionic/scripts/setup.sh +0 -2
  45. package/examples/ionic/tsconfig.json +0 -1
  46. package/examples/react_native/README.md +2 -0
  47. package/examples/react_native/app.config.ts +0 -1
  48. package/examples/react_native/package.json +19 -17
  49. package/examples/react_native/scripts/android.sh +8 -6
  50. package/examples/react_native/scripts/ios.sh +7 -5
  51. package/examples/react_native/scripts/setup.sh +7 -4
  52. package/ios/CDVFaceSDK.swift +6 -1
  53. package/ios/Decoder.swift +1 -1
  54. package/ios/Implementation.swift +4 -4
  55. package/ios/RNFaceSDK.swift +2 -2
  56. package/package.json +1 -1
  57. package/plugin.xml +11 -11
  58. package/react-native-face-sdk.podspec +14 -0
  59. package/test/package-lock.json +1 -1
  60. package/www/capacitor/internal/cordova.js +2 -2
  61. package/www/cordova.js +2 -2
  62. package/RNFaceSDK.podspec +0 -21
  63. package/android/build.gradle +0 -36
  64. package/android/cordova.gradle +0 -18
  65. package/examples/capacitor/android/app/capacitor.build.gradle +0 -21
  66. package/examples/capacitor/android/capacitor.settings.gradle +0 -12
  67. package/examples/capacitor/ionic.config.json +0 -7
  68. package/examples/capacitor/ios/App/App/Base.lproj/Main.storyboard +0 -19
  69. package/examples/capacitor/ios/App/App.xcworkspace/contents.xcworkspacedata +0 -10
  70. package/examples/capacitor/ios/App/App.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -8
  71. package/examples/capacitor/ios/App/Podfile +0 -31
  72. package/examples/capacitor/ios/App/Podfile.lock +0 -57
  73. package/examples/react_native/package-lock.json +0 -8908
  74. package/examples/react_native/vendor/image-size-metro-compat/index.cjs +0 -16
  75. package/examples/react_native/vendor/image-size-metro-compat/package.json +0 -8
@@ -7,40 +7,36 @@
7
7
  "postinstall": "patch-package"
8
8
  },
9
9
  "dependencies": {
10
- "@angular-devkit/build-angular": "^22.0.5",
11
- "@angular/cli": "^22.0.5",
12
- "@angular/common": "^22.0.5",
13
- "@angular/compiler-cli": "^22.0.5",
14
- "@angular/core": "^22.0.5",
15
- "@angular/forms": "^22.0.5",
16
- "@angular/platform-browser-dynamic": "^22.0.5",
17
- "@angular/router": "^22.0.5",
18
- "@ionic/angular": "^8.8.13",
19
- "@ionic/cordova-builders": "^12.3.0",
20
- "@awesome-cordova-plugins/camera": "^9.2.0",
21
- "@awesome-cordova-plugins/dialogs": "^9.2.0",
22
- "@awesome-cordova-plugins/file": "^9.2.0",
23
- "@regulaforensics/face-sdk": "8.4.1399-rc",
24
- "@regulaforensics/face-core-basic": "8.4.848-rc",
25
- "cordova-android": "^15.0.0",
10
+ "@angular-devkit/build-angular": "^22.1.8",
11
+ "@angular/cli": "^22.1.8",
12
+ "@angular/common": "^22.1.7",
13
+ "@angular/compiler-cli": "^22.1.7",
14
+ "@angular/core": "^22.1.7",
15
+ "@angular/forms": "^22.1.7",
16
+ "@angular/platform-browser-dynamic": "^22.1.7",
17
+ "@angular/router": "^22.1.7",
18
+ "@ionic/angular": "^9.0.4",
19
+ "@ionic/cordova-builders": "^13.0.0",
20
+ "@awesome-cordova-plugins/camera": "^9.6.0",
21
+ "@awesome-cordova-plugins/dialogs": "^9.6.0",
22
+ "@awesome-cordova-plugins/file": "^9.6.0",
23
+ "@regulaforensics/face-sdk": "8.4.1403-beta",
24
+ "@regulaforensics/face-core-basic": "8.4.854-beta",
25
+ "cordova-android": "^15.1.0",
26
26
  "cordova-ios": "^8.1.1",
27
27
  "cordova-plugin-camera": "^8.0.0",
28
28
  "cordova-plugin-dialogs": "^2.0.2",
29
29
  "cordova-plugin-file": "^8.1.3",
30
30
  "cordova-plugin-ionic-webview": "^5.0.1",
31
- "patch-package": "^8.0.1"
31
+ "patch-package": "^8.0.1",
32
+ "@angular/compiler": "^22.1.7",
33
+ "@angular/platform-browser": "^22.1.7",
34
+ "zone.js": "~0.16.3",
35
+ "typescript": "~6.0.3"
32
36
  },
33
37
  "overrides": {
34
- "@babel/core": "^7.29.0",
35
- "ajv": "^8.18.0",
36
- "esbuild": "^0.28.1",
37
- "http-proxy-middleware": "^3.0.7",
38
- "picomatch": "^4.0.4",
39
- "serialize-javascript": "^7.0.4",
40
- "uuid": "^14.0.0",
41
- "postcss": "^8.5.22",
42
- "image-size": "npm:image-size-next@2.1.1",
43
- "webpack-dev-server": "^5.2.4"
38
+ "serialize-javascript": "^7.1.1",
39
+ "uuid": "^11.1.1"
44
40
  },
45
41
  "cordova": {
46
42
  "plugins": {
@@ -7,5 +7,3 @@ if [[ " $* " == *" --open "* ]] || [[ " $* " == *" -o "* ]]; then
7
7
  else
8
8
  ionic cordova run android
9
9
  fi
10
-
11
- exit 0
@@ -7,5 +7,3 @@ if [[ " $* " == *" --open "* ]] || [[ " $* " == *" -o "* ]]; then
7
7
  else
8
8
  ionic cordova run ios
9
9
  fi
10
-
11
- exit 0
@@ -6,5 +6,3 @@ ionic cordova prepare || {
6
6
  pod repo update
7
7
  ionic cordova prepare
8
8
  }
9
-
10
- exit 0
@@ -9,6 +9,5 @@
9
9
  "experimentalDecorators": true,
10
10
  "target": "es2022",
11
11
  "jsx": "react-jsx",
12
- "skipLibCheck": true, // Temp fix for https://github.com/ionic-team/ionic-framework/issues/30650
13
12
  }
14
13
  }
@@ -1,5 +1,7 @@
1
1
  # Regula Face SDK React Native demo application
2
2
 
3
+ Requires Node.js 22+, Xcode 26+, CocoaPods, Android Studio with JDK 17 and Android SDK 37.
4
+
3
5
  ## How to build demo application
4
6
  1. Download or the clone current repository using the command `git clone https://github.com/regulaforensics/npm-face-sdk.git`.
5
7
 
@@ -16,7 +16,6 @@ export default ({ config }: ConfigContext): ExpoConfig => ({
16
16
  },
17
17
  android: {
18
18
  package: 'com.regula.example.face.react',
19
- edgeToEdgeEnabled: true
20
19
  },
21
20
  plugins: [
22
21
  '@regulaforensics/face-sdk',
@@ -5,29 +5,31 @@
5
5
  "setup": "scripts/setup.sh",
6
6
  "ios": "scripts/ios.sh",
7
7
  "android": "scripts/android.sh",
8
- "start": "expo start"
8
+ "start": "expo start --port \"$npm_package_config_metroPort\""
9
9
  },
10
10
  "dependencies": {
11
- "@regulaforensics/face-sdk": "8.4.1399-rc",
12
- "@regulaforensics/face-core-basic": "8.4.848-rc",
13
- "react-native": "^0.81.4",
11
+ "@regulaforensics/face-sdk": "8.4.1403-beta",
12
+ "@regulaforensics/face-core-basic": "8.4.854-beta",
13
+ "react-native": "0.88.0-rc.0",
14
14
  "react-native-fs": "^2.20.0",
15
15
  "react-native-image-picker": "^8.2.1",
16
- "react-native-webview": "^13.16.0",
17
- "@react-native/metro-config": "^0.81.1",
18
- "react": "^19.1.1",
19
- "@types/react": "^19.1.13",
20
- "expo": "^54.0.7",
21
- "expo-dev-client": "^6.0.12",
16
+ "react-native-webview": "^14.0.1",
17
+ "react": "19.2.3",
18
+ "@types/react": "19.2.18",
19
+ "expo": "58.0.0-preview.3",
20
+ "expo-dev-client": "58.0.3",
22
21
  "expo-custom-assets": "^1.5.0",
23
- "expo-build-properties": "^1.0.8",
24
- "typescript": "5.9.2",
25
- "image-size": "file:vendor/image-size-metro-compat"
22
+ "expo-build-properties": "58.0.3",
23
+ "typescript": "^7.0.2",
24
+ "@expo/config-plugins": "58.0.0"
26
25
  },
27
26
  "overrides": {
28
- "postcss": "^8.5.10",
29
27
  "uuid": "^14.0.0",
30
- "image-size": "$image-size",
31
- "js-yaml": "^4.1.1"
28
+ "expo-custom-assets": {
29
+ "expo": "$expo"
30
+ }
31
+ },
32
+ "config": {
33
+ "metroPort": 8082
32
34
  }
33
- }
35
+ }
@@ -1,13 +1,15 @@
1
1
  #!/usr/bin/env bash
2
2
  set -e
3
3
 
4
- adb reverse tcp:8081 tcp:8081 >/dev/null || :
4
+ adb reverse tcp:${npm_package_config_metroPort} tcp:${npm_package_config_metroPort} >/dev/null || :
5
5
  if [[ " $* " == *" --open "* ]] || [[ " $* " == *" -o "* ]]; then
6
6
  open -a 'Android Studio' android
7
- # check if metro is already running
8
- [[ -z $(pgrep -f 'expo start') ]] && npm start
7
+ # Check if Metro is running at app's port.
8
+ if [[ "$(curl --silent --max-time 2 http://localhost:${npm_package_config_metroPort}/status)" != "packager-status:running" ]]; then
9
+ npm start
10
+ else
11
+ echo "Metro is already running on port ${npm_package_config_metroPort}."
12
+ fi
9
13
  else
10
- expo run:android --device
14
+ expo run:android --device --port ${npm_package_config_metroPort}
11
15
  fi
12
-
13
- exit 0
@@ -3,10 +3,12 @@ set -e
3
3
 
4
4
  if [[ " $* " == *" --open "* ]] || [[ " $* " == *" -o "* ]]; then
5
5
  open ios/Face.xcworkspace
6
- # check if metro is already running
7
- [[ -z $(pgrep -f 'expo start') ]] && npm start
6
+ # Check if Metro is running at app's port.
7
+ if [[ "$(curl --silent --max-time 2 http://localhost:${npm_package_config_metroPort}/status)" != "packager-status:running" ]]; then
8
+ npm start
9
+ else
10
+ echo "Metro is already running on port ${npm_package_config_metroPort}."
11
+ fi
8
12
  else
9
- npx expo run:ios --device
13
+ npx expo run:ios --device --port ${npm_package_config_metroPort}
10
14
  fi
11
-
12
- exit 0
@@ -1,12 +1,15 @@
1
1
  #!/usr/bin/env bash
2
2
  set -e
3
3
 
4
+ # Kill Metro instance at app's port.
5
+ lsof -tiTCP:${npm_package_config_metroPort} -sTCP:LISTEN | xargs kill 2>/dev/null || true
6
+
4
7
  npm install
5
- expo prebuild
8
+ rm -rf node_modules/expo/node_modules/expo-modules-core/android/.cxx # Temp fix for expo@58.0.0-preview.3
9
+ npx expo prebuild --no-install
10
+ (cd ios && (pod install || pod update))
6
11
 
7
- # add aaptOptions for offline match
12
+ # Add aaptOptions for offline match
8
13
  if ! grep -q faceSdkResource android/app/build.gradle && grep -q face-core-match package.json; then
9
14
  sed -i '' "s/androidResources/aaptOptions {\n\t\tnoCompress 'Regula\/faceSdkResource.dat'\n\t}\n\tandroidResources/" android/app/build.gradle
10
15
  fi
11
-
12
- exit 0
@@ -1,3 +1,8 @@
1
+ #if canImport(Cordova)
2
+ import Cordova
3
+ #endif
4
+ import UIKit
5
+
1
6
  @objc(CDVFaceSDK)
2
7
  class CDVFaceSDK: CDVPlugin {
3
8
  @objc(exec:)
@@ -33,7 +38,7 @@ func sendEvent(_ event: String, _ data: Any? = "") {
33
38
  this!.commandDelegate.send(result!, callbackId: callbackId)
34
39
  }
35
40
 
36
- func runAsync(_ action: @escaping (UIViewController) -> Void) {
41
+ func withPresenter(_ action: @escaping (UIViewController) -> Void) {
37
42
  DispatchQueue.main.async {
38
43
  let windows = UIApplication.shared.connectedScenes.compactMap { $0 as? UIWindowScene }.filter { $0.activationState == .foregroundActive || $0.activationState == .foregroundInactive }.flatMap { $0.windows }
39
44
  let candidates = windows.filter { $0.isKeyWindow } + windows.filter { !$0.isKeyWindow && !$0.isHidden && $0.alpha > 0 && $0.windowLevel == .normal }
package/ios/Decoder.swift CHANGED
@@ -1002,7 +1002,7 @@ public extension SearchPersonFilter {
1002
1002
  let it = it as! [String: Any]
1003
1003
  let result = Self()
1004
1004
  result.groups = it["groups"] as! [String]
1005
- result.threshold = CGFloat(it["threshold"] as! Float)
1005
+ result.threshold = CGFloat(truncating: it["threshold"] as! NSNumber)
1006
1006
  result.limit = it["limit"] as! Int
1007
1007
  result.setValue(it["fieldName"] as Any?, forKey: "fieldName")
1008
1008
  result.setValue(it["fieldValues"] as Any?, forKey: "fieldValues")
@@ -39,7 +39,7 @@ func methodCall(_ method: String, _ callback: @escaping Callback) {
39
39
  })
40
40
  case("deinitialize"): face.deinitialize()
41
41
  case("startFaceCapture"): let config = FaceCaptureConfiguration.decode(argsNullable(0))
42
- runAsync { presenter in
42
+ withPresenter { presenter in
43
43
  face.presentFaceCaptureViewController(
44
44
  from: presenter,
45
45
  animated: true,
@@ -48,7 +48,7 @@ func methodCall(_ method: String, _ callback: @escaping Callback) {
48
48
  }
49
49
  case("stopFaceCapture"): face.stopFaceCaptureViewController()
50
50
  case("startLiveness"): let config = LivenessConfiguration.decode(argsNullable(0))
51
- runAsync { presenter in
51
+ withPresenter { presenter in
52
52
  face.startLiveness(
53
53
  from: presenter,
54
54
  animated: true,
@@ -56,7 +56,7 @@ func methodCall(_ method: String, _ callback: @escaping Callback) {
56
56
  onLiveness: { callback($0.encode()) })
57
57
  }
58
58
  case("startEnrollment"): let config = EnrollmentConfiguration.decode2(args(0))
59
- runAsync { presenter in
59
+ withPresenter { presenter in
60
60
  face.startEnrollment(
61
61
  from: presenter,
62
62
  animated: true,
@@ -67,7 +67,7 @@ func methodCall(_ method: String, _ callback: @escaping Callback) {
67
67
  ]) })
68
68
  }
69
69
  case("startVerification"): let config = VerificationConfiguration.decode2(args(0))
70
- runAsync { presenter in
70
+ withPresenter { presenter in
71
71
  face.startVerification(
72
72
  from: presenter,
73
73
  animated: true,
@@ -34,10 +34,10 @@ private var this: RNFaceSDK?
34
34
 
35
35
  func sendEvent(_ event: String, _ data: Any? = nil) {
36
36
  guard let plugin = this, hasListeners else { return }
37
- runAsync { _ in plugin.sendEvent(withName: event, body: data.toSendable()) }
37
+ DispatchQueue.main.async { plugin.sendEvent(withName: event, body: data.toSendable()) }
38
38
  }
39
39
 
40
- func runAsync(_ action: @escaping (UIViewController) -> Void) {
40
+ func withPresenter(_ action: @escaping (UIViewController) -> Void) {
41
41
  DispatchQueue.main.async {
42
42
  if let presenter = RCTPresentedViewController() {
43
43
  action(presenter)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@regulaforensics/face-sdk",
3
- "version": "8.4.1399-rc",
3
+ "version": "8.4.1403-beta",
4
4
  "description": "This is an npm module for Regula Face SDK. It allows you to easily compaire faces using your phone's camera.",
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/face-sdk" version="8.4.1399-rc" xmlns="http://apache.org/cordova/ns/plugins/1.0">
2
+ <plugin id="@regulaforensics/face-sdk" version="8.4.1403-beta" xmlns="http://apache.org/cordova/ns/plugins/1.0">
3
3
  <name>FaceSDK</name>
4
4
  <description>Cordova plugin for Regula Face SDK</description>
5
5
  <license>commercial</license>
@@ -9,12 +9,12 @@
9
9
  <clobbers target="FaceSDKPlugin" />
10
10
  </js-module>
11
11
 
12
- <platform name="ios">
12
+ <platform name="ios" package="swift">
13
13
  <config-file target="config.xml" parent="/widget">
14
14
  <feature name="FaceSDK">
15
15
  <param name="ios-package" value="CDVFaceSDK" />
16
16
  </feature>
17
- <preference name="deployment-target" value="13.0" />
17
+ <preference name="deployment-target" value="15.0" />
18
18
  <preference name="SwiftVersion" value="5" />
19
19
  </config-file>
20
20
  <source-file src="ios/CDVFaceSDK.swift" />
@@ -27,7 +27,7 @@
27
27
  <source url="https://github.com/regulaforensics/podspecs.git" />
28
28
  </config>
29
29
  <pods>
30
- <pod name="FaceSDKStage" spec="8.4.4980" />
30
+ <pod name="FaceSDKStage" spec="8.4.4983" nospm="true" />
31
31
  </pods>
32
32
  </podspec>
33
33
  </platform>
@@ -35,14 +35,14 @@
35
35
  <platform name="android">
36
36
  <config-file parent="/*" target="res/xml/config.xml">
37
37
  <feature name="FaceSDK">
38
- <param name="android-package" value="com.regula.plugin.facesdk.CDVFaceSDK" />
38
+ <param name="android-package" value="com.regula.plugin.face.sdk.CDVFaceSDK" />
39
39
  </feature>
40
40
  </config-file>
41
- <framework src="android/cordova.gradle" custom="true" type="gradleReference" />
42
- <source-file src="android/CDVFaceSDK.kt" target-dir="kotlin/com.regula.plugin.facesdk" />
43
- <source-file src="android/src/main/kotlin/com/regula/plugin/facesdk/Implementation.kt" target-dir="kotlin/com.regula.plugin.facesdk" />
44
- <source-file src="android/src/main/kotlin/com/regula/plugin/facesdk/JSONConstructor.kt" target-dir="kotlin/com.regula.plugin.facesdk" />
45
- <source-file src="android/src/main/kotlin/com/regula/plugin/facesdk/Config.kt" target-dir="kotlin/com.regula.plugin.facesdk" />
46
- <source-file src="android/src/main/kotlin/com/regula/plugin/facesdk/Utils.kt" target-dir="kotlin/com.regula.plugin.facesdk" />
41
+ <framework src="android/cordova.gradle.kts" custom="true" type="gradleReference" />
42
+ <source-file src="android/CDVFaceSDK.kt" target-dir="kotlin/com.regula.plugin.face.sdk" />
43
+ <source-file src="android/src/main/kotlin/com/regula/plugin/face/sdk/Implementation.kt" target-dir="kotlin/com.regula.plugin.face.sdk" />
44
+ <source-file src="android/src/main/kotlin/com/regula/plugin/face/sdk/JSONConstructor.kt" target-dir="kotlin/com.regula.plugin.face.sdk" />
45
+ <source-file src="android/src/main/kotlin/com/regula/plugin/face/sdk/Config.kt" target-dir="kotlin/com.regula.plugin.face.sdk" />
46
+ <source-file src="android/src/main/kotlin/com/regula/plugin/face/sdk/Utils.kt" target-dir="kotlin/com.regula.plugin.face.sdk" />
47
47
  </platform>
48
48
  </plugin>
@@ -0,0 +1,14 @@
1
+ Pod::Spec.new do |s|
2
+ s.name = 'react-native-face-sdk'
3
+ s.version = '8.4.1403-beta'
4
+ s.summary = 'Regula React Native plugin.'
5
+ s.license = 'commercial'
6
+ s.authors = { 'RegulaForensics' => 'support@regulaforensics.com' }
7
+ s.homepage = 'https://regulaforensics.com'
8
+ s.source = { :path => '.' }
9
+ s.ios.deployment_target = '15.0'
10
+ s.source_files = [ 'ios/*.swift', 'ios/RN*.m' ]
11
+ s.exclude_files = [ 'ios/CDVFaceSDK.swift' ]
12
+ s.dependency 'FaceSDKStage', '8.4.4983'
13
+ s.dependency 'React'
14
+ end
@@ -13,7 +13,7 @@
13
13
  },
14
14
  "..": {
15
15
  "name": "@regulaforensics/face-sdk",
16
- "version": "8.4.1399-rc",
16
+ "version": "8.4.1403-beta",
17
17
  "dev": true,
18
18
  "license": "commercial",
19
19
  "dependencies": {
@@ -1,8 +1,8 @@
1
- var _exec = (completion, options) => cordova.exec(completion, null, "FaceSDK", "exec", options)
1
+ var _exec = (completion, params, errorCallback = null) => cordova.exec(completion, errorCallback, "FaceSDK", "exec", params)
2
2
 
3
3
  export const NativeModules = {
4
4
  RNFaceSDK: {
5
- exec: async (name, options) => new Promise((resolve, _) => _exec(data => resolve(data), [name, ...options]))
5
+ exec: async (name, params) => new Promise((resolve, reject) => _exec(resolve, [name, ...params], error => reject(new Error(error))))
6
6
  }
7
7
  }
8
8
 
package/www/cordova.js CHANGED
@@ -2985,11 +2985,11 @@ __webpack_require__.r(__webpack_exports__);
2985
2985
  /* harmony export */ NativeEventEmitter: () => (/* binding */ NativeEventEmitter),
2986
2986
  /* harmony export */ NativeModules: () => (/* binding */ NativeModules)
2987
2987
  /* harmony export */ });
2988
- var _exec = (completion, options) => cordova.exec(completion, null, "FaceSDK", "exec", options)
2988
+ var _exec = (completion, params, errorCallback = null) => cordova.exec(completion, errorCallback, "FaceSDK", "exec", params)
2989
2989
 
2990
2990
  const NativeModules = {
2991
2991
  RNFaceSDK: {
2992
- exec: async (name, options) => new Promise((resolve, _) => _exec(data => resolve(data), [name, ...options]))
2992
+ exec: async (name, params) => new Promise((resolve, reject) => _exec(resolve, [name, ...params], error => reject(new Error(error))))
2993
2993
  }
2994
2994
  }
2995
2995
 
package/RNFaceSDK.podspec DELETED
@@ -1,21 +0,0 @@
1
- require 'json'
2
-
3
- package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
4
- source = File.join(__dir__, 'ios')
5
-
6
- Pod::Spec.new do |s|
7
- s.name = 'RNFaceSDK'
8
- s.version = '8.4.1399-rc'
9
- s.summary = package['description']
10
- s.license = package['license']
11
-
12
- s.authors = { 'RegulaForensics' => 'support@regulaforensics.com' }
13
- s.homepage = 'https://regulaforensics.com'
14
-
15
- s.source = { http: "file:#{source}" }
16
- s.ios.deployment_target = '13.0'
17
- s.source_files = [ 'ios/**/*.swift', 'ios/**/RN*.m' ]
18
- s.exclude_files = [ 'ios/CDVFaceSDK.swift' ]
19
- s.dependency 'FaceSDKStage', '8.4.4980'
20
- s.dependency 'React'
21
- end
@@ -1,36 +0,0 @@
1
- apply plugin: 'com.android.library'
2
- apply plugin: 'kotlin-android'
3
-
4
- android {
5
- // Conditional for compatibility with AGP <4.2.
6
- if (project.android.hasProperty("namespace")) {
7
- namespace 'com.regula.plugin.facesdk'
8
- }
9
-
10
- compileSdk 36
11
-
12
- defaultConfig {
13
- minSdkVersion 24
14
- targetSdk 36
15
- versionCode 1
16
- versionName "1.0"
17
- }
18
- }
19
-
20
- rootProject.allprojects {
21
- repositories {
22
- maven {
23
- url "https://maven.regulaforensics.com/RegulaDocumentReader/Stage"
24
- }
25
- }
26
- }
27
-
28
- dependencies {
29
- //noinspection GradleDynamicVersion
30
- implementation 'com.facebook.react:react-native:+'
31
- //noinspection GradleDependency
32
- implementation('com.regula.face:api:8.4.5406'){
33
- transitive = true
34
- }
35
- }
36
-
@@ -1,18 +0,0 @@
1
- android {
2
- aaptOptions {
3
- noCompress "Regula/faceSdkResource.dat"
4
- }
5
- }
6
-
7
- repositories {
8
- maven {
9
- url "https://maven.regulaforensics.com/RegulaDocumentReader/Stage"
10
- }
11
- }
12
-
13
- dependencies {
14
- //noinspection GradleDependency
15
- implementation('com.regula.face:api:8.4.5406'){
16
- transitive = true
17
- }
18
- }
@@ -1,21 +0,0 @@
1
- // DO NOT EDIT THIS FILE! IT IS GENERATED EACH TIME "capacitor update" IS RUN
2
-
3
- android {
4
- compileOptions {
5
- sourceCompatibility JavaVersion.VERSION_21
6
- targetCompatibility JavaVersion.VERSION_21
7
- }
8
- }
9
-
10
- apply from: "../capacitor-cordova-android-plugins/cordova.variables.gradle"
11
- dependencies {
12
- implementation project(':capacitor-app')
13
- implementation project(':capacitor-dialog')
14
- implementation project(':capacitor-status-bar')
15
- implementation "androidx.webkit:webkit:1.4.0"
16
- implementation "androidx.core:core:1.6.+"
17
- }
18
-
19
- if (hasProperty('postBuildExtras')) {
20
- postBuildExtras()
21
- }
@@ -1,12 +0,0 @@
1
- // DO NOT EDIT THIS FILE! IT IS GENERATED EACH TIME "capacitor update" IS RUN
2
- include ':capacitor-android'
3
- project(':capacitor-android').projectDir = new File('../node_modules/@capacitor/android/capacitor')
4
-
5
- include ':capacitor-app'
6
- project(':capacitor-app').projectDir = new File('../node_modules/@capacitor/app/android')
7
-
8
- include ':capacitor-dialog'
9
- project(':capacitor-dialog').projectDir = new File('../node_modules/@capacitor/dialog/android')
10
-
11
- include ':capacitor-status-bar'
12
- project(':capacitor-status-bar').projectDir = new File('../node_modules/@capacitor/status-bar/android')
@@ -1,7 +0,0 @@
1
- {
2
- "name": "FaceSDK",
3
- "integrations": {
4
- "capacitor": {}
5
- },
6
- "type": "react-vite"
7
- }
@@ -1,19 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14111" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
3
- <device id="retina4_7" orientation="portrait">
4
- <adaptation id="fullscreen"/>
5
- </device>
6
- <dependencies>
7
- <deployment identifier="iOS"/>
8
- <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
9
- </dependencies>
10
- <scenes>
11
- <!--Bridge View Controller-->
12
- <scene sceneID="tne-QT-ifu">
13
- <objects>
14
- <viewController id="BYZ-38-t0r" customClass="CAPBridgeViewController" customModule="Capacitor" sceneMemberID="viewController"/>
15
- <placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
16
- </objects>
17
- </scene>
18
- </scenes>
19
- </document>
@@ -1,10 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <Workspace
3
- version = "1.0">
4
- <FileRef
5
- location = "group:App.xcodeproj">
6
- </FileRef>
7
- <FileRef
8
- location = "group:Pods/Pods.xcodeproj">
9
- </FileRef>
10
- </Workspace>
@@ -1,8 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
- <plist version="1.0">
4
- <dict>
5
- <key>IDEDidComputeMac32BitWarning</key>
6
- <true/>
7
- </dict>
8
- </plist>
@@ -1,31 +0,0 @@
1
- source 'https://github.com/CocoaPods/Specs.git'
2
- source 'https://github.com/regulaforensics/podspecs.git'
3
-
4
- require_relative '../../node_modules/@capacitor/ios/scripts/pods_helpers'
5
-
6
- platform :ios, '15.0'
7
- use_frameworks!
8
-
9
- # workaround to avoid Xcode caching of Pods that requires
10
- # Product -> Clean Build Folder after new Cordova plugins installed
11
- # Requires CocoaPods 1.6 or newer
12
- install! 'cocoapods', :disable_input_output_paths => true
13
-
14
- def capacitor_pods
15
- pod 'Capacitor', :path => '../../node_modules/@capacitor/ios'
16
- pod 'CapacitorCordova', :path => '../../node_modules/@capacitor/ios'
17
- pod 'CapacitorApp', :path => '../../node_modules/@capacitor/app'
18
- pod 'CapacitorDialog', :path => '../../node_modules/@capacitor/dialog'
19
- pod 'CapacitorStatusBar', :path => '../../node_modules/@capacitor/status-bar'
20
- pod 'CordovaPlugins', :path => '../capacitor-cordova-ios-plugins'
21
- pod 'CordovaPluginsResources', :path => '../capacitor-cordova-ios-plugins'
22
- end
23
-
24
- target 'App' do
25
- capacitor_pods
26
- # Add your Pods here
27
- end
28
-
29
- post_install do |installer|
30
- assertDeploymentTarget(installer)
31
- end