added translation for product page
This commit is contained in:
@@ -9,9 +9,12 @@ import { useLocation, useNavigate } from 'react-router-dom';
|
||||
import Item from '../components/Item';
|
||||
import ProductInfo from '../helper/productpage/ProductInfo';
|
||||
import Ratings from '../helper/productpage/Ratings';
|
||||
import {useTranslation} from "react-i18next";
|
||||
|
||||
|
||||
export default function Product() {
|
||||
|
||||
const { t } = useTranslation();
|
||||
const location = useLocation();
|
||||
const item = location.state?.item as Item;
|
||||
const navigate = useNavigate();
|
||||
@@ -25,10 +28,10 @@ export default function Product() {
|
||||
return (
|
||||
<Box className="no-page-container">
|
||||
<Typography variant="h1" className="no-page-title">
|
||||
Product not found
|
||||
{t('productNotFound')}
|
||||
</Typography>
|
||||
<Typography variant="h5" className="no-page-description">
|
||||
It seems you are locking for a product that doesn't exist or has been removed.
|
||||
{t('productDoesNotExist')}
|
||||
</Typography>
|
||||
<Button
|
||||
variant="contained"
|
||||
@@ -37,7 +40,7 @@ export default function Product() {
|
||||
className="no-page-button"
|
||||
onClick={handleGoHome}
|
||||
>
|
||||
Go Back to Home
|
||||
{t('backToHome')}
|
||||
</Button>
|
||||
</Box>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user