Back to Components
Components

Metric Bar

Horizontal bar with label, value, and filled percentage visualization.

Storage used

of 100 GB

42 GB
42%

API calls

of 10,000 limit

8,421
84%

Team seats

3 / 5
60%

Dependencies

  • clsx
  • tailwind-merge

Files

  • components/ui/metric-bar.tsx

Installation

Using shadcn CLI

npx shadcn add metric-bar --url https://ui.hampton.io

Manual installation

Copy the component file to your project and install dependencies:

npm install clsx tailwind-merge