Site logo

[Resolved] Added Custom CSS for Margins on Pictures Doesn’t Affect All

Home Forums Support [Resolved] Added Custom CSS for Margins on Pictures Doesn’t Affect All

Home Forums Support Added Custom CSS for Margins on Pictures Doesn’t Affect All

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #2502769
    Mihail

    Hello,

    I added this custom CSS to add margins to all my photos in single blog posts, as seen in this support topic.

    body.single figure.wp-block-image img{
    margin-top:50px;
    margin-bottom:50px;
    }

    However, it doesn’t change the margins on all my photos. I made sure they are Gutenberg image blocks, but still doesn’t have any effect on them.

    Can you please help me with this? I added the blog post credentials below.

    Thank you!

    #2502805
    David
    Staff
    Customer Support

    Hi there,

    try changing the CSS to:

    body.single .wp-block-image img{
        margin-top:50px;
        margin-bottom:50px;
    }
    #2503489
    Mihail

    Thank you David, this worked! 🙂

    #2503720
    David
    Staff
    Customer Support

    Glad to hear that!

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.