progress-bars
v1.3.0
Published
Simple progress bar(s) at the bottom of the browser window.
Downloads
10
Readme
progress-bars
Simple progress bar at the bottom of the browser window. If multiple bars are added, they are stacked. You can also add progress bar with auto timers.
npm install progress-bars
bower install progress-bars
Example
<!-- if installed with bower -->
<script src="node_components/progress-bars/bar.js"></script>
<!-- if installed with bower -->
<script src="components/progress-full-width/bar.js"></script>
<script>
var bar = progressBars.init({
height: 10 // pixels
});
bar.progress(75);
var bar2 = progressBars.init({
id: 'bar2',
color: '#00ff00',
height: 10,
zindex: 1001
});
bar2.progress(25);
var bar3 = progressBars.init();
bar3.timer(60); // 1 minute
</script>
You can also place the progress bar element inside another element using selector option
progressBar.init({
selector: '.somewhere'
})
// will produce DOM structure
// <div class="somewhere>
// <div id="bar" ...>
// </div>
Small print
Author: Gleb Bahmutov © 2015
License: MIT - do anything with the code, but don't blame me if it does not work.
Spread the word: tweet, star on github, etc.
Support: if you find any problems with this module, email / tweet / open issue on Github
MIT License
Copyright (c) 2015 Gleb Bahmutov
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.