import { getSignupMode } from "@/lib/settings";
import { LoginForm } from "@/components/auth/login-form";
import { SignupMode } from "@/lib/generated/prisma/enums";

// Whether to show the "Sign up" link depends on live, admin-editable
// settings -- this can't be prerendered once at build time.
export const dynamic = "force-dynamic";

export default async function LoginPage() {
  const signupMode = await getSignupMode();

  return <LoginForm showSignupLink={signupMode !== SignupMode.CLOSED} />;
}
