From 33271a88b17a54bad62db22d85dfd452fa74b6f5 Mon Sep 17 00:00:00 2001 From: Udit Takkar <53316345+Udit-takkar@users.noreply.github.com> Date: Thu, 24 Nov 2022 01:23:12 +0530 Subject: [PATCH] fix: ui of button (#5552) Co-authored-by: alannnc --- packages/ui/v2/core/banner.tsx | 38 +++++++++++++++------------------- 1 file changed, 17 insertions(+), 21 deletions(-) diff --git a/packages/ui/v2/core/banner.tsx b/packages/ui/v2/core/banner.tsx index 3a4acb7199..d7ae94215c 100644 --- a/packages/ui/v2/core/banner.tsx +++ b/packages/ui/v2/core/banner.tsx @@ -3,8 +3,6 @@ import { Icon } from "react-feather"; import classNames from "@calcom/lib/classNames"; -import { Button } from "../../components/button"; - const stylesByVariant = { neutral: { background: "bg-gray-100 ", text: "!text-gray-800", hover: "hover:!bg-gray-200" }, warning: { background: "bg-orange-100 ", text: "!text-orange-800", hover: "hover:!bg-orange-200" }, @@ -24,7 +22,6 @@ export type BannerProps = { const Banner = (props: BannerProps) => { const { variant, errorMessage, title, description, className, Icon, ...rest } = props; - const buttonStyle = classNames(stylesByVariant[variant].text, stylesByVariant[variant].hover); const [show, setShow] = useState(true); if (!show) { return null; @@ -38,29 +35,28 @@ const Banner = (props: BannerProps) => { className )} {...rest}> -
-
{Icon && }
+
+
{Icon && }

{title}

{description &&

{description}

} {props.variant === "error" &&

{errorMessage}

}
-
-
- {props.actionText && ( - - )} - +
+ {props.actionText && ( + + )} + +
);