mirror of
https://github.com/tubearchivist/tubearchivist-frontend.git
synced 2024-11-22 11:50:14 +00:00
chore: update links to next/link
This commit is contained in:
parent
9988779f3a
commit
99316eeee8
@ -1,15 +1,19 @@
|
|||||||
import NextImage from "next/image";
|
import NextImage from "next/image";
|
||||||
|
import NextLink from "next/link";
|
||||||
import BannerDark from "../images/banner-tube-archivist-dark.png";
|
import BannerDark from "../images/banner-tube-archivist-dark.png";
|
||||||
import IconSearch from "../images/icon-search.svg";
|
import IconSearch from "../images/icon-search.svg";
|
||||||
import IconGear from "../images/icon-gear.svg";
|
import IconGear from "../images/icon-gear.svg";
|
||||||
import IconExit from "../images/icon-exit.svg";
|
import IconExit from "../images/icon-exit.svg";
|
||||||
|
import { signIn, signOut, useSession } from "next-auth/react";
|
||||||
|
|
||||||
/** TODO: Fix these nav links */
|
/** TODO: Fix these nav links */
|
||||||
export const Nav = () => {
|
export const Nav = () => {
|
||||||
|
const { data: session } = useSession();
|
||||||
return (
|
return (
|
||||||
<div className="boxed-content">
|
<div className="boxed-content">
|
||||||
<div className="top-banner">
|
<div className="top-banner">
|
||||||
<a href="/">
|
<NextLink href="/">
|
||||||
|
<a>
|
||||||
{/* {% if colors == 'dark */}
|
{/* {% if colors == 'dark */}
|
||||||
<NextImage
|
<NextImage
|
||||||
width={700}
|
width={700}
|
||||||
@ -22,12 +26,15 @@ export const Nav = () => {
|
|||||||
{/* <img src="/img/banner-tube-archivist-light.png" alt="tube-archivist-banner"> */}
|
{/* <img src="/img/banner-tube-archivist-light.png" alt="tube-archivist-banner"> */}
|
||||||
{/* {% endif %} */}
|
{/* {% endif %} */}
|
||||||
</a>
|
</a>
|
||||||
|
</NextLink>
|
||||||
</div>
|
</div>
|
||||||
<div className="top-nav">
|
<div className="top-nav">
|
||||||
<div className="nav-items">
|
<div className="nav-items">
|
||||||
<a href="/">
|
<NextLink href="/">
|
||||||
|
<a>
|
||||||
<div className="nav-item">home</div>
|
<div className="nav-item">home</div>
|
||||||
</a>
|
</a>
|
||||||
|
</NextLink>
|
||||||
<a href="/channel">
|
<a href="/channel">
|
||||||
<div className="nav-item">channels</div>
|
<div className="nav-item">channels</div>
|
||||||
</a>
|
</a>
|
||||||
@ -57,7 +64,10 @@ export const Nav = () => {
|
|||||||
title="Settings"
|
title="Settings"
|
||||||
/>
|
/>
|
||||||
</a>
|
</a>
|
||||||
<a href="/logout">
|
<a
|
||||||
|
style={{ cursor: "pointer" }}
|
||||||
|
onClick={!!session?.user ? () => signOut() : () => signIn()}
|
||||||
|
>
|
||||||
<NextImage
|
<NextImage
|
||||||
width={40}
|
width={40}
|
||||||
height={40}
|
height={40}
|
||||||
|
Loading…
Reference in New Issue
Block a user