You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
967 B
38 lines
967 B
|
|
import React from 'react';
|
|
import { useTheme } from '../Style/ThemeContext';
|
|
import { Link } from 'react-router-dom';
|
|
import './ErrorStyle.css';
|
|
import { FormattedMessage } from 'react-intl';
|
|
import { Button } from 'react-bootstrap';
|
|
|
|
|
|
|
|
//@ts-ignore
|
|
function ErrorPage({ code = "", msg = "Something is wrong"}) {
|
|
|
|
const theme = useTheme();
|
|
|
|
|
|
return (
|
|
<div className='mainErrorDiv'>
|
|
<div className='titleError'>
|
|
<div>
|
|
<h1>ERROR</h1>
|
|
<hr style={{width:"100%"}}/>
|
|
</div>
|
|
{ code != "" &&
|
|
<h1 style={{color:'darkred', margin:'10px'}}>{code}</h1>
|
|
}
|
|
<h2>{msg}</h2>
|
|
</div>
|
|
|
|
<div className='centerDivH' style={{margin: "20px"}}>
|
|
<Button href='/' variant='danger'>Retour à l'accueil</Button>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export default ErrorPage;
|