Progress
Progress is used to show the progress of current operation, and inform the user the current status.
Linear progress bar
Use percentage attribute to set the percentage. It is required and must be between 0-100. You can custom text format by setting format.
Internal percentage
In this case the percentage takes no additional space. stroke-width attribute decides the width of progress bar, and use text-inside attribute to put description inside the progress bar.
Custom color
You can use color attr to set the progress bar color. it accepts color string, function, or array.
Circular progress bar
You can specify type attribute to circle to use circular progress bar, and use width attribute to change the size of circle.
Customized content
Use default slot to add customized content.
Indeterminate progress
Use indeterminate attribute to set indeterminate progress, with duration to control the animation duration.
Striped progress
Use striped attribute to set striped progress. You can use striped-flow to get the stripes to flow, with duration to control the animation duration.
Sizes
you can use stroke width to set the width of the progress.
Progress API
Progress Attributes
Name | Description | Type | Default |
---|---|---|---|
percentage | Percentage (required) | Number | 0 |
type | The type of progress bar | line circle dashboard | line |
stroke-width | The width of progress bar | Number | 8 |
text-inside | Whether to place the percentage inside progress bar, only works when type is 'line' | Boolean | false |
status | The current status of progress bar | success exception warning | - |
indeterminate | Set indeterminate progress | Boolean | false |
duration | Control the animation duration of indeterminate progress or striped flow progress | Number | 3 |
color | Background color of progress bar. Overrides status prop | String Function Array | - |
width | The canvas width of circle progress bar | Number | 126 |
show-text | Whether to show percentage | Boolean | true |
stroke-linecap | Circle type shape at the end path | butt round square | round |
format | Custom text format | Function | - |
striped | Stripe over the progress bar's color | Boolean | false |
striped-flow | Get the stripes to flow | Boolean | false |
Slots
Name | Description |
---|---|
default | Customized content, parameter is |