Progress

A horizontal bar that visually indicates the completion status of a task or process.

Anatomy

<script>
  import {
    Progress,
    ProgressRoot,
    ProgressTrack,
    ProgressRange,
    ProgressLabel,
    ProgressValueText,
  } from "@saas-ui/svelte/components/progress";
</script>

<Progress.Root value={50}>
  <Progress.Label>Loading...</Progress.Label>
  <Progress.Track>
    <Progress.Range />
  </Progress.Track>
  <Progress.ValueText />
</Progress.Root>

Examples

Animated Stripes Accessibility

Use the animated prop to animate the striped pattern.

Basic Accessibility

Basic progress bar with default styling.

Colours Accessibility

Use the colour prop to change the colour scheme of the progress bar.

Indeterminate Accessibility

Set value to null for an indeterminate progress bar.

Inline Label Accessibility

Progress bar with inline label using Progress.ValueText.

Range Colours Accessibility

Use the colour prop dynamically based on value to indicate different progress ranges (e.g., red for low, green for high).

Shapes Accessibility

Use the shape prop to change the shape of the progress bar.

Sizes Accessibility

Use the size prop to change the size of the progress bar.

Stripes Accessibility

Use the striped prop to add a striped pattern to the progress bar.

Values Accessibility

Use the value prop to set the progress percentage.

Variants Accessibility

Use the variant prop to change the visual style of the progress bar.

With Info Tip Accessibility

Progress bar with info tooltip on label.

With Label Accessibility

Use Progress.Label to add a label to the progress bar.

Props

Prop Type Default Description
value [object Object] 50 The current value of the progress (0-100). Set to null for indeterminate.
min number 0 The minimum value.
max number 100 The maximum value.
size xs | sm | md | lg | xl md The size of the component.
variant outline | subtle outline The visual style of the component.
shape square | rounded | full rounded The shape of the progress bar.
colour gray | red | orange | yellow | green | teal | blue | cyan | purple | pink | rose accent The colour theme of the component.
striped boolean false Whether to show stripes on the progress bar.
animated boolean false Whether to animate the stripes.
class text - Additional CSS classes to apply.
children any - The content to be rendered inside the component.