@umituz/react-native-subscription 2.22.2 → 2.22.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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umituz/react-native-subscription",
|
|
3
|
-
"version": "2.22.
|
|
3
|
+
"version": "2.22.3",
|
|
4
4
|
"description": "Complete subscription management with RevenueCat, paywall UI, and credits system for React Native apps",
|
|
5
5
|
"main": "./src/index.ts",
|
|
6
6
|
"types": "./src/index.ts",
|
|
@@ -31,7 +31,7 @@ export const SubscriptionDetailScreen: React.FC<
|
|
|
31
31
|
SubscriptionDetailScreenProps
|
|
32
32
|
> = ({ config }) => {
|
|
33
33
|
const tokens = useAppDesignTokens();
|
|
34
|
-
const showCredits = config.
|
|
34
|
+
const showCredits = config.credits && config.credits.length > 0;
|
|
35
35
|
const showUpgradePrompt = !config.isPremium && config.upgradePrompt;
|
|
36
36
|
|
|
37
37
|
const styles = useMemo(
|
|
@@ -68,8 +68,8 @@ export const SubscriptionDetailScreen: React.FC<
|
|
|
68
68
|
) : undefined
|
|
69
69
|
}
|
|
70
70
|
>
|
|
71
|
-
{
|
|
72
|
-
|
|
71
|
+
<View style={styles.cardsContainer}>
|
|
72
|
+
{config.isPremium && (
|
|
73
73
|
<SubscriptionHeader
|
|
74
74
|
statusType={config.statusType}
|
|
75
75
|
isPremium={config.isPremium}
|
|
@@ -79,20 +79,20 @@ export const SubscriptionDetailScreen: React.FC<
|
|
|
79
79
|
daysRemaining={config.daysRemaining}
|
|
80
80
|
translations={config.translations}
|
|
81
81
|
/>
|
|
82
|
+
)}
|
|
82
83
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
showUpgradePrompt && (
|
|
84
|
+
{showCredits && (
|
|
85
|
+
<CreditsList
|
|
86
|
+
credits={config.credits!}
|
|
87
|
+
title={
|
|
88
|
+
config.translations.usageTitle || config.translations.creditsTitle
|
|
89
|
+
}
|
|
90
|
+
description={config.translations.creditsResetInfo}
|
|
91
|
+
remainingLabel={config.translations.remainingLabel}
|
|
92
|
+
/>
|
|
93
|
+
)}
|
|
94
|
+
|
|
95
|
+
{showUpgradePrompt && (
|
|
96
96
|
<UpgradePrompt
|
|
97
97
|
title={config.upgradePrompt!.title}
|
|
98
98
|
subtitle={config.upgradePrompt!.subtitle}
|
|
@@ -100,8 +100,8 @@ export const SubscriptionDetailScreen: React.FC<
|
|
|
100
100
|
upgradeButtonLabel={config.translations.upgradeButton}
|
|
101
101
|
onUpgrade={config.onUpgrade}
|
|
102
102
|
/>
|
|
103
|
-
)
|
|
104
|
-
|
|
103
|
+
)}
|
|
104
|
+
</View>
|
|
105
105
|
|
|
106
106
|
<View style={styles.spacer} />
|
|
107
107
|
</ScreenLayout>
|