From e4a217febb3446ec16fa4d11f5dddfa9423045cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ricardo=20L=C3=BCders?= Date: Mon, 5 Dec 2022 22:51:28 +0100 Subject: [PATCH] fix(toast): ToastToggle must have className --- src/lib/components/Toast/ToastToggle.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lib/components/Toast/ToastToggle.tsx b/src/lib/components/Toast/ToastToggle.tsx index 2a6079b06..d66af5ae4 100644 --- a/src/lib/components/Toast/ToastToggle.tsx +++ b/src/lib/components/Toast/ToastToggle.tsx @@ -1,3 +1,4 @@ +import classNames from 'classnames'; import type { ComponentProps, FC } from 'react'; import { HiX } from 'react-icons/hi'; import { useTheme } from '../Flowbite/ThemeContext'; @@ -7,7 +8,7 @@ type ToastToggleProps = ComponentProps<'button'> & { xIcon?: FC>; }; -export const ToastToggle: FC = ({ xIcon: XIcon = HiX }) => { +export const ToastToggle: FC = ({ className, xIcon: XIcon = HiX }) => { const { duration, isClosed, isRemoved, setIsClosed, setIsRemoved } = useToastContext(); const theme = useTheme().theme.toast.toggle; @@ -17,7 +18,7 @@ export const ToastToggle: FC = ({ xIcon: XIcon = HiX }) => { }; return ( - );