fix(auth): force input remount on mode switch to handle autofill

This commit is contained in:
Reviflow Bot committed 2026-01-31 13:33:18 +01:00
1 parent 7cb6c36d10
commit 7a816c8230
1 file changed
+2
+2
View File
@@ -102,6 +102,7 @@ export const LoginPage = () => {
{isParentMode ? <Mail className="h-5 w-5" /> : <Mail className="h-5 w-5" />}
</div>
<input
key={isParentMode ? "email-input" : "username-input"}
id="identifier"
type={isParentMode ? "email" : "text"}
placeholder={isParentMode ? "michael@exemple.com" : "Nom d'apprenti"}
@@ -121,6 +122,7 @@ export const LoginPage = () => {
<Lock className="h-5 w-5" />
</div>
<input
key={isParentMode ? "password-input" : "pin-input"}
id="password"
type={showPassword ? "text" : "password"}
placeholder={isParentMode ? "••••••••" : "••••"}