About
Multi-variant SaaS pricing plan suite with five distinct layouts, Pro UI segmented pill tabs, floating header cards, and standard shadcn tokens.
Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Minimal Pricing Plan to your project and fits it to your theme.
Code
How Minimal Pricing Plan is used: the demo's code. The component's own source comes with a free account.
Usage.tsx
import { useState, useEffect } from "react";
import MinimalPricingPlan, { defaultTiers } from "@/components/ui/minimal-pricing-plan";
import { Sun, Moon } from "lucide-react";
const PROFILE_REFERRAL_URL = "https://21st.dev/@wrapcoders?ref=mdruhulhasan";
export default function MinimalPricingPlanDemo() {
const [isDark, setIsDark] = useState<boolean>(() => {
if (typeof window !== "undefined") {
const params = new URLSearchParams(window.location.search);
const themeParam = params.get("theme");
if (themeParam === "dark") return true;
if (themeParam === "light") return false;
return document.documentElement.classList.contains("dark");
}
return false;
});
useEffect(() => {
if (typeof document !== "undefined") {
if (isDark) {
document.documentElement.classList.add("dark");
} else {
document.documentElement.classList.remove("dark");
}
}
}, [isDark]);
const toggleTheme = () => {
setIsDark((prev) => !prev);
};
return (
<div className="relative min-h-screen w-full bg-background text-foreground transition-colors duration-200">
<header className="sticky top-0 z-30 w-full border-b border-border/40 bg-background/80 backdrop-blur-md">
<div className="mx-auto flex max-w-6xl items-center justify-between px-4 py-3 sm:px-6 lg:px-8">
<div className="flex items-center gap-2">
<span className="text-xs font-semibold tracking-wide text-foreground uppercase font-mono">
Transparent Pricing
</span>
<span className="rounded-full bg-purple-500/10 text-purple-600 dark:text-purple-400 border border-purple-500/20 px-2 py-0.5 text-[10px] font-mono font-medium">
3 Tier Inset
</span>
</div>
<div className="flex items-center gap-2">
<a
href={PROFILE_REFERRAL_URL}
target="_blank"
rel="noopener noreferrer"
className="inline-flex h-8 items-center gap-1.5 rounded-full border border-primary/30 bg-primary/10 px-3 text-xs font-medium text-primary transition-colors hover:bg-primary/20"
>
<span>Explore on 21st.dev</span>
<span className="text-[10px] opacity-75">↗</span>
</a>
<button
type="button"
onClick={toggleTheme}
className="inline-flex h-8 items-center gap-1.5 rounded-full border border-border bg-muted/50 px-3 text-xs font-medium text-foreground transition-colors hover:bg-muted"
aria-label={`Switch to ${isDark ? "light" : "dark"} mode`}
>
{isDark ? (
<>
<Sun className="h-3.5 w-3.5 text-amber-400" />
<span>Light</span>
</>
) : (
<>
<Moon className="h-3.5 w-3.5 text-muted-foreground" />
<span>Dark</span>
</>
)}
</button>
</div>
</div>
</header>
<main className="w-full pb-16">
<MinimalPricingPlan
badgeHref={PROFILE_REFERRAL_URL}
footerHref={PROFILE_REFERRAL_URL}
tiers={defaultTiers.map((tier) => ({
...tier,
cta: { ...tier.cta, href: PROFILE_REFERRAL_URL },
}))}
/>
</main>
<footer className="w-full border-t border-border/40 py-6 text-center text-xs text-muted-foreground">
<a
href={PROFILE_REFERRAL_URL}
target="_blank"
rel="noopener noreferrer"
className="hover:text-foreground transition-colors inline-flex items-center gap-1"
>
Explore more components on 21st.dev ↗
</a>
</footer>
</div>
);
}
















