|
|
|
@ -9,11 +9,7 @@ const ROLE_LABEL: Record<UserRole, string> = {
|
|
|
|
|
['student']: 'Studente',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type Props = {
|
|
|
|
|
noLogin?: boolean
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export const Header = ({ noLogin }: Props) => {
|
|
|
|
|
export const Header = ({}) => {
|
|
|
|
|
const [user] = useCurrentUser()
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
@ -44,11 +40,11 @@ export const Header = ({ noLogin }: Props) => {
|
|
|
|
|
</div>
|
|
|
|
|
</>
|
|
|
|
|
) : (
|
|
|
|
|
!noLogin && (
|
|
|
|
|
<div class="nav-item">
|
|
|
|
|
<Link href={prependBaseUrl('/login')}>Login</Link>
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
<div class="nav-item">
|
|
|
|
|
<Link activeClassName="active" href={prependBaseUrl('/login')}>
|
|
|
|
|
Login
|
|
|
|
|
</Link>
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
</nav>
|
|
|
|
|
</header>
|
|
|
|
|