Circle Progress
<msc-circle-progress />
provides progress with circle shape. Developers could use it to indicate upload、form complete status for users.
Try to adjust the following settings and see what can <msc-circle-progress />
do ?
Basic Usage
<msc-circle-progress />
is a web component. All we need to do is put the required script into your HTML document. Then follow <msc-circle-progress />
's html structure and everything will be all set.
Required Script
Structure
Put <msc-circle-progress />
into HTML document. It will have different functions and looks with attribute mutation.
Otherwise, developers could also choose remoteconfig to fetch config for <msc-circle-progress />
.
JavaScript Instantiation
<msc-circle-progress />
could also use JavaScript to create DOM element. Here comes some examples.
Style Customization
Developers could apply styles to decorate <msc-circle-progress />
's looking.
Otherwise, apply pseudo class ::part(value)
to direct style text element.
Attributes
<msc-circle-progress />
supports some attributes to let it become more convenience & useful.
size
Set size for <msc-circle-progress />
. It will change progress size. Default is 20 (not set).
value
Set value for <msc-circle-progress />
. Default is 0 (not set).
max
Set max for <msc-circle-progress />
. Default is 100 (not set).
round
It will switch <msc-circle-progress />
bar as round once set. Default is false (not set).
Property
Property Name | Type | Description |
---|---|---|
size
|
Number | Getter / Setter for size. Default is 20. |
value
|
Number | Getter / Setter for value. Default is 0. |
max
|
Number | Getter / Setter for max. Default is 100. |
round
|
Boolean | Getter / Setter for round. Default is false. |
Method
Method Signature | Description |
---|---|
refresh
|
Force refresh <msc-circle-progress /> 's redering. Developers could call this method when <msc-circle-progress /> mutated. |