Billing Member Usage Breakdown
A list of team members with their storage or resource usage, a small progress bar against their allotted limit, and the cost that usage generated. Built for enterprise billing portals and team admin screens where an account owner needs to see at a glance who's using the most and what it's costing.
Docs
Installation
A real shadcn registry command, not a copy-paste stand-in: it fetches this block plus its avatar dependencies and any missing npm packages, and installs them straight into your project.
npx shadcn add https://staaarter.com/r/billing-member-usage-breakdown.jsonPrefer not to use the CLI? Copy the source from the Code toggle above into src/components/blocks/billing/billing73.tsx instead.
Usage
The file also exports billing73Demo, the exact props behind the preview above. Spread it to get a working section in one line, then replace it with your own data.
import { Billing73, billing73Demo } from "@/components/blocks/billing/billing73"; export default function Page() { return <Billing73 {...billing73Demo} />; }
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| title | string | "Member usage" | Heading shown above the member list. |
| description | string | none | Optional one-line note under the heading. |
| unit | string | "GB" | Unit label shown after each member's usage numbers. |
| members | MemberUsageRow[] | none | Rows rendered in the order given, one per team member. |
| totalCost | string | none | Optional total shown in the header, for example the combined cost of all members this cycle. |
| className | string | none | Extra classes for the outer container. |
Types
interface MemberUsageRow { id: string; name: string; email: string; avatarSrc?: string; role?: string; usage: number; limit: number; cost: string; }
Behavior notes
- Each member's usage bar fills to usage / limit as a percentage, capped at 100% so it never overflows the track even if usage exceeds the limit.
- A member whose usage exceeds their limit gets a destructive-colored bar instead of the default primary color, there's no separate alert or badge for it.
- Avatars fall back to two-letter initials, derived from the first letter of up to the first two words in the member's name, whenever avatarSrc is missing or fails to load.
- Email and role are combined into a single truncating line so long addresses don't wrap and break row height.
- The optional totalCost in the header is a plain string you compute and pass in, the component doesn't sum the individual member costs itself.
Frequently asked questions
More Billing Blocks
View all →Billing Invoice List
Invoice history table with status badges, formatted amounts, and a per-row download link, built with shadcn/ui and Tailwind CSS.
Billing Failed Payment Alert
High-contrast failed-payment alert with a message, a retry button, and an optional update-payment-method button, built with shadcn/ui and Tailwind CSS.
Billing Credit Balance
Compact credit balance card with a large total, an optional purchased-versus-promotional breakdown, a low-balance notice, and a top-up button.
Billing Payment Methods
A saved payment method list for React and Next.js with brand icons, a default badge, near-expiry warnings, and remove/set-default actions per row.
Billing Add Card
A card entry form for React and Next.js with auto-formatted fields, internal brand detection, and per-field validation feedback built with shadcn/ui and Tailwind CSS.
Billing Coupon Code
An inline promo code input for React and Next.js with a simulated loading state, an applied summary showing the discount amount, and an invalid-code message.