From b1cb7d599fd5b92adc0bd81f74f67fefb13dd029 Mon Sep 17 00:00:00 2001 From: maxmoney21m Date: Sun, 12 Mar 2023 20:34:50 +0800 Subject: [PATCH] Make account switcher scrollable --- .idea/deploymentTargetDropDown.xml | 17 ----------------- .../ui/navigation/AccountSwitchBottomSheet.kt | 5 ++++- 2 files changed, 4 insertions(+), 18 deletions(-) delete mode 100644 .idea/deploymentTargetDropDown.xml diff --git a/.idea/deploymentTargetDropDown.xml b/.idea/deploymentTargetDropDown.xml deleted file mode 100644 index 0c0237e9c..000000000 --- a/.idea/deploymentTargetDropDown.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/app/src/main/java/com/vitorpamplona/amethyst/ui/navigation/AccountSwitchBottomSheet.kt b/app/src/main/java/com/vitorpamplona/amethyst/ui/navigation/AccountSwitchBottomSheet.kt index 0f414299e..0541d2351 100644 --- a/app/src/main/java/com/vitorpamplona/amethyst/ui/navigation/AccountSwitchBottomSheet.kt +++ b/app/src/main/java/com/vitorpamplona/amethyst/ui/navigation/AccountSwitchBottomSheet.kt @@ -11,7 +11,9 @@ import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.width +import androidx.compose.foundation.rememberScrollState import androidx.compose.foundation.shape.CircleShape +import androidx.compose.foundation.verticalScroll import androidx.compose.material.Icon import androidx.compose.material.IconButton import androidx.compose.material.MaterialTheme @@ -64,8 +66,9 @@ fun AccountSwitchBottomSheet( val accountUser = accountUserState?.user ?: return var popupExpanded by remember { mutableStateOf(false) } + val scrollState = rememberScrollState() - Column { + Column(modifier = Modifier.verticalScroll(scrollState)) { Row( modifier = Modifier .fillMaxWidth()