1234567891011121314151617181920212223242526 |
- import { Result } from "antd";
- import { useEffect, useRef } from "react";
- export default function NotFound() {
- const timeRef = useRef(-1);
- useEffect(() => {
- timeRef.current = window.setTimeout(() => {
- const dom: HTMLDivElement = document.querySelector(".noFindPage")!;
- dom.style.opacity = "1";
- }, 500);
- return () => {
- clearTimeout(timeRef.current);
- };
- }, []);
- return (
- <div className="noFindPage">
- <Result
- status="404"
- title="404"
- subTitle="找不到页面,或没有权限!"
- />
- </div>
- );
- }
|