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

aria-hidden="true" within labels is not honored upon focus of associated input #4162

Closed
nvaccessAuto opened this issue May 29, 2014 · 4 comments

Comments

@nvaccessAuto
Copy link

Reported by james.curd.razorfish on 2014-05-29 20:43
Often, asterisks are used to denote that an input is required to a sighted user. Since screen reader users have aria-required to communicate this information to them, it seems preferable to not need to listen to the ASCII method of communicating this.

Placing aria-hidden="true" on the spans wrapping the asterisks should prevent them from being read.

When navigating element by element, NVDA recognizes that aria-hidden is applied to the asterisk and does not read it. However, upon entering an input field, NVDA no longer honors the aria-hidden attribute and reads the asterisk as "star".

<label for="first_name">First Name<span aria-hidden="true">*</span></label>
<input id="first_name" type="text" aria-required="true">

Expected reading upon entering the field: "First Name edit required"
Current reading upon entering the field: "First Name star edit required"

This issue occurs in NVDA with both IE9 and Firefox in Windows 7.
This works properly in JAWS with IE9 as well as VoiceOver for Safari, Firefox, and Chrome.

@nvaccessAuto
Copy link
Author

Comment 1 by jteh on 2014-05-29 21:34
When reporting the focus, we report the label as exposed by the browser. If this is a bug, it is a browser bug. For Firefox, we would work with Mozilla to get this fixed. For IE, we would probably have to hack around it as usual.

ARIA does specify that hidden elements shouldn't be ignored if aria-labelledby references a hidden element. In this case, aria-labelledby isn't used, but the question is whether associating a label using the @for attribute of the label element is intended to be equivalent to aria-labelledby. My guess is that this is why Firefox is doing it this way. If you have any references that are clear about this being incorrect, please provide them. Regardless, I'll file a bug with Mozilla to at least get discussion going.

@Adriani90
Copy link
Collaborator

@james.curd.razorfish is this issue still reproducible?
cc: @jcsteh if yes, is there already a Mozilla bug for this?

@Adriani90
Copy link
Collaborator

@Martinator could you try to reproduce it please?

@Adriani90
Copy link
Collaborator

Testing with NVDA 2019.1.1, This is reproducible only in IE11.
I am closing this in favor of #5833.

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

No branches or pull requests

4 participants