Feat: Add button on admin page to return to main page
This commit is contained in:
parent
a2a3beb868
commit
0c0d8cfdb3
1 changed files with 11 additions and 0 deletions
|
|
@ -27,6 +27,17 @@ export default function Header(): JSX.Element {
|
||||||
<Link to="/">
|
<Link to="/">
|
||||||
<span className="ml-4 text-2xl">⛓️</span>
|
<span className="ml-4 text-2xl">⛓️</span>
|
||||||
</Link>
|
</Link>
|
||||||
|
{location.pathname === "/admin" && (
|
||||||
|
<Button
|
||||||
|
onClick={() => {
|
||||||
|
navigate("/");
|
||||||
|
}}
|
||||||
|
variant="outline"
|
||||||
|
className=""
|
||||||
|
>
|
||||||
|
Main page
|
||||||
|
</Button>
|
||||||
|
)}
|
||||||
{autoLogin === false && (
|
{autoLogin === false && (
|
||||||
<Button
|
<Button
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue