info@53: // info@53: // Navs info@53: // -------------------------------------------------- info@53: info@53: info@53: // Base class info@53: // -------------------------------------------------- info@53: info@53: .nav { info@53: margin-bottom: 0; info@53: padding-left: 0; // Override default ul/ol info@53: list-style: none; info@53: .clearfix(); info@53: info@53: > li { info@53: position: relative; info@53: display: block; info@53: info@53: > a { info@53: position: relative; info@53: display: block; info@53: padding: @nav-link-padding; info@53: &:hover, info@53: &:focus { info@53: text-decoration: none; info@53: background-color: @nav-link-hover-bg; info@53: } info@53: } info@53: info@53: // Disabled state sets text to gray and nukes hover/tab effects info@53: &.disabled > a { info@53: color: @nav-disabled-link-color; info@53: info@53: &:hover, info@53: &:focus { info@53: color: @nav-disabled-link-hover-color; info@53: text-decoration: none; info@53: background-color: transparent; info@53: cursor: not-allowed; info@53: } info@53: } info@53: } info@53: info@53: // Open dropdowns info@53: .open > a { info@53: &, info@53: &:hover, info@53: &:focus { info@53: background-color: @nav-link-hover-bg; info@53: border-color: @link-color; info@53: } info@53: } info@53: info@53: // Nav dividers (deprecated with v3.0.1) info@53: // info@53: // This should have been removed in v3 with the dropping of `.nav-list`, but info@53: // we missed it. We don't currently support this anywhere, but in the interest info@53: // of maintaining backward compatibility in case you use it, it's deprecated. info@53: .nav-divider { info@53: .nav-divider(); info@53: } info@53: info@53: // Prevent IE8 from misplacing imgs info@53: // info@53: // See https://github.com/h5bp/html5-boilerplate/issues/984#issuecomment-3985989 info@53: > li > a > img { info@53: max-width: none; info@53: } info@53: } info@53: info@53: info@53: // Tabs info@53: // ------------------------- info@53: info@53: // Give the tabs something to sit on info@53: .nav-tabs { info@53: border-bottom: 1px solid @nav-tabs-border-color; info@53: > li { info@53: float: left; info@53: // Make the list-items overlay the bottom border info@53: margin-bottom: -1px; info@53: info@53: // Actual tabs (as links) info@53: > a { info@53: margin-right: 2px; info@53: line-height: @line-height-base; info@53: border: 1px solid transparent; info@53: border-radius: @border-radius-base @border-radius-base 0 0; info@53: &:hover { info@53: border-color: @nav-tabs-link-hover-border-color @nav-tabs-link-hover-border-color @nav-tabs-border-color; info@53: } info@53: } info@53: info@53: // Active state, and it's :hover to override normal :hover info@53: &.active > a { info@53: &, info@53: &:hover, info@53: &:focus { info@53: color: @nav-tabs-active-link-hover-color; info@53: background-color: @nav-tabs-active-link-hover-bg; info@53: border: 1px solid @nav-tabs-active-link-hover-border-color; info@53: border-bottom-color: transparent; info@53: cursor: default; info@53: } info@53: } info@53: } info@53: // pulling this in mainly for less shorthand info@53: &.nav-justified { info@53: .nav-justified(); info@53: .nav-tabs-justified(); info@53: } info@53: } info@53: info@53: info@53: // Pills info@53: // ------------------------- info@53: .nav-pills { info@53: > li { info@53: float: left; info@53: info@53: // Links rendered as pills info@53: > a { info@53: border-radius: @nav-pills-border-radius; info@53: } info@53: + li { info@53: margin-left: 2px; info@53: } info@53: info@53: // Active state info@53: &.active > a { info@53: &, info@53: &:hover, info@53: &:focus { info@53: color: @nav-pills-active-link-hover-color; info@53: background-color: @nav-pills-active-link-hover-bg; info@53: } info@53: } info@53: } info@53: } info@53: info@53: info@53: // Stacked pills info@53: .nav-stacked { info@53: > li { info@53: float: none; info@53: + li { info@53: margin-top: 2px; info@53: margin-left: 0; // no need for this gap between nav items info@53: } info@53: } info@53: } info@53: info@53: info@53: // Nav variations info@53: // -------------------------------------------------- info@53: info@53: // Justified nav links info@53: // ------------------------- info@53: info@53: .nav-justified { info@53: width: 100%; info@53: info@53: > li { info@53: float: none; info@53: > a { info@53: text-align: center; info@53: margin-bottom: 5px; info@53: } info@53: } info@53: info@53: > .dropdown .dropdown-menu { info@53: top: auto; info@53: left: auto; info@53: } info@53: info@53: @media (min-width: @screen-sm-min) { info@53: > li { info@53: display: table-cell; info@53: width: 1%; info@53: > a { info@53: margin-bottom: 0; info@53: } info@53: } info@53: } info@53: } info@53: info@53: // Move borders to anchors instead of bottom of list info@53: // info@53: // Mixin for adding on top the shared `.nav-justified` styles for our tabs info@53: .nav-tabs-justified { info@53: border-bottom: 0; info@53: info@53: > li > a { info@53: // Override margin from .nav-tabs info@53: margin-right: 0; info@53: border-radius: @border-radius-base; info@53: } info@53: info@53: > .active > a, info@53: > .active > a:hover, info@53: > .active > a:focus { info@53: border: 1px solid @nav-tabs-justified-link-border-color; info@53: } info@53: info@53: @media (min-width: @screen-sm-min) { info@53: > li > a { info@53: border-bottom: 1px solid @nav-tabs-justified-link-border-color; info@53: border-radius: @border-radius-base @border-radius-base 0 0; info@53: } info@53: > .active > a, info@53: > .active > a:hover, info@53: > .active > a:focus { info@53: border-bottom-color: @nav-tabs-justified-active-link-border-color; info@53: } info@53: } info@53: } info@53: info@53: info@53: // Tabbable tabs info@53: // ------------------------- info@53: info@53: // Hide tabbable panes to start, show them when `.active` info@53: .tab-content { info@53: > .tab-pane { info@53: display: none; info@53: } info@53: > .active { info@53: display: block; info@53: } info@53: } info@53: info@53: info@53: // Dropdowns info@53: // ------------------------- info@53: info@53: // Specific dropdowns info@53: .nav-tabs .dropdown-menu { info@53: // make dropdown border overlap tab border info@53: margin-top: -1px; info@53: // Remove the top rounded corners here since there is a hard edge above the menu info@53: .border-top-radius(0); info@53: }