react-native-purchases-ui 9.4.0 → 9.4.2
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/RNPaywalls.podspec +1 -1
- package/android/build.gradle +2 -2
- package/android/src/main/java/com/revenuecat/purchases/react/ui/BasePaywallViewManager.kt +3 -1
- package/android/src/main/java/com/revenuecat/purchases/react/ui/RNCustomerCenterModule.kt +1 -1
- package/android/src/main/java/com/revenuecat/purchases/react/ui/RNPaywallsModule.kt +1 -1
- package/package.json +3 -3
package/RNPaywalls.podspec
CHANGED
@@ -17,6 +17,6 @@ Pod::Spec.new do |spec|
|
|
17
17
|
spec.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES' }
|
18
18
|
|
19
19
|
spec.dependency "React-Core"
|
20
|
-
spec.dependency "PurchasesHybridCommonUI", '17.
|
20
|
+
spec.dependency "PurchasesHybridCommonUI", '17.6.0'
|
21
21
|
spec.swift_version = '5.7'
|
22
22
|
end
|
package/android/build.gradle
CHANGED
@@ -59,7 +59,7 @@ android {
|
|
59
59
|
minSdkVersion getExtOrIntegerDefault("minSdkVersion")
|
60
60
|
targetSdkVersion getExtOrIntegerDefault("targetSdkVersion")
|
61
61
|
versionCode 1
|
62
|
-
versionName '9.4.
|
62
|
+
versionName '9.4.2'
|
63
63
|
}
|
64
64
|
|
65
65
|
buildTypes {
|
@@ -91,7 +91,7 @@ dependencies {
|
|
91
91
|
//noinspection GradleDynamicVersion
|
92
92
|
implementation "com.facebook.react:react-native:+"
|
93
93
|
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
94
|
-
implementation 'com.revenuecat.purchases:purchases-hybrid-common-ui:17.
|
94
|
+
implementation 'com.revenuecat.purchases:purchases-hybrid-common-ui:17.6.0'
|
95
95
|
implementation 'androidx.compose.ui:ui-android:1.5.4'
|
96
96
|
implementation "androidx.appcompat:appcompat:1.6.1"
|
97
97
|
}
|
@@ -79,7 +79,9 @@ internal abstract class BasePaywallViewManager<T : View> : SimpleViewManager<T>(
|
|
79
79
|
val offeringMap = options.getDynamic(OPTION_OFFERING).asMap();
|
80
80
|
|
81
81
|
// this is a workaround for the fact that getDynamic doesn't work with null values
|
82
|
-
|
82
|
+
// Null check required for version 0.81 of RN where `asMap()` returns optional
|
83
|
+
@Suppress("UNNECESSARY_SAFE_CALL")
|
84
|
+
val offeringIdentifier = offeringMap?.getString(OFFERING_IDENTIFIER)
|
83
85
|
if (offeringIdentifier == null) {
|
84
86
|
return
|
85
87
|
}
|
@@ -63,7 +63,7 @@ internal class RNCustomerCenterModule(
|
|
63
63
|
fun presentCustomerCenter(
|
64
64
|
promise: Promise
|
65
65
|
) {
|
66
|
-
currentActivity?.let {
|
66
|
+
reactApplicationContext.currentActivity?.let {
|
67
67
|
customerCenterPromise = promise
|
68
68
|
presentCustomerCenterFromActivity(it)
|
69
69
|
} ?: run {
|
@@ -23,7 +23,7 @@ internal class RNPaywallsModule(
|
|
23
23
|
|
24
24
|
private val currentFragmentActivity: FragmentActivity?
|
25
25
|
get() {
|
26
|
-
return when (val currentActivity = currentActivity) {
|
26
|
+
return when (val currentActivity = reactApplicationContext.currentActivity) {
|
27
27
|
is FragmentActivity -> currentActivity
|
28
28
|
else -> {
|
29
29
|
Log.e(NAME, "RevenueCat paywalls require applications to use a FragmentActivity")
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "react-native-purchases-ui",
|
3
3
|
"title": "React Native Purchases UI",
|
4
|
-
"version": "9.4.
|
4
|
+
"version": "9.4.2",
|
5
5
|
"description": "React Native in-app purchases and subscriptions made easy. Supports iOS and Android.",
|
6
6
|
"main": "lib/commonjs/index",
|
7
7
|
"module": "lib/module/index",
|
@@ -77,7 +77,7 @@
|
|
77
77
|
"peerDependencies": {
|
78
78
|
"react": "*",
|
79
79
|
"react-native": ">= 0.73.0",
|
80
|
-
"react-native-purchases": "9.4.
|
80
|
+
"react-native-purchases": "9.4.2",
|
81
81
|
"react-native-web": "*"
|
82
82
|
},
|
83
83
|
"peerDependenciesMeta": {
|
@@ -122,6 +122,6 @@
|
|
122
122
|
]
|
123
123
|
},
|
124
124
|
"dependencies": {
|
125
|
-
"@revenuecat/purchases-typescript-internal": "17.
|
125
|
+
"@revenuecat/purchases-typescript-internal": "17.6.0"
|
126
126
|
}
|
127
127
|
}
|