hubl/src/styles/components/sidebar.scss
2020-06-18 20:02:54 +02:00

190 lines
3.8 KiB
SCSS

.no-sidebar {
flex: 1;
margin-top: 50px;
@include breakpoint(lg) {
margin-top: 0;
}
&.with-padding {
padding: 1.3rem;
}
}
.with-sidebar {
flex-grow: 1;
display: flex;
flex-direction: row;
align-items: stretch;
margin-top: 50px;
overflow: hidden;
@include breakpoint(lg) {
margin-top: 0;
}
.views-container {
flex: 1 0 0;
/*-webkit-backface-visibility: hidden;*/
&.sidebar-is-closed {
@include breakpoint(lg) {
margin-left: -15.5rem;
transform: translate(15.5rem);
}
}
}
>div {
transition: all 0.5s;
}
nav {
background: var(--color-right-menu-background);
transition: all 0.5s;
width: 25rem;
>solid-router {
color: var(--color-right-menu-text);
flex: 0 0 auto;
font-weight: 600;
>ul {
cursor: pointer;
display: flex;
flex-direction: column;
list-style: none;
margin: 0;
padding-left: 0;
li {
align-items: center;
border-bottom: 1px solid var(--color-right-menu-link-border);
display: flex;
margin: 0;
padding: 2.15rem 2.55rem;
position: relative;
/*width: 12em;*/
&::before {
float: left;
font-size: 4rem;
margin-left: 0;
margin-right: 2.85rem;
}
}
>li {
@include icon('arrow-right-circle');
}
>solid-route {
&[name*='circle'],
&[name*='project'] {
>li::before {
font-size: 4rem;
}
}
&[name*='users'] {
>li::before {
font-size: 5rem;
}
}
&[name$='chat']>li {
@include ci('chat');
}
&[name$='create']>li {
@include ci('offer');
}
&[name$='edit']>li {
@include ci('list');
}
&[name$='profile']>li, &[name$='information']>li {
@include ci('information');
}
&[name$='drive']>li {
@include ci('file');
}
&[name='admin-users']>li::before {
background-color: var(--color-secondary);
content: '';
display: inline-block;
height: 40px;
mask: url('/images/add-user.svg') 1% 1% / 1px 1px no-repeat;
mask-size: cover;
-webkit-mask: url('/images/add-user.svg') 1% 1% / 1px 1px no-repeat;
-webkit-mask-size: cover;
width: 40px;
}
&[name='admin-circles']>li {
@include ci('bubble-add');
}
&[name='admin-projects']>li {
@include ci('add');
}
&[active] {
background-color: var(--color-right-menu-active-background);
color: var(--color-right-menu-active-text);
display: inline-block;
}
&.active-color[active] {
>li::before {
background-color: var(--color-right-menu-active-icon);
}
}
}
}
}
&.jsRightMenu {
display: none;
@include breakpoint(lg) {
display: block;
}
}
&.jsRightMenu:not([open]) {
transform: translate(15.5rem);
& .jsOffsiteToggle::before {
transform: rotate(180deg);
}
}
&.jsRightMenu[open] {
@include breakpoint(md) {
display: block;
background: var(--color-right-menu-background);
bottom: 0;
box-shadow: 0 2px 9px 0 rgba(0, 0, 0, 0.12);
min-width: 60%;
position: fixed;
right: 0;
top: 50px;
z-index: 1;
}
@include breakpoint(lg) {
top: 83px;
}
}
}
}