mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-09-07 14:15:44 +00:00
feat: setup posthog
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
/**
|
||||
* Shown when a render error escapes to the app root.
|
||||
*
|
||||
* Before this existed, a render exception unmounted the tree and left the
|
||||
* customer staring at a blank white page with no way forward. The matching
|
||||
* `$exception` is reported by the surrounding PostHogErrorBoundary.
|
||||
*/
|
||||
export function AppErrorFallback() {
|
||||
return (
|
||||
<div className="flex min-h-screen items-center justify-center bg-slate-50 p-6">
|
||||
<div className="w-full max-w-md rounded-xl border border-slate-200 bg-white p-6 shadow-sm">
|
||||
<h2 className="text-lg font-semibold text-slate-900">
|
||||
Something went wrong
|
||||
</h2>
|
||||
<p className="mt-2 text-sm text-slate-600">
|
||||
This page failed to load. The problem has been reported. Try reloading
|
||||
— if it keeps happening, please contact support.
|
||||
</p>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => window.location.reload()}
|
||||
className="mt-4 rounded-lg bg-teal-700 px-4 py-2 text-sm font-medium text-white hover:bg-teal-800"
|
||||
>
|
||||
Reload page
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default AppErrorFallback;
|
||||
Reference in New Issue
Block a user