Skip to content

Commit

Permalink
add separators and headlines between groups of settings
Browse files Browse the repository at this point in the history
  • Loading branch information
UrAvgCode committed Feb 27, 2025
1 parent 955350c commit 72bce16
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import androidx.compose.foundation.verticalScroll
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.automirrored.filled.ArrowBack
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.HorizontalDivider
import androidx.compose.material3.Icon
import androidx.compose.material3.IconButton
import androidx.compose.material3.MaterialTheme
Expand Down Expand Up @@ -78,9 +79,7 @@ fun SettingsScreen(onNavigateBack: () -> Unit) {
title = {
Text(
text = "Settings",
style = MaterialTheme.typography.titleLarge.copy(
fontSize = 32.sp
)
style = MaterialTheme.typography.titleLarge
)
},
navigationIcon = {
Expand All @@ -100,6 +99,12 @@ fun SettingsScreen(onNavigateBack: () -> Unit) {
.padding(padding)
.padding(16.dp)
) {
Text(
text = "General Settings",
style = MaterialTheme.typography.titleMedium,
modifier = Modifier.padding(vertical = 8.dp)
)

SettingsRowSwitch(
title = "Enable Sound",
isChecked = isSoundEnabled.value,
Expand All @@ -118,6 +123,13 @@ fun SettingsScreen(onNavigateBack: () -> Unit) {
}
)

HorizontalDivider(modifier = Modifier.padding(vertical = 8.dp))
Text(
text = "Display Settings",
style = MaterialTheme.typography.titleMedium,
modifier = Modifier.padding(vertical = 8.dp)
)

SettingsRowSwitch(
title = "Enable Edge-to-Edge",
isChecked = isEdgeToEdgeEnabled.value,
Expand All @@ -139,6 +151,13 @@ fun SettingsScreen(onNavigateBack: () -> Unit) {
steps = 9
)

HorizontalDivider(modifier = Modifier.padding(vertical = 8.dp))
Text(
text = "Circle Lifetimes",
style = MaterialTheme.typography.titleMedium,
modifier = Modifier.padding(vertical = 8.dp)
)

SettingsRowTimeSlider(
title = "Circle Lifetime",
value = circleLifetime.longValue,
Expand Down Expand Up @@ -171,7 +190,6 @@ fun SettingsScreen(onNavigateBack: () -> Unit) {
valueRange = 0L..3000L,
steps = 5,
)

}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,11 @@ val Typography = Typography(
fontSize = 16.sp,
lineHeight = 24.sp,
letterSpacing = 0.5.sp
),
titleLarge = TextStyle(
fontSize = 32.sp
),
titleMedium = TextStyle(
fontSize = 24.sp
)
)

0 comments on commit 72bce16

Please sign in to comment.