How do I center collection grid?

Solved
Excursionist
26 0 0

https://kvm69ncx3emcsr5v-707682.shopifypreview.com

^ I need help aligning the collection grid to the center. This happened after manually removing a sidebar from the code, not sure if I've removed anything vital. 

0 Likes
Shopify Partner
45 13 9

Hi @wwqqq ,

 

1. Go to Online Store->Theme->Edit code
2. Asset->theme.scss->paste bellow code in bottom of file

 

This is the css code for increasing width of the grid to 100%.

 

@media (min-width: 992px){
.pageCollectionInner .col-md-9 {
width: 100% !important;
}
}

@media (min-width: 768px){
.pageCollectionInner .col-sm-8 {
width: 100%;
}
}

Let me know if it works.

Thanks

 

If helpful then please Like and Accept Solution.
Email: mijan.karim@yahoo.com
Skype: mijan.karim
0 Likes
Shopify Partner
45 13 9

Hi, This is the css code just centering without increasing width to 100%.

 

@media (min-width: 992px){
.pageCollectionInner .col-md-9 {
    margin: 0 auto;
    float: none;
}
}

@media (min-width: 768px){
.pageCollectionInner .col-sm-8 {
    margin: 0 auto;
    float: none;
}
}
If helpful then please Like and Accept Solution.
Email: mijan.karim@yahoo.com
Skype: mijan.karim
0 Likes

Success.

Shopify Expert
84 14 16

Hi,

Find id="proListCollection" in your collection page and change class "col-md-9" to "col-md-12".

See the image for better understand Untitled-1.jpg

 

Thank you :)

0 Likes
Excursionist
26 0 0

thanks it works for now! 

0 Likes
Excursionist
26 0 0

hi thanks for reaching out! I pasted this at the bottom of theme.liquid, but it doesn't work. Are there any alternatives for this?

0 Likes