Skip to content

A full-featured CRM built with React, shadcn/ui, and Supabase.

Remove Forgot password button when email/password authentication is disabled

React-Admin CI42f1ad533149
diff --git a/src/components/atomic-crm/login/LoginPage.tsx b/src/components/atomic-crm/login/LoginPage.tsx
index 4ce0eb4b..7def1317 100644
--- a/src/components/atomic-crm/login/LoginPage.tsx
+++ b/src/components/atomic-crm/login/LoginPage.tsx
@@ -102,12 +102,14 @@ export const LoginPage = (props: { redirectTo?: string }) => {
Sign in with Google Workplace
</SSOAuthButton>
) : null}
- <Link
- to={"/forgot-password"}
- className="block text-sm text-center hover:underline"
- >
- Forgot your password?
- </Link>
+ {disableEmailPasswordAuthentication ? null : (
+ <Link
+ to={"/forgot-password"}
+ className="block text-sm text-center hover:underline"
+ >
+ Forgot your password?
+ </Link>
+ )}
</div>
</div>
</div>