Make a settings dialog usable with a keyboard
A dialog is not accessible merely because it looks centered. Users need to identify it and operate it without a pointer.
Start here
This example uses the sample details below. Replace them with your own facts before applying the instructions.
- Dialog contains controls and a close action.
Start with the facts
Dialog contains controls and a close action. Keep a small reproducible example and the expected behavior. Remove secrets from the code or error message before requesting help.
Spot the problem
The wording or action to avoid is: “Let focus remain hidden behind the open dialog.” A dialog is not accessible merely because it looks centered. Users need to identify it and operate it without a pointer.
Make the correction
Provide a labelled dialog, sensible initial focus, reachable controls and a predictable close interaction.
Check before using the result
Navigate with Tab and Shift+Tab, close the dialog and confirm that focus returns to a sensible initiating control.
Worked example and reusable input
Use the stated inputs to reproduce checked local outputs. Replace sample facts when applying a brief to your own work.
TASK Make a settings dialog usable with a keyboard SAMPLE INPUT — replace with your actual facts Dialog contains controls and a close action. AVOID Let focus remain hidden behind the open dialog. CORRECTED APPROACH Provide a labelled dialog, sensible initial focus, reachable controls and a predictable close interaction. ACCEPTANCE CHECK Navigate with Tab and Shift+Tab, close the dialog and confirm that focus returns to a sensible initiating control.
Key takeaways
- A dialog is not accessible merely because it looks centered. Users need to identify it and operate it without a pointer.
- Navigate with Tab and Shift+Tab, close the dialog and confirm that focus returns to a sensible initiating control.