Refresh invite operations workspace
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
'use client'
|
||||
|
||||
import { useEffect, useState } from 'react'
|
||||
import { usePathname } from 'next/navigation'
|
||||
import { useEffect, useState } from 'react'
|
||||
import { authFetch, clearToken, getApiBase, getToken } from '../lib/auth'
|
||||
|
||||
export default function HeaderActions() {
|
||||
@@ -55,10 +55,18 @@ export default function HeaderActions() {
|
||||
? []
|
||||
: role === 'admin'
|
||||
? [
|
||||
{
|
||||
href: '/admin/invites',
|
||||
label: 'Invites',
|
||||
match: (path: string) => path.startsWith('/admin/invites') || path.startsWith('/admin/profiles'),
|
||||
},
|
||||
{
|
||||
href: '/admin',
|
||||
label: 'Config',
|
||||
match: (path: string) => path.startsWith('/admin'),
|
||||
match: (path: string) =>
|
||||
path.startsWith('/admin') &&
|
||||
!path.startsWith('/admin/invites') &&
|
||||
!path.startsWith('/admin/profiles'),
|
||||
},
|
||||
]
|
||||
: [
|
||||
|
||||
Reference in New Issue
Block a user