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

🐛 [BUG] - SubdomainNavBar has wrapping/overflow issues #581

Open
simurai opened this issue Apr 25, 2024 · 3 comments
Open

🐛 [BUG] - SubdomainNavBar has wrapping/overflow issues #581

simurai opened this issue Apr 25, 2024 · 3 comments
Labels
brand bug Something isn't working

Comments

@simurai
Copy link
Contributor

simurai commented Apr 25, 2024

Describe the bug

Reported here (internal). When resizing the browser window to around 930px, it can cause wrapping/overflow issues when there are multiple CTA buttons with multi-word text labels.

Reproduction steps

  1. Go to https://github-2c2fbb9b0f-1106639.drafts.github.io/ (internal)
  2. Scroll down a bit (until CTAs appear)
  3. Resize browser window to around 930px
  4. Notice wrapping/overflow issues

Expected behavior

  1. Go to https://github-2c2fbb9b0f-1106639.drafts.github.io/ (internal)
  2. Scroll down a bit (until CTAs appear)
  3. Resize browser window to around 930px
  4. Button text should not wrap onto multiple lines. Buttons should not overlap links.

Screenshots

Image

Browsers

Chrome

OS

Mac

@simurai simurai added the bug Something isn't working label Apr 25, 2024
@simurai
Copy link
Contributor Author

simurai commented Apr 25, 2024

I tried to fix it with white-space: nowrap;, but then the buttons get cut-off:

Image

And truncation also doesn't really work. I guess it's literally not possible to show everything in the available space. Maybe instead of switching to the "hamburger menu" at 767px, it could happen earlier, based on the space that is needed. Might not be easy..? Container queries? JS measuring needed width, then switching over? 🤔

@simurai
Copy link
Contributor Author

simurai commented Apr 25, 2024

Ok, as a quick fix, the "Become a speaker" button gets hidden when not enough space (around 1080px).

@rezrah rezrah added the brand label Apr 26, 2024
@rezrah
Copy link
Collaborator

rezrah commented May 6, 2024

Thanks for filing this @simurai

Potential solutions:

  • Implement small Buttons for consistency with other, newer nav patterns (SubNav)
  • Add short title option

We generally discourage long CTA labels anyway, but the above two options might be enough here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
brand bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants