dokuwiki-template-sprintdoc.../css/area_main-sidebar-nav.less
2017-04-10 13:11:39 +02:00

301 lines
6.6 KiB
Text
Executable file

/**
* This file provides the design styles the navigational elements in the sidebar
*
* @author Jana Deutschlaender <deutschlaender@cosmocode.de>
* @author Andreas Gohr <gohr@cosmocode.de>
*/
#dokuwiki__aside {
@icon-size: @font-size-big;
@menu-margin: @icon-size + @margin-small*2; // FIXME this is still wrong
nav > p,
.mmissuelist li,
.mmissuelist div {
color: @ini_nav_menu_color;
&.noissue {
color: @ini_text_webframe;
* {
color: inherit;
}
}
}
nav {
li {
color: @ini_nav_menu_color;
> div {
color: @ini_text_webframe;
}
}
}
/* jira itemlist */
.mmissuelist {
li {
&.noissue {
list-style-type: none;
margin-left: 0;
}
a {
display: inline-block;
}
}
img {
vertical-align: bottom;
margin-right: .3rem;
}
.mm__status {
padding-left: .3rem;
padding-right: .3rem;
}
form {
vertical-align: text-top;
}
}
> * {
margin-left: @menu-margin; // moves *all* sidebar content to the right
}
a {
&:link,
&:visited {
opacity: .9;
color: @ini_nav_menu_color;
}
* {
color: inherit;
}
}
// the toggle element
a.nav {
.display-flex();
.align-items();
cursor: pointer;
height: @icon-size + @margin-small;
opacity: 1;
border: 1px solid transparent;
border-radius: @fix_border-radius;
color: @ini_nav_menu_color;
font-size: @font-size-head6;
font-weight: normal;
margin: -1px 0 (@font-size-head6 / 2) (@menu-margin * -1); // moves the toggles back to the left
transition: @transition color, @transition background-color, @transition border-color;
span {
display: inline-block;
vertical-align: middle;
color: inherit;
}
span.lbl {
flex-grow: 1;
}
span.ico {
width: @menu-margin;
height: @icon-size;
flex-grow: 0;
border-right: 1px solid @ini_nav_menu_color;
text-align: center;
margin-right: 4%;
color: inherit;
// simple fake icon
strong {
display: inline-block;
font-size: @icon-size * 0.5;
width: @icon-size * 0.9;
height: @icon-size * 0.9;
line-height: @icon-size * 0.9;
margin: @icon-size * 0.05;
vertical-align: baseline;
text-align: center;
color: inherit;
border: 2px solid @ini_nav_menu_color;
border-top-right-radius: 50%;
border-bottom-left-radius: 50%;
transition: @transition border-color;
}
// real icon
svg {
width: @icon-size;
height: @icon-size;
path {
fill: @ini_nav_menu_color;
transition: @transition all;
}
}
}
&:hover,
&:focus,
&:active {
background-color: @ini_nav_menu_hover_bg;
border-color: @ini_nav_menu_hover_color;
color: @ini_nav_menu_hover_color;
text-decoration: none;
span.ico {
border-color: inherit;
strong {
border-color: inherit;
}
svg {
path {
fill: @ini_nav_menu_hover_color;
}
}
}
}
}
// the panel (hidden by default)
div.nav-panel {
display: none;
margin-top: .5rem;
ul {
margin-bottom: 1rem;
ul {
margin-bottom: 0;
}
}
}
}
/* + + + + + + wide page content border-bottom between a.nav (short width) + + + + +
.wide-content {
#dokuwiki__aside {
a.nav {
position: relative;
&::after {
content: '';
position: absolute;
bottom: -1px;
left: 0;
width: 100%;
height: 1px;
border-bottom: solid 1px @ini_border;
}
&:hover,
&:focus,
&:active {
&::after {
display: none;
}
}
}
}
} */
/* + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* min-width: 1440px */
@media @screen_min-xlg {
#dokuwiki__aside {
nav {
li:not([class]),
.li {
font-size: @font-size-head6;
padding: .15em 0;
* {
font-size: inherit;
font-weight: inherit;
}
a {
font-size: (@font-size-head6 - .05);
}
}
}
}
}
/* + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* max-width: 1023px */
@media @screen_max-md {
// show when toggled
body.show-mobile-sidebar {
.search.main-sidebar {
display: block !important;
position: relative;
form {
margin-bottom: 1rem;
.no {
display: block;
}
}
}
#dokuwiki__aside {
> nav {
position: relative;
z-index: 2;
&:first-child {
margin-top: 1.2rem;
}
}
a.nav {
border-radius: 0;
border-right-width: 0;
border-left-width: 0;
}
.nav-panel,
a.nav {
padding-right: .8em;
}
}
}
}
/* + + + + + + + + + + + + + + + + + + + + + + + + + + */
/* max-width: 1439px */
@media @screen_max-xlg {
#dokuwiki__aside {
nav {
li:not([class]),
.li {
font-size: @font-size-default;
padding: .15em 0 .15em .25rem;
* {
font-size: inherit;
font-weight: inherit;
}
}
}
}
}