Skip to content

Key figures band in React

Four key figures in a row, each with its caption, separated by thin rules.

Here is an excerpt of this component's code in React. The full code is free for members, ready to copy into your project.

This component also comes in

Open in a new tab

The code in React

StatsBand.tsx
export function StatsBand() {
  return (
    <section className="mx-auto w-[min(100%_-_2rem,66rem)] py-8">
      <section>
        <dl className="grid grid-cols-2 gap-y-6 min-[900px]:grid-cols-4">
          <div className="flex flex-col-reverse justify-end gap-1.5 border-l border-[#c9d6f2] px-4 dark:border-[#22335a]">
            <dt className="leading-snug text-[#46577a] dark:text-[#a9b9dd]">clients actifs</dt>
            <dd className="text-3xl font-black tracking-[-0.03em] whitespace-nowrap text-blue-700 md:text-5xl dark:text-[#93b4ff]">
              12 400
            </dd>
          </div>
          <div className="flex flex-col-reverse justify-end gap-1.5 border-l border-[#c9d6f2] px-4 dark:border-[#22335a]">

Free component: copy it freely, including for commercial projects.

Statistics components in React
  • A client area page for a small business website: sidebar, four metrics (visits, requests, reply rate and reply time) with their change, an SVG line chart per period and a filterable table of the latest messages, with no chart library.

    • Tailwind
    • React
    • CSS
    • WordPress
    Component
  • Three semicircle gauges whose needle swings to the value, with figure, label and source readable as text, in pure CSS.

    • Tailwind
    • React
    • CSS
    • WordPress
    Component
  • A row of guarantees (ten-year insurance, free quote, call-out within 24 hours, RGE and Qualibat labels) that reassures visitors right below the call to action.

    • Tailwind
    • React
    • CSS
    • WordPress
    Component
  • Four key figures in cards that count up from zero to their value when the section scrolls into view, with icon, unit and label.

    • Tailwind
    • React
    • CSS
    • WordPress
    Component
  • Four tinted paper cards pinned askew with tape on a dotted background: each figure of the venue's story has its line drawing, its title and its sentence.

    • Tailwind
    • React
    • CSS
    • WordPress
    Component