Allow the specification of blocks allowed within columns #25183
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This an updated version of #18164.
I and @aristath developed a solution to the issue where an individual column could not define any specifically allowed blocks to be added in it. This also applies to newly added columns in the columns block (from the slider at the columns settings) also specify the blocks allowed to be added into that column. We believe that this is important to custom Gutenberg block development to nest blocks in a good and effective way.
How has this been tested?
Me and @aristath have tested this locally.
Screenshots
Types of changes
We have added a new attribute called allowedBlocks in the column, and a childAllowedBlocks attribute within the columns block, which allows for defining the allowed blocks per individual column.
Example of use:
Checklist:
fixes #18161