2017-03-26 21:09:19 -04:00
|
|
|
//
|
|
|
|
// Search input and autocomplete
|
|
|
|
//
|
|
|
|
|
|
|
|
.search {
|
2018-10-23 11:40:39 -04:00
|
|
|
position: relative;
|
|
|
|
z-index: 99;
|
|
|
|
flex-grow: 1;
|
2019-05-12 08:12:00 -04:00
|
|
|
height: 100%;
|
2018-10-23 11:40:39 -04:00
|
|
|
margin-bottom: $sp-3;
|
2017-03-26 21:09:19 -04:00
|
|
|
|
|
|
|
@include mq(md) {
|
2018-10-23 11:40:39 -04:00
|
|
|
margin-bottom: 0;
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.search-input-wrap {
|
|
|
|
display: flex;
|
2019-05-12 08:12:00 -04:00
|
|
|
height: 100%;
|
|
|
|
padding: $sp-2;
|
2019-08-13 17:24:23 -04:00
|
|
|
background-color: $search-background-color;
|
2019-05-12 08:12:00 -04:00
|
|
|
border-radius: $border-radius;
|
|
|
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08);
|
|
|
|
|
|
|
|
@include mq(md) {
|
|
|
|
padding-top: 0;
|
|
|
|
padding-right: 0;
|
|
|
|
padding-bottom: 0;
|
|
|
|
padding-left: 0;
|
2019-05-18 20:41:40 -04:00
|
|
|
background-color: $body-background-color;
|
2019-08-13 17:24:23 -04:00
|
|
|
border-radius: 0;
|
2019-05-12 08:12:00 -04:00
|
|
|
box-shadow: none;
|
|
|
|
}
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
.search-input {
|
2019-05-12 08:12:00 -04:00
|
|
|
align-self: center;
|
2017-11-08 11:23:05 -05:00
|
|
|
width: 100%;
|
2017-03-26 21:09:19 -04:00
|
|
|
padding-top: $sp-1;
|
|
|
|
padding-bottom: $sp-1;
|
2019-05-18 20:41:40 -04:00
|
|
|
background-color: $search-background-color;
|
2017-03-26 21:09:19 -04:00
|
|
|
border-top: 0;
|
|
|
|
border-right: 0;
|
2017-06-04 17:50:01 -04:00
|
|
|
border-bottom: 0;
|
2017-03-26 21:09:19 -04:00
|
|
|
border-left: 0;
|
|
|
|
order: 2;
|
2019-05-18 20:41:40 -04:00
|
|
|
@include fs-4;
|
2017-03-26 21:09:19 -04:00
|
|
|
|
|
|
|
&:focus {
|
|
|
|
outline: 0;
|
2017-06-04 17:50:01 -04:00
|
|
|
box-shadow: none;
|
2017-03-26 21:09:19 -04:00
|
|
|
|
|
|
|
+ .search-icon {
|
2018-11-18 11:07:45 -05:00
|
|
|
fill: $link-color;
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
|
|
|
}
|
2018-10-24 14:05:29 -04:00
|
|
|
|
|
|
|
@include mq(md) {
|
2019-05-18 20:41:40 -04:00
|
|
|
background-color: $body-background-color;
|
2019-05-12 08:12:00 -04:00
|
|
|
@include fs-3;
|
2018-10-24 14:05:29 -04:00
|
|
|
}
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
.search-icon {
|
|
|
|
align-self: center;
|
|
|
|
margin-right: $sp-2;
|
|
|
|
fill: $grey-dk-000;
|
|
|
|
order: 1;
|
|
|
|
}
|
|
|
|
|
2019-05-12 08:12:00 -04:00
|
|
|
.search-results-wrap {
|
|
|
|
position: absolute;
|
|
|
|
z-index: 100;
|
2019-08-13 17:24:23 -04:00
|
|
|
display: none;
|
2019-05-12 08:12:00 -04:00
|
|
|
width: 100%;
|
2019-05-18 20:41:40 -04:00
|
|
|
background: $search-background-color;
|
2019-08-13 17:24:23 -04:00
|
|
|
border-radius: $border-radius;
|
2019-05-12 08:12:00 -04:00
|
|
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08);
|
|
|
|
|
|
|
|
&.active {
|
|
|
|
display: block;
|
|
|
|
}
|
2019-05-18 17:07:02 -04:00
|
|
|
|
|
|
|
@include mq(md) {
|
|
|
|
width: $search-results-width;
|
|
|
|
}
|
2019-05-12 08:12:00 -04:00
|
|
|
}
|
|
|
|
|
2017-03-26 21:09:19 -04:00
|
|
|
.search-results-list {
|
|
|
|
padding-left: 0;
|
2017-06-04 17:50:01 -04:00
|
|
|
margin-top: $sp-1;
|
2017-03-26 21:09:19 -04:00
|
|
|
margin-bottom: $sp-1;
|
|
|
|
list-style: none;
|
2019-05-12 08:12:00 -04:00
|
|
|
@include fs-4;
|
|
|
|
|
|
|
|
@include mq(md) {
|
|
|
|
@include fs-3;
|
|
|
|
}
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
.search-results-list-item {
|
|
|
|
padding: 0;
|
|
|
|
margin: 0;
|
|
|
|
}
|
|
|
|
|
2019-05-18 17:07:02 -04:00
|
|
|
.search-result {
|
2017-03-26 21:09:19 -04:00
|
|
|
display: block;
|
|
|
|
padding-top: $sp-1;
|
|
|
|
padding-bottom: $sp-1;
|
|
|
|
padding-left: $sp-3;
|
2019-05-18 17:07:02 -04:00
|
|
|
padding-right: $sp-3;
|
2017-03-26 21:09:19 -04:00
|
|
|
|
2019-05-18 17:51:30 -04:00
|
|
|
&:hover, &.active {
|
2019-05-18 20:41:40 -04:00
|
|
|
background-color: darken($search-background-color, 5%);
|
2019-05-18 17:07:02 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
@include mq(md) {
|
|
|
|
padding-left: $sp-4;
|
|
|
|
padding-right: $sp-4;
|
|
|
|
}
|
|
|
|
|
|
|
|
.search-result-title {
|
|
|
|
display: block;
|
|
|
|
padding-top: $sp-2;
|
|
|
|
padding-bottom: $sp-2;
|
|
|
|
padding-right: $sp-4;
|
|
|
|
|
|
|
|
@include mq(sm) {
|
|
|
|
display: inline-block;
|
|
|
|
width: 40%;
|
|
|
|
vertical-align: top;
|
2019-05-19 11:21:20 -04:00
|
|
|
word-wrap: break-word;
|
2019-05-18 17:07:02 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.search-result-preview {
|
|
|
|
display: block;
|
|
|
|
padding-top: $sp-2;
|
|
|
|
padding-bottom: $sp-2;
|
|
|
|
padding-left: $sp-4;
|
|
|
|
border-left: $border;
|
|
|
|
border-left-color: $border-color;
|
|
|
|
color: $search-result-preview-color;
|
|
|
|
@include fs-2;
|
|
|
|
|
|
|
|
@include mq(sm) {
|
|
|
|
display: inline-block;
|
|
|
|
width: 60%;
|
2019-05-19 11:21:20 -04:00
|
|
|
vertical-align: top;
|
2019-05-18 17:07:02 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.search-result-highlight {
|
|
|
|
color: $link-color;
|
|
|
|
font-weight: bold;
|
2017-03-26 21:09:19 -04:00
|
|
|
}
|
2017-03-24 09:47:37 -04:00
|
|
|
}
|