button:active state is not being triggered on spacebar press
Categories
(Core :: DOM: UI Events & Focus Handling, defect)
Tracking
()
People
(Reporter: katherine.deibel, Unassigned)
Details
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:81.0) Gecko/20100101 Firefox/81.0
Steps to reproduce:
I created the following codepen: https://codepen.io/metageek/pen/gOrVzba
that contains buttons with distinct focus (dark blue background), hover (green box shadow), and active (yellow text on purple background and dotted red outline) states. An output log shows keydown events and click events on the button (newest message at top).
Actual results:
button:active state is triggered correctly when a button is clicked by a mouse. No active state is seen when a focus button is triggered by the spacebar.
Expected results:
On a spacebar keydown event, the active state should have been shown and should have stayed active as long as the key remain pressed. This is a visual affordance to know that the button was clicked.
Updated•4 years ago
|
Updated•4 years ago
|
Description
•