diff --git a/app/scenes/Search/index.tsx b/app/scenes/Search/index.tsx index 81082754a6..eaf8d85625 100644 --- a/app/scenes/Search/index.tsx +++ b/app/scenes/Search/index.tsx @@ -262,6 +262,14 @@ function Search(props: Props) { const results = documents.searchResults(query); const showEmpty = !isLoading && query && results?.length === 0; + // Set `InputSearch` box value when + // `term` changes. + React.useEffect(() => { + if (searchInputRef.current) { + searchInputRef.current.value = term; + } + }, [term]); + return (