-
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
Only show grid resizer if grid block allows resizing on children. #61552
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: +25 B (0%) Total Size: 1.74 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.
Good catch! This is testing well for me, with the resizer visible on the Grid block, but not when selecting the Post Template block.
I opted to still display the grid visualiser because I personally like clearly seeing where each spot in the grid starts and ends, but it could also be removed; feedback welcome!
I agree, I found it valuable when clicking through blocks to see the bounds of the Post Template block, particularly when there's no background color present, it helps make it clearer, I think:

LGTM, but also feel free to wait until you've got design feedback if you'd prefer! 🚀
Thanks for the review @andrewserong! I'll go ahead and merge this as it fixes the brokenness, but happy to iterate further on another PR if needed. |
⭐ |
What?
The grid resizer should only appear when the parent block with grid layout explicitly sets
allowSizingOnChildren
. This PR adds a check to only render the resizer if that attribute is present.Testing Instructions
Screenshots or screencast
Trunk:
This branch:
I opted to still display the grid visualiser because I personally like clearly seeing where each spot in the grid starts and ends, but it could also be removed; feedback welcome!