Fix search icon behavior and add new icon X

This commit is contained in:
Gabriel Luiz Freitas Almeida 2024-03-08 23:37:54 -03:00
commit 35c35c9964
2 changed files with 14 additions and 3 deletions

View file

@ -250,10 +250,20 @@ export default function ExtraSidebar(): JSX.Element {
setSearch(event.target.value);
}}
/>
<div className="search-icon">
<div
className="search-icon "
onClick={() => {
if (search) {
setFilterData(data);
setSearch("");
}
}}
>
<IconComponent
name="Search"
className={"h-5 w-5 stroke-[1.5] text-primary"}
name={search ? "X" : "Search"}
className={`h-5 w-5 stroke-[1.5] text-primary ${
search ? "cursor-pointer" : "cursor-default"
}`}
aria-hidden="true"
/>
</div>

View file

@ -278,6 +278,7 @@ export const nodeNames: { [char: string]: string } = {
};
export const nodeIconsLucide: iconsType = {
X: X,
Notify: Bell,
ListFlows: Group,
ClearMessageHistory: FileClock,