-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Quote block: remove appender #60307
Quote block: remove appender #60307
Conversation
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Size Change: +45 B (0%) Total Size: 1.72 MB
ℹ️ View Unchanged
|
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 fixes the layout shifting issue. GIF showing clicking the quote block to show a layout shift in trunk:
After, GIF showing the same approach but without the layout shift:
I'd tend to agree that the fixed-position appender as exists in group and other containers may not be needed here, since it's a text block primarily. But it may still be worth investigating, separately, why this container block has a layout shift with the appender present, whereas the Group block does not.
@jasmussen Because even though the appender is position: absolute, the quote has a padding that makes the margin of the paragraph visible, I guess that happens when there's an element after the paragraph even though it positioned. |
Interesting, a paragraph inside a group is not affected by this, presumably that would be the same no? |
@jasmussen No, because that paragraph doesn't have any margin. The CSS from the theme is: .wp-block-quote :where(p) {
margin-block-start: 0;
margin-block-end: calc(var(--wp--preset--spacing--10) + 0.5rem);
} |
Hmm. Curious. In any case, happy to move forward. And the more we can do without that fixed-position appender, IMO, the better. Text-first blocks are the easiest to remove from. |
Yeah agreed. Again a reason to not render these appenders in the canvas. We already do that for some appenders but not all. We should refactor that. |
Co-authored-by: ellatrix <[email protected]> Co-authored-by: jasmussen <[email protected]>
What?
Addresses #59073 (comment).
I'm not convinced we should add an appender for the quote block at all. Quote contents is usually text and easy to press Enter to add blocks, and an empty paragraph comes with an appender.
Why?
How?
Testing Instructions
Testing Instructions for Keyboard
Screenshots or screencast