Studio theme - Product + Cart Page , make product images all square aspect 1:1

Solved

Studio theme - Product + Cart Page , make product images all square aspect 1:1

Matty2019
Excursionist
38 0 11

Hi,

 

Studio theme - Product + Cart Page , make product images all square aspect 1:1

 

Currently they are all different, and there is no option to force to make the image a aspect 1:1

 

the collection page is fine and is 1:1,

 

seatdripco.au

 

Thanks

Accepted Solution (1)

B2Bridge
Excursionist
334 67 82

This is an accepted solution.

Hi @Matty2019  , you can follow these steps:

Step 1: Open Online Store -> Themes -> Edit code.

Step 2: Find component-card.css file

Step 3: Paste this code at the bottom of the file

 

.product-media-container {
 min-width: 320px !important;
 height: 320px !important;
}
.product-media-container img.image-magnify-lightbox {
 max-height: 320px !important;
}
.cart-drawer .cart-item__image {
 max-width: 110px !important;
 max-height: 110px !important;
 object-fit: cover !important;
}

 

Screenshot_1.png

If this is helpful, please let us know by giving us a like and marking it as a solution. Thank you 😍

B2Bridge: All-in-one B2B wholesale solution, enabling merchants to set up a complete B2B store quickly and without coding.
With features like customizable registration forms, customer segmentation, and tailored price lists, it simplifies wholesale management.
B2Bridge also includes a dedicated Quick Order page and flexible Net Payment Terms, streamlining operations for wholesalers and enhancing the buying experience.

View solution in original post

Replies 2 (2)

Dan-From-Ryviu
Shopify Partner
11360 2227 2399

Hi @Matty2019 

Please add this code at the bottom of your base.css file 

.product .product-media-container {
    --aspect-ratio: 1;
}
.product .product-media-container .product__media img {
    object-fit: contain;
}
.cart-items .cart-item__image {
    aspect-ratio: 1 / 1;
    object-fit: contain;
}

Here is the result

Screenshot 2025-03-10 at 09.47.24.png

- Found this helpful? Hit "Like" and "Accept as Solution"!
- Reton: Loyalty & Rewards - Earn points through tasks, redeem for discounts, and enjoy exclusive VIP rewards!
- Ryviu - Reviews & QA app: Collect product reviews, import reviews from AliExpress, Amazon, Etsy, Walmart, Shopee, Dhgate and CSV.
- Lookfy Gallery: Lookbook Image - Gain customers with photo gallery, video & shoppable image
Built for Shopify

Reelfy‑Shoppable Videos+Reels: Create shoppable videos to engage customers and drive more sales.
- En...
Sign up now.

B2Bridge
Excursionist
334 67 82

This is an accepted solution.

Hi @Matty2019  , you can follow these steps:

Step 1: Open Online Store -> Themes -> Edit code.

Step 2: Find component-card.css file

Step 3: Paste this code at the bottom of the file

 

.product-media-container {
 min-width: 320px !important;
 height: 320px !important;
}
.product-media-container img.image-magnify-lightbox {
 max-height: 320px !important;
}
.cart-drawer .cart-item__image {
 max-width: 110px !important;
 max-height: 110px !important;
 object-fit: cover !important;
}

 

Screenshot_1.png

If this is helpful, please let us know by giving us a like and marking it as a solution. Thank you 😍

B2Bridge: All-in-one B2B wholesale solution, enabling merchants to set up a complete B2B store quickly and without coding.
With features like customizable registration forms, customer segmentation, and tailored price lists, it simplifies wholesale management.
B2Bridge also includes a dedicated Quick Order page and flexible Net Payment Terms, streamlining operations for wholesalers and enhancing the buying experience.