Skip to content

Commit f68f815

Browse files
authored
일부 디자인 디테일 잡기 (#55)
* refactor : Embed padding within dialog component for consistency * refactor : bubble detail * feat : FillBounds -> Crop
1 parent e22f5bf commit f68f815

File tree

8 files changed

+12
-20
lines changed

8 files changed

+12
-20
lines changed

core/designsystem/src/main/kotlin/com/chipichipi/dobedobe/core/designsystem/component/Bubble.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,10 @@ private fun Path.drawBubbleTail(
124124
// 꼬리 오른쪽 부분 그리기
125125
relativeCubicTo(
126126
dx1 = -13.dp.toPx(),
127-
dy1 = 5.dp.toPx(),
128-
dx2 = 7.dp.toPx(),
127+
dy1 = 10.dp.toPx(),
128+
dx2 = 8.dp.toPx(),
129129
dy2 = 24.dp.toPx(),
130-
dx3 = -11.dp.toPx(),
130+
dx3 = -8.dp.toPx(),
131131
dy3 = tailHeight,
132132
)
133133

@@ -138,9 +138,9 @@ private fun Path.drawBubbleTail(
138138
// 꼬리 왼쪽 부분 그리기
139139
cubicTo(
140140
x1 = x - 14.dp.toPx(),
141-
y1 = y - 4.dp.toPx(),
141+
y1 = y - 8.dp.toPx(),
142142
x2 = x - 9.dp.toPx(),
143-
y2 = height + 3.dp.toPx(),
143+
y2 = height + 2.dp.toPx(),
144144
x3 = tailStartX,
145145
y3 = height,
146146
)

core/designsystem/src/main/kotlin/com/chipichipi/dobedobe/core/designsystem/component/Dialog.kt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ fun DobeDobeDialog(
4242
properties = properties,
4343
) {
4444
Surface(
45-
modifier = modifier,
45+
modifier = modifier
46+
.fillMaxWidth()
47+
.padding(horizontal = 24.dp),
4648
shape = RoundedCornerShape(16.dp),
4749
color = DobeDobeTheme.colors.white,
4850
) {

feature/dashboard/src/main/kotlin/com/chipichipi/dobedobe/feature/dashboard/DashboardScreen.kt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import androidx.compose.animation.core.AnimationVector1D
99
import androidx.compose.animation.core.tween
1010
import androidx.compose.foundation.layout.Box
1111
import androidx.compose.foundation.layout.fillMaxSize
12-
import androidx.compose.foundation.layout.fillMaxWidth
1312
import androidx.compose.foundation.layout.padding
1413
import androidx.compose.foundation.layout.size
1514
import androidx.compose.material3.CircularProgressIndicator
@@ -307,9 +306,6 @@ private fun GoalNotificationPermission(
307306
notificationsPermissionState.launchPermissionRequest()
308307
showGoalNotificationDialog = false
309308
},
310-
modifier = Modifier
311-
.fillMaxWidth()
312-
.padding(horizontal = 24.dp),
313309
)
314310
}
315311
}

feature/dashboard/src/main/kotlin/com/chipichipi/dobedobe/feature/dashboard/component/CollapsedPhotoFrame.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ private fun SharedTransitionScope.CollapsedPhotoFrame(
9494
.rotate(rotation)
9595
.clip(RoundedCornerShape(24.dp))
9696
.clickable(onClick = onToggleExpansion),
97-
contentScale = ContentScale.FillBounds,
97+
contentScale = ContentScale.Crop,
9898
model = uri,
9999
contentDescription = null,
100100
)

feature/dashboard/src/main/kotlin/com/chipichipi/dobedobe/feature/dashboard/component/DashboardViewMode.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ internal fun SharedTransitionScope.DashboardViewMode(
3939
.fillMaxSize()
4040
.paint(
4141
painterResource(id = R.drawable.rabbit_sheet_content_background),
42-
contentScale = ContentScale.FillBounds,
42+
contentScale = ContentScale.Crop,
4343
),
4444
horizontalAlignment = Alignment.CenterHorizontally,
4545
) {

feature/dashboard/src/main/kotlin/com/chipichipi/dobedobe/feature/dashboard/component/EditModePhotoFrame.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ internal fun EditModePhotoFrame(
5858
modifier = Modifier
5959
.fillMaxSize()
6060
.clickable(onClick = onDeletePhoto),
61-
contentScale = ContentScale.FillBounds,
61+
contentScale = ContentScale.Crop,
6262
model = uri,
6363
contentDescription = "photo",
6464
)

feature/dashboard/src/main/kotlin/com/chipichipi/dobedobe/feature/dashboard/component/ExpandedPhotoFrame.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ private fun SharedTransitionScope.ExpandedPhotoFrame(
8585
)
8686
.rotate(rotation)
8787
.clip(RoundedCornerShape(16.dp)),
88-
contentScale = ContentScale.FillBounds,
88+
contentScale = ContentScale.Crop,
8989
model = targetState.uri,
9090
contentDescription = "expanded photo",
9191
)

feature/goal/src/main/kotlin/com/chipichipi/dobedobe/feature/goal/DetailGoalScreen.kt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -219,9 +219,6 @@ private fun DetailGoalContent(
219219
visible = visibleDialog,
220220
onConfirm = onConfirmDialog,
221221
onDismiss = onDismissDialog,
222-
modifier = Modifier
223-
.fillMaxWidth()
224-
.padding(horizontal = 24.dp),
225222
)
226223
}
227224

@@ -252,9 +249,6 @@ private fun DeleteDialogPreview() {
252249
visible = true,
253250
onConfirm = {},
254251
onDismiss = {},
255-
modifier = Modifier
256-
.fillMaxWidth()
257-
.padding(horizontal = 24.dp),
258252
)
259253
}
260254
}

0 commit comments

Comments
 (0)