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

a11y: External/new window icons missing text equivalent #147

Open
iamjolly opened this issue Jan 22, 2021 · 0 comments
Open

a11y: External/new window icons missing text equivalent #147

iamjolly opened this issue Jan 22, 2021 · 0 comments
Labels
a11y accessibility issues

Comments

@iamjolly
Copy link

Description:

The external/new window icons on links are rendered using a CSS generated background image which does not have the ability to offer text alt with it like a foreground image would. This means that screen reader users who cannot see the icon do not get the same information as a sighted user does.

Screenshots:

screenshot of generated content icons with annotations
screen shot of accessibility tree results of generated content icons

WCAG SC

Success Criterion 1.1.1 Non-text Content (Level A): All non-text content that is presented to the user has a text alternative that serves the equivalent purpose...

Recommended fix:

Either of the following fixes would be appropriate for this issue:

  • Use a foreground image of the icon (instead of CSS generated background image) with alt set to "opens in new window", or...
  • Use visibly-hidden text within the link text (apply .usa-sr-only class to the span) to append "- opens in new window" to the link text, or...
  • Remove target="_blank" and .usa-link--external class from the links.
@peterrowland peterrowland added the a11y accessibility issues label Jan 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a11y accessibility issues
Projects
None yet
Development

No branches or pull requests

2 participants