Skip to content

Start a full-screen hero's text below an overlay header - #266

Draft
amjadr360 wants to merge 2 commits into
mainfrom
fix/hero-text-clear-of-overlay-header
Draft

amjadr360 wants to merge 2 commits into
mainfrom
fix/hero-text-clear-of-overlay-header

Conversation

@amjadr360

Copy link
Copy Markdown
Contributor

When the header sits over a full-screen hero, the hero's text could start behind the header on a short screen or under a two-row header, about 20px hidden at 1280×720. This pushes the hero's text down by the header's height while the header overlays it.

Still to do

  • The fix sets the hero's top padding to the header height plus the large section spacing (spacing-70), so it overrides whatever padding the hero pattern chose. Of the 16 full-screen hero patterns, 8 use that spacing, but 6 use spacing-60 (they gain about 16px) and 2 use no top padding (they gain about 112px). The better fix adds the header's height above the hero's content and leaves the pattern's own padding alone. Needs doing before this merges, or soon after.

An overlay header pulls the first full-screen hero up by the header's
measured height, so the photo runs behind it, but nothing pushed the
hero's content back down. On a short screen, or under a tall header,
the hero's centred text started behind the header: about 20px under a
two-row header at 1280x720 on WordPress 7.1.2.

The hero's cover now adds the header's height to its top padding, on
top of the section spacing, only while the overlay applies. A hero
under a normal header, or one that fits its content and so is never
overlaid, keeps its padding as written.
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