update filter
This commit is contained in:
@@ -147,6 +147,7 @@ export default function Component({
|
||||
</header>
|
||||
|
||||
<Outlet />
|
||||
|
||||
<Toaster
|
||||
position="top-center"
|
||||
richColors={true}
|
||||
|
||||
@@ -144,19 +144,14 @@ export function NavUser({
|
||||
|
||||
{apps
|
||||
.filter(({ appId }) => !excludeApps.includes(appId))
|
||||
.map(({ appId, title, url, scope = [], icon: Icon }) => {
|
||||
if (grantIfHas(scope, userScope)) {
|
||||
return (
|
||||
.filter(({ scope = [] }) => grantIfHas(scope, userScope))
|
||||
.map(({ appId, title, url, icon: Icon }) => (
|
||||
<DropdownMenuItem key={appId} asChild>
|
||||
<Link to={url} className="cursor-pointer">
|
||||
<Icon /> {title}
|
||||
</Link>
|
||||
</DropdownMenuItem>
|
||||
)
|
||||
}
|
||||
|
||||
return <></>
|
||||
})}
|
||||
))}
|
||||
</DropdownMenuGroup>
|
||||
|
||||
<DropdownMenuSeparator />
|
||||
|
||||
Reference in New Issue
Block a user