From d1687e894bdf304b08ea1a5cfe6e1a7fa40ae744 Mon Sep 17 00:00:00 2001 From: dankito Date: Thu, 5 Sep 2024 02:30:53 +0200 Subject: [PATCH] Extracted VerticalSpacing --- .../kotlin/net/codinux/banking/ui/appskeleton/SideMenu.kt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/appskeleton/SideMenu.kt b/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/appskeleton/SideMenu.kt index 4765392..1842704 100644 --- a/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/appskeleton/SideMenu.kt +++ b/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/appskeleton/SideMenu.kt @@ -48,6 +48,8 @@ private val itemModifier = Modifier.height(ItemHeight).widthIn(min = 350.dp) private val iconSize = 24.dp +private val VerticalSpacing = 12.dp + @Composable fun SideMenu(appContent: @Composable () -> Unit) { @@ -90,7 +92,7 @@ fun SideMenu(appContent: @Composable () -> Unit) { } } - Spacer(Modifier.height(12.dp)) + Spacer(Modifier.height(VerticalSpacing)) NavigationMenuItem(itemModifier, "Konto hinzufügen", textColor, horizontalPadding = ItemHorizontalPadding, icon = { Icon(Icons.Filled.Add, "Konto hinzufügen", Modifier.size(iconSize)) }) { uiState.showAddAccountDialog.value = true @@ -101,7 +103,7 @@ fun SideMenu(appContent: @Composable () -> Unit) { } if (accounts.isNotEmpty()) { - Spacer(Modifier.height(12.dp)) + Spacer(Modifier.height(VerticalSpacing)) NavigationMenuItem(itemModifier, "Neue Überweisung", textColor, horizontalPadding = ItemHorizontalPadding, icon = { Icon(Icons.Filled.Add, "Konto hinzufügen", Modifier.size(iconSize)) }) { uiState.showTransferMoneyDialog.value = true @@ -116,7 +118,7 @@ fun SideMenu(appContent: @Composable () -> Unit) { if (accounts.isNotEmpty()) { Divider(color = Colors.DrawerDivider) - Spacer(Modifier.height(12.dp)) + Spacer(Modifier.height(VerticalSpacing)) NavigationMenuItem(itemModifier, "Daten exportieren", textColor, horizontalPadding = ItemHorizontalPadding, icon = { Icon(Icons.AutoMirrored.Filled.Send, "Konto hinzufügen", Modifier.size(iconSize)) }) { coroutineScope.launch {