Yelotofu

Yelotofu ~ “In building standards compliant sites we are creating a better Web for the future.”

jQuery UI Spinner

After contributing jQuery Numeric Stepper to the jQuery UI community. Paul Bakaus kindly asked whether I'd like to merge it with the official jQuery UI Spinner, of which I was more than happy to do out of pure love for jQuery.

The jQuery UI Spinner widget will be available with the soon to be released jQuery UI v1.6.

Here's a demo of the current incarnation.

Also, check out Subversion if you're interested in getting the latest and greatest.

Update: this spin control is currently in re-design phase and will come under intense refactoring to be leaner and meaner. So the UI team have decided to push back its release to v1.next, which means it will not be part of the final 1.6 release. Sorry guys!

Update2: I've posted an update on this here.

Similar Posts

12 Comments

  1. By Jason at

    Looking great! If it’s non-trivial, I suggest adding support for time. http://keith-wood.name/timeEntry.html does a decent job, but it seems like a natural addition to this plugin as well.

  2. By caphun at

    @jason: interesting proposal. will definitely give this one some thought. :)

  3. By Javi at

    Definitely what I was looking for :-) . I’ve tried the version included in JQuery UI 1.6RC1, and it seems to work great.

    My suggestion: make “stepping” and the number of decimals independent. For example, if I specified something like:

    { decimals: 2, stepping: 1 }

    Then two decimals would be displayed, but the number would be increased/decreased by one unit when the buttons are hit.

  4. By caphun at

    @javi: that’s a good suggestion. I think there are many use cases for this. It’s pretty easy addition too! I’ll get that into the spinner soon. Thanks :)

  5. By caphun at

    @javi: I have added a decimals option to the SVN version. The latest is also here:

    http://yelotofu.com/labs/jquery/UI/spinner/ui/ui.spinner.js

    Thanks!

  6. By Javi at

    Thanks! I’ve just tried it, and it works great :-) .

  7. By Den at

    This is a cool and useful widget.

    There’s just one little thing. It doesn’t feel natural to click the UP arrow to scroll DOWN a list, in my opinion.

    Perfectly natural for the numeric stepper, though.

    Congratulations.

  8. By Jon Thomas at

    Wait, so was this released in 1.6 or not? Sorry for asking if you’ve already clarified somewhere, but I wasn’t sure.

  9. By Jon Thomas at

    I’m sorry, you did clarify that. You said it would not be in 1.6. I’m guessing it is not in 1.7 either, which is 1.6.7??

  10. By Pawel at

    It’s not working with jquery 1.3.2
    Do you have an easy fix

  11. By caphun at

    @jon – the spinner has not been released yet but is very close now. It will most likely be part of 1.8 but no guarantees.

    @pawel – see, update2 above.

  12. By bamboolabcode at

    Very interesting list. It’s a great addon to what I’m already doing. Thanks.

Leave a Reply

* marks a required field.



(this will not be published)