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

Links that open in new tabs/windows should be tagged for assistive technology #10654

Open
6 of 7 tasks
rebekaburnett opened this issue Nov 8, 2024 · 2 comments
Open
6 of 7 tasks
Labels
bug An error in the Docusaurus core causing instability or issues with its execution domain: a11y Related to accessibility concerns of the default theme

Comments

@rebekaburnett
Copy link

rebekaburnett commented Nov 8, 2024

Have you read the Contributing Guidelines on issues?

Prerequisites

  • I'm using the latest version of Docusaurus.
  • I have tried the npm run clear or yarn clear command.
  • I have tried rm -rf node_modules yarn.lock package-lock.json and re-installing packages.
  • I have tried creating a repro with https://new.docusaurus.io.
  • I have read the console error message carefully (if applicable).

Description

Accessibility requirement:

Links that open in a new tab or a new window should either have an "aria-label" attribute or a screen-reader only element explaining to the screen-readers that this opens in a new tab.

This happens on every link that goes to another website. Here is an example: Example page (see attachment)

1_links-open-tabs

Reproducible demo

You can see this on https://docusaurus.io/

Steps to reproduce

You can see the error by scanning the Docusaurs.io site with accessible: https://accessibe.com/accessscan?website=https://docusaurus.io/

Expected behavior

Pass accessibility scans

Actual behavior

Fails scans

Your environment

Self-service

  • I'd be willing to fix this bug myself.
@rebekaburnett rebekaburnett added bug An error in the Docusaurus core causing instability or issues with its execution status: needs triage This issue has not been triaged by maintainers labels Nov 8, 2024
@slorber slorber added domain: a11y Related to accessibility concerns of the default theme and removed status: needs triage This issue has not been triaged by maintainers labels Nov 8, 2024
@rebekaburnett
Copy link
Author

It seems like these elements just need an aria-label like this:

<a href="https://example.com" target="_blank" aria-label="Example Link (opens in a new tab)">
  Example Link
</a>

@slorber
Copy link
Collaborator

slorber commented Nov 11, 2024

Thanks for reporting a11y issues @rebekaburnett.

Now is not the right time for me, but I'll try to implement all the pending suggested improvements later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An error in the Docusaurus core causing instability or issues with its execution domain: a11y Related to accessibility concerns of the default theme
Projects
None yet
Development

No branches or pull requests

2 participants