diff --git a/app/(auth)/signin/page.tsx b/app/(auth)/signin/page.tsx index 1000d3c..59a3ef6 100644 --- a/app/(auth)/signin/page.tsx +++ b/app/(auth)/signin/page.tsx @@ -1,12 +1,15 @@ "use client" import Link from 'next/link' import React, {useState} from 'react' +import { EyeInvisibleOutlined, EyeOutlined } from '@ant-design/icons' export default function SignIn() { const [inputValue, setInputValue] = useState(''); const [inputFocused, setInputFocused] = useState(false); const [inputPasswordValue, setInputPasswordValue] = useState(''); const [inputPasswordFocused, setInputPasswordFocused] = useState(false); + const [type, setType] = useState("password"); + const handleInputChange = (e: React.ChangeEvent) => { setInputValue(e.target.value); }; @@ -19,6 +22,12 @@ export default function SignIn() { const handleInputPasswordFocus = () => { setInputPasswordFocused(true); }; + const changeStatus = () => { + if (type == "password") + setType("text"); + else + setType("password"); + } return (
@@ -58,7 +67,7 @@ export default function SignIn() { value={inputPasswordValue} onChange={handleInputPasswordChange} onFocus={handleInputPasswordFocus} - type="password" + type={type} className={`w-full border rounded-lg text-black caret-black p-4 m-2 ${inputPasswordFocused && inputPasswordValue === '' ? 'border-red-500':''}`} placeholder="Nhập mật khẩu"> @@ -66,12 +75,26 @@ export default function SignIn() {

Vui lòng nhập mật khẩu

)} +
+ {type == "password" && ( + + )} + {type == "text" && ( + + )} +
+
+ Chưa có tài khoản? + +