From 1d3a0db4d8565b1da8e8ba46b820f0d96c26ca02 Mon Sep 17 00:00:00 2001 From: Mekan1206 Date: Sat, 6 Jun 2026 00:33:55 +0500 Subject: [PATCH] ok --- resources/views/home.blade.php | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/resources/views/home.blade.php b/resources/views/home.blade.php index 8e0fb0f..cd752e5 100644 --- a/resources/views/home.blade.php +++ b/resources/views/home.blade.php @@ -150,27 +150,14 @@ btn.classList.add(...activeClasses); // 2. Filter products - let visibleIndex = 0; - productCards.forEach(card => { - // Reset animation state - card.classList.remove('is-visible'); - if (category === 'all' || card.getAttribute('data-category') === category) { card.style.display = 'block'; - - // Recalculate transition delay dynamically based on visible items - card.style.transitionDelay = `${(visibleIndex % 4) * 100}ms`; - visibleIndex++; - - // Small timeout to allow browser to register display:block before animating - setTimeout(() => { - card.classList.add('is-visible'); - }, 50); + // Ensure it's visible without waiting for scroll animation + card.classList.add('is-visible'); + card.style.transitionDelay = '0ms'; } else { card.style.display = 'none'; - // Reset delay so it doesn't affect future changes - card.style.transitionDelay = '0ms'; } }); });