-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Group Block - add support for Background Images #14744
Comments
Great would be in this move also a color overlay as with the Cover Block. |
Yeah, I'm not sure about this as this will just be a cover block in the end if we do this. |
As an end user, I understand it this way: Cover Block: a block to add text to a background image at the beginning of a post. Alternatively it can also be used in the middle of a post as call-to-action. Section Block: can do anything. Columns, background color, background image, Section in Section, ect... Simply: The LEGO building block for a website. It would be great to know which block should be used for what. For me the cover block is completely superfluous. The Block section should have all the functions currently available in the cover block. A section block without the possibility to insert pictures just doesn't make sense. This is a must have! |
Thanks for sharing your opinion, let's keep the discussion flowing but let's avoid "absolute" statements. "this doesn't make sense, this is a must have". |
Ok. Sorry! |
I would prefer if the cover block (and all blocks with InnerBlock) supported filtering the list of allowed inner blocks. The themes that want to add 3 columns inside a Cover Block could write the styles to support it. |
Why not use the cover block if the aim is to have a background image ? |
@truchot - the cover block doesn't support nested blocks. Adding to @getdave's feature request: The ability to fix image position and add a background overlay. My use case: |
Yes it does :)
|
o perfect @truchot! Didn't catch that in the release notes. It still doesn't support other blocks, like columns. My question now: Why not get rid of the cover block and just add the same background settings to the group? We can add the extra spacing with a spacing block |
Mockups: (Please note that as this is an older mockup, many general UI elements are outdated.) Some questions:
|
Well, I still think that's a great thing. I hardly use the cover block at all. I'm a big fan of these groups and at the moment I'm still solving everything about the function: individual classes. If this is pushed further, it would be a nice thing for the end user! Please carry on! |
This wouldn't be that difficult to achieve. Personally, I feel it is a worthy addition to the Group Block, but I know others have reservations. |
Discussed during today's accessibility bug scrub, agreed on a couple recommendations:
|
Which setting are the a11y team thinking? |
We haven't discussed specifically which settings. Personal opinion: all the ones that are needed to "get the job done" :) at the very least: edit / replace / remove image. |
+1 |
Either being able to nest more blocks (especially columns) in the cover block; or adding background image and overlay to the groups block would be great. |
Absolutely. It would be nice if a decision was made. |
We discussed this in today's design meeting. It seems like there's a need for a background image option in the group block. However, at this point, it starts competing with the cover image block and I think it would be a good idea to have one type of block for both a start of a page post or a section with all forementioned functionality. |
Are there any developments here? I find this function so fundamental and I as an end user somehow get totally mixed up when to use a group block and when to use a cover block. That's kind of confusing. After posting mtias in #16479 the goal is to add a background function here. Is there a roadmap @getdave or @youknowriad ? |
If anyone is keen to see background images land in the Group block then please do add your 👍 to this experimental PR which looks to add that feature. It would be helpful to gauge the current demand for the feature. Many thanks 🙇 |
+1! |
I'm guessing since there's been little movement on this for a year, it's not happening, but I would like to advocate for it. Adding the ability to put a background image on a Group does not just make it a Cover block. The Cover block is much more "opinionated" in the placement of inner content than a Group is. I would argue that adding the ability to put a background image on a Group might obviate the need for the Cover block at all, but I think there's room for both of them. A good way to think about it is that the Cover block is primarily about the image (with limited options for overlaying content), whereas the Group is primarily about the inner content… and would probably have more limited options for handling the background image. For example, the "Minimum Height of Cover" setting would not make sense, because the inner content of the Group would dictate the height of the image. |
Imo both group and cover block are a failed concept. This “simplicity” or “less is more” type of interfaces always end up being too niched and opinionated. People come to this repo and make suggestions like these, hoping that the development of the block builder will somehow skew towards some utopian free and flexible site builder, which is not what the devs have in mind. If it were then there should have been a container block with ALL the features and all other blocks would have had lots more features, basically following the 3 C’s holy grail of content and page building. Then they would have implemented an API, like the theme json, where features would have been turned off/on or customized. They could even come up with a default config to keep the interface simple and blog oriented or whatever. Of course this will not happen for lots of reasons. |
Is this not a feature at all? How else are you supposed to put a background on a container with core blocks? Maybe I'm missing something but the cover block is not a container, it's kind of a superfluous feature block in my opinion that has few uses. A group block is incredibly flexible, limiting it to only color backgrounds makes no sense. I wonder if it's a limitation in how the block is built? Any other ideas on how to get a background on a container using core blocks? |
Well… it kind of is; you can put any blocks into the inner container of a Cover, including a Group. But that does still leave some weird issues because the Group is inside the Cover's more restrictive padding rules. It just seems to me that the Cover block conceptually missed the mark; eliminating it and giving the Group block some of Cover's capabilities (background image + its positioning/sizing features, overlay color) would address this concern. The problem is a lack of a singular cohesive and comprehensive vision for Gutenberg from the outset, but that kind of Platonic ideal was never possible in reality. Overall I think Gutenberg has shaped up much better than I expected it to early on, but this weird dichotomy between the Cover and Group blocks is definitely a sticking point. I'm guessing the biggest deterrent to combining them would be that the Cover block is something conceptually easier to understand for novice users, who seem to be a primary intended audience for Gutenberg… even though I do not think Gutenberg is easier for novices to understand. |
@paaljoachim the site logo is media - an image we decied it has the meaning of Logo. But backgrounds are style, it should be set from the design panel I think? |
Further use cases
Possible way forward?
|
Sounds good, together with the group renaming option it would give the site editor a huge boost in usability. Is there a possibility to have a dedicated color for the group block, e.g. green, complementing the purple of template parts when it's used as the outer wrapper? |
Since this issue was first submitted, various features have been added to the Cover block.
What would be the ideal approach in light of the latest Gutenberg specifications? |
@jasmussen I concur regarding Inspector controls in particular and also in general that in the Inspector Panel one accumulates way too much time… … scrolling
…clicking the same long pathways again and again due to: The Inspector panel UI certainly needs compacting and clever minimalism to get efficient. |
This comment was marked as off-topic.
This comment was marked as off-topic.
Anyone is welcome to apply to work for Automattic but this definitely isn't the right avenue to discuss. Let's keep it focused on the work at hand. If you'd like to talk about life at Automattic, feel free to ping me on WordPress.org slack (@annezazu there too). |
I really like the approach used in the Site Logo block. Between that and recent work with the HTML Tag Processor, I think we're likely in a good place to re-explore adding in a background image / media block support now. I've opened up a draft PR over in #53934 exploring one way to implement it if anyone would like to take a look! |
The Group Block recently merged with support for background colors. As a next step, it would be good to add support for background images along with the focal picker.
Describe the solution you'd like
This would upgrade the Group Block with the following:
cover
Block) (thanks to @SchneiderSam )Considerations
cover
Block? Or should we encourage users to utilise acover
Block within asection
to achieve this?The text was updated successfully, but these errors were encountered: