Download Demo
Rangestepper.js is a jQuery plugin that creates a highly css style-able snappable range input
I needed a slider / range input / input of type range that I could customize via css, all the slider plugins are way overkill out there and also the HTML input of range type is customizable but not enough, besides changing the way the thumb and the track looks I also wanted to style the snappable points.
1. INCLUDE CSS AND JS FILES
<link rel= "stylesheet" type= "text/css" href= "css/rangestepper.css" > <script src= "js/rangestepper.js" ></script> |
<div id= "demo-rangestepper" ></div> |
$( '#demo-rangestepper' ).rangestepper({ inputName: 'rangestepper' , minVal: -10, maxVal: 10 }); |
Also, there is the ability to set the minVal and maxVal, if the minVal is set to 0 the thumb will be by default placed at the beginning of the range input slider, if a negative value is set to minVal, the thumb will be set at the center/origin where the value reaches 0.
You can easily get the value with the default $(‘#demo-rangestepper input’).val();
No comments:
Post a Comment