From 6df02d6a2bf6d5ea77f7703917f2709562308a1a Mon Sep 17 00:00:00 2001 From: Rafi Zadanly Date: Sun, 20 Nov 2022 01:08:57 +0700 Subject: Improve page transition and product card badge --- src/components/Layout.js | 10 ++-------- src/components/ProductCard.js | 2 +- 2 files changed, 3 insertions(+), 9 deletions(-) (limited to 'src/components') diff --git a/src/components/Layout.js b/src/components/Layout.js index 42d8ebdf..6933d535 100644 --- a/src/components/Layout.js +++ b/src/components/Layout.js @@ -1,15 +1,9 @@ import { motion } from 'framer-motion'; -export default function Layout({ children, pageProps }) { - const variants = { - hidden: { opacity: 0, x: -75, y: 0 }, - enter: { opacity: 1, x: 0, y: 0 }, - exit: { opacity: 0, x: 0, y: -50 }, - }; - +export default function Layout({ children, ...pageProps }) { const transition = { ease: 'linear', - duration: 0.4 + duration: 0.3 }; return children && ( diff --git a/src/components/ProductCard.js b/src/components/ProductCard.js index 3b0ef162..063a5f6b 100644 --- a/src/components/ProductCard.js +++ b/src/components/ProductCard.js @@ -13,7 +13,7 @@ export default function ProductCard({ data }) { {product.variant_total > 1 ? ( -
{product.variant_total} Varian
+
{product.variant_total} Varian
) : ''}
-- cgit v1.2.3