Re-add search icon
This commit is contained in:
parent
6e6454e597
commit
ed10c7e066
@ -1,10 +1,11 @@
|
||||
|
||||
<div ngbDropdown #resultsDropdown="ngbDropdown" (openChange)="onDropdownOpenChange">
|
||||
<form class="form-inline col-6 position-relative">
|
||||
<form class="form-inline col-12 col-md-6 position-relative">
|
||||
<i-bs width="1em" height="1em" name="search"></i-bs>
|
||||
<input #searchInput class="form-control form-control-sm" type="text" name="query"
|
||||
autocomplete="off" placeholder="Search everything" aria-label="Search" i18n-placeholder
|
||||
autocomplete="off" placeholder="Search" aria-label="Search" i18n-placeholder
|
||||
[(ngModel)]="query" (ngModelChange)="this.queryDebounce.next($event)" (keyup)="searchInputKeyDown($event)" ngbDropdownAnchor>
|
||||
<span class="badge text-muted position-absolute top-50 start-100 translate-middle ms-n4 fw-normal">⌘K</span>
|
||||
<span class="badge d-none d-lg-inline text-muted position-absolute top-50 start-100 translate-middle ms-n4 fw-normal">⌘K</span>
|
||||
</form>
|
||||
|
||||
<ng-template #resultItemTemplate let-item="item" let-nameProp="nameProp" let-type="type" let-icon="icon">
|
||||
|
@ -1,5 +1,23 @@
|
||||
form {
|
||||
position: relative;
|
||||
|
||||
> i-bs {
|
||||
position: absolute;
|
||||
left: 0.6rem;
|
||||
top: .35rem;
|
||||
color: rgba(255, 255, 255, 0.6);
|
||||
|
||||
@media screen and (min-width: 768px) {
|
||||
// adjust for smaller font size on non-mobile
|
||||
top: 0.25rem;
|
||||
}
|
||||
}
|
||||
|
||||
&:focus-within {
|
||||
i-bs {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.form-control::placeholder {
|
||||
color: rgba(255, 255, 255, 0);
|
||||
}
|
||||
@ -13,6 +31,7 @@ form {
|
||||
.form-control {
|
||||
color: rgba(255, 255, 255, 0.3);
|
||||
background-color: rgba(0, 0, 0, 0.15);
|
||||
padding-left: 1.8rem;
|
||||
border-color: rgba(255, 255, 255, 0.2);
|
||||
transition: all .3s ease, padding-left 0s ease, background-color 0s ease; // Safari requires all
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user