Skip to content
shadcn.io

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.

Framework
UI library

Preview

Preview width

Installation

Part of Pro
Pro unlocks the code and one-line install of every Pro button and text effect, plus the MCP for your AI editor.
Have Pro already? Sign in to open it.Opens here as soon as you're Pro.

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.

What happens on a phone?

Every column stays. The table is fixed-layout: the name takes about 38% and truncates, the change takes a narrow column so "vs last week" can wrap, and the bar keeps the rest. The closed and quota amounts wrap onto more than one line rather than pushing the table sideways.

What moves?

The header and the table fade up once. The bars don't grow, and the badges don't pop in on their own. With reduced motion the fade is off. Hovering a row doesn't tint it, so the filled badge stays as readable as it is at rest.

  • Pro

    Progress Bar List Stats

    Goals and progress

    Six 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 progress

    Weekly 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 tiles

    Four 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

    A 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 progress

    Six 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

    A 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.