1
0
Fork 0

Reset search query if really empty

This commit is contained in:
Lim Chee Aun 2023-12-22 23:03:05 +08:00
parent 768477ea6c
commit b00033129f

View file

@ -168,8 +168,8 @@ function Search({ columnMode, ...props }) {
});
useEffect(() => {
searchFormRef.current?.setValue?.(q || '');
if (q) {
searchFormRef.current?.setValue?.(q);
loadResults(true);
} else {
searchFormRef.current?.focus?.();