DEV Community

Discussion on: Styling a radio button with only CSS

Collapse
 
ashleyjsheridan profile image
Ashley Sheridan

when you hide the input using display: none;, you remove it from screen readers and keyboard users too. A better approach would be to use absolute positioning (on a positioned parent) and give it an opacity of 0. You should also try to give it the same dimensions as your new styled radio so that it correlates correctly when blind people are using touch discovery on a mobile device.