Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix default width for flow children
  • Loading branch information
tellthemachines committed Feb 27, 2024
commit 39140e3700497db5664a9067c9283232628e2316
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,10 @@ export default function ChildLayoutControl( {
selectedValue = 'fixedNoShrink';
} else if ( selfAlign === 'fit' ) {
selectedValue = 'fit';
} else {
} else if ( parentLayoutType === 'constrained' ) {
selectedValue = 'content';
} else {
selectedValue = 'fill';
}
} else if (
parentLayoutType === 'flex' &&
Expand Down Expand Up @@ -256,10 +258,10 @@ export default function ChildLayoutControl( {
...childLayout,
[ widthProp ]: key,
} );
onChangeAlignment( null );
onChangeAlignment( undefined );
} else {
onChange( { [ widthProp ]: key } );
onChangeAlignment( null );
onChangeAlignment( undefined );
}
} else if ( parentLayoutType === 'flex' ) {
onChange( {
Expand Down