Skip to content

Commit

Permalink
fix: searchbox should collapse if query is not empty
Browse files Browse the repository at this point in the history
  • Loading branch information
jeangovil committed Sep 29, 2023
1 parent d6d9cb5 commit 3be1bb2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/SearchBox/SearchBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export const SearchBox: React.FC<SearchBoxProps> = ({
const [activeInput, setActiveInput] = useState(false)
const stickyComponent = globalMode
? 'results'
: focused || !activeInput
: query.length === 0 || !activeInput
? 'root'
: 'results'

Expand Down

0 comments on commit 3be1bb2

Please sign in to comment.