--- title: Progress description: "`Progress` is a component for visually indicating progress." links: - style: https://github.com/yamada-ui/yamada-ui/tree/main/packages/react/src/components/progress/progress.style.ts - source: https://github.com/yamada-ui/yamada-ui/tree/main/packages/react/src/components/progress - storybook: https://yamada-ui.github.io/yamada-ui?path=/story/components-progress--basic --- ```tsx ``` ## Usage ```tsx import { Progress } from "@yamada-ui/react" ``` ```tsx import { Progress } from "@/components/ui" ``` ```tsx import { Progress } from "@workspaces/ui" ``` ```tsx ``` ### Change Variant ```tsx {(variant, index) => ( )} ``` ### Change Size ```tsx {(size, index) => ( )} ``` ### Change Color Scheme ```tsx ``` ### Change Shape ```tsx {(shape, index) => ( )} ``` ### Change Range Color To change the range color, set `rangeColor` to a color. ```tsx ``` ### Change Track Color To change the track color, set `trackColor` to a color. ```tsx ``` ### Stripes To use stripes, set `striped` to `true`. ```tsx ``` ### Animated Stripes To use animated stripes, set `animated` to `true`. ```tsx ``` ### Change Duration To change the duration, set `duration` to a number (seconds) or a string. ```tsx ``` ### Use Animation To use animation, set `value` to `null`. ```tsx ``` ## Used By Components & Hooks ## Props | Prop | Default | Type | Description | | ------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | | `as` | - | `As` | The HTML element to render. | | `asChild` | - | `boolean` | Merges its props onto its immediate child. | | `css` | - | `CSSObject \| CSSObject[]` | The CSS object. | | `colorScheme` | - | `"amber" \| "black" \| "blackAlpha" \| "blue" \| "cyan" \| "danger" \| "emerald" \| "error" \| "flashy" \| "fuchsia" ...` | Set color scheme variables. | | `size` | `"md"` | `"lg" \| "md" \| "sm" \| "xl" \| "xs"` | The size of the component. | | `variant` | `"outline"` | `"outline" \| "subtle"` | The variant of the component. | | `duration` | - | `number \| string` | The animation duration in seconds. | | `max` | `100` | `number` | The maximum value of the progress. | | `min` | `0` | `number` | The minimum value of the progress. | | `rangeColor` | - | `"-moz-initial" \| "AccentColor" \| "AccentColorText" \| "ActiveBorder" \| "ActiveCaption" \| "ActiveText" \| "aliceblue" \| "amber.100" \| "amber.200" \| "amber.300" ...` | The color of the progress range. | | `rangeProps` | - | `ProgressRangeProps` | Props for the progress range element. | | `trackColor` | - | `"-moz-initial" \| "AccentColor" \| "AccentColorText" \| "ActiveBorder" \| "ActiveCaption" \| "ActiveText" \| "aliceblue" \| "amber.100" \| "amber.200" \| "amber.300" ...` | The color of the progress track. | | `value` | `0` | `null \| number` | The value of the progress. If `null`, the progress will be indeterminate. | ## Accessibility The `Progress` follows the [WAI-ARIA - Meter Pattern](https://www.w3.org/WAI/ARIA/apg/patterns/meter/) for accessibility. Setting `aria-label` or `aria-labelledby` on `Progress` will make it readable by screen readers. ```tsx ``` ```tsx Central Processing Unit (CPU) Usage ``` ### ARIA Roles and Attributes | Component | Role and Attribute | Usage | | ---------- | -------------------- | -------------------------------------------------- | | `Progress` | `role="progressbar"` | Indicates that it is a progress bar. | | | `aria-valuemin` | Sets the minimum value. Default: `0` | | | `aria-valuemax` | Sets the maximum value. Default: `100` | | | `aria-valuenow` | Represents the current value. | | | `aria-label` | Set the label that describes the current progress. |