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

Core: Unnecessary aria-describedby (makes #2094 fixable) #2410

Open
wants to merge 15 commits into
base: master
Choose a base branch
from

Conversation

eden-jh
Copy link

@eden-jh eden-jh commented Nov 16, 2021

Apologies for the messy commit history. I squashed it (eden-jh@73a70d2) but then it forced me to merge before pushing.

Description

I added an ariaDescribedByCleanup option to the validator setting. The default is false just to keep the current behavior (leave the value in place but empty and hide the error elements). I don't feel strongly about that, but it felt safer to make this opt-in, especially because there's a certain amount of customization that needs to happen in order for this to be a problem.

Fixes #2094 (kind of; the examples given in the issue are from unobtrusive, and the default is the current behavior, the setting will have to be updated in unobtrusive.)

Added additional tests for this functionality, plus a demo page.

Groups

aria-describedby is used on all group elements if any of them has an error, and is only removed when all elements in that group are valid. This seemed the most consistent with the current functionality.

@github-actions
Copy link

This issue/proposal has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automatically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and one of the maintainers will (try!) to follow up.
Thank you for contributing :)

@github-actions github-actions bot added the stale Used to mark stale issues label Apr 15, 2022
@github-actions github-actions bot closed this Apr 22, 2022
@bytestream bytestream reopened this May 8, 2024
@bytestream bytestream added NEEDS REVIEW and removed stale Used to mark stale issues labels May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unnecessary aria-describedby attribute causes WCAG scans to fail
2 participants