You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
AdminLTE/build/scss/_main-sidebar.scss

197 lines
3.0 KiB

7 years ago
/**
* Component: Main Sidebar
* -----------------------
7 years ago
*/
.main-sidebar {
height: 100vh;
overflow-y: hidden;
z-index: $zindex-main-sidebar;
7 years ago
}
.sidebar {
height: calc(100% - 4rem);
overflow-y: auto;
7 years ago
padding-bottom: $sidebar-padding-y;
padding-left: $sidebar-padding-x;
padding-right: $sidebar-padding-x;
padding-top: $sidebar-padding-y;
7 years ago
}
// Sidebar user panel
.user-panel {
position: relative;
[class*='sidebar-dark'] & {
7 years ago
border-bottom: 1px solid lighten($dark, 12%);
}
[class*='sidebar-light'] & {
7 years ago
border-bottom: 1px solid $gray-300;
}
&,
.info {
overflow: hidden;
white-space: nowrap;
}
.image {
display: inline-block;
padding-left: $nav-link-padding-x - .2;
7 years ago
}
img {
height: auto;
width: $sidebar-user-image-width;
7 years ago
}
.info {
display: inline-block;
padding: 5px 5px 5px 10px;
}
.status,
.dropdown-menu {
font-size: $font-size-sm;
}
}
// Sidebar navigation menu
.nav-sidebar {
// All levels
.nav-item {
> .nav-link {
margin-bottom: 0.2rem;
7 years ago
.right {
@include transition(transform $transition-fn $transition-speed);
}
}
}
.nav-link > p > .right {
position: absolute;
right: 1rem;
top: 12px;
&:nth-child(2) {
right: 2.5rem;
}
7 years ago
}
.menu-open {
> .nav-treeview {
display: block;
}
> .nav-link {
i.right {
7 years ago
@include rotate(-90deg);
}
}
}
// First Level
> .nav-item {
margin-bottom: 0;
.nav-icon {
text-align: center;
width: $sidebar-nav-icon-width;
font-size: 1.2rem;
margin-right: .2rem;
&.fa,
&.fas,
&.far,
&.fab,
&.glyphicon,
&.ion {
font-size: 1.1rem;
}
7 years ago
}
.float-right {
margin-top: 3px;
}
}
// Tree view menu
.nav-treeview {
display: none;
list-style: none;
padding: 0;
> .nav-item {
> .nav-link {
> .nav-icon {
width: $sidebar-nav-icon-width;
}
}
}
}
&.nav-child-indent { 
.nav-treeview{
padding-left: 1rem;
}
}
7 years ago
.nav-header {
font-size: .9rem;
padding: $nav-link-padding-y;
&:not(:first-of-type) {
padding: 1.7rem 1rem .5rem 1rem;
}
}
.nav-link p {
display: inline-block;
margin: 0;
}
}
#sidebar-overlay {
background-color: rgba($black, 0.1);
7 years ago
bottom: 0;
display: none;
left: 0;
position: fixed;
right: 0;
top: 0;
7 years ago
z-index: $zindex-main-sidebar - 1;
@include media-breakpoint-down(md) {
.sidebar-open & {
display: block;
}
}
}
.sidebar-mini-md.sidebar-open {
#sidebar-overlay {
@include media-breakpoint-up(sm) {
display: none;
}
@include media-breakpoint-down(sm) {
display: block;
}
}
}
7 years ago
// Sidebar variants
@each $name, $color in $theme-colors {
.sidebar-dark-#{$name} {
@include skin-dark-sidebar($color)
}
.sidebar-light-#{$name} {
@include skin-light-sidebar($color)
}
}