front: GameHeader as one line of elemnts

This commit is contained in:
djmil 2023-10-27 13:41:56 +02:00
parent 74c396bea7
commit b6994554b3
3 changed files with 40 additions and 40 deletions

View File

@ -1,19 +1,19 @@
h1 {
display: inline-flex;
}
.OnlineTgl {
transform: scale(.25, .25);
width: 1px;
height: 1px;
transform: scale(.5);
margin-left: -19px;
}
.app-header {
padding: auto;
display: flex;
}
.app-header nav {
align-items: center;
justify-content: center;
display: flex;
flex-wrap: wrap;
padding-top: 10px;
}
.app-header a {

View File

@ -8,11 +8,22 @@ import { AppData } from "../../context/data"
export default function Header() {
const [data] = React.useContext(AppData)
return <div>
return (
<div className='app-header'>
<h1 >
CordaCheckers<OnlineToggle />
CordaCheckers
</h1>
<nav className='app-header'>
<OnlineToggle />
<nav>
<NavLink to="/about" className={""}>
About
</NavLink>
<NavLink to="/game" className={data.gamesFetching && "woble"}>
<span>G</span>
<span>a</span>
<span>m</span>
<span>e</span>
</NavLink>
<NavLink to="/leaderboard" className={data.leaderboardFetching && "woble"}>
<span>L</span>
<span>e</span>
@ -26,17 +37,7 @@ export default function Header() {
<span>r</span>
<span>d</span>
</NavLink>
<NavLink to="/game" className={data.gamesFetching && "woble"}>
<span>G</span>
<span>a</span>
<span>m</span>
<span>e</span>
</NavLink>
<NavLink to="/about" className={""}>
About
</NavLink>
</nav>
</div>
)
}

View File

@ -1,4 +1,3 @@
.tgl {
display: none;