Skip to content

fix(blog): article TOC rendered as a broken flex row#17

Merged
alabulei1 merged 1 commit into
mainfrom
fix/article-toc-nav-style
Jul 13, 2026
Merged

fix(blog): article TOC rendered as a broken flex row#17
alabulei1 merged 1 commit into
mainfrom
fix/article-toc-nav-style

Conversation

@alabulei1

Copy link
Copy Markdown
Member

The global nav { display:flex; height:72px; … } style (for the top nav bar) also matched the right-sidebar table of contents <nav class="toc">, forcing it into a 72px flex row so its heading links collapsed into ~1-character-wide columns (see the article right sidebar). This affected every Astro-rendered article once dist/ started being deployed.

Fix: scope the top-nav rule to body > nav so .toc stays a normal block and its links stack vertically. Verified with a desktop-width render of the built article.

🤖 Generated with Claude Code

The global `nav { display:flex; height:72px; ... }` rule targeted every
<nav>, including the right-sidebar table of contents (<nav class="toc">).
That forced the TOC into a 72px flex row, collapsing its heading links
into 1-character-wide columns. Scope the rule to `body > nav` (the top
bar) so `.toc` stays a normal block and its links stack vertically.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@alabulei1
alabulei1 merged commit 95aeb03 into main Jul 13, 2026
2 checks passed
@alabulei1
alabulei1 deleted the fix/article-toc-nav-style branch July 13, 2026 18:05
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