Have your say in Community Polls: What was/is your greatest motivation to start your own business?

Re: Grid size by number of products on collection page

Solved

Grid size by number of products on collection page

Okyns
Tourist
12 1 1

Hi!

I am using the Craft theme. There is no problem if the number of products is 4 or more on the collection pages. However, the dimensions of the product field change depending on whether it is 3.2 or 1. When I look at the base.css file, I see that settings such as grid--4-col , grid--3-col , grid--2-col have been made. When making changes to these, the slide show and multi-column areas on the main page are broken. I'm waiting for your help.1_shpfy.jpg2_shpfy.jpg3_shpfy.jpg

Accepted Solutions (2)
AvadaCommerce
Shopify Partner
3879 839 988

This is an accepted solution.

Hi @Okyns ,

 

You can follow the instruction below:

1. Go to Online Store->Theme->Edit code
2. Asset->/base.css->paste below code at the bottom of the file:

@screen (min-width: 990px) {
    #ProductGridContainer #product-grid .grid__item {
        max-width: calc(25% - var(--grid-desktop-horizontal-spacing) * 3 / 4) !important;
    }
}

If you feel like my answer is helpful, please mark it as a SOLUTION. Let me know if you have any further questions.

banned

View solution in original post

Okyns
Tourist
12 1 1

This is an accepted solution.

 

 

Thank you so much .

I changed it with a little touch as follows.

 

@media screen and (min-width: 990px) {
#ProductGridContainer #product-grid .grid__item {
max-width: calc(25% - var(--grid-desktop-horizontal-spacing) * 3 / 4) !important;
     }
}

 

 

I'm marking it as a solution.

View solution in original post

Replies 7 (7)

AvadaCommerce
Shopify Partner
3879 839 988

Hi @Okyns ,

 

Can you clearly note the part you want so we can help you? Do you mean that on the collection page, the grid card will show 4 columns in 1 row?

 

Thanks

banned
Okyns
Tourist
12 1 1

Hi
If there are 4 products in a category, it shows 4 products in a row and everything is fine. But if the number of products is 3 or 2, the image sizes change. I want the image sizes to not change even if the number of products is less than four.

What I want to see are 4 products in 1 line and as below.

1_shpfy.jpg

Okyns
Tourist
12 1 1

I'm waiting for your help

 

 

 

51.jpg

 

52.jpg

AvadaCommerce
Shopify Partner
3879 839 988

Hi @Okyns ,

 

sorry for the slow response

Please share your store URL and if your store is password protected then please provide password too.

So that we can help you.

 

Thank you.

banned
Okyns
Tourist
12 1 1

Hi,

 

My Store :  https://oceanhometextile.de/

Password : weisha

AvadaCommerce
Shopify Partner
3879 839 988

This is an accepted solution.

Hi @Okyns ,

 

You can follow the instruction below:

1. Go to Online Store->Theme->Edit code
2. Asset->/base.css->paste below code at the bottom of the file:

@screen (min-width: 990px) {
    #ProductGridContainer #product-grid .grid__item {
        max-width: calc(25% - var(--grid-desktop-horizontal-spacing) * 3 / 4) !important;
    }
}

If you feel like my answer is helpful, please mark it as a SOLUTION. Let me know if you have any further questions.

banned
Okyns
Tourist
12 1 1

This is an accepted solution.

 

 

Thank you so much .

I changed it with a little touch as follows.

 

@media screen and (min-width: 990px) {
#ProductGridContainer #product-grid .grid__item {
max-width: calc(25% - var(--grid-desktop-horizontal-spacing) * 3 / 4) !important;
     }
}

 

 

I'm marking it as a solution.