@purchasely/cordova-plugin-purchasely 6.0.0-rc.1 → 6.0.0-rc.3

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.
@@ -18,7 +18,7 @@
18
18
  <platform name="android">
19
19
  <allow-intent href="market:*" />
20
20
  <preference name="GradlePluginKotlinEnabled" value="true" />
21
- <preference name="GradlePluginKotlinVersion" value="2.1.21" />
21
+ <preference name="GradlePluginKotlinVersion" value="2.3.21" />
22
22
  </platform>
23
23
  <platform name="ios">
24
24
  <allow-intent href="itms:*" />
@@ -19,7 +19,7 @@
19
19
  },
20
20
  "..": {
21
21
  "name": "@purchasely/cordova-plugin-purchasely",
22
- "version": "6.0.0-rc.1",
22
+ "version": "6.0.0-rc.3",
23
23
  "dev": true,
24
24
  "license": "ISC",
25
25
  "devDependencies": {
@@ -36,7 +36,7 @@
36
36
  },
37
37
  "../../purchasely-google": {
38
38
  "name": "@purchasely/cordova-plugin-purchasely-google",
39
- "version": "6.0.0-rc.1",
39
+ "version": "6.0.0-rc.3",
40
40
  "dev": true,
41
41
  "license": "ISC"
42
42
  },
@@ -111,9 +111,9 @@
111
111
  }
112
112
  },
113
113
  "node_modules/android-versions": {
114
- "version": "2.1.2",
115
- "resolved": "https://registry.npmjs.org/android-versions/-/android-versions-2.1.2.tgz",
116
- "integrity": "sha512-JmyCaE2AWe/1ENDv70Bx1hBiVvkUV/JJYnAH6vFGENXDb2DdmCDMO9icoCvGR9TAsRJ/AuszEcIpyHM6qim3SA==",
114
+ "version": "2.2.0",
115
+ "resolved": "https://registry.npmjs.org/android-versions/-/android-versions-2.2.0.tgz",
116
+ "integrity": "sha512-lrad0HHmy9406sSmBHYIetx4n3WMnVVD+HMv7C+YJrByLFGPYWvlM1WcYrYL+e2s1GErvRF85nWsRY7RpwIGLw==",
117
117
  "dev": true,
118
118
  "license": "MIT",
119
119
  "dependencies": {
@@ -236,9 +236,9 @@
236
236
  }
237
237
  },
238
238
  "node_modules/cordova-ios": {
239
- "version": "8.1.0",
240
- "resolved": "https://registry.npmjs.org/cordova-ios/-/cordova-ios-8.1.0.tgz",
241
- "integrity": "sha512-IgVtJIQJBJi+QqqrGjx/moY+M9DqO+RQLeIpHGsZD1Xy+mGflDrp7lunmFYqVchV31b8O/aqE4y4AsDUZip04w==",
239
+ "version": "8.1.1",
240
+ "resolved": "https://registry.npmjs.org/cordova-ios/-/cordova-ios-8.1.1.tgz",
241
+ "integrity": "sha512-fiowa8HeuVd45ZI2fb2az1qDAqlm3H9ruVcXBDUJ3FneMoMmwKKrsrg2tc5L4C8z2ZTZ3d7+NDl/XqJ2M9Ydyw==",
242
242
  "dev": true,
243
243
  "license": "Apache-2.0",
244
244
  "dependencies": {
@@ -804,14 +804,17 @@
804
804
  }
805
805
  },
806
806
  "node_modules/uuid": {
807
- "version": "7.0.3",
808
- "resolved": "https://registry.npmjs.org/uuid/-/uuid-7.0.3.tgz",
809
- "integrity": "sha512-DPSke0pXhTZgoF/d+WSt2QaKMCFSfx7QegxEWT+JOuHF5aWrKEn0G+ztjuJg/gG8/ItK+rbPCD/yNv8yyih6Cg==",
810
- "deprecated": "uuid@10 and below is no longer supported. For ESM codebases, update to uuid@latest. For CommonJS codebases, use uuid@11 (but be aware this version will likely be deprecated in 2028).",
807
+ "version": "11.1.1",
808
+ "resolved": "https://registry.npmjs.org/uuid/-/uuid-11.1.1.tgz",
809
+ "integrity": "sha512-vIYxrBCC/N/K+Js3qSN88go7kIfNPssr/hHCesKCQNAjmgvYS2oqr69kIufEG+O4+PfezOH4EbIeHCfFov8ZgQ==",
811
810
  "dev": true,
811
+ "funding": [
812
+ "https://github.com/sponsors/broofa",
813
+ "https://github.com/sponsors/ctavan"
814
+ ],
812
815
  "license": "MIT",
813
816
  "bin": {
814
- "uuid": "dist/bin/uuid"
817
+ "uuid": "dist/esm/bin/uuid"
815
818
  }
816
819
  },
817
820
  "node_modules/which": {
@@ -22,7 +22,8 @@
22
22
  },
23
23
  "overrides": {
24
24
  "@xmldom/xmldom": "^0.9.8",
25
- "plist": "^3.1.1"
25
+ "plist": "^3.1.1",
26
+ "uuid": "^11.1.1"
26
27
  },
27
28
  "cordova": {
28
29
  "plugins": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@purchasely/cordova-plugin-purchasely",
3
- "version": "6.0.0-rc.1",
3
+ "version": "6.0.0-rc.3",
4
4
  "description": "Purchasely is a solution to ease the integration and boost your In-App Purchases & Subscriptions on the App Store, Google Play Store, Amazon Appstore and Huawei App Gallery.",
5
5
  "cordova": {
6
6
  "id": "@purchasely/cordova-plugin-purchasely",
package/plugin.xml CHANGED
@@ -1,5 +1,5 @@
1
1
  <?xml version='1.0' encoding='utf-8'?>
2
- <plugin id="@purchasely/cordova-plugin-purchasely" version="6.0.0-rc.1" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
2
+ <plugin id="@purchasely/cordova-plugin-purchasely" version="6.0.0-rc.3" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
3
3
  <name>Purchasely</name>
4
4
  <js-module name="Purchasely" src="www/Purchasely.js">
5
5
  <clobbers target="Purchasely" />
@@ -38,7 +38,7 @@
38
38
  <source url="https://github.com/CocoaPods/Specs.git"/>
39
39
  </config>
40
40
  <pods use-frameworks="true">
41
- <pod name="Purchasely" spec="6.0.0-rc.2"/>
41
+ <pod name="Purchasely" spec="6.0.0-rc.3"/>
42
42
  </pods>
43
43
  </podspec>
44
44
  </platform>
@@ -49,10 +49,11 @@
49
49
  </feature>
50
50
  <preference name="AndroidXEnabled" value="true" />
51
51
  <preference name="GradlePluginKotlinEnabled" value="true" />
52
+ <preference name="GradlePluginKotlinVersion" value="2.3.21" />
52
53
  <preference name="GradlePluginKotlinCodeStyle" value="official" />
53
54
  </config-file>
54
55
  <framework src="src/android/build-extras.gradle" custom="true" type="gradleReference" />
55
- <framework src="io.purchasely:core:6.0.0-rc.2" />
56
+ <framework src="io.purchasely:core:6.0.0-rc.3" />
56
57
  <source-file src="src/android/PurchaselyPlugin.kt" target-dir="java/cordova/plugin/purchasely" />
57
58
  </platform>
58
59
  </plugin>
@@ -276,7 +276,7 @@
276
276
  [r setKeepCallbackAsBool:YES];
277
277
  [strongSelf.commandDelegate sendPluginResult:r callbackId:callbackId];
278
278
  }];
279
- builder = [builder onClose:^{
279
+ builder = [builder onCloseRequested:^{
280
280
  CDVPurchasely *strongSelf = weakSelf; if (strongSelf == nil) return;
281
281
  CDVPluginResult *r = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsDictionary:@{@"event": @"closeRequested"}];
282
282
  [r setKeepCallbackAsBool:YES];
@@ -555,13 +555,13 @@
555
555
 
556
556
  // Helpers
557
557
 
558
- // v6: builds a PLYDisplayMode from the JS transition object (see normalizeTransition):
558
+ // v6: builds a PLYTransition from the JS transition object (see normalizeTransition):
559
559
  // { type, dismissible?, height?: { type: 'pixel'|'percentage', value }, backgroundColor? }
560
560
  // (a bare mode string is also tolerated). Objective-C only exposes percentage height for
561
561
  // drawer/popin (pixel height and popin width are Swift-only in the SDK), so those honor a
562
562
  // percentage height + dismissible + background colors; other dimensions are ignored.
563
563
  // Returns nil for an unknown/absent value so the backend-defined default is honored.
564
- - (PLYDisplayMode * _Nullable) displayModeFromTransition:(id) transition {
564
+ - (PLYTransition * _Nullable) displayModeFromTransition:(id) transition {
565
565
  NSDictionary *map = [transition isKindOfClass:[NSDictionary class]] ? transition : nil;
566
566
  NSString *type = map != nil ? map[@"type"] : ([transition isKindOfClass:[NSString class]] ? transition : nil);
567
567
  if (![type isKindOfClass:[NSString class]]) {
@@ -593,17 +593,17 @@
593
593
  }
594
594
 
595
595
  if ([type isEqualToString:@"fullScreen"]) {
596
- return [PLYDisplayMode fullScreen];
596
+ return [PLYTransition fullScreen];
597
597
  } else if ([type isEqualToString:@"modal"]) {
598
- return [PLYDisplayMode modalWithDismissible:dismissible];
598
+ return [PLYTransition modalWithDismissible:dismissible];
599
599
  } else if ([type isEqualToString:@"push"]) {
600
- return [PLYDisplayMode push];
600
+ return [PLYTransition push];
601
601
  } else if ([type isEqualToString:@"inlinePaywall"]) {
602
- return [PLYDisplayMode inlinePaywall];
602
+ return [PLYTransition inlinePaywall];
603
603
  } else if ([type isEqualToString:@"drawer"]) {
604
- return [[PLYDisplayMode alloc] initWithType:PLYDisplayModeTypeDrawer heightPercentage:heightPercentage backgroundColors:backgroundColors dismissible:dismissible];
604
+ return [[PLYTransition alloc] initWithType:PLYTransitionTypeDrawer heightPercentage:heightPercentage backgroundColors:backgroundColors dismissible:dismissible];
605
605
  } else if ([type isEqualToString:@"popin"]) {
606
- return [[PLYDisplayMode alloc] initWithType:PLYDisplayModeTypePopin heightPercentage:heightPercentage backgroundColors:backgroundColors dismissible:dismissible];
606
+ return [[PLYTransition alloc] initWithType:PLYTransitionTypePopin heightPercentage:heightPercentage backgroundColors:backgroundColors dismissible:dismissible];
607
607
  }
608
608
  return nil;
609
609
  }
@@ -736,8 +736,8 @@
736
736
  }
737
737
  id<PLYPresentation> presentation = info.presentation;
738
738
  if (presentation != nil) {
739
- if (presentation.id != nil) {
740
- [infosResult setObject:presentation.id forKey:@"presentationId"];
739
+ if (presentation.screenId != nil) {
740
+ [infosResult setObject:presentation.screenId forKey:@"presentationId"];
741
741
  }
742
742
  if (presentation.placementId != nil) {
743
743
  [infosResult setObject:presentation.placementId forKey:@"placementId"];
@@ -1176,7 +1176,7 @@ static BOOL PLYPresentationActionFromString(NSString *kind, PLYPresentationActio
1176
1176
  [r setKeepCallbackAsBool:YES];
1177
1177
  [strongSelf.commandDelegate sendPluginResult:r callbackId:callbackId];
1178
1178
  };
1179
- presentationLoaded.onClose = ^{
1179
+ presentationLoaded.onCloseRequested = ^{
1180
1180
  CDVPurchasely *strongSelf = weakSelf; if (strongSelf == nil) return;
1181
1181
  CDVPluginResult *r = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK messageAsDictionary:@{@"event": @"closeRequested"}];
1182
1182
  [r setKeepCallbackAsBool:YES];
@@ -1224,7 +1224,7 @@ static BOOL PLYPresentationActionFromString(NSString *kind, PLYPresentationActio
1224
1224
 
1225
1225
  - (id<PLYPresentation>) findPresentationLoadedFor:(NSString * _Nullable) presentationId {
1226
1226
  for (id<PLYPresentation> presentationLoaded in self.presentationsLoaded) {
1227
- if ([presentationLoaded.id isEqualToString: presentationId]) {
1227
+ if ([presentationLoaded.screenId isEqualToString: presentationId]) {
1228
1228
  return presentationLoaded;
1229
1229
  }
1230
1230
  }
@@ -1234,7 +1234,7 @@ static BOOL PLYPresentationActionFromString(NSString *kind, PLYPresentationActio
1234
1234
  - (NSInteger) findIndexPresentationLoadedFor:(NSString * _Nullable) presentationId {
1235
1235
  NSInteger index = 0;
1236
1236
  for (id<PLYPresentation> presentationLoaded in self.presentationsLoaded) {
1237
- if ([presentationLoaded.id isEqualToString: presentationId]) {
1237
+ if ([presentationLoaded.screenId isEqualToString: presentationId]) {
1238
1238
  return index;
1239
1239
  }
1240
1240
  index++;
@@ -1269,8 +1269,8 @@ static BOOL PLYPresentationActionFromString(NSString *kind, PLYPresentationActio
1269
1269
 
1270
1270
  if (presentation != nil) {
1271
1271
 
1272
- if (presentation.id != nil) {
1273
- [presentationResult setObject:presentation.id forKey:@"id"];
1272
+ if (presentation.screenId != nil) {
1273
+ [presentationResult setObject:presentation.screenId forKey:@"id"];
1274
1274
  }
1275
1275
 
1276
1276
  if (presentation.placementId != nil) {
package/www/Purchasely.js CHANGED
@@ -56,7 +56,7 @@ exports.start = function (options, success, error) {
56
56
  var opts = options || {};
57
57
  var cordovaSdkVersion = cordova.define.moduleMap['cordova/plugin_list'].exports['metadata']['cordova-plugin-purchasely']
58
58
  if(!cordovaSdkVersion) {
59
- cordovaSdkVersion = "6.0.0-rc.1";
59
+ cordovaSdkVersion = "6.0.0-rc.3";
60
60
  }
61
61
  opts.sdkVersion = cordovaSdkVersion;
62
62
  exec(success, error, 'Purchasely', 'start', [opts]);