From 70121e9a8df24fb68f6be23ad65e0c7a9fcb3ee7 Mon Sep 17 00:00:00 2001 From: kdeus Date: Mon, 25 Nov 2024 11:36:00 -0800 Subject: [PATCH] Hide the top bar, for a cleaner look. (#799) The app looks much cleaner if the top bar blends in with the background (same color) and if we omit the title. Tested by: - Manual testing of several screens. - ./gradlew connectedCheck - ./gradlew check Signed-off-by: Kevin Deus --- .../android/identity_credential/wallet/ui/CommonUI.kt | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/wallet/src/main/java/com/android/identity_credential/wallet/ui/CommonUI.kt b/wallet/src/main/java/com/android/identity_credential/wallet/ui/CommonUI.kt index 6426c1c86..94bef8f14 100644 --- a/wallet/src/main/java/com/android/identity_credential/wallet/ui/CommonUI.kt +++ b/wallet/src/main/java/com/android/identity_credential/wallet/ui/CommonUI.kt @@ -55,14 +55,12 @@ fun ScreenWithAppBar( topBar = { CenterAlignedTopAppBar( colors = TopAppBarDefaults.topAppBarColors( - containerColor = MaterialTheme.colorScheme.primaryContainer, + // The app looks cleaner if the top bar is invisible (same color as the bg). + containerColor = MaterialTheme.colorScheme.background, titleContentColor = MaterialTheme.colorScheme.primary, ), - title = { - Text( - title, maxLines = 1, overflow = TextOverflow.Ellipsis - ) - }, + // The app looks cleaner if we omit the title. + title = {}, navigationIcon = navigationIcon, scrollBehavior = scrollBehavior, actions = actions,