Overview
Web users have certain expectations about what will happen when they tab onto a button, click in a form field, or select an item from a combo box. These sorts of behaviors are historically one step in a process in which the user first gives focus to the item (e.g., they enter a form field), then they make a selection, then exit the form field, and ultimately submit the form after they’ve made their selections. If any of these steps prematurely triggers a change of context such as opening a new window, moving focus to a different component, going to a new page, or significantly re-arranging the content of the page, this can be very disorienting for users, especially screen reader users, screen magnification users, and other users with disabilities.
Techniques
Avoid using features that trigger a change in focus or context on hover or focus. For example:
- Opening a new window
- Moving focus to a different component
- Going to a new page
- Significantly re-arranging the content of the page
A change in focus or context should happen only at the user’s request. Users should be informed of what to expect prior to taking action, then if they choose to take that action, they can do so with a mouse click or key press.
WCAG 2.1 success criteria
The issues described on this page, and associated Techniques pages, map to the following success criteria in the W3C’s Web Content Accessibility Guidelines (WCAG) 2.1:
- 3.2.1 On Focus (Level A)
- 3.2.2 On Input (Level A)