- This topic has 6 replies, 3 voices, and was last updated 3 years, 6 months ago by
David.
-
AuthorPosts
-
June 16, 2022 at 6:19 am #2255202
Sam
Hi,
consider this scenario :
I created an element -> added a container -> added a heading.
Pretty simple right?GP automatically adds a
gb-inside-containerdiv inside of my container element. That inside div (in my case) isn’t necessary, non-semantic and I have no way of controlling its visual aspects except via custom CSS.Any way I can prevent GP from adding this auto div?
June 16, 2022 at 6:49 am #2255234David
StaffCustomer SupportHi there,
that comes from the GenerateBlocks plugin container block. And currently there is non way to remove, its something we may address in a future update to the GB Plugin.
Its main purpose is for setting a different inner content width, and for stacking order. Aside from that there should be no visible styles. What issue are you having ?
June 16, 2022 at 7:01 am #2255245Sam
Hello David,
I had some weird CSS issue when I tried to edit a GB hero pattern but, I was able to solve that.
It’s just that I don’t like having unnecessary/non-semantic html elements.September 16, 2022 at 12:44 am #2344492akal
Hi David,
even if I totaly understand its purpose, I’m also wondering if it wouldn’t be a good choice to give to the user the ability to prevent its auto generation. I’ve different scenarios :– When I use uikit (like bootstrap), I have sometime css issue because of this extra container (like for modals, when I add data-parameters to a grid, uikit applies some CSS to the 1st child grid which is the inside-container, so I have to write extra CSS to target this child.
– Or when I use a template (yes I could do it in another way…) to display a canvas as background which gave me :<div class="gb-container gb-container-0292be8f" id="particles-js"> <div class="gb-inside-container"></div> <canvas class="particles-js-canvas-el"></canvas> </div>Which doesn’t leads any issue, but still “unnecessary/non-semantic html elements” (as Sam said)…
Yes this is not an issue, but – in my humble opinion – considering a kind of checkbox “disable inside-container” in the grid block option panel would give a better control ^_^September 16, 2022 at 3:47 am #2344642David
StaffCustomer SupportHi there,
we’re currently working on an update to the Container Block.
this will remove thediv.gb-inside-containerfrom the Container Block by default.For use cases where the inner container is required, users will be able to add another Container inside it, and to simplify that process we will add a Variant Container Block that does that for you.
Any legacy containers will keep their current structure ie. with
div.gb-inside-containerbut we will have an option to convert them to the new version.This update will give you guys what you need and will allow us to utilise the container block for other purposes in GB.
September 16, 2022 at 4:06 am #2344664akal
Great news ! Thank you guys to make wordpress much more fun to work on ^_^
September 17, 2022 at 3:01 am #2345585David
StaffCustomer SupportYou’re welcome
-
AuthorPosts
- You must be logged in to reply to this topic.