Gallery: removing images doesn't update maximum number of columns #13423
Labels
[Block] Gallery
Affects the Gallery Block - used to display groups of images
[Type] Bug
An existing feature does not function as intended
Describe the bug
Gallery block allows the maximum number of columns not be higher than the number of images.
When removing images via "Edit gallery" button from the block's toolbar, the number columns does not get reflected to "new maximum".
To Reproduce
Steps to reproduce the behavior:
Go to block editor
Add gallery block and some images to it
From the sidebar, change the number of columns to maximum
Press "pen" icon from block's toolbar to "edit gallery"
Remove image from media modal
Observe the number of columns stay higher than the number of images:
Removing images via "x" icons on corners works and updates the number of columns correctly.
Expected behavior
I expected a number of columns to be lowered to match the number of images.
Desktop (please complete the following information):
We found out about this while building a custom gallery block that also relies on media modal:
Automattic/wp-calypso#30015
The text was updated successfully, but these errors were encountered: