fix(website): hero code-window no longer overlaps CTA buttons#50
Merged
Conversation
The hero's review-changes.json code preview used a negative top margin (-mt-6 mobile / md:-mt-12 desktop) to tuck it under the CTA button row. Since the code-window figure has `position: relative` + `z-10`, it stacks above the (statically-positioned) button row, so the negative margin visually covered the buttons instead of just peeking behind them. At common viewports (768px tablet, 1440px desktop, and 390px mobile once the row wraps to two lines) the code window's title bar fully overlapped "Get Started", "What is taskflow?", and "GitHub", making them nearly unreadable/unclickable through the glass blur. Replaced the negative overlap with a plain positive gap (mt-10 / md:mt-14) consistent with the rest of the hero's vertical rhythm. Verified with Playwright screenshots at 390x844, 768x1024, and 1440x900 for both en and zh-cn locales — buttons are now fully visible and the code window sits cleanly below them.
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.
Reported via screenshot: the "Get Started" button was nearly invisible, hidden behind the hero code-preview window.
Root cause
The
review-changes.jsoncode preview under the hero CTA row used a negative top margin (-mt-6mobile /md:-mt-12desktop) to tuck it under the buttons. Because the figure hasposition: relative+z-10, it stacks above the statically-positioned button row — so instead of subtly peeking behind the buttons, it fully covered them.At common viewports (768 tablet, 1440 desktop, and even 390 mobile once the row wraps to two lines) the code window's title bar sat directly on top of "Get Started" / "What is taskflow?" / "GitHub", making them barely legible through the glass blur and covering their click targets.
Fix
Replaced the negative overlap with a plain positive gap (
mt-10/md:mt-14), consistent with the rest of the hero's vertical rhythm (mt-7,mt-10,mt-12elsewhere in the same section).Verification
Ran the dev server locally and captured Playwright screenshots before/after at three viewports, both locales:
pnpm run build(Turbopack, 86/86 static pages) still passes.