50 lines
1.1 KiB
JavaScript
50 lines
1.1 KiB
JavaScript
import Link from "next/link";
|
|
import { useRouter } from "next/router";
|
|
import styles from "../styles/NavBar.module.scss";
|
|
|
|
export default function NavBar() {
|
|
const router = useRouter();
|
|
return (
|
|
<div className={styles.navbar}>
|
|
{/* <Link href="/forum">
|
|
<a
|
|
className={
|
|
styles.link + " " + (router.route == "/forum" && styles.selected)
|
|
}
|
|
>
|
|
Forum
|
|
</a>
|
|
</Link> */}
|
|
<Link href="/exercices">
|
|
<a
|
|
className={
|
|
styles.link +
|
|
" " +
|
|
(router.route == "/exercices/[[...exo]]" && styles.selected)
|
|
}
|
|
>
|
|
Exercices
|
|
</a>
|
|
</Link>
|
|
<Link href="/fiches">
|
|
<a
|
|
className={
|
|
styles.link + " " + (router.route == "/fiches" && styles.selected)
|
|
}
|
|
>
|
|
Fiches PDF
|
|
</a>
|
|
</Link>
|
|
<Link href="/room">
|
|
<a
|
|
className={
|
|
styles.link + " " + (router.route == "/room" && styles.selected)
|
|
}
|
|
>
|
|
Room
|
|
</a>
|
|
</Link>
|
|
</div>
|
|
);
|
|
}
|