Re: Dawn 'Image with text' section - make image smaller

Solved

Dawn 'Image with text' section - make image smaller

hnaegele
Excursionist
30 1 3

Hi there - I'm using the Dawn theme and on my homepage I have two "Text with image" containers.   I've managed to make the image square by pasting the following code in the theme.liquid section above the tag </head>:

 

<style>
.image-with-text .image-with-text__media-item.image-with-text__media-item--small{
width: 50% !important;
}
</style>

 

I would like the images to remain square but make them smaller - maybe 75% of the current size.  Here is the current page - https://29and11.com/  Could anyone help me with that?

 

Thank you!

Accepted Solution (1)
Made4uo-Ribe
Shopify Partner
9846 2340 2934

This is an accepted solution.

Yep, since you take 30% of 100% height n width. We can add 15% margin. 

The margin will add automatic in all sides.

 

.image-with-text .image-with-text__media-item.image-with-text__media-item--small img {
    height: 70%;
    width: 70%;
    margin: 15%;
}

 

And Save.

Result;

Made4uoRibe_1-1712952547941.png

 

 

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

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.

View solution in original post

Replies 4 (4)

Made4uo-Ribe
Shopify Partner
9846 2340 2934

Hi @hnaegele 

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:

 

.image-with-text .image-with-text__media-item.image-with-text__media-item--small img {
    height: 75%;
    width: 75%;
}

 

And Save. 

Result:

Made4uoRibe_0-1712950733874.png

 

 

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

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.
hnaegele
Excursionist
30 1 3

That definitely made the pictures the size I was hoping for - thank you!! Now my issue appears to be that they aren't centered with the text.  Is there a way to center them and have the spacing between the picture and text equal with the space on the margins?  In the top text with image container, the margins to the right of the picture are large, and in the lower text with image container, the space between the picture and text is large.  Is there some way to evenly distribute the spacing?

 

Thank you so much!!

Made4uo-Ribe
Shopify Partner
9846 2340 2934

This is an accepted solution.

Yep, since you take 30% of 100% height n width. We can add 15% margin. 

The margin will add automatic in all sides.

 

.image-with-text .image-with-text__media-item.image-with-text__media-item--small img {
    height: 70%;
    width: 70%;
    margin: 15%;
}

 

And Save.

Result;

Made4uoRibe_1-1712952547941.png

 

 

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

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.
hnaegele
Excursionist
30 1 3

That worked perfectly - thank you so much for your help!!  You are a lifesaver!!! - Haley