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

ensure overlay does not add aria-label if it has no role #2254

Merged

Conversation

keithamus
Copy link
Member

@keithamus keithamus commented Sep 21, 2023

Authors: Please fill out this form carefully and completely.

Reviewers: By approving this Pull Request you are approving the code change, as well as its deployment and mitigation plans.
Please read this description carefully. If you feel there is anything unclear or missing, please ask for updates.

What are you trying to accomplish?

Fix https://github.com/github/primer/issues/2668 which notes that there is an AXE violation due to the ActionMenu <anchored-position> having no role assigned, but having an aria-label.

Screenshots

Integration

No

List the issues that this change affects.

Closes https://github.com/github/primer/issues/2668

Risk Assessment

  • Low risk the change is small, highly observable, and easily rolled back.
  • Medium risk changes that are isolated, reduced in scope or could impact few users. The change will not impact library availability.
  • High risk changes are those that could impact customers and SLOs, low or no test coverage, low observability, or slow to rollback.

What approach did you choose and why?

I decided to guard the assignment of aria-label so that it isn't set if the :role isn't supplied.

Anything you want to highlight for special attention from reviewers?

Accessibility

  • Fixes axe scan violation - This change fixes an existing axe scan violation.
  • No new axe scan violation - This change does not introduce any new axe scan violations.
  • New axe violation - This change introduces a new axe scan violation. Please describe why the violation cannot be resolved below.

Merge checklist

  • Added/updated tests
  • Added/updated documentation
  • Added/updated previews (Lookbook)
  • Tested in Chrome
  • Tested in Firefox
  • Tested in Safari
  • Tested in Edge

Take a look at the What we look for in reviews section of the contributing guidelines for more information on how we review PRs.

@changeset-bot
Copy link

changeset-bot bot commented Sep 21, 2023

🦋 Changeset detected

Latest commit: bab4b15

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/view-components Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the ruby Pull requests that update Ruby code label Sep 21, 2023
@keithamus keithamus temporarily deployed to preview September 21, 2023 10:54 — with GitHub Actions Inactive
@keithamus keithamus temporarily deployed to preview September 21, 2023 11:05 — with GitHub Actions Inactive
@keithamus keithamus merged commit cdb9fe4 into main Sep 22, 2023
27 checks passed
@keithamus keithamus deleted the ensure-overlay-does-not-add-aria-label-if-it-has-no-role branch September 22, 2023 19:57
@keithamus keithamus temporarily deployed to preview September 22, 2023 19:57 — with GitHub Actions Inactive
@primer primer bot mentioned this pull request Sep 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch release ruby Pull requests that update Ruby code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants