Skip to content

Commit

Permalink
implement Button - enabled 파라미터 삭제
Browse files Browse the repository at this point in the history
  • Loading branch information
eshc123 committed Aug 1, 2024
1 parent d3a7b98 commit 6e1a913
Showing 1 changed file with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,11 @@ fun MissionMateTextButton(
modifier: Modifier = Modifier,
buttonType: MissionMateButtonType = MissionMateButtonType.ACTIVE,
textColor: Color = Color(0xFFFFFFFF),
textStyle: TextStyle = MissionMateTypography.body_lg_bold,
enabled: Boolean = true
textStyle: TextStyle = MissionMateTypography.body_lg_bold
) {
MissionMateButton(
modifier = modifier,
buttonType = buttonType,
enabled = enabled,
onClick = onClick
) {
Text(
Expand All @@ -60,14 +58,13 @@ fun MissionMateButton(
onClick: () -> Unit,
modifier: Modifier = Modifier,
buttonType: MissionMateButtonType = MissionMateButtonType.ACTIVE,
enabled: Boolean = true,
shape: Shape = RoundedCornerShape(30.dp),
contentPadding: PaddingValues = PaddingValues(vertical = 18.dp, horizontal = 30.dp),
content: @Composable () -> Unit
) {
Button(
modifier = modifier,
enabled = enabled,
enabled = buttonType != MissionMateButtonType.DISABLED,
shape = shape,
colors = ButtonColors(
containerColor = buttonType.containerColor,
Expand Down Expand Up @@ -110,7 +107,7 @@ fun PreviewTextButtonDisabled(){
MissionMateTextButton(
modifier = Modifier.fillMaxWidth(),
textId = R.string.app_name,
enabled = false,
buttonType = MissionMateButtonType.DISABLED,
onClick = {}
)
}

0 comments on commit 6e1a913

Please sign in to comment.