project-ufa / jpicker

jPicker is a fast, lightweight color picker jQuery plugin.
0 stars 0 forks source link

Radio button optim #28

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
This is not a real issue.
Juste a note to improve your plug in

You could add a "name='colorButton'" attr on your radio buttons. 
Then, you could remove 
$(this).parents('tbody:first').find('input:radio[value!="' + e.target.value + 
'"]').removeAttr('checked'); 
in the radioClicked function as the browser manage only one check for radio 
buttons

You'll have a lighter js ;)

Anyway, thank you for your plug in, this is really good job !

Original issue reported on code.google.com by micho...@gmail.com on 1 Sep 2011 at 9:31

GoogleCodeExporter commented 9 years ago
Not a terrible idea, however the first version did that. It interferes if you 
have more than one picker on the screen, and sub-naming by list index number 
would increase JS code and complexity. It was a quick decision as to which way 
to go.

Original comment by christop...@gmail.com on 26 Sep 2012 at 12:30

GoogleCodeExporter commented 9 years ago

Original comment by christop...@gmail.com on 5 Nov 2012 at 5:36