Shopify themes, liquid, logos, and UX
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Hi,
Is it possible to align the add to cart button from different products to the same height?
Here is my website: https://1cabe3-26.myshopify.com/
Thank you.
Solved! Go to the solution
This is an accepted solution.
In theme customizer, go to Theme Settings, find "Custom CSS" and add the following code:
.product-thumbnail, .product-thumbnail__info {
display: flex;
flex-direction: column;
flex-grow:1;
}
.product__form {
margin-top: auto;
}
Or, can use "Custom CSS" in product grid sections settings
This is an accepted solution.
Yeah, sometimes it happens when you have no access to the source code...
Try this instead:
.product-thumbnail {
min-height: 100%;
}
Hello @Mentorpublish
You can add code by following these steps
1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file
3. Paste the below code before </body> on theme.liquid
<style>
.product-thumbnail__header {
height: 3.5rem;
}
</style>
Was my reply helpful? Click Like to let me know!
Was your question answered? Mark it as an Accepted Solution.
This is an accepted solution.
In theme customizer, go to Theme Settings, find "Custom CSS" and add the following code:
.product-thumbnail, .product-thumbnail__info {
display: flex;
flex-direction: column;
flex-grow:1;
}
.product__form {
margin-top: auto;
}
Or, can use "Custom CSS" in product grid sections settings
Hi @tim ,
Sorry to bother again, just found out if I change the product card from "Grid" to "Slideshow", then the alignment of add to cart will be gone, do you know how to solve this issue?
Thank you very much.
Try adding
.product-thumbnail {
height: 100%;
}
This is an accepted solution.
Yeah, sometimes it happens when you have no access to the source code...
Try this instead:
.product-thumbnail {
min-height: 100%;
}