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:
ayangweb
2025-04-08 15:35:10 +08:00
committed by GitHub
parent 57b2a20c56
commit b45eb0b91d
2 changed files with 5 additions and 5 deletions

View File

@@ -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

View File

@@ -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 ? (