Skip to content

Commit 3c4f0ff

Browse files
committed
[FIX/#364] UI 코드 리뷰 반영
1 parent fe74e77 commit 3c4f0ff

2 files changed

Lines changed: 14 additions & 21 deletions

File tree

core/designsystem/src/main/java/com/terning/core/designsystem/component/topappbar/TerningBasicTopAppBar.kt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,14 @@ import com.terning.core.designsystem.theme.White
2222
@OptIn(ExperimentalMaterial3Api::class)
2323
@Composable
2424
fun TerningBasicTopAppBar(
25+
modifier: Modifier = Modifier,
2526
title: String = "",
26-
modifier: Modifier,
2727
showBackButton: Boolean = false,
2828
actions: List<@Composable () -> Unit> = emptyList(),
2929
onBackButtonClick: () -> Unit = {},
3030
) {
3131
CenterAlignedTopAppBar(
32+
modifier = modifier,
3233
title = {
3334
Text(
3435
text = title,
@@ -46,7 +47,7 @@ fun TerningBasicTopAppBar(
4647
Icon(
4748
painter = painterResource(id = R.drawable.ic_back),
4849
contentDescription = stringResource(id = R.string.ic_back),
49-
modifier = modifier
50+
modifier = Modifier
5051
.padding(start = 8.dp)
5152
.noRippleClickable { onBackButtonClick() }
5253
)
@@ -56,7 +57,7 @@ fun TerningBasicTopAppBar(
5657
}
5758
},
5859
actions = {
59-
actions.drop(1).forEach { action ->
60+
actions.forEach { action ->
6061
action()
6162
}
6263
},

feature/intern/src/main/java/com/terning/feature/intern/InternRoute.kt

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import androidx.compose.foundation.layout.statusBarsPadding
1212
import androidx.compose.foundation.lazy.LazyColumn
1313
import androidx.compose.foundation.text.selection.SelectionContainer
1414
import androidx.compose.material3.Icon
15-
import androidx.compose.material3.IconButton
1615
import androidx.compose.material3.Text
1716
import androidx.compose.runtime.Composable
1817
import androidx.compose.runtime.LaunchedEffect
@@ -174,24 +173,17 @@ fun InternScreen(
174173
onBackButtonClick = {
175174
navController.popBackStack()
176175
},
177-
actions = listOf(
178-
{},
179-
{
180-
IconButton(
181-
onClick = onClickShareButton
182-
) {
183-
Icon(
184-
painter = painterResource(id = R.drawable.ic_share_32),
185-
contentDescription = null,
186-
modifier = Modifier
187-
.padding(end = 8.dp)
188-
.noRippleClickable {
189-
onClickShareButton()
190-
}
176+
actions = listOf {
177+
Icon(
178+
painter = painterResource(id = R.drawable.ic_share_32),
179+
contentDescription = null,
180+
modifier = Modifier
181+
.padding(end = 8.dp)
182+
.noRippleClickable(
183+
onClick = onClickShareButton
191184
)
192-
}
193-
}
194-
)
185+
)
186+
}
195187
)
196188

197189
LazyColumn(

0 commit comments

Comments
 (0)