Skip to content

Commit

Permalink
chore: lint format manually..
Browse files Browse the repository at this point in the history
  • Loading branch information
murjune committed Jan 23, 2025
1 parent 035851f commit 88b9e37
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 73 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,9 @@ private fun OnboardingScreen(

// TODO : 클릭 시 Goal DB에 저장 필요
DobeDobeTextButton(
modifier =
Modifier
.fillMaxWidth()
.heightIn(54.dp),
modifier = Modifier
.fillMaxWidth()
.heightIn(54.dp),
onClick = completeOnboarding,
) {
// TODO : Writing 수정 필요
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,10 @@ fun DobDobeAsyncImage(

val imageLoader =
rememberAsyncImagePainter(
model =
ImageRequest.Builder(LocalContext.current)
.data(model)
.crossfade(true)
.build(),
model = ImageRequest.Builder(LocalContext.current)
.data(model)
.crossfade(true)
.build(),
contentScale = contentScale,
onState = { state -> imagePainterState = state },
)
Expand All @@ -65,9 +64,11 @@ fun DobDobeAsyncImage(
is AsyncImagePainter.State.Loading -> {
onLoading()
}

is AsyncImagePainter.State.Error -> {
onError()
}

is AsyncImagePainter.State.Empty,
is AsyncImagePainter.State.Success,
-> Unit
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,10 @@ fun DobeDobeTextButton(
onClick = onClick,
modifier = modifier,
enabled = enabled,
colors =
ButtonDefaults.textButtonColors(
contentColor = Color.White,
containerColor = Color.Black,
),
colors = ButtonDefaults.textButtonColors(
contentColor = Color.White,
containerColor = Color.Black,
),
shape = RoundedCornerShape(20.dp),
contentPadding = ButtonDefaults.TextButtonContentPadding,
content = content,
Expand All @@ -52,11 +51,10 @@ fun DobeDobeOutlinedButton(
modifier = modifier,
enabled = enabled,
colors = ButtonDefaults.outlinedButtonColors(),
border =
BorderStroke(
width = 1.dp,
color = MaterialTheme.colorScheme.outline,
),
border = BorderStroke(
width = 1.dp,
color = MaterialTheme.colorScheme.outline,
),
contentPadding = ButtonDefaults.ContentPadding,
content = content,
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@ fun DobeDobeTextField(
state = state,
enabled = enabled,
readOnly = readOnly,
textStyle =
TextStyle(
fontSize = 24.sp,
fontWeight = FontWeight.SemiBold,
),
textStyle = TextStyle(
fontSize = 24.sp,
fontWeight = FontWeight.SemiBold,
),
decorator = { innerTextField ->
Column(
modifier =
Expand All @@ -55,11 +54,10 @@ fun DobeDobeTextField(
)
}
},
keyboardOptions =
KeyboardOptions(
keyboardType = keyboardType,
imeAction = imeAction,
),
keyboardOptions = KeyboardOptions(
keyboardType = keyboardType,
imeAction = imeAction,
),
modifier = modifier,
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,9 @@ private fun GoalBottomSheetHeader() {
fontWeight = FontWeight.SemiBold,
)
IconButton(
modifier =
Modifier
.size(42.dp)
.offset {
IntOffset(x = 12.dp.roundToPx(), y = 0)
},
modifier = Modifier
.size(42.dp)
.offset { IntOffset(x = 12.dp.roundToPx(), y = 0) },
onClick = {},
) {
Icon(
Expand All @@ -95,10 +92,9 @@ private fun GoalBottomSheetBody(
onGoalClicked: (Goal) -> Unit,
) {
LazyColumn(
modifier =
Modifier
.fillMaxWidth()
.requiredHeightIn(min = 200.dp),
modifier = Modifier
.fillMaxWidth()
.requiredHeightIn(min = 200.dp),
// TODO: 최소 높이 조절 필요
verticalArrangement = Arrangement.spacedBy(18.dp),
contentPadding = PaddingValues(horizontal = 24.dp),
Expand All @@ -120,17 +116,16 @@ private fun GoalBottomSheetContentPreview(
) {
var goals by remember { mutableStateOf(pGoals) }
val onGoalDone: (Goal) -> Unit = {
goals =
goals.map { goal ->
if (goal.id == it.id) {
return@map if (goal.state == Goal.State.Done) {
goal.copy(state = Goal.State.Todo)
} else {
goal.copy(state = Goal.State.Done)
}
goals = goals.map { goal ->
if (goal.id == it.id) {
return@map if (goal.state == Goal.State.Done) {
goal.copy(state = Goal.State.Todo)
} else {
goal.copy(state = Goal.State.Done)
}
goal
}
goal
}
}
GoalBottomSheetContent(
goals = goals,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@ fun GoalRow(
onClick = onGoalClicked,
) {
Row(
modifier =
Modifier
.fillMaxWidth()
.padding(start = 15.dp, top = 17.dp, bottom = 18.dp, end = 15.dp),
modifier = Modifier
.fillMaxWidth()
.padding(start = 15.dp, top = 17.dp, bottom = 18.dp, end = 15.dp),
verticalAlignment = Alignment.CenterVertically,
) {
DobeDobeCheckBox(
Expand Down Expand Up @@ -77,35 +76,32 @@ private fun GoalRowPreview() {
DobeDobeTheme {
Column(verticalArrangement = Arrangement.spacedBy(8.dp)) {
GoalRow(
goal =
Goal(
id = 1L,
title = "Todo",
isPinned = false,
state = Goal.State.Todo,
),
goal = Goal(
id = 1L,
title = "Todo",
isPinned = false,
state = Goal.State.Todo,
),
onGoalDone = {},
onGoalClicked = {},
)
GoalRow(
goal =
Goal(
id = 1L,
title = "Done",
isPinned = false,
state = Goal.State.Done,
),
goal = Goal(
id = 1L,
title = "Done",
isPinned = false,
state = Goal.State.Done,
),
onGoalDone = {},
onGoalClicked = {},
)
GoalRow(
goal =
Goal(
id = 1L,
title = "Pinned",
isPinned = true,
state = Goal.State.Done,
),
goal = Goal(
id = 1L,
title = "Pinned",
isPinned = true,
state = Goal.State.Done,
),
onGoalDone = {},
onGoalClicked = {},
)
Expand Down

0 comments on commit 88b9e37

Please sign in to comment.