Skip to content

Conversation

@liuliu-dev
Copy link
Contributor

@liuliu-dev liuliu-dev commented Jan 23, 2026

What are you trying to accomplish?

Fixes an accessibility issue where tab navigation items overlapped at narrow viewport widths (320×256px), failing WCAG 1.4.10 Reflow requirements.

Updated .tabnav-tabs CSS to enable horizontal scrolling instead of hiding overflow, added flex-shrink: 0 to child <li> elements to prevent them from collapsing

Screenshots

Before After
Screenshot 2026-01-23 at 11 15 19 AM Screenshot 2026-01-23 at 11 15 34 AM

Integration

List the issues that this change affects.

Related issue: https://github.com/github/accessibility-audits/issues/14743

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?

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 Jan 23, 2026

🦋 Changeset detected

Latest commit: f1e5efa

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
Copy link
Contributor

github-actions bot commented Jan 23, 2026

Uh oh! @liuliu-dev, at least one image you shared is missing helpful alt text. Check your pull request body to fix the following violations:

  • Images should have meaningful alternative text (alt text) at line 13
  • Images should have meaningful alternative text (alt text) at line 13
  • Images should have meaningful alternative text (alt text) at line 13
  • Images should have meaningful alternative text (alt text) at line 13

Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image.

Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs.

🤖 Beep boop! This comment was added automatically by github/accessibility-alt-text-bot.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes an accessibility violation where tab navigation items overlapped at narrow viewport widths (320×256px), failing to meet WCAG 1.4.10 Reflow requirements.

Changes:

  • Updated .tabnav-tabs CSS to enable horizontal scrolling instead of hiding overflow
  • Added flex-shrink: 0 to child <li> elements to prevent tab collapse at narrow viewports

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
app/components/primer/alpha/tab_nav.pcss Modified CSS to enable horizontal scrolling and prevent tab item shrinking at narrow viewports
.changeset/mighty-toys-remain.md Added changeset documenting the patch-level fix for TabNav overlapping issue

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@liuliu-dev liuliu-dev added this pull request to the merge queue Jan 27, 2026
Merged via the queue into main with commit 2001888 Jan 27, 2026
38 checks passed
@liuliu-dev liuliu-dev deleted the liuliu/fix-overlapping-issue-in-tabnav-at-narrow-viewports branch January 27, 2026 17:11
@primer primer bot mentioned this pull request Jan 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants