2016-03-23 05:26:27 +00:00
|
|
|
@import '../constants/colors';
|
2016-03-21 05:47:49 +00:00
|
|
|
@import '../constants/dimensions';
|
|
|
|
|
|
|
|
.dropdown {
|
|
|
|
position: relative;
|
2016-04-04 07:15:30 +00:00
|
|
|
display: inline-block;
|
2016-03-21 05:47:49 +00:00
|
|
|
|
2016-07-06 20:18:26 +00:00
|
|
|
&:focus {
|
|
|
|
outline: none;
|
|
|
|
}
|
|
|
|
|
2016-06-20 06:05:40 +00:00
|
|
|
.dropdown__backdrop {
|
|
|
|
display: none;
|
|
|
|
position: fixed;
|
|
|
|
z-index: 999;
|
|
|
|
left: 0;
|
|
|
|
right: 0;
|
|
|
|
top: 0;
|
|
|
|
bottom: 0;
|
|
|
|
content: ' ';
|
|
|
|
}
|
|
|
|
|
2016-03-21 05:47:49 +00:00
|
|
|
ul {
|
2016-06-20 06:05:40 +00:00
|
|
|
display: none;
|
2016-03-21 05:47:49 +00:00
|
|
|
position: absolute;
|
2016-04-07 01:11:16 +00:00
|
|
|
top: 100%;
|
2016-03-21 06:36:39 +00:00
|
|
|
left: 0;
|
2016-05-01 20:46:11 +00:00
|
|
|
z-index: 1000;
|
2016-04-10 05:03:18 +00:00
|
|
|
min-width: $dropdown-min-width;
|
2016-04-17 22:46:17 +00:00
|
|
|
box-shadow: 0 0 1rem 0 rgba(0, 0, 0, 0.25);
|
2016-04-10 06:37:22 +00:00
|
|
|
// Separate it from the button a bit
|
2016-04-17 22:46:17 +00:00
|
|
|
margin-top: 3px;
|
|
|
|
margin-bottom: 3px;
|
|
|
|
border-radius: $radius-md;
|
|
|
|
background: $bg-super-light;
|
|
|
|
overflow: hidden;
|
2016-04-10 06:37:22 +00:00
|
|
|
|
2016-04-04 07:15:30 +00:00
|
|
|
li {
|
|
|
|
& > button {
|
|
|
|
font-size: $font-size-md;
|
|
|
|
text-align: left;
|
2016-06-16 06:16:24 +00:00
|
|
|
padding: $padding-xs $padding-md $padding-xs $padding-sm;
|
2016-04-04 07:15:30 +00:00
|
|
|
width: 100%;
|
|
|
|
display: block;
|
2016-04-26 07:29:24 +00:00
|
|
|
color: $font-super-light-bg !important;
|
2016-07-19 16:59:26 +00:00
|
|
|
white-space: nowrap;
|
2016-04-04 07:15:30 +00:00
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background: $hl-sm;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active {
|
|
|
|
background: $hl-md;
|
|
|
|
}
|
|
|
|
|
|
|
|
i.fa {
|
|
|
|
display: inline-block;
|
2016-04-05 05:35:21 +00:00
|
|
|
width: 2em;
|
2016-04-15 02:13:49 +00:00
|
|
|
text-align: center;
|
2016-04-04 07:15:30 +00:00
|
|
|
}
|
2016-03-23 18:34:39 +00:00
|
|
|
}
|
2016-03-21 05:47:49 +00:00
|
|
|
}
|
|
|
|
}
|
2016-04-05 05:35:21 +00:00
|
|
|
|
2016-04-23 06:53:22 +00:00
|
|
|
li.dropdown__divider {
|
|
|
|
border-bottom: 1px solid $hl-lg;
|
|
|
|
overflow: visible !important;
|
|
|
|
margin: $padding-md $padding-md $padding-md $padding-sm;
|
|
|
|
height: 0;
|
|
|
|
padding: 0;
|
|
|
|
|
|
|
|
.dropdown__divider__label {
|
|
|
|
position: relative;
|
2016-06-20 06:05:40 +00:00
|
|
|
top: -0.85rem;
|
|
|
|
// HACK: Fine adjustment
|
2016-04-23 06:53:22 +00:00
|
|
|
color: $hl-xxl;
|
|
|
|
padding-right: 1em;
|
|
|
|
background: #fff;
|
|
|
|
font-size: $font-size-xs;
|
|
|
|
margin-top: 0.5em;
|
|
|
|
margin-bottom: 0.5em;
|
|
|
|
text-transform: uppercase;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-04-07 01:11:16 +00:00
|
|
|
&.dropdown--flip ul {
|
|
|
|
bottom: 100%;
|
|
|
|
top: auto;
|
|
|
|
}
|
|
|
|
|
2016-06-20 06:05:40 +00:00
|
|
|
&.dropdown--open {
|
|
|
|
ul {
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
|
|
|
|
.dropdown__backdrop {
|
|
|
|
display: block;
|
|
|
|
}
|
2016-04-05 05:35:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
&.dropdown--right ul {
|
|
|
|
right: 0;
|
|
|
|
left: auto;
|
|
|
|
}
|
2016-03-21 05:47:49 +00:00
|
|
|
}
|