WordPress / developer-blog-content

In this GitHub space, WordPress team coordinate content to be published on the Developer Blog. Discussion and montly meetings (first Thu) in WP Slack #core-dev-blog
36 stars 2 forks source link

Using the Grid layout type for theme creators #211

Closed bph closed 4 months ago

bph commented 5 months ago

Discussed in https://github.com/WordPress/developer-blog-content/discussions/94

Originally posted by **justintadlock** April 4, 2023 Gutenberg 15.5 is introducing a new Grid layout type: https://github.com/WordPress/gutenberg/pull/49018 Currently, it's usable as an experimental Group block feature: https://github.com/WordPress/gutenberg/pull/49359 Once this is out of the experimental state, this will be a major layout feature for theme authors, and they'll need to know how to build with it. This is still early in development, so it'll be a while before it's ready for any sort of docs/tutorials. But, I wanted to go ahead and note it for a future post. I'm super excited about this because I've just been wanting to build something like this layout for two years now with proper layout support instead of hacking Columns to make it happen: ![gb-gallery-w-quote](https://user-images.githubusercontent.com/1816309/229821976-a8f99150-0251-47da-a828-986c4f554903.jpg)
justintadlock commented 5 months ago

Because the Grid variation has never landed in core for the Group block, I wanted to tackle this from a different angle.

First, technically, grid support is available to any block (or variation) that opts into it. So, the primary purpose of the post will be showing developers how to enable it in a forward-compatible way for the Group. Basically, creating their own Grid variation.

But this post could also potentially how block developers can enable it for their own blocks.

justintadlock commented 5 months ago

I will draft this here: https://docs.google.com/document/d/1IBogXvaZygADpiTfJ3sMhaWsG74434j42CEOGTZYHFQ/edit?usp=sharing

justintadlock commented 5 months ago

This one is ready for its first review: https://docs.google.com/document/d/1IBogXvaZygADpiTfJ3sMhaWsG74434j42CEOGTZYHFQ/edit?usp=sharing

justintadlock commented 5 months ago

Thanks to @ndiego for the first pass on this.

rmartinezduque commented 4 months ago

@justintadlock, I left a couple of very minor suggestions. Otherwise, the post looks great to me. At first, I had questions about using upper or lower case in "grid," but I see that it follows a consistency when it has been capitalized.

justintadlock commented 4 months ago

Yeah, the uppercase use should specifically be the named variation and lowercase when talking about the CSS feature.

justintadlock commented 4 months ago

I am happy to report that—after nearly a year—this post is finally published! 🥂

Social copy:

Did you know that WordPress has built-in grid support? Learn how to enable it in your WordPress themes and build even more amazing layouts!

https://developer.wordpress.org/news/2024/01/29/how-to-disable-specific-blocks-in-wordpress/

bph commented 4 months ago

scheduled on social for 2/29 or so.

bhdd commented 1 week ago

Did you know that WordPress has built-in grid support? Learn how to enable it in your WordPress themes and build even more amazing layouts! https://developer.wordpress.org/news/2024/01/29/how-to-disable-specific-blocks-in-wordpress/

@justintadlock, should the link be this instead? https://developer.wordpress.org/news/2024/02/06/adding-and-using-grid-support-in-wordpress-themes/