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

image with empty alt and global aria-attribute should not pass the image-alt rule #2502

Closed
straker opened this issue Sep 1, 2020 · 1 comment
Labels
fix Bug fixes

Comments

@straker
Copy link
Contributor

straker commented Sep 1, 2020

The following code snippet should not pass the image-alt rule. The problem is that our has-alt check passes as the image has an empty alt, but the image is not considered presentational because of role conflict resolution of the global aria-label attribute.

<img src="img.jpg" id="violation11" alt="" aria-label="" />
@straker
Copy link
Contributor Author

straker commented Oct 7, 2020

Tested this in:

  • Safari/VO
  • IE11/JAWS
  • Chrome/JAWS
  • Firefox/NVDA

and all report the image as "blank" but not as an image element (just as in a newline character or empty tag). Thus this isn't an accessibility problem.

@straker straker closed this as completed Oct 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fixes
Projects
None yet
Development

No branches or pull requests

1 participant