Browsers have included focus indicators for many years and people are accustomed to seeing them when tabbing through a webpage and using forms.
- Provide ways to help users navigate, find content, and determine where they are
- Focus helps users with cognitive difficulties
- Young people, seniors benefit
- Helpful in low light, mobile devices or distracting environments
Browsers started it, don't break the browser
Browsers have included focus indicators for many years and people are accustomed to seeing them when tabbing through a webpage and using forms. All browsers display the indicator in slightly different ways, but the current consensus seems to be a soft, glowing blue line or a fine dotted black line. The purpose of focus in a web browser is to show an element on a webpage has focus, meaning that any other actions taken by the user will be on the item with focus. So a form field that has focus will receive the letters typed, a link with focus will be activated with the return key, etc.
Removing or adversely modifying the focus indicator removes the "you are here" function it supplies.
In addition to preserving focus, it is useful to extend it, by one or more of the following:
- Increasing the visibility, contrast or style of focus e.g. strong background or text colour change.
- Extending the
hoverstate common to mouse movement to the focus state e.g.
- Normalising focus across different browsers.
- Show focus in applications and controls and not just forms and links.