- pgSchema "mesh" with 4 tables isolating the peer mesh domain - Enums: visibility, transport, tier, role - audit_log is metadata-only (E2E encryption enforced at broker/client) - Cascade on mesh delete, soft-delete via archivedAt/revokedAt Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
36 lines
797 B
TypeScript
36 lines
797 B
TypeScript
/* eslint-disable i18next/no-literal-string */
|
|
"use client";
|
|
|
|
import { useEffect } from "react";
|
|
|
|
import { captureException } from "@turbostarter/monitoring-web";
|
|
|
|
export default function GlobalError({
|
|
error,
|
|
reset,
|
|
}: {
|
|
error: Error & { digest?: string };
|
|
reset: () => void;
|
|
}) {
|
|
useEffect(() => {
|
|
captureException(error);
|
|
}, [error]);
|
|
|
|
return (
|
|
<html>
|
|
<body>
|
|
<h2>Something went wrong!</h2>
|
|
<p>{error.message}</p>
|
|
{(error.digest ?? error.stack) && (
|
|
<details>
|
|
<summary>More details</summary>
|
|
{error.digest && <p>{error.digest}</p>}
|
|
{error.stack && <pre>{error.stack}</pre>}
|
|
</details>
|
|
)}
|
|
<button onClick={() => reset()}>Try again</button>
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|