-
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
Add block gap to Post Content block. #54282
Conversation
Flaky tests detected in 88d932d. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/6118324985
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is testing very nicely for me, too. Great that all the prep work done separately means that this feature just works out of the box once it's switched on!
✅ Styles set in global styles are output correctly.
✅ Block-level block spacing within a template correctly overrides styles set in global styles.
✅ Styles are output correctly in post and page editor, and in the site editor, and editing a single page within the site editor.
✅ Block spacing (correctly) only applies to root level blocks within a post content block, and any nested blocks use their own block spacing values as expected.
Examining the styles in dev tools shows the styles are all being overridden correctly:
- User agent styles are overridden by the layout type's default spacing
- Layout type's default spacing is overridden by post content block in global styles
- Global styles spacing is overridden by block-level styles within the particular template
LGTM! ✨
Thanks for reviewing and testing folks! |
What?
Partially addresses #48902. (I'm not sure how useful adding margin and padding to Post Content might be, though happy to also do so if it's desirable)
We should be able to set a custom spacing in Post Content.
Testing Instructions
Check that block gap can be set on Post Content at the block level as well as in global styles. Gap value should also be correctly reflected in the post editor.