Skip to content

Commit 059a8dd

Browse files
committed
fix bugs introduced by #232 on small screens
1 parent 1d72fe6 commit 059a8dd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

components/searchBar/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ export default function SearchBar({
6161
if (event) event.preventDefault();
6262

6363
// When input value is null, set error & empty state to `true` and do nothing.
64-
if (!query || !inputRef.current.value) {
64+
if (!inputRef.current.value) {
6565
setIsError(true);
6666
setIsEmpty(true);
6767
return;
@@ -81,7 +81,7 @@ export default function SearchBar({
8181
style={{ marginRight: -12 }}
8282
onClick={() => handleSubmit()}
8383
aria-label="Search"
84-
disabled={isEmpty}
84+
disabled={!smallScreen && isEmpty}
8585
>
8686
<Search />
8787
</IconButton>

0 commit comments

Comments
 (0)