mirror of
https://github.com/infinilabs/coco-app.git
synced 2025-12-16 11:37:47 +01:00
fix: fixed the problem of not being able to search in secondary directories (#338)
* fix: fixed the problem of not being able to search in secondary directories * docs: update changelog
This commit is contained in:
@@ -19,6 +19,8 @@ Information about release notes of Coco Server is provided here.
|
||||
|
||||
### Bug fix
|
||||
|
||||
- Fixed the problem of not being able to search in secondary directories #338
|
||||
|
||||
### Improvements
|
||||
|
||||
- refactor: web components #331
|
||||
|
||||
@@ -7,6 +7,7 @@ import { useSearchStore } from "@/stores/searchStore";
|
||||
import ContextMenu from "./ContextMenu";
|
||||
import { NoResults } from "@/components/Common/UI/NoResults";
|
||||
import Footer from "@/components/Common/UI/Footer";
|
||||
|
||||
interface SearchProps {
|
||||
isTauri: boolean;
|
||||
changeInput: (val: string) => void;
|
||||
@@ -75,15 +76,12 @@ function Search({
|
||||
const debouncedSearch = useCallback(debounce(getSuggest, 500), [input]);
|
||||
|
||||
useEffect(() => {
|
||||
!isChatMode && !sourceData && debouncedSearch();
|
||||
!isChatMode && debouncedSearch();
|
||||
if (!input) setSuggests([]);
|
||||
}, [input]);
|
||||
|
||||
return (
|
||||
<div
|
||||
ref={mainWindowRef}
|
||||
className={`h-full pb-10 w-full relative`}
|
||||
>
|
||||
<div ref={mainWindowRef} className={`h-full pb-10 w-full relative`}>
|
||||
{/* Search Results Panel */}
|
||||
{suggests.length > 0 ? (
|
||||
sourceData ? (
|
||||
|
||||
Reference in New Issue
Block a user