From 36136a54444236b32b60a97d5ae323e17152ddd0 Mon Sep 17 00:00:00 2001 From: Nikolai Kryshnev Date: Wed, 11 Dec 2024 00:27:57 +0300 Subject: [PATCH] Fixed: Button now covers parent area for intuitive usability and includes a noticeable hover effect. --- src/components/search/SearchBar.tsx | 30 ++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/src/components/search/SearchBar.tsx b/src/components/search/SearchBar.tsx index d79aecd..eafa9aa 100644 --- a/src/components/search/SearchBar.tsx +++ b/src/components/search/SearchBar.tsx @@ -19,6 +19,9 @@ export function SearchBar({ value, placeholder, onChangeValue, isFetching }: Pro onChangeValue(value); }; + const iconStyle = + 'flex h-10 w-10 items-center justify-center rounded-full bg-pink-600 sm:h-12 sm:w-12'; + return (
-
- {isFetching && } - {!isFetching && !value && } - {!isFetching && value && ( - onChange(null)}> + + {isFetching && ( +
+ +
+ )} + {!isFetching && !value && ( +
+ +
+ )} + {!isFetching && value && ( +
+ onChange(null)} + > - )} -
+
+ )}
); }