react-native-okaycam 1.2.7 → 1.2.9

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/README.md CHANGED
@@ -1,13 +1,15 @@
1
1
  # react-native-okaycam
2
2
 
3
3
  ## Requirements
4
+
4
5
  ### Android
6
+
5
7
  - minSdkVersion >= 21
6
8
 
7
9
  ### iOS
8
- - iOS 9+
9
- - Swift 5
10
10
 
11
+ - iOS 12+
12
+ - Swift 5
11
13
 
12
14
  ## Getting started
13
15
 
@@ -33,7 +35,8 @@ post_install do |installer|
33
35
  end
34
36
  end
35
37
  ```
36
- 3. Run command `Pod install`
38
+
39
+ 3. Run command `pod install`
37
40
 
38
41
  4. Add camera permission
39
42
 
@@ -49,15 +52,16 @@ configurations { compile.exclude group: "junit", module: "junit" }
49
52
 
50
53
  #### iOS Issue
51
54
 
52
- > Undefined symbol: __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers
55
+ > Undefined symbol: \__swift_FORCE_LOAD_$\_swiftUniformTypeIdentifiers
53
56
 
54
- > Undefined symbol: __swift_FORCE_LOAD_$_swiftCoreMIDI
57
+ > Undefined symbol: \__swift_FORCE_LOAD_$\_swiftCoreMIDI
55
58
 
56
59
  If you encouter the errors above, you may create a new swift file called **Void.swift** without adding **bridging header**.
57
60
 
58
61
  <img src="images/image1.png">
59
62
 
60
63
  ## License
64
+
61
65
  Apply licenses for Android and iOS SDKs
62
66
 
63
67
  ```
@@ -68,45 +72,47 @@ const license = Platform.select({
68
72
  ```
69
73
 
70
74
  ## OkayCam Document
75
+
71
76
  ### Configuration
72
77
 
73
- -| Property name | Description |Default value
74
- |--|--|--|--|
75
- |-|torchBtnEnabled|to show torch button. If set to true, it will only be shown if onFlash from captureConfig is set to false.|false|
76
- |-|crop|crop the frame area|false|
77
- |-|width|width to resize the image|original width|
78
- |-|imageQuality|quality of image|1.0 (range from 0.0 to 1.0)|
79
- |frame|size|size of the frame (width and height)|90% of screen width and height is scaled proportionally according to card ratio|
80
- |frame|color|color of the frame|#ffffff|
81
- |frame|content|content of the frame (able to display svg file within the frame for guidance|null|
82
- |-|showOverlay|transparent black overlay|true|
83
- |topLabel|text|text of the top label|""(empty string)|
84
- |topLabel|color|color of the top label|#ffffff|
85
- |topLabel|size|text size of the top label|20|
86
- |bottomLabel|text|text of the bottom label|""(empty string)|
87
- |bottomLabel|color|color of the bottom label|#ffffff|
88
- |bottomLabel|size|text size of the bottom label|20|
89
- |timer|backgroundColor|background of the count down timer|#ffa500|
90
- |timer|textColor|text color of the count down timer|#ffffff|
91
- |confirmBtnConfig|backgroundColor|background color of the confirm button|#ffa500|
92
- |confirmBtnConfig|contentColor|content color of the confirm button|#ffffff|
93
- |retakeBtnConfig|backgroundColor|background color of the retake button|#ffa500|
94
- |retakeBtnConfig|contentColor|content color of the retake button|#ffffff|
95
- |-|captureBtnColor|color of the capture button|#ffffff|
96
- |-|firstPhotoConfig|config for the first capture|delay:0s,onFlash:false,outputPath: null|
97
- |-|secondPhotoConfig|config for the second capture|null|
98
- |preview |title|title on preview screen|""(empty string)|
99
- |preview |refImg|ref image on preview screen|null|
100
- |preview |instruction1|instruction on preview screen|""(empty string)|
101
- |preview|instruction2|instruction on preview screen|""(empty string)|
102
- |preview |instruction3|instruction on preview screen|""(empty string)|
103
- |preview |backgroundColor|background color of preview screen|null|
104
- |instruction <sup>**New**</sup> |title|Instruction's title on camera caputre screen|""(empty string)|
105
- |instruction <sup>**New**</sup> |refImage1|Instruction's reference image 1|null|
106
- |instruction <sup>**New**</sup> |refImage2|Instruction's reference image 2|null|
107
- |-|showPreviewInstruction|Show or hide preview instruction for captured photos|false|
78
+ | - | Property name | Description | Default value |
79
+ | ------------------------------ | ---------------------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
80
+ | - | torchBtnEnabled | to show torch button. If set to true, it will only be shown if onFlash from captureConfig is set to false. | false |
81
+ | - | crop | crop the frame area | false |
82
+ | - | width | width to resize the image | original width |
83
+ | - | imageQuality | quality of image | 1.0 (range from 0.0 to 1.0) |
84
+ | frame | size | size of the frame (width and height) | 90% of screen width and height is scaled proportionally according to card ratio |
85
+ | frame | color | color of the frame | #ffffff |
86
+ | frame | content | content of the frame (able to display svg file within the frame for guidance | null |
87
+ | - | showOverlay | transparent black overlay | true |
88
+ | topLabel | text | text of the top label | ""(empty string) |
89
+ | topLabel | color | color of the top label | #ffffff |
90
+ | topLabel | size | text size of the top label | 20 |
91
+ | bottomLabel | text | text of the bottom label | ""(empty string) |
92
+ | bottomLabel | color | color of the bottom label | #ffffff |
93
+ | bottomLabel | size | text size of the bottom label | 20 |
94
+ | timer | backgroundColor | background of the count down timer | #ffa500 |
95
+ | timer | textColor | text color of the count down timer | #ffffff |
96
+ | confirmBtnConfig | backgroundColor | background color of the confirm button | #ffa500 |
97
+ | confirmBtnConfig | contentColor | content color of the confirm button | #ffffff |
98
+ | retakeBtnConfig | backgroundColor | background color of the retake button | #ffa500 |
99
+ | retakeBtnConfig | contentColor | content color of the retake button | #ffffff |
100
+ | - | captureBtnColor | color of the capture button | #ffffff |
101
+ | - | firstPhotoConfig | config for the first capture | delay:0s,onFlash:false,outputPath: null |
102
+ | - | secondPhotoConfig | config for the second capture | null |
103
+ | preview | title | title on preview screen | ""(empty string) |
104
+ | preview | refImg | ref image on preview screen | null |
105
+ | preview | instruction1 | instruction on preview screen | ""(empty string) |
106
+ | preview | instruction2 | instruction on preview screen | ""(empty string) |
107
+ | preview | instruction3 | instruction on preview screen | ""(empty string) |
108
+ | preview | backgroundColor | background color of preview screen | null |
109
+ | instruction <sup>**New**</sup> | title | Instruction's title on camera caputre screen | ""(empty string) |
110
+ | instruction <sup>**New**</sup> | refImage1 | Instruction's reference image 1 | null |
111
+ | instruction <sup>**New**</sup> | refImage2 | Instruction's reference image 2 | null |
112
+ | - | showPreviewInstruction | Show or hide preview instruction for captured photos | false |
108
113
 
109
114
  ## Usage
115
+
110
116
  ```
111
117
  import { captureDocument } from "react-native-okaycam"
112
118
 
@@ -190,32 +196,35 @@ captureDocument(
190
196
  ```
191
197
 
192
198
  ### Result
193
- | Result | Description |
194
- |--|--|
195
- |fullDocumentImage|Result of firstPhotoConfig|
196
- |fullDocumentImage2|Result of secondPhotoConfig. Will only return if secondPhotoConfig is configured|
199
+
200
+ | Result | Description |
201
+ | ------------------ | -------------------------------------------------------------------------------- |
202
+ | fullDocumentImage | Result of firstPhotoConfig |
203
+ | fullDocumentImage2 | Result of secondPhotoConfig. Will only return if secondPhotoConfig is configured |
197
204
 
198
205
  ## OkayCam Selfie
206
+
199
207
  ### Configuration
200
208
 
201
- -| Property name | Description |Default value
202
- |--|--|--|--|
203
- ||width|width to resize the image|null|
204
- |-|imageQuality|quality of image|1.0 (range from 0.0 to 1.0)|
205
- |topLabel|text|text of the top label|Please align your face within the frame|
206
- |topLabel|color|color of the top label|#FFFFFF|
207
- |topLabel|size|text size of the top label|24|
208
- |-|bottomFrameColor|color of the bottom frame|#EB6709|
209
- |switchBtnConfig|color|color of the switch button|#FFFFFF|
210
- |switchBtnConfig|show|show or hide the camera switch button|true|
211
- |confirmBtnConfig|backgroundColor|background color of the confirm button|#ffa500|
212
- |confirmBtnConfig|contentColor|content color of the confirm button|#ffffff|
213
- |retakeBtnConfig|backgroundColor|background color of the retake button|#ffa500|
214
- |retakeBtnConfig|contentColor|content color of the retake button|#ffffff|
215
- |-|captureBtnColor|color of the capture button|#FFFFFF|
216
- |-|defaultCameraFacing|initial camera facing when the selfie cam is launched|CameraFacing.FRONT|
209
+ | - | Property name | Description | Default value |
210
+ | ---------------- | ------------------- | ----------------------------------------------------- | --------------------------------------- |
211
+ | | width | width to resize the image | null |
212
+ | - | imageQuality | quality of image | 1.0 (range from 0.0 to 1.0) |
213
+ | topLabel | text | text of the top label | Please align your face within the frame |
214
+ | topLabel | color | color of the top label | #FFFFFF |
215
+ | topLabel | size | text size of the top label | 24 |
216
+ | - | bottomFrameColor | color of the bottom frame | #EB6709 |
217
+ | switchBtnConfig | color | color of the switch button | #FFFFFF |
218
+ | switchBtnConfig | show | show or hide the camera switch button | true |
219
+ | confirmBtnConfig | backgroundColor | background color of the confirm button | #ffa500 |
220
+ | confirmBtnConfig | contentColor | content color of the confirm button | #ffffff |
221
+ | retakeBtnConfig | backgroundColor | background color of the retake button | #ffa500 |
222
+ | retakeBtnConfig | contentColor | content color of the retake button | #ffffff |
223
+ | - | captureBtnColor | color of the capture button | #FFFFFF |
224
+ | - | defaultCameraFacing | initial camera facing when the selfie cam is launched | CameraFacing.FRONT |
217
225
 
218
226
  ## Usage
227
+
219
228
  ```
220
229
  import { captureSelfie } from "react-native-okaycam"
221
230
 
@@ -255,14 +264,15 @@ captureSelfie(
255
264
  ```
256
265
 
257
266
  ### Result
258
- | Result | Description |
259
- |--|--|
260
- |selfieImage|Captured selfie image|
267
+
268
+ | Result | Description |
269
+ | ----------- | --------------------- |
270
+ | selfieImage | Captured selfie image |
261
271
 
262
272
  ## Error Codes
263
273
 
264
- | Error | Description |
265
- | ------------------------------------------- | ------------------------------------------------------------------------ |
266
- | invalid license | The license is invalid |
267
- | camera permission denied | The use did not grant the permission to access camera in order to do OCR |
268
- | cancel | The user canceled during the scanning process |
274
+ | Error | Description |
275
+ | ------------------------ | ------------------------------------------------------------------------ |
276
+ | invalid license | The license is invalid |
277
+ | camera permission denied | The use did not grant the permission to access camera in order to do OCR |
278
+ | cancel | The user canceled during the scanning process |
@@ -1,2 +1,2 @@
1
- #Fri Jan 05 16:34:25 BDT 2024
2
- gradle.version=6.8
1
+ #Mon May 06 09:35:00 BDT 2024
2
+ gradle.version=6.9
@@ -39,7 +39,7 @@ repositories {
39
39
 
40
40
  dependencies {
41
41
  implementation 'com.facebook.react:react-native:+'
42
- implementation('com.innov8tif.okaycam:OkayCam:1.2.5@aar') {
42
+ implementation('com.innov8tif.okaycam:OkayCam:1.2.6@aar') {
43
43
  transitive = true
44
44
  }
45
45
  implementation 'com.googlecode.json-simple:json-simple:1.1.1'
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "react-native-okaycam",
3
3
  "title": "React Native OkayCam",
4
- "version": "1.2.7",
4
+ "version": "1.2.9",
5
5
  "description": "React-Native version of OkayCam",
6
6
  "main": "index.ts",
7
7
  "files": [
@@ -22,7 +22,7 @@ Pod::Spec.new do |s|
22
22
  s.requires_arc = true
23
23
  s.static_framework = true
24
24
  s.dependency "React"
25
- s.dependency "OkayCam", "1.1.22"
25
+ s.dependency "OkayCam", "1.1.28"
26
26
  end
27
27
 
28
28
 
File without changes