discourse/app/assets/stylesheets/common/select-kit/combo-box.scss

125 lines
2.3 KiB
SCSS
Raw Normal View History

.select-kit {
2017-10-19 15:51:08 -04:00
&.combo-box {
min-width: auto;
.select-kit-body {
2017-10-19 15:51:08 -04:00
width: 100%;
min-width: 150px;
border-radius: 0;
box-shadow: shadow("dropdown");
2017-10-19 15:51:08 -04:00
}
.select-kit-row {
margin: 0;
2017-10-19 15:51:08 -04:00
min-height: 1px;
padding: 6px 10px;
&.no-content {
font-weight: normal;
}
2017-10-19 15:51:08 -04:00
}
.select-kit-filter {
2018-09-19 11:12:34 -04:00
padding: $input-padding;
border-top: 1px solid $primary-low;
border-bottom: 1px solid $primary-low;
2017-10-19 15:51:08 -04:00
.spinner {
flex: 0 0 auto;
}
.filter-input,
.filter-input:focus,
.filter-input:active {
flex: 0 0 auto;
width: 90%; // Firefox quirk
}
.filter-icon {
padding-left: 5px;
2017-10-19 15:51:08 -04:00
}
}
.select-kit-header {
2017-10-19 15:51:08 -04:00
background: $secondary;
border: 1px solid $primary-medium;
padding: 0 5px 0 10px;
2017-10-19 15:51:08 -04:00
font-weight: 500;
2018-01-12 17:27:38 -05:00
font-size: $font-0;
2017-10-19 15:51:08 -04:00
&.is-focused {
border: 1px solid $tertiary;
box-shadow: shadow("focus");
2017-10-19 15:51:08 -04:00
}
}
.select-kit-collection {
display: flex;
flex-direction: column;
padding: 0;
min-width: 100px;
max-height: 200px;
max-width: 32em;
.collection-header {
a {
white-space: nowrap;
color: $primary;
line-height: $line-height-medium;
font-weight: bold;
display: block;
padding: 6px 10px;
color: $tertiary;
&:hover {
text-decoration: underline;
}
}
}
}
2017-10-19 15:51:08 -04:00
&.is-disabled {
.select-kit-header {
2017-10-19 15:51:08 -04:00
background: #e9e9e9;
border-color: #ddd;
}
}
&.is-highlighted {
.select-kit-header {
2017-10-19 15:51:08 -04:00
border: 1px solid $tertiary;
box-shadow: shadow("focus");
2017-10-19 15:51:08 -04:00
}
}
&.is-expanded {
.select-kit-wrapper {
2017-10-19 15:51:08 -04:00
display: block;
border: 1px solid $tertiary;
box-shadow: shadow("focus");
2017-10-19 15:51:08 -04:00
}
}
&.is-expanded.is-above {
.select-kit-header {
2017-10-19 15:51:08 -04:00
border-radius: 0 0 3px 3px;
}
.select-kit-body {
border-radius: 3px 3px 0 0;
}
2017-10-19 15:51:08 -04:00
}
&.tag-drop,
&.group-dropdown {
min-width: auto;
.select-kit-row {
font-weight: bold;
}
2018-05-03 11:08:14 -04:00
}
&.is-expanded .select-kit-wrapper,
.select-kit-wrapper {
2018-05-03 11:08:14 -04:00
display: none;
}
2017-10-19 15:51:08 -04:00
}
}