Progress bar in javascript + calc element.

javier94

Member
hello, i'm trying to make a progress bar using the javascript plugin in the element.

using out of fabrik the progress bar is working.. but using the calc element .. not.

in fabrik plugin.. i put this code..

UIkit.util.ready(function() {
let bar = document.getElementById('js-progressbar');
let animate = setInterval(function() {
bar.value += 1;
if (bar.value >= bar.dataset.stop) {
clearInterval(animate);
}
}, 10);
});

the js pluguin. make and advice.. not an error..

and in the calc element

<progress id="js-progressbar" class="uk-progress" value="0" data-stop="234" max="365"></progress>

the doubt is with the js code ...? maybe in fabrik don´t work like this.

Any suggestion?

thanks

Javier
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top