Scale down image to fit container for image with text on Dawn theme

Scale down image to fit container for image with text on Dawn theme

Dazhal
Visitor
1 0 0

For Dawn Theme, image with text.

 

Currently my image will not fit. I don't want the image and text section to over lap or the image to be cropped or distorted. I want the image to use the object-fit scale down or contain.

 

The below logo contains the word "Lossnay" and the y on the end is being cropped. 

 

https://dd42f1-55.myshopify.com/pages/heat-recovery-ventilation

 

Password: staetu

 

Dazhal_0-1725499942070.png

 

Thank you

 

Replies 3 (3)

BSSCommerce-B2B
Shopify Partner
1972 564 568

@Dazhal 

Step 1: Go to Admin -> Online store -> Theme > Edit code

BSSCommerceB2B_0-1725500381910.png

Step 2:   Find the file theme.liquid 

Step 3: Paste the below code before </body> on theme.liquid

 

<style>
.section-template--15660508512319__image_with_text_nDeGkb-padding img {
   object-fit: contain!important;
}
</style>

Result:

BSSCommerceB2B_1-1725500459088.png

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

 

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

Dan-From-Ryviu
Shopify Partner
11612 2276 2456

Hi @Dazhal 

Please add this code to Custom CSS of that section

img { object-fit: contain !important; }

Screenshot 2024-09-05 at 08.41.53.png

- Helpful? Like & Accept solution!
- Ryviu - Product Reviews & QA app: Collect customer reviews, import reviews from AliExpress, Amazon, Etsy, Walmart, Dhgate and CSV.
- Reton: Loyalty & Rewards - Earn points through tasks, redeem for discounts, and enjoy exclusive VIP rewards!
- Lookfy Gallery: Lookbook Image - Gain customers with photo gallery, video & shoppable image
- Reelfy‑Shoppable Videos+Reels: Create shoppable videos to engage customers and drive more sales.
- En...
Sign up now.

topnewyork
Astronaut
1332 161 220

Hi @Dazhal ,

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file
3. In theme.liquid, paste the below code before </head>

 

<style>
.section-template--15660508512319__image_with_text_nDeGkb-padding img {
   object-fit: contain !important;
}
</style>

 

If my reply is helpful, kindly click like and mark it as an accepted solution.

Thanks!

Need a Shopify developer? Hire us at Top New York Web Design
Boost Your Store Sales with Volume/Tier Discount Try Big Bulk Discount
Create New Shopify Store For Just 1$/Month