2016-03-23 05:26:27 +00:00
|
|
|
@import '../constants/colors';
|
2016-03-21 05:47:49 +00:00
|
|
|
@import '../constants/dimensions';
|
2016-07-21 21:55:03 +00:00
|
|
|
@import '../constants/fonts';
|
2016-03-21 05:47:49 +00:00
|
|
|
|
|
|
|
.dropdown {
|
|
|
|
position: relative;
|
2016-04-04 07:15:30 +00:00
|
|
|
display: inline-block;
|
2016-11-11 22:01:21 +00:00
|
|
|
box-sizing: border-box;
|
2016-11-25 19:01:41 +00:00
|
|
|
text-align: left;
|
2016-03-21 05:47:49 +00:00
|
|
|
|
2016-07-06 20:18:26 +00:00
|
|
|
&:focus {
|
|
|
|
outline: none;
|
|
|
|
}
|
|
|
|
|
2017-06-16 17:44:11 +00:00
|
|
|
}
|
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
.dropdown__backdrop {
|
2017-06-16 17:44:11 +00:00
|
|
|
position: fixed;
|
2017-06-16 22:21:41 +00:00
|
|
|
z-index: 999;
|
|
|
|
display: none;
|
2017-06-16 17:44:11 +00:00
|
|
|
left: 0;
|
2017-06-16 22:21:41 +00:00
|
|
|
right: 0;
|
|
|
|
top: 0;
|
|
|
|
bottom: 0;
|
|
|
|
content: ' ';
|
|
|
|
}
|
2017-06-16 17:44:11 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
.dropdown__menu {
|
|
|
|
&.dropdown__menu--open .dropdown__backdrop {
|
2017-06-16 17:44:11 +00:00
|
|
|
display: block;
|
2016-07-20 19:09:21 +00:00
|
|
|
}
|
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
ul {
|
|
|
|
z-index: 9999;
|
|
|
|
display: none;
|
|
|
|
position: fixed;
|
|
|
|
top: 0;
|
|
|
|
left: 0;
|
|
|
|
border: 1px solid @hl-sm;
|
|
|
|
box-shadow: 0 0 1rem 0 rgba(0, 0, 0, 0.1);
|
|
|
|
box-sizing: border-box;
|
|
|
|
background: var(--color-bg);
|
2016-11-29 20:55:31 +00:00
|
|
|
|
2017-06-17 19:31:21 +00:00
|
|
|
// Separate it from it's surroundings a bit
|
|
|
|
margin: @padding-xxs 3px;
|
2016-11-29 20:55:31 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
padding-top: @radius-md;
|
|
|
|
padding-bottom: @radius-md;
|
2016-11-29 20:55:31 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
border-radius: @radius-md;
|
|
|
|
overflow: auto;
|
|
|
|
|
|
|
|
.dropdown__inner {
|
|
|
|
width: 100%;
|
2016-11-29 20:55:31 +00:00
|
|
|
}
|
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
.dropdown__text {
|
|
|
|
white-space: nowrap;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
align-items: center;
|
2017-06-16 17:44:11 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
& > *:not(:first-child) {
|
|
|
|
margin-left: 0.3em;
|
|
|
|
}
|
2017-06-16 17:44:11 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
.dropdown__hint,
|
|
|
|
.dropdown__right {
|
|
|
|
color: @hl-xl;
|
|
|
|
margin-left: auto;
|
|
|
|
padding-left: @padding-lg;
|
|
|
|
}
|
2017-06-16 17:44:11 +00:00
|
|
|
}
|
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
li > button {
|
|
|
|
font-size: @font-size-md;
|
|
|
|
text-align: left;
|
|
|
|
padding-right: @padding-md;
|
|
|
|
padding-left: @padding-sm;
|
|
|
|
height: @line-height-xs;
|
|
|
|
width: 100%;
|
|
|
|
display: block;
|
|
|
|
color: var(--color-font) !important;
|
|
|
|
white-space: nowrap;
|
|
|
|
margin: 0;
|
|
|
|
|
|
|
|
&:hover:not(:disabled),
|
|
|
|
&:focus:not(:disabled) {
|
|
|
|
background: @hl-sm;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active:not(:disabled) {
|
|
|
|
background: @hl-md;
|
|
|
|
}
|
2017-06-16 17:44:11 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
i.fa:first-child {
|
|
|
|
display: inline-block;
|
|
|
|
width: 2.2em;
|
|
|
|
text-align: center;
|
|
|
|
}
|
2016-04-23 06:53:22 +00:00
|
|
|
}
|
2016-08-15 17:04:36 +00:00
|
|
|
|
2017-06-16 22:21:41 +00:00
|
|
|
li.dropdown__divider {
|
|
|
|
border-bottom: 1px solid @hl-lg;
|
|
|
|
overflow: visible !important;
|
|
|
|
height: 0;
|
|
|
|
margin: @padding-md @padding-md @padding-md @padding-md;
|
|
|
|
min-width: @dropdown-min-width - @padding-md * 2;
|
2016-08-15 17:04:36 +00:00
|
|
|
|
|
|
|
.dropdown__divider__label {
|
2017-06-16 22:21:41 +00:00
|
|
|
position: relative;
|
|
|
|
left: -@padding-sm / 2;
|
|
|
|
top: -0.7rem;
|
|
|
|
color: @hl;
|
|
|
|
padding-right: 1em;
|
|
|
|
background: var(--color-bg);
|
|
|
|
font-size: @font-size-xs;
|
|
|
|
text-transform: uppercase;
|
|
|
|
}
|
|
|
|
|
|
|
|
&.dropdown__divider--no-name {
|
|
|
|
margin: @padding-xs 0;
|
|
|
|
|
|
|
|
.dropdown__divider__label {
|
|
|
|
display: none;
|
|
|
|
}
|
2016-08-15 17:04:36 +00:00
|
|
|
}
|
|
|
|
}
|
2016-04-23 06:53:22 +00:00
|
|
|
}
|
2017-06-16 22:21:41 +00:00
|
|
|
|
|
|
|
&.dropdown__menu--open ul {
|
|
|
|
display: block;
|
|
|
|
animation: fadeIn 200ms ease-out;
|
|
|
|
}
|
2016-03-21 05:47:49 +00:00
|
|
|
}
|
2017-06-16 17:44:11 +00:00
|
|
|
|