shadcn.io is not affiliated with official shadcn/ui
Rep Attainment Table Stats Block for React
A quota table for a sales team, each rep's attainment bar beside a badge for the change on last week.
Installation
Overview
An attainment table for React with Base UI. Quotely, a quota desk, lists six reps in a real table: the rep, an attainment Progress bar with the closed and quota amounts, and a Badge for the change on last week, in points. A rise is a filled badge with an up arrow, a fall an outline badge with a down arrow, and a flat week an outline badge with a dash. All three are the text colour. The heading's team percent and the count of reps ahead of last week are summed from the same rows. The block has no state: it's Guides, Table, Progress, Badge and CSS transitions for the entrance. For the numbers section of a sales page.
FAQ
How do I change the reps?
Edit REPS at the top of the file. Each rep is an id, a name, closed and quota in dollars, and last, last week's whole percent. This week's percent is the rounded share of quota, and the pill is that percent minus last. The team percent is everyone's closed dollars over everyone's quota.
How does the badge decide its look?
From the sign of the point change. Above zero it is filled, foreground on the background colour, with an arrow toward the end and up. Below zero it is an outline with an arrow toward the end and down. Zero is an outline with a dash, so a flat week is not drawn as a fall. The number keeps its sign, and a minus is the true minus sign.
Why isn't a rise green and a fall red?
Ahead of last week is not always the point of the row: the bar already shows how close the rep is to quota, and the arrow shows the week. Colouring the pill would argue, on a churn-style number, the wrong way. Direction is the arrow and the sign. The sample has three reps ahead, two behind and one flat, and the heading counts only the three ahead.
How is the table named?
A caption, hidden visually, names it with the rep count and says the pills are against last week. The column headers are column headers, and each rep's name is a row header.
Related
- Pro
Progress Bar List Stats
Goals and progressSix launch milestones in one hairline frame, each with its owner and due week, its count against the target, the percentage and a Progress bar, under a headline that counts the milestones done.
- Pro
Weekly Pace Sparkline Stats
Goals and progressWeekly pacing for a sales team, each line of business with its quarter bar and an eight-week sparkline of that week's bookings.
- Pro
Delta Pill KPI Tiles Stats
KPI bands and tilesFour raised KPI tiles for a checkout analytics tool, each with its change as a pill: filled for a rise, outlined for a fall and muted for none, with an arrow or a dash and a sign.
- Pro
Dense Checklist Progress Stats
Goals and progressA dense onboarding checklist for a customer-success tool, ten steps in a three-part row beside a summary of how far new accounts get.
- Pro
Quota Tile Grid Stats
Goals and progressSix plan-quota tiles (seats, API calls, storage, projects, bandwidth, builds) with used against limit, a bar, what is left and a reset hint in days; a tile at 90% or more gets a solid bar and an Upgrade link badge.
- Pro
Revenue Funnel Stats
FunnelsA funnel as a real table for a sales team's pipeline: stage, deals, step conversion and value, each number with a thin bar to the scale of its column, and the overall conversion rolling in the header.