Chamilo is a learning management system focused on ease of use and accessibility
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.
 
 
 
 
 
 
chamilo-lms/assets/css/scss/_sidebar.scss

466 lines
8.7 KiB

// ---------------------------------------------------------
// SIDEBAR SCSS
// ---------------------------------------------------------
.sidebar {
background-color: $default-white;
bottom: 0;
overflow: hidden;
position: fixed;
top: 0;
transition: all 0.2s ease;
width: $offscreen-size;
z-index: 1000;
ul {
list-style-type: none;
}
@include between($breakpoint-md, $breakpoint-xl) {
width: $collapsed-size;
.sidebar-inner {
.sidebar-logo {
border-bottom: 1px solid transparent;
padding: 0;
a {
.logo {
background-position: center center;
width: $collapsed-size;
}
}
}
.sidebar-menu {
overflow-x: hidden;
> li {
> a {
.title {
display: none;
}
}
}
li {
&.dropdown {
.arrow {
opacity: 0;
}
&.open {
ul.dropdown-menu {
display: none !important;
}
}
}
}
}
}
&:hover {
width: $offscreen-size;
.sidebar-inner {
.sidebar-logo {
border-bottom: 1px solid $border-color;
padding: 0 20px;
}
.sidebar-menu {
> li {
> a {
.title {
display: inline-block;
}
}
}
li {
&.dropdown {
.arrow {
opacity: 1;
}
}
&.open {
> ul.dropdown-menu {
display: block !important;
}
}
}
}
}
}
}
@include to($breakpoint-md) {
left: -$offscreen-size;
width: calc(#{$offscreen-size} - 30px);
}
}
// ---------------------------------------------------------
// SIDEBAR INNER
// ---------------------------------------------------------
.sidebar-inner {
position: relative;
height: 100%;
}
// ---------------------------------------------------------
// SIDEBAR LOGO
// ---------------------------------------------------------
.sidebar-logo {
border-bottom: 1px solid $border-color;
border-right: 1px solid $border-color;
line-height: 0;
padding: 0 20px;
transition: all 0.2s ease;
a {
display: inline-block;
width: 100%;
.logo {
background: no-repeat center left;
display: inline-block;
min-height: calc(#{$header-height} - 1px);
width: 100%;
}
.logo-text {
color: $grey-900;
}
}
.mobile-toggle {
display: none;
float: right;
font-size: 18px;
line-height: calc(#{$header-height} - 1px);
a {
color: $default-text-color;
}
@include to($breakpoint-md) {
display: inline-block;
}
@include between($breakpoint-md, $breakpoint-xl) {
display: none;
}
}
}
// ---------------------------------------------------------
// SIDEBAR MENU
// ---------------------------------------------------------
.sidebar-menu {
@include clearfix;
border-right: 1px solid $border-color;
height: calc(100vh - #{$header-height});
list-style: none;
margin: 0;
overflow: auto;
padding: 0;
position: relative;
background: linear-gradient(180deg, #0181bf, #00bcda);
.nav-header {
margin-top: 10px;
margin-bottom: 10px;
padding-left: 10px;
padding-right: 10px;
font-size: 12px;
color: $default-white;
}
.sidebar-divider {
height: 0;
margin: .5rem 0;
overflow: hidden;
border-top: 1px solid #217aa4;
border-bottom: 1px solid #16b1fd;
}
.dropdown-toggle::after {
display: none;
}
.sidebar-link {
&.active::before {
background: $default-warning;
content: '';
display: block;
height: 100%;
left: -4px;
position: absolute;
top: 0;
width: 8px;
}
}
li {
position: relative;
&.dropdown {
.arrow {
font-size: 10px;
line-height: 40px;
position: absolute;
right: 30px;
transition: all 0.05s ease-in;
@include to($breakpoint-md) {
right: 25px;
}
}
&.open {
> a {
color: $default-white;
&.dropdown-toggle {
background: $default-active;
}
.icon-holder {
color: $default-info;
}
> .arrow {
transform: rotate(90deg);
}
}
> .dropdown-menu {
display: block;
.dropdown-menu {
padding-left: 20px;
}
.arrow {
line-height: 25px;
}
}
}
}
a {
color: $default-white;
transition: all 0.3s ease;
display: block;
font-size: 14px;
font-weight: normal;
padding: 5px 15px;
position: relative;
white-space: nowrap;
i {
border-radius: 6px;
display: inline-block;
font-size: 17px;
height: 35px;
left: 0;
line-height: 35px;
margin-right: 14px;
position: relative;
text-align: center;
transition: all 0.3s ease;
width: 40px;
}
&.active {
background: $default-active;
}
&:hover,
&:focus {
color: $default-info;
text-decoration: none;
background: $default-active;
.icon-holder {
color: $default-info;
}
}
}
}
> li {
&.dropdown {
ul {
&.dropdown-menu {
background-color: #0099ca;
border-radius: 0;
border: 0;
box-shadow: none;
float: none;
padding-left: 10px;
padding-top: 0;
position: relative;
width: 100%;
> li {
> a {
display: block;
padding: 10px 15px;
&:hover,
&:focus {
background-color: transparent;
color: $default-dark;
}
}
&.active {
a {
color: $default-dark;
}
}
}
}
}
}
}
}
// ---------------------------------------------------------
// SIDEBAR COLLAPSED
// ---------------------------------------------------------
.is-collapsed {
.sidebar {
@include from($breakpoint-xl) {
width: $collapsed-size;
.sidebar-inner {
.sidebar-logo {
border-bottom: 1px solid transparent;
padding: 0;
}
.sidebar-menu {
overflow-x: hidden;
> li {
&.nav-header {
display: none;
}
> a {
.title {
display: none;
}
}
}
li {
&.dropdown {
.arrow {
opacity: 0;
}
&.open {
ul.dropdown-menu {
display: none !important;
}
}
}
}
}
}
&:hover {
width: $offscreen-size;
.sidebar-inner {
.sidebar-logo {
border-bottom: 1px solid $border-color;
padding: 0 20px;
}
.sidebar-menu {
> li {
&.nav-header {
display: inline-block;
}
> a {
.title {
display: inline-block;
}
}
}
li {
&.dropdown {
.arrow {
opacity: 1;
}
}
&.open {
> ul.dropdown-menu {
display: block !important;
}
}
}
}
}
}
}
@include between($breakpoint-md, $breakpoint-xl) {
width: $offscreen-size;
.sidebar-inner {
.sidebar-logo {
border-bottom: 1px solid $border-color;
padding: 0 20px;
> a {
.logo {
background-position: center left;
width: 150px;
}
}
}
.sidebar-menu {
> li {
> a {
.title {
display: inline-block;
}
}
}
li {
&.dropdown {
.arrow {
opacity: 1;
}
}
&.open {
> ul.dropdown-menu {
display: block !important;
}
}
}
}
}
}
@include to($breakpoint-md) {
left: 0;
}
}
}