The New Form Controls: Radio Buttons
Posted by Dave Hyatt on Wednesday, August 10th, 2005 at 3:38 pmThe new radio buttons are now enabled (along with checkboxes) in the latest WebKit builds. Radio buttons behave as checkboxes do, meaning that they wont respond to properties like background-image or border until you disable the -khtml-appearance property. Once you do, you’ll get a completely blank slate and can define how all the states of the control should look.
I also did some cleanup on radio buttons to make them more consistent with WinIE and with OS X as far as keyboard navigation goes. The radio group is now a single item as far as tabbing is concerned, and the arrow keys can now be used to navigate within the radio group itself.
August 10th, 2005 at 4:22 pm
Any chance you could post up some funky images for us plebes to view?
August 10th, 2005 at 7:31 pm
I’m glad that support for this is being checked in. In order to help people see what everything looks like, I’ve created a simple test page. This page will be updated as support for more form controls is added.
August 11th, 2005 at 1:11 am
:checked works just fine on radio buttons, Karl. Unnamed radio buttons don’t belong to a group and therefore do not check. This change was made along with the other fixes to radio buttons to be more consistent with WinIE (which also does not allow a group-less radio button to check). Put the radio buttons in a group by adding name=”mygroup” to all of them, and then they’ll work.
August 11th, 2005 at 3:07 am
Fantastic news about the fixed keyboard nav. Throw in input/label pair clicking to bring *that* into line with the rest of the OS/other browsers and I might just burst
August 11th, 2005 at 8:25 am
Thanks for the information, Dave. The test has been updated accordingly.
August 27th, 2005 at 3:33 pm
Dave, will you be working on improving Safari’s support for tags be soon? I hope so! Form accessibility suffers without being able to click on checkbox and radio button labels especially.
http://bugzilla.opendarwin.org/show_bug.cgi?id=3244