github icon

This commit is contained in:
Dallin Romney 2024-11-25 17:00:34 -08:00
parent 093cddb8fe
commit 671335c236
3 changed files with 35 additions and 6 deletions

View file

@ -84,7 +84,7 @@ function App() {
const vscTheme = useVscTheme();
const submenuContextProvidersMethods = useSubmenuContextProviders();
// throw new Error("hahaha");
return (
<VscThemeContext.Provider value={vscTheme}>
<SubmenuContextProvidersContext.Provider

View file

@ -0,0 +1,27 @@
interface GithubIconProps extends React.SVGProps<SVGSVGElement> {
size?: number;
}
export function GithubIcon({
size = 24,
className,
...props
}: GithubIconProps) {
return (
<svg
width={size}
height={size}
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
className={className}
{...props}
>
<path
d="M12 2C6.477 2 2 6.477 2 12c0 4.42 2.865 8.17 6.839 9.49.5.092.682-.217.682-.482 0-.237-.008-.866-.013-1.7-2.782.604-3.369-1.341-3.369-1.341-.454-1.155-1.11-1.462-1.11-1.462-.908-.62.069-.608.069-.608 1.003.07 1.531 1.03 1.531 1.03.892 1.529 2.341 1.087 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.11-4.555-4.943 0-1.091.39-1.984 1.029-2.683-.103-.253-.446-1.27.098-2.647 0 0 .84-.269 2.75 1.025A9.578 9.578 0 0112 6.836c.85.004 1.705.115 2.504.337 1.909-1.294 2.747-1.025 2.747-1.025.546 1.377.203 2.394.1 2.647.64.699 1.028 1.592 1.028 2.683 0 3.842-2.339 4.687-4.566 4.935.359.309.678.919.678 1.852 0 1.336-.012 2.415-.012 2.743 0 .267.18.578.688.48C19.138 20.167 22 16.418 22 12c0-5.523-4.477-10-10-10z"
fill="currentColor"
strokeWidth="0"
/>
</svg>
);
}

View file

@ -3,6 +3,7 @@ import { useNavigate, useRouteError } from "react-router-dom";
import { newSession } from "../redux/slices/stateSlice";
import ContinueButton from "../components/mainInput/ContinueButton";
import { vscBackground } from "../components";
import { GithubIcon } from "../components/svg/Github";
export default function ErrorPage() {
const error: any = useRouteError();
@ -11,17 +12,14 @@ export default function ErrorPage() {
const navigate = useNavigate();
return (
<div
id="error-page"
className="text-center"
style={{ backgroundColor: vscBackground }}
>
<div className="text-center" style={{ backgroundColor: vscBackground }}>
<h1>Error in Continue React App</h1>
<p>
<i>{error.statusText || error.message}</i>
</p>
<br />
<p>Click below to Continue</p>
<GithubIcon />
<br />
<ContinueButton
disabled={false}
@ -29,6 +27,10 @@ export default function ErrorPage() {
onClick={() => {
dispatch(newSession());
localStorage.removeItem("persist:root");
localStorage.removeItem("inputHistory_chat");
// localStorage.removeItem("showTutorialCard");
// localStorage.removeItem("onboardingStatus");
// localStorage.removeItem("lastSessionId");
navigate("/");
}}
></ContinueButton>