]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-3825 support pages without sidebar
authorSimon Brandhof <simon.brandhof@gmail.com>
Sun, 25 Nov 2012 21:29:02 +0000 (22:29 +0100)
committerSimon Brandhof <simon.brandhof@gmail.com>
Mon, 26 Nov 2012 12:57:41 +0000 (13:57 +0100)
sonar-server/src/main/webapp/WEB-INF/app/controllers/alerts_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/controllers/dependencies_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/controllers/measures_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/controllers/profiles_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/controllers/reviews_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb
sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_layout.html.erb
sonar-server/src/main/webapp/WEB-INF/app/views/measures/search.html.erb
sonar-server/src/main/webapp/stylesheets/layout.css

index f0d47d8e9df652d0869c3429a2c0a7f22bf705cd..c27ca5a90ebd862b2f273dbc8490553a4a9f74f3 100644 (file)
@@ -18,7 +18,6 @@
 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02
 #
 class AlertsController < ApplicationController
-  SECTION=Navigation::SECTION_CONFIGURATION
 
   verify :method => :post, :only => ['create', 'update', 'delete'], :redirect_to => { :action => 'index' }
   before_filter :admin_required, :except => [ 'index' ]
index a3c03b63086e7cc372a5b5c1cd54d8cb1a97607a..91c62d822f9f5ea77330b7a2fbfcda610f063122 100644 (file)
@@ -18,7 +18,6 @@
 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02
 #
 class DependenciesController < ApplicationController
-  SECTION = Navigation::SECTION_HOME
 
   SEARCH_MINIMUM_SIZE=3
   QUALIFIERS=['TRK', 'BRC', 'LIB']
index 40d74b6f14e079a038dfa476486de564be1315ad..e99fb71704a03c6adf4ec3e8c147c7edddc736bc 100644 (file)
@@ -19,8 +19,6 @@
 #
 class MeasuresController < ApplicationController
 
-  SECTION=Navigation::SECTION_HOME
-
   # GET /measures/index
   def index
     @filter = MeasureFilter.new
index 1dc5ab7d8a1bd6664528b561a906e6d5971b4d0e..821b6313b56a94330dee68348d87f9d0b738df51 100644 (file)
@@ -18,7 +18,6 @@
 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02
 #
 class ProfilesController < ApplicationController
-  SECTION=Navigation::SECTION_CONFIGURATION
 
   # the backup action is allow to non-admin users : see http://jira.codehaus.org/browse/SONAR-2039
   before_filter :admin_required, :only => ['create', 'delete', 'set_as_default', 'copy', 'restore', 'change_parent', 'set_projects', 'rename_form', 'rename']
index fb769042aea98d1986141f4362087e3f3ea12072..a4b1c4cabf1a12caa5945465a74be3f7707d76c1 100644 (file)
@@ -20,8 +20,6 @@
 
 class ReviewsController < ApplicationController
 
-  SECTION=Navigation::SECTION_HOME
-
   verify :method => :post,
          :only => [:violation_assign, :violation_flag_as_false_positive, :violation_change_severity,
                    :violation_save_comment, :violation_delete_comment, :violation_change_status,
index 0b6f838924c74f6f63d6df6b38ead26bc4789bef..5d0ad9c1b68fb26d271bc1763b8749bbcc9a6098 100644 (file)
@@ -21,8 +21,6 @@ require 'cgi'
 
 class RulesConfigurationController < ApplicationController
 
-  SECTION=Navigation::SECTION_CONFIGURATION
-
   STATUS_ACTIVE = "ACTIVE"
   STATUS_INACTIVE = "INACTIVE"
   ANY_SELECTION = [["Any", '']]
index 63c220d9ad5964e8d7e0e6f57f9a468cf424eb0f..f55bca5f408ba9080de523e68c37a6145ae2f058 100644 (file)
@@ -1,5 +1,6 @@
 <%
-   selected_section = controller.class::SECTION
+   selected_section = controller.class::SECTION if defined?(controller.class::SECTION)
+
    if selected_section==Navigation::SECTION_RESOURCE && !@project && !@resource
      selected_section = Navigation::SECTION_HOME
    end
   <div id="sb">
     <div id="sidebar">
       <ul>
-        <% if selected_section==Navigation::SECTION_HOME %>
-          <% ActiveDashboard.user_dashboards(current_user, true).each do |active_dashboard| %>
-            <li class="<%= 'selected' if @dashboard && controller.controller_path=='dashboard' && active_dashboard.dashboard_id==@dashboard.id -%>">
-              <a href="<%= ApplicationController.root_context -%>/dashboard/?did=<%= active_dashboard.dashboard_id -%>"><%= active_dashboard.dashboard.name(true) -%></a>
-            </li>
-          <% end %>
+        <li>
+          <a href="<%= ApplicationController.root_context -%>/"><%= message('layout.dashboards') -%></a>
+        </li>
+        <li>
+          <a href="<%= ApplicationController.root_context -%>/measures"><%= message('layout.measures') -%></a>
+        </li>
+        <%= render 'layouts/tools' -%>
+      </ul>
+    </div>
+    <div id="nav">
+      <ul>
+        <li>
+          <input type="text" size="15" name="search" id="searchInput" onFocus="autocompleteResources()" value="<%= message('search_verb') -%>"/>
+          <img src="<%= ApplicationController.root_context -%>/images/loading-small.gif" id="searchingResources" style="display:none">
+        </li>
+        <li>
+          <a href="javascript:window.print()"><img src="<%= ApplicationController.root_context -%>/images/print.gif" alt="<%= message('layout.print') -%>" title="<%= message('layout.print') -%>"/></a>
+        </li>
+        <% unless logged_in? %>
+          <li><a href="<%= ApplicationController.root_context -%>/sessions/new?return_to=<%= u (request.request_uri) -%>"><%= message('layout.login') -%></a></li>
+        <% end %>
+        <%= render 'layouts/user_panel' -%>
+      </ul>
+    </div>
+    <div id="searchResourcesResults" class="autocomplete" style="display:none"></div>
+  </div>
+  <%= render 'layouts/breadcrumb' if selected_section==Navigation::SECTION_RESOURCE -%>
 
-          <% controller.java_facade.getPages(Navigation::SECTION_HOME, nil, nil, nil, nil).each do |page|
-            page_url = (page.isController() ? page.getId() : "/plugins/home/#{page.getId()}")
-            selected=request.request_uri.include?("/plugins/home/#{page_url}")
-          %>
-            <li class="<%= 'selected' if selected -%>">
-              <a href="<%= ApplicationController.root_context -%><%= page_url -%>"><%= message(page.getId() + '.page', :default => page.getTitle()) -%></a></li>
-          <% end %>
+  <div id="body">
+    <% if selected_section %>
+      <div id="sb">
+        <div id="sidebar">
+          <ul>
+            <% if selected_section==Navigation::SECTION_HOME %>
+              <% ActiveDashboard.user_dashboards(current_user, true).each do |active_dashboard| %>
+                <li class="<%= 'selected' if @dashboard && controller.controller_path=='dashboard' && active_dashboard.dashboard_id==@dashboard.id -%>">
+                  <a href="<%= ApplicationController.root_context -%>/dashboard/?did=<%= active_dashboard.dashboard_id -%>"><%= active_dashboard.dashboard.name(true) -%></a>
+                </li>
+              <% end %>
 
         <% elsif selected_section==Navigation::SECTION_RESOURCE %>
           <% ActiveDashboard.user_dashboards(current_user, false).each do |active_dashboard| %>
               <li class="<%= 'selected' if request.request_uri.include?('/project/deletion') -%>">
                 <a href="<%= ApplicationController.root_context -%>/project/deletion/<%= @project.id -%>"><%= message('resource_deletion.page', :params => message('qualifier.' + @project.qualifier)) -%></a>
               </li>
-            <% end %>
-          <% end %>
+              <li class="<%= 'selected' if request.request_uri.include?('/cloud/index') -%>">
+                <a href="<%= ApplicationController.root_context -%>/cloud/index/<%= @project.id -%>"><%= message('clouds.page') -%></a></li>
+              <% controller.java_facade.getPages(Navigation::SECTION_RESOURCE, @project.scope, @project.qualifier, @project.language, @project.last_snapshot.metric_keys.to_java(:string)).each do |page|
+                page_url = (page.isController() ? "#{page.getId()}?id=#{@project.id}" : "/plugins/resource/#{@project.id}?page=#{page.getId()}")
+              %>
+                <li class="<%= 'selected' if request.request_uri.include?(page_url) -%>">
+                  <a href="<%= ApplicationController.root_context -%><%= page_url -%>"><%= message(page.getId() + '.page', :default => page.getTitle()) %></a>
+                </li>
+              <% end %>
+              <% if has_role?(:admin, @project) %>
+                <li class="h2"><%= message('sidebar.project_settings') -%></li>
+                <% if (@project.project?) %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/profile') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/profile/<%= @project.id -%>"><%= message('project_quality_profiles.page') -%></a></li>
+                <% end %>
+                <li class="<%= 'selected' if request.request_uri.include?('/manual_measures') -%>">
+                  <a href="<%= ApplicationController.root_context -%>/manual_measures/index/<%= @project.id -%>"><%= message('manual_measures.page') -%></a></li>
+                <% if (@project.project?) %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/action_plans') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/action_plans/index/<%= @project.id -%>"><%= message('action_plans.page') -%></a></li>
+                <% end %>
+                <% if (@project.project? || @project.module?) %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/settings') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/settings/<%= @project.id -%>"><%= message('project_settings.page') -%></a>
+                  </li>
+                <% end %>
+                <% if (@project.project?) %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/links') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/links/<%= @project.id -%>"><%= message('project_links.page') -%></a></li>
+                <% end %>
+                <%
+                   # NOTE: we keep "@project.view? || @project.subview?" in the test for backward compatibility with the Views plugin
+                   if (controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'hasRolePolicy') || @project.view? || @project.subview?)
+                %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project_roles') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project_roles/index?resource=<%= @project.id -%>"><%= message('roles.page') -%></a></li>
+                <% end %>
+                <%
+                   # NOTE: we keep "@project.view? || @project.subview?" in the test for backward compatibility with the Views plugin
+                   if (controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'modifiable_history') || @project.view? || @project.subview?)
+                %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/history') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/history/<%= @project.id -%>"><%= message('project_history.page') -%></a></li>
+                <% end %>
+                <% if controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'updatable_key') %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/key') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/key/<%= @project.id -%>"><%= message('update_key.page') -%></a></li>
+                <% end %>
+                <% if controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'deletable') %>
+                  <li class="<%= 'selected' if request.request_uri.include?('/project/deletion') -%>">
+                    <a href="<%= ApplicationController.root_context -%>/project/deletion/<%= @project.id -%>"><%= message('resource_deletion.page', :params => message('qualifier.' + @project.qualifier)) -%></a>
+                  </li>
+                <% end %>
+              <% end %>
 
-        <% elsif selected_section==Navigation::SECTION_CONFIGURATION && is_admin? %>
-        
-            <li class="h2" style="padding-top: 0px;"><%= message('sidebar.project_settings') -%></li>
-            <li class="<%= 'selected' if request.request_uri.include?('/settings') -%>">
-              <a href="<%= ApplicationController.root_context -%>/settings/index"><%= message('settings.page') -%></a></li>
-            <li class="<%= 'selected' if controller.controller_path=='metrics' -%>">
-              <a href="<%= ApplicationController.root_context -%>/metrics/index"><%= message('manual_metrics.page') -%></a></li>
-            <li class="<%= 'selected' if controller.controller_path=='manual_rules' -%>">
-              <a href="<%= ApplicationController.root_context -%>/manual_rules/index"><%= message('manual_rules.page') -%></a></li>
-            <li class="<%= 'selected' if controller.controller_path=='admin_dashboards' -%>">
-              <a href="<%= ApplicationController.root_context -%>/admin_dashboards/index"><%= message('default_dashboards.page') -%></a></li>
-            <% controller.java_facade.getPages(Navigation::SECTION_CONFIGURATION, nil, nil, nil, nil).each do |page|
-              page_url = (page.isController() ? page.getId() : "/plugins/configuration/#{page.getId()}")
-            %>
-              <li class="<%= 'selected' if request.request_uri.include?(page_url) -%>">
-                <a href="<%= ApplicationController.root_context -%><%= page_url -%>"><%= message(page.getId() + '.page', :default => page.getTitle()) %></a>
+            <% elsif selected_section==Navigation::SECTION_CONFIGURATION && is_admin? %>
+
+              <li class="h2" style="padding-top: 0;"><%= message('sidebar.project_settings') -%></li>
+              <li class="<%= 'selected' if request.request_uri.include?('/settings') -%>">
+                <a href="<%= ApplicationController.root_context -%>/settings/index"><%= message('settings.page') -%></a></li>
+              <li class="<%= 'selected' if controller.controller_path=='metrics' -%>">
+                <a href="<%= ApplicationController.root_context -%>/metrics/index"><%= message('manual_metrics.page') -%></a></li>
+              <li class="<%= 'selected' if controller.controller_path=='manual_rules' -%>">
+                <a href="<%= ApplicationController.root_context -%>/manual_rules/index"><%= message('manual_rules.page') -%></a></li>
+              <li class="<%= 'selected' if controller.controller_path=='admin_dashboards' -%>">
+                <a href="<%= ApplicationController.root_context -%>/admin_dashboards/index"><%= message('default_dashboards.page') -%></a></li>
+              <% controller.java_facade.getPages(Navigation::SECTION_CONFIGURATION, nil, nil, nil, nil).each do |page|
+                page_url = (page.isController() ? page.getId() : "/plugins/configuration/#{page.getId()}")
+              %>
+                <li class="<%= 'selected' if request.request_uri.include?(page_url) -%>">
+                  <a href="<%= ApplicationController.root_context -%><%= page_url -%>"><%= message(page.getId() + '.page', :default => page.getTitle()) %></a>
+                </li>
+              <% end %>
+
+              <li class="h2"><%= message('sidebar.security') -%></li>
+              <li class="<%= 'selected' if request.request_uri.include?('/users') -%>"><a href="<%= ApplicationController.root_context -%>/users"><%= message('users.page') -%></a>
               </li>
-            <% end %>
+              <li class="<%= 'selected' if request.request_uri.include?('/groups') -%>">
+                <a href="<%= ApplicationController.root_context -%>/groups/index"><%= message('user_groups.page') -%></a></li>
+              <li class="<%= 'selected' if request.request_uri.include?('/roles/global') -%>">
+                <a href="<%= ApplicationController.root_context -%>/roles/global"><%= message('system_administrators.page') -%></a></li>
+              <li class="<%= 'selected' if request.request_uri.include?('/roles/projects') -%>">
+                <a href="<%= ApplicationController.root_context -%>/roles/projects"><%= message('roles.page') -%></a></li>
 
-            <li class="h2"><%= message('sidebar.security') -%></li>
-            <li class="<%= 'selected' if request.request_uri.include?('/users') -%>"><a href="<%= ApplicationController.root_context -%>/users"><%= message('users.page') -%></a>
-            </li>
-            <li class="<%= 'selected' if request.request_uri.include?('/groups') -%>">
-              <a href="<%= ApplicationController.root_context -%>/groups/index"><%= message('user_groups.page') -%></a></li>
-            <li class="<%= 'selected' if request.request_uri.include?('/roles/global') -%>">
-              <a href="<%= ApplicationController.root_context -%>/roles/global"><%= message('system_administrators.page') -%></a></li>
-            <li class="<%= 'selected' if request.request_uri.include?('/roles/projects') -%>">
-              <a href="<%= ApplicationController.root_context -%>/roles/projects"><%= message('roles.page') -%></a></li>
+              <li class="h2"><%= message('sidebar.system') -%></li>
+              <li class="<%= 'selected' if controller.controller_path=='backup' -%>"><a href="<%= ApplicationController.root_context -%>/backup"><%= message('backup.page') -%></a>
+              </li>
+              <li class="<%= 'selected' if controller.controller_path=='bulk_deletion' -%>">
+                <a href="<%= ApplicationController.root_context -%>/bulk_deletion"><%= message('bulk_deletion.page') -%></a>
+              </li>
+              <% update_center_activated = controller.java_facade.getSettings().getBoolean('sonar.updatecenter.activate')
+                 if update_center_activated %>
+                <li class="<%= 'selected' if controller.controller_path=='updatecenter' -%>">
+                  <a href="<%= ApplicationController.root_context -%>/updatecenter"><%= message('update_center.page') -%></a></li>
+                <li class="<%= 'selected' if controller.controller_path=='system' -%>">
+                  <a href="<%= ApplicationController.root_context -%>/system"><%= message('system_info.page') -%></a></li>
+              <% end %>
 
-            <li class="h2"><%= message('sidebar.system') -%></li>
-            <li class="<%= 'selected' if controller.controller_path=='backup' -%>"><a href="<%= ApplicationController.root_context -%>/backup"><%= message('backup.page') -%></a>
-            </li>
-            <li class="<%= 'selected' if controller.controller_path=='bulk_deletion' -%>">
-              <a href="<%= ApplicationController.root_context -%>/bulk_deletion"><%= message('bulk_deletion.page') -%></a>
-            </li>
-            <% update_center_activated = controller.java_facade.getSettings().getBoolean('sonar.updatecenter.activate')
-               if update_center_activated %>
-              <li class="<%= 'selected' if controller.controller_path=='updatecenter' -%>">
-                <a href="<%= ApplicationController.root_context -%>/updatecenter"><%= message('update_center.page') -%></a></li>
-            <li class="<%= 'selected' if controller.controller_path=='system' -%>">
-              <a href="<%= ApplicationController.root_context -%>/system"><%= message('system_info.page') -%></a></li>
             <% end %>
+          </ul>
+          <%= yield :sidebar %>
+          <div id="logo">
+            <center><a href="http://www.sonarsource.org/" target="SonarSource"><%= image_tag('sonar.png', :alt => message('layout.sonar.slogan'), :class => 'png') -%></a></center>
+          </div>
+        </div>
 
+        <% if @sidebar %>
+          <div id="sidebarconf"><%= render :partial => @sidebar %></div>
+        <% else %>
+          <div id="sidebarconf" class="hidden"></div>
         <% end %>
-      </ul>
-      <%= yield :sidebar %>
-      <div id="logo">
-        <center><a href="http://www.sonarsource.org/" target="SonarSource"><%= image_tag('sonar.png', :alt => message('layout.sonar.slogan'), :class => 'png') -%></a></center>
       </div>
-    </div>
-
-    <% if @sidebar %>
-      <div id="sidebarconf"><%= render :partial => @sidebar %></div>
-    <% else %>
-      <div id="sidebarconf" class="hidden"></div>
     <% end %>
 
-  </div>
-  <div id="content" class="with_sidebar">
-    <% if @project %>
-      <div class="print"><h2><%= @project.name(true) %></h2></div>
-    <% end %>
-    <div class="error" id="error" style="display:none">
-      <span id="errormsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('error').hide();return false;"><%= message('hide').downcase -%></a>]
-    </div>
-    <div class="notice" id="info" style="display:none">
-      <span id="infomsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('info').hide();return false;"><%= message('hide').downcase -%></a>]
-    </div>
-    <div class="warning" id="warning" style="display:none">
-      <span id="warningmsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('warning').hide();return false;"><%= message('hide').downcase -%></a>]
+    <div id="content" class="<%= selected_section ? 'with_sidebar' : 'wo_sidebar' -%>">
+      <% if @project %>
+        <div class="print"><h2><%= @project.name(true) %></h2></div>
+      <% end %>
+      <div class="error" id="error" style="display:none">
+        <span id="errormsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('error').hide();return false;"><%= message('hide').downcase -%></a>]
+      </div>
+      <div class="notice" id="info" style="display:none">
+        <span id="infomsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('info').hide();return false;"><%= message('hide').downcase -%></a>]
+      </div>
+      <div class="warning" id="warning" style="display:none">
+        <span id="warningmsg"></span> &nbsp;&nbsp;[<a href="#" onclick="javascript:$('warning').hide();return false;"><%= message('hide').downcase -%></a>]
+      </div>
+      <%= yield %>
     </div>
-    <%= yield %>
   </div>
 </div>
-</div>
 
 <% unless params[:hd]=='false' %>
   <%= yield :footer %>
index deb3d90ab37f81fe7ec0110d89b13bd30035f29f..ca88e75f055989617dfa7d252b431a202fdcacb2 100644 (file)
@@ -1,77 +1,75 @@
 <% content_for :style do %>
   <style type="text/css">
-    #filter-form {
-      float: left;
-      width: 240px;
+    #filter-form [type="text"].large-input {
+      width: 180px;
+
     }
 
-    #filter-form select {
-      width: 200px;
-      padding: 1px;
+    #filter-form select.large-input {
+      width: 100%;
+      box-sizing: border-box;
+      -webkit-box-sizing: border-box;
+      -moz-box-sizing: border-box;
     }
 
     #filter-form select option {
       padding: 1px 10px 1px 4px;
     }
-
-    #filter-result {
-      padding-left: 250px;
-    }
   </style>
 <% end %>
 
-<div id="measure-filter">
-  <div id="filter-form">
+<div id="measure-filters">
+  <div id="filter-form" class="page-split-left">
     <form method="GET" action="<%= ApplicationController.root_context -%>/measures/search">
       <% if @filter.id %>
         <input type="hidden" name="id" value="<%= @filter.id -%>">
       <% end %>
-      <table>
+      <table class="width100">
         <tbody>
         <tr>
-          <td>
+          <td class="width100">
             Base:<br>
-            <input type="text" name="base" value="<%= @filter.criteria['base'] -%>">
+            <input type="text" name="base" value="<%= @filter.criteria['base'] -%>" class="large-input">
           </td>
         </tr>
         <tr>
-          <td>
+          <td class="width100">
             On components:<br>
             <%= check_box_tag 'onBaseComponents', 'true', @filter.criteria['onBaseComponents'] -%>
           </td>
         </tr>
         <tr>
-          <td>
+          <td class="width100">
             Qualifiers:<br>
             <%
-              qualifiers = Api::Utils.java_facade.getResourceTypesForFilter().map do |resource_type|
-                [message("qualifiers.#{resource_type.getQualifier()}"), resource_type.getQualifier()]
-              end
+               qualifiers = Api::Utils.java_facade.getResourceTypesForFilter().map do |resource_type|
+                 [message("qualifiers.#{resource_type.getQualifier()}"), resource_type.getQualifier()]
+               end
             %>
-            <%= select_tag 'qualifiers[]', options_for_select([[message('any'), '']].concat(qualifiers), @filter.criteria['qualifiers']||''), :size => 5, :multiple => true -%>
+            <%= select_tag 'qualifiers[]', options_for_select([[message('any'), '']].concat(qualifiers), @filter.criteria['qualifiers']||''), :size => 5, :multiple => true, :class => 'large-input' -%>
           </td>
         </tr>
         <tr>
           <td>
             Language:<br>
             <% languages = [[message('any'), '']].concat(Api::Utils.languages.map { |lang| [lang.name, lang.key] }) %>
-            <%= select_tag 'languages[]', options_for_select(languages, @filter.criteria['languages']||''), :size => 5, :multiple => true -%>
+            <%= select_tag 'languages[]', options_for_select(languages, @filter.criteria['languages']||''), :size => 5, :multiple => true, :class => 'large-input' -%>
           </td>
         </tr>
         <tr>
-          <td>
+          <td class="width100">
             Name:<br>
-            <input type="text" name="nameRegexp" value="<%= h @filter.criteria['nameRegexp'] -%>"></td>
+            <input type="text" name="nameRegexp" value="<%= h @filter.criteria['nameRegexp'] -%>" class="large-input"></td>
         </tr>
         <tr>
-          <td>
+          <td class="width100">
             Key:<br>
-            <input type="text" name="keyRegexp" value="<%= h @filter.criteria['keyRegexp'] -%>"></td>
+            <input type="text" name="keyRegexp" value="<%= h @filter.criteria['keyRegexp'] -%>" class="large-input"></td>
         </tr>
         <tr>
           <td>
             Favourites only:<br>
-            <%= check_box_tag 'onFavourites', 'true', @filter.criteria['onFavourites']=='true' %>
+            <%= check_box_tag 'onFavourites', 'true', @filter.criteria['onFavourites']=='true' -%>
           </td>
         </tr>
         <tr>
@@ -99,6 +97,7 @@
         </tr>
         <tr>
           <td>
+            <br/>
             <input type="submit" name="search" value="Search">
             <a href="<%= ApplicationController.root_context -%>/measures">New search</a>
           </td>
       </table>
     </form>
 
-    <br/>
-
     <% if logged_in? %>
+      <br/>
       <ul id="my-filters">
         <% current_user.favourited_measure_filters.each do |my_filter| %>
           <li>
   </div>
 
   <% if @filter.results %>
-    <div id="filter-result">
+    <div id="filter-result" class="page-split-right width100">
       <% if @filter.name %>
-        <h2><%= h @filter.name -%></h2>
-        <% if @filter.description %>
-          <p><%= h @filter.description -%></p>
-        <% end %>
+        <p>
+          <span class="h3"><%= h @filter.name -%></span>
+          <% if @filter.description.present? %>
+            - <span><%= h @filter.description -%></span>
+          <% end %>
+        </p>
+
       <% end %>
 
       Display as:
index 551d37ad0faae008ac1dae3471d7075feeb1ae3d..df7dadddd53500e1efd9780b1888d610296d8e5a 100644 (file)
@@ -53,11 +53,11 @@ body, a {
 #hd {
   color: #FFF;
   background: #262626;
-  padding: 0 5px;
+  padding: 0 8px 0 18px;
   height: 30px;
   line-height: 30px;
   font-size: 93%;
-  margin: 0 10px;
+  margin: 0;
   position: relative;
 }
 
@@ -87,7 +87,7 @@ body, a {
 
 #nav-left > ul> li {
   float: left;
-  padding: 0 10px 0 5px;
+  padding: 0 10px 0 0;
 }
 
 #nav > ul> li {
@@ -106,13 +106,14 @@ body, a {
 #crumbs {
   color: #444;
   background: #EFEFEF;
-  height: 22px;
-  line-height: 22px;
+  height: 26px;
+  line-height: 26px;
   font-size: 93%;
-  margin: 0 10px;
+  margin: 0;
+  padding: 0 8px 0 18px;
   border-bottom: 1px solid #CCC;
-  border-right: 1px solid #CCC;
 }
+
 #crumbs img {
   vertical-align: text-bottom;
 }
@@ -127,8 +128,7 @@ body, a {
 
 #bc li.first {
   background: #EFEFEF;
-  border-left: 2px solid #CCC;
-  padding: 0 10px 0 5px;
+  padding: 0 10px 0 0;
 }
 
 #bc li img {
@@ -193,22 +193,22 @@ body, a {
 }
 
 .with_sidebar {
-  margin: 0 10px 0 170px;
+  margin: 0 8px 0 168px;
 }
 
 .wo_sidebar {
-  margin: 0 10px 0 10px;
+  margin: 0 8px;
 }
 
 #content {
-  padding-top: 10px;
+  padding-top: 8px;
   width: auto;
 }
 
 #sb {
   width: 150px;
   position: absolute;
-  margin: 0 10px;
+  margin: 0 8px;
   top: 0;
   left: 0;
 }
@@ -279,3 +279,26 @@ body, a {
 .nolayout {
   padding: 10px;
 }
+
+.page-split-left {
+  min-width: 180px;
+  width: 180px;
+  margin: 0;
+  -moz-box-sizing: border-box;
+  display: table-cell;
+  vertical-align: top;
+  background-color: #EFEFEF;
+  border: 1px solid #CCC;
+  color: #666;
+  line-height: 1.1em;
+  padding: 10px;
+}
+
+.page-split-right {
+  position: relative;
+  padding: 10px 0 0 10px;
+  -moz-box-sizing: border-box;
+  display: table-cell;
+  margin: 0;
+  vertical-align: top;
+}
\ No newline at end of file