--- title: Progress description: "`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 ``` ## 使い方 ```tsx import { Progress } from "@yamada-ui/react" ``` ```tsx import { Progress } from "@/components/ui" ``` ```tsx import { Progress } from "@workspaces/ui" ``` ```tsx ``` ### バリアントを変更する ```tsx {(variant, index) => ( )} ``` ### サイズを変更する ```tsx {(size, index) => ( )} ``` ### カラースキームを変更する ```tsx ``` ### 形を変更する ```tsx {(shape, index) => ( )} ``` ### レンジの色を変更する レンジの色を変更する場合は、`rangeColor`に色を設定します。 ```tsx ``` ### トラックの色を変更する トラックの色を変更する場合は、`trackColor`に色を設定します。 ```tsx ``` ### ストライプを使う ストライプを使う場合は、`striped`を`true`にします。 ```tsx ``` ### ストライプにアニメーションを使う ストライプにアニメーションを使う場合は、`animated`を`true`に設定します。 ```tsx ``` ### 所要時間を変更する 所要時間を変更する場合は、`duration`に数値(秒)または文字列を設定します。 ```tsx ``` ### アニメーションを使う アニメーションを使う場合は、`value`を`null`に設定します。 ```tsx ``` ## 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. | | `animated` | `false` | `boolean` | If `true`, the progress bar will animate. | | `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" \| "ActiveBorder" \| "ActiveCaption" \| "aliceblue" \| "amber.100" \| "amber.200" \| "amber.300" \| "amber.400" \| "amber.50" \| "amber.500" ...` | The color of the progress range. | | `rangeProps` | - | `ProgressRangeProps` | Props for the progress range element. | | `shape` | `"rounded"` | `"circle" \| "rounded" \| "square"` | The shape of the progress bar. | | `striped` | `false` | `boolean` | If `true`, the progress bar will show stripe. | | `trackColor` | - | `"-moz-initial" \| "ActiveBorder" \| "ActiveCaption" \| "aliceblue" \| "amber.100" \| "amber.200" \| "amber.300" \| "amber.400" \| "amber.50" \| "amber.500" ...` | The color of the progress track. | | `value` | `0` | `null \| number` | The value of the progress. If `null`, the progress will be indeterminate. | ## アクセシビリティ 現在、v2の移行に伴い、このセクションは更新中です。