narrower sidebar, transparent minimized state, cleaned up search results

This commit is contained in:
Eden Halperin 2013-11-05 11:37:21 -05:00 committed by John Firebaugh
parent ff752b072f
commit 080236a242
4 changed files with 29 additions and 15 deletions

View file

@ -11,8 +11,8 @@ $lightgrey: #EEE;
$darkgrey: #AAA;
$hovercolor: 20%;
$headerHeight: 54px;
$sidebarWidth: 350px;
$keyline: 1px solid $grey;
$sidebarWidth: 300px;
$keyline: 1px solid $lightgrey;
$border-radius: 3px;
/* Styles common to large and small screens */
@ -595,11 +595,13 @@ nav.secondary {
border-right: $keyline;
h2, h3, h4 {
padding: $lineheight;
padding: $lineheight $lineheight $lineheight/2;
}
h4 {
font-weight: normal;
color: #666;
font-size: 12px;
}
.icon.close {
@ -620,16 +622,28 @@ nav.secondary {
color: #666;
}
}
p.large-text {
font-size: 1.7em;
line-height: 1.4em;
font-weight: 300;
}
}
#sidebar.minimized {
position: absolute;
z-index: 1000;
height: auto;
border-right: none;
#sidebar_content {
display: none;
}
#search_form {
background: none;
width: 78%;
}
}
#map {
@ -805,7 +819,7 @@ nav.secondary {
#sidebar_content {
position: absolute;
top: 72px;
top: 50px;
bottom: 0;
width: 100%;
overflow-y: auto;
@ -823,9 +837,8 @@ nav.secondary {
#search_form {
position: relative;
padding: $lineheight;
padding: $lineheight/2 $lineheight;
background-color: $lightgrey;
border-bottom: $keyline;
#query_wrapper {
position: relative;
@ -925,7 +938,8 @@ a.donate {
.search_results_entry {
ul li {
border-bottom: 1px solid #ccc;
border-bottom: $keyline;
&:first-child { border-top: $keyline; }
}
.search_details {

View file

@ -18,11 +18,11 @@ module GeocoderHelper
html << link_to(result[:name], url, html_options) if result[:name]
html << result[:suffix] if result[:suffix]
if result[:type] and result[:id]
html << content_tag(:small, :class => ["deemphasize", "search_details"]) do
link_to(t("browse.#{result[:type]}_history.view_details"), :controller => :browse, :action => result[:type], :id => result[:id])
end
end
# if result[:type] and result[:id]
# html << content_tag(:small, :class => ["deemphasize", "search_details"]) do
# link_to(t("browse.#{result[:type]}_history.view_details"), :controller => :browse, :action => result[:type], :id => result[:id])
# end
# end
return raw(html)
end

View file

@ -1,6 +1,6 @@
<h2><%= t('site.sidebar.search_results') %></h2>
<% @sources.each do |source| %>
<h4><%= raw(t "geocoder.search.title.#{source}") %></h4>
<h4 class="inner12"><%= raw(t "geocoder.search.title.#{source}") %></h4>
<div class="search_results_entry" data-href="<%= url_for params.merge(:action => "search_#{source}") %>">
<%= image_tag "searching.gif", :class => "loader" %>
</div>

View file

@ -3,7 +3,7 @@
<span class="icon close"></span>
</h2>
<p class="inner22"><%= t 'layouts.intro_text' %></p>
<p class="inner12 large-text"><%= t 'layouts.intro_text' %></p>
<div class='footer'>
<a title="<%= t('layouts.make_a_donation.title') %>" href="http://donate.openstreetmap.org/" class="donate">
@ -11,7 +11,7 @@
<span><%= t('layouts.make_a_donation.text') %></span>
</a>
<p class='credits inner22'>
<p class='credits inner12'>
<%= t 'layouts.partners_html',
:ucl => link_to(t('layouts.partners_ucl'), "http://www.vr.ucl.ac.uk"),
:ic => link_to(t('layouts.partners_ic'), "http://www.imperial.ac.uk/"),