shadcn.io is not affiliated with official shadcn/ui
Top Performer Awards Block for React
Three award winners on shared hairlines, each with initials, a name, the award taken and two figures set against a team median, with the difference in words and a small bar.
Installation
Overview
A top performers block for React with Base UI. A centred header sits over three cells that share their hairlines, three across from lg and one column below. Each cell is a person (initials in a circle, no photographs, name and role), the award they took as an outlined badge and two figures. Each figure is set against a team median: the person's value in large type, the difference worked out in words ("37% above the median"), a small bar on a track with a tick where the median falls, and the median itself in text. The bars are drawings; every figure is also in text. The page's rails and top rule come from the Guides spine. It's built from Guides, Avatar and Badge, with CSS transitions for the entrance. The people, awards and figures are made up for the example.
FAQ
How do I change the performers and their figures?
Edit PERFORMERS at the top of the file. Each person has a name, a role, an award and two metrics, each with a label, the person's value, the team median and a unit ("%" or nothing). The percentage above the median, the bar's length and the tick's place are all worked out from those numbers, so nothing else needs a change.
How is the difference worked out?
It is the person's value minus the median, divided by the median, rounded to a whole percent: 41 deals against a median of 30 is 37% above. It is relative to the median, not a number of points, and the block says so in its words. If lower is better for a measure of yours, change aboveOf and its sentence.
What do the bars show?
A bar runs from zero to the person's value on a track that reaches a tenth past the larger of the value and the median. The tick marks the median. The bars are drawings hidden from assistive technology: the value, the difference and the median are all in text beside them.
Does it work in a right-to-left layout?
Yes. The cells and text follow the page direction. The bars and ticks stay in a left-to-right box, so a longer bar always means a bigger value, and every figure sits in a bidirectional-isolation element so it keeps its order.
Related
- Pro
Month Picker Awards
People and teamsA prize that honours one person a month: a strip of twelve month cells with each winner's initials, and the chosen month's profile with the citation, three facts and the number of colleagues who nominated them.
- Pro
Team Achievement Awards
People and teamsThree team award cells set apart with overshoot corners: the award, the team, a group of initials avatars with a count of the rest, one line on what the team did and the teams it shared the award with.
- Pro
Medal Count Awards
Rankings and scoresAn Olympic-style medals table for a league-tables service: seven product lines ranked by gold, then silver, with drawn medal heads, a total, a stated ranking rule and a top-line callout.
- Pro
Trend Arrows Awards
Lists and tablesA ruled table for an investing app comparing five award measures this year and last year, with the change as an arrow icon and words (up 4, flat, down 1) so a change is never told by colour alone.
- Pro
Badge Tracker Team
RecognitionOne person's eight badges in hairline cells, earned ones solid and locked ones dashed outlines, beside the person and a bar to the next badge: 7 of 10 reviews to Reviewer II.
- 213Pro
Three Step Podium Awards
Rankings and scoresA podium of three steps in the order 2, 1, 3, their heights in proportion to rank, a drawn medal on each and the award, programme and year above it.