Improve loading speed immensely
This commit is contained in:
@@ -63,7 +63,7 @@ export default function ItemCard({ item }: { item: Item }) {
|
||||
<Typography gutterBottom variant="h5" component="div">
|
||||
{item.name}
|
||||
</Typography>
|
||||
<Rating name="half-rating" readOnly defaultValue={item.rating /2} precision={0.01} />
|
||||
<Rating name="half-rating" readOnly defaultValue={item.rating /2} precision={0.5} />
|
||||
<Box sx={{ display: "flex", justifyContent: "space-between", alignItems: "flex-end" }}>
|
||||
<Typography variant="body2" sx={{ color: 'text.secondary' }} className="item-description">
|
||||
{(item.price100 / 100 * (1 - item.discount100 / 100)).toFixed(2)} €
|
||||
|
||||
@@ -107,7 +107,7 @@ export default function ProductInfo({ item }: { item: Item }) {
|
||||
</Typography>
|
||||
|
||||
<Box display="flex" alignItems="center" gap={1}>
|
||||
<Rating value={item.rating /2} precision={0.01} readOnly />
|
||||
<Rating value={item.rating /2} precision={0.5} readOnly />
|
||||
<Typography variant="body2" color="text.secondary">
|
||||
{item.rating > 0 ? `(${item.rating / 2} / 5)` : t('noRatingsYet')}
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ export default function RatingCard(ratingType: RatingType) {
|
||||
name="half-rating"
|
||||
readOnly
|
||||
defaultValue={ratingType.rating / 2}
|
||||
precision={0.01}
|
||||
precision={0.5}
|
||||
/>
|
||||
|
||||
<Typography
|
||||
|
||||
Reference in New Issue
Block a user