feat(settings): Preferences appearance setting

Reuses the existing local Appearance color-scheme picker instead of a
second divergent implementation — this has always been a device-side
preference in this app, not a server-synced one.
This commit is contained in:
2026-08-15 20:30:08 +01:00
parent ba3ede9ae2
commit a4c09f28a0
@@ -245,6 +245,8 @@ struct SettingsView: View {
preferencesSubsection("Display") {
languageRow
Divider()
appearanceRow
}
}
.frame(maxWidth: 480, alignment: .leading)
@@ -292,6 +294,30 @@ struct SettingsView: View {
}
}
/// Same `@AppStorage("outpost.appearance")` binding the standalone
/// Appearance section already uses this is a local-only, device-side
/// preference (matches how this app has always handled it), not a
/// server-synced Outline preference, so it doesn't need its own
/// save call or error state.
private var appearanceRow: some View {
HStack {
VStack(alignment: .leading, spacing: 2) {
Text("Appearance")
Text("Choose your preferred interface colour scheme.")
.font(.caption)
.foregroundStyle(.secondary)
}
Spacer()
Picker("Appearance", selection: $appearance) {
ForEach(AppAppearance.allCases) { option in
Text(option.label).tag(option)
}
}
.labelsHidden()
.frame(width: 200)
}
}
private var languageBinding: Binding<String> {
Binding(
get: { session.userLanguage ?? "en_US" },