rsuite
Version:
A suite of react components
25 lines (24 loc) • 894 B
TypeScript
import React from 'react';
import { WithAsProps, TypeAttributes, RsRefForwardingComponent } from '../@types/common';
export interface MessageProps extends WithAsProps {
/** The type of the message box. */
type?: TypeAttributes.Status;
/** Whether it is possible to close the message box */
closable?: boolean;
/**
* Delay automatic removal of messages.
* When set to 0, the message is not automatically removed.
* (Unit: milliseconds)
*/
duration?: number;
/** The title of the message */
header?: React.ReactNode;
/** Whether to display an icon */
showIcon?: boolean;
/** Fill the container */
full?: boolean;
/** Callback after the message is removed */
onClose?: (event?: React.MouseEvent<HTMLButtonElement>) => void;
}
declare const Message: RsRefForwardingComponent<'div', MessageProps>;
export default Message;