[Resolved] Adding padding to images on mobile

Home Forums Support [Resolved] Adding padding to images on mobile

Home Forums Support Adding padding to images on mobile

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1331188
    John

    Hi there…

    On mobile, I’d like to have just a little padding (right and left) for the images on this page.

    My own CSS attempt isn’t working.

    @media(max-width: 768px) {
        	.wp-block-coblocks-gallery-masonry alignwide {
        	padding: 0 1em 0 1em;
    	}
    }

    Thanks,

    John

    #1331256
    John

    This worked.


    @media
    (max-width: 768px) {
    .coblocks-gallery {
    list-style: none !important;
    padding-left: 2em;
    padding-right: 2em;
    }
    }

    Thank you!

    #1331469
    David
    Staff
    Customer Support

    Glad you found a solution.
    You’re original attempt needed to be this:

    @media(max-width: 768px) {
        .wp-block-coblocks-gallery-masonry {
            padding: 0 1em 0 1em;
            box-sizing: border-box;
        }
    }
    #1331507
    John

    Thank you, David!

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