Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block Pattern Previews appear broken for full-height cover blocks with a fixed background image #30814

Closed
kjellr opened this issue Apr 13, 2021 · 0 comments · Fixed by #31640
Closed
Assignees
Labels
[Feature] Patterns A collection of blocks that can be synced (previously reusable blocks) or unsynced [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@kjellr
Copy link
Contributor

kjellr commented Apr 13, 2021

When the parallax option is active on a full-height block pattern's cover block, the pattern preview only displays a portion of the image:

Preview:
Screen Shot 2021-04-13 at 3 07 01 PM

Live Pattern:
Screen Shot 2021-04-13 at 3 07 11 PM

To reproduce:

  1. Add a block pattern that uses a full-height cover block with a fixed background.
  2. View the pattern preview in the block inserter.

Sample:

<!-- wp:cover {"url":"https://cldup.com/7zTYWtDXdo.jpg","id":2653,"hasParallax":true,"minHeight":100,"minHeightUnit":"vh"} -->
<div class="wp-block-cover has-background-dim has-parallax" style="background-image:url(https://cldup.com/7zTYWtDXdo.jpg);min-height:100vh"><div class="wp-block-cover__inner-container"><!-- wp:paragraph {"align":"center","placeholder":"Write title…","fontSize":"large"} -->
<p class="has-text-align-center has-large-font-size">This is a cover block pattern.</p>
<!-- /wp:paragraph --></div></div>
<!-- /wp:cover -->
@kjellr kjellr added [Type] Bug An existing feature does not function as intended [Feature] Patterns A collection of blocks that can be synced (previously reusable blocks) or unsynced labels Apr 13, 2021
@glendaviesnz glendaviesnz self-assigned this May 10, 2021
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label May 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Patterns A collection of blocks that can be synced (previously reusable blocks) or unsynced [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants