summaryrefslogtreecommitdiffhomepage
path: root/android
diff options
context:
space:
mode:
Diffstat (limited to 'android')
-rw-r--r--android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/NavigationComposeCell.kt4
-rw-r--r--android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/SettingsScreen.kt20
2 files changed, 18 insertions, 6 deletions
diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/NavigationComposeCell.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/NavigationComposeCell.kt
index 3edab0bb77..3bb06a35b3 100644
--- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/NavigationComposeCell.kt
+++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/cell/NavigationComposeCell.kt
@@ -60,6 +60,7 @@ fun NavigationComposeCell(
modifier: Modifier = Modifier,
showWarning: Boolean = false,
bodyView: @Composable () -> Unit = { DefaultNavigationView(chevronContentDescription = title) },
+ isRowEnabled: Boolean = true,
onClick: () -> Unit
) {
BaseCell(
@@ -67,7 +68,8 @@ fun NavigationComposeCell(
title = {
NavigationTitleView(title = title, modifier = modifier, showWarning = showWarning)
},
- bodyView = { bodyView() }
+ bodyView = { bodyView() },
+ isRowEnabled = isRowEnabled
)
}
diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/SettingsScreen.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/SettingsScreen.kt
index 54f3223360..d0b460633b 100644
--- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/SettingsScreen.kt
+++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/SettingsScreen.kt
@@ -127,13 +127,23 @@ fun SettingsScreen(
},
bodyView =
@Composable {
- NavigationCellBody(
- content = uiState.appVersion,
- contentBodyDescription = stringResource(id = R.string.app_version),
- isExternalLink = true,
- )
+ if (BuildConfig.BUILD_TYPE != BuildTypes.RELEASE) {
+ NavigationCellBody(
+ content = uiState.appVersion,
+ contentBodyDescription =
+ stringResource(id = R.string.app_version),
+ isExternalLink = true,
+ )
+ } else {
+ Text(
+ text = uiState.appVersion,
+ style = MaterialTheme.typography.labelMedium,
+ color = MaterialTheme.colorScheme.onSecondary
+ )
+ }
},
showWarning = uiState.isUpdateAvailable,
+ isRowEnabled = BuildConfig.BUILD_TYPE != BuildTypes.RELEASE
)
}
if (uiState.isUpdateAvailable) {