Progress bars with colour change.

Developer
Size
3,845 Kb
Views
18,216

How do I make an progress bars with colour change.?

A set of progress bar styles that change the color based on the progress. Useful for showing levels.. What is a progress bars with colour change.? How do you make a progress bars with colour change.? This script and codes were developed by Nick Nikolov on 17 October 2022, Monday.

Progress bars with colour change. Previews

Progress bars with colour change. - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Progress bars with colour change.</title> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ .progress { box-sizing: border-box;
}
.progress .bar { box-sizing: border-box; background-image: -moz-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-image: -webkit-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-image: -ms-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-size: 1px 2000px; background-position: top left; background-repeat: repeat-x; transition: all 0.5s ease-in-out;
}
.progress-main { margin-bottom: 20px; background: #eee; box-shadow: rgba(0, 0, 0, 0.15) 0 2px 3px -1px;
}
.progress-main .bar { height: 10px;
}
.progress-small { background: #eee; display: inline-block; width: 100px;
}
.progress-small .bar { height: 6px;
}
body { font-family: Roboto, Arial, sans-serif; font-size: 16px; font-weight: 300;
}
h1 { font-size: 24px; font-weight: 300;
}
.container { max-width: 600px; margin: 0 auto; padding: 20px 0;
}
table { border-collapse: collapse; table-layout: fixed; width: 100%; background: #FFF; box-shadow: rgba(0, 0, 0, 0.15) 0 4px 4px -4px; border: 1px solid #eee;
}
table tr:hover { background: #F8F8F8; transition: all 0.3s ease-in-out;
}
table td,
table th { vertical-align: top; text-align: left; padding: 10px; border-bottom: 1px solid #eee;
}
table td:last-child,
table th:last-child { width: 100px;
} </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <div class="container"> <h1>Progress bar Demo</h1> <div class="progress progress-main"> <div class="bar"></div> </div> <table> <tbody> <tr> <td>Steve Overturf</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> <tr> <td>Sophia Vandyne</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> <tr> <td>Carl Brasel</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> <tr> <td>Tanisha Forgione</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> <tr> <td>Steve Overturf</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> <tr> <td>Devora Hodnett</td> <td> <div class="progress progress-small"> <div class="bar"></div> </div> </td> </tr> </tbody> </table>
</div>
<link href='https://fonts.googleapis.com/css?family=Roboto:300,400' rel='stylesheet' type='text/css'> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>

Progress bars with colour change. - Script Codes CSS Codes

.progress { box-sizing: border-box;
}
.progress .bar { box-sizing: border-box; background-image: -moz-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-image: -webkit-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-image: -ms-linear-gradient(90deg, #53d769 0%, #fcff00 50%, #fc3d39 100%); background-size: 1px 2000px; background-position: top left; background-repeat: repeat-x; transition: all 0.5s ease-in-out;
}
.progress-main { margin-bottom: 20px; background: #eee; box-shadow: rgba(0, 0, 0, 0.15) 0 2px 3px -1px;
}
.progress-main .bar { height: 10px;
}
.progress-small { background: #eee; display: inline-block; width: 100px;
}
.progress-small .bar { height: 6px;
}
body { font-family: Roboto, Arial, sans-serif; font-size: 16px; font-weight: 300;
}
h1 { font-size: 24px; font-weight: 300;
}
.container { max-width: 600px; margin: 0 auto; padding: 20px 0;
}
table { border-collapse: collapse; table-layout: fixed; width: 100%; background: #FFF; box-shadow: rgba(0, 0, 0, 0.15) 0 4px 4px -4px; border: 1px solid #eee;
}
table tr:hover { background: #F8F8F8; transition: all 0.3s ease-in-out;
}
table td,
table th { vertical-align: top; text-align: left; padding: 10px; border-bottom: 1px solid #eee;
}
table td:last-child,
table th:last-child { width: 100px;
}

Progress bars with colour change. - Script Codes JS Codes

//SOME JS FOR SETTING THE DEMO VALUES
$('document').ready(function() { randomize(); var timer = setInterval(function() { randomize() }, 3000);
});
function randomize() { $('.progress .bar').each(function() { var val = Math.floor((Math.random() * 100)); $(this).attr('style', 'width:' + val + '%;background-position:0 ' + val + '%'); });
}
Progress bars with colour change. - Script Codes
Progress bars with colour change. - Script Codes
Home Page Home
Developer Nick Nikolov
Username necks
Uploaded October 17, 2022
Rating 4
Size 3,845 Kb
Views 18,216
Do you need developer help for Progress bars with colour change.?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Nick Nikolov (necks) Script Codes
Create amazing web content with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!