diff --git a/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SwissTransferTobAppBar.kt b/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SwissTransferTobAppBar.kt index 6818d6436..f5a2171a7 100644 --- a/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SwissTransferTobAppBar.kt +++ b/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SwissTransferTobAppBar.kt @@ -46,7 +46,7 @@ fun SwissTransferTobAppBar( actionIconContentColor = SwissTransferTheme.colors.toolbarIconColor, navigationIconContentColor = SwissTransferTheme.colors.toolbarIconColor, ), - title = { Text(stringResource(id = titleRes)) }, + title = { Text(stringResource(id = titleRes), style = SwissTransferTheme.typography.h2) }, navigationIcon = { navigationMenu?.let { MenuButton(navigationMenu) } }, actions = { actionMenus.forEach { actionMenu -> MenuButton(actionMenu) } }, ) diff --git a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/main/settings/components/OptionScaffold.kt b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/main/settings/components/OptionScaffold.kt index 2ae90d55d..05054d13c 100644 --- a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/main/settings/components/OptionScaffold.kt +++ b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/main/settings/components/OptionScaffold.kt @@ -23,6 +23,7 @@ import androidx.compose.foundation.layout.padding import androidx.compose.foundation.rememberScrollState import androidx.compose.foundation.verticalScroll import androidx.compose.material3.Scaffold +import androidx.compose.material3.adaptive.navigationsuite.NavigationSuiteType import androidx.compose.runtime.Composable import androidx.compose.runtime.getValue import androidx.compose.runtime.mutableIntStateOf @@ -31,6 +32,7 @@ import androidx.compose.runtime.setValue import androidx.compose.ui.Modifier import com.infomaniak.swisstransfer.ui.components.SwissTransferTobAppBar import com.infomaniak.swisstransfer.ui.components.TopAppBarButton +import com.infomaniak.swisstransfer.ui.screen.main.LocalNavType @Composable fun OptionScaffold( @@ -42,8 +44,12 @@ fun OptionScaffold( navigateBack: (() -> Unit)? = null, ) { Scaffold(topBar = { - val canDisplayBackButton = navigateBack?.let { TopAppBarButton.backButton(navigateBack) } - SwissTransferTobAppBar(topAppBarTitleRes, navigationMenu = canDisplayBackButton) + val backNavigationMenu = if (LocalNavType.current == NavigationSuiteType.NavigationBar) { + TopAppBarButton.backButton(navigateBack ?: {}) + } else { + null + } + SwissTransferTobAppBar(topAppBarTitleRes, navigationMenu = backNavigationMenu) }) { paddingsValue -> Column( modifier = Modifier