diff --git a/docs/reports/public/assets/report.css b/docs/reports/public/assets/report.css index d609e7d..8fceecb 100644 --- a/docs/reports/public/assets/report.css +++ b/docs/reports/public/assets/report.css @@ -18,7 +18,7 @@ html { body { margin: 7% auto 0; - max-width: 400px; + max-width: 405px; min-height: 180px; padding: 30px 0 15px; } diff --git a/docs/reports/src/view.tsx b/docs/reports/src/view.tsx index f370f94..48a22c0 100644 --- a/docs/reports/src/view.tsx +++ b/docs/reports/src/view.tsx @@ -8,6 +8,27 @@ function formatBytes(value: number | null): string { return `${value}b`; } +function crashDetail(code: string): string { + switch (code) { + case 'SIGSEGV': + case 'EXCEPTION_ACCESS_VIOLATION': + return 'Invalid memory access'; + case 'SIGBUS': + return 'Bus error'; + case 'SIGFPE': + return 'Floating point exception'; + case 'SIGILL': + case 'EXCEPTION_ILLEGAL_INSTRUCTION': + return 'Illegal instruction'; + case 'SIGABRT': + return 'Abort'; + case 'EXCEPTION_STACK_OVERFLOW': + return 'Stack overflow'; + default: + return 'Fatal error'; + } +} + const Shell = ({ title, children }: { title: string; children: Child }) => (
@@ -37,58 +58,62 @@ const BlankPage = () => ( ); -const ReportPage = ({ report, url }: { report: CrashReport; url: string }) => ( -
- {report.reason}.{' '}
-
- {report.code} at {report.addr}
-
-
- Ant crashed and sent a redacted report.
-
- This report URL: {url} -
-+ This report URL: {url} +
+ + ); +}; export function renderBlank(): string { return `${(