Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 23 additions & 4 deletions src/pages/SignupPage/SignupPage.style.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export const SignupContainer = styled.div`
export const Title = styled.h1`
color: #171A1F;
text-align: center;
font-family: Archivo;
font-family: Pretendard;
font-size: 32px;
font-style: normal;
font-weight: 700;
Expand All @@ -114,7 +114,7 @@ export const Title = styled.h1`
export const Subtitle = styled.h2`
color: #323842;
text-align: center;
font-family: Archivo;
font-family: Pretendard;
font-size: 20px;
font-style: normal;
font-weight: 600;
Expand All @@ -123,6 +123,7 @@ export const Subtitle = styled.h2`

export const FormGroup = styled.div`
margin-bottom: 1rem;
min-width: 400px;
`;

export const Label = styled.label`
Expand Down Expand Up @@ -150,13 +151,14 @@ export const PasswordContainer = styled.div`

export const ToggleVisibility = styled.button`
position: absolute;
right: 10px;
right: 5px;
top: 50%;
transform: translateY(-50%);
background: none;
border: none;
cursor: pointer;
color: #888;
outline: none;
`;

export const SubmitButton = styled.button`
Expand Down Expand Up @@ -218,9 +220,26 @@ export const WalletButton = styled.button`

export const SuccessMessage = styled.h1`
color: #171A1F;
font-family: Archivo;
font-family: Pretendard;
font-size: 32px;
font-style: normal;
font-weight: 700;
line-height: 48px; /* 150% */
`;

export const EyeIcon = styled.div`
position: absolute;
right: 5px;
top: 50%;
transform: translateY(-50%);
cursor: pointer;
color: #777;
outline: none;
`;

export const Form = styled.form`
display: flex;
flex-direction: column;
align-items: center;
width: 100%;
`;
26 changes: 13 additions & 13 deletions src/pages/SignupPage/SignupPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ import {
Main, ProgressBarContainer, Navigation, NavButton, Indicators,
Dot, SignupContainer, Title, Subtitle, FormGroup, Label, Input,
PasswordContainer, ToggleVisibility, SubmitButton, ForgotPassword,
ForgotLink, WalletButton, WalletButtonContainer, WalletContainer, SuccessMessage
ForgotLink, WalletButton, WalletButtonContainer, WalletContainer, SuccessMessage,
EyeIcon, Form
} from './SignupPage.style';

// Component Interfaces
Expand All @@ -37,7 +38,6 @@ const ProgressBar: React.FC<ProgressBarProps> = ({ currentStep, totalSteps }) =>

const SignupForm: React.FC<{ handleNext: () => void; formData: any; setFormData: any }> = ({ handleNext, formData, setFormData }) => {
let navigate = useNavigate();
const [showPassword, setShowPassword] = useState(false);

const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {
const { name, value } = e.target;
Expand All @@ -55,7 +55,7 @@ const SignupForm: React.FC<{ handleNext: () => void; formData: any; setFormData:
<Title>회원가입</Title>
<Subtitle>회원 정보 입력</Subtitle>

<form onSubmit={handleSubmit}>
<Form onSubmit={handleSubmit}>
<FormGroup>
<Label htmlFor="name">이름</Label>
<Input
Expand Down Expand Up @@ -84,7 +84,6 @@ const SignupForm: React.FC<{ handleNext: () => void; formData: any; setFormData:
<Label htmlFor="password">비밀번호</Label>
<PasswordContainer>
<Input
type={showPassword ? "text" : "password"}
id="password"
name="password"
placeholder="비밀번호를 입력해주세요."
Expand All @@ -98,24 +97,25 @@ const SignupForm: React.FC<{ handleNext: () => void; formData: any; setFormData:
<Label htmlFor="confirmPassword">비밀번호 확인</Label>
<PasswordContainer>
<Input
type={showPassword ? "text" : "password"}
id="confirmPassword"
name="confirmPassword"
placeholder="비밀번호를 입력해주세요."
value={formData.confirmPassword}
onChange={handleChange}
/>
<ToggleVisibility
type="button"
onClick={() => setShowPassword(!showPassword)}
>
👁️
<ToggleVisibility >
<EyeIcon>
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2">
<path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"></path>
<circle cx="12" cy="12" r="3"></circle>
</svg>
</EyeIcon>
</ToggleVisibility>
</PasswordContainer>
</FormGroup>

<SubmitButton type="button" onClick={() => {handleNext();}}>다음</SubmitButton>
</form>
</Form>

<ForgotPassword>
이미 계정이 있으신가요?<ForgotLink onClick={() => navigate('/')}>로그인</ForgotLink>
Expand Down Expand Up @@ -178,8 +178,8 @@ const SuccessForm: React.FC<{ formData: any }> = ({ formData }) => {
<img src={SuccessIcon}></img>
<WalletButtonContainer>
<SuccessMessage>
{formData.name}님의 지갑이 <br></br>
연동 완료되었습니다!
{formData.name}님의 지갑 연동이 <br></br>
완료되었습니다!
</SuccessMessage>
</WalletButtonContainer>
</WalletContainer>
Expand Down