import classNames from "classnames"; import { noop } from "lodash"; import type { ReactNode } from "react"; import { X, AlertTriangle, Info } from "@calcom/ui/components/icon"; export type TopBannerProps = { text: string; variant?: keyof typeof variantClassName; actions?: ReactNode; onClose?: () => void; }; const variantClassName = { default: "bg-gradient-primary", warning: "bg-orange-400", error: "bg-red-400", }; export function TopBanner(props: TopBannerProps) { const { variant = "default", text, actions, onClose } = props; return (

{variant === "error" && (

{actions &&
{actions}
}
{typeof onClose === "function" && ( )}
); }