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

NavList: Add aria-current to active nav item #2075

Merged
merged 6 commits into from
Jun 14, 2023
Merged

Conversation

camertron
Copy link
Contributor

What are you trying to accomplish?

This PR updates NavList so that the currently active nav item has an aria-current attribute set on it.

Integration

No changes necessary in production.

List the issues that this change affects.

Fixes https://github.com/github/primer/issues/2313

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.

Accessibility

  • No new axe scan violation - This change does not introduce any new axe scan violations.

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 Jun 13, 2023

🦋 Changeset detected

Latest commit: 9579cc0

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

@camertron camertron temporarily deployed to preview June 13, 2023 22:27 — with GitHub Actions Inactive
@github-actions github-actions bot added patch release javascript Pull requests that update Javascript code ruby Pull requests that update Ruby code labels Jun 13, 2023
@camertron camertron temporarily deployed to github-pages June 13, 2023 22:32 — with GitHub Actions Inactive
@camertron camertron marked this pull request as ready for review June 13, 2023 23:08
@camertron camertron requested review from a team and keithamus June 13, 2023 23:08
Copy link
Contributor

@jamieshark jamieshark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@camertron - I had originally brought this up in the #primer-rails channel because of https://github.com/github/accessibility-audits/issues/3650. That issue suggests a solution of not just aria-current="true" but aria-current="page". Do we know if the value of the attribute will make a difference to the user? Maybe @primer/accessibility-reviewers might have more context.

@camertron
Copy link
Contributor Author

camertron commented Jun 14, 2023

Woops! Good catch @jamieshark, I will fix that asap. Based on these docs, page looks much more correct than true, so I don't think we need to involve @primer/accessibility-reviewers.

@camertron camertron temporarily deployed to preview June 14, 2023 17:10 — with GitHub Actions Inactive
@camertron camertron temporarily deployed to github-pages June 14, 2023 17:15 — with GitHub Actions Inactive
@camertron camertron temporarily deployed to preview June 14, 2023 17:54 — with GitHub Actions Inactive
@camertron camertron temporarily deployed to github-pages June 14, 2023 17:58 — with GitHub Actions Inactive
app/components/primer/alpha/nav_list.ts Outdated Show resolved Hide resolved
@camertron camertron enabled auto-merge (squash) June 14, 2023 22:26
@camertron camertron merged commit 2eb286f into main Jun 14, 2023
@camertron camertron deleted the nav_list_aria_current branch June 14, 2023 22:27
@primer-css primer-css mentioned this pull request Jun 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
javascript Pull requests that update Javascript code patch release ruby Pull requests that update Ruby code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants