From: Jeremy Davis Date: Thu, 28 Jul 2022 09:55:56 +0000 (+0200) Subject: SONAR-16683 [891475] global menu aria-current X-Git-Tag: 9.6.0.59041~129 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=8ba422425e92fb3a2d4dc0ff3de0d8c07a705a0f;p=sonarqube.git SONAR-16683 [891475] global menu aria-current --- diff --git a/server/sonar-web/src/main/js/app/components/nav/global/GlobalNavMenu.tsx b/server/sonar-web/src/main/js/app/components/nav/global/GlobalNavMenu.tsx index 866004c5051..ae72bfedf00 100644 --- a/server/sonar-web/src/main/js/app/components/nav/global/GlobalNavMenu.tsx +++ b/server/sonar-web/src/main/js/app/components/nav/global/GlobalNavMenu.tsx @@ -46,7 +46,10 @@ export class GlobalNavMenu extends React.PureComponent { return (
  • - + {translate('projects.page')}
  • @@ -64,17 +67,18 @@ export class GlobalNavMenu extends React.PureComponent { } renderIssuesLink() { - const active = this.props.location.pathname.startsWith('/issues'); - const search = (this.props.currentUser.isLoggedIn && isMySet() ? new URLSearchParams({ resolved: 'false', myIssues: 'true' }) : new URLSearchParams({ resolved: 'false' }) ).toString(); + return (
  • - + (isActive ? ACTIVE_CLASS_NAME : '')} + to={{ pathname: '/issues', search }}> {translate('issues.page')} - +
  • ); }