Files
ragflow/web/src/pages/404.tsx
chanx a8a060676a Refactor: UmiJs -> Vite (#12410)
### What problem does this PR solve?

Refactor: UmiJs -> Vite+React

### Type of change

- [x] Refactoring

---------

Co-authored-by: Liu An <asiro@qq.com>
2026-01-04 19:14:20 +08:00

30 lines
675 B
TypeScript

import { Routes } from '@/routes';
import { history } from '@/utils/simple-history-util';
import { Button, Result } from 'antd';
import { useLocation } from 'react-router';
const NoFoundPage = () => {
const location = useLocation();
return (
<Result
status="404"
title="404"
subTitle="Page not found, please enter a correct address."
extra={
<Button
type="primary"
onClick={() => {
history.push(
location.pathname.startsWith(Routes.Admin) ? Routes.Admin : '/',
);
}}
>
Business
</Button>
}
/>
);
};
export default NoFoundPage;