import clsx from "clsx"; import { Check, CircleAlert, OctagonAlert, TriangleAlert } from "lucide-react"; import type * as React from "react"; import { assertUnreachable } from "~/utils/types"; import styles from "./Alert.module.css"; export type AlertVariation = "INFO" | "WARNING" | "ERROR" | "SUCCESS"; export function Alert({ children, textClassName, alertClassName, variation = "INFO", tiny = false, }: { children: React.ReactNode; textClassName?: string; alertClassName?: string; variation?: AlertVariation; tiny?: boolean; }) { return (
{" "}
{children}
); } function Icon({ variation }: { variation: AlertVariation }) { switch (variation) { case "INFO": return ; case "WARNING": return ; case "ERROR": return ; case "SUCCESS": return ; default: assertUnreachable(variation); } }