Clear q URL when clear search field
This commit is contained in:
parent
ef2f55457f
commit
b29e7ad1cb
1 changed files with 5 additions and 0 deletions
|
@ -69,6 +69,11 @@ function Search() {
|
||||||
type="search"
|
type="search"
|
||||||
autofocus
|
autofocus
|
||||||
placeholder="Search"
|
placeholder="Search"
|
||||||
|
onSearch={(e) => {
|
||||||
|
if (!e.target.value) {
|
||||||
|
setSearchParams({});
|
||||||
|
}
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</form>
|
</form>
|
||||||
<div class="header-side" />
|
<div class="header-side" />
|
||||||
|
|
Loading…
Add table
Reference in a new issue