There is such a task, to style the range slider. Highlight the selected portion of the field and the remainder in another color. Shoveled the whole network, maybe bad and my knowledge of this is not great. As it turned out, the task is not typical, as I understood. Found a good solution, here is an example: Link to an example
HTML <input type="range" min="0" max="100" step="1" value="50"> CSS input[type="range"]{ -webkit-appearance: none; border-radius:2px; width:200px; height:3px; background-image:-webkit-linear-gradient(left ,#f22 0%,#f22 50%,#fff 50%, #fff 100%); box-shadow:inset #ebb 0 0 5px; outline : none; transition:.1s; } input[type="range"]::-webkit-slider-thumb{ -webkit-appearance: none; width:10px; height:10px; background:#f22; border-radius:50%; transition:.1s; } input[type="range"]::-webkit-slider-thumb:hover, input[type="range"]::-webkit-slider-thumb:active{ width:16px; height:16px; } Скрипт $(function(){ var r = $('input'); r.on('mouseenter',function(){ var p = r.val(); r.on('click',function(){ p = r.val(); bg(p); }); r.on('mousemove',function(){ p = r.val(); bg(p); }); }); function bg(n){ r.css({ 'background-image':'-webkit-linear-gradient(left ,#f22 0%,#f22 '+n+'%,#fff '+n+'%, #fff 100%)' }); } }); Everything would be fine, if not one BUT. As soon as you change the maximum value other than 100, the whole thing immediately leads in different directions.
I really hope for your help, can anyone come across this issue.