Skip to content

Spread the menu entries across the width of the bar - #26

Merged
cdiddens merged 1 commit into
pyoomph:mainfrom
cdiddens:distribute-menu-entries
Aug 8, 2026
Merged

Spread the menu entries across the width of the bar#26
cdiddens merged 1 commit into
pyoomph:mainfrom
cdiddens:distribute-menu-entries

Conversation

@cdiddens

@cdiddens cdiddens commented Aug 8, 2026

Copy link
Copy Markdown
Collaborator

The five nav entries sat bunched in the middle of an otherwise empty green bar. The list is now laid out as a flex row and distributed with space-evenly, so the gaps between neighbours and at the two ends are equal and the bar is used over its full width.

column-gap is the floor the spacing may never fall below; once it would, the row wraps instead. From 800px down the layout switches back to centred — spreading a wrapped list edge to edge leaves a lopsided last row.

Also replaces the per-<li> left/right margins with that gap. Two adjacent margins added up between neighbours but gave the row ends only half as much, which is what made the entries read as bunched in the first place.

Checked in headless Chromium at 1200, 900, 780, 620, 480 and 360px: wrapped rows stay centred and nothing overflows at the narrowest width. CSS only — no markup change.

https://claude.ai/code/session_01TtWDWoCaBcP1uFCK4e4RsJ

The five nav entries sat bunched in the middle of an otherwise empty
green bar. Lay the list out as a flex row and distribute it with
space-evenly, so the gaps between neighbours and at the two ends are all
equal and the bar is used over its full width.

column-gap is the minimum the spacing may fall to; below that the row
wraps. From 800px down the layout switches back to centred, because
spreading a wrapped list edge to edge leaves a lopsided last row.

Replace the per-item left/right margins with that gap while here. Two
adjacent margins added up between neighbours but gave the ends only half
as much, which is what made the row read as bunched.

Claude-Session: https://claude.ai/code/session_01TtWDWoCaBcP1uFCK4e4RsJ
@cdiddens
cdiddens merged commit 7108ed4 into pyoomph:main Aug 8, 2026
1 check passed
@cdiddens
cdiddens deleted the distribute-menu-entries branch August 8, 2026 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant