How can I set image grid spacing to 0 in my design?

Solved

How can I set image grid spacing to 0 in my design?

NachoBCN12
Excursionist
35 1 7

I wnat to put no spaces between the grid of images. I've tried to change it through the design section, but it doesn't allow me to reduce it to less than 4 px. Could you provide me with the code to set that space to 0?

Accepted Solution (1)

Made4uo-Ribe
Shopify Partner
10038 2387 3014

This is an accepted solution.

Hi @NachoBCN12 

Its the product grid you mean?

Then try 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:

 

.grid {
    column-gap: 0px !important;
    row-gap: 0px !important;
}

 

  • And Save. 
  • Result:
  • Made4uoRibe_0-1695984637843.png
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 3 (3)

Artzen_tech
Shopify Partner
552 113 111

Hello @NachoBCN12 
Its Artzen Technologies! We will be happy to help you today.

 

You can try to follow these steps:

Go to Online Store -> Themes -> Actions -> Edit code.

Go Assets folder -> theme.liquid file.

Add the following code in the bottom of the file above </body> tag

<style>
.product__media-wrapper ul.product__media-list.contains-media {
    row-gap: 2px;
    column-gap: 2px;
}
</style>

like this :-

Artzen_tech_0-1695984984765.png

 

 

Let me know if need further assistance
Regards,
Artzen Technologies

If helpful, please Like and Accept this Solution to help others
Artzen Technologies | A Shopify Development Agency
WhatsApp - 9877983930

Book FREE CONSULTATION who want to migrate to Shopify or want to start an eCommerce business with Shopify

Made4uo-Ribe
Shopify Partner
10038 2387 3014

This is an accepted solution.

Hi @NachoBCN12 

Its the product grid you mean?

Then try 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:

 

.grid {
    column-gap: 0px !important;
    row-gap: 0px !important;
}

 

  • And Save. 
  • Result:
  • Made4uoRibe_0-1695984637843.png
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.
NachoBCN12
Excursionist
35 1 7

And to delete the border of the images?? thank you very much!