@digiotech/react-native 1.0.13 → 1.0.15
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
|
@@ -86,7 +86,7 @@ function YourComponent() {
|
|
|
86
86
|
|
|
87
87
|
## Android
|
|
88
88
|
#### Note: Incase you are using camera feature and facing black screen on camera then follow below steps
|
|
89
|
-
- Add digioKycworkflow.aar file inside your react project under android/app/libs folder. [Download digio_kyc_workflow-4.0.
|
|
89
|
+
- Add digioKycworkflow.aar file inside your react project under android/app/libs folder. [Download digio_kyc_workflow-4.0.15.aar](https://drive.google.com/file/d/1nHeZhDBPavLxwJp0VgNrMiEZpXswENgz/view?usp=sharing)
|
|
90
90
|
|
|
91
91
|
|
|
92
92
|
- Add below in your project under build.gradle file inside dependencies
|
package/android/build.gradle
CHANGED
|
@@ -106,7 +106,7 @@ dependencies {
|
|
|
106
106
|
implementation 'com.google.android.gms:play-services-location:21.0.1'
|
|
107
107
|
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
compileOnly 'com.github.digio-tech:protean-esign:v3.2'
|
|
110
110
|
implementation 'com.android.volley:volley:1.2.1'
|
|
111
111
|
implementation 'com.scottyab:rootbeer-lib:0.1.0'
|
|
112
112
|
}
|
|
@@ -8,6 +8,7 @@ import android.content.Context;
|
|
|
8
8
|
import android.content.Intent;
|
|
9
9
|
import android.content.IntentFilter;
|
|
10
10
|
import android.text.TextUtils;
|
|
11
|
+
import android.os.Build;
|
|
11
12
|
|
|
12
13
|
import androidx.annotation.NonNull;
|
|
13
14
|
import androidx.annotation.Nullable;
|
|
@@ -137,7 +138,8 @@ public class DigioReactNativeModule extends ReactContextBaseJavaModule implement
|
|
|
137
138
|
public void onHostResume() {
|
|
138
139
|
if (!isReceiverRegistered) {
|
|
139
140
|
IntentFilter filter = new IntentFilter(DigioConstants.GATEWAY_EVENT);
|
|
140
|
-
this.getReactApplicationContext().registerReceiver(eventBroadcastReceiver, filter);
|
|
141
|
+
// this.getReactApplicationContext().registerReceiver(eventBroadcastReceiver, filter);
|
|
142
|
+
compatRegisterReceiver(this.getReactApplicationContext(), eventBroadcastReceiver, filter, true);
|
|
141
143
|
isReceiverRegistered = true;
|
|
142
144
|
}
|
|
143
145
|
|
|
@@ -162,6 +164,16 @@ public class DigioReactNativeModule extends ReactContextBaseJavaModule implement
|
|
|
162
164
|
return NAME;
|
|
163
165
|
}
|
|
164
166
|
|
|
167
|
+
private void compatRegisterReceiver(Context context, BroadcastReceiver receiver,
|
|
168
|
+
IntentFilter filter, boolean exported) {
|
|
169
|
+
if (Build.VERSION.SDK_INT >= 34 && context.getApplicationInfo().targetSdkVersion >= 34) {
|
|
170
|
+
context.registerReceiver(
|
|
171
|
+
receiver, filter, exported ? Context.RECEIVER_EXPORTED : Context.RECEIVER_NOT_EXPORTED);
|
|
172
|
+
} else {
|
|
173
|
+
context.registerReceiver(receiver, filter);
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
165
177
|
@ReactMethod
|
|
166
178
|
public void start(String documentId, String identifier, String tokenId, ReadableMap additionalData, ReadableMap config, Promise promise) {
|
|
167
179
|
this.resultPromise = promise;
|