修改默认404。 #3
1
app/not-found-animation.json
Normal file
1
app/not-found-animation.json
Normal file
File diff suppressed because one or more lines are too long
19
app/not-found.tsx
Normal file
19
app/not-found.tsx
Normal file
@ -0,0 +1,19 @@
|
||||
"use client";
|
||||
import Lottie from "react-lottie";
|
||||
import * as animationData from "./not-found-animation.json";
|
||||
|
||||
export default function NotFound() {
|
||||
return (
|
||||
<div className="not-found" style={{ pointerEvents: "none" }}>
|
||||
<Lottie
|
||||
height={400}
|
||||
width={400}
|
||||
options={{
|
||||
animationData: animationData,
|
||||
loop: true,
|
||||
autoplay: true,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
@ -32,6 +32,7 @@
|
||||
"node-fetch": "^3.3.1",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-lottie": "^1.2.4",
|
||||
"react-markdown": "^8.0.7",
|
||||
"react-router-dom": "^6.15.0",
|
||||
"rehype-highlight": "^6.0.0",
|
||||
|
Loading…
x
Reference in New Issue
Block a user