@selligent-marketing-cloud/selligent-react-native 2.6.0 → 2.9.0

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/CHANGELOG.md +32 -0
  2. package/README.md +77 -4
  3. package/RNSelligent.podspec +4 -4
  4. package/android/build/generated/source/buildConfig/debug/com/selligent/BuildConfig.java +12 -0
  5. package/android/build/intermediates/aapt_friendly_merged_manifests/debug/aapt/AndroidManifest.xml +9 -0
  6. package/android/build/intermediates/aapt_friendly_merged_manifests/debug/aapt/output-metadata.json +16 -0
  7. package/android/build/intermediates/aar_metadata/debug/aar-metadata.properties +2 -0
  8. package/android/build/intermediates/annotation_processor_list/debug/annotationProcessors.json +1 -0
  9. package/android/build/intermediates/compile_library_classes_jar/debug/classes.jar +0 -0
  10. package/android/build/intermediates/compile_r_class_jar/debug/R.jar +0 -0
  11. package/android/build/intermediates/compile_symbol_list/debug/R.txt +6422 -0
  12. package/android/build/intermediates/incremental/mergeDebugJniLibFolders/merger.xml +2 -0
  13. package/android/build/intermediates/incremental/mergeDebugShaders/merger.xml +2 -0
  14. package/android/build/intermediates/incremental/packageDebugAssets/merger.xml +2 -0
  15. package/android/build/intermediates/incremental/packageDebugResources/compile-file-map.properties +1 -0
  16. package/android/build/intermediates/incremental/packageDebugResources/merger.xml +2 -0
  17. package/android/build/intermediates/javac/debug/classes/com/selligent/BroadcastDataFactory$1.class +0 -0
  18. package/android/build/intermediates/javac/debug/classes/com/selligent/BroadcastDataFactory.class +0 -0
  19. package/android/build/intermediates/javac/debug/classes/com/selligent/BroadcastEventDataParser.class +0 -0
  20. package/android/build/intermediates/javac/debug/classes/com/selligent/BroadcastEventType.class +0 -0
  21. package/android/build/intermediates/javac/debug/classes/com/selligent/BuildConfig.class +0 -0
  22. package/android/build/intermediates/javac/debug/classes/com/selligent/ButtonBroadcastEventDataParser.class +0 -0
  23. package/android/build/intermediates/javac/debug/classes/com/selligent/ClearCacheIntervalValue.class +0 -0
  24. package/android/build/intermediates/javac/debug/classes/com/selligent/Event.class +0 -0
  25. package/android/build/intermediates/javac/debug/classes/com/selligent/EventReceiver.class +0 -0
  26. package/android/build/intermediates/javac/debug/classes/com/selligent/EventType.class +0 -0
  27. package/android/build/intermediates/javac/debug/classes/com/selligent/GCMTokenBroadcastEventDataParser.class +0 -0
  28. package/android/build/intermediates/javac/debug/classes/com/selligent/InAppMessageBroadcastEventDataParser.class +0 -0
  29. package/android/build/intermediates/javac/debug/classes/com/selligent/InAppMessageRefreshType.class +0 -0
  30. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent$1.class +0 -0
  31. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent$2.class +0 -0
  32. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent$3.class +0 -0
  33. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent$4.class +0 -0
  34. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent$5.class +0 -0
  35. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligent.class +0 -0
  36. package/android/build/intermediates/javac/debug/classes/com/selligent/RNSelligentPackage.class +0 -0
  37. package/android/build/intermediates/javac/debug/classes/com/selligent/RemoteMessageDisplayType.class +0 -0
  38. package/android/build/intermediates/javac/debug/classes/com/selligent/SMEventFactory$1.class +0 -0
  39. package/android/build/intermediates/javac/debug/classes/com/selligent/SMEventFactory.class +0 -0
  40. package/android/build/intermediates/javac/debug/classes/com/selligent/SMSettingsFactory.class +0 -0
  41. package/android/build/intermediates/javac/debug/classes/com/selligent/Settings.class +0 -0
  42. package/android/build/intermediates/local_only_symbol_list/debug/R-def.txt +2 -0
  43. package/android/build/intermediates/manifest_merge_blame_file/debug/manifest-merger-blame-debug-report.txt +11 -0
  44. package/android/build/intermediates/merged_manifest/debug/AndroidManifest.xml +9 -0
  45. package/android/build/intermediates/navigation_json/debug/navigation.json +1 -0
  46. package/android/build/intermediates/packaged_manifests/debug/output-metadata.json +16 -0
  47. package/android/build/intermediates/runtime_library_classes_jar/debug/classes.jar +0 -0
  48. package/android/build/intermediates/symbol_list_with_package_name/debug/package-aware-r.txt +4812 -0
  49. package/android/build/outputs/logs/manifest-merger-debug-report.txt +25 -0
  50. package/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
  51. package/android/build.gradle +14 -18
  52. package/android/libs/sdk-release.aar +0 -0
  53. package/android/src/main/java/com/selligent/SMSettingsFactory.java +3 -0
  54. package/android/src/main/java/com/selligent/Settings.java +24 -0
  55. package/constants.js +1 -1
  56. package/index.js +2 -1
  57. package/ios/SMManagerSetting+ClientSettings.m +2 -2
  58. package/ios/SelligentReactNative.xcodeproj/project.pbxproj +4 -12
  59. package/ios/include/SMEvent.h +1 -1
  60. package/ios/include/SMInAppContentImageViewController.h +0 -1
  61. package/ios/include/SMInAppContentViewController.h +0 -1
  62. package/ios/include/SMInAppMessageType.h +1 -1
  63. package/ios/include/SMManager+InAppMessage.h +3 -3
  64. package/ios/include/SMManager+RemoteNotification.h +1 -1
  65. package/ios/include/SMManager+UserNotification.h +17 -4
  66. package/ios/include/SMManager.h +1 -1
  67. package/ios/include/SMManagerInAppMessageDelegate.h +2 -2
  68. package/ios/include/SMManagerSetting+Location.h +1 -1
  69. package/ios/include/SMManagerSetting.h +2 -2
  70. package/ios/include/SMNSNotification.h +4 -10
  71. package/ios/include/SMNotificationButtonType.h +0 -12
  72. package/ios/include/SMRemoteMessageDisplayType.h +2 -2
  73. package/ios/{libSelligentMobile2.7.a → libSelligentMobile.a} +0 -0
  74. package/package.json +3 -3
  75. package/trigger.yml +9 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,32 @@
1
+ # Changelog
2
+
3
+ ## [2.9.0] - 20 May 2022
4
+
5
+ ### Added
6
+ - Add possibility to set the app's notification channel's ID, name and description on `Android` via `notificationChannelId`, `notificationChannelName`, and `notificationChannelDescription` settings keys in `selligent.json`.
7
+ - Add comment to README about rich push notification method invocation deprecation on iOS.
8
+
9
+ ### Changed
10
+ - Add version 3.9.0 of the Android SDK to `android/libs`
11
+ - Add version 2.7.4 of the iOS SDK static library to `/ios`
12
+ - Change used native SDK version numbers to `3.9.0` and `2.7.4` for Android and iOS respectively in README
13
+
14
+ ## [2.8.0] - 18 February 2022
15
+
16
+ ### Added
17
+ - Re-add plotProjects dependency for Android in `android/build.gradle`
18
+ - Re-add geolocation native module functions (`enableGeolocation`, `isGeoLocationEnabled`) for Android
19
+ - Re-add geofencing header files for iOS in `ios/include` and module files in `ios/`
20
+ - Re-add plotProjects and geolocation documentation to README
21
+ - Add documentation regarding the Gradle build tool version and Gradle version compatability
22
+
23
+ ### Changed
24
+ - Add version 3.8.1 of the Android SDK to `android/libs`
25
+ - Swap the deprecated maven plugin and its archiving capabilities for the maven-publish plugin in `android/build.gradle`
26
+ - Add version 2.7.2 of the iOS SDK static library to `ios/`
27
+ - Change used native SDK version numbers to `3.8.1` and `2.7.2` for Android and iOS respectively in README
28
+ - Bump the react-native library to `0.67.2` in `package.json`
29
+ - Bump wrapper version to `2.8.0` in `package.json`
30
+
31
+ ### Fixed
32
+ - Fix typos in README as duly noted in https://github.com/SelligentMarketingCloud/MobileSDK-ReactNative/issues/25
package/README.md CHANGED
@@ -7,7 +7,14 @@ This module provides an API for the usage of the Selligent SDK in React Native.
7
7
  - Android
8
8
  - iOS
9
9
 
10
- > _**Important:** Since version 2.4.0 of this module we require your app to use the Android Gradle Plugin version 4.1.0 or higher in order to build on Android. This is the default Android Gradle Plugin version since React Native version 0.64.0 but can be manually increased in older versions of React Native._
10
+ > _**Important:** Since version 2.6.0 of this module we require your app to use the Android Gradle Plugin version 4.2.0 or higher in order to build on Android. This is the default Android Gradle Plugin version since React Native version 0.64.0 but can be manually increased in older versions of React Native._
11
+
12
+ This module uses the native Selligent SDKs:
13
+
14
+ | SDK | Version |
15
+ | ----------------------------------------------------------------------- | ------- |
16
+ | [Android](https://github.com/SelligentMarketingCloud/MobileSDK-Android) | 3.9.0 |
17
+ | [iOS](https://github.com/SelligentMarketingCloud/MobileSDK-iOS) | 2.7.4 |
11
18
 
12
19
  ## ToC
13
20
 
@@ -63,11 +70,53 @@ This module provides an API for the usage of the Selligent SDK in React Native.
63
70
  | loadCacheAsynchronously | boolean | No | Android Only |
64
71
  | fullyQualifiedNotificationActivityClassName | string | No | Android Only |
65
72
  | notificationIconColor | string | No | Android Only |
73
+ | notificationChannelId | string | No | Android Only |
74
+ | notificationChannelName | string | No | Android Only |
75
+ | notificationChannelDescription | string | No | Android Only |
66
76
 
67
77
 
68
78
 
69
79
  ### Android Specific Installation
70
80
 
81
+ > ### **Atention for Huawei developers!**
82
+ >
83
+ > In order to use this module on Huawei devices (without Goggle Play services), you should add the following dependencies in the `build.gradle` files of the Android project in your React Native project:
84
+ >
85
+ > In your Android project's root `build.gradle` file:
86
+ >
87
+ > ```gradle
88
+ >
89
+ > buildscript {
90
+ > repositories {
91
+ > maven { url 'https://developer.huawei.com/repo/' }
92
+ > }
93
+ > dependencies {
94
+ > classpath 'com.huawei.agconnect:agcp:1.6.0.300'
95
+ > }
96
+ > }
97
+ >
98
+ > allProjects: {
99
+ > repositories: {
100
+ > maven { url 'https://developer.huawei.com/repo/' }
101
+ > }
102
+ > }
103
+ >
104
+ > ```
105
+ >
106
+ > In your app module's `build.gradle` file:
107
+ >
108
+ > ```gradle
109
+ >
110
+ > apply plugin: 'com.huawei.agconnect'
111
+ >
112
+ > dependencies {
113
+ > api 'com.huawei.hms:base:6.2.0.300'
114
+ > api 'com.huawei.hms:push:6.1.0.300'
115
+ > api 'com.huawei.hms:maps:6.2.0.301'
116
+ > }
117
+ >
118
+ > ```
119
+
71
120
  <details>
72
121
  <summary>Without autolinking (RN 0.59 and below)</summary>
73
122
 
@@ -80,13 +129,17 @@ This module provides an API for the usage of the Selligent SDK in React Native.
80
129
  project(':selligent-react-native').projectDir = new File(rootProject.projectDir, '../node_modules/@selligent-marketing-cloud/selligent-react-native/android')
81
130
  ```
82
131
 
83
- 3. Add the following in the `android/build.gradle` file:
132
+ 3. Add the following in the `android/build.gradle` file, and make sure the the the Gradle version in `android/gradle/wrapper/gradle-wrapper.properties` is >= 6.7.1:
84
133
 
85
134
  ```groovy
135
+ // android/build.gradle
136
+
86
137
  buildscript {
87
138
  ...
88
139
  dependencies {
89
140
  ...
141
+ // Make sure your Gradle plugin version is >= 4.2.0
142
+ classpath("com.android.tools.build:gradle:4.2.0")
90
143
  // Add the following:
91
144
  classpath 'com.google.gms:google-services:4.3.3'
92
145
  }
@@ -108,6 +161,13 @@ This module provides an API for the usage of the Selligent SDK in React Native.
108
161
  }
109
162
  ```
110
163
 
164
+ ```groovy
165
+ // android/gradle/wrapper/gradle-wrapper.properties
166
+ ...
167
+ distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-all.zip
168
+ ...
169
+ ```
170
+
111
171
  4. Add the following in the `android/app/build.gradle` file:
112
172
 
113
173
  ```groovy
@@ -168,13 +228,17 @@ This module provides an API for the usage of the Selligent SDK in React Native.
168
228
  project(':selligent-react-native').projectDir = new File(rootProject.projectDir, '../node_modules/@selligent-marketing-cloud/selligent-react-native/android')
169
229
  ```
170
230
 
171
- 3. Add the following in the `android/build.gradle` file:
231
+ 3. Add the following in the `android/build.gradle` file, and make sure the the the Gradle version in `android/gradle/wrapper/gradle-wrapper.properties` is >= 6.7.1:
172
232
 
173
233
  ```groovy
234
+ // android/build.gradle
235
+
174
236
  buildscript {
175
237
  ...
176
238
  dependencies {
177
239
  ...
240
+ // Make sure your Gradle plugin version is >= 4.2.0
241
+ classpath("com.android.tools.build:gradle:4.2.0")
178
242
  // Add the following:
179
243
  classpath 'com.google.gms:google-services:4.3.3'
180
244
  }
@@ -196,6 +260,13 @@ This module provides an API for the usage of the Selligent SDK in React Native.
196
260
  }
197
261
  ```
198
262
 
263
+ ```groovy
264
+ // android/gradle/wrapper/gradle-wrapper.properties
265
+ ...
266
+ distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-all.zip
267
+ ...
268
+ ```
269
+
199
270
  4. Add the following in the `android/app/build.gradle` file:
200
271
 
201
272
  ```groovy
@@ -370,7 +441,9 @@ Add the following properties to the `selligent.json` file:
370
441
  Make sure you add your `appGroupId` to the `selligent.json`.
371
442
  > **IMPORTANT!** make sure your `appGroupId` has the following structure or it will not work: `group.{MAIN_APP_BUNDLE_ID}`
372
443
 
373
- #### Geolocation
444
+ > **IMPORTAND** Since v2.9.0, `-(void)didReceiveNotification:(UNNotification *)notification` of `SMManager+RemoteNotification` has become deprecated. You will need to invoke `-(void)didReceiveNotification:(UNNotification *)notification withContext` instead. Consult [**the iOS documentation**](https://github.com/SelligentMarketingCloud/MobileSDK-iOS/tree/master/Documentation#start-the-sdk-from-inside-the-extension-1) for more details.
445
+
446
+ #### Geolocation
374
447
 
375
448
  For geolocation services, follow section [**Geolocation**](https://github.com/SelligentMarketingCloud/MobileSDK-iOS/tree/master/Documentation#geolocation), of the native documentation. You also need to configure several permissions described [**here**](https://github.com/SelligentMarketingCloud/MobileSDK-iOS/tree/master/Documentation#permission-for-geolocation).
376
449
 
@@ -12,17 +12,17 @@ Pod::Spec.new do |s|
12
12
  DESC
13
13
  s.homepage = "https://github.com/SelligentMarketingCloud/MobileSDK-ReactNative"
14
14
  s.license = "MIT"
15
- s.platform = :ios, "7.0"
15
+ s.platform = :ios, "11.0"
16
16
  s.source = { :git => "https://github.com/SelligentMarketingCloud/MobileSDK-ReactNative.git", :tag => "#{s.version}" }
17
17
 
18
18
  s.source_files = "ios/**/*.{h,m}"
19
19
  s.requires_arc = true
20
20
 
21
- s.vendored_libraries = "ios/libSelligentMobile2.7.a"
22
- s.libraries = "SelligentMobile2.7"
21
+ s.vendored_libraries = "ios/libSelligentMobile.a"
22
+ s.libraries = "SelligentMobile"
23
23
 
24
24
  s.dependency "React"
25
- s.dependency 'PlotPlugin'
25
+ s.dependency "PlotPlugin"
26
26
  end
27
27
 
28
28
 
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Automatically generated file. DO NOT MODIFY
3
+ */
4
+ package com.selligent;
5
+
6
+ public final class BuildConfig {
7
+ public static final boolean DEBUG = Boolean.parseBoolean("true");
8
+ public static final String LIBRARY_PACKAGE_NAME = "com.selligent";
9
+ public static final String BUILD_TYPE = "debug";
10
+ // Selligent settings
11
+ public static final String SELLIGENT_SETTINGS = "{\"url\":\"https://mobile.emsecure.net/mobilepush/api/\",\"clientId\":\"4acaf646-ef68-4b78-9a30-8412d3007cba\",\"privateKey\":\"TzYgBoYF+I1fZ+1Tapdpz+XQXKyLUZocDzmWV1kBYHKIQ8WWWXL61/m7FWo8mY6hSrAMVUoH1EaViq7+dgQ9Jg==\",\"fullyQualifiedNotificationActivityClassName\":\"com.selligentdevapprn.MainActivity\",\"inAppMessageRefreshType\":11,\"configureLocationServices\":true,\"notificationSmallIcon\":\"ic_notification\",\"notificationLargeIcon\":\"ic_notification\",\"notificationIconColor\":\"#FF0000\",\"appGroupId\":\"group.be.appfoundry.selligent.reactnative.development.app\",\"notificationChannelId\":\"SMChannel001\",\"notificationChannelName\":\"SMDefaultChannel\",\"notificationChannelDescription\":\"\"}";
12
+ }
@@ -0,0 +1,9 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <manifest xmlns:android="http://schemas.android.com/apk/res/android"
3
+ package="com.selligent" >
4
+
5
+ <uses-sdk
6
+ android:minSdkVersion="21"
7
+ android:targetSdkVersion="30" />
8
+
9
+ </manifest>
@@ -0,0 +1,16 @@
1
+ {
2
+ "version": 2,
3
+ "artifactType": {
4
+ "type": "AAPT_FRIENDLY_MERGED_MANIFESTS",
5
+ "kind": "Directory"
6
+ },
7
+ "applicationId": "com.selligent",
8
+ "variantName": "debug",
9
+ "elements": [
10
+ {
11
+ "type": "SINGLE",
12
+ "filters": [],
13
+ "outputFile": "AndroidManifest.xml"
14
+ }
15
+ ]
16
+ }
@@ -0,0 +1,2 @@
1
+ aarFormatVersion=1.0
2
+ aarMetadataVersion=1.0