For my shop I’ve created a few custom liquids. However whenever I do this, for some reason my products on my collection page are alligned wrong on mobile:
When I remove the custom liquid, they’re alligned correctly (gotta use imgur cus I can only upoad 1 image to this post): Imgur: The magic of the Internet
Now what baffles me, is that even if I place a custom liquid on a different page, the products on the collecting page still allign wrong.
Yes I did create all of these with AI, but unfortunately neither me or AI seem to have the solution for this.
Store: https://createe.nl/
Below one of my custom liquids:
<!DOCTYPE html>
<html lang="nl">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Banner met Aleo knoppen</title>
<!-- Tailwind CSS voor de styling -->
<script src="https://cdn.tailwindcss.com"></script>
<!-- Aleo lettertype van Google Fonts -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Aleo:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
<style>
.font-aleo {
font-family: 'Aleo', serif;
}
</style>
</head>
<body class="bg-gray-100 p-8">
<!-- De Banner Container -->
<div class="w-full pt-6">
<!--
Hier zit de padding van 20px aan de linkerkant (pl-[20px]),
ruimte tussen de knoppen en de balk (pb-3),
en de gekleurde streep onderaan (border-b-4 border-[#174D13])
-->
<div class="flex pl-[20px] pb-3 border-b-4 border-[#174D13]">
<a href="https://createe.nl/collections/all" class="nav-link font-aleo text-sm px-4 py-2 bg-transparent border border-black hover:bg-gray-200 text-black mr-2 transition-colors duration-200 inline-block">
Alle Items
</a>
<a href="https://createe.nl/collections/polos" class="nav-link font-aleo text-sm px-4 py-2 bg-transparent border border-black hover:bg-gray-200 text-black mr-2 transition-colors duration-200 inline-block">
Polo's
</a>
<a href="https://createe.nl/collections/tees" class="nav-link font-aleo text-sm px-4 py-2 bg-transparent border border-black hover:bg-gray-200 text-black transition-colors duration-200 inline-block">
Tees
</a>
</div>
</div>
<!-- Script om de actieve pagina zwart te maken -->
<script>
document.addEventListener("DOMContentLoaded", () => {
const navLinks = document.querySelectorAll('.nav-link');
// Pak het pad van de huidige URL (bijv. /collections/all)
const currentPath = window.location.pathname;
navLinks.forEach(link => {
const linkPath = new URL(link.href).pathname;
// Controleer of het huidige URL-pad overeenkomt met het pad van de knop
if (currentPath === linkPath || window.location.href === link.href) {
// Verwijder de standaard styling
link.classList.remove('bg-transparent', 'text-black', 'hover:bg-gray-200');
// Voeg de actieve zwarte styling toe
link.classList.add('bg-black', 'text-white', 'hover:bg-black');
}
});
});
</script>
</body>
</html>
