ragflow/web/src/components/ui/message.ts
dcc123456 7f707ef5ed
Fix: optimize the chunk result page (#8676)
### What problem does this PR solve?
fix: Create a new message component to replace the antd message
component, create a new Spin component to replace the antd Spin
component, optimize the original paging component style, and optimize
the chunk result page[
#3221](https://github.com/infiniflow/ragflow/issues/3221)

### Type of change

- [X] Bug Fix (non-breaking change which fixes an issue)
2025-07-04 19:00:30 +08:00

29 lines
564 B
TypeScript

import { toast } from 'sonner';
const message = {
success: (msg: string) => {
toast.success(msg, {
position: 'top-center',
closeButton: false,
});
},
error: (msg: string) => {
toast.error(msg, {
position: 'top-center',
closeButton: false,
});
},
warning: (msg: string) => {
toast.warning(msg, {
position: 'top-center',
closeButton: false,
});
},
info: (msg: string) => {
toast.info(msg, {
position: 'top-center',
closeButton: false,
});
},
};
export default message;