Skip to contents

Progress

Displays the status of a task that takes a long time.

View as Markdown
Export data

Anatomy

Import the component and assemble its parts:

Anatomy

API reference

Root

Groups all parts of the progress bar and provides the task completion status to screen readers. Renders a <div> element.

value*
number | null
Name
Description

The current value. The component is indeterminate when value is null.

Type
number | null
Default
null
aria-valuetext
string
Description

A string value that provides a user-friendly name for aria-valuenow, the current value of the meter.

Type
string | undefined
getAriaValueText
function
Description

Accepts a function which returns a string value that provides a human-readable text alternative for the current value of the progress bar.

Type
locale
Intl.LocalesArgument
Name
Description

The locale used by Intl.NumberFormat when formatting the value. Defaults to the user’s runtime locale.

Type
Intl.LocalesArgument | undefined
min
number
0
Name
Description

The minimum value.

Type
number | undefined
Default
0
max
number
100
Name
Description

The maximum value.

Type
number | undefined
Default
100
format
Intl.NumberFormatOptions
Name
Description

Options to format the value.

Type
Intl.NumberFormatOptions | undefined
className
string | function
Description

CSS class applied to the element, or a function that returns a class based on the component’s state.

Type
style
React.CSSProperties | function
Name
Type
render
ReactElement | function
Name
Description

Allows you to replace the component’s HTML element with a different tag, or compose it with another component.

Accepts a ReactElement or a function that returns the element to render.

Type
data-complete
Present when the progress has completed.
data-indeterminate
Present when the progress is in interminate state.
data-progressing
Present while the progress is progressing.

Additional Types

Progress.Root.Props

Re-Export of Root props as ProgressRootProps

Progress.Root.State

Track

Contains the progress bar indicator. Renders a <div> element.

className
string | function
Description

CSS class applied to the element, or a function that returns a class based on the component’s state.

Type
style
React.CSSProperties | function
Name
Type
render
ReactElement | function
Name
Description

Allows you to replace the component’s HTML element with a different tag, or compose it with another component.

Accepts a ReactElement or a function that returns the element to render.

Type
data-complete
Present when the progress has completed.
data-indeterminate
Present when the progress is in interminate state.
data-progressing
Present while the progress is progressing.

Additional Types

Progress.Track.Props

Re-Export of Track props as ProgressTrackProps

Indicator

Visualizes the completion status of the task. Renders a <div> element.

className
string | function
Description

CSS class applied to the element, or a function that returns a class based on the component’s state.

Type
style
React.CSSProperties | function
Name
Type
render
ReactElement | function
Name
Description

Allows you to replace the component’s HTML element with a different tag, or compose it with another component.

Accepts a ReactElement or a function that returns the element to render.

Type
data-complete
Present when the progress has completed.
data-indeterminate
Present when the progress is in interminate state.
data-progressing
Present while the progress is progressing.

Additional Types

Progress.Indicator.Props

Re-Export of Indicator props as ProgressIndicatorProps

Value

A text label displaying the current value. Renders a <span> element.

children
| ((formattedValue: string | null, value: number | null) => React.ReactNode)
| null
Type
((formattedValue: string | null, value: number | null) => React.ReactNode) | null | undefined
className
string | function
Description

CSS class applied to the element, or a function that returns a class based on the component’s state.

Type
style
React.CSSProperties | function
Name
Type
render
ReactElement | function
Name
Description

Allows you to replace the component’s HTML element with a different tag, or compose it with another component.

Accepts a ReactElement or a function that returns the element to render.

Type
data-complete
Present when the progress has completed.
data-indeterminate
Present when the progress is in interminate state.
data-progressing
Present while the progress is progressing.

Additional Types

Progress.Value.Props

Re-Export of Value props as ProgressValueProps

Label

An accessible label for the progress bar. Renders a <span> element.

className
string | function
Description

CSS class applied to the element, or a function that returns a class based on the component’s state.

Type
style
React.CSSProperties | function
Name
Type
render
ReactElement | function
Name
Description

Allows you to replace the component’s HTML element with a different tag, or compose it with another component.

Accepts a ReactElement or a function that returns the element to render.

Type
data-complete
Present when the progress has completed.
data-indeterminate
Present when the progress is in interminate state.
data-progressing
Present while the progress is progressing.

Additional Types

Progress.Label.Props

Re-Export of Label props as ProgressLabelProps