-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Cover block align-top doesn't work. #50610
Comments
Thank you for reporting this @Ren2049. I found this issue while investigating a similar report in the support forum. I recorded a video to illustrate the problem. Could you please confirm that this is what you are seeing on your end too? Screen.Capture.on.2023-05-31.at.16-46-26.mp4Thank you! |
@mrfoxtalbot Yes! Thats the problem! |
Hello, wordpress_cover.block.issue.mp4 |
I can confirm the issue, and have done some digging. When the 'Change content position' button is used to move an item from the default center/center alignment to any of the other eight positions, the CSS on the inner block (.wp-block-cover__inner-container) changes from a width of 100% to 'width:auto'. This sort of makes sense, since the 'Change content position' button is moving the inner block to left, right, up and down, or combinations of these (top left, center right, etc.). But it's inconsistent with the default. Starting with a Pattern (say cover image with branding/nav over the top of it) the pattern contains a Spacer block — something that offends my mildly fastidious views about superfluous code. This forces the branding/nav block to stay at the top. A fix would be to allow for the width of the inner row (.wp-block-cover__inner-container) to be reset to 100%. Or, alternatively, to flex-grow:1. Could all of this be accomplished with grid positioning instead? I'd like to be able to, say, put the branding/nav row at the top and place other items (header, blurb, button) in the middle of the cover block. |
I ran into this in testing today and reported on Automattic/wp-calypso#78502 - the Screen.Capture.on.2023-06-21.at.12-36-32.mp4
Addresses the width issue as a workaround for now. |
another big annoying issue for whoever wants to display a menu on top of the cover block (for instance) cover-inner-content-width.webm |
Description
Trying to build a transparent hero-header with the cover block as the outer wrapper I've noticed that the align-top/change content position feature doesn't work. A theme designer would expect the cover block to work like the group or stack blocks, but with the additional media and overlay functionality.
Can we have a proper section block with media functionality? I'm currently using the cover block as a "section wrapper".
Step-by-step reproduction instructions
Screenshots, screen recording, code snippet
No response
Environment info
No response
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
The text was updated successfully, but these errors were encountered: