You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 19, 2024. It is now read-only.
In shady DOM, iron-a11y-keys responds to key presses that happen on non-target elements.
Expected outcome
When I focus on a <button> element that is a sibling of the iron-a11y-keys target Node and tap the Space or Enter keys, iron-a11y-keys does not respond to the key press.
Actual outcome
When I focus on a <button> element that is a sibling of the iron-a11y-keys target Node and tap the Space or Enter keys, iron-a11y-keys responds to the key press.
Press the Enter or Space key -- Two events are fired, and their rootTargets are printed in the Console. The rootTarget of the first is iron-a11y-keys, even though the element with focus (the button) is not the target of iron-a11y-keys.
Other notes
When I add
if (e.detail.keyboardEvent) {
e.detail.keyboardEvent.preventDefault();
}
to the _handleTapped function (above the console.log()), the second (correct) event is no longer fired when Enter is tapped, but the rootTarget of the event that does fire is still wrong.
Browsers Affected
Chrome*
Firefox
Safari 9*
Safari 8
Safari 7
Edge
IE 11
IE 10
*The issue also exists in Chrome 64 and Safari 11, but only in shady DOM.
The text was updated successfully, but these errors were encountered:
Description
In shady DOM,
iron-a11y-keys
responds to key presses that happen on non-target elements.Expected outcome
When I focus on a
<button>
element that is a sibling of theiron-a11y-keys
target Node and tap the Space or Enter keys, iron-a11y-keys does not respond to the key press.Actual outcome
When I focus on a
<button>
element that is a sibling of theiron-a11y-keys
target Node and tap the Space or Enter keys, iron-a11y-keys responds to the key press.Live Demo
https://codepen.io/talimarcus/pen/aqLpmG?editors=1010
Steps to reproduce
<button>
elementiron-a11y-keys
, even though the element with focus (the button) is not the target ofiron-a11y-keys
.Other notes
When I add
to the
_handleTapped
function (above theconsole.log()
), the second (correct) event is no longer fired when Enter is tapped, but the rootTarget of the event that does fire is still wrong.Browsers Affected
*The issue also exists in Chrome 64 and Safari 11, but only in shady DOM.
The text was updated successfully, but these errors were encountered: