Staaarter

Big Hero Stat

A hero-style stats section built around a single dominant number (an eyebrow label, a very large value, and a headline/description underneath), with 2-3 smaller supporting stats arranged in a row beneath a divider. Useful for leading with one flagship metric while still surfacing a couple of secondary numbers.

By Staaarter Team
Stats
Docs
Live preview

Docs

Installation

A real shadcn registry command, not a copy-paste stand-in: it fetches this block plus its dependencies and any missing npm packages, and installs them straight into your project.

npx shadcn add https://staaarter.com/r/big-hero-stat.json

Prefer not to use the CLI? Copy the source from the Code toggle above into src/components/blocks/stats/stats3.tsx instead.

Usage

The file also exports stats3Demo, 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 { Stats3, stats3Demo } from "@/components/blocks/stats/stats3";

export default function Page() {
  return <Stats3 {...stats3Demo} />;
}

Props

PropTypeDefaultDescription
eyebrowstringundefinedSmall uppercase label above the big number.
valuestringnoneThe large, dominant stat value.
labelstringnoneHeadline text describing the big stat.
descriptionstringundefinedOptional supporting sentence under the label.
supportingStatsSupportingStat[][]Smaller stats shown below a divider.
classNamestringnoneExtra classes for the outer section element.

Types

type SupportingStat = { value: string; label: string };

Behavior notes

  • Fully static: the big number and supporting stats are all fixed string props, no count-up or animation.
  • The supporting-stats row (with its top divider) only renders when supportingStats has at least one entry, so the block also works as a single big-number-only section.
  • The big stat's font size (text-7xl / text-8xl on larger screens) is intentionally much larger than any other stats block in this category, matching the brief's 'dominant visual focus' requirement.