Skip to content

Commit

Permalink
Fix responsivity of min size
Browse files Browse the repository at this point in the history
  • Loading branch information
tellthemachines committed Mar 22, 2023
1 parent 7bb10f9 commit 52bfcc7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/block-supports/layout.php
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ function gutenberg_get_layout_style( $selector, $layout, $has_block_gap_support

$layout_styles[] = array(
'selector' => $selector,
'declarations' => array( 'grid-template-columns' => 'repeat(auto-fill, minmax(' . $minimum_column_width . ', 1fr))' ),
'declarations' => array( 'grid-template-columns' => 'repeat(auto-fill, minmax(min(' . $minimum_column_width . ', 100%), 1fr))' ),
);

if ( $has_block_gap_support && isset( $gap_value ) ) {
Expand Down
2 changes: 1 addition & 1 deletion packages/block-editor/src/layouts/grid.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export default {

if ( minimumColumnWidth ) {
rules.push(
`grid-template-columns: repeat(auto-fill, minmax(${ minimumColumnWidth }, 1fr))`
`grid-template-columns: repeat(auto-fill, minmax(min(${ minimumColumnWidth }, 100%), 1fr))`
);
}

Expand Down

0 comments on commit 52bfcc7

Please sign in to comment.