Skip to content

Commit

Permalink
style: ktFormat
Browse files Browse the repository at this point in the history
  • Loading branch information
murjune committed Feb 21, 2025
1 parent 73ee521 commit fa53aef
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ private fun DetailGoalScreen(
onRemoveGoal: (Long) -> Unit,
modifier: Modifier = Modifier,
) {
val (visibleDialog, setVisibleDialog) = rememberSaveable { mutableStateOf(false) }
val (visibleDeleteDialog, setVisibleDeleteDialog) = rememberSaveable { mutableStateOf(false) }

Scaffold(
modifier = modifier,
Expand All @@ -169,7 +169,7 @@ private fun DetailGoalScreen(
navigateToBack = navigateToBack,
actions = {
TextButton(
onClick = { if (uiState.isSuccess) setVisibleDialog(true) },
onClick = { if (uiState.isSuccess) setVisibleDeleteDialog(true) },
colors = ButtonDefaults.textButtonColors().copy(
contentColor = DobeDobeTheme.colors.red,
),
Expand Down Expand Up @@ -213,12 +213,12 @@ private fun DetailGoalScreen(
)

GoalDeleteDialog(
visible = visibleDialog,
visible = visibleDeleteDialog,
onConfirm = {
setVisibleDialog(false)
setVisibleDeleteDialog(false)
onRemoveGoal(goal.id)
},
onDismiss = { setVisibleDialog(false) },
onDismiss = { setVisibleDeleteDialog(false) },
)

GoalCompleteDialog(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ sealed interface DetailGoalUiState {

sealed interface DetailGoalUiEvent {
data object Delete : DetailGoalUiEvent

data object CompleteGoal : DetailGoalUiEvent

data object UnDoGoal : DetailGoalUiEvent
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ private fun DialogTitle() {
}
}


@Composable
private fun DialogCharacter(
characterType: CharacterType,
Expand All @@ -131,7 +130,6 @@ private fun CharacterType.rawRes(): Int = when (this) {
CharacterType.Rabbit -> R.raw.goal_complete_rabbit
}


@ThemePreviews
@Composable
private fun GoalCompleteBirdDialogPreview() {
Expand All @@ -154,4 +152,4 @@ private fun GoalCompleteRabbitDialogPreview() {
onDismissRequest = {},
)
}
}
}

0 comments on commit fa53aef

Please sign in to comment.