-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[feat] 로그인페이지, 회원가입 페이지 완성 (예외 로직 보류) (#25)
* feat(#22) : 회원가입 화면에서 headerstate 수정 * file(#22) : star 이미지 common 디렉터리로 이동 * file(#22) : star 이미지 common 디렉터리로 이동 * style(#22) : 헤더 height 변경 * feat(#22) : 원팀시작하기 버튼 생성 * feat(#22) : 이름, 활동지역, 전공, 희망직무 컴포넌트 완료 * feat(#22) : 입력 예외 처리 전 구현 완료 * feat(#22) : 에러 메세지 enum으로 분리 * feat(#22) : 에러 메세지 분리 및 컴포넌트 처ㅣㄹ * feat(#22) : input값 가져오는 로직 구성 * feat(#22-1) : 로그인 로직 변경 * feat(#22) : 로그인 이동 페이지 생성 * style(#22) : 사진 수정 * feat(#22) : 로그인시 headerState 변경 * feat(#22) : 헤더에서 리스트 클릭시 경로 라우팅 설정 및 headerState 설정 * feat(#22) : 헤더 Spacer 설정 * feat(#22) : vercel 배포용 에러 제거 * fix(#22) : api 타입 수정
- Loading branch information
Showing
20 changed files
with
559 additions
and
166 deletions.
There are no files selected for viewing
File renamed without changes
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import styled from 'styled-components'; | ||
|
||
const ErrorMessage = ({ errorText }: { errorText: string }) => { | ||
return <ErrorText>{errorText}</ErrorText>; | ||
}; | ||
const ErrorText = styled.div` | ||
position: absolute; | ||
bottom: -2rem; | ||
left: 12.6rem; | ||
color: ${(props) => props.theme.colors.error60}; | ||
${(props) => props.theme.fonts.bodyXXS}; | ||
`; | ||
export default ErrorMessage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
import styled from 'styled-components'; | ||
import { REGIONS } from '../../constants/Join'; | ||
|
||
const SelectInput = ({ onChangeFunc }: { onChangeFunc: any }) => { | ||
return ( | ||
<SelectContainer> | ||
<Label>활동 지역</Label> | ||
<Select onChange={onChangeFunc} name="region"> | ||
{REGIONS.map((each, idx) => ( | ||
<Option key={idx} value={each}> | ||
{each} | ||
</Option> | ||
))} | ||
</Select> | ||
</SelectContainer> | ||
); | ||
}; | ||
const SelectContainer = styled.div` | ||
width: 100%; | ||
height: 6rem; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
border-radius: 0.5rem; | ||
border: 1px solid ${(props) => props.theme.colors.gray20}; | ||
background-color: white; | ||
padding: 1.4rem 2.4rem; | ||
`; | ||
|
||
const Label = styled.label` | ||
width: 12rem; | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.subtitleL}; | ||
`; | ||
const Select = styled.select` | ||
width: 100%; | ||
/* flex: 1; */ | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.bodyL}; | ||
border: none; | ||
`; | ||
const Option = styled.option` | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.bodyL}; | ||
`; | ||
export default SelectInput; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
import styled from 'styled-components'; | ||
import { InputProps } from '../../interface/Join'; | ||
import React, { useState } from 'react'; | ||
import ErrorMessage from './ErrorMessage'; | ||
|
||
const TextAreaInput = ({ | ||
inputProps, | ||
onChangeFunc, | ||
}: { | ||
inputProps: InputProps; | ||
onChangeFunc: any; | ||
}) => { | ||
const MIN_LENGTH = 10; | ||
const MAX_LENGTH = 140; | ||
const [text, setText] = useState(''); | ||
const handleChange = (event: React.ChangeEvent<HTMLTextAreaElement>) => { | ||
setText(event.target.value); | ||
onChangeFunc(event); | ||
}; | ||
return ( | ||
<InputContainer> | ||
<Label>{inputProps.label}</Label> | ||
<Input | ||
placeholder={inputProps.placeholder} | ||
onChange={handleChange} | ||
minLength={MIN_LENGTH} | ||
maxLength={MAX_LENGTH} | ||
name={inputProps.elemName} | ||
></Input> | ||
<LengthCount> | ||
{text.length}/{MAX_LENGTH} | ||
</LengthCount> | ||
<ErrorMessage errorText={inputProps.errorText} /> | ||
</InputContainer> | ||
); | ||
}; | ||
const InputContainer = styled.div` | ||
position: relative; | ||
width: 100%; | ||
display: flex; | ||
justify-content: center; | ||
/* align-items: center; */ | ||
border-radius: 0.5rem; | ||
border: 1px solid ${(props) => props.theme.colors.gray20}; | ||
background-color: white; | ||
padding: 1.4rem 2.4rem; | ||
`; | ||
|
||
const Label = styled.label` | ||
width: 12rem; | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.subtitleL}; | ||
`; | ||
const Input = styled.textarea` | ||
width: 100%; | ||
min-height: 10rem; | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.bodyL}; | ||
border: none; | ||
resize: none; | ||
`; | ||
const LengthCount = styled.div` | ||
position: absolute; | ||
right: 2rem; | ||
bottom: 2rem; | ||
color: ${(props) => props.theme.colors.gray50}; | ||
${(props) => props.theme.fonts.buttonXXS}; | ||
`; | ||
export default TextAreaInput; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import styled from 'styled-components'; | ||
import { InputProps } from '../../interface/Join'; | ||
import ErrorMessage from './ErrorMessage'; | ||
|
||
const TextInput = ({ | ||
inputProps, | ||
onChangeFunc, | ||
}: { | ||
inputProps: InputProps; | ||
onChangeFunc: any; | ||
}) => { | ||
return ( | ||
<InputContainer> | ||
<Label>{inputProps.label}</Label> | ||
<Input | ||
onChange={onChangeFunc} | ||
type="text" | ||
placeholder={inputProps.placeholder} | ||
name={inputProps.elemName} | ||
></Input> | ||
<ErrorMessage errorText={inputProps.errorText} /> | ||
</InputContainer> | ||
); | ||
}; | ||
const InputContainer = styled.div` | ||
position: relative; | ||
width: 100%; | ||
height: 6rem; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
border-radius: 0.5rem; | ||
border: 1px solid ${(props) => props.theme.colors.gray20}; | ||
background-color: white; | ||
padding: 1.4rem 2.4rem; | ||
`; | ||
|
||
const Label = styled.label` | ||
width: 12rem; | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.subtitleL}; | ||
`; | ||
const Input = styled.input` | ||
width: 100%; | ||
/* flex: 1; */ | ||
color: ${(props) => props.theme.colors.gray80}; | ||
${(props) => props.theme.fonts.bodyL}; | ||
border: none; | ||
`; | ||
export default TextInput; |
Oops, something went wrong.