-
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
Consider a way to allow/disallow alignment for InnerBlocks #27179
Comments
This sounds similar to what was introduced in #26380 with the Now when a button block is used within the buttons block the alignment option is not displayed, but if it's used outside buttons (I think this is currently only possibly by copy/pasting a button block in the code editor) it still does support alignment. |
Thanks @talldan - does that mean a similar approach could be used with the Social Links block? |
@jordesign Yep, I believe it could be defined on the navigation block to stop inner blocks having alignment. |
Thanks for the direction @talldan - I was able to open a PR with the same approach as that used on the Buttons block. |
Fixed by #27365 |
Problem
Currently, when a block is allowed to be inserted as an InnerBlock it will default to having the same alignment options as normal. In some instances - this isn't appropriate.
Example. In enabling the 'Social Links' block to be included in the Navigation block - the alignment options were still available despite the fact contextually the social links should effectively appear inline with the other menu items. Selecting an alignment for the Social LInks block can break the appearance of the Navigation block altogether
link to image
Ref: #25016
Proposed Solution
It would be great if there were a way to define the alignment support for blocks contextually - or be able to overide it when the block is used as an InnerBlock. Anything above that general idea is above my pay grade ;)
The text was updated successfully, but these errors were encountered: