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

jsx-a11y/control-has-associated-label not recognizing aria-hidden #635

Closed
ghost opened this issue Sep 27, 2019 · 1 comment · Fixed by #723
Closed

jsx-a11y/control-has-associated-label not recognizing aria-hidden #635

ghost opened this issue Sep 27, 2019 · 1 comment · Fixed by #723

Comments

@ghost
Copy link

ghost commented Sep 27, 2019

Hey!

When I add aria-hidden="true" to the element I would expect this rule to ignore this particular control element. It seems not be the case.

Example

// rule config

'jsx-a11y/label-has-associated-control': [
  'error',
  {
    assert: 'either',
  }
],

<input type="hidden" aria-hidden="true" />

This fails.

Thanks!

@ljharb
Copy link
Member

ljharb commented Sep 27, 2019

I would expect any type=hidden input to be exempted from this rule, aria-hidden or not.

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

Successfully merging a pull request may close this issue.

1 participant