Skip to content

Commit c7e9bf0

Browse files
committed
refactor :: 다크테마 컬러 적용
1 parent 3cfa6ba commit c7e9bf0

File tree

3 files changed

+21
-3
lines changed

3 files changed

+21
-3
lines changed

feature/src/main/java/team/aliens/dms/android/feature/voting/VotingModelStudentScreen.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import androidx.compose.foundation.BorderStroke
55
import androidx.compose.foundation.background
66
import androidx.compose.foundation.interaction.MutableInteractionSource
77
import androidx.compose.foundation.interaction.collectIsPressedAsState
8+
import androidx.compose.foundation.isSystemInDarkTheme
89
import androidx.compose.foundation.layout.Arrangement
910
import androidx.compose.foundation.layout.Box
1011
import androidx.compose.foundation.layout.Column
@@ -229,6 +230,11 @@ private fun StudentProfile(
229230
onClick: () -> Unit,
230231
) {
231232
val interactionSource = remember { MutableInteractionSource() }
233+
val color = if (isSystemInDarkTheme()) {
234+
Color.White
235+
} else {
236+
Color.Black
237+
}
232238

233239
HorizontalDivider(
234240
thickness = 1.dp,
@@ -262,7 +268,7 @@ private fun StudentProfile(
262268
Text(
263269
text = "$studentGcn $name",
264270
textAlign = TextAlign.End,
265-
color = Color.Black,
271+
color = color,
266272
)
267273
}
268274
}

feature/src/main/java/team/aliens/dms/android/feature/voting/VotingSelectedScreen.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package team.aliens.dms.android.feature.voting
22

33
import androidx.compose.animation.animateContentSize
44
import androidx.compose.foundation.interaction.MutableInteractionSource
5+
import androidx.compose.foundation.isSystemInDarkTheme
56
import androidx.compose.foundation.layout.Box
67
import androidx.compose.foundation.layout.Column
78
import androidx.compose.foundation.layout.Row
@@ -156,6 +157,11 @@ private fun TopicProfile(
156157
onClick: () -> Unit,
157158
) {
158159
val interactionSource = remember { MutableInteractionSource() }
160+
val color = if (isSystemInDarkTheme()) {
161+
Color.White
162+
} else {
163+
Color.Black
164+
}
159165

160166
HorizontalDivider(
161167
thickness = 1.dp,
@@ -181,7 +187,7 @@ private fun TopicProfile(
181187
Text(
182188
text = topicOption,
183189
textAlign = TextAlign.End,
184-
color = Color.Black,
190+
color = color,
185191
)
186192
}
187193
}

feature/src/main/java/team/aliens/dms/android/feature/voting/VotingStudentScreen.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import androidx.compose.animation.animateContentSize
44
import androidx.compose.foundation.BorderStroke
55
import androidx.compose.foundation.background
66
import androidx.compose.foundation.interaction.MutableInteractionSource
7+
import androidx.compose.foundation.isSystemInDarkTheme
78
import androidx.compose.foundation.layout.Arrangement
89
import androidx.compose.foundation.layout.Box
910
import androidx.compose.foundation.layout.Column
@@ -229,6 +230,11 @@ private fun StudentProfile(
229230
onClick: () -> Unit,
230231
) {
231232
val interactionSource = remember { MutableInteractionSource() }
233+
val color = if (isSystemInDarkTheme()) {
234+
Color.White
235+
} else {
236+
Color.Black
237+
}
232238

233239
HorizontalDivider(
234240
thickness = 1.dp,
@@ -262,7 +268,7 @@ private fun StudentProfile(
262268
Text(
263269
text = "$studentGcn $name",
264270
textAlign = TextAlign.End,
265-
color = Color.Black,
271+
color = color,
266272
)
267273
}
268274
}

0 commit comments

Comments
 (0)