react-native-insider 4.4.0 → 4.4.1
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/RNInsider.podspec +2 -2
- package/android/build.gradle +1 -1
- package/android/src/main/java/com/useinsider/react/RNInsiderModule.java +74 -17
- package/changelog/4.4.1.md +4 -0
- package/index.js +30 -0
- package/ios/RNInsider/RNInsider.m +24 -0
- package/package.json +1 -1
- package/changelog/4.4.0.md +0 -4
package/RNInsider.podspec
CHANGED
|
@@ -9,11 +9,11 @@ Pod::Spec.new do |s|
|
|
|
9
9
|
s.authors = package_json['author']
|
|
10
10
|
s.license = 'MIT'
|
|
11
11
|
s.platform = :ios, '10.0'
|
|
12
|
-
s.source = {:http => 'https://mobilesdk.useinsider.com/iOS/11.3.
|
|
12
|
+
s.source = {:http => 'https://mobilesdk.useinsider.com/iOS/11.3.3/InsiderMobileIOSFramework.zip'}
|
|
13
13
|
s.source_files = 'ios/RNInsider/*.{h,m}'
|
|
14
14
|
s.requires_arc = true
|
|
15
15
|
s.static_framework = true
|
|
16
16
|
s.dependency 'React'
|
|
17
|
-
s.dependency 'InsiderMobile', '11.3.
|
|
17
|
+
s.dependency 'InsiderMobile', '11.3.3'
|
|
18
18
|
s.dependency 'InsiderHybrid', '1.1.2'
|
|
19
19
|
end
|
package/android/build.gradle
CHANGED
|
@@ -36,7 +36,7 @@ android {
|
|
|
36
36
|
|
|
37
37
|
dependencies {
|
|
38
38
|
implementation "com.facebook.react:react-native:${getVersionFromPartner('reactNativeVersion', '+')}"
|
|
39
|
-
implementation ('com.useinsider:insider:12.3.
|
|
39
|
+
implementation ('com.useinsider:insider:12.3.1')
|
|
40
40
|
implementation ('com.useinsider:insiderhybrid:1.1.3')
|
|
41
41
|
|
|
42
42
|
implementation 'com.google.android.play:core:1.10.1'
|
|
@@ -355,12 +355,17 @@ public class RNInsiderModule extends ReactContextBaseJavaModule {
|
|
|
355
355
|
}
|
|
356
356
|
|
|
357
357
|
@ReactMethod
|
|
358
|
-
public void setGDPRConsent(boolean gdprConsent) {
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
358
|
+
public void setGDPRConsent(final boolean gdprConsent) {
|
|
359
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
360
|
+
@Override
|
|
361
|
+
public void run() {
|
|
362
|
+
try {
|
|
363
|
+
Insider.Instance.setGDPRConsent(gdprConsent);
|
|
364
|
+
} catch (Exception e) {
|
|
365
|
+
Insider.Instance.putException(e);
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
});
|
|
364
369
|
}
|
|
365
370
|
|
|
366
371
|
@ReactMethod
|
|
@@ -555,11 +560,16 @@ public class RNInsiderModule extends ReactContextBaseJavaModule {
|
|
|
555
560
|
|
|
556
561
|
@ReactMethod
|
|
557
562
|
public void startTrackingGeofence() {
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
564
|
+
@Override
|
|
565
|
+
public void run() {
|
|
566
|
+
try {
|
|
567
|
+
Insider.Instance.startTrackingGeofence();
|
|
568
|
+
} catch (Exception e) {
|
|
569
|
+
Insider.Instance.putException(e);
|
|
570
|
+
}
|
|
571
|
+
}
|
|
572
|
+
});
|
|
563
573
|
}
|
|
564
574
|
|
|
565
575
|
@ReactMethod
|
|
@@ -601,12 +611,17 @@ public class RNInsiderModule extends ReactContextBaseJavaModule {
|
|
|
601
611
|
}
|
|
602
612
|
|
|
603
613
|
@ReactMethod
|
|
604
|
-
public void enableIDFACollection(boolean enableIDFACollection) {
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
614
|
+
public void enableIDFACollection(final boolean enableIDFACollection) {
|
|
615
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
616
|
+
@Override
|
|
617
|
+
public void run() {
|
|
618
|
+
try {
|
|
619
|
+
Insider.Instance.enableIDFACollection(enableIDFACollection);
|
|
620
|
+
} catch (Exception e) {
|
|
621
|
+
Insider.Instance.putException(e);
|
|
622
|
+
}
|
|
623
|
+
}
|
|
624
|
+
});
|
|
610
625
|
}
|
|
611
626
|
|
|
612
627
|
@ReactMethod
|
|
@@ -636,4 +651,46 @@ public class RNInsiderModule extends ReactContextBaseJavaModule {
|
|
|
636
651
|
Insider.Instance.putException(e);
|
|
637
652
|
}
|
|
638
653
|
}
|
|
654
|
+
|
|
655
|
+
@ReactMethod
|
|
656
|
+
public void enableLocationCollection(final boolean consentStatus) {
|
|
657
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
658
|
+
@Override
|
|
659
|
+
public void run() {
|
|
660
|
+
try {
|
|
661
|
+
Insider.Instance.enableLocationCollection(consentStatus);
|
|
662
|
+
} catch (Exception e) {
|
|
663
|
+
Insider.Instance.putException(e);
|
|
664
|
+
}
|
|
665
|
+
}
|
|
666
|
+
});
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
@ReactMethod
|
|
670
|
+
public void enableIpCollection(final boolean consentStatus) {
|
|
671
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
672
|
+
@Override
|
|
673
|
+
public void run() {
|
|
674
|
+
try {
|
|
675
|
+
Insider.Instance.enableIpCollection(consentStatus);
|
|
676
|
+
} catch (Exception e) {
|
|
677
|
+
Insider.Instance.putException(e);
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
});
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
@ReactMethod
|
|
684
|
+
public void enableCarrierCollection(final boolean consentStatus) {
|
|
685
|
+
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
|
686
|
+
@Override
|
|
687
|
+
public void run() {
|
|
688
|
+
try {
|
|
689
|
+
Insider.Instance.enableCarrierCollection(consentStatus);
|
|
690
|
+
} catch (Exception e) {
|
|
691
|
+
Insider.Instance.putException(e);
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
});
|
|
695
|
+
}
|
|
639
696
|
}
|
package/index.js
CHANGED
|
@@ -322,4 +322,34 @@ export default class RNInsider {
|
|
|
322
322
|
Insider.putErrorLog(generateJSONErrorString(error));
|
|
323
323
|
}
|
|
324
324
|
}
|
|
325
|
+
|
|
326
|
+
static enableLocationCollection (consentStatus) {
|
|
327
|
+
if (shouldNotProceed()) return;
|
|
328
|
+
|
|
329
|
+
try {
|
|
330
|
+
Insider.enableLocationCollection(consentStatus);
|
|
331
|
+
} catch (error) {
|
|
332
|
+
Insider.putErrorLog(generateJSONErrorString(error));
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
static enableIpCollection (consentStatus) {
|
|
337
|
+
if (shouldNotProceed()) return;
|
|
338
|
+
|
|
339
|
+
try {
|
|
340
|
+
Insider.enableIpCollection(consentStatus);
|
|
341
|
+
} catch (error) {
|
|
342
|
+
Insider.putErrorLog(generateJSONErrorString(error));
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
static enableCarrierCollection (consentStatus) {
|
|
347
|
+
if (shouldNotProceed()) return;
|
|
348
|
+
|
|
349
|
+
try {
|
|
350
|
+
Insider.enableCarrierCollection(consentStatus);
|
|
351
|
+
} catch (error) {
|
|
352
|
+
Insider.putErrorLog(generateJSONErrorString(error));
|
|
353
|
+
}
|
|
354
|
+
}
|
|
325
355
|
}
|
|
@@ -460,6 +460,30 @@ RCT_EXPORT_METHOD(showNativeAppReview) {
|
|
|
460
460
|
}
|
|
461
461
|
}
|
|
462
462
|
|
|
463
|
+
RCT_EXPORT_METHOD(enableLocationCollection:(BOOL)enabled) {
|
|
464
|
+
@try {
|
|
465
|
+
[Insider enableLocationCollection:enabled];
|
|
466
|
+
} @catch (NSException *e){
|
|
467
|
+
[Insider sendError:e desc:[NSString stringWithFormat:@"%s:%d", __func__, __LINE__]];
|
|
468
|
+
}
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
RCT_EXPORT_METHOD(enableIpCollection:(BOOL)enabled) {
|
|
472
|
+
@try {
|
|
473
|
+
[Insider enableIpCollection:enabled];
|
|
474
|
+
} @catch (NSException *e){
|
|
475
|
+
[Insider sendError:e desc:[NSString stringWithFormat:@"%s:%d", __func__, __LINE__]];
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
RCT_EXPORT_METHOD(enableCarrierCollection:(BOOL)enabled) {
|
|
480
|
+
@try {
|
|
481
|
+
[Insider enableCarrierCollection:enabled];
|
|
482
|
+
} @catch (NSException *e){
|
|
483
|
+
[Insider sendError:e desc:[NSString stringWithFormat:@"%s:%d", __func__, __LINE__]];
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
|
|
463
487
|
-(void)emitEvent:(NSDictionary *)evetData {
|
|
464
488
|
@try {
|
|
465
489
|
RNNotificationHandler *handler = [[RNNotificationHandler alloc] init];
|
package/package.json
CHANGED
package/changelog/4.4.0.md
DELETED