From 51dda971500686f11b901c82da7a0b133d4034a3 Mon Sep 17 00:00:00 2001 From: simonbrandhof Date: Mon, 28 Mar 2011 15:43:54 +0200 Subject: [PATCH] Improve rendering of violations --- .../webapp/WEB-INF/app/views/resource/index.html.erb | 4 ++-- sonar-server/src/main/webapp/stylesheets/style.css | 10 ++-------- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/resource/index.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/resource/index.html.erb index e4f575a928d..71d1e4634a3 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/resource/index.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/resource/index.html.erb @@ -59,8 +59,8 @@ elsif line.hits status=(line.hits>0 ? '' : 'ko') end - elsif @display_violations - status="sev#{line.violation_severity}" + elsif @display_violations && line.violations? + status="ko" end end %> diff --git a/sonar-server/src/main/webapp/stylesheets/style.css b/sonar-server/src/main/webapp/stylesheets/style.css index 9698968edec..e4e37fd9e39 100644 --- a/sonar-server/src/main/webapp/stylesheets/style.css +++ b/sonar-server/src/main/webapp/stylesheets/style.css @@ -699,17 +699,11 @@ span.rulename a:hover { border-top: 1px solid #6EC563; border-bottom: 1px solid #6EC563; } -.sources2 td.sev0, .sources2 td.sev1, .sources2 td.warn { - /* info, minor */ +.sources2 td.warn { background-color: #FFF6BF; - border-top: 1px solid #FFD324; - border-bottom: 1px solid #FFD324; } -.sources2 td.sev2, .sources2 td.sev3, .sources2 td.sev4, .sources2 td.ko { - /* major, critical, blocker */ +.sources2 td.ko { background-color: #FF9090; - border-top: 1px solid #FF5252; - border-bottom: 1px solid #FF5252; } .sources2 td.new_section { border-top: 1px solid #DDD; -- 2.39.5