next.js搭建路由01
This commit is contained in:
21
crop-x/src/app/not-found.tsx
Normal file
21
crop-x/src/app/not-found.tsx
Normal file
@@ -0,0 +1,21 @@
|
||||
export default function NotFound() {
|
||||
return (
|
||||
<div className="min-h-screen flex items-center justify-center bg-gradient-to-br from-gray-50 via-blue-50 to-green-50">
|
||||
<div className="text-center">
|
||||
<h1 className="text-6xl font-bold text-gray-800 mb-4">404</h1>
|
||||
<h2 className="text-2xl font-semibold text-gray-700 mb-4">
|
||||
页面未找到
|
||||
</h2>
|
||||
<p className="text-gray-600 mb-8">
|
||||
抱歉,您访问的页面不存在
|
||||
</p>
|
||||
<a
|
||||
href="/"
|
||||
className="px-4 py-2 bg-green-600 text-white rounded-md hover:bg-green-700 transition-colors"
|
||||
>
|
||||
返回首页
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user