Image shape with text section

Topic summary

Issue: In a Shopify Dawn theme, the “Image with text” block on the home page no longer appears square; the merchant wants it to match the square look used on the About Us page. The source image is square. A live site link and screenshots were provided for context.

Proposed fixes: Two contributors suggested adding custom CSS via Online Store > Themes > Edit code, either in theme.liquid (before ) or in the theme’s CSS file (base.css/style.css/theme.css). The CSS targets the class .image-with-text__media–small using media queries (conditional rules by screen width) to force a square shape by setting explicit height/width values.

Outcome: After applying the first suggestion and adjusting height to 35rem, the image became square on mobile. However, it still isn’t square on desktop.

Follow-up: A second code snippet added a desktop media query, but it did not resolve the desktop shape. The merchant notes previous margin/padding changes may be interfering.

Status: Partially resolved (mobile fixed); desktop issue remains open. Screenshots and the live URL are central to diagnosing the problem.

Summarized with AI on December 29. AI used: gpt-5.

Hi there,> > I have a problem with my website, which I built using Dawn theme.> > The image in the ‘image with text’ section at the bottom of the home page has changed in shape. It used to be square, and I would like it to be square as the image in the ‘image with text’ section in the ‘about us’ page. The original image is square.> > Link and screenshot below.> > Any idea of how to fix this?> > Many thanks> > https://900artanddesign.com/> >

1 Like

Hello @Andrecolap

You can add code by following these steps

  1. Go to Online Store → Theme → Edit code.

  2. Open your theme.liquid file

  3. Paste the below code before on theme.liquid

@media screen and (max-width: 768px){ .image-with-text__media--small { height: 29.2rem !important; } }

Was my reply helpful? Click Like to let me know!
Was your question answered? Mark it as an Accepted Solution.

Hi @Andrecolap

Check this one.

From your Shopify admin dashboard, click on “Online Store” and then “Themes”.

Find the theme that you want to edit and click on “Actions” and then “Edit code”.

In the “Assets” folder, click on “base.css, style.css or theme.css” file, depending on which file your theme uses to store its CSS styles. At the bottom of the file, add the following CSS code:

@media only screen and (max-width:749px){
.image-with-text__media--small {
    height: 60vh;
    width: 60vh;
    margin:auto;
} 
}

And Save.

Result:

Please don’t forget to Like and Mark Solution to the post that helped you. Thanks!

Thank you @niraj_patel

I used your code, adjusted the height to 35 rem, and the image is now again square on mobile.

It still is not square on desktop (see screenshot below), can you suggest any solution?

You can add code by following these steps

  1. Go to Online Store → Theme → Edit code.

  2. Open your theme.liquid file

  3. Paste the below code before on theme.liquid

@media screen and (max-width: 767px) { .image-with-text__media--small { height: 338px !important; } } @media screen and (min-width: 768px) .image-with-text__media--small { height: 31.4rem !important; } }

Was my reply helpful? Click Like to let me know!
Was your question answered? Mark it as an Accepted Solution.

Hi @niraj_patel ,

this didn’t work, I also tried to change something within your code, but that didn’t help. Maybe it is because of some other changes I previously did on margins and paddings.

If you have another solution, please do let me know.

Thank you