Files
ragflow/web/src/layouts/index.tsx
balibabu 08bc5d3521 Feat: Install sonner library #3221 (#6898)
### What problem does this PR solve?

Feat: Install sonner library #3221

### Type of change


- [x] New Feature (non-breaking change which adds functionality)
2025-04-09 17:21:01 +08:00

43 lines
1.0 KiB
TypeScript

import { Divider, Layout, theme } from 'antd';
import React from 'react';
import { Outlet } from 'umi';
import '../locales/config';
import Header from './components/header';
import { Toaster as Sonner } from '@/components/ui/sonner';
import { Toaster } from '@/components/ui/toaster';
import styles from './index.less';
const { Content } = Layout;
const App: React.FC = () => {
const {
token: { colorBgContainer, borderRadiusLG },
} = theme.useToken();
return (
<Layout className={styles.layout}>
<Layout>
<Header></Header>
<Divider orientationMargin={0} className={styles.divider} />
<Content
style={{
minHeight: 280,
background: colorBgContainer,
borderRadius: borderRadiusLG,
overflow: 'auto',
display: 'flex',
}}
>
<Outlet />
</Content>
<Toaster />
<Sonner position={'top-right'} expand richColors closeButton></Sonner>
</Layout>
</Layout>
);
};
export default App;