scinote-web/app/assets/stylesheets/partials/_sidebar.scss
2020-02-07 11:33:25 +01:00

128 lines
2.2 KiB
SCSS

/*!
* Start Bootstrap - Simple Sidebar HTML Template (http://startbootstrap.com)
* Code licensed under the Apache License v2.0.
* For details, see http://www.apache.org/licenses/LICENSE-2.0.
*/
@import "constants";
@import "mixins";
:root {
--wrapper-width: 280px;
}
@mixin sidebar-shown {
// This rule is always overriden (show()) in JS
// after document is loaded
display: none;
padding-left: var(--wrapper-width);
padding-right: 0;
transition: .4s $timing-function-sharp;
#sidebar-arrow {
background-color: $color-concrete;
border-bottom-right-radius: 10px;
border-top-right-radius: 10px;
bottom: 50%;
display: block;
position: absolute;
right: -18px;
span {
padding: 9px 5px;
}
}
#sidebar-arrow:hover {
background-color: $color-concrete;
cursor: pointer;
}
#sidebar-arrow > span {
transform: rotateY(0deg);
transition: .6s; }
#sidebar-arrow[data-shown] > span {
padding-left: 7px;
padding-right: 3px;
transform: rotateY(180deg);
transition: .6s;
}
#sidebar-wrapper {
background-color: $color-concrete;
height: 100%;
left: 83px;
position: fixed;
transition: .4s $timing-function-sharp;
width: var(--wrapper-width);
z-index: 999;
#slide-panel {
height: 100%;
overflow: hidden;
.disabled {
opacity: 1;
}
.fa-caret-right {
padding: 3px 5px;
}
.tree {
margin-bottom: 0;
opacity: 1;
overflow-y: auto;
padding: 20px 0;
position: absolute;
right: 0;
width: var(--wrapper-width);
}
}
}
}
@mixin sidebar-hidden {
padding-left: 0;
#sidebar-wrapper {
left: calc(83px - var(--wrapper-width));
#slide-panel {
.tree {
@include transition(opacity .5s ease);
}
}
}
}
.my-module-group-element::before {
border-left: 1px dotted $color-emperor;
bottom: 20px;
content: "";
left: 34px;
position: absolute;
top: 25px;
}
#wrapper {
@include sidebar-shown;
}
#wrapper.no-animation * {
@include no-animation;
}
#wrapper.toggled {
@include sidebar-hidden;
}
#wrapper.hidden2 {
@include sidebar-hidden;
}
.sidebar-no-module-group {
color: $color-silver-chalice;
}