cordova-plugin-repro 6.27.1 → 6.29.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cordova-plugin-repro",
3
- "version": "6.27.1",
3
+ "version": "6.29.0",
4
4
  "description": "Repro Cordova Plugin",
5
5
  "cordova": {
6
6
  "id": "cordova-plugin-repro",
package/plugin.xml CHANGED
@@ -1,6 +1,6 @@
1
1
  <?xml version='1.0' encoding='UTF-8'?>
2
2
 
3
- <plugin xmlns:android="http://schemas.android.com/apk/res/android" id="cordova-plugin-repro" version="6.27.1" xmlns="http://apache.org/cordova/ns/plugins/1.0">
3
+ <plugin xmlns:android="http://schemas.android.com/apk/res/android" id="cordova-plugin-repro" version="6.29.0" xmlns="http://apache.org/cordova/ns/plugins/1.0">
4
4
  <name>Repro</name>
5
5
  <description>Repro Cordova Plugin</description>
6
6
  <license>Commercial</license>
@@ -1,5 +1,5 @@
1
1
  {
2
- "ios-sdk": "5.24.1",
3
- "android-sdk": "5.24.0",
4
- "bridge": "6.27.1"
2
+ "ios-sdk": "5.26.0",
3
+ "android-sdk": "5.26.0",
4
+ "bridge": "6.29.0"
5
5
  }
@@ -46,7 +46,7 @@ import io.repro.android.user.UserProfilePrefecture;
46
46
  */
47
47
  public final class CordovaPlugin extends org.apache.cordova.CordovaPlugin {
48
48
 
49
- private static final String REPRO_CORDOVA_BRIDGE_VERSION = "6.27.1";
49
+ private static final String REPRO_CORDOVA_BRIDGE_VERSION = "6.29.0";
50
50
 
51
51
  private interface CordovaReproCommand {
52
52
  boolean execute(CordovaPlugin plugin, CordovaArgs args, CallbackContext callbackContext) throws JSONException;
@@ -340,6 +340,16 @@ public final class CordovaPlugin extends org.apache.cordova.CordovaPlugin {
340
340
  return plugin.unlinkLineID(args, callbackContext);
341
341
  }
342
342
  });
343
+ COMMAND_MAP.put("subscribeEmailChannel", new CordovaReproCommand() {
344
+ public boolean execute(CordovaPlugin plugin, CordovaArgs args, CallbackContext callbackContext) throws JSONException {
345
+ return plugin.subscribeEmailChannel(args, callbackContext);
346
+ }
347
+ });
348
+ COMMAND_MAP.put("unsubscribeEmailChannel", new CordovaReproCommand() {
349
+ public boolean execute(CordovaPlugin plugin, CordovaArgs args, CallbackContext callbackContext) throws JSONException {
350
+ return plugin.unsubscribeEmailChannel(args, callbackContext);
351
+ }
352
+ });
343
353
  COMMAND_MAP.put("getNewsFeedsWithLimit", new CordovaReproCommand() {
344
354
  public boolean execute(CordovaPlugin plugin, CordovaArgs args, CallbackContext callbackContext) throws JSONException {
345
355
  return plugin.getNewsFeedsWithLimit(args, callbackContext);
@@ -1312,6 +1322,40 @@ public final class CordovaPlugin extends org.apache.cordova.CordovaPlugin {
1312
1322
  return true;
1313
1323
  }
1314
1324
 
1325
+ private boolean subscribeEmailChannel(final CordovaArgs args, final CallbackContext callbackContext) throws JSONException {
1326
+ final Object channelId = args.opt(0);
1327
+ if (!(channelId instanceof Number)) {
1328
+ android.util.Log.e("Repro", "Didn't subscribe email channel: channel ID is required, and should be Number. null or undefined is not allowed.");
1329
+ return true;
1330
+ }
1331
+
1332
+ callAPI(new API(callbackContext) {
1333
+ Void api() {
1334
+ Repro.subscribeEmailChannel(((Number)channelId).longValue());
1335
+ return null;
1336
+ }
1337
+ });
1338
+
1339
+ return true;
1340
+ }
1341
+
1342
+ private boolean unsubscribeEmailChannel(final CordovaArgs args, final CallbackContext callbackContext) throws JSONException {
1343
+ final Object channelId = args.opt(0);
1344
+ if (!(channelId instanceof Number)) {
1345
+ android.util.Log.e("Repro", "Didn't unsubscribe email channel: channel ID is required, and should be Number. null or undefined is not allowed.");
1346
+ return true;
1347
+ }
1348
+
1349
+ callAPI(new API(callbackContext) {
1350
+ Void api() {
1351
+ Repro.unsubscribeEmailChannel(((Number)channelId).longValue());
1352
+ return null;
1353
+ }
1354
+ });
1355
+
1356
+ return true;
1357
+ }
1358
+
1315
1359
  private boolean getNewsFeedsWithLimit(final CordovaArgs args, final CallbackContext callbackContext) throws JSONException {
1316
1360
  final Object limit = args.opt(0);
1317
1361
  if (!isValidNewsFeedRequestNumericParam(limit)) {
Binary file
@@ -7,7 +7,7 @@
7
7
 
8
8
  #import <Cordova/CDV.h>
9
9
 
10
- #define REPRO_CORDOVA_BRIDGE_VERSION "6.27.1"
10
+ #define REPRO_CORDOVA_BRIDGE_VERSION "6.29.0"
11
11
 
12
12
  @interface CDVRepro : CDVPlugin
13
13
 
@@ -564,6 +564,28 @@ static NSDictionary* convertNSStringJSONToNSDictionary(NSString* json) {
564
564
  [Repro unlinkLineID:lineUserId lineChannelID:lineChannelId];
565
565
  }
566
566
 
567
+ - (void)subscribeEmailChannel:(CDVInvokedUrlCommand*)command
568
+ {
569
+ id channelId = [command.arguments objectAtIndex:0];
570
+ if (![channelId isKindOfClass:NSNumber.class]) {
571
+ NSLog(@"ERROR: Repro Didn't subscribe email channel: channel ID is required, and should be Number. null or undefined is not allowed.");
572
+ return;
573
+ }
574
+
575
+ [Repro subscribeEmailChannel:[channelId integerValue]];
576
+ }
577
+
578
+ - (void)unsubscribeEmailChannel:(CDVInvokedUrlCommand*)command
579
+ {
580
+ id channelId = [command.arguments objectAtIndex:0];
581
+ if (![channelId isKindOfClass:NSNumber.class]) {
582
+ NSLog(@"ERROR: Repro Didn't unsubscribe email channel: channel ID is required, and should be Number. null or undefined is not allowed.");
583
+ return;
584
+ }
585
+
586
+ [Repro unsubscribeEmailChannel:[channelId integerValue]];
587
+ }
588
+
567
589
  - (void)getNewsFeedsWithLimit:(CDVInvokedUrlCommand*)command
568
590
  {
569
591
  NSNumber* limit = [command.arguments objectAtIndex:0];
@@ -6,33 +6,33 @@
6
6
  <array>
7
7
  <dict>
8
8
  <key>LibraryIdentifier</key>
9
- <string>ios-arm64_i386_x86_64-simulator</string>
9
+ <string>ios-arm64_armv7_armv7s</string>
10
10
  <key>LibraryPath</key>
11
11
  <string>Repro.framework</string>
12
12
  <key>SupportedArchitectures</key>
13
13
  <array>
14
14
  <string>arm64</string>
15
- <string>i386</string>
16
- <string>x86_64</string>
15
+ <string>armv7</string>
16
+ <string>armv7s</string>
17
17
  </array>
18
18
  <key>SupportedPlatform</key>
19
19
  <string>ios</string>
20
- <key>SupportedPlatformVariant</key>
21
- <string>simulator</string>
22
20
  </dict>
23
21
  <dict>
24
22
  <key>LibraryIdentifier</key>
25
- <string>ios-arm64_armv7_armv7s</string>
23
+ <string>ios-arm64_i386_x86_64-simulator</string>
26
24
  <key>LibraryPath</key>
27
25
  <string>Repro.framework</string>
28
26
  <key>SupportedArchitectures</key>
29
27
  <array>
30
28
  <string>arm64</string>
31
- <string>armv7</string>
32
- <string>armv7s</string>
29
+ <string>i386</string>
30
+ <string>x86_64</string>
33
31
  </array>
34
32
  <key>SupportedPlatform</key>
35
33
  <string>ios</string>
34
+ <key>SupportedPlatformVariant</key>
35
+ <string>simulator</string>
36
36
  </dict>
37
37
  </array>
38
38
  <key>CFBundlePackageType</key>
@@ -22,11 +22,11 @@
22
22
  </data>
23
23
  <key>ios-arm64_armv7_armv7s/Repro.framework/Headers/Repro.h</key>
24
24
  <data>
25
- Ijp34pJsZUnUlKunBHxeir6oH2A=
25
+ wHd93CwpJg5Q1Q/hM/0wlt13r5c=
26
26
  </data>
27
27
  <key>ios-arm64_armv7_armv7s/Repro.framework/Info.plist</key>
28
28
  <data>
29
- C5aL70HLHNvOT0654m+GrpC1wMg=
29
+ FY5xB59hx7Y9KfSiu5T/xdtgmRQ=
30
30
  </data>
31
31
  <key>ios-arm64_armv7_armv7s/Repro.framework/Modules/module.modulemap</key>
32
32
  <data>
@@ -38,7 +38,7 @@
38
38
  </data>
39
39
  <key>ios-arm64_armv7_armv7s/Repro.framework/Repro</key>
40
40
  <data>
41
- PloKqlz8RYM74hde6P6eRMUXSvQ=
41
+ H8gf9nQCscF5u3juhCiX0TOYlAI=
42
42
  </data>
43
43
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Headers/RPREventProperties.h</key>
44
44
  <data>
@@ -58,11 +58,11 @@
58
58
  </data>
59
59
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Headers/Repro.h</key>
60
60
  <data>
61
- Ijp34pJsZUnUlKunBHxeir6oH2A=
61
+ wHd93CwpJg5Q1Q/hM/0wlt13r5c=
62
62
  </data>
63
63
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Info.plist</key>
64
64
  <data>
65
- xpAjc6XlcsJlPTW/PxaKCldCnJI=
65
+ OHOaCEb+2BgQHCmnm3WNgox87e4=
66
66
  </data>
67
67
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Modules/module.modulemap</key>
68
68
  <data>
@@ -74,7 +74,7 @@
74
74
  </data>
75
75
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Repro</key>
76
76
  <data>
77
- oZpf8MEVfE2EvkuqK7/+CCGCpHw=
77
+ KF4fWXudcgsKoK41seN4kEPyRa4=
78
78
  </data>
79
79
  </dict>
80
80
  <key>files2</key>
@@ -127,22 +127,22 @@
127
127
  <dict>
128
128
  <key>hash</key>
129
129
  <data>
130
- Ijp34pJsZUnUlKunBHxeir6oH2A=
130
+ wHd93CwpJg5Q1Q/hM/0wlt13r5c=
131
131
  </data>
132
132
  <key>hash2</key>
133
133
  <data>
134
- 29d05BLsAPQZQr9ot1fLEs3dAhNKCGe7yfrF1bYdAd4=
134
+ p6QzaicoKozMHf1twylf3lCRIk4271lEWtwnnBtYi20=
135
135
  </data>
136
136
  </dict>
137
137
  <key>ios-arm64_armv7_armv7s/Repro.framework/Info.plist</key>
138
138
  <dict>
139
139
  <key>hash</key>
140
140
  <data>
141
- C5aL70HLHNvOT0654m+GrpC1wMg=
141
+ FY5xB59hx7Y9KfSiu5T/xdtgmRQ=
142
142
  </data>
143
143
  <key>hash2</key>
144
144
  <data>
145
- eqLJIurbXXY3O+3a1aZ7EQoB/XTqBc76Xri79MY2sXM=
145
+ 3BcF9JZvnKxCJLGlfg7viTZUcFxz9dm267QDgEWBEiI=
146
146
  </data>
147
147
  </dict>
148
148
  <key>ios-arm64_armv7_armv7s/Repro.framework/Modules/module.modulemap</key>
@@ -171,11 +171,11 @@
171
171
  <dict>
172
172
  <key>hash</key>
173
173
  <data>
174
- PloKqlz8RYM74hde6P6eRMUXSvQ=
174
+ H8gf9nQCscF5u3juhCiX0TOYlAI=
175
175
  </data>
176
176
  <key>hash2</key>
177
177
  <data>
178
- SrR/gwIIitDp+LYrpG1x3pOdK2xcOlA3y3lE9w/ny5k=
178
+ t0fZD9gp/akf+5MsAoHjWMcpciYM/Cnw/fgPWnllNB0=
179
179
  </data>
180
180
  </dict>
181
181
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Headers/RPREventProperties.h</key>
@@ -226,22 +226,22 @@
226
226
  <dict>
227
227
  <key>hash</key>
228
228
  <data>
229
- Ijp34pJsZUnUlKunBHxeir6oH2A=
229
+ wHd93CwpJg5Q1Q/hM/0wlt13r5c=
230
230
  </data>
231
231
  <key>hash2</key>
232
232
  <data>
233
- 29d05BLsAPQZQr9ot1fLEs3dAhNKCGe7yfrF1bYdAd4=
233
+ p6QzaicoKozMHf1twylf3lCRIk4271lEWtwnnBtYi20=
234
234
  </data>
235
235
  </dict>
236
236
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Info.plist</key>
237
237
  <dict>
238
238
  <key>hash</key>
239
239
  <data>
240
- xpAjc6XlcsJlPTW/PxaKCldCnJI=
240
+ OHOaCEb+2BgQHCmnm3WNgox87e4=
241
241
  </data>
242
242
  <key>hash2</key>
243
243
  <data>
244
- VeN9FIOfP8GEbiHn/8qImcdapVKrsrZFg6/pehsP1vE=
244
+ 6r4Hl/uO6vWlQSVIA0Q+271s2klM0BSBuvLeQ4BZBCo=
245
245
  </data>
246
246
  </dict>
247
247
  <key>ios-arm64_i386_x86_64-simulator/Repro.framework/Modules/module.modulemap</key>
@@ -270,11 +270,11 @@
270
270
  <dict>
271
271
  <key>hash</key>
272
272
  <data>
273
- oZpf8MEVfE2EvkuqK7/+CCGCpHw=
273
+ KF4fWXudcgsKoK41seN4kEPyRa4=
274
274
  </data>
275
275
  <key>hash2</key>
276
276
  <data>
277
- jBZrwV4LJ4Gyc3lSjNE6GVJhFEOpe2cEYoMqKCCeF+g=
277
+ PtsDZKkPv5qugGAKgVDEtaNBdW7xdN6vOO521rA3WKA=
278
278
  </data>
279
279
  </dict>
280
280
  </dict>
@@ -260,6 +260,13 @@ NS_SWIFT_NAME(linkLineID(lineUserID:lineChannelID:));
260
260
  + (void)unlinkLineID:(nonnull NSString *)lineUserId lineChannelID:(nonnull NSString *)lineChannelId
261
261
  NS_SWIFT_NAME(unlinkLineID(lineUserID:lineChannelID:));
262
262
 
263
+ // Email Channel Integration
264
+ + (void)subscribeEmailChannel:(NSInteger)channelId
265
+ NS_SWIFT_NAME(subscribeEmailChannel(channelID:));
266
+
267
+ + (void)unsubscribeEmailChannel:(NSInteger)channelId
268
+ NS_SWIFT_NAME(unsubscribeEmailChannel(channelID:));
269
+
263
270
  + (void)deepLinkReceived:(nonnull NSURL *)url
264
271
  NS_SWIFT_NAME(deepLinkReceived(url:));
265
272
 
@@ -260,6 +260,13 @@ NS_SWIFT_NAME(linkLineID(lineUserID:lineChannelID:));
260
260
  + (void)unlinkLineID:(nonnull NSString *)lineUserId lineChannelID:(nonnull NSString *)lineChannelId
261
261
  NS_SWIFT_NAME(unlinkLineID(lineUserID:lineChannelID:));
262
262
 
263
+ // Email Channel Integration
264
+ + (void)subscribeEmailChannel:(NSInteger)channelId
265
+ NS_SWIFT_NAME(subscribeEmailChannel(channelID:));
266
+
267
+ + (void)unsubscribeEmailChannel:(NSInteger)channelId
268
+ NS_SWIFT_NAME(unsubscribeEmailChannel(channelID:));
269
+
263
270
  + (void)deepLinkReceived:(nonnull NSURL *)url
264
271
  NS_SWIFT_NAME(deepLinkReceived(url:));
265
272
 
package/www/Repro.js CHANGED
@@ -238,6 +238,14 @@ Repro.prototype.unlinkLineID = function (lineUserId, lineChannelId, successCallb
238
238
  exec(successCallback, errorCallback, "Repro", "unlinkLineID", [lineUserId, lineChannelId]);
239
239
  };
240
240
 
241
+ Repro.prototype.subscribeEmailChannel = function (channelId, successCallback, errorCallback) {
242
+ exec(successCallback, errorCallback, "Repro", "subscribeEmailChannel", [channelId]);
243
+ };
244
+
245
+ Repro.prototype.unsubscribeEmailChannel = function (channelId, successCallback, errorCallback) {
246
+ exec(successCallback, errorCallback, "Repro", "unsubscribeEmailChannel", [channelId]);
247
+ };
248
+
241
249
  Repro.prototype.getNewsFeedsWithLimit = function (limit, successCallback, errorCallback) {
242
250
  exec(successCallback, errorCallback, "Repro", "getNewsFeedsWithLimit", [limit]);
243
251
  };