lbry-desktop/src/ui/scss/component/_navigation.scss
2019-03-28 12:53:13 -04:00

158 lines
2.9 KiB
SCSS

.navigation {
background-color: $lbry-white;
border-right: 1px solid rgba($lbry-gray-1, 0.9);
font-size: 1.25rem;
padding-top: var(--spacing-vertical-large);
padding-right: var(--spacing-vertical-small);
position: relative;
html[data-mode='dark'] & {
background-color: $lbry-black;
border-right: 1px solid $lbry-black;
}
// The navigation does not need to be visible
// on smaller screen widths
@media (min-width: 601px) {
min-width: 171px; // 1px is for the border
}
@media (max-width: 600px) {
display: none;
}
&::before {
top: 0;
left: 0;
bottom: 0;
right: 0;
// TODO: Make this gradient "to bottom" on mobile view
background-image: linear-gradient(
to right,
transparent,
rgba(mix($lbry-blue-3, $lbry-gray-4, 15%), 0.2) 100%
);
content: '';
position: absolute;
z-index: 0;
html[data-mode='dark'] & {
background-image: linear-gradient(
to bottom right,
transparent,
rgba(mix($lbry-blue-3, $lbry-gray-4, 15%), 0.2) 100%
);
}
}
}
.navigation__links {
position: relative;
}
.navigation__links--bottom {
position: absolute;
bottom: var(--spacing-vertical-large);
}
.navigation__link {
display: block;
line-height: 1.75;
padding-left: var(--spacing-vertical-large);
position: relative;
text-align: left;
transition: color 0.2s;
white-space: nowrap;
width: 100%;
color: $lbry-gray-5;
&::before {
top: 0;
left: 0;
width: 0;
background-color: $lbry-teal-3;
content: '';
height: 100%;
position: absolute;
transition: width 0.2s;
}
&:not(.navigation__link--title):hover,
&.navigation__link--active {
color: $lbry-black;
html[data-mode='dark'] & {
color: $lbry-gray-1;
}
&::before {
width: 0.5rem;
}
}
&.navigation__link--guide:not(:hover) {
color: rgba($lbry-black, 0.75);
html[data-mode='dark'] & {
color: rgba($lbry-white, 0.75);
}
&::before {
animation: bounce 1.75s infinite;
}
}
}
.navigation__link--title {
margin-bottom: var(--spacing-vertical-small);
padding-top: var(--spacing-vertical-large);
color: $lbry-gray-5;
cursor: default;
font-size: 1.15rem;
font-weight: 700;
letter-spacing: 0.1rem;
text-transform: uppercase;
}
.navigation__link-items {
font-size: 1.15rem;
padding-left: var(--spacing-vertical-large);
}
.navigation__link-item {
position: relative;
&::before {
width: 0.25rem;
height: 0.25rem;
top: 44%;
left: -1rem;
border-radius: 50%;
content: '';
position: absolute;
transition: background-color 0.2s;
}
&:not(.navigation__link-item--active) {
color: $lbry-gray-5;
&::before {
background-color: transparent;
}
}
&:hover,
.navigation__link-item--active {
&::before {
background-color: $lbry-black;
html[data-mode='dark'] & {
color: $lbry-gray-1;
}
}
}
}