add a navpusher to fix nav's overlapping issues
due to the "sticky" nature of the navigation bar used in the site content would get pushed under it and hidden another element with the height of the navbar has been added that now fixed this issue
This commit is contained in:
@@ -3,20 +3,29 @@ import { GractwoLogo } from "./GractwoLogo";
|
||||
|
||||
export default function Home() {
|
||||
return (
|
||||
<nav className="main">
|
||||
<GractwoLogo className="logo" />
|
||||
<Link href="/">
|
||||
<a>Główna</a>
|
||||
</Link>
|
||||
<Link href="">
|
||||
<a>Rankingi</a>
|
||||
</Link>
|
||||
<Link href="/o-gractwie">
|
||||
<a>O Gractwie</a>
|
||||
</Link>
|
||||
<Link href="">
|
||||
<a>Zaloguj się</a>
|
||||
</Link>
|
||||
</nav>
|
||||
<>
|
||||
<nav className="main">
|
||||
<GractwoLogo className="logo" />
|
||||
<Link href="/">
|
||||
<a>Główna</a>
|
||||
</Link>
|
||||
<Link href="">
|
||||
<a>Rankingi</a>
|
||||
</Link>
|
||||
<Link href="/o-gractwie">
|
||||
<a>O Gractwie</a>
|
||||
</Link>
|
||||
<Link href="">
|
||||
<a>Zaloguj się</a>
|
||||
</Link>
|
||||
</nav>
|
||||
<p className="navpusher">
|
||||
I'm coming after you.
|
||||
{/*
|
||||
This is rendered behind the navbar, pushing the main page's
|
||||
content downwards while keeping nav's fixed position.
|
||||
*/}
|
||||
</p>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -18,6 +18,9 @@ body {
|
||||
scrollbar-width: none; /* Firefox */
|
||||
}
|
||||
|
||||
.navpusher {
|
||||
height: 4rem;
|
||||
}
|
||||
nav.main {
|
||||
z-index: 1;
|
||||
height: 4rem;
|
||||
|
||||
Reference in New Issue
Block a user