Skip to content

Nav header wraps poorly at certain widths #760

@gosko

Description

@gosko

When I resize my desktop browser to be narrower, the 'My account' text and icon get truncated at certain widths.

screenshot when signed in

This only happens when signed in to a W3C account (when the text reads 'My account'), not when signed out (when the text reads 'Sign in')

screenshot when signed out

Also at narrower widths (as in the second screenshot above), it feels like there is way too much space between the logo and the first menu item (Standards), and slightly too much even at wider widths (approx 208 pixels between the logo and Standards, but only 156 pixels between the magnifying glass and 'Sign in')

screenshot of wider viewport

I think it would look better if the nav items and magnifying glass were moved to the left a bit, as they were before the logo update.

screenshot of site before logo update

Removing the margin-inline-start: 3em from this part of the CSS seems to resolve the issue:

@media screen and (min-width: 70em) {
  .global-nav__inner > ul {
    flex-basis: auto;
    flex-wrap: nowrap;
    margin-inline-start: 3em;
    padding-bottom: 0;
  }
}

It also fixes another minor issue I hadn't noticed before: the 'My account' icon is not right-aligned with the site translation links above.

screenshot of current markup screenshot with margin-inline-start disabled

Metadata

Metadata

Labels

websiteIssues related to the W3C website

Type

Projects

Status

🏗 In progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions