From: Grégoire Aubert Date: Tue, 6 Jun 2017 15:24:20 +0000 (+0200) Subject: SONAR-9245 Update leak project cards style on projects page X-Git-Tag: 6.5-M1~72 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=db6fc1233cfe6d281c1bbee419d4cfdff6b02561;p=sonarqube.git SONAR-9245 Update leak project cards style on projects page --- diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.js b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.js index 9e38e2bcb2d..ac47c003b7a 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.js +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeak.js @@ -86,14 +86,14 @@ export default function ProjectCardLeak({ measures, organization, project }: Pro hasLeakPeriodStart &&
{hasLeakPeriodStart && - + {translateWithParameters( 'projects.leak_period_x', moment(project.leakPeriodDate).fromNow() )} } {isProjectAnalyzed && - + {translateWithParameters( 'projects.last_analysis_on_x', moment(project.analysisDate).format('LLL') diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js index 2b9698e7c19..db61abdf13a 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js @@ -49,7 +49,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) {
- {translate('metric.new_bugs.name')} + {translate('metric.bugs.name')}
@@ -66,7 +66,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) {
- {translate('metric.new_vulnerabilities.name')} + {translate('metric.vulnerabilities.name')}
@@ -83,7 +83,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) {
- {translate('metric.new_code_smells.name')} + {translate('metric.code_smells.name')}
@@ -97,7 +97,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) { />
- {translate('metric.new_coverage.name')} + {translate('metric.coverage.name')}
@@ -111,7 +111,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) { />
- {translate('metric.new_duplicated_lines_density.short_name')} + {translate('metric.duplicated_lines_density.short_name')}
@@ -126,7 +126,7 @@ export default function ProjectCardLeakMeasures({ measures }: Props) { />
- {translate('metric.new_lines.short_name')} + {translate('metric.lines.name')}
} diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.js b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.js index 8ef49b49179..72bbccbd7ae 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.js +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardOverall.js @@ -82,7 +82,7 @@ export default function ProjectCardOverall({ measures, organization, project }: {hasTags && } {isProjectAnalyzed && -
+
{translateWithParameters( 'projects.last_analysis_on_x', diff --git a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeak-test.js.snap b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeak-test.js.snap index 101ba723485..cb539fbafe6 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeak-test.js.snap +++ b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeak-test.js.snap @@ -35,12 +35,12 @@ exports[`should display the leak measures and quality gate 1`] = `
- - projects.leak_period_x.a month ago - + projects.leak_period_x.a month ago + + projects.last_analysis_on_x.March 1, 2017 9:36 AM
diff --git a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeakMeasures-test.js.snap b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeakMeasures-test.js.snap index 964ff49ff68..fa740a935fe 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeakMeasures-test.js.snap +++ b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardLeakMeasures-test.js.snap @@ -28,7 +28,7 @@ exports[`should not render new coverage 1`] = `
- metric.new_coverage.name + metric.coverage.name
@@ -62,7 +62,7 @@ exports[`should not render new duplications 1`] = `
- metric.new_duplicated_lines_density.short_name + metric.duplicated_lines_density.short_name
@@ -110,7 +110,7 @@ exports[`should render correctly with all data 1`] = ` - metric.new_bugs.name + metric.bugs.name @@ -150,7 +150,7 @@ exports[`should render correctly with all data 1`] = ` - metric.new_vulnerabilities.name + metric.vulnerabilities.name @@ -190,7 +190,7 @@ exports[`should render correctly with all data 1`] = ` - metric.new_code_smells.name + metric.code_smells.name @@ -221,7 +221,7 @@ exports[`should render correctly with all data 1`] = `
- metric.new_coverage.name + metric.coverage.name
@@ -252,7 +252,7 @@ exports[`should render correctly with all data 1`] = `
- metric.new_duplicated_lines_density.short_name + metric.duplicated_lines_density.short_name
@@ -283,7 +283,7 @@ exports[`should render correctly with all data 1`] = `
- metric.new_lines.short_name + metric.lines.name
diff --git a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardOverall-test.js.snap b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardOverall-test.js.snap index 1e666cc1854..b93bf252c31 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardOverall-test.js.snap +++ b/server/sonar-web/src/main/js/apps/projects/components/__tests__/__snapshots__/ProjectCardOverall-test.js.snap @@ -33,7 +33,7 @@ exports[`should display the overall measures and quality gate 1`] = ` className="pull-right text-right" />