Shopify themes, liquid, logos, and UX
Hi,
I am trying to fix something that looks kinda ugly and would appreciate some advice to fix it. For the home page I am trying to get both the widgets levelled at the bottom, for the product page I am trying to get both levelled at the bottom as well but also moved above the add to cart button when it appears by scrolling down. I would highly appreciate any help that comes my way.
Kind regards,
Ibrahim W.
Hello @IbrahimWB
Go to Online Store, then Theme, and select Edit Code.
Search for Layout/theme.liquid
Add the provided code at the end of the file.
<script>
if (!document.querySelector('.sticky-cart-button')) {
const dropdownStyle = document.querySelector('.baDropdownStyle.mobile_bottom_left:not(.hideOnMobile)');
if (dropdownStyle) {
dropdownStyle.style.bottom = '-20px!important';
}
}
document.addEventListener('DOMContentLoaded', function() {
const whatsappWidget = document.querySelector('.whatsapp-widget');
if (whatsappWidget) {
whatsappWidget.style.bottom = '50px';
}
});
</script>
Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025Discover opportunities to improve SEO with new guidance available from Shopify’s growth...
By Jacqui May 1, 2025