aboutsummaryrefslogtreecommitdiff
path: root/lib/responsive.less
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2012-01-08 02:30:18 -0800
committerMark Otto <[email protected]>2012-01-08 02:30:18 -0800
commit9e7acc637057292205906edc99fb23a49c937afa (patch)
tree792705ba809d15e2d9d710ea9d1974ae7f06b842 /lib/responsive.less
parentcf05dc86774ea05aa0f40aff771538e6e2f405d2 (diff)
downloadbootstrap-9e7acc637057292205906edc99fb23a49c937afa.tar.xz
bootstrap-9e7acc637057292205906edc99fb23a49c937afa.zip
fix responsive navbar nav treatment by using hover instead of click
Diffstat (limited to 'lib/responsive.less')
-rw-r--r--lib/responsive.less100
1 files changed, 55 insertions, 45 deletions
diff --git a/lib/responsive.less b/lib/responsive.less
index 7856121be..9f8f9ec6c 100644
--- a/lib/responsive.less
+++ b/lib/responsive.less
@@ -81,52 +81,62 @@
}
// Make the nav work for small devices
- .nav {
- position: absolute;
- top: 0;
- left: 0;
- width: 180px;
- padding-top: 40px;
- list-style: none;
- }
- .nav,
- .nav > li:last-child a {
- .border-radius(0 0 4px 0);
- }
- .nav > li {
- float: none;
- display: none;
- }
- .nav > li > a {
- float: none;
- background-color: #222;
- }
- .nav > .active {
- display: block;
- position: absolute;
- top: 0;
- left: 0;
- }
- .navbar ul .active > a {
- background-color: transparent;
- }
- .nav > .active a:after {
- display: inline-block;
- width: 0;
- height: 0;
- margin-top: 8px;
- margin-left: 6px;
- text-indent: -99999px;
- vertical-align: top;
- border-left: 4px solid transparent;
- border-right: 4px solid transparent;
- border-top: 4px solid @white;
- .opacity(100);
- content: "&darr;";
- }
- .nav > .active a:hover {
- background-color: rgba(255,255,255,.05);
+ .navbar {
+ .nav {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 180px;
+ padding-top: 40px;
+ list-style: none;
+ }
+ .nav,
+ .nav > li:last-child a {
+ .border-radius(0 0 4px 0);
+ }
+ .nav > li {
+ float: none;
+ display: none;
+ }
+ .nav > li > a {
+ float: none;
+ background-color: #222;
+ }
+ .nav > .active {
+ display: block;
+ position: absolute;
+ top: 0;
+ left: 0;
+ }
+ .nav > .active > a {
+ background-color: transparent;
+ }
+ .nav > .active > a:hover {
+ background-color: #333;
+ }
+ .nav > .active > a:after {
+ display: inline-block;
+ width: 0;
+ height: 0;
+ margin-top: 8px;
+ margin-left: 6px;
+ text-indent: -99999px;
+ vertical-align: top;
+ border-left: 4px solid transparent;
+ border-right: 4px solid transparent;
+ border-top: 4px solid @white;
+ .opacity(100);
+ content: "&darr;";
+ }
+
+ .nav:hover > li {
+ display: block;
+ }
+ .nav:hover > li > a:hover {
+ background-color: #333;
+ }
}
+
}