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

Add 'aria-errormessage' to definitions list #499

Closed
AutoSponge opened this issue Aug 26, 2017 · 5 comments · Fixed by #517
Closed

Add 'aria-errormessage' to definitions list #499

AutoSponge opened this issue Aug 26, 2017 · 5 comments · Fixed by #517
Labels

Comments

@AutoSponge
Copy link
Contributor

context:

'aria-expanded': {

spec: https://www.w3.org/TR/wai-aria-1.1/#aria-errormessage

Suggested fix: insert

	'aria-errormessage': {
		type: 'idref'
	},
@WilcoFiers
Copy link
Contributor

I have some reservations about allowing this into axe-core just yet. Do you know if there are any assistive technologies that support this yet? We have a policy of only taking in accessibility feature that have sufficient support. The only exception to that being, those features that wouldn't get in the way if they weren't support. I don't think that's the case here, but certainly open to some counter-arguments.

@AutoSponge
Copy link
Contributor Author

@WilcoFiers, as far as I know, aria-errormessage is not supported by browser/AT yet. Currently, techniques that use aria-describedby to link the error message read out when the linked element is focused. The error message is also read out when using role=alert or aria-live=assertive.

I see three options here:

Option 1

Replacing aria-describedby with aria-errormessage and continued use of aria-live (adoption now)

PRO:

  • the error message will read out when the error is added
  • the code will be spec compliant
  • will have future functionality when aria-errormessage is widely supported
  • sends message to AT community is ready to support the feature

CON:

  • focus element with current error state will not read out

Option 2

Use both aria-describedby and aria-errormessage and continued use of aria-live (adoption now)

PRO:

  • the error message will read out when the error is added
  • will have future functionality when aria-errormessage is widely supported.
  • focus element with current error state will read out
  • sends message to AT community is ready to support the feature BUT requires AT to plan for conflict (see below)

CON:

  • when aria-errormessage becomes widely available, IF AT chooses to read both aria-describedby and aria-errormessage, the error message will be read twice on focus. Otherwise, aria-errormessage must proceed aria-describedby when both exist.

Option 3

No changes to current pattern (opposes adoption now)

PRO:

  • No need to change code/patterns

CON:

  • AT may never implement since no one codes for it or is ready to support it

@WilcoFiers
Copy link
Contributor

@AutoSponge Sounds good. I agree, if aria-errormessage was to point to a live region, or if it pointed to the same element as aria-describedby, I think it should pass axe-core. Are you interested on working on a PR for this? If not I think we can leave it on the issue board and we'll get to it when we can.

@AutoSponge
Copy link
Contributor Author

Great! I will start work on a PR.

@DavidMacDonald
Copy link

JAWS appears to support it in browsers.

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

Successfully merging a pull request may close this issue.

4 participants