feat: sync design of header with current web
This commit is contained in:
@@ -1,13 +1,18 @@
|
||||
import { auth } from "@/auth"
|
||||
|
||||
import styles from "./topMenu.module.css"
|
||||
|
||||
import type { TopMenuProps } from "@/types/components/current/header/topMenu"
|
||||
|
||||
export default function TopMenu({
|
||||
export default async function TopMenu({
|
||||
frontpageLinkText,
|
||||
homeHref,
|
||||
links,
|
||||
languageSwitcher,
|
||||
lang,
|
||||
}: TopMenuProps) {
|
||||
const session = await auth()
|
||||
|
||||
return (
|
||||
<div className={styles.topMenu}>
|
||||
<div className={styles.container}>
|
||||
@@ -25,6 +30,17 @@ export default function TopMenu({
|
||||
</a>
|
||||
</li>
|
||||
))}
|
||||
<li className={styles.loginContainer}>
|
||||
{session ? (
|
||||
<a href={`${lang}/logout`} className={styles.loginLink}>
|
||||
Log out
|
||||
</a>
|
||||
) : (
|
||||
<a href={`${lang}/login`} className={styles.loginLink}>
|
||||
Log in
|
||||
</a>
|
||||
)}
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -37,12 +37,15 @@
|
||||
Arial,
|
||||
sans-serif;
|
||||
font-size: 13px;
|
||||
font-weight: 400;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
text-rendering: optimizeLegibility;
|
||||
}
|
||||
.langSwitcher {
|
||||
text-align: center;
|
||||
position: relative;
|
||||
display: block;
|
||||
padding: 3px 15px;
|
||||
}
|
||||
|
||||
@media screen and (min-width: 768px) {
|
||||
@@ -63,6 +66,16 @@
|
||||
.link {
|
||||
padding-top: 4px;
|
||||
padding-bottom: 4px;
|
||||
font-weight: 300;
|
||||
}
|
||||
|
||||
.loginContainer {
|
||||
margin-left: 10px;
|
||||
background-color: #f3f2f1;
|
||||
}
|
||||
|
||||
.loginLink {
|
||||
padding-left: 30px;
|
||||
padding-right: 30px;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user