feat: add chirpy to error page
This commit is contained in:
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 14 KiB |
@@ -10,15 +10,17 @@ export function ErrorPage({ error }: { error: Error }) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<article>
|
<article className="w-full">
|
||||||
<section className="prose mx-auto mb-20 mt-28 max-w-prose px-8 text-2xl transition-all duration-150 ease-linear space-y-2">
|
<section className="mx-auto mt-20 p-6 md:p-10 text-xl transition-all duration-150 ease-linear space-y-2">
|
||||||
|
<div className="grid grid-cols-1 md:grid-cols-2 gap-8">
|
||||||
|
<div>
|
||||||
<Heading as="h2" className="text-text-primary">
|
<Heading as="h2" className="text-text-primary">
|
||||||
This is a little embarrassing...
|
This is a little embarrassing...
|
||||||
</Heading>
|
</Heading>
|
||||||
<P>
|
<P>
|
||||||
We are really sorry but an error occured in the web client that caused
|
We are really sorry but an error occured in the web client that
|
||||||
it to crash. This is not supposed to happen and we are working hard to
|
caused it to crash. This is not supposed to happen and we are
|
||||||
fix it.
|
working hard to fix it.
|
||||||
</P>
|
</P>
|
||||||
<P>
|
<P>
|
||||||
The best way to prevent this from happening again to you or anyone
|
The best way to prevent this from happening again to you or anyone
|
||||||
@@ -37,7 +39,8 @@ export function ErrorPage({ error }: { error: Error }) {
|
|||||||
href={newGithubIssueUrl({
|
href={newGithubIssueUrl({
|
||||||
repoUrl: "https://github.com/meshtastic/web",
|
repoUrl: "https://github.com/meshtastic/web",
|
||||||
template: "bug.yml",
|
template: "bug.yml",
|
||||||
title: "[Bug]: An unhandled error occurred. <Add details here>",
|
title:
|
||||||
|
"[Bug]: An unhandled error occurred. <Add details here>",
|
||||||
logs: error?.stack,
|
logs: error?.stack,
|
||||||
})}
|
})}
|
||||||
>
|
>
|
||||||
@@ -71,10 +74,19 @@ export function ErrorPage({ error }: { error: Error }) {
|
|||||||
</>
|
</>
|
||||||
) : null}
|
) : null}
|
||||||
{!error?.message && !error?.stack ? (
|
{!error?.message && !error?.stack ? (
|
||||||
<pre className=" w-full text-slate-400">{error.toString()}</pre>
|
<pre className=" w-full text-slate-400">
|
||||||
|
{error.toString()}
|
||||||
|
</pre>
|
||||||
) : null}
|
) : null}
|
||||||
</span>
|
</span>
|
||||||
</details>
|
</details>
|
||||||
|
</div>
|
||||||
|
<img
|
||||||
|
src="/images/chirpy.svg"
|
||||||
|
alt="Chripy the Meshtastic error"
|
||||||
|
className="max-w-2/5 aspect-auto place-self-center md:justify-self-start"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</section>
|
</section>
|
||||||
</article>
|
</article>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -1,7 +1,10 @@
|
|||||||
|
import { cn } from "@app/core/utils/cn";
|
||||||
|
|
||||||
export interface PProps {
|
export interface PProps {
|
||||||
children: React.ReactNode;
|
children: React.ReactNode;
|
||||||
|
className?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export const P = ({ children }: PProps) => (
|
export const P = ({ children, className }: PProps) => (
|
||||||
<p className="leading-7 not-first:mt-6">{children}</p>
|
<p className={cn("leading-7 not-first:mt-6", className)}>{children}</p>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user