Skip to content

Commit

Permalink
fix: checkButton 파라미터 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
easyhz committed Jul 19, 2024
1 parent cc0e90f commit 4eb45ad
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import com.easyhz.noffice.core.design_system.R
Expand All @@ -38,6 +39,7 @@ import com.easyhz.noffice.core.design_system.theme.Grey600
@Composable
fun CheckButton(
modifier: Modifier = Modifier,
textAlign: TextAlign = TextAlign.Start,
text: String,
isComplete: Boolean,
color: CheckButtonDefaults = CheckButtonDefaults.default(),
Expand All @@ -61,7 +63,8 @@ fun CheckButton(
modifier = Modifier.weight(1f),
text = text,
color = if(isComplete) color.completeContentColor else color.incompleteContentColor,
style = Body14
style = Body14,
textAlign = textAlign
)
if ((isComplete && color.completeIconColor != null) || color.incompleteIconColor != null) {
Icon(
Expand Down Expand Up @@ -189,7 +192,7 @@ private fun CheckButtonOrganizationCompletePrev() {

@Preview(group = "checkButton", name = "organization - complete")
@Composable
private fun CheckButtonOrganizationCompletePrev2() {
private fun CheckButtonOrganizationCompleteNullPrev() {
CheckButton(
modifier = Modifier.width(300.dp),
text = "CMC 15th",
Expand Down

0 comments on commit 4eb45ad

Please sign in to comment.