1. Performance: 25 pages switched from force-dynamic to revalidate=300 (ISR); 2 pages (community, developers) now fully static (SSG) 2. DB indexes: Added @@index on foreign keys for WebsiteArticles, WebsiteArticleReactions, WebsiteArticleComments, WebsiteHelpCenterTickets, WebsiteShopArticles, RadioSongRequests, StaffActivities 3. SEO: Added robots.ts, sitemap.ts, canonical URLs, Open Graph + Twitter Card metadata on root layout and news articles 4. A11Y: Replaced <details>/<summary> dropdowns with accessible button-based NavDropdown (aria-expanded, aria-haspopup, role=menu). MobileNav now uses translated aria-label, aria-expanded, aria-controls, role=menu 5. Code quality: Added try/catch to updateArticle/deleteArticle; deleteArticle now uses prisma. for atomicity 6. CI/CD: Added GitHub Actions workflow (typecheck + test) 7. i18n: Added openMenu/closeMenu keys to all 6 locales 8. Observability: Health endpoint now checks SMTP reachability when configured 9. Loading states: Added loading.tsx for root, admin, and news sections 10. Word filter cache: Added 60s TTL auto-refresh instead of manual cache bust
32 lines
935 B
TypeScript
32 lines
935 B
TypeScript
import { getTranslations } from "next-intl/server";
|
|
import { ContentCard } from "@/components/public/ui";
|
|
import { siteSettings } from "@/lib/services/site-settings";
|
|
|
|
export const revalidate = 300;
|
|
|
|
export default async function MaintenancePage() {
|
|
const t = await getTranslations("pages.maintenance");
|
|
const [hotel, message] = await Promise.all([
|
|
siteSettings.get("hotel_name", "Atom"),
|
|
siteSettings.get(
|
|
"maintenance_message",
|
|
"We are currently performing maintenance. Please check back soon.",
|
|
),
|
|
]);
|
|
|
|
return (
|
|
<main style={{ maxWidth: 560, margin: "2rem auto" }}>
|
|
<ContentCard
|
|
icon="🛠️"
|
|
title={t("title", { hotel: hotel ?? "Atom" })}
|
|
subtitle={t("subtitle")}
|
|
>
|
|
<p style={{ marginTop: 0 }}>{message}</p>
|
|
<p className="muted" style={{ marginBottom: 0 }}>
|
|
{t("staffCanLogIn")}
|
|
</p>
|
|
</ContentCard>
|
|
</main>
|
|
);
|
|
}
|