-
Notifications
You must be signed in to change notification settings - Fork 783
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-describedby reports referencing error, for empty spans that will have error messages. #1151
Comments
Hey David. Thanks for reporting. This is something I've been thinking about myself. I don't think axe should just pass when IDREFs don't exist, but I think it might be worth putting it into review. Certainly this seems like a false positive to me, so I think we should treat it that way and work out a fix for it. I'm actually inclined to no longer put requirements on ARIA idrefs attributes, and to only require that an idref attribute doesn't have a space (as those aren't allowed in IDs). We can than have a separate rule testing that IDREF targets exist. WDYT? |
I think its valuable to check that there is a matching id. Its fine if its a separate check. However, I think perhaps downgrading the check for corresponding id if the aria-describedby on a input type="text" to needs manual conformation. |
@WilcoFiers , @straker : Please confirm - no new documentation required here until we create a new rule specifically testing the IDREF? Thanks. |
@jeankaplansky Correct. No new documentation required. |
👍 Thanks! |
@chandana7393 I hope you can verify it now. |
@WilcoFiers we need to create another release of axe-core to fix the incomplete translation message for all downstream dependencies. |
@chandana7393 since this requires a new version of axe and Attest to pull it in, could we close this issue as the problem has been resolved for axe? |
Tested, working as expected in axe-coconut. |
@WilcoFiers @straker : The intended fix for this issue is not working as expected. Case-1 in the below samples does not show up as "needs review'. Demo: https://codepen.io/iamrafan/pen/abOrzVb?editors=1000
|
A site has gets injected with a span that is populated with an error message if the user submits the form without filling in the field that is required. Axe reporting an aria-describedby error.
Invalid ARIA attribute value: aria-describedby="giftCard_0Error"
<input id="giftCard_0" aria-describedby="giftCard_0Error" aria-invalid="false" ...
Because there is no corresponding element with a matching id until the user makes an error and submits.
does it require an empty span?
<span id="giftCard_0Error" aria-live="polite">[nothing here yet]></span>
I wonder if there is some way to make the aria-describedby message conditional to the presence of an error message?? Not sure, but its a false positive as it stands.
The text was updated successfully, but these errors were encountered: