-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FE] Input 컴포넌트 리팩터링 #946
base: FE/dev
Are you sure you want to change the base?
[FE] Input 컴포넌트 리팩터링 #946
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고하셨습니다!
수정 사항 남겨놓았으니, 시간날 때 확인해주세요~
@@ -49,8 +52,9 @@ export const Item = styled.li<{ $isChecked: boolean }>` | |||
} | |||
`; | |||
|
|||
export const CustomInputMessage = css` | |||
top: 4rem; | |||
export const Form = styled.form` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
export const Form = styled.form` | |
export const Layout = styled.form` |
width?: string; | ||
height?: string; | ||
borderRadius?: string; | ||
focusColor?: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
여기서 hex값보다는 theme.color를 받는 게 더 좋을 것 같아요!
status = 'DEFAULT', | ||
fontSize = theme.fontSize.sm, | ||
$css, | ||
children, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
status = 'DEFAULT', | |
fontSize = theme.fontSize.sm, | |
$css, | |
children, | |
$css, | |
status = 'DEFAULT', | |
fontSize = theme.fontSize.sm, | |
children, |
props
와 정렬 순서가 같았으면 좋겠어요!
status?: InputStatus; | ||
$css?: ReturnType<typeof css>; | ||
width?: string; | ||
height?: string; | ||
borderRadius?: string; | ||
focusColor?: string; | ||
onReset?: () => void; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
status?: InputStatus; | |
$css?: ReturnType<typeof css>; | |
width?: string; | |
height?: string; | |
borderRadius?: string; | |
focusColor?: string; | |
onReset?: () => void; | |
$css?: ReturnType<typeof css>; | |
status?: InputStatus; | |
width?: string; | |
height?: string; | |
borderRadius?: string; | |
focusColor?: string; | |
onReset?: () => void; |
$css
가 가장 위로 올라갔으면 좋겠어요! (가독성 문제)
onReset?: () => void; | ||
} | ||
|
||
const Input = forwardRef<HTMLInputElement, InputProps>( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
저희 forwardRef
제거하기로 했으니 제거합시다!
$width={width} | ||
$height={height} | ||
$borderRadius={borderRadius} | ||
$focusColor={focusColor} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
그냥 color
로 받아도 되지 않을까요?
연관된 이슈
구현한 기능
#932
상세 설명
색깔이 생각보다 많이 변해서 일단
이렇게 했는데 나중에 맞춰봐요!
Input�이 내부에 속해있는 느낌이라 레이아웃을 Input 으로 네이밍 하는게 약간 어색하다고 생각해서 일단 InputGroup 으로 했습니다. 혹시 더 좋은 네이밍 있으면 말해주세요!!
나머지 내용은 화요일에 가서 자세히 설명해드릴게요