How to center images horizontally on Dawn theme

Hi, how can I center an “image with text” section that has only image? I just want to center an image horizontally without any text. For example:

I just want to use an image as a divider? Is there another easier way?

Another example:

@Xaxoxuxu

Sorry you are facing this issue, it would be my pleasure to help you.

Welcome to the Shopify community! :blush:
Thanks for your good question.

Please share your site URL,
I will check out the issue and provide you a solution here.

Hey, thanks for the response.

Site: https://ilimilly.myshopify.com/

password: creugg

I just wanna center for example the “image with section” widget with the little bee on the homepage

@Xaxoxuxu

can you try this code

  1. Go to Online Store->Theme->Edit code
  2. Asset->/base.css ->paste below code at the bottom of the file.
@media screen and (min-width: 750px) {
#shopify-section-template--15307744673979__16429426963923e0ed .grid--2-col-tablet .grid__item {
    max-width: 300px;
}
#shopify-section-template--15307744673979__16429426963923e0ed .image-with-text__grid {
    justify-content: center;
}

#shopify-section-template--15307744673979__16429426963923e0ed .image-with-text__grid .image-with-text__text-item.grid__item {
    display: none;
}
}

Thank you very much, it’s perfect!

Hello! Tried this code but doesn’t seem to work for me. Can you help with this? pyro555.com - pass: laneocinco555

@KetanKumar I tried your code but it’s not working for me. can you help?

https://volcano-king-coffee.myshopify.com/

password: dowsah

@volcanoking

can you please provide screenshot further issue

I want to center the divider between the two products

@KetanKumar when it’s in mobile mode the divider is centered but in desktop mode it’s not. I know the text and button layout is the reason but I want to know how to adjust the alignment. Thanks

Hi @Xaxoxuxu , need to center the image horizontally in the Shopify Dawn Theme? Check out this YouTube video: https://www.youtube.com/watch?v=LNCzj6cxw1s.