Overview
All interactive functionality must be operable with a keyboard alone. Users who can't use a mouse depend entirely on keyboard navigation.
The Problem
This pattern is inaccessible — avoid it.
The Fix
Use this accessible pattern instead.
Step-by-step
Test your page by unplugging your mouse and using Tab, Shift+Tab, Enter, Space, and arrow keys.
Replace div/span click handlers with <button> or <a> elements.
If you must use a custom widget, add role, tabindex="0", and keydown handlers.
Ensure every interactive element can be reached and activated by keyboard.
Don't use tabindex values > 0 — they create confusing tab order.
Framework Notes
How to apply this fix in your stack.