@umituz/react-native-subscription 2.27.55 → 2.27.56
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 +3 -2
- package/src/application/ports/ISubscriptionService.ts +0 -5
- package/src/domains/config/domain/index.ts +2 -2
- package/src/domains/config/domain/value-objects/Config.ts +1 -1
- package/src/domains/config/index.ts +1 -1
- package/src/domains/paywall/components/FeatureList.tsx +1 -1
- package/src/domains/paywall/components/PaywallContainer.types.ts +1 -1
- package/src/domains/paywall/components/PaywallFeatures.tsx +1 -1
- package/src/domains/paywall/components/PaywallFooter.tsx +1 -1
- package/src/domains/paywall/components/PaywallModal.tsx +1 -1
- package/src/domains/paywall/hooks/usePaywallTranslations.ts +1 -1
- package/src/domains/paywall/index.ts +1 -1
- package/src/infrastructure/services/SubscriptionService.ts +0 -6
- package/src/utils/index.ts +0 -4
- package/src/domains/config/domain/entities/index.ts +0 -1
- package/src/domains/config/domain/value-objects/index.ts +0 -1
- package/src/domains/config/utils/index.ts +0 -1
- package/src/domains/paywall/entities/index.ts +0 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umituz/react-native-subscription",
|
|
3
|
-
"version": "2.27.
|
|
3
|
+
"version": "2.27.56",
|
|
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",
|
|
@@ -40,7 +40,8 @@
|
|
|
40
40
|
"react": ">=18.2.0",
|
|
41
41
|
"react-native": ">=0.74.0",
|
|
42
42
|
"react-native-purchases": ">=7.0.0",
|
|
43
|
-
"react-native-safe-area-context": ">=5.0.0"
|
|
43
|
+
"react-native-safe-area-context": ">=5.0.0",
|
|
44
|
+
"zustand": ">=5.0.0"
|
|
44
45
|
},
|
|
45
46
|
"devDependencies": {
|
|
46
47
|
"@expo/vector-icons": "^15.0.3",
|
|
@@ -6,11 +6,6 @@
|
|
|
6
6
|
import type { SubscriptionStatus } from '../../domain/entities/SubscriptionStatus';
|
|
7
7
|
|
|
8
8
|
export interface ISubscriptionService {
|
|
9
|
-
/**
|
|
10
|
-
* Get current subscription status
|
|
11
|
-
*/
|
|
12
|
-
getStatus(userId: string): Promise<SubscriptionStatus | null>;
|
|
13
|
-
|
|
14
9
|
/**
|
|
15
10
|
* Activate a subscription
|
|
16
11
|
*/
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from "./entities";
|
|
2
|
-
export * from "./value-objects";
|
|
1
|
+
export * from "./entities/Plan";
|
|
2
|
+
export * from "./value-objects/Config";
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
import React from "react";
|
|
7
7
|
import { View, StyleSheet } from "react-native";
|
|
8
8
|
import { FeatureItem } from "./FeatureItem";
|
|
9
|
-
import type { SubscriptionFeature } from '../entities';
|
|
9
|
+
import type { SubscriptionFeature } from '../entities/types';
|
|
10
10
|
|
|
11
11
|
interface FeatureListProps {
|
|
12
12
|
features: SubscriptionFeature[];
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
import type { ImageSourcePropType } from "react-native";
|
|
7
|
-
import type { PaywallTranslations, PaywallLegalUrls, SubscriptionFeature } from "../entities";
|
|
7
|
+
import type { PaywallTranslations, PaywallLegalUrls, SubscriptionFeature } from "../entities/types";
|
|
8
8
|
import type { PurchaseSource, PackageAllocationMap } from "../../../domain/entities/Credits";
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { View } from "react-native";
|
|
3
3
|
import { AtomicText, AtomicIcon, useAppDesignTokens } from "@umituz/react-native-design-system";
|
|
4
|
-
import type { SubscriptionFeature } from "../entities";
|
|
4
|
+
import type { SubscriptionFeature } from "../entities/types";
|
|
5
5
|
import { paywallModalStyles as styles } from "./PaywallModal.styles";
|
|
6
6
|
|
|
7
7
|
export const PaywallFeatures: React.FC<{ features: SubscriptionFeature[] }> = ({ features }) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { View, TouchableOpacity } from "react-native";
|
|
3
3
|
import { AtomicText, useAppDesignTokens } from "@umituz/react-native-design-system";
|
|
4
|
-
import type { PaywallTranslations, PaywallLegalUrls } from "../entities";
|
|
4
|
+
import type { PaywallTranslations, PaywallLegalUrls } from "../entities/types";
|
|
5
5
|
import { paywallModalStyles as styles } from "./PaywallModal.styles";
|
|
6
6
|
|
|
7
7
|
interface PaywallFooterProps {
|
|
@@ -8,7 +8,7 @@ import { BaseModal, useAppDesignTokens, AtomicText, AtomicIcon, AtomicSpinner }
|
|
|
8
8
|
import { Image } from "expo-image";
|
|
9
9
|
import type { PurchasesPackage } from "react-native-purchases";
|
|
10
10
|
import { PlanCard } from "./PlanCard";
|
|
11
|
-
import type { SubscriptionFeature, PaywallTranslations, PaywallLegalUrls } from "../entities";
|
|
11
|
+
import type { SubscriptionFeature, PaywallTranslations, PaywallLegalUrls } from "../entities/types";
|
|
12
12
|
import { paywallModalStyles as styles } from "./PaywallModal.styles";
|
|
13
13
|
import { PaywallFeatures } from "./PaywallFeatures";
|
|
14
14
|
import { PaywallFooter } from "./PaywallFooter";
|
|
@@ -55,12 +55,6 @@ export class SubscriptionService implements ISubscriptionService {
|
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
// Alias for ISubscriptionService interface compliance
|
|
59
|
-
async getStatus(userId: string): Promise<SubscriptionStatus | null> {
|
|
60
|
-
const status = await this.getSubscriptionStatus(userId);
|
|
61
|
-
return status.isPremium ? status : null;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
58
|
async isPremium(userId: string): Promise<boolean> {
|
|
65
59
|
const status = await this.getSubscriptionStatus(userId);
|
|
66
60
|
return this.repository.isSubscriptionValid(status);
|
package/src/utils/index.ts
CHANGED
|
@@ -9,7 +9,3 @@ export * from "./priceUtils";
|
|
|
9
9
|
export * from "./tierUtils";
|
|
10
10
|
export * from "./types";
|
|
11
11
|
export * from "./validation";
|
|
12
|
-
|
|
13
|
-
// Logger (infrastructure utility re-exported for convenience)
|
|
14
|
-
export { Logger, LOG_CATEGORY } from "../infrastructure/utils/Logger";
|
|
15
|
-
export type { LogLevel, LogCategory, LogContext } from "../infrastructure/utils/Logger";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./Plan";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./Config";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./helpers";
|