Progress
Requires:
@ray-js/ray≥0.6.15
Description
Progress bar component for displaying the current progress of an operation or task.
Props
| Property | Type | Required | Default | Description |
|---|---|---|---|---|
percent | number | No | 0 | Current progress, range 0-100 |
showInfo | boolean | No | false | Whether to show the percentage on the right of the progress bar |
borderRadius | number | string | No | 0 | Corner radius, default unit rpx |
fontSize | number | string | No | 16 | Right-side percentage font size, default unit px |
strokeWidth | number | string | No | 6 | Progress bar line width, default unit rpx |
activeColor | string | No | #007aff | Color of the completed portion |
backgroundColor | string | No | rgba(0,0,0,0.04) | Color of the unfinished portion |
active | boolean | No | false | Whether to enable left-to-right progress animation |
activeMode | "backwards" | "forwards" | No | backwards | Animation playback mode: backwards plays from the beginning; forwards continues from the last end point |
Valid Values
activeMode
| Value | Description | Since |
|---|---|---|
backwards | Play the progress animation from the beginning each time | - |
forwards | Resume the progress animation from where it last ended | - |