]> git.localhorst.tv Git - alttp.git/blobdiff - resources/js/components/pages/Front.js
change footer
[alttp.git] / resources / js / components / pages / Front.js
index aa4b333afce9e8087dc8443973fb178f53012e56..42ac7cf9d26e3da9e2239740464f4b87966d2457 100644 (file)
@@ -1,7 +1,37 @@
 import React from 'react';
+import { Button, Col, Container, Image, Row } from 'react-bootstrap';
+import { useNavigate } from 'react-router-dom';
 
-const Front = () => <div className="mt-5 text-center">
-       <h1>It&apos;s a mystery to everyone.</h1>
-</div>;
+import CanonicalLinks from '../common/CanonicalLinks';
+
+const Front = () => {
+       const navigate = useNavigate();
+
+       React.useEffect(() => {
+               const returnPath = localStorage.getItem('returnPath');
+               if (returnPath) {
+                       localStorage.removeItem('returnPath');
+                       navigate(returnPath);
+               }
+       }, []);
+
+       return <Container className="mt-5">
+               <CanonicalLinks base="/" />
+               <Row>
+                       <Col md={{ offset: 3, span: 6 }}>
+                               <Button
+                                       className="front-panel"
+                                       onClick={() => navigate('/tournaments/6')}
+                                       variant="outline-secondary"
+                               >
+                                       <Image alt="" className="image" src="/media/alttp/front.png" />
+                                       <div className="title">
+                                               ALttPR Weekly
+                                       </div>
+                               </Button>
+                       </Col>
+               </Row>
+       </Container>;
+};
 
 export default Front;