114 lines
2.1 KiB
SCSS
114 lines
2.1 KiB
SCSS
.wunderbar {
|
|
min-width: 175px;
|
|
height: 100%;
|
|
cursor: text;
|
|
display: flex;
|
|
align-items: center;
|
|
flex: 1;
|
|
position: relative;
|
|
z-index: 1;
|
|
margin-right: calc(var(--spacing-large));
|
|
|
|
@media (max-width: 600px) {
|
|
margin-right: 0;
|
|
}
|
|
|
|
> .icon {
|
|
top: 0;
|
|
left: var(--spacing-small);
|
|
height: 100%;
|
|
position: absolute;
|
|
z-index: 1;
|
|
}
|
|
}
|
|
|
|
.wunderbar__active-suggestion {
|
|
background-color: $lbry-blue-2;
|
|
color: $lbry-black;
|
|
|
|
[data-mode='dark'] & {
|
|
background-color: $lbry-blue-4;
|
|
color: inherit;
|
|
}
|
|
}
|
|
|
|
.wunderbar__input {
|
|
width: 100%;
|
|
height: var(--button-height);
|
|
border-radius: var(--button-radius);
|
|
background-color: $lbry-gray-1;
|
|
align-items: center;
|
|
border: none;
|
|
min-width: 0;
|
|
padding-right: var(--spacing-small);
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
|
|
padding-left: 2.5rem;
|
|
transition: all 0.2s;
|
|
|
|
&:focus {
|
|
border-radius: var(--input-border-radius);
|
|
}
|
|
|
|
&::placeholder {
|
|
color: $lbry-black;
|
|
opacity: 0.9;
|
|
}
|
|
|
|
[data-mode='dark'] & {
|
|
background-color: var(--dm-color-03);
|
|
color: $lbry-white;
|
|
|
|
&::placeholder {
|
|
color: var(--dm-color-02);
|
|
}
|
|
}
|
|
}
|
|
|
|
.wunderbar__menu {
|
|
background-color: $lbry-white;
|
|
box-shadow: 0 1px 5px rgba($lbry-black, 0.15);
|
|
min-width: 100%;
|
|
overflow: hidden;
|
|
|
|
[data-mode='dark'] & {
|
|
background-color: $lbry-gray-5;
|
|
color: $lbry-white;
|
|
}
|
|
}
|
|
|
|
.wunderbar__suggestion {
|
|
align-items: center;
|
|
cursor: pointer;
|
|
display: flex;
|
|
flex-direction: row;
|
|
justify-items: flex-start;
|
|
padding: var(--spacing-small) var(--spacing-medium);
|
|
|
|
&:not(:first-of-type) {
|
|
border-top: 1px solid transparent;
|
|
}
|
|
|
|
.icon {
|
|
flex-shrink: 0;
|
|
}
|
|
}
|
|
|
|
.wunderbar__suggestion-label {
|
|
overflow: hidden;
|
|
padding-left: var(--spacing-large);
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.wunderbar__suggestion-label--action {
|
|
font-size: 1rem;
|
|
font-weight: 600;
|
|
line-height: 0.1; // to vertically align because the font size is smaller
|
|
margin-left: var(--spacing-small);
|
|
opacity: 0.7;
|
|
text-transform: uppercase;
|
|
white-space: nowrap;
|
|
}
|