-
-
Notifications
You must be signed in to change notification settings - Fork 10.5k
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
aria-current has incorrect value "true" #6109
Comments
Looking at this again, the |
Yep, I brought this up the first time: https://github.com/ReactTraining/react-router/pull/4708/files#r120510832 A PR to change it would be appreciated! |
Hello, I'd like to take this! I'll send over a PR shortly. |
@timdorr @rmccue Correct me if I'm wrong, but based on the article linked above (https://tink.uk/using-the-aria-current-attribute/), it looks to me that |
@brandonrninefive I believe so. The spec includes |
Taking the liberty to cc @LJWatson in this conversation. |
Per the aria-current definition, Technically speaking, it's ok to use
|
* Added 'false' as a valid value for aria-current in NavLink. Also made the default value 'page' instead of 'true'. * Remove "false" string as a permitted aria-current value.
Version
4.2.2
Test Case
https://codesandbox.io/s/wol5pjk8m5
(I couldn't actually get the original CodeSandbox link to work, but the code should be right.)
Steps to reproduce
aria-current
is"true"
Expected Behavior
aria-current
should have a valid value; namely"page"
Actual Behavior
aria-current
has an invalid value; namely"true"
Hi!
aria-current
is an attribute which takes one of a few valid string values.Currently in react-router-dom, this is set to the valueSee comment; the error comes from the default being set to"true"
instead."true"
.This was caught during an accessibility audit of our site. :)
The text was updated successfully, but these errors were encountered: