This time I will share jQuery Plugin and tutorial about Easy Stylable jQuery Number Input Spinner Plugin – Numble, hope it will help you in programming stack.
Numble is a fast, simple jQuery plugin for transforming the normal number input into an enhanced input spinner with increment / decrement controls and mouse scroll wheel handling.
How to use it:
1. Include the jQuery numble plugin after jQuery library is loaded in your document.
1 |
< script src = "//code.jquery.com/jquery-1.11.3.min.js" ></ script > |
2 |
< script src = "dist/jquery.numble.js" ></ script > |
2. Call the function on your number input.
1 |
$( "input[type=number]" ).numble(); |
3. Style the input spinner whatever you like.
05 |
border : 1px solid #ccc ; |
07 |
background-color : #E74C3C ; |
11 |
.numble-control .numble-arrow { |
18 |
.numble-control .numble-increment { top : 10px ; } |
20 |
.numble-control .numble-decrement { top : 25px ; } |
4. Available options.
17 |
initialValue: undefined, |
23 |
incrementText: "▲" , |
26 |
decrementText: "▼" , |
Change logs:
2015-09-13
- Readonly support, prevent direct edit beyond min/max
2015-08-12
2015-07-24
- Allow for direct edit of numble control
2015-07-23
This awesome jQuery plugin is developed by jasonyost. For more Advanced Usages, please check the demo page or visit the official website.