Fixed buttons not using ShadCN buttons on header of components section

This commit is contained in:
Lucas Oliveira 2024-06-06 14:42:50 -03:00
commit a96b08472f

View file

@ -3,6 +3,7 @@ import IconComponent from "../../../../components/genericIconComponent";
import ShadTooltip from "../../../../components/shadTooltipComponent"; import ShadTooltip from "../../../../components/shadTooltipComponent";
import { Checkbox } from "../../../../components/ui/checkbox"; import { Checkbox } from "../../../../components/ui/checkbox";
import { cn } from "../../../../utils/utils"; import { cn } from "../../../../utils/utils";
import { Button } from "../../../../components/ui/button";
type HeaderComponentProps = { type HeaderComponentProps = {
handleSelectAll: (select) => void; handleSelectAll: (select) => void;
@ -61,12 +62,17 @@ const HeaderComponent = ({
) )
} }
> >
<button onClick={handleExport} disabled={disableFunctions}> <Button
variant="none"
size="none"
onClick={handleExport}
disabled={disableFunctions}
>
<IconComponent <IconComponent
name="FileDown" name="FileDown"
className={cn("h-5 w-5 text-primary transition-all")} className={cn("h-5 w-5 text-primary transition-all")}
/> />
</button> </Button>
</ShadTooltip> </ShadTooltip>
</div> </div>
<div> <div>
@ -79,12 +85,17 @@ const HeaderComponent = ({
) )
} }
> >
<button onClick={handleDuplicate} disabled={disableFunctions}> <Button
variant="none"
size="none"
onClick={handleDuplicate}
disabled={disableFunctions}
>
<IconComponent <IconComponent
name="Copy" name="Copy"
className={cn("h-5 w-5 text-primary transition-all")} className={cn("h-5 w-5 text-primary transition-all")}
/> />
</button> </Button>
</ShadTooltip> </ShadTooltip>
</div> </div>
<div> <div>
@ -97,7 +108,12 @@ const HeaderComponent = ({
) )
} }
> >
<button onClick={handleDelete} disabled={disableFunctions}> <Button
variant="none"
size="none"
onClick={handleDelete}
disabled={disableFunctions}
>
<IconComponent <IconComponent
name="Trash2" name="Trash2"
className={cn( className={cn(
@ -105,7 +121,7 @@ const HeaderComponent = ({
disableFunctions ? "" : "hover:text-destructive", disableFunctions ? "" : "hover:text-destructive",
)} )}
/> />
</button> </Button>
</ShadTooltip> </ShadTooltip>
</div> </div>
</div> </div>