- This topic has 11 replies, 5 voices, and was last updated 3 years, 2 months ago by
Leo.
-
AuthorPosts
-
December 1, 2022 at 6:42 am #2444426
Matthew
Hello,
I switched to Generatepress a few months ago and don’t recall having this issue until recently.
Basically, in a post there should automatically be some padding between any image and the text below it. Recently, all images in my posts have no padding below them.
Example: redacted
This isn’t the case inside the editor. I can resolve it manually by adding space but it should be automatic.
Please help me resolve this.
Thank you
December 1, 2022 at 7:45 am #2444532David
StaffCustomer SupportHi there,
it happened in WP 6.1 where they moved HTML/Classes that applied the bottom margin.
until we find a way to overcome their change without effecting everyones sites who don’t have an issue you will need to add some CSS:figure { margin-bottom: 1.5em; }December 1, 2022 at 10:04 pm #2446070Matthew
Thank you David.
That code only appears to relate to the featured image as the remaining images still have no lower padding (please see same example).
Can you kindly let me know the CSS to apply to all post images?
December 1, 2022 at 10:31 pm #2446089Fernando Customer Support
Hi Matthew,
Can you try updating the code provided to this?:
.wp-block-image figure { margin-bottom: 1.5em; }Let us how it goes.
December 2, 2022 at 1:14 am #2446248Matthew
Hi Fernando,
That seems to work for most images but interestingly now the featured image in the above example is displaying without padding for me. I’ve tried clearing the cache and different browsers. Is it working for you?
Some images on my site still don’t have the padding for some reason but most do.
December 2, 2022 at 1:29 am #2446263Fernando Customer Support
I see. Can you provide the link to a specific post where the code isn’t working for the featured image and some other images?
You may use the Private Information field for this: https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information
December 2, 2022 at 3:56 am #2446472Matthew
Hi Fernando,
I have provided links in the private section.
Thank you
December 2, 2022 at 4:34 am #2446525David
StaffCustomer SupportTry this CSS to cover all bases:
figure, .wp-block-image, .wp-block-image figure { margin-bottom: 1.5em; }December 2, 2022 at 6:56 am #2446689Matthew
That seems to have done the trick. Thank you both.
December 2, 2022 at 8:33 am #2446911David
StaffCustomer SupportGlad to hear that !
February 12, 2023 at 10:18 am #2530554Michael
Is this still the fix? I updated yesterday and it screwed up SOME of our images. But not all. This bandaid fixed it but it’s causing other issues. It is now pushing down out affiliate disclosure block that will tuck up below the first image (not the featured, as it is not displayed, but the first in content image).
It’s probably fixable by giving the affiliate disclosure (it’s a reusable block) it’s own CSS Class and custom CSS, but 1) I don’t feel like trying to figure it out and 2) just seems “unnecessary.”
February 12, 2023 at 2:33 pm #2530720Leo
StaffCustomer SupportHi Michael,
WordPress keeps on changing things so it’s difficult for us to keep up.
Can you start a new topic and link me to the page(s) in question?
We can take a look to see which CSS would work the best in your case.
Thanks!
-
AuthorPosts
- You must be logged in to reply to this topic.