Files
Iris/src/scss/components/_context-menu.scss

156 lines
2.4 KiB
SCSS
Raw Normal View History

2016-10-27 10:02:12 +13:00
.context-menu {
position: fixed;
left: 0;
top: 0;
z-index: 99;
2016-10-27 10:02:12 +13:00
background: $dark_grey;
color: #FFFFFF;
&.right-align {
margin-left: -140px;
}
&.right-align-submenu .submenu {
left: auto !important;
right: 140px !important;
}
&.bottom-align-submenu .submenu {
top: auto !important;
bottom: 0 !important;
}
2017-01-27 16:13:11 +13:00
.title {
cursor: pointer;
display: block;
padding: 8px 12px;
width: 100%;
font-weight: bold;
box-sizing: border-box;
position: relative;
overflow: hidden;
img {
@include blur(5px);
background-size: cover;
background-position: 50% 0%;
opacity: 0.2;
position: absolute;
top: 0;
left: 0;
right: 0;
}
}
.menu-item-wrapper {
2016-10-27 10:02:12 +13:00
display: block;
2016-11-14 11:20:02 +13:00
position: relative;
2016-10-27 10:02:12 +13:00
.menu-item {
cursor: pointer;
display: block;
padding: 8px 12px;
width: 140px;
box-sizing: border-box;
}
.icon {
display: none;
}
.submenu-icon {
2016-11-12 16:36:36 +13:00
font-size: 10px;
float: right;
padding-top: 4px;
}
2016-11-11 23:21:51 +13:00
.submenu {
display: none;
position: absolute;
left: 140px;
2016-11-11 23:21:51 +13:00
top: 0;
2016-11-14 11:20:02 +13:00
max-height: 200px;
2016-11-11 23:21:51 +13:00
overflow-y: scroll;
background: lighten($dark_grey, 5%);
2016-12-13 17:02:23 +13:00
.menu-item {
width: 140px;
2016-11-12 16:36:36 +13:00
&:hover {
background: lighten($dark_grey, 10%);
}
2016-11-11 23:21:51 +13:00
}
2016-10-27 10:02:12 +13:00
}
&.cancel {
float: right;
opacity: 0.5;
}
&:not(:first-child) .menu-item {
border-top: 1px solid lighten($dark_grey, 8%);
}
&:hover {
.menu-item {
background: lighten($dark_grey, 5%);
}
.submenu {
display: block;
}
}
2016-10-27 10:02:12 +13:00
}
2016-12-14 16:41:05 +13:00
&.touch{
bottom: 0 !important;
left: 0 !important;
right: 0 !important;
top: auto !important;
background: $blue;
.menu-item-wrapper {
display: inline-block;
.menu-item {
display: inline-block;
text-align: center;
width: 56px;
height: 56px;
border: 0 !important;
vertical-align: top;
&:hover {
background: inherit;
}
&:active,
&:focus {
background: rgba(255,255,255,0.2);
}
.icon {
padding: 5px;
display: inline-block;
}
.label {
display: block;
font-size: 10px;
}
.submenu-icon {
display: none !important;
}
}
.submenu {
display: none !important;
}
&:not(:first-child) .menu-item {
border-left: 1px solid rgba(255,255,255,0.2) !important;
}
}
}
2016-10-27 10:02:12 +13:00
}