Some checks failed
CodeQL / Analyze (javascript) (push) Failing after 16s
CodeQL / Analyze (python) (push) Failing after 3s
i18n sync check / check:sync (push) Failing after 3s
React Doctor / react-doctor (push) Failing after 16s
Branch Build CE / Build-Push Admin Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Admin Manifest (push) Has been cancelled
Branch Build CE / Build-Push Web Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Web Manifest (push) Has been cancelled
Branch Build CE / Build-Push Space Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Proxy Manifest (push) Has been cancelled
Branch Build CE / Merge Space Manifest (push) Has been cancelled
Branch Build CE / Prepare AIO Assets (push) Has been cancelled
Branch Build CE / Build Setup (push) Has been cancelled
Branch Build CE / Build-Push Live Collaboration Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Live Collaboration Manifest (push) Has been cancelled
Branch Build CE / Build-Push API Server Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge API Server Manifest (push) Has been cancelled
Branch Build CE / Build-Push Proxy Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Build-Push AIO Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge AIO Manifest (push) Has been cancelled
Branch Build CE / Upload Build Assets (push) Has been cancelled
Branch Build CE / Build Release (push) Has been cancelled
44 lines
1.7 KiB
TypeScript
44 lines
1.7 KiB
TypeScript
/**
|
|
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
* See the LICENSE file for details.
|
|
*/
|
|
|
|
import { observer } from "mobx-react";
|
|
import { useTheme } from "next-themes";
|
|
import { Button } from "@makeplane/propel/components/button";
|
|
// assets
|
|
import { AuthHeader } from "@/app/(all)/(home)/auth-header";
|
|
import InstanceFailureDarkImage from "@/app/assets/instance/instance-failure-dark.svg?url";
|
|
import InstanceFailureImage from "@/app/assets/instance/instance-failure.svg?url";
|
|
|
|
const handleRetry = () => {
|
|
window.location.reload();
|
|
};
|
|
|
|
export const InstanceFailureView = observer(function InstanceFailureView() {
|
|
const { resolvedTheme } = useTheme();
|
|
|
|
const instanceImage = resolvedTheme === "dark" ? InstanceFailureDarkImage : InstanceFailureImage;
|
|
|
|
return (
|
|
<>
|
|
<AuthHeader />
|
|
<div className="mt-10 flex w-full flex-grow flex-col items-center justify-center py-6">
|
|
<div className="relative flex w-full max-w-[22.5rem] flex-col gap-6">
|
|
<div className="relative flex flex-col items-center justify-center space-y-4">
|
|
<img src={instanceImage} alt="Instance failure illustration" />
|
|
<h3 className="text-center text-20 font-medium text-on-color">Unable to fetch instance details.</h3>
|
|
<p className="text-center text-14 font-medium">
|
|
We were unable to fetch the details of the instance. Fret not, it might just be a connectivity issue.
|
|
</p>
|
|
</div>
|
|
<div className="flex justify-center">
|
|
<Button variant="primary" size="md" stretch="auto" onClick={handleRetry} label="Retry" />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</>
|
|
);
|
|
});
|