shadcn.io is not affiliated with official shadcn/ui
Metric Hero Strip Features Block for React
Four metric-over-feature columns for a data-pipeline tool: a giant tabular figure and label, then the feature that makes it true, in one divided band under a centred header.
Installation
Overview
A metric-led features section for React with Base UI. A centred header says "The numbers first, then why they hold". Under it, one band runs from rail to rail, ruled across the top with a + on each rail and divided into four columns by shared hairlines (two by two before lg). Each column leads with a giant tabular figure (99.99%, 2.4B, 40 ms, 300+) and a label, and under a hairline the feature that makes the number true, a heading and one sentence. It's built from Sliding Number and Guides, with a CSS transition for the entrance. It has no button on purpose: the numbers are the pitch. For infrastructure and data platforms that want proof first and features second.
FAQ
How do I change the metrics?
Edit METRICS at the top of the file: each is a value, how many decimals it shows, a unit that follows it, a label, and the feature and description under the hairline. Keep four, so the band fills its rows at two and four across.
Do the numbers count up?
They show their value at once, and the digits roll like an odometer only if the value changes. Counting up from zero when the band scrolls into view is one prop (trigger="view"), but the page then shows zeros before JavaScript runs, and in a screenshot, so this block leaves it off.
What does a screen reader hear?
For each column, the figure and its unit in one piece ("99.99 %"), the label, then the feature's heading and sentence. The figure keeps its real text for assistive technology while the rolling digits are decoration.
Why are the figures wrapped in a bdi element?
A figure with a unit or a sign ("300+", "40 ms") would otherwise reorder in a right-to-left layout and show the unit on the wrong side. Wrapping the figure and its unit in one bdi keeps them in reading order.
Related
- Pro
Stats Ribbon Over Grid Features
Metrics and chartsA features section for payments infrastructure: a compact header with two buttons, a slim ribbon of four stat chips between hairlines, and three cells led by a settlement timeline, ledger rows and a payout schedule.
- Pro
Stat Paired Feature Quad Features
Metrics and chartsFour stat and feature pairs in a 2 by 2 grid that shares its hairlines: a giant number counted from its own was and now figures, a pair of bars, an icon, a heading and the sentence that explains it.
- Pro
Ring Progress Metric Split Features
Metrics and chartsA split for a platform SLA monitor: copy, four ticks and a button at the start, and at the end one chart of three concentric rings with a legend, whose values a 7, 30 or 90 day toggle swaps.
- Pro
Gauge Cluster Features
Metrics and chartsThree semicircle gauges in one framed band, driven by a single "Simulate load" slider: CPU, memory and queue wait, each with a needle, an arc, a reading and a state.
- Pro
Left-Heavy Metric Cards Hero
Stats and live dataA split hero for an API host: copy and two calls to action beside a column, behind a divider, of three metric cells whose lines overshoot their corners and whose figures roll up into view.
- Pro
Split Screenshot With Stats Features
Split with mockupA split features section for an audit-log service: four ticked rows and two buttons beside a framed audit log with a strip of three figures docked inside its foot.