diff --git a/package.json b/package.json index 0b67282..5eac2ff 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,7 @@ }, "dependencies": { "@reach/router": "^1.3.4", - "tc-auth-lib": "topcoder-platform/tc-auth-lib#1.0.1", + "tc-auth-lib": "topcoder-platform/tc-auth-lib#1.0.3", "browser-cookies": "^1.2.0", "classnames": "^2.2.6", "config": "^3.3.2", diff --git a/src/components/NavLink/index.jsx b/src/components/NavLink/index.jsx index 7d06c07..023f1f8 100644 --- a/src/components/NavLink/index.jsx +++ b/src/components/NavLink/index.jsx @@ -7,14 +7,16 @@ import React from "react"; import { Link } from "@reach/router"; import cn from "classnames"; -const NavLink = ({ to, className, activeClassName, children }) => ( +const NavLink = ({ to, className, activeClassName, children, exact }) => ( { + getProps={({ isCurrent, isPartiallyCurrent }) => { // the object returned here is passed to the // anchor element's props return { - className: cn(className, { [activeClassName]: isCurrent }), + className: cn(className, { + [activeClassName]: exact ? isCurrent : isPartiallyCurrent, + }), }; }} > diff --git a/src/constants/apps.js b/src/constants/apps.js index ddcb8bd..df83e0f 100644 --- a/src/constants/apps.js +++ b/src/constants/apps.js @@ -57,7 +57,7 @@ export const APP_CATEGORIES = [ { title: "TaaS", icon: appTaasIcon, - path: "/taas", + path: "/taas/myteams", menu: [ { title: "My Teams", @@ -65,24 +65,6 @@ export const APP_CATEGORIES = [ icon: myteamsIcon, activeIcon: myteamsGreenIcon, }, - { - title: "Feedback", - path: "/taas/feedback", - icon: discussionsIcon, - activeIcon: discussionsGreenIcon, - }, - { - title: "Invoices", - path: "/taas/invoices", - icon: apisIcon, - activeIcon: apisGreenIcon, - }, - { - title: "Reports", - path: "/taas/reports", - icon: reportsIcon, - activeIcon: reportsGreenIcon, - }, ], }, {