Skip to content

Header: align with website redesign (hover-open, underline, Model dropdown)#21

Merged
PavelMakarchuk merged 1 commit into
mainfrom
align/header-redesign
May 26, 2026
Merged

Header: align with website redesign (hover-open, underline, Model dropdown)#21
PavelMakarchuk merged 1 commit into
mainfrom
align/header-redesign

Conversation

@PavelMakarchuk
Copy link
Copy Markdown
Contributor

Mirrors the website header changes in PolicyEngine/policyengine-app-v2#1059 so users see consistent navigation across PolicyEngine zones.

What changes

  • Hover-to-open dropdowns (About, Model) with a 100ms intent delay and a 200ms close grace. A transparent paddingTop "bridge" inside the same hover container fills the 10px gap between trigger and panel — moving the cursor into the panel no longer closes it. Click toggles, Escape, and outside-click still work for touch / keyboard.

  • Per-item underline-grow on hover (transform: scaleX(0→1) from center). The active page — or any child of a dropdown trigger — keeps the underline lit, so the bar always shows where you are.

  • Model dropdown replaces the flat Model link. Full sidebar mirror:

    • Rules — Coverage, Parameters, Variables
    • Data — Pipeline, Calibration, Validation
    • Behavioral responses

    Children indented one level. Parents (Rules, Data, Behavioral responses) clickable to their overview pages (now real pages as of PolicyEngine/policyengine-model#41).

  • Per-property transition delays on dropdown rows: the cascading entry reveal staggers opacity only; hover background/color stay instant. Fixes the lag when sweeping the cursor across rows of an open dropdown.

  • Logo→nav gap bumped from 12px to 40px so the logo reads as an anchor rather than another menu entry.

  • Mobile menu walks nested children and renders them indented.

Test plan

  • Hover any nav item → underline grows from center
  • Hover About → dropdown opens after ~100ms; mouse down to a child via the gap doesn't close it
  • Hover Model → same; children render indented; parents clickable
  • Sweep mouse rapidly across open dropdown rows → hover background tracks the cursor with no perceptible delay
  • Tab through nav with keyboard → focus produces same affordance as hover; Escape closes an open dropdown
  • Resize to mobile → menu icon opens slide-out; Model dropdown shows nested children indented

🤖 Generated with Claude Code

…pdown)

Mirrors the website header changes (PolicyEngine/policyengine-app-v2#1059)
so users see consistent navigation across zones.

- Dropdowns open on hover with a 100ms intent delay and a 200ms close
  grace; a transparent paddingTop "bridge" inside the same hover
  container fills the 10px gap so the cursor doesn't trigger close
  while travelling to the panel. Click toggles, Escape, and
  outside-click still work for touch / keyboard.
- Per-item center-out underline grow on hover. The active page (or
  any child of a dropdown trigger) keeps the underline lit so the bar
  shows where you are. Active-state walks dropdown children
  recursively.
- Model is now a dropdown with the full sidebar mirror: Rules
  (Coverage / Parameters / Variables), Data (Pipeline / Calibration /
  Validation), Behavioral responses. Children are indented one level.
- Per-property transition delays on dropdown rows: the cascading
  entry reveal staggers opacity only; hover background/color stay
  instant.
- Logo→nav gap bumped from spacing.md (12px) to 40px so the logo
  reads as an anchor instead of another menu entry.
- MobileMenu now walks nested children too and indents them.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
household-api-docs Ready Ready Preview, Comment May 26, 2026 2:15pm

Request Review

@PavelMakarchuk PavelMakarchuk merged commit a0cd5c0 into main May 26, 2026
2 checks passed
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