Skip to content

Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.

🔥 Remove language and theme switchers from auth layout (#2992)

Luke Vellae66650003d32
diff --git a/apps/web/src/app/[locale]/(auth)/components/auth-footer.tsx b/apps/web/src/app/[locale]/(auth)/components/auth-footer.tsx
deleted file mode 100644
index ee935eb58..000000000
--- a/apps/web/src/app/[locale]/(auth)/components/auth-footer.tsx
+++ /dev/null
@@ -1,29 +0,0 @@
-"use client";
-
-import { useRouter } from "next/navigation";
-import { LanguageSelect } from "@/components/language-selector";
-import { ThemeSwitcher } from "@/components/theme-switcher";
-import { useTranslation } from "@/i18n/client";
-import { setLocaleCookie, useLocale } from "@/lib/locale/client";
-
-export function AuthFooter() {
- const { t } = useTranslation();
- const router = useRouter();
- const { locale } = useLocale();
-
- return (
- // h-40 mirrors the header's 160px logo slot so the vertically centered
- // content sits at the true middle of the page
- <footer className="flex items-end justify-center gap-x-4">
- <LanguageSelect
- aria-label={t("language", { defaultValue: "Language" })}
- value={locale}
- onChange={(language) => {
- setLocaleCookie(language);
- router.refresh();
- }}
- />
- <ThemeSwitcher />
- </footer>
- );
-}
diff --git a/apps/web/src/app/[locale]/(auth)/layout.tsx b/apps/web/src/app/[locale]/(auth)/layout.tsx
index 255addc8f..ecaa57845 100644
--- a/apps/web/src/app/[locale]/(auth)/layout.tsx
+++ b/apps/web/src/app/[locale]/(auth)/layout.tsx
@@ -1,5 +1,5 @@
-import { AuthFooter } from "@/app/[locale]/(auth)/components/auth-footer";
import { Logo } from "@/features/branding/components/logo";
+import { LOGO_VIEWBOX } from "@/features/branding/constants";
import { QuickCreateButton } from "@/features/quick-create/components/quick-create-button";
import { QuickCreateWidget } from "@/features/quick-create/components/quick-create-widget";
import { isQuickCreateEnabled } from "@/features/quick-create/constants";
@@ -41,7 +41,9 @@ export default async function Layout({
<QuickCreateButton />
</div>
) : null}
- <AuthFooter />
+ {/* empty spacer matching the header's logo slot height so the
+ vertically centered content sits at the true middle of the page */}
+ <footer style={{ height: LOGO_VIEWBOX.height }} />
</div>
{isQuickCreateEnabled ? (
<div className="relative hidden flex-1 flex-col justify-center rounded-lg border bg-muted/50 lg:flex lg:p-16">