0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-12-01 13:24:25 +01:00

Merge pull request #8406 from cvrebert/navs-nesting

more nesting in navs.less
This commit is contained in:
Mark Otto 2013-07-07 18:26:26 -07:00
commit 65141338df

View File

@ -31,14 +31,15 @@
// Disabled state sets text to gray and nukes hover/tab effects
&.disabled > a {
color: @gray-light;
}
&.disabled > a:hover,
&.disabled > a:focus {
&:hover,
&:focus {
color: @gray-light;
text-decoration: none;
background-color: transparent;
cursor: default;
}
}
// Space the headers out when they follow another list item (link)
+ .nav-header {
@ -47,9 +48,10 @@
}
// Open dropdowns
&.open > a,
&.open > a:hover,
&.open > a:focus {
&.open > a {
&,
&:hover,
&:focus {
color: #fff;
background-color: @link-color;
border-color: @link-color;
@ -58,6 +60,7 @@
border-bottom-color: #fff;
}
}
}
// Redeclare pull classes because of specificity
// Todo: consider making these utilities !important to avoid this bullshit
@ -99,9 +102,10 @@
}
// Active state, and it's :hover to override normal :hover
&.active > a,
&.active > a:hover,
&.active > a:focus {
&.active > a {
&,
&:hover,
&:focus {
color: @gray;
background-color: @body-bg;
border: 1px solid #ddd;
@ -109,6 +113,7 @@
cursor: default;
}
}
}
// pulling this in mainly for less shorthand
&.nav-justified {
.nav-justified;
@ -134,13 +139,15 @@
}
// Active state
&.active > a,
&.active > a:hover,
&.active > a:focus {
&.active > a {
&,
&:hover,
&:focus {
color: #fff;
background-color: @component-active-bg;
}
}
}
}
@ -218,9 +225,11 @@
.pill-content > .pill-pane {
display: none;
}
.tab-content > .active,
.pill-content > .active {
.tab-content,
.pill-content {
> .active {
display: block;
}
}