Skip to content

Commit

Permalink
remove projects tab outside of GG rounds
Browse files Browse the repository at this point in the history
  • Loading branch information
codenamejason committed May 8, 2024
1 parent 13813a9 commit 3aec201
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions packages/grant-explorer/src/features/discovery/LandingTabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@ import { Tab, Tabs } from "../common/styles";
import { toQueryString } from "./RoundsFilter";
import { RoundStatus } from "./hooks/useFilterRounds";
import { useMediaQuery } from "@chakra-ui/react";
import {
useAlloVersion,
} from "common/src/components/AlloVersionSwitcher";
import { useAlloVersion } from "common/src/components/AlloVersionSwitcher";

type TabType = {
to: string;
Expand Down Expand Up @@ -40,19 +38,21 @@ export default function LandingTabs() {
children: isDesktop ? "Explore rounds" : "Rounds",
tabName: "home-rounds-tab",
},
{
to: "/projects",
activeRegExp: /^\/projects/,
children: isDesktop ? "Explore projects" : "Projects",
tabName: "home-projects-tab",
},
// Note: removing when a GG round is not running.
// {
// to: "/projects",
// activeRegExp: /^\/projects/,
// children: isDesktop ? "Explore projects" : "Projects",
// tabName: "home-projects-tab",
// },
];

const { version: currentVersion } = useAlloVersion();
if (currentVersion === "allo-v1") {
// Remove the projects tab if the current version is allo-v1
tabs.pop();
}
// Note: removing when a GG round is not running.
// const { version: currentVersion } = useAlloVersion();
// if (currentVersion === "allo-v1") {
// // Remove the projects tab if the current version is allo-v1
// tabs.pop();
// }

return (
<Tabs className="font-mono">
Expand Down

0 comments on commit 3aec201

Please sign in to comment.