23 lines
617 B
JavaScript
23 lines
617 B
JavaScript
import React from 'react';
|
|
import { notification } from 'antd';
|
|
|
|
const { success, error, warning, info } = notification;
|
|
|
|
export const showSuccess = (message, description) => {
|
|
success({ message, description, placement: 'topRight' });
|
|
};
|
|
|
|
export const showError = (message, description) => {
|
|
error({ message, description, placement: 'topRight' });
|
|
};
|
|
|
|
export const showWarning = (message, description) => {
|
|
warning({ message, description, placement: 'topRight' });
|
|
};
|
|
|
|
export const showInfo = (message, description) => {
|
|
info({ message, description, placement: 'topRight' });
|
|
};
|
|
|
|
export default notification;
|