From ecbe27b373bbe241af332d51a663192fd71a2520 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Fri, 4 Oct 2013 17:34:06 -0700 Subject: [PATCH 1/1] Render flash in sidebar --- app/assets/stylesheets/common.css.scss | 28 ++++++++++++-------------- app/views/layouts/_flash.html.erb | 15 +++++++++++--- app/views/layouts/map.html.erb | 6 ++++-- 3 files changed, 29 insertions(+), 20 deletions(-) diff --git a/app/assets/stylesheets/common.css.scss b/app/assets/stylesheets/common.css.scss index 43d59cfb5..bef955509 100644 --- a/app/assets/stylesheets/common.css.scss +++ b/app/assets/stylesheets/common.css.scss @@ -561,10 +561,6 @@ nav.secondary { width: $sidebarWidth; border-right: $keyline; - .alert { - background: #e00; - } - h2, h3, h4 { padding: $lineheight; border-bottom: $keyline; @@ -1541,17 +1537,19 @@ a.donate { /* Rules for "flash" notice boxes shown at the top of the content area */ -.flash { - padding: $lineheight; - &#error { - background-color: #ff7070; - } - &#warning { - background-color: #ffe0cc; - } - &#notice { - background-color: #CBEEA7; - } +.error { + padding: $lineheight; + background-color: #ff7070; +} + +.warning { + padding: $lineheight; + background-color: #ffe0cc; +} + +.notice { + padding: $lineheight; + background-color: #CBEEA7; } /* Rules for highlighting fields with rails validation errors */ diff --git a/app/views/layouts/_flash.html.erb b/app/views/layouts/_flash.html.erb index a3cbbc207..51ef3fe41 100644 --- a/app/views/layouts/_flash.html.erb +++ b/app/views/layouts/_flash.html.erb @@ -1,11 +1,20 @@ <% if flash[:error] %> -
<%=image_tag("notice.png", :class => "small_icon", :border=>0)%><%= raw flash[:error] %>
+

+ <%= image_tag("notice.png", :class => "small_icon", :border => 0) %> + <%= raw flash[:error] %> +

<% end %> <% if flash[:warning] %> -
<%=image_tag("notice.png", :class => "small_icon", :border=>0)%><%= raw flash[:warning] %>
+

+ <%= image_tag("notice.png", :class => "small_icon", :border => 0) %> + <%= raw flash[:warning] %> +

<% end %> <% if flash[:notice] %> -
<%=image_tag("notice.png", :class => "small_icon", :border=>0)%><%= raw flash[:notice] %>
+

+ <%= image_tag("notice.png", :class => "small_icon", :border => 0) %> + <%= raw flash[:notice] %> +

<% end %> diff --git a/app/views/layouts/map.html.erb b/app/views/layouts/map.html.erb index a8a15a30f..8be2aff81 100644 --- a/app/views/layouts/map.html.erb +++ b/app/views/layouts/map.html.erb @@ -17,11 +17,13 @@ -- 2.43.2