From bf3c5e070e2ee74181aa8b2c75f32387827b01c2 Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Thu, 27 Jun 2013 20:49:29 -0700 Subject: remove submenus. for more context: http://www.youtube.com/watch?v=ggWyUEuGcWY&feature=youtu.be&t=48s --- less/dropdowns.less | 62 +---------------------------------------------------- 1 file changed, 1 insertion(+), 61 deletions(-) (limited to 'less/dropdowns.less') diff --git a/less/dropdowns.less b/less/dropdowns.less index 3e0152788..f2ddc4392 100644 --- a/less/dropdowns.less +++ b/less/dropdowns.less @@ -63,9 +63,7 @@ // Hover/Focus state // ----------- .dropdown-menu > li > a:hover, -.dropdown-menu > li > a:focus, -.dropdown-submenu:hover > a, -.dropdown-submenu:focus > a { +.dropdown-menu > li > a:focus { text-decoration: none; color: @dropdown-link-hover-color; #gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%)); @@ -153,64 +151,6 @@ } } -// Sub menus -// --------------------------- -.dropdown-submenu { - position: relative; -} -// Default dropdowns -.dropdown-submenu > .dropdown-menu { - top: 0; - left: 100%; - margin-top: -6px; - margin-left: -1px; - border-top-left-radius: 0; // Nuke the closest corner as appropriate -} -.dropdown-submenu:hover > .dropdown-menu { - display: block; -} - -// Dropups -.dropup .dropdown-submenu > .dropdown-menu { - top: auto; - bottom: 0; - margin-top: 0; - margin-bottom: -2px; - border-bottom-left-radius: 0; // Nuke the closest corner as appropriate -} - -// Caret to indicate there is a submenu -.dropdown-submenu > a:after { - display: block; - content: " "; - float: right; - width: 0; - height: 0; - border-color: transparent; - border-style: solid; - border-width: 5px 0 5px 5px; - border-left-color: darken(@dropdown-bg, 20%); - margin-top: 5px; - margin-right: -10px; -} -.dropdown-submenu:hover > a:after { - border-left-color: @dropdown-link-hover-color; -} - -// Left aligned submenus -.dropdown-submenu.pull-left { - // Undo the float - // Yes, this is awkward since .pull-left adds a float, but it sticks to our conventions elsewhere. - float: none; - - // Positioning the submenu - > .dropdown-menu { - left: -100%; - margin-left: 10px; - border-top-right-radius: 0; // Remove the rounded corner here - } -} - // Tweak nav headers // --------------------------- // Increase padding from 15px to 20px on sides -- cgit v1.2.3 From e6529e9588bed07af84daeb7af2651f05cb9220e Mon Sep 17 00:00:00 2001 From: liuyl Date: Fri, 5 Jul 2013 15:09:16 +0800 Subject: delete typeahead style --- less/dropdowns.less | 6 ------ 1 file changed, 6 deletions(-) (limited to 'less/dropdowns.less') diff --git a/less/dropdowns.less b/less/dropdowns.less index f2ddc4392..0a412f9c3 100644 --- a/less/dropdowns.less +++ b/less/dropdowns.less @@ -158,9 +158,3 @@ padding-left: 20px; padding-right: 20px; } - -// Typeahead -// --------------------------- -.typeahead { - z-index: 1051; -} -- cgit v1.2.3 From 7e154740f3c9a06cfdd406672ba0ba143cd50b4d Mon Sep 17 00:00:00 2001 From: Chris Rebert Date: Sat, 6 Jul 2013 22:27:56 -0700 Subject: use LESS nesting more in dropdowns.less --- less/dropdowns.less | 54 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 31 insertions(+), 23 deletions(-) (limited to 'less/dropdowns.less') diff --git a/less/dropdowns.less b/less/dropdowns.less index 0a412f9c3..8ae9dbba1 100644 --- a/less/dropdowns.less +++ b/less/dropdowns.less @@ -62,40 +62,48 @@ // Hover/Focus state // ----------- -.dropdown-menu > li > a:hover, -.dropdown-menu > li > a:focus { - text-decoration: none; - color: @dropdown-link-hover-color; - #gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%)); +.dropdown-menu > li > a { + &:hover, + &:focus { + text-decoration: none; + color: @dropdown-link-hover-color; + #gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%)); + } } // Active state // ------------ -.dropdown-menu > .active > a, -.dropdown-menu > .active > a:hover, -.dropdown-menu > .active > a:focus { - color: @dropdown-link-active-color; - text-decoration: none; - outline: 0; - #gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%)); +.dropdown-menu > .active > a { + &, + &:hover, + &:focus { + color: @dropdown-link-active-color; + text-decoration: none; + outline: 0; + #gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%)); + } } // Disabled state // -------------- // Gray out text and ensure the hover/focus state remains gray -.dropdown-menu > .disabled > a, -.dropdown-menu > .disabled > a:hover, -.dropdown-menu > .disabled > a:focus { - color: @gray-light; +.dropdown-menu > .disabled > a { + &, + &:hover, + &:focus { + color: @gray-light; + } } // Nuke hover/focus effects -.dropdown-menu > .disabled > a:hover, -.dropdown-menu > .disabled > a:focus { - text-decoration: none; - background-color: transparent; - background-image: none; // Remove CSS gradient - .reset-filter(); - cursor: default; +.dropdown-menu > .disabled > a { + &:hover, + &:focus { + text-decoration: none; + background-color: transparent; + background-image: none; // Remove CSS gradient + .reset-filter(); + cursor: default; + } } // Open state for the dropdown -- cgit v1.2.3