DEV Community

Discussion on: 5 CSS tips you didn't know you needed

Collapse
 
jwesorick profile image
Jake Wesorick

Pretty sure you're not supposed to prevent highlighting as thats there for people with disabilities.

Collapse
 
apixelvisuals profile image
APixel Visuals

Can also be used to prevent selection of images by accident.

Collapse
 
lynnewritescode profile image
Lynne Finnigan • Edited

When I had to use this it was to prevent the highlighting when you clicked multiple times on a carousel arrow really fast. I wouldn’t apply it to text or anything like that - I would have no reason to.

I can’t find much info on this specific property and accessibility issues, where did you find that information?

Collapse
 
jwesorick profile image
Jake Wesorick

I am wrong. I was thinking of this: a11yproject.com/posts/never-remove.... As long as it still has an outline when it's focused you're safe.

Thread Thread
 
lynnewritescode profile image
Lynne Finnigan

It was worth checking again, considering how screenreaders work! Thanks for sharing the issue with removing the outline on focus 🙂