26 lines
749 B
TypeScript
26 lines
749 B
TypeScript
'use client'
|
|
|
|
export default function Error({
|
|
error,
|
|
reset,
|
|
}: {
|
|
error: Error & { digest?: string }
|
|
reset: () => void
|
|
}) {
|
|
return (
|
|
<div className="min-h-screen flex items-center justify-center bg-gray-50">
|
|
<div className="max-w-md w-full bg-white rounded-lg shadow-md p-6">
|
|
<h2 className="text-xl font-semibold text-gray-900 mb-4">Something went wrong!</h2>
|
|
<p className="text-gray-600 mb-4">
|
|
There was an error loading this page. Please try again.
|
|
</p>
|
|
<button
|
|
onClick={reset}
|
|
className="w-full bg-blue-500 hover:bg-blue-600 text-white font-medium py-2 px-4 rounded-lg transition-colors"
|
|
>
|
|
Try again
|
|
</button>
|
|
</div>
|
|
</div>
|
|
)
|
|
} |