Accessibility engineering

Test keyboard access and focus

A keyboard audit checks whether a person can reach, understand and operate every interactive control without a pointer. Combine manual traversal with automated checks and assistive-technology review; a passing scanner alone does not establish accessibility.

Inventory interactive behavior

List links, buttons, fields, menus, dialogs and custom widgets, then verify each has an accessible name, an expected keyboard interaction and a visible focus indicator. Prefer native controls when their built-in behavior matches the requirement.

  • Tab through the complete page in visual order
  • Activate buttons with Enter and Space as appropriate
  • Check that links and controls have useful names

Treat focus as application state

When a modal opens, move focus into it and prevent keyboard navigation from escaping. On dismissal, restore focus to the invoking control if it still exists. Avoid delayed focus timers that race with close actions or route changes.

  • Record the invoking element before opening a dialog
  • Test Tab and Shift+Tab at both boundaries
  • Verify close and restoration with keyboard only

Test dynamic and empty states

Search results, validation errors and loading states can change the focusable controls. Repeat the keyboard path after updates and confirm that no-match states remain understandable and offer a clear way to continue.

  • Test initial, filtered and empty result states
  • Confirm focus remains predictable after updates
  • Check Escape and dismissal behavior where expected

Combine tools with human review

Automated accessibility tools can identify common markup and contrast issues, but they do not assess every interaction or wording decision. Test with browser accessibility trees and representative screen-reader workflows.

  • Run an automated scan on key templates
  • Review semantics in browser accessibility tools
  • Record defects with reproducible steps and expected behavior

Questions to keep in view

Can automated accessibility tests replace manual testing?

No. Automated checks find a useful subset of failures. Keyboard-only interaction, focus behavior, accessible naming and screen-reader usability still need manual review.

What should happen to focus when a dialog closes?

Focus generally returns to the element that opened it, if that element still exists and remains operable. If the user navigated elsewhere, do not force focus back to a stale control.