import React, { ReactNode } from "react"; import { cls } from "../../utils/css"; import "./box.less"; export enum BoxType { error = "error", } export interface BoxProps { absolute?: boolean; type?: BoxType; onClose?: () => void; children: ReactNode; } const Box: React.FC = ({ absolute, type, onClose, children }) => (
{onClose && ( )} {children}
); export default Box;