Skip to content

Commit

Permalink
Add product details to ProductCard component
Browse files Browse the repository at this point in the history
  • Loading branch information
MuttakinHasib committed Feb 19, 2024
1 parent 0a005b9 commit b954146
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions apps/web/src/components/product/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,23 @@ export const ProductCard = memo(({ product }: Props) => {
priority
/>
</Link>
<div className="px-4 pt-2 bg-white">
<div className="space-y-1">
<div className="text-xs text-gray-500 uppercase">
SKU:{" "}
{product.type === "simple" ? product.sku : product.variants[0]?.sku}
</div>
<div>
<Link
href={`/products/${product.slug}`}
className="text-gray-800 font-medium"
>
{product.name}
</Link>
</div>
</div>
<div className="py-4"></div>
</div>
</div>
);
});
Expand Down

0 comments on commit b954146

Please sign in to comment.