update error page
Some checks failed
Deploy App / docker (ubuntu-latest) (push) Has been cancelled

This commit is contained in:
Lee 2024-04-22 02:41:42 +01:00
parent 525b4981fe
commit ffa2db120f

@ -3,6 +3,8 @@
import * as Sentry from "@sentry/nextjs"; import * as Sentry from "@sentry/nextjs";
import Error from "next/error"; import Error from "next/error";
import { useEffect } from "react"; import { useEffect } from "react";
import Link from "next/link";
import { Button } from "@/app/components/ui/button";
export default function GlobalError({ error, reset }: { error: Error & { digest?: string }; reset: () => void }) { export default function GlobalError({ error, reset }: { error: Error & { digest?: string }; reset: () => void }) {
useEffect(() => { useEffect(() => {
@ -10,10 +12,12 @@ export default function GlobalError({ error, reset }: { error: Error & { digest?
}, [error]); }, [error]);
return ( return (
<html> <div className="flex text-center flex-col gap-4">
<body> <div>
<h1>Something shit the fan</h1> <h2 className="text-red-400 font-2xl font-semibold">Error</h2>
</body> <p>An error occurred while rendering this page.</p>
</html> </div>
<Button onClick={reset}>Reload</Button>
</div>
); );
} }