Gallery Block Fix in WordPress 6.1

WordPress 6.1 modified the coding for the Image Gallery Block. This modification has caused the Gallery Block to display incorrectly in many WordPress themes (the Button block may also be affected on some sites). While we await WordPress to fix this issue, we have a workaround for you!

Copy the code snippet below and paste it at WordPress > Appearance > Customize > Additional CSS.

.is-layout-flex {
  display: flex;
  gap: 0.5em;
  flex-wrap: wrap; }