Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 21, 03:37 UTC
| 1 | 'use client'; |
| 2 | |
| 3 | export default function GlobalError({ |
| 4 | reset, |
| 5 | }: { |
| 6 | error: Error & { digest?: string }; |
| 7 | reset: () => void; |
| 8 | }) { |
| 9 | return ( |
| 10 | <html lang="en"> |
| 11 | <head> |
| 12 | <meta name="viewport" content="width=device-width, initial-scale=1" /> |
| 13 | <style |
| 14 | dangerouslySetInnerHTML={{ |
| 15 | __html: ` |
| 16 | body { margin: 0; font-family: Inter, system-ui, sans-serif; background: #fff; color: #171414; } |
| 17 | .ge-heading { color: rgba(0,0,0,0.1); } |
| 18 | .ge-muted { color: #666; } |
| 19 | .ge-btn-primary { background: #171414; color: #fff; border: none; } |
| 20 | .ge-btn-secondary { background: #fff; color: #171414; border: 1px solid #e5e0df; } |
| 21 | @media (prefers-color-scheme: dark) { |
| 22 | body { background: #131211; color: #e8e4e0; } |
| 23 | .ge-heading { color: rgba(255,255,255,0.1); } |
| 24 | .ge-muted { color: #a8a29e; } |
| 25 | .ge-btn-primary { background: #e8e4e0; color: #1a1815; } |
| 26 | .ge-btn-secondary { background: #1e1d1c; color: #e8e4e0; border-color: #2c2a28; } |
| 27 | } |
| 28 | `, |
| 29 | }} |
| 30 | /> |
| 31 | </head> |
| 32 | <body> |
| 33 | <div style={{ display: 'flex', minHeight: '100vh', flexDirection: 'column', alignItems: 'center', justifyContent: 'center', padding: '1rem' }}> |
| 34 | <h1 className="ge-heading" style={{ fontSize: '6rem', fontWeight: 700, letterSpacing: '-0.05em', margin: 0, lineHeight: 1 }}> |
| 35 | 500 |
| 36 | </h1> |
| 37 | <div style={{ marginTop: '0.5rem', textAlign: 'center', maxWidth: '28rem' }}> |
| 38 | <h2 style={{ fontSize: '1.25rem', fontWeight: 600, margin: 0 }}> |
| 39 | Something went wrong |
| 40 | </h2> |
| 41 | <p className="ge-muted" style={{ marginTop: '0.5rem', fontSize: '0.875rem' }}> |
| 42 | An unexpected error occurred. Try again or head back to the docs. |
| 43 | </p> |
| 44 | </div> |
| 45 | <div style={{ marginTop: '2rem', display: 'flex', gap: '0.75rem' }}> |
| 46 | <button |
| 47 | className="ge-btn-primary" |
| 48 | onClick={reset} |
| 49 | style={{ padding: '0.5rem 1rem', fontSize: '0.875rem', fontWeight: 500, borderRadius: '0.5rem', cursor: 'pointer' }} |
| 50 | > |
| 51 | Try again |
| 52 | </button> |
| 53 | {/* Client-side nav may be broken inside the global error boundary; a full reload is intentional. */} |
| 54 | {/* eslint-disable-next-line nextjs/no-html-link-for-pages */} |
| 55 | <a |
| 56 | className="ge-btn-secondary" |
| 57 | href="/" |
| 58 | style={{ padding: '0.5rem 1rem', fontSize: '0.875rem', fontWeight: 500, borderRadius: '0.5rem', textDecoration: 'none' }} |
| 59 | > |
| 60 | Home |
| 61 | </a> |
| 62 | </div> |
| 63 | </div> |
| 64 | </body> |
| 65 | </html> |
| 66 | ); |
| 67 | } |