DEV Community

Discussion on: Styling native Checkboxes and Radio inputs (CSS Only)

Collapse
 
felipperegazio profile image
Felippe Regazio • Edited

Nice tunes. But adding the user select none leads to some usability benefit or is pure aesthetic? Im asking in case someone wants to copy the text on the label, that should be a valid situation, maybe.

And must be some issue with input names. I'll fix it for sure, thanks for the notice :)

Collapse
 
bourhaouta profile image
Omar Bourhaouta

It's just pure aesthetic, avoiding selecting the text after a double-click.

I tend to think about toggles as buttons, as the text in it won't be selectable because it's not interesting to be selected.

It's just my opinion.

Thread Thread
 
felipperegazio profile image
Felippe Regazio

Nice, is definitely a good point. I also like to bind label+checkbox as as a button, but I don't usually add user-select:none. Ill adopt it for some situations,thanks!