Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#211] Error page #212

Merged
merged 2 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added public/error.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions src/app/error.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
'use client';

import { Button } from '@/components/ui/button';
import Image from 'next/image';
import { useRouter } from 'next/navigation';

const Error = () => {
const router = useRouter();

return (
<div className="flex h-[100vh] w-full flex-col items-center justify-center gap-2">
<Image
src={'/error.png'}
height={80}
width={80}
alt="bad"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

error page image 같은 명확한 이름으로 하면 스크린리더기를 사용하는 사용자에게 도움이 될거 같아요!!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

네 반영하겠씁니다

/>
<div className="flex flex-col items-center justify-center">
<p className="font-bold">오류가 발생했습니다.</p>
<p className="text-[#9F9F9F]">이용에 불편을 드려죄송합니다.</p>
</div>

<Button onClick={() => router.replace('/')}>홈으로</Button>
</div>
);
};
export default Error;
Loading