import React from "react"; import * as AlertDialog from "@radix-ui/react-alert-dialog"; import "./index.scss"; import Button from "~components/Button"; import { ButtonType } from "~utils/enums"; // Props interface Props { open: boolean; title?: string; message: string; primaryAction?: () => void; primaryActionText?: string; cancelAction: () => void; cancelActionText: string; } const Alert = (props: Props) => { return (
{props.title ? Error : ""} {props.message}
{props.primaryAction ? ( {props.primaryActionText} ) : ( "" )}
); }; export default Alert;