1. Sally G

    The more I hear about blocks, the less I like them. Newbie user, not developer, and my work is with small, volunteer organizations’ sites, so not a commercially important reaction.

    Just a question—what is wrong with using columns of individual images? It seems very understandable, columns keep the images properly lined up, and presumably the images could be whatever shape one wants? Why must there be a single gallery holding them all, why not just have the ability to group them into a unit, as one does on a print-layout page if one wants to move them together?


    • Justin Tadlock

      From a technical standpoint, columns and galleries are not the same thing. I would describe them both as different subsets of layout grids, each with their own pros and cons. Columns don’t have rows, for example. You could fake them with the Columns block, but you couldn’t do things like equal-height image cropping with it, automatically switching all the image sizes at once, or just any bulk operations on all the images in the group at once.

      And, there is certainly nothing wrong with a user building out a custom image layout via the Columns block. However, it’s simply easier to get images loaded up and laid out automatically with the Gallery block.

      I could also potentially see some accessibility concerns. Or, at least there are semantic markup issues using Columns if you are, in fact, building a gallery — in my mind, that automatically creates accessibility issues. The end result might look OK, but the under-the-hood stuff would be problematic.

      From the user experience end of things, I would think the average user would jump to using the Gallery block before the Columns block to create an image gallery. It might not be until later (after adding their images) that they realize there are some missing features. So, it makes sense to round out the feature set of the Gallery block, which is the common starting point.


  2. Emma

    It’s funny cause this change got requested back when WP 5.0 still didn’t exist:


    Just to be closed with the following answers: “I am not sure nested image blocks make sense” and “I don’t see how nested blocks helps this”. What’s changed now?

    This shows how open to external ideas Gutenberg devs are.


    • Justin Tadlock

      I’ve seen the ticket. The first reply was asking for additional feedback. But, the OP never answered what were legitimate questions. Having a different opinion doesn’t mean that you’re not open.

      Admittedly, I thought it was closed prematurely after a week, but the person closing also said they were happy to reopen with more insight.

      Sending out feature requests is fine. However, you need to back up your arguments for inclusion of something new or changes to features. Basically saying, “I want this,” is not always good enough to give a request the green light.

      What changed? Someone put in the time and effort to make it happen.


  3. Bjarne

    As a Gutenberg fan, I welcome such improvements, even if it means I have to refactor some custom code. Mostly it’s for the better, and how many popular page builders are held back and unable to utilize modern techniques as css grid or custom properties due to backwards compatibility? It’s not much fun.

    But forgive me for the maybe stupid question. But could Gutenberg not just let the old gallery block be as is, and create a new “modern gallery” block, maybe offering that as default when inserting? It can’t be that much legacy code. Out of date blocks could even be moved to a plugin during transition? Like the classic editor? I could do without the spacer block – that’s for sure. :)


  4. Glen Davies

    Thanks for writeup!

    “While the expectation is nothing changes in terms of output … This statement could be misleading

    Thanks also for pointing this out. The “nothing changes in terms of output” was in terms of what the end user sees, but I can see how most people reading this post would be thinking in terms of html output, so I will try and get that post updated with something like the following, which also explains the reason for the underlying markup change.

    “While the expectation is nothing changes in terms of output for the end user, this is a pretty major change on a technical level for a very popular block, including a change in the underlying markup to align it with the W3C WAI guidelines on grouping of images (https://www.w3.org/WAI/tutorials/images/groups/), so it’d be a huge help to gather as much testing feedback as possible.”


    • Justin Tadlock

      Great! That wording is much better.

      Given that the Make blogs tend to have a more dev-friendly audience, I wanted to make sure folks didn’t gloss over it, thinking it wouldn’t affect something like theme styles.


    • Justin Tadlock

      Also, linking out to the W3C WAI guidelines on image grouping bolsters the argument for the markup change. It provides much better context.


Comments are closed.

%d bloggers like this: