Shopify themes, liquid, logos, and UX
Hi, my banner image crops on mobile and I looked most of the discussions and tried various css codes in them but none of them worked out. My site is gamaderma.com can anyone help me please?
Solved! Go to the solution
This is an accepted solution.
@knrys please add this code also
.banner--medium:not(.banner--mobile-bottom):not(.banner--adapt) .banner__content {
min-height: 15rem;
}
let me know
This is an accepted solution.
@knrys here is the steps
1, https://prnt.sc/5i6qGO96Ubqe
2, https://prnt.sc/FJ0HK_5ENIK2
Hey @knrys
Follow these Steps:
1) Go to Online Store
2) Edit Code
3) Find theme.liquid file
4) Add the following code in the bottom of the file above </body> tag
<style>
.banner__media.media.scroll-trigger.animate--fade-in img {
object-fit: contain !important;
}
</style>
RESULT:
If I managed to help you then, don't forget to Like it and Mark it as Solution!
Best Regards,
Moeed
<style>
@media only screen and (max-width: 767px) {
.banner__media.media.scroll-trigger.animate--fade-in img {
object-fit: contain;
}
}
</style>
Thank you it worked but now there is grey spaces in top and bottom. Can I make it that only the banner looks in full resolution without spaces
This is an accepted solution.
@knrys please add this code also
.banner--medium:not(.banner--mobile-bottom):not(.banner--adapt) .banner__content {
min-height: 15rem;
}
let me know
I couldn't find dm but filled the form in your website.
This is an accepted solution.
@knrys here is the steps
1, https://prnt.sc/5i6qGO96Ubqe
2, https://prnt.sc/FJ0HK_5ENIK2
Hey @knrys
You could try updating the css with the following code.
@media screen and (max-width: 749px) {
.banner--medium:not(.banner--mobile-bottom):not(.banner--adapt) .banner__content {
min-height: 15rem;
}
.banner__media.media.scroll-trigger.animate--fade-in img {
object-fit:contain;
}
}
Updating the min height that is set should remove the grey space above and below the image
I added this to theme.liquid but it didn't work. Sorry I do not understand coding where should I exactly paste this?
As 2024 wraps up, the dropshipping landscape is already shifting towards 2025's trends....
By JasonH Nov 27, 2024Hey Community! It’s time to share some appreciation and celebrate what we have accomplis...
By JasonH Nov 14, 2024In today’s interview, we sat down with @BSS-Commerce to discuss practical strategies f...
By JasonH Nov 13, 2024