diff options
author | Jenkins CI <ci@sonarsource.com> | 2016-03-02 08:01:26 +0100 |
---|---|---|
committer | Jenkins CI <ci@sonarsource.com> | 2016-03-02 08:01:26 +0100 |
commit | c503b4775824ee2b2d82bdd71f1aed134cf4bdbe (patch) | |
tree | 0d690e6dc9f6aaeff5129d7fb0b27ab16bfb4089 /server | |
parent | cabf4e94cb5974788fda7a6881ec5876d777a84b (diff) | |
parent | 8de7cbc9b0565e43a17bdbf2b0fc886a3c248c4f (diff) | |
download | sonarqube-c503b4775824ee2b2d82bdd71f1aed134cf4bdbe.tar.gz sonarqube-c503b4775824ee2b2d82bdd71f1aed134cf4bdbe.zip |
Automatic merge from branch-5.4
* origin/branch-5.4:
fix widgets resizing on the overview page
[maven-release-plugin] prepare for next development iteration
[maven-release-plugin] prepare release 5.4-RC3
Diffstat (limited to 'server')
-rw-r--r-- | server/sonar-web/src/main/js/apps/overview/components/domain-treemap.js | 5 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/apps/overview/components/ncloc-distribution.js | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/server/sonar-web/src/main/js/apps/overview/components/domain-treemap.js b/server/sonar-web/src/main/js/apps/overview/components/domain-treemap.js index 635c0cb41e6..3addeefc02b 100644 --- a/server/sonar-web/src/main/js/apps/overview/components/domain-treemap.js +++ b/server/sonar-web/src/main/js/apps/overview/components/domain-treemap.js @@ -133,10 +133,13 @@ export class DomainTreemap extends React.Component { const canBeClicked = node => node.qualifier !== 'FIL' && node.qualifier !== 'UTS'; + // FIXME remove this magic number + const height = HEIGHT - 35; + return <Treemap items={items} breadcrumbs={this.state.breadcrumbs} - height={HEIGHT} + height={height} canBeClicked={canBeClicked} onRectangleClick={this.handleRectangleClick.bind(this)} onReset={this.handleReset.bind(this)}/>; diff --git a/server/sonar-web/src/main/js/apps/overview/components/ncloc-distribution.js b/server/sonar-web/src/main/js/apps/overview/components/ncloc-distribution.js index 4c904d72a3f..eb1a6f38be2 100644 --- a/server/sonar-web/src/main/js/apps/overview/components/ncloc-distribution.js +++ b/server/sonar-web/src/main/js/apps/overview/components/ncloc-distribution.js @@ -104,6 +104,9 @@ export const NclocDistribution = React.createClass({ }, render () { + const componentsCount = this.state.components ? this.state.components.length : 1; + const height = componentsCount * 25; + return <div className="overview-domain-chart"> <div className="overview-card-header"> <h2 className="overview-title">{translate('overview.chart.components')}</h2> @@ -111,7 +114,7 @@ export const NclocDistribution = React.createClass({ {translateWithParameters('overview.chart.legend.size_x', translate('metric.ncloc.name'))} </span> </div> - <div className="overview-bar-chart" style={{ height: HEIGHT }}> + <div className="overview-bar-chart" style={{ height }}> {this.renderBarChart()} </div> </div>; |