diff options
author | Stas Vilchik <vilchiks@gmail.com> | 2014-07-21 17:11:38 +0200 |
---|---|---|
committer | Stas Vilchik <vilchiks@gmail.com> | 2014-07-21 17:11:47 +0200 |
commit | 123c84f35b97f4c362f382fc2299696620300eef (patch) | |
tree | a6713616241d9115189606c214fdb74e25bfe3f1 | |
parent | 409f06d2f2178256ce913c5a16881cf29fec7e4e (diff) | |
download | sonarqube-123c84f35b97f4c362f382fc2299696620300eef.tar.gz sonarqube-123c84f35b97f4c362f382fc2299696620300eef.zip |
Fix the sqale rating display around the application
4 files changed, 8 insertions, 6 deletions
diff --git a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/debt_overview.erb b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/debt_overview.erb index d17b3d12519..a945f084724 100644 --- a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/debt_overview.erb +++ b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/debt_overview.erb @@ -10,9 +10,7 @@ <div class="widget-measure widget-measure-main"> <span class="widget-label"><%= message('metric.sqale_rating.name') -%></span> <span class="nowrap"> - <a href="<%= url_for_drilldown('sqale_rating') -%>" class="widget-link"> - <span class="rating rating-<%= sqale_rating.text_value -%>"><%= sqale_rating.text_value -%></span> - </a> + <%= format_measure(sqale_rating, :url => url_for_drilldown(sqale_rating)) %> <% unless dashboard_configuration.selected_period? %> <%= trend_icon(sqale_rating) -%> <% end %> diff --git a/server/sonar-web/src/main/less/component-viewer.less b/server/sonar-web/src/main/less/component-viewer.less index 67e73a6c603..8dfd5113cf3 100644 --- a/server/sonar-web/src/main/less/component-viewer.less +++ b/server/sonar-web/src/main/less/component-viewer.less @@ -429,7 +429,6 @@ .rating { font-size: 18px; - font-weight: 300; } } diff --git a/server/sonar-web/src/main/less/ui.less b/server/sonar-web/src/main/less/ui.less index eeb002fdde4..571f245e061 100644 --- a/server/sonar-web/src/main/less/ui.less +++ b/server/sonar-web/src/main/less/ui.less @@ -319,8 +319,12 @@ input[type=button] { */ .rating { - padding: 2px 5px; + display: inline-block; + .size(1em, 1.3em); + line-height: 1.3; color: #fff; + font-weight: 300; + text-align: center; } .rating-A { @@ -333,6 +337,7 @@ input[type=button] { .rating-C { background-color: #FFEE00; + color: @baseFontColor; } .rating-D { diff --git a/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb b/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb index c9ccaf7012e..9a58a14981d 100644 --- a/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb +++ b/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb @@ -271,7 +271,7 @@ module ApplicationHelper alert_class="class='alert_#{m.alert_status}'" unless m.metric.val_type==Metric::VALUE_TYPE_LEVEL link_rel=h(m.alert_text) elsif m.metric.val_type==Metric::VALUE_TYPE_RATING && m.color - style = "style='background-color: #{m.color.html};padding: 2px 5px'" + alert_class="class='rating rating-" + m.formatted_value + "'" end span_id='' |