From: Stas Vilchik Date: Thu, 14 Sep 2017 16:23:29 +0000 (+0200) Subject: SONAR-9813 display "Private" badge tooltip based on qualifier X-Git-Tag: 6.6-RC1~275 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=c47f23a368580c818c3a7a7db425078f4eb3554c;p=sonarqube.git SONAR-9813 display "Private" badge tooltip based on qualifier --- diff --git a/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBreadcrumbs.js b/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBreadcrumbs.js index 27637b0f3ed..8bbd0a0c5ce 100644 --- a/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBreadcrumbs.js +++ b/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBreadcrumbs.js @@ -93,7 +93,9 @@ class ComponentNavBreadcrumbs extends React.PureComponent { )} {items} - {component.visibility === 'private' && } + {component.visibility === 'private' && ( + + )} ); } diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.tsx b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.tsx index 89e6dd61c78..1505bef784b 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.tsx +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.tsx @@ -57,7 +57,9 @@ export default function ProjectCardLeak({ organization, project }: Props) { {project.analysisDate && }
- {isPrivate && } + {isPrivate && ( + + )} {hasTags && }
{project.analysisDate && diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.tsx b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.tsx index 135f71c3e35..80ce9ceadb0 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.tsx +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.tsx @@ -56,7 +56,9 @@ export default function ProjectCardOverall({ organization, project }: Props) { {project.analysisDate && }
- {isPrivate && } + {isPrivate && ( + + )} {hasTags && }
{project.analysisDate && ( diff --git a/server/sonar-web/src/main/js/apps/projectsManagement/ProjectRow.tsx b/server/sonar-web/src/main/js/apps/projectsManagement/ProjectRow.tsx index c87abea71e4..ce7df2a1c43 100644 --- a/server/sonar-web/src/main/js/apps/projectsManagement/ProjectRow.tsx +++ b/server/sonar-web/src/main/js/apps/projectsManagement/ProjectRow.tsx @@ -64,7 +64,9 @@ export default class ProjectRow extends React.PureComponent { - {project.visibility === Visibility.Private && } + {project.visibility === Visibility.Private && ( + + )} diff --git a/server/sonar-web/src/main/js/apps/projectsManagement/__tests__/__snapshots__/ProjectRow-test.tsx.snap b/server/sonar-web/src/main/js/apps/projectsManagement/__tests__/__snapshots__/ProjectRow-test.tsx.snap index d0e3ac5b4f8..87d61db023e 100644 --- a/server/sonar-web/src/main/js/apps/projectsManagement/__tests__/__snapshots__/ProjectRow-test.tsx.snap +++ b/server/sonar-web/src/main/js/apps/projectsManagement/__tests__/__snapshots__/ProjectRow-test.tsx.snap @@ -39,7 +39,9 @@ exports[`renders 1`] = ` - + - + +
{translate('visibility.private')}
diff --git a/server/sonar-web/src/main/js/components/common/__tests__/PrivateBadge-test.tsx b/server/sonar-web/src/main/js/components/common/__tests__/PrivateBadge-test.tsx index 02bdfcab213..93c199d8e25 100644 --- a/server/sonar-web/src/main/js/components/common/__tests__/PrivateBadge-test.tsx +++ b/server/sonar-web/src/main/js/components/common/__tests__/PrivateBadge-test.tsx @@ -22,5 +22,5 @@ import { shallow } from 'enzyme'; import PrivateBadge from '../PrivateBadge'; it('renders', () => { - expect(shallow()).toMatchSnapshot(); + expect(shallow()).toMatchSnapshot(); }); diff --git a/server/sonar-web/src/main/js/components/common/__tests__/__snapshots__/PrivateBadge-test.tsx.snap b/server/sonar-web/src/main/js/components/common/__tests__/__snapshots__/PrivateBadge-test.tsx.snap index d8f24f25b26..2ec0bd7a891 100644 --- a/server/sonar-web/src/main/js/components/common/__tests__/__snapshots__/PrivateBadge-test.tsx.snap +++ b/server/sonar-web/src/main/js/components/common/__tests__/__snapshots__/PrivateBadge-test.tsx.snap @@ -2,7 +2,7 @@ exports[`renders 1`] = `