Skip to content

Commit

Permalink
Fix project sidebar deps
Browse files Browse the repository at this point in the history
  • Loading branch information
vanpelt committed Dec 19, 2024
1 parent 680f4fc commit 1ea3f7d
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions weave-js/src/components/FancyPage/useProjectSidebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ export const useProjectSidebar = (
const isNoSidebarItems = !showModelsSidebarItems && !showWeaveSidebarItems;
const isBothSidebarItems = showModelsSidebarItems && showWeaveSidebarItems;
const isShowAll = isNoSidebarItems || isBothSidebarItems;
let weaveOnlyMenu = [
'weave/leaderboards',
'weave/operations',
'weave/objects',
];
if (isWandbAdmin) {
weaveOnlyMenu.push('weave/mods');
}

return useMemo(() => {
const weaveOnlyMenu = [
'weave/leaderboards',
'weave/operations',
'weave/objects',
];
if (isWandbAdmin) {
weaveOnlyMenu.push('weave/mods');
}
const allItems = isLoading
? []
: [
Expand Down Expand Up @@ -267,5 +267,6 @@ export const useProjectSidebar = (
isModelsOnly,
showWeaveSidebarItems,
isLaunchActive,
isWandbAdmin,
]);
};

0 comments on commit 1ea3f7d

Please sign in to comment.