mirror of
https://github.com/vale981/Vulcan
synced 2025-03-10 12:36:39 -04:00
109 lines
1.7 KiB
SCSS
109 lines
1.7 KiB
SCSS
![]() |
|
||
|
.menu-dropdown{
|
||
|
|
||
|
// menu
|
||
|
|
||
|
text-align: left;
|
||
|
position:relative;
|
||
|
|
||
|
// indicator for menu with items
|
||
|
|
||
|
&.menu-has-items{
|
||
|
.menu-label-wrapper{
|
||
|
cursor: pointer;
|
||
|
.menu-label{
|
||
|
font-weight: normal;
|
||
|
}
|
||
|
&:after{
|
||
|
display:inline-block;
|
||
|
position:relative;
|
||
|
top:-1px;
|
||
|
margin-left:4px;
|
||
|
content:"▼";
|
||
|
font-size:8px;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
// hover state
|
||
|
|
||
|
&:hover{
|
||
|
|
||
|
// show menu items
|
||
|
.menu-items{
|
||
|
display:block;
|
||
|
}
|
||
|
|
||
|
// add special pseudo-element to preserve hover continuity between menu label and menu items
|
||
|
.menu-label{
|
||
|
&:after{
|
||
|
content: " ";
|
||
|
display: block;
|
||
|
position: absolute;
|
||
|
top: 10px;
|
||
|
width: 100%;
|
||
|
height: 20px;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
// dropdown style
|
||
|
|
||
|
.menu-items, .menu-child-items{
|
||
|
display:none; // hidden until user hovers
|
||
|
top:30px;
|
||
|
left:0px;
|
||
|
position:absolute;
|
||
|
z-index: 10000;
|
||
|
background:white;
|
||
|
min-width:180px;
|
||
|
border-radius: 3px;
|
||
|
box-shadow: 0 1px 3px black(0.35);
|
||
|
list-style-type: none;
|
||
|
padding: 5px 0;
|
||
|
}
|
||
|
|
||
|
// menu item
|
||
|
|
||
|
.menu-item{
|
||
|
position: relative;
|
||
|
margin-bottom: 0px;
|
||
|
padding: 5px 10px;
|
||
|
|
||
|
// hover
|
||
|
|
||
|
&:hover{
|
||
|
background: black(0.05);
|
||
|
&>.menu-child-items{
|
||
|
display: block;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
// indicator for menu items with children
|
||
|
|
||
|
&.menu-item-has-children{
|
||
|
.menu-items-toggle{
|
||
|
display: block;
|
||
|
}
|
||
|
.menu-icon-collapse{
|
||
|
display: none;
|
||
|
}
|
||
|
.menu-icon-expand{
|
||
|
position: relative;
|
||
|
right: -5px;
|
||
|
opacity: 0.5;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
.menu-item-label{
|
||
|
display: block;
|
||
|
width: 100%;
|
||
|
}
|
||
|
.menu-child-items{
|
||
|
top: -5px;
|
||
|
left: 100%;
|
||
|
}
|
||
|
|
||
|
}
|