This component require metro-progressbar.js
.
<div class="progress-bar" data-role="progress-bar" data-value="10"></div> <div class="progress-bar" data-role="progress-bar" data-color="bg-green"></div> <div class="progress-bar" data-role="progress-bar" data-color="#ccc"></div>
<div class="progress-bar small"></div> <div class="progress-bar"></div> <div class="progress-bar large"></div>
You can activate widget manually or auto with data-*
api.
$("#componennt_id").progressbar({ value: int // progress value, default 0 color: string, // existing class (bg-*) or color schema (#NNNNNN) onchange: function(val){...} });
var pb = $("#componennt_id").progressbar(); pb.progressbar('value', 75);
var pb = $("#componennt_id").progressbar(); pb.progressbar('color', '#000');
<div class="progress-bar" data-role="progress-bar" data-value="75" data-color="bg-pink"> </div>
Slider supported next options:
value | data-value | Set a new position and progress of the progress bar. |
color | data-color | Set the color of the progress bar. |
animate | data-animate | Animate progress value changes of the progress bar. |
max | data-max | Optionally set the maximum value of the progress bar to be below 100. |
You can sets options over javascript or data-* api.