User Interface

Command Palette Accessibility and Interaction Quality

Accessibility and interaction quality standards for command palettes, including focus behavior, announcements, and error ergonomics.

Command Palette Accessibility and Interaction Quality

Scope

This guide sets quality bars for accessible command palette interactions.

Interaction Model

  • open palette and move focus to input
  • keep logical tab order
  • preserve keyboard parity with pointer interactions

Accessibility Requirements

  • dialog role with proper label
  • listbox semantics for command results
  • active descendant tracking for keyboard selection
  • announced result count updates

Focus Behavior

  • return focus to trigger element when palette closes
  • avoid focus loss on rerender
  • ensure Escape closes predictably

Empty and Error States

  • no results state with actionable guidance
  • async failure state with retry path
  • non-blocking toast for command execution failures

Performance Targets

  • search to first result under 50ms for normal command sets
  • keyboard navigation without dropped frames

Testing

Unit:

  • keyboard transition logic
  • empty-state predicate

Integration:

  • role attributes and aria relationships
  • focus return and active selection semantics

E2E:

  • full keyboard-only flow
  • screen reader announcement verification

Anti-patterns

  • trapping focus without Escape exit path
  • using visual selection without aria active state
  • missing error pathway for failed commands