Agreed. This seems great, but ditching standard form elements for a bunch of divs and spans generally ends up an accessibility nightmare.
Backbone.UI.Button = an anchor tag with a span inside rather than a button tag. Backbone.UI.Checkbox = an anchor containing some divs rather than an input[type=checkbox]. Radio group and Pulldown give similar output.
Re:Backbone UI
by Nervetattoo on Tuesday June 19, 2012 @08:48AM
(#4131486)
For me this is a 100% deal breaker. I can understand the desire to dress up checkboxes which doesn't work great as native controls but a lot should be doable just by wrapping it in some custom stuff.
Without form elements it has not compatibility with existing solutions, you can't use this to add some interactive components to an existing form and expect to native-submit that form.
Re:Backbone UI
by wahnfrieden on Tuesday June 19, 2012 @11:17AM
(#4132243)
If you want styled / styleable UI controls which have full accessibility (as a requirement), check out Dijit.
I remember that when Backbone came on the scene, not having to use native elements was a selling point. If you wanted to use native elements you could. But you'd end up having to put `event.preventDefault();` in every one of your event handlers.
Using custom widgets instead of native often leads to usability issues. In this case, when the a checkbox gains focus, a SPACE BAR scrolls the page instead of toggling its state.