Skip to content

shadcn.io is not affiliated with official shadcn/ui

Shadcn Progress for React

Displays task progress with a linear indicator.

Installation

bunx --bun shadcn@latest add https://kit.dev/r/aria/progress.json

Anatomy

Progress
├── ProgressLabel
├── ProgressTrack
├── ProgressIndicator
├── ProgressValue
├── ProgressView
└── ProgressCircle
    ├── ProgressCircleTrack
    └── ProgressCircleRange

Usage

import { useEffect, useState } from "react";
import { Progress } from "@/components/ui/progress";
const ProgressDemo = () => {
  const [progress, setProgress] = useState(13);

  useEffect(() => {
    const timer = setTimeout(() => setProgress(66), 500);
    return () => clearTimeout(timer);
  }, []);

  return <Progress className="w-[60%]" value={progress} />;
};

Demos

Label

Use ProgressLabel and ProgressValue to add a label and value display.

Controlled

A progress bar that can be controlled by a slider.

Rtl

Right-to-left progress. See the RTL configuration guide for document direction.

API Reference

Progress

PropType
AttributeType

ProgressTrack

PropType
AttributeType

ProgressIndicator

PropType
AttributeType

ProgressRange

AttributeType

ProgressLabel

PropType
elementType?string
AttributeType

ProgressValue

PropType
AttributeType

useProgress