Jump to content

Centering Products on Shop Page (Desktop)

Go to solution Solved by Beyondspace,

Recommended Posts

Hi all, 

I'm trying to get the products on my shop page to center. I got some code that worked great to center the products on mobile, but the products on desktop are still slightly to the left. Can someone help me with some custom css I can plugin?

Here is the code I am using to center them on mobile:

@media screen and (max-width:767px) {
.products.collection-content-wrapper .products-flex-container .list-grid .grid-item {
    margin: 0 auto;
}
}

Screen shot attached of the desktop view, which is off-center.

Thank you!

Screen Shot 2023-03-04 at 11.13.10 AM.png

Link to comment
21 hours ago, j_m_g said:

Hi all, 

I'm trying to get the products on my shop page to center. I got some code that worked great to center the products on mobile, but the products on desktop are still slightly to the left. Can someone help me with some custom css I can plugin?

Here is the code I am using to center them on mobile:

@media screen and (max-width:767px) {
.products.collection-content-wrapper .products-flex-container .list-grid .grid-item {
    margin: 0 auto;
}
}

Screen shot attached of the desktop view, which is off-center.

Thank you!

Screen Shot 2023-03-04 at 11.13.10 AM.png

Can you share your URL so I can take a look?

Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.
Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio plugin
If you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you

Link to comment
  • Solution

I believe that this code makes your products smaller with only 80% of width. So they are not at aligned center.

image.thumb.png.31b622a112b065865efa8b1faa36a7b8.png

Try removing this code or add the following code to overwrite the one one

.products.collection-content-wrapper .products-flex-container .list-grid .grid-item {
  width: 100%;
}

Support me by pressing 👍 or marking as solution if this is useful for you

Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.
Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio plugin
If you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you

Link to comment

My testing

image.thumb.png.60ab2399253d4668493b3b4af1fa78c1.png

Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.
Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio plugin
If you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.