Dapper UI
Download more icon variants from https://tabler-icons.io/i/brand-github View on GitHub
Download more icon variants from https://tabler-icons.io/i/notebook Getting Started
Quick Start (tl;dr)
Installation
Usage
Download more icon variants from https://tabler-icons.io/i/components Components
Button
TextField
Slider
Select
Checkbox
Text
Dialog
Modal
ProgressBar
Meter
Download more icon variants from https://tabler-icons.io/i/bulb Concepts
Theming
Colors
Icons
Styling
Dark Mode
Download more icon variants from https://tabler-icons.io/i/notebook Getting Started
Quick Start (tl;dr)
Installation
Usage
Download more icon variants from https://tabler-icons.io/i/components Components
Button
TextField
Slider
Select
Checkbox
Text
Dialog
Modal
ProgressBar
Meter
Download more icon variants from https://tabler-icons.io/i/bulb Concepts
Theming
Colors
Icons
Styling
Dark Mode

ProgressBar

import { ProgressBar } from "@dapper-ui/core";
A visual representation of the progress of a task, such as a download.

Demo

Example
Color
1
<ProgressBar value={25} label="Example"/>

Accessibility + Usability

It is highly recommended to label the progress bar for accessibility purposes. Even if you do not want to display the label for aesthetic reasons, you should still set a label and hide it with the hideLabel prop. This ensures that the label is still accessible to users who rely on assistive technologies such as screen readers.
Screen readers usually read the value of a progress bar as a percentage. However, if this doesn't accurately reflect the progress bar's current status, you should use the ariaValuetext prop to provide a more accurate text description of the current value.
Avoid using the progress bar as a meter, such as for displaying remaining battery percentage. Instead, use the Meter component for this purpose.

Props

ProgressBar

labelId

Type
string
Default Value
Autogenerated random ID

The id of the label element.

color

Type
string | undefined
Default Value
undefined

The name of a color in the theme. Does not support arbitrary colors.

When set to undefined, the primary color of the theme will be used.

radius

Type
Radius | undefined
Default Value
undefined

The border radius of the button. When set to undefined, the button will have the default border radius defined in the theme.

label

Type
string | undefined
Default Value
None

A label for the progress bar.

It is highly recommended to label the progress bar for accessibility purposes. Even if you do not want to display the label for aesthetic reasons, you should still set a label and hide it with the hideLabel prop. This ensures that the label is still accessible to users who rely on assistive technologies such as screen readers.

hideLabel

Type
boolean
Default Value
false

Visually hides the label.

ariaValuetext

Type
string | undefined
Default Value
undefined

The aria-valuetext attibute.

Screen readers usually read the value of a progress bar as a percentage. However, if this doesn't accurately reflect the progress bar's current status, you should use the ariaValuetext prop to provide a more accurate text description of the current value.

indeterminate

Type
boolean
Default Value
false

Whether the progress bar is indeterminate.

value

Type
number
Default Value
0

The current value of the progress bar.

Should be between the min and max values.

min

Type
number
Default Value
0

The minimum value of the progress bar.

max

Type
number
Default Value
100

The maximum value of the progress bar.

style

Type
string | undefined
Default Value
undefined

Custom CSS styles to apply.

Especially useful for positioning styles like margings.