Repository navigation
Conversation
The first-visit wave, reading-order style vars, and grid delay now live in one place, so later pages can reuse them instead of copying Events. The navbar and footer rise on the first load of the visit only, on Home's three beats. Overlays get a 180ms scale-and-fade from their trigger, with a faster exit. The Events page and its timings are unchanged.
The shared module now owns the entering class, item delay variables, and overlay origin. A page wraps its root, hero, grid, or list (and, for a grid, passes the column map that already matches its CSS). Checkout and other early-return pages can use the class hook so the first-visit flag is only read once.
Hero visuals use the same --entrance-i stagger as list items. The wrapper now sets that variable, defaulting to the first beat, so a lone hero and a row of lead portraits stay on the shared wave.
Rename the entrance helpers so they describe the wave order, not a style object. Keep the hidden start state on the first painted frame, cap long grid waves, and key each page's clock so a remount cannot restart it.
Point Events' month rows and chips at the shared grid tokens so a long list cannot outlast the wave, and so the month timing lives with the rest of the entrance delays.
The bar centers those links with transform: translate(-50%, -50%). The shared rise animation was replacing that transform, so the links sat low and to the right until the wave ended. Chrome now fades and shifts with the individual translate property, which leaves the centering transform in place.
|
🚀 Deployed on https://pr-484--iuga.netlify.app |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rationale
Events already had an entrance wave, while the navbar, footer, and the rest of the site appeared abruptly on load. Instead of copying stagger math and session flags into every page, I extracted one shared module (
PageEntrance.jsx,usePageEntrance.js,useEntranceColumns.js,pageEntrance.js, and_pageEntrance.scss) so pages opt in withPageRoot,EntranceHero,EntranceGrid,EntranceList,OverlayEntrance, anduseChromeEntrance.I also fixed two visual bugs surfaced while sharing the wave: items start at
opacity: 0before keyframes run so there is no first-frame flash, and the navbar and footer animate the individualtranslateproperty instead oftransformso desktop.nav-primary-linkskeeps its centeringtranslate(-50%, -50%)throughout the fade-in.Desktop Before (About, 1440px):
about-before-1440.mp4
Desktop After (About, 1440px):
about-after-1440.mp4
Desktop Before (Shop, 1440px):
shop-before-1440.mp4
Desktop After (Shop, 1440px):
shop-after-1440.mp4
Mid-animation navbar centering on About and Shop (1440px) and sampled-opacity trace:
Observable Behavior
translatewithout shifting the centered links.ENTRANCE_WAVE_MS = 1200), row cap (6), and hero stagger helpers.prefers-reduced-motion: reducesee everything at rest right away.Verification
/aboutor/shopon desktop (1440px) and check that the navbar links stay centered while fading in and never snap or flash.fe10fc7infrontend/:npm test -- --run(68 files, 923 tests passed),npx stylelint "src/**/*.scss"(0 errors, 258 pre-existing warnings), andVITE_API_URL=http://localhost:7777 npm run build(passed). Note: runningsrc/stylesheets/pageEntrance.test.json this branch alone fails 1 test (staggers vertical list items with the shared item cap) until PR [Grok bot] Wave Get Involved lead cards and committee rows in on first visit #487 adds the.pageEntrance__listItemrule.Stack Context
Stacked on PR #482 (
feat/events-page-entrance). Merge PR #482 first, then #484 through #492 in order.Co-authored with Grok Bot.