-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Open
Labels
[Feature] BlocksOverall functionality of blocksOverall functionality of blocks[Type] EnhancementA suggestion for improvement.A suggestion for improvement.
Description
What problem does this address?
In block.json setting the allowVerticalAlignment to true in the following way:
{
"supports": {
"layout": {
"default": {
"type": "flex"
},
"allowVerticalAlignment": true,
"allowJustification": false,
"allowOrientation": false,
"allowInheriting": false
}
}
}
At the moment the default value of the vertical alignment is hardcoded here:
gutenberg/packages/block-editor/src/layouts/flex.js
Lines 200 to 203 in 2478dae
| const defaultVerticalAlignment = | |
| orientation === 'horizontal' | |
| ? verticalAlignmentMap.center | |
| : verticalAlignmentMap.top; |
Based on the orientation it will be either set to center or top.
It would be useful to be able to set the default to a custom value, like for example bottom in the below case:
In the above case, the default position of the Next/Previous buttons for the Product Image Gallery is bottom, but the default vertical alignment set by Gutenberg is center.
Metadata
Metadata
Assignees
Labels
[Feature] BlocksOverall functionality of blocksOverall functionality of blocks[Type] EnhancementA suggestion for improvement.A suggestion for improvement.