473
Sponsor

Progress Bar

Determinate progress bar with percent and value/total display

Terminal

Installation

$ pnpm dlx shadcn@latest add @termcn/progress-bar

Usage

import { ProgressBar } from "@/components/ui/progress-bar";
<ProgressBar value={42} total={100} label="Uploading" />

Examples

Custom Characters and Color

Terminal
import { ProgressBar } from "@/components/ui/progress-bar";

export function ProgressBarCustom() {
  return <ProgressBar value={80} fillChar="=" emptyChar="-" color="#22c55e" />;
}

API Reference

ProgressBar

PropTypeDefault
valuenumberrequired
totalnumber-
widthnumber30
showPercentbooleantrue
showEtabooleanfalse
fillCharstring"█"
emptyCharstring"░"
colorstring-
labelstring-