refactor(auth): post-review tidy — drop @NotNull, refresh e2e comment, use oidc.primary
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -52,14 +52,14 @@ export function LoginPage() {
|
||||
if (isAuthenticated) return <Navigate to="/" replace />;
|
||||
if (capsLoading) return null;
|
||||
|
||||
const oidcEnabled = caps?.oidc?.enabled === true;
|
||||
const oidcPrimary = caps?.oidc?.primary === true;
|
||||
const adminRecoveryOnly = caps?.localAccounts?.adminRecoveryOnly === true;
|
||||
const providerName = caps?.oidc?.providerName || 'Single Sign-On';
|
||||
|
||||
// Render decisions
|
||||
const showSsoPrimary = oidcEnabled && adminRecoveryOnly && !forceLocal;
|
||||
const showLocalForm = !oidcEnabled || forceLocal || !adminRecoveryOnly || capsFailed;
|
||||
const showAdminRecoveryBanner = oidcEnabled && adminRecoveryOnly && forceLocal;
|
||||
const showSsoPrimary = oidcPrimary && adminRecoveryOnly && !forceLocal;
|
||||
const showLocalForm = !oidcPrimary || forceLocal || !adminRecoveryOnly || capsFailed;
|
||||
const showAdminRecoveryBanner = oidcPrimary && adminRecoveryOnly && forceLocal;
|
||||
|
||||
const handleSubmit = (e: FormEvent) => {
|
||||
e.preventDefault();
|
||||
|
||||
Reference in New Issue
Block a user