Unified · Split
| @@ -167,6 +167,40 @@ function ShellSkeleton() { · 166 unmodified lines | ||
| 167 | 167 | ); |
| 168 | 168 | } |
| 169 | 169 | |
| 170 | +function ShellErrorFallback() { | |
| 171 | + const supportLinks = [ | |
| 172 | + { label: "Discord", href: "https://discord.gg/eF29HBHwM6" }, | |
| 173 | + { label: "GitHub Issues", href: "https://github.com/RhysSullivan/executor/issues" }, | |
| 174 | + { label: "Slack", href: "mailto:rhys@executor.sh?subject=Executor%20Slack%20invite" }, | |
| 175 | + { label: "Email", href: "mailto:rhys@executor.sh?subject=Executor%20support" }, | |
| 176 | + ] as const; | |
| 177 | + | |
| 178 | + return ( | |
| 179 | + <main className="flex min-h-screen items-center justify-center bg-background px-6 py-10"> | |
| 180 | + <section className="w-full max-w-md text-center"> | |
| 181 | + <div className="mx-auto mb-5 flex size-11 items-center justify-center rounded-full border border-border bg-muted"> | |
| 182 | + <span className="text-lg font-semibold text-muted-foreground">!</span> | |
| 183 | + </div> | |
| 184 | + <h1 className="text-xl font-semibold text-foreground">Something went wrong</h1> | |
| 185 | + <p className="mt-2 text-sm leading-6 text-muted-foreground"> | |
| 186 | + We've tracked it. Give refreshing a try, and get in touch if support is needed. | |
| 187 | + </p> | |
| 188 | + <div className="mt-6 flex flex-wrap items-center justify-center gap-x-4 gap-y-2 text-sm"> | |
| 189 | + {supportLinks.map((link) => ( | |
| 190 | + <a | |
| 191 | + key={link.label} | |
| 192 | + href={link.href} | |
| 193 | + className="font-medium text-foreground underline-offset-4 hover:underline" | |
| 194 | + > | |
| 195 | + {link.label} | |
| 196 | + </a> | |
| 197 | + ))} | |
| 198 | + </div> | |
| 199 | + </section> | |
| 200 | + </main> | |
| 201 | + ); | |
| 202 | +} | |
| 203 | + | |
| 170 | 204 | function AuthGate() { |
| 171 | 205 | const auth = useAuth(); |
| 172 | 206 | |
| @@ -184,7 +218,7 @@ function AuthGate() { · 11 unmodified lines | ||
| 184 | 218 | |
| 185 | 219 | return ( |
| 186 | 220 | <AutumnProvider pathPrefix="/api/autumn"> |
| 187 | − <Sentry.ErrorBoundary fallback={<ShellSkeleton />} showDialog={false}> | |
| 221 | + <Sentry.ErrorBoundary fallback={<ShellErrorFallback />} showDialog={false}> | |
| 188 | 222 | <ExecutorProvider fallback={<ShellSkeleton />} onHandledError={captureFrontendError}> |
| 189 | 223 | <ExecutorPluginsProvider plugins={clientPlugins}> |
| 190 | 224 | <Shell /> |