Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

details element giving false positive for no-noninteractive-element-interactions #582

Closed
anthony-dandrea opened this issue Apr 8, 2019 · 1 comment
Assignees

Comments

@anthony-dandrea
Copy link

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details

I'm getting what I perceive to be a false positive for jsx-a11y/no-noninteractive-element-interactions . This is in fact an interactive element that can be toggled open and closed natively. I'm adding listeners to the element in order to provide fallback support for IE/Edge that do not support it.

<details
  onKeyDown={this.handleKey}
  onClick={this.toggle}
/>
@anthony-dandrea anthony-dandrea changed the title details element giving false position for no-noninteractive-element-interactions details element giving false positive for no-noninteractive-element-interactions Apr 8, 2019
@jessebeach
Copy link
Collaborator

@sh0ji is correct, this is not a false positive. The details element maps to a group role, which is non-interactive. The summary element should be considered interactive, though. We'll fix this in #656

https://w3c.github.io/html-aria/#el-details
https://w3c.github.io/html-aria/#el-summary

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants