use zustand
This commit is contained in:
parent
d2d358bff2
commit
5f29bc436c
15 changed files with 74 additions and 83 deletions
|
@ -1,11 +1,11 @@
|
|||
import { PropsWithChildren } from 'react'
|
||||
import { Role, useUser } from '../app/user/user.ts'
|
||||
import { Role, useUserStore } from '../app/user/user.ts'
|
||||
import NavButton from './buttons/NavButton.tsx'
|
||||
|
||||
type NavBarProps = unknown
|
||||
|
||||
export default function NavBar({ children }: PropsWithChildren<NavBarProps>) {
|
||||
const user = useUser()
|
||||
const user = useUserStore((state) => state.user)
|
||||
const isSuperUser = user?.roles.includes(Role.SuperUser)
|
||||
return (
|
||||
<nav className={`w-full flex flex-row justify-between px-4 md:px-8 py-3`}>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue