From 4fe8ef40ee70bee9d4ad897b51f602231e81bfc3 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Thu, 29 Jun 2017 18:22:34 -0400 Subject: Worked on sidebar style --- app/assets/stylesheets/application.css.scss | 49 ++++++++++++++++++++--------- app/views/layouts/application.html.haml | 6 ++-- 2 files changed, 37 insertions(+), 18 deletions(-) diff --git a/app/assets/stylesheets/application.css.scss b/app/assets/stylesheets/application.css.scss index 44383b4..a1445d6 100644 --- a/app/assets/stylesheets/application.css.scss +++ b/app/assets/stylesheets/application.css.scss @@ -32,6 +32,7 @@ body#main-body { min-width: 890px; display: -webkit-flex; display: flex; + flex-direction: row-reverse; } @keyframes trottingPonies { @@ -65,6 +66,7 @@ body#main-body { -moz-box-shadow: 1px 1px 5px 0px rgba(0,0,0,0.75); box-shadow: 1px 1px 5px 0px rgba(0,0,0,0.75); width: 75%; + min-width: 720px } #content { @@ -72,19 +74,6 @@ body#main-body { padding-top: 1em; } -#sidebar { - box-sizing: border-box; - padding: 1em; - width: 25%; - font-size: .75em; - color: black; - border-left: 1px solid #eee; -} - -#sidebar h2 { - font-size: 1em; -} - #flash { width: 100%; text-align: center; @@ -194,12 +183,42 @@ body#userdata-body { font-weight: bold; } -.sidebar-module + .sidebar-module { - margin-top: 2em; +#sidebar { + box-sizing: border-box; + width: 25%; + font-size: .75em; + color: black; + border-left: 1px solid #eee; + margin-top: 1em; + margin-bottom: 2em; +} + +#sidebar h2 { + font-size: 1em; + margin: 0; +} + +.sidebar-module { + padding: 1em; + margin-top: 1em; + box-shadow: 1px 1px 2px 0px rgba(0, 0, 0, 0.75); +} + +.sidebar-module:nth-child(2n+1) { + background-color: #feff8f; +} + +.sidebar-module:nth-child(2n+2) { + background-color: #8fefab; +} + +.sidebar-module p { + margin-bottom: 0; } .sidebar-module ul { padding-left: 0; + margin-bottom: 0; } .sidebar-module li { diff --git a/app/views/layouts/application.html.haml b/app/views/layouts/application.html.haml index ee028b4..ed3b9a2 100644 --- a/app/views/layouts/application.html.haml +++ b/app/views/layouts/application.html.haml @@ -11,9 +11,6 @@ - if flash[:notice] %div#flash.flash-notice= flash[:notice] #container - #main - %header#banner= link_to "feffernoo.se", root_url - #content= yield #sidebar .sidebar-module %h2 I'm Fef. @@ -25,3 +22,6 @@ %li= link_to "Log in", new_user_session_path - if user_signed_in? %li= link_to "Log out", destroy_user_session_path, method: :delete + #main + %header#banner= link_to "feffernoo.se", root_url + #content= yield -- cgit 1.4.1