aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/sonar-core-plugin
diff options
context:
space:
mode:
authorStas Vilchik <vilchiks@gmail.com>2014-11-21 14:48:40 +0100
committerStas Vilchik <vilchiks@gmail.com>2014-11-21 15:15:52 +0100
commitc36f2e731414c844661c7d39d4958f05e4b1d1c0 (patch)
treed786eb64e9e0096c84c00854b492f1db03dc0bfd /plugins/sonar-core-plugin
parent8fbb72e42255f1f2232d7c44b6c364dce7dce400 (diff)
downloadsonarqube-c36f2e731414c844661c7d39d4958f05e4b1d1c0.tar.gz
sonarqube-c36f2e731414c844661c7d39d4958f05e4b1d1c0.zip
SONAR-5544 Make the Complexity widget comply with the new SonarQube widget Look and Feel
Diffstat (limited to 'plugins/sonar-core-plugin')
-rw-r--r--plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/complexity.html.erb50
1 files changed, 26 insertions, 24 deletions
diff --git a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/complexity.html.erb b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/complexity.html.erb
index b37a7ce3821..6a24a955965 100644
--- a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/complexity.html.erb
+++ b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/complexity.html.erb
@@ -10,40 +10,42 @@
<div class="widget-row">
<div class="widget-span widget-span-5">
<div class="widget-measure-container">
- <div class="widget-measure widget-measure-main">
- <span class="widget-label"><%= message('widget.complexity.name') -%></span>
- <% if function_complexity %>
+ <% if complexity %>
+ <p class="widget-measure widget-measure-main">
+ <span class="widget-label"><%= message('metric.complexity.name') %></span>
+ <span class="nowrap">
+ <%= format_measure(complexity, :url => url_for_drilldown(complexity)) %>
+ <%= dashboard_configuration.selected_period? ? format_variation(complexity) : trend_icon(complexity) -%>
+ </span>
+ </p>
+ <% end %>
+ <% if function_complexity %>
+ <p class="widget-measure">
+ <span class="widget-label"><%= message('widget.complexity.per_method.suffix') %></span>
<span class="nowrap">
<%= format_measure(function_complexity, :url => url_for_drilldown(function_complexity)) %>
<%= dashboard_configuration.selected_period? ? format_variation(function_complexity) : trend_icon(function_complexity) -%>
- <span class="small"><%= message('widget.complexity.per_method.suffix') %></span>
</span>
- <% end %>
- <% if class_complexity %>
- <br>
+ </p>
+ <% end %>
+ <% if class_complexity %>
+ <p class="widget-measure">
+ <span class="widget-label"><%= message('widget.complexity.per_class.suffix') %></span>
<span class="nowrap">
<%= format_measure(class_complexity, :url => url_for_drilldown(class_complexity)) %>
- <%= dashboard_configuration.selected_period? ? format_variation(class_complexity) : trend_icon(class_complexity) -%>
- <span class="small"><%= message('widget.complexity.per_class.suffix') %></span>
+ <%= dashboard_configuration.selected_period? ? format_variation(class_complexity) : trend_icon(class_complexity) -%>
</span>
- <% end %>
- <% if file_complexity %>
- <br>
+ </p>
+ <% end %>
+ <% if file_complexity %>
+ <p class="widget-measure">
+ <span class="widget-label"><%= message('widget.complexity.per_file.suffix') %></span>
<span class="nowrap">
<%= format_measure(file_complexity, :url => url_for_drilldown(file_complexity)) %>
- <%= dashboard_configuration.selected_period? ? format_variation(file_complexity) : trend_icon(file_complexity) -%>
- <span class="small"><%= message('widget.complexity.per_file.suffix') %></span>
+ <%= dashboard_configuration.selected_period? ? format_variation(file_complexity) : trend_icon(file_complexity) -%>
</span>
- <% end %>
- <% if complexity %>
- <br>
- <span class="nowrap">
- <%= message('widget.complexity.total') -%>
- : <%= format_measure(complexity, :url => url_for_drilldown(complexity)) %>
- <%= dashboard_configuration.selected_period? ? format_variation(complexity) : trend_icon(complexity) -%>
- </span>
- <% end %>
- </div>
+ </p>
+ <% end %>
</div>
</div>