pstream is dead; long live pstream
taciturnaxolotl.github.io/pstream-ng/
1import { Helmet } from "react-helmet-async";
2import { useTranslation } from "react-i18next";
3
4import { Button } from "@/components/buttons/Button";
5import { Icons } from "@/components/Icon";
6import { IconPill } from "@/components/layout/IconPill";
7import { Navigation } from "@/components/layout/Navigation";
8import { Title } from "@/components/text/Title";
9import { Paragraph } from "@/components/utils/Text";
10import { ErrorContainer, ErrorLayout } from "@/pages/layouts/ErrorLayout";
11import { maintenanceTime } from "@/setup/App";
12
13type MaintenancePageProps = {
14 onHomeButtonClick: () => void;
15};
16
17function MaintenancePage({ onHomeButtonClick }: MaintenancePageProps) {
18 const { t } = useTranslation();
19
20 return (
21 <div className="relative flex flex-1 flex-col">
22 <Navigation />
23 <Helmet>
24 <title>{t("downtimeNotice.title")}</title>
25 </Helmet>
26 <div className="flex h-full flex-1 flex-col items-center justify-center p-5 text-center">
27 <ErrorLayout>
28 <ErrorContainer>
29 <IconPill icon={Icons.WARNING}>
30 {t("downtimeNotice.badge")}
31 </IconPill>
32 <Title>{t("downtimeNotice.title")}</Title>
33 <Paragraph>{t("downtimeNotice.message")}</Paragraph>
34 <span className="font-bold text-white">{maintenanceTime}</span>
35 <div className="flex gap-3">
36 <Button
37 onClick={onHomeButtonClick}
38 theme="purple"
39 className="mt-6"
40 >
41 {t("downtimeNotice.goHome")}
42 </Button>
43 </div>
44 </ErrorContainer>
45 </ErrorLayout>
46 </div>
47 </div>
48 );
49}
50
51export default MaintenancePage;