Skip to content

Commit 46d1a49

Browse files
committed
Remove favorite
1 parent 826bf71 commit 46d1a49

File tree

1 file changed

+0
-23
lines changed

1 file changed

+0
-23
lines changed

src/components/Product/ProductCard.component.tsx

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import Link from 'next/link';
22
import Image from 'next/image';
3-
import { useState } from 'react';
43

54
interface ProductCardProps {
65
databaseId: number;
@@ -19,31 +18,9 @@ const ProductCard = ({
1918
slug,
2019
image,
2120
}: ProductCardProps) => {
22-
const [isFavorite, setIsFavorite] = useState(false);
23-
2421
return (
2522
<div className="group">
2623
<div className="aspect-[3/4] overflow-hidden bg-gray-100 relative">
27-
<button
28-
onClick={() => setIsFavorite(!isFavorite)}
29-
className="absolute right-4 top-4 z-10 rounded-full bg-white p-2 hover:scale-110 transition-transform duration-200"
30-
>
31-
<svg
32-
className={`h-5 w-5 ${
33-
isFavorite ? 'fill-red-500' : 'fill-none stroke-gray-600'
34-
}`}
35-
viewBox="0 0 24 24"
36-
stroke="currentColor"
37-
strokeWidth="2"
38-
>
39-
<path
40-
strokeLinecap="round"
41-
strokeLinejoin="round"
42-
d="M4.318 6.318a4.5 4.5 0 000 6.364L12 20.364l7.682-7.682a4.5 4.5 0 00-6.364-6.364L12 7.636l-1.318-1.318a4.5 4.5 0 00-6.364 0z"
43-
/>
44-
</svg>
45-
</button>
46-
4724
<Link href={`/produkt/${slug}?id=${databaseId}`}>
4825
{image?.sourceUrl ? (
4926
<Image

0 commit comments

Comments
 (0)