summaryrefslogtreecommitdiff
path: root/src/components/ProductCard.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/ProductCard.js')
-rw-r--r--src/components/ProductCard.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/components/ProductCard.js b/src/components/ProductCard.js
index b8967cc8..2cb0d99b 100644
--- a/src/components/ProductCard.js
+++ b/src/components/ProductCard.js
@@ -1,10 +1,8 @@
import Link from "./Link";
import currencyFormat from "../helpers/currencyFormat";
import { createSlug } from "../helpers/slug";
-import { LazyLoadImage } from "react-lazy-load-image-component";
import { ChevronRightIcon } from "@heroicons/react/20/solid";
-
-import 'react-lazy-load-image-component/src/effects/blur.css';
+import Image from "./Image";
export default function ProductCard({ data }) {
@@ -12,7 +10,11 @@ export default function ProductCard({ data }) {
return (
<div className="product-card">
<Link href={'/shop/product/' + createSlug(product.name, product.id)} className="block relative bg-white">
- <LazyLoadImage effect="blur" src={product.image ? product.image : '/images/noimage.jpeg'} alt={product.name} className="product-card__image" />
+ <Image
+ src={product.image}
+ alt={product.name}
+ className="product-card__image"
+ />
{product.variant_total > 1 ? (
<div className="absolute bottom-2 left-2 badge-gray">{product.variant_total} Varian</div>
) : ''}