fix: login improvement (#941)

This commit is contained in:
Matri
2023-08-21 21:26:32 +08:00
committed by GitHub
parent e0a48c4972
commit 062e2e915b
2 changed files with 8 additions and 0 deletions

View File

@@ -237,6 +237,10 @@ const NormalForm = () => {
id="password"
value={password}
onChange={e => setPassword(e.target.value)}
onKeyDown={(e) => {
if (e.key === 'Enter')
handleEmailPasswordLogin()
}}
type={showPassword ? 'text' : 'password'}
autoComplete="current-password"
placeholder={t('login.passwordPlaceholder') || ''}
@@ -256,6 +260,7 @@ const NormalForm = () => {
<div className='mb-2'>
<Button
tabIndex={0}
type='primary'
onClick={handleEmailPasswordLogin}
disabled={isLoading}