K Merle
03/04/2024, 2:13 PMNavHost
transition working correctly, and second implementation breaks NavHost
animation transition? Note that I am navigation from screen A to screen B, and implementation in thread is screen B.K Merle
03/04/2024, 2:14 PM@Composable
fun FriendRosterScreen(
userFirstAndLastName: String,
navigateBack: () -> Unit
) {
Box(
modifier = Modifier
.fillMaxSize()
)
}
Does not work:
@Composable
fun FriendRosterScreen(
userFirstAndLastName: String,
navigateBack: () -> Unit
) {
Scaffold(
topBar = {
AppSmallTopBar(
title = {
Text(
style = MaterialTheme.typography.titleLarge,
text = userFirstAndLastName,
color = MaterialTheme.colorScheme.onPrimary
)
},
navigationIcon = {
IconButton(onClick = navigateBack) {
Icon(
imageVector = Icons.AutoMirrored.Default.ArrowBack,
contentDescription = stringResource(id = R.string.back_button_content_description),
tint = MaterialTheme.colorScheme.onPrimary
)
}
},
containerColor = MaterialTheme.colorScheme.primary
)
}
) {
Box(
modifier = Modifier
.padding(it)
.fillMaxSize()
)
}
}
Stylianos Gakis
03/04/2024, 4:09 PMfillMaxSize
as the modifier of the Scaffold too, does that change anything?
Also might be worth it to share what exactly it is that does not work besides just that it breaks?K Merle
03/04/2024, 4:12 PMStylianos Gakis
03/04/2024, 4:16 PM