bugfix on homepage (filter and buttons)

This commit is contained in:
Laura Dolibois
2025-05-31 20:56:06 +02:00
parent d97a135b2f
commit 339af6f318
4 changed files with 42 additions and 23 deletions

View File

@@ -39,9 +39,6 @@ export default function ItemCard({ item }: { item: Item }) {
<Rating name="half-rating" readOnly defaultValue={item.rating} precision={0.5} />
<Typography variant="body2" sx={{ color: 'text.secondary' }} className="item-description">
{(item.price * (1 - item.discount / 100)).toFixed(2)}
<IconButton aria-label={t('addToCart')} onClick={handleAddToCart}>
<AddShoppingCart />
</IconButton>
</Typography>
{item.stock > 10 ? (
@@ -59,6 +56,11 @@ export default function ItemCard({ item }: { item: Item }) {
)}
</CardContent>
</CardActionArea>
<CardContent>
<IconButton aria-label={t('addToCart')} onClick={handleAddToCart}>
<AddShoppingCart />
</IconButton>
</CardContent>
</Card>
</Paper>
)