From 3ffdbd9e347ffc498f0559d0b1cf39b5c6bbac23 Mon Sep 17 00:00:00 2001 From: Simon Brandhof Date: Fri, 21 Sep 2012 21:13:50 +0200 Subject: [PATCH] Improve CSS --- .../dashboards/_available_dashboards.html.erb | 2 +- .../views/dashboards/_my_dashboards.html.erb | 2 +- .../WEB-INF/app/views/layouts/_head.html.erb | 107 ++++++++++-------- .../app/views/profiles/_rename_form.html.erb | 6 +- .../WEB-INF/app/views/profiles/index.html.erb | 4 +- .../src/main/webapp/stylesheets/style.css | 6 +- 6 files changed, 68 insertions(+), 59 deletions(-) diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_available_dashboards.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_available_dashboards.html.erb index ca88843c2cd..1146206e2fd 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_available_dashboards.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_available_dashboards.html.erb @@ -19,7 +19,7 @@ <%= link_to h(dashboard.name(true)), {:controller => :dashboard, :action => :index, :did => dashboard.id, :id => (params[:resource] unless dashboard.global?)}, - :id => "view-#{u dashboard.name}", :class => 'link-action' %> + :id => "view-#{u dashboard.name}" %>
<%= h dashboard.description -%>
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_my_dashboards.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_my_dashboards.html.erb index f6cd8d762a1..193af39786f 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_my_dashboards.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboards/_my_dashboards.html.erb @@ -18,7 +18,7 @@ <%= link_to h(dashboard.name(true)), {:controller => :dashboard, :action => :index, :did => dashboard.id, :id => (params[:resource] unless dashboard.global?)}, - :id => "view-#{u dashboard.name}", :class => 'link-action' %> + :id => "view-#{u dashboard.name}" %>
<%= h dashboard.description -%>
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_head.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_head.html.erb index c2f6ada98e3..8ef39b808f0 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_head.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_head.html.erb @@ -1,50 +1,61 @@ - - - - -<% - if @project -%> -<% - else -%><% - end + + + + + + + <% + if @project + %> + + <% + else + %> + + <% + end - if @page_title - title="Sonar - #{h(@page_title)}" - elsif @project - title="Sonar - #{h(@project.name)}" - elsif @resource - title="#{h(@resource.long_name)}" - else - title='Sonar' - end -%> -<%= title -%> -<% if ENV['RAILS_ENV'] == 'production' -%><%= stylesheet_link_tag 'sonar', :media => 'all' -%><%= javascript_include_tag 'sonar' --%><% else %> -<%= stylesheet_link_tag 'yui-reset-font', :media => 'all' %> -<%= stylesheet_link_tag 'select2', :media => 'all' %> -<%= stylesheet_link_tag 'layout', :media => 'all' %> -<%= stylesheet_link_tag 'jquery-ui', :media => 'all' %> -<%= stylesheet_link_tag 'style', :media => 'all' %> -<%= stylesheet_link_tag 'sonar-colorizer', :media => 'all' %> -<%= stylesheet_link_tag 'dashboard', :media => 'all' %> -<%= javascript_include_tag 'prototype' %> -<%= javascript_include_tag 'scriptaculous' %> -<%= javascript_include_tag 'tablekit' %> -<%= javascript_include_tag 'jquery.min' %> -<%= javascript_include_tag 'jquery-ui.min' %> -<%= javascript_include_tag 'select2.min' %> -<%= javascript_include_tag 'protovis' %> -<%= javascript_include_tag 'protovis-sonar' %> -<%= javascript_include_tag 'application' %> -<%= javascript_include_tag 'dashboard' %> -<%= javascript_include_tag 'duplication' %> -<%= javascript_include_tag 'resource' %> -<% end %> - - - \ No newline at end of file + if @page_title + title="Sonar - #{h(@page_title)}" + elsif @project + title="Sonar - #{h(@project.name)}" + elsif @resource + title="#{h(@resource.long_name)}" + else + title='Sonar' + end + %> + <%= title -%> + <% if ENV['RAILS_ENV'] == 'production' + %> + <%= stylesheet_link_tag 'sonar', :media => 'all' -%> + <%= yield :css -%> + <%= javascript_include_tag 'sonar' -%> + <% else %> + <%= stylesheet_link_tag 'yui-reset-font', :media => 'all' %> + <%= stylesheet_link_tag 'select2', :media => 'all' %> + <%= stylesheet_link_tag 'layout', :media => 'all' %> + <%= stylesheet_link_tag 'jquery-ui', :media => 'all' %> + <%= stylesheet_link_tag 'style', :media => 'all' %> + <%= stylesheet_link_tag 'sonar-colorizer', :media => 'all' %> + <%= stylesheet_link_tag 'dashboard', :media => 'all' %> + <%= javascript_include_tag 'prototype' %> + <%= javascript_include_tag 'scriptaculous' %> + <%= javascript_include_tag 'tablekit' %> + <%= javascript_include_tag 'jquery.min' %> + <%= javascript_include_tag 'jquery-ui.min' %> + <%= javascript_include_tag 'select2.min' %> + <%= javascript_include_tag 'protovis' %> + <%= javascript_include_tag 'protovis-sonar' %> + <%= javascript_include_tag 'application' %> + <%= javascript_include_tag 'dashboard' %> + <%= javascript_include_tag 'duplication' %> + <%= javascript_include_tag 'resource' %> + <% end %> + + + <%= yield :script -%> + + \ No newline at end of file diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_rename_form.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_rename_form.html.erb index f64315285e5..d024b747940 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_rename_form.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_rename_form.html.erb @@ -1,4 +1,4 @@ - +
@@ -7,10 +7,6 @@ <% end %>
-
- - -
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/index.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/index.html.erb index e1e8e3bd93e..b69715c0791 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/index.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/index.html.erb @@ -158,8 +158,10 @@

<% end %> -<% content_for :javascript_header do %> +<% content_for :script do %> + <% end %> diff --git a/sonar-server/src/main/webapp/stylesheets/style.css b/sonar-server/src/main/webapp/stylesheets/style.css index b628cbeffd2..565a81f3bfb 100644 --- a/sonar-server/src/main/webapp/stylesheets/style.css +++ b/sonar-server/src/main/webapp/stylesheets/style.css @@ -2368,13 +2368,13 @@ select.medium-width { } .form-footer { text-align: right; - padding: 0.5em; + padding: 4px 10px; border-top: 1px solid #CCC; } .form-footer input { margin-right: 10px; } input[type=text],input[type=password] { - height: 20px; - padding: 0 5px; + height: 18px; + padding: 0 3px; } -- 2.39.5