summaryrefslogtreecommitdiff
path: root/Hutch/App/HutchApp.swift
diff options
context:
space:
mode:
Diffstat (limited to 'Hutch/App/HutchApp.swift')
-rw-r--r--Hutch/App/HutchApp.swift5
1 files changed, 5 insertions, 0 deletions
diff --git a/Hutch/App/HutchApp.swift b/Hutch/App/HutchApp.swift
index e65833c..016ddd0 100644
--- a/Hutch/App/HutchApp.swift
+++ b/Hutch/App/HutchApp.swift
@@ -4,12 +4,17 @@ import SwiftUI
struct HutchApp: App {
@State private var appState = AppState()
@State private var networkMonitor = NetworkMonitor()
+ @AppStorage(AppStorageKeys.appTheme) private var appTheme: AppTheme = .system
+ @AppStorage(AppStorageKeys.displayDensity) private var displayDensity: DisplayDensity = .standard
var body: some Scene {
WindowGroup {
RootView()
.environment(appState)
.environment(networkMonitor)
+ .environment(\.displayDensity, displayDensity)
+ .environment(\.defaultMinListRowHeight, displayDensity == .compact ? 36 : 44)
+ .preferredColorScheme(appTheme.colorScheme)
.onOpenURL { url in
if let link = DeepLink(url: url) {
appState.pendingDeepLink = link