Skip to content

Project pages: sticky header and side navigation - #4

Merged
msetkowski merged 1 commit into
mainfrom
feature/sticky-project-chrome
Nov 9, 2026
Merged

msetkowski merged 1 commit into
mainfrom
feature/sticky-project-chrome

Conversation

@msetkowski

Copy link
Copy Markdown
Owner

Summary

On project pages, the header (logo, breadcrumbs, account menu) and the left side navigation stay in place while the main area scrolls.

  • .app-header is position: sticky on pages that have the project workbench (body:has(.workbench)). Other pages are unchanged.
  • The side navigation is pinned below the header (top: var(--header-h), full window height). It scrolls on its own when it's taller than the window.
  • The page itself still scrolls, so mouse wheel, keyboard, find-in-page and in-page anchors work as before. Anchor targets (.doc-section, .doc-element) now stop below the header instead of underneath it.
  • app.js keeps --header-h in sync with the header height using a ResizeObserver, because the header grows when the breadcrumbs wrap.
  • At 720 px and below, nothing is sticky. The navigation already stacks above the content there, and a wrapped header would take too much of a phone screen.

Test plan

Checked in Chromium (Playwright) against the dev app:

  • 1440 px, scrolled 1200 px on the read view: header at top 0 (60 px tall), side navigation at top 60 and filling the rest of the window.
  • Side-navigation link to #baseline: the section heading lands at 76 px, below the 60 px header.
  • Home page: unaffected (no --header-h, header not sticky).
  • 400 px: header and navigation scroll away normally, --header-h is 0.
  • No server code or templates changed. CI runs the full build.

🤖 Generated with Claude Code

The app header (breadcrumbs) is sticky on pages with the project workbench, and
the side navigation is pinned below it with its own scroll when it is taller than
the window. The page itself still scrolls, so wheel, keyboard, find-in-page and
anchors behave as before; anchor targets now stop below the header. app.js keeps
--header-h in sync with the header's height, which grows when breadcrumbs wrap.
Narrow screens (720 px and below), where the navigation stacks above the content,
keep the previous non-sticky layout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@msetkowski
msetkowski merged commit 5585d57 into main Nov 9, 2026
5 checks passed
@msetkowski
msetkowski deleted the feature/sticky-project-chrome branch November 9, 2026 22:47
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