diff --git a/src/assets/circle check_.png b/src/assets/circle check_.png new file mode 100644 index 0000000..51445b6 Binary files /dev/null and b/src/assets/circle check_.png differ diff --git a/src/components/login/LoginForm.jsx b/src/components/login/LoginForm.jsx new file mode 100644 index 0000000..7022fa1 --- /dev/null +++ b/src/components/login/LoginForm.jsx @@ -0,0 +1,132 @@ +import styled from "styled-components"; +import CheckIcon from "../../assets/circle check_.png"; +import { useState } from "react"; + +export default function LoginForm() { + const [isChecked, setIsChecked] = useState(false); // 로그인 유지하기 버튼 클릭 상태관리 + const [isError, setIsError] = useState(false); // 에러 상태 관리 + + // 로그인 유지하기 기능 구현 필요 + const handleCheckClick = () => { + setIsChecked(!isChecked); + }; + + // 로그인 버튼 클릭 시 기능 구현 예정 + const handleLoginClick = () => { + // 아이디, 비밀번호 일치하지 않을 떄 error message 구현 + setIsError(true); + }; + + return ( +
+ + + + + + + + + + + + + check + 로그인 상태 유지하기 + + + + {isError && ( + + 아이디(이메일) 또는 비밀번호를 잘못 입력했습니다. 입력하신 내용을 다시 + 확인해주세요. + + )} + + 로그인 +
+ ); +} + +const Label = styled.div` + font-size: 16px; + font-weight: 600; + margin-bottom: 20px; + + span { + color: #ff0000; + } +`; + +const IDContaner = styled.div` + margin-bottom: 75px; +`; + +const Input = styled.input` + width: 866px; + height: 42px; + background-color: #3f424e; + border: none; + border-radius: 6px; + color: #ffffff; + padding: 5px; + + &::placeholder { + color: #ffffff; + font-size: 14px; + font-weight: 400; + padding: 5px; + } +`; + +const PWContainer = styled.div` + margin-bottom: 40px; +`; + +const LoginBtn = styled.button` + width: 877px; + height: 47px; + background-color: #5263ff; + color: #ffffff; + font-size: 15px; + font-weight: 600; + border: none; + border-radius: 6px; + margin-top: 30px; + align-items: center; +`; + +const ErrorMessage = styled.div` + color: #ff0000; + font-size: 15px; + font-weight: 400; + margin-bottom: 20px; +`; + +const CheckContainer = styled.button` + font-size: 15px; + font-weight: 400; + margin-top: 30px; + margin-bottom: 20px; + background-color: transparent; + border: none; + color: ${(props) => (props.isChecked ? "#5263ff" : "inherit")}; +`; + +const Img = styled.img` + margin-right: 10px; + filter: ${(props) => (props.isChecked ? "invert(100%)" : "inherit")}; +`; + +const CheckLabel = styled.label` + display: flex; + align-items: center; + color: ${(props) => (props.isChecked ? "#5263ff" : "inherit")}; +`; diff --git a/src/pages/Login.jsx b/src/pages/Login.jsx index ce4454f..a016c44 100644 --- a/src/pages/Login.jsx +++ b/src/pages/Login.jsx @@ -1,9 +1,25 @@ +import styled from "styled-components"; +import LoginForm from "../components/login/LoginForm"; + const Login = () => { - return ( -
- Login 페이지입니다 -
- ) -} - -export default Login; \ No newline at end of file + return ( + + 로그인 + + + ); +}; + +export default Login; + +const Wrapper = styled.div` + max-width: 900px; + margin: 0 auto; +`; + +const Title = styled.div` + color: #5263ff; + font-size: 40px; + font-weight: 600; + margin-bottom: 30px; +`;