Subscription
A beautiful subscription card component with popular plan highlighting and customizable theme support
Zezo Subscription Component
Start-Up Plan
₹99 /per month
FEATURES
- Access to basic content
- Ad-supported streaming
- Standard Definition quality
- Watch on 1 device
Enterprise Plan
₹199 /per month
FEATURES
- Access to all content
- No ads
- Full HD and 4K streaming
- Offline download
- Watch on 4 devices simultaneously
- Exclusive content access
📦 Installation
pnpm dlx shadcn@latest add https://zezo-ui.vercel.app/r/zezo-subscription.json
💡 Usage Example
import Subscription from "@/components/zezo/subscription/subscription";
import type { ISubscriptionData } from "@zezosoft/zezo-ott-api-client";
// Single plan card
<Subscription
plan={{
_id: "premium",
name: "Premium Plan",
price: 199,
points: ["HD Streaming", "No Ads", "Download Support"],
isPopular: true
}}
onSelect={(plan) => {
console.log("Selected plan:", plan.name);
// Handle plan selection
}}
/>
// Render multiple plans
{plans.map((plan) => (
<Subscription
key={plan._id}
plan={plan}
onSelect={(plan) => handlePlanSelect(plan)}
/>
))}📘 Props
| Prop | Type | Required | Description |
|---|---|---|---|
| plan | ISubscriptionData | Yes | Single subscription plan data object |
| onSelect | (plan: ISubscriptionData) => void | Optional | Callback function called when "Get Started" button is clicked |
🧩 ISubscriptionData Interface
The component uses the ISubscriptionData interface from @zezosoft/zezo-ott-api-client. Key properties:
interface ISubscriptionData {
_id: string; // Required: Unique plan identifier
name: string; // Required: Plan name (e.g., "Premium Plan")
price: number; // Required: Plan price (displayed as ₹price)
points?: string[]; // Optional: Array of feature points
isPopular?: boolean | string; // Optional: Marks plan as popular (shows badge)
description?: string; // Optional: Plan description
duration?: string; // Optional: Plan duration
currency?: string[]; // Optional: Supported currencies
maxVideoQuality?: string; // Optional: Maximum video quality
// ... other optional fields
}✨ Features
💳 Plan Card
Displays plan name, price, and features
⭐ Popular Badge
Highlights popular plans with badge and special styling
✅ Feature List
Shows plan features with checkmark icons
🎨 Theme Integration
Uses dynamic theme colors for buttons and badges
🌓 Dark Mode
Automatic theme support
🎯 Popular Styling
Popular plans get gradient background and primary button
📱 Responsive
Mobile-first responsive design
🔄 Click Handler
Optional callback for plan selection
