2014-12-02 22:02:35 +00:00
|
|
|
//
|
|
|
|
// Navbars
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
// Wrapper and base class
|
|
|
|
//
|
|
|
|
// Provide a static navbar from which we expand to create full-width, fixed, and
|
|
|
|
// other navbar variations.
|
|
|
|
|
|
|
|
.navbar {
|
|
|
|
position: relative;
|
|
|
|
padding: $spacer;
|
|
|
|
margin-bottom: $navbar-margin-bottom;
|
2014-12-11 22:47:10 +00:00
|
|
|
@include clearfix;
|
2014-12-02 22:02:35 +00:00
|
|
|
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
@include border-radius($navbar-border-radius);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//
|
|
|
|
// Navbar alignment options
|
|
|
|
//
|
|
|
|
// Display the navbar across the entirety of the page or fixed it to the top or
|
|
|
|
// bottom of the page.
|
|
|
|
|
|
|
|
// Static top (unfixed, but 100% wide) navbar
|
|
|
|
.navbar-static-top {
|
|
|
|
z-index: $zindex-navbar;
|
|
|
|
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
@include border-radius(0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Fix the top/bottom navbars when screen real estate supports it
|
|
|
|
.navbar-fixed-top,
|
|
|
|
.navbar-fixed-bottom {
|
|
|
|
position: fixed;
|
|
|
|
right: 0;
|
|
|
|
left: 0;
|
|
|
|
z-index: $zindex-navbar-fixed;
|
2014-12-11 22:47:10 +00:00
|
|
|
margin-bottom: 0; // override .navbar defaults
|
2014-12-02 22:02:35 +00:00
|
|
|
|
|
|
|
// Undo the rounded corners
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
@include border-radius(0);
|
|
|
|
}
|
|
|
|
}
|
2014-12-11 22:47:10 +00:00
|
|
|
|
2014-12-02 22:02:35 +00:00
|
|
|
.navbar-fixed-top {
|
|
|
|
top: 0;
|
|
|
|
}
|
2014-12-11 22:47:10 +00:00
|
|
|
|
2014-12-02 22:02:35 +00:00
|
|
|
.navbar-fixed-bottom {
|
|
|
|
bottom: 0;
|
|
|
|
}
|
|
|
|
|
2015-04-14 02:00:59 +00:00
|
|
|
.navbar-sticky-top {
|
|
|
|
position: sticky;
|
|
|
|
top: 0;
|
|
|
|
width: 100%;
|
|
|
|
z-index: $zindex-navbar-sticky;
|
|
|
|
|
|
|
|
// Undo the rounded corners
|
|
|
|
@include media-breakpoint-up(sm) {
|
|
|
|
@include border-radius(0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-12-02 22:02:35 +00:00
|
|
|
|
|
|
|
// Brand/project name
|
|
|
|
|
|
|
|
.navbar-brand {
|
|
|
|
float: left;
|
2014-12-04 22:18:13 +00:00
|
|
|
padding: .725rem .75rem;
|
2014-12-02 22:02:35 +00:00
|
|
|
margin-right: $spacer;
|
|
|
|
margin-bottom: 0; // For headings
|
|
|
|
font-size: $font-size-lg;
|
|
|
|
line-height: $line-height-computed;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
> a {
|
|
|
|
@include hover-focus {
|
|
|
|
text-decoration: none;
|
|
|
|
}
|
2014-12-02 22:02:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
> img {
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Navbar toggle
|
|
|
|
//
|
|
|
|
// Custom button for toggling the `.navbar-collapse`, powered by the collapse
|
|
|
|
// JavaScript plugin.
|
|
|
|
|
|
|
|
.navbar-toggler {
|
|
|
|
padding: .55rem .75rem;
|
|
|
|
margin-right: $spacer;
|
|
|
|
margin-bottom: 0; // For headings
|
|
|
|
font-size: $font-size-lg;
|
|
|
|
line-height: $line-height-computed;
|
|
|
|
background: none;
|
|
|
|
border: 0;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
text-decoration: none;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-04-17 01:50:32 +00:00
|
|
|
// Custom override for
|
|
|
|
.navbar-toggleable {
|
|
|
|
&-xs {
|
|
|
|
@include media-breakpoint-up(sm) {
|
|
|
|
display: block !important;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
&-sm {
|
|
|
|
@include media-breakpoint-up(md) {
|
|
|
|
display: block !important;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-12-02 22:02:35 +00:00
|
|
|
|
|
|
|
// Navbar form
|
|
|
|
//
|
|
|
|
// Extension of the `.form-inline` with some extra flavor for optimum display in
|
|
|
|
// our navbars.
|
|
|
|
|
|
|
|
.navbar-form {
|
|
|
|
padding: 10px $navbar-padding-horizontal;
|
2014-12-11 20:05:29 +00:00
|
|
|
margin-right: -$navbar-padding-horizontal;
|
|
|
|
margin-left: -$navbar-padding-horizontal;
|
2014-12-02 22:02:35 +00:00
|
|
|
border-top: 1px solid transparent;
|
|
|
|
border-bottom: 1px solid transparent;
|
|
|
|
@include box-shadow(inset 0 1px 0 rgba(255,255,255,.1), 0 1px 0 rgba(255,255,255,.1));
|
|
|
|
|
|
|
|
// Mixin behavior for optimum display
|
|
|
|
@extend .form-inline;
|
|
|
|
|
|
|
|
.form-group {
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
margin-bottom: 5px;
|
|
|
|
|
|
|
|
&:last-child {
|
|
|
|
margin-bottom: 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Vertically center in expanded, horizontal navbar
|
|
|
|
// @include navbar-vertical-align($input-height-base);
|
|
|
|
|
|
|
|
// Undo 100% width for pull classes
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
width: auto;
|
|
|
|
padding-top: 0;
|
|
|
|
padding-bottom: 0;
|
2014-12-11 20:05:29 +00:00
|
|
|
margin-right: 0;
|
|
|
|
margin-left: 0;
|
|
|
|
border: 0;
|
2014-12-02 22:02:35 +00:00
|
|
|
@include box-shadow(none);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Dropdown menus
|
|
|
|
|
|
|
|
// Menu position and menu carets
|
|
|
|
.navbar-nav > li > .dropdown-menu {
|
|
|
|
margin-top: 0;
|
|
|
|
@include border-top-radius(0);
|
|
|
|
}
|
|
|
|
// Menu position and menu caret support for dropups via extra dropup class
|
|
|
|
.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu {
|
|
|
|
@include border-top-radius($navbar-border-radius);
|
|
|
|
@include border-bottom-radius(0);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Buttons in navbars
|
|
|
|
//
|
|
|
|
// Vertically center a button within a navbar (when *not* in a form).
|
|
|
|
|
|
|
|
// .navbar-btn {
|
|
|
|
// @include navbar-vertical-align($input-height-base);
|
|
|
|
|
|
|
|
// &.btn-sm {
|
|
|
|
// @include navbar-vertical-align($input-height-sm);
|
|
|
|
// }
|
|
|
|
// &.btn-xs {
|
|
|
|
// @include navbar-vertical-align(22);
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
// Text in navbars
|
|
|
|
//
|
|
|
|
// Add a class to make any element properly align itself vertically within the navbars.
|
|
|
|
|
|
|
|
.navbar-text {
|
|
|
|
// @include navbar-vertical-align($line-height-computed);
|
|
|
|
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
float: left;
|
|
|
|
margin-right: $navbar-padding-horizontal;
|
2014-12-11 20:05:29 +00:00
|
|
|
margin-left: $navbar-padding-horizontal;
|
2014-12-02 22:02:35 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Component alignment
|
|
|
|
//
|
|
|
|
// Repurpose the pull utilities as their own navbar utilities to avoid specificity
|
|
|
|
// issues with parents and chaining. Only do this when the navbar is uncollapsed
|
|
|
|
// though so that navbar contents properly stack and align in mobile.
|
|
|
|
//
|
|
|
|
// Declared after the navbar components to ensure more specificity on the margins.
|
|
|
|
|
2014-12-29 21:40:19 +00:00
|
|
|
@include media-breakpoint-up(sm) {
|
2014-12-02 22:02:35 +00:00
|
|
|
.navbar-left {
|
2014-12-16 20:29:47 +00:00
|
|
|
@include pull-left();
|
2014-12-02 22:02:35 +00:00
|
|
|
}
|
|
|
|
.navbar-right {
|
2014-12-16 20:29:47 +00:00
|
|
|
@include pull-right();
|
2014-12-02 22:02:35 +00:00
|
|
|
margin-right: -$navbar-padding-horizontal;
|
|
|
|
|
|
|
|
~ .navbar-right {
|
|
|
|
margin-right: 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Alternate navbars
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
// Default navbar
|
|
|
|
.navbar-default {
|
|
|
|
background-color: $navbar-default-bg;
|
|
|
|
border-color: $navbar-default-border;
|
|
|
|
|
|
|
|
.navbar-brand {
|
|
|
|
color: $navbar-default-brand-color;
|
2014-12-20 02:35:10 +00:00
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-brand-hover-color;
|
|
|
|
background-color: $navbar-default-brand-hover-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-text {
|
|
|
|
color: $navbar-default-color;
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-nav {
|
|
|
|
> li > a {
|
|
|
|
color: $navbar-default-link-color;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-hover-color;
|
|
|
|
background-color: $navbar-default-link-hover-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
> .active > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-active-color;
|
|
|
|
background-color: $navbar-default-link-active-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
> .disabled > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-disabled-color;
|
|
|
|
background-color: $navbar-default-link-disabled-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-toggle {
|
|
|
|
border-color: $navbar-default-toggle-border-color;
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
background-color: $navbar-default-toggle-hover-bg;
|
|
|
|
}
|
|
|
|
.icon-bar {
|
|
|
|
background-color: $navbar-default-toggle-icon-bar-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-collapse,
|
|
|
|
.navbar-form {
|
|
|
|
border-color: $navbar-default-border;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Dropdown menu items
|
|
|
|
.navbar-nav {
|
|
|
|
// Remove background color from open dropdown
|
|
|
|
> .open > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-active-color;
|
2014-12-11 20:05:29 +00:00
|
|
|
background-color: $navbar-default-link-active-bg;
|
2014-12-02 22:02:35 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Links in navbars
|
|
|
|
//
|
|
|
|
// Add a class to ensure links outside the navbar nav are colored correctly.
|
|
|
|
|
|
|
|
.navbar-link {
|
|
|
|
color: $navbar-default-link-color;
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-hover-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.btn-link {
|
|
|
|
color: $navbar-default-link-color;
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-hover-color;
|
|
|
|
}
|
2014-12-22 21:33:58 +00:00
|
|
|
&:disabled,
|
2014-12-02 22:02:35 +00:00
|
|
|
fieldset[disabled] & {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-default-link-disabled-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Inverse navbar
|
|
|
|
|
|
|
|
.navbar-inverse {
|
|
|
|
background-color: $navbar-inverse-bg;
|
|
|
|
border-color: $navbar-inverse-border;
|
|
|
|
|
|
|
|
.navbar-toggler,
|
|
|
|
.navbar-brand > a,
|
|
|
|
.nav-pills > .nav-item > .nav-link {
|
|
|
|
color: $navbar-inverse-link-color;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-hover-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
.nav-pills > .nav-item > .nav-link {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-active-color;
|
|
|
|
background-color: $navbar-inverse-link-active-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
.nav-pills > .active > .nav-link,
|
|
|
|
.nav-pills > .nav-link.active {
|
|
|
|
color: $navbar-inverse-link-active-color;
|
|
|
|
background-color: $navbar-inverse-link-active-bg;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.navbar-brand {
|
|
|
|
color: $navbar-inverse-brand-color;
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-brand-hover-color;
|
|
|
|
background-color: $navbar-inverse-brand-hover-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-text {
|
|
|
|
color: $navbar-inverse-color;
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-nav {
|
|
|
|
> li > a {
|
|
|
|
color: $navbar-inverse-link-color;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-hover-color;
|
|
|
|
background-color: $navbar-inverse-link-hover-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
> .active > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-active-color;
|
|
|
|
background-color: $navbar-inverse-link-active-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
> .disabled > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-disabled-color;
|
|
|
|
background-color: $navbar-inverse-link-disabled-bg;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-collapse,
|
|
|
|
.navbar-form {
|
|
|
|
border-color: darken($navbar-inverse-bg, 7%);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Dropdowns
|
|
|
|
.navbar-nav {
|
|
|
|
> .open > a {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include plain-hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-active-color;
|
2014-12-11 20:05:29 +00:00
|
|
|
background-color: $navbar-inverse-link-active-bg;
|
2014-12-02 22:02:35 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.navbar-link {
|
|
|
|
color: $navbar-inverse-link-color;
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-hover-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.btn-link {
|
|
|
|
color: $navbar-inverse-link-color;
|
|
|
|
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-hover-color;
|
|
|
|
}
|
|
|
|
|
2014-12-22 21:33:58 +00:00
|
|
|
&:disabled,
|
2014-12-02 22:02:35 +00:00
|
|
|
fieldset[disabled] & {
|
2015-01-01 09:05:01 +00:00
|
|
|
@include hover-focus {
|
2014-12-02 22:02:35 +00:00
|
|
|
color: $navbar-inverse-link-disabled-color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|