From 30c8be62204cecdf5060b1d766e44b78a3ecfa6c Mon Sep 17 00:00:00 2001 From: Nikolai Kristiansen Date: Fri, 14 Sep 2012 16:03:09 +0200 Subject: [PATCH] Menu style updates, fixes sub-menu --- wp-content/themes/tn-2012/sass/screen.scss | 40 +++++++++++++++++-- .../themes/tn-2012/stylesheets/screen.css | 35 ++++++++++++++-- 2 files changed, 68 insertions(+), 7 deletions(-) diff --git a/wp-content/themes/tn-2012/sass/screen.scss b/wp-content/themes/tn-2012/sass/screen.scss index b086289..b9b9adb 100644 --- a/wp-content/themes/tn-2012/sass/screen.scss +++ b/wp-content/themes/tn-2012/sass/screen.scss @@ -110,12 +110,46 @@ body { ul { @include inline-list; + ul { + position: absolute; + display: none; + margin: 0; + } + li { - border-right: 1px solid #FFFFE1; - padding: 6px; + float: left; + + &:hover ul, &:focus ul { + display:block; + z-index:9; + color:rgba(255,255,255,1); + background:rgba(0,0,0,0.3); + } + + a { + display: block; + height: 22px; + padding: 0px 7px 7px; + text-decoration: none; + border-right: 1px solid #FFFFE1; + + &:hover, .current { + color:rgba(255,255,255,1); + background:rgba(0,0,0,0.3); + } + } + + .sub-menu li { + position: relative; + a { + border: 0px; + } + } &.social-icon { - border: 0px; + a { + border: 0px; + } #facebook-icon { padding-left: 6px; diff --git a/wp-content/themes/tn-2012/stylesheets/screen.css b/wp-content/themes/tn-2012/stylesheets/screen.css index 42e422d..e1fc78c 100644 --- a/wp-content/themes/tn-2012/stylesheets/screen.css +++ b/wp-content/themes/tn-2012/stylesheets/screen.css @@ -169,11 +169,38 @@ body #site-header #header-container #menu ul, body #site-header #header-containe padding: 0px; display: inline; } -body #site-header #header-container #menu ul li { - border-right: 1px solid #FFFFE1; - padding: 6px; +body #site-header #header-container #menu ul ul { + position: absolute; + display: none; + margin: 0; } -body #site-header #header-container #menu ul li.social-icon { +body #site-header #header-container #menu ul li { + float: left; +} +body #site-header #header-container #menu ul li:hover ul, body #site-header #header-container #menu ul li:focus ul { + display: block; + z-index: 9; + color: white; + background: rgba(0, 0, 0, 0.3); +} +body #site-header #header-container #menu ul li a { + display: block; + height: 22px; + padding: 0px 7px 7px; + text-decoration: none; + border-right: 1px solid #FFFFE1; +} +body #site-header #header-container #menu ul li a:hover, body #site-header #header-container #menu ul li a .current { + color: white; + background: rgba(0, 0, 0, 0.3); +} +body #site-header #header-container #menu ul li .sub-menu li { + position: relative; +} +body #site-header #header-container #menu ul li .sub-menu li a { + border: 0px; +} +body #site-header #header-container #menu ul li.social-icon a { border: 0px; } body #site-header #header-container #menu ul li.social-icon #facebook-icon {