mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-17 10:11:31 +10:00
- normalize username and email fields to lowercase, resolves #1740
- add autoComplete attributes to auth flow for easier sign in/sign up
This commit is contained in:
@ -77,6 +77,7 @@ export const BackupOtpPage = () => {
|
||||
<Input
|
||||
pattern="[a-z0-9]{10}"
|
||||
placeholder="a1b2c3d4e5"
|
||||
autoComplete="one-time-code"
|
||||
title={t`Backup Codes may contain only lowercase letters or numbers, and must be exactly 10 characters.`}
|
||||
{...field}
|
||||
/>
|
||||
|
||||
@ -81,7 +81,7 @@ export const ForgotPasswordPage = () => {
|
||||
<FormItem>
|
||||
<FormLabel>{t`Email`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input placeholder="john.doe@example.com" {...field} />
|
||||
<Input placeholder="john.doe@example.com" autoComplete="email" {...field} />
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
</FormItem>
|
||||
|
||||
@ -89,7 +89,12 @@ export const LoginPage = () => {
|
||||
<FormItem>
|
||||
<FormLabel>{t`Email`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input placeholder="john.doe@example.com" {...field} />
|
||||
<Input
|
||||
autoComplete="email"
|
||||
className="lowercase"
|
||||
placeholder="john.doe@example.com"
|
||||
{...field}
|
||||
/>
|
||||
</FormControl>
|
||||
<FormDescription>{t`You can also enter your username.`}</FormDescription>
|
||||
<FormMessage />
|
||||
@ -104,7 +109,7 @@ export const LoginPage = () => {
|
||||
<FormItem>
|
||||
<FormLabel>{t`Password`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input type="password" {...field} />
|
||||
<Input type="password" autoComplete="password" {...field} />
|
||||
</FormControl>
|
||||
<FormDescription>
|
||||
<Trans>
|
||||
|
||||
@ -119,6 +119,7 @@ export const RegisterPage = () => {
|
||||
<FormLabel>{t`Username`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input
|
||||
className="lowercase"
|
||||
placeholder={t({
|
||||
message: "john.doe",
|
||||
context:
|
||||
@ -140,6 +141,7 @@ export const RegisterPage = () => {
|
||||
<FormLabel>{t`Email`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input
|
||||
className="lowercase"
|
||||
placeholder={t({
|
||||
message: "john.doe@example.com",
|
||||
context:
|
||||
|
||||
@ -82,7 +82,7 @@ export const ResetPasswordPage = () => {
|
||||
<FormItem>
|
||||
<FormLabel>{t`Password`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input type="password" {...field} />
|
||||
<Input type="password" autoComplete="new-password" {...field} />
|
||||
</FormControl>
|
||||
<FormDescription>
|
||||
<Trans>
|
||||
|
||||
@ -81,7 +81,7 @@ export const VerifyOtpPage = () => {
|
||||
<FormItem>
|
||||
<FormLabel>{t`One-Time Password`}</FormLabel>
|
||||
<FormControl>
|
||||
<Input placeholder="123456" {...field} />
|
||||
<Input placeholder="123456" autoComplete="one-time-code" {...field} />
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
</FormItem>
|
||||
|
||||
Reference in New Issue
Block a user