assentify-sdk-react-native 1.0.0-Beta.21 → 1.0.0-Beta.23

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 (60) hide show
  1. package/Package.swift +172 -0
  2. package/README.md +11 -32
  3. package/android/build.gradle +1 -6
  4. package/android/src/main/java/com/assentifysdk/AssentifySdkModule.kt +8 -5
  5. package/android/src/main/java/com/assentifysdk/FlowActivity.kt +5 -5
  6. package/ios/AssentifySdkBaseModule.swift +1 -0
  7. package/ios/NativeAssentifySdk.mm +2 -1
  8. package/ios/NativeAssentifySdk.swift +18 -13
  9. package/ios/UIComponents/RNPassportScanner.swift +4 -3
  10. package/ios/View/AssentifySdkEventEmitting.swift +10 -0
  11. package/ios/View/DataDecoder.swift +16 -16
  12. package/ios/View/FaceMatchController.swift +51 -51
  13. package/ios/View/IDCardController.swift +37 -37
  14. package/ios/View/OtherController.swift +33 -33
  15. package/ios/View/PassportController.swift +36 -36
  16. package/ios/View/QrController.swift +10 -10
  17. package/ios/View/UI.swift +77 -26
  18. package/lib/commonjs/AssentifyProvider.js +3 -0
  19. package/lib/commonjs/AssentifyProvider.js.map +1 -1
  20. package/lib/commonjs/AssentifyWrapper.js +4 -4
  21. package/lib/commonjs/AssentifyWrapper.js.map +1 -1
  22. package/lib/commonjs/Language.js +5 -1
  23. package/lib/commonjs/Language.js.map +1 -1
  24. package/lib/module/AssentifyProvider.js +4 -0
  25. package/lib/module/AssentifyProvider.js.map +1 -1
  26. package/lib/module/AssentifyWrapper.js +4 -4
  27. package/lib/module/AssentifyWrapper.js.map +1 -1
  28. package/lib/module/Language.js +4 -0
  29. package/lib/module/Language.js.map +1 -1
  30. package/lib/typescript/babel.config.d.ts +0 -1
  31. package/lib/typescript/example/babel.config.d.ts +7 -4
  32. package/lib/typescript/example/babel.config.d.ts.map +1 -1
  33. package/lib/typescript/example/metro.config.d.ts +9 -1
  34. package/lib/typescript/example/metro.config.d.ts.map +1 -1
  35. package/lib/typescript/example/react-native.config.d.ts +5 -2
  36. package/lib/typescript/example/react-native.config.d.ts.map +1 -1
  37. package/lib/typescript/example/src/App.d.ts.map +1 -1
  38. package/lib/typescript/example/src/Home.d.ts.map +1 -1
  39. package/lib/typescript/lib/commonjs/AssentifyProvider.d.ts.map +1 -1
  40. package/lib/typescript/lib/commonjs/AssentifyWrapper.d.ts +2 -2
  41. package/lib/typescript/lib/commonjs/AssentifyWrapper.d.ts.map +1 -1
  42. package/lib/typescript/lib/commonjs/Language.d.ts +6 -0
  43. package/lib/typescript/lib/module/AssentifyProvider.d.ts.map +1 -1
  44. package/lib/typescript/lib/module/AssentifyWrapper.d.ts +2 -2
  45. package/lib/typescript/lib/module/AssentifyWrapper.d.ts.map +1 -1
  46. package/lib/typescript/lib/module/Language.d.ts +6 -0
  47. package/lib/typescript/lib/module/index.d.ts +2 -2
  48. package/lib/typescript/src/AssentifyProvider.d.ts.map +1 -1
  49. package/lib/typescript/src/AssentifyWrapper.d.ts +3 -2
  50. package/lib/typescript/src/AssentifyWrapper.d.ts.map +1 -1
  51. package/lib/typescript/src/Language.d.ts +5 -0
  52. package/lib/typescript/src/Language.d.ts.map +1 -1
  53. package/lib/typescript/src/index.d.ts +2 -2
  54. package/package.json +9 -8
  55. package/src/AssentifyProvider.tsx +341 -305
  56. package/src/AssentifyWrapper.ts +7 -4
  57. package/src/Language.ts +7 -0
  58. package/assentify-sdk.podspec +0 -44
  59. package/lib/typescript/example/src/navigator.d.ts +0 -4
  60. package/lib/typescript/example/src/navigator.d.ts.map +0 -1
@@ -1,5 +1,6 @@
1
1
  import { NativeModules, Platform, Alert, Linking } from 'react-native';
2
2
  import { type LanguageCode } from './Language';
3
+ import { type FlowUiLanguageCode } from './Language';
3
4
  import { type TemplatesByCountry } from './types';
4
5
  import { type BackgroundTypeCode } from './BackgroundType';
5
6
  import { type FlowStepperTypeCode } from './FlowStepperType';
@@ -47,7 +48,8 @@ const AssentifyWrapper = {
47
48
  iOSMinRam?: number,
48
49
  minCPUCores ?: number,
49
50
  manualClickColor?: string,
50
- countDownNumbersColor?: string
51
+ countDownNumbersColor?: string,
52
+ flowUiLanguage ?: FlowUiLanguageCode
51
53
  ) {
52
54
  AssentifySdk.initialize(
53
55
  apiKey,
@@ -71,7 +73,8 @@ const AssentifyWrapper = {
71
73
  iOSMinRam??2,
72
74
  minCPUCores??6,
73
75
  manualClickColor ?? '#f5a103',
74
- countDownNumbersColor ?? '#f5a103'
76
+ countDownNumbersColor ?? '#f5a103',
77
+ flowUiLanguage ?? "en",
75
78
  );
76
79
  },
77
80
 
@@ -126,7 +129,7 @@ const AssentifyWrapper = {
126
129
  holdUntilClickColors?: number,
127
130
  backgroundType?: BackgroundTypeCode,
128
131
  clear?: boolean,
129
- language?: LanguageCode,
132
+ extractedDataLanguage?: LanguageCode,
130
133
  enableNfc?: boolean,
131
134
  enableQr?: boolean,
132
135
  blockLoaderCustomProperties?:Record<string, string>,
@@ -151,7 +154,7 @@ const AssentifyWrapper = {
151
154
  holdUntilClickColors ?? 0.4,
152
155
  backgroundType,
153
156
  clear,
154
- language ?? "NON",
157
+ extractedDataLanguage ?? "NON",
155
158
  enableNfc ?? false,
156
159
  enableQr ?? false,
157
160
  JSON.stringify(blockLoaderCustomProperties ?? {}),
package/src/Language.ts CHANGED
@@ -20,3 +20,10 @@ export const Language = {
20
20
  };
21
21
 
22
22
  export type LanguageCode = typeof Language[keyof typeof Language];
23
+
24
+ export const FlowUiLanguage = {
25
+ English: "en",
26
+ Arabic: "ar",
27
+ };
28
+
29
+ export type FlowUiLanguageCode = typeof FlowUiLanguage[keyof typeof FlowUiLanguage];
@@ -1,44 +0,0 @@
1
- require "json"
2
-
3
- package = JSON.parse(File.read(File.join(__dir__, "package.json")))
4
- folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
5
-
6
- Pod::Spec.new do |s|
7
- s.name = "assentify-sdk"
8
- s.version = package["version"]
9
- s.summary = package["description"]
10
- s.homepage = package["homepage"]
11
- s.license = package["license"]
12
- s.authors = package["author"]
13
-
14
- s.platforms = { :ios => min_ios_version_supported }
15
- s.source = { :git => "https://github.com/AssentifyLTD/Assentify.SDK.ReactNative.git", :tag => "#{s.version}" }
16
-
17
- s.swift_versions = ['5.0', '5.1', '5.2', '5.3', '5.4', '5.5']
18
-
19
- s.ios.deployment_target = '14.0'
20
- s.pod_target_xcconfig = {
21
- 'DEFINES_MODULE' => 'YES'
22
- }
23
-
24
-
25
- s.source_files = "ios/**/*.{h,m,mm,swift}"
26
-
27
- s.resources = ["ios/Resources/info_icon.png",
28
- "ios/Resources/zoom_in.png",
29
- "ios/Resources/zoom_out.png",
30
- "ios/Resources/expire.png",
31
- "ios/Resources/id_warning.png",
32
- "ios/Resources/warning.png",
33
- "ios/Resources/sending.png",
34
- "ios/Resources/id.gif",
35
- "ios/Resources/passport.gif",
36
- "ios/Resources/card.gif",
37
- ]
38
-
39
-
40
- s.dependency "React-Core"
41
- s.dependency "MLKitFaceDetection", '8.0.0'
42
- s.dependency "AssentifySdk", '1.0.0-Beta.18'
43
-
44
- end
@@ -1,4 +0,0 @@
1
- import React from 'react';
2
- declare function MyStack(): React.JSX.Element;
3
- export default MyStack;
4
- //# sourceMappingURL=navigator.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"navigator.d.ts","sourceRoot":"","sources":["../../../../example/src/navigator.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,iBAAS,OAAO,sBAMf;AAED,eAAe,OAAO,CAAC"}