POL-125: Add showPassword state to login form hook
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -11,6 +11,7 @@ export function useLoginForm() {
|
|||||||
|
|
||||||
const [email, setEmail] = useState("");
|
const [email, setEmail] = useState("");
|
||||||
const [password, setPassword] = useState("");
|
const [password, setPassword] = useState("");
|
||||||
|
const [showPassword, setShowPassword] = useState(false);
|
||||||
const [error, setError] = useState("");
|
const [error, setError] = useState("");
|
||||||
|
|
||||||
async function submit(e: React.SyntheticEvent) {
|
async function submit(e: React.SyntheticEvent) {
|
||||||
@@ -24,7 +25,7 @@ export function useLoginForm() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return { email, setEmail, password, setPassword, error, isLoading, submit };
|
return { email, setEmail, password, setPassword, showPassword, setShowPassword, error, isLoading, submit };
|
||||||
}
|
}
|
||||||
|
|
||||||
export function useRegisterForm() {
|
export function useRegisterForm() {
|
||||||
|
|||||||
Reference in New Issue
Block a user