From ba4e8a474f503e0ed3884805699aa2df3b4f108c Mon Sep 17 00:00:00 2001 From: Delirium Date: Mon, 18 Mar 2024 12:12:46 +0100 Subject: [PATCH] fix(ui): fix search input clear (#1969) --- .../shared/SessionSearchField/AiSessionSearchField.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/app/components/shared/SessionSearchField/AiSessionSearchField.tsx b/frontend/app/components/shared/SessionSearchField/AiSessionSearchField.tsx index 1590fa79b..4fbcdb971 100644 --- a/frontend/app/components/shared/SessionSearchField/AiSessionSearchField.tsx +++ b/frontend/app/components/shared/SessionSearchField/AiSessionSearchField.tsx @@ -88,8 +88,8 @@ const AiSearchField = observer(({ edit }: Props) => { const debounceAiFetch = React.useCallback(debounce(aiFiltersStore.getSearchFilters, 1000), []); const onSearchChange = ({ target: { value } }: any) => { + setSearchQuery(value); if (value !== '' && value !== searchQuery) { - setSearchQuery(value); debounceAiFetch(value); } };