-
Notifications
You must be signed in to change notification settings - Fork 0
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
Chip 구현 #25
base: main
Are you sure you want to change the base?
Chip 구현 #25
Conversation
@yourssu/android-maintainer 이걸로 리뷰어 요청하시면 됩니다! |
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.
깔끔하네요! 첫 PR 수고하셨습니다 👍
fun Chip( | ||
onCheckedChange: (Boolean) -> Unit, | ||
modifier: Modifier = Modifier, | ||
text: 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.
onCheckedChange
에도 기본 값을 두는 게 어떨까요?
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.
호야님 수고많으셨습니다~!! 새해에도 같이 화이팅 해봐요🔥
val iconSize: IconSize = IconSize.XS, | ||
val horizontalPadding: Dp = 12.dp, | ||
val round: Dp = 40.dp |
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.
이 부분이 chip의 사이즈에 영향을 받지 않는 부분이라면 파일 맨 끝에 아래와 같이 명시 하는게 어떠할까요? 상수 값을 따로 뺀다면 sealed class여야 할 이유도 없어 보입니다..! 지금도 너무 좋은 코드지만, 다른 핸디 컴포넌트 구현들과 구조를 맞추는게 좋지 아니할까 싶습니닷..!!
object DialogDefaults {
val dialogWidth = 296.dp
val dialogPadding = 20.dp
val dialogInsidePadding = 16.dp
val dialogButtonSpacing = 8.dp
}
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.
기존에 구현된 컴포넌트 코드를 보니, 사이즈에 따라 타이포나 아이콘 사이즈 등이 달라지는 경우에는 sealed class, 단순 size 구분에는 enum class를 사용한 걸로 파악이 됩니다!
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.
첫 PR 수고하셨습니다!!
onCheckedChange: (Boolean) -> Unit, | ||
modifier: Modifier = Modifier, | ||
text: 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.
기본값이 없는 파라미터(필수 파라미터)의 경우 modifier보다 위에 두는 것을 권장합니다! 기본값이 있는 optional 파라미터는 modifier 밑으로 두면됩니다
onCheckedChange: (Boolean) -> Unit, | |
modifier: Modifier = Modifier, | |
text: String, | |
onCheckedChange: (Boolean) -> Unit, | |
text: String, | |
modifier: Modifier = Modifier, |
Summary
Chip을 구현하였습니다.
Describe your changes