SOLVED: Getting rid of "text-wrapper" and a <p>

This post was flagged by the community and is temporarily hidden.

Hi,
is it possible that you’ve fixed it already?

When i inspect the code i can’t see the .text-wrapper or any of the bricks classes :face_with_monocle: , but only generate-blocks classes.

This post was flagged by the community and is temporarily hidden.

Hi,

you’re welcome! Ok, the problem is related to the “text element” that works as a wrapper in your markup. I don´t know how generate blocks works, but you can possibly swap the text element for a container (or maybe a shortcode element?). If the text element is absolutely necessary, you can remove the p-Tag visually (it stays in the markup but won´t cause a layout shift) with the following custom css (add it to the text element style » custom css):

root .text-wrapper p {
  display: none;
}

Best regards,
timmse

1 Like

Thx !
But sorry I’m not sure it comes from GenerateBlocks.
I do have another test on the page mentioned below.
Wrapper is linked to Bricks template while displaying a {post_content}.
I wonder how it could come from Bricks itself ?
Thx a lot !!

Generate Blocks isn’t the problem, but the text element is. There is a function that should remove the p-tag, but it doesn’t seem to work in your case.

You can use the shortcode element instead of the text element to render your {post_content}. That should display your content without the unnecessary tags (both .text-wrapper and the p). Just insert {post_content} into the shortcode element and it should work. Or like i said above, “remove” it with custom css.

1 Like

SOLVED :slight_smile:
Awesome, I use shortcode element and it’s ok.
Won’t disturb for further inspection on that and my consider it’s over :slight_smile:
Thx !!

1 Like