front: CordaCheckers online tgl

This commit is contained in:
djmil 2023-10-19 16:09:19 +02:00
parent c884494618
commit a16b886645
3 changed files with 9 additions and 5 deletions

View File

@ -9,14 +9,12 @@ import {
import Header from "./components/Header"
import Leaderboard from "./components/Leaderboard"
import GameProposal from "./components/GameProposal"
import DataPolling from './components/OfflineToggle';
function App() {
return <div className="App">
<BrowserRouter>
<Header/>
<DataPolling/>
<div className="Container">
<Routes>
<Route path="/leaderboard" element={<Leaderboard/>} />

View File

@ -1,3 +1,7 @@
p {
margin-bottom: 30px;
h1 {
display: inline-flex;
}
.OfflineToggle {
margin-left: 15px;
}

View File

@ -1,11 +1,13 @@
import './index.css';
import React from "react"
import { Link } from "react-router-dom";
import OfflineToggle from '../OfflineToggle';
export default function Header() {
return <div>
<h1>CordaCheckers</h1>
<h1>CordaCheckers <OfflineToggle/> </h1>
<nav>
<Link to="/leaderboard">Leaderboard</Link> {"| "}
<Link to="/gameproposal">Game Proposal</Link> {"| "}