[P0-①] Theme follows system + keyboard background transparent
- Split Palette.dark / Palette.light into a ThemePalette struct - Add EnvironmentKey<ThemePalette> + ThemedRoot<Content> - Wrap OSGKeyboardApp root in ThemedRoot so main App follows system - Remove 6 .preferredColorScheme(.dark) overrides from main App views - KeyboardRootView drops its Palette.background fill, uses .background(Color.clear) - Drop the unused 'background' computed property from KeyboardRootView - Legacy 'Palette.xxx' static accessors still resolve to dark values, so 2000 lines of existing call sites stay untouched xcodebuild iOS Simulator: SUCCEEDED
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
// OSGKeyboardApp.swift
|
||||
// OSGKeyboard · Main App
|
||||
//
|
||||
// DEBUG VERSION 2: restore real flow but instrument every step.
|
||||
|
||||
import SwiftUI
|
||||
import OSGKeyboardShared
|
||||
@@ -11,21 +9,22 @@ struct OSGKeyboardApp: App {
|
||||
@StateObject private var config = ProviderConfig.shared
|
||||
|
||||
init() {
|
||||
#if DEBUG
|
||||
print("🔥 [OSGKeyboardApp] init()")
|
||||
#endif
|
||||
}
|
||||
|
||||
var body: some Scene {
|
||||
WindowGroup {
|
||||
Group {
|
||||
if config.isConfigured {
|
||||
HomeView()
|
||||
.onAppear { print("🔥 [OSGKeyboardApp] → HomeView appeared") }
|
||||
} else {
|
||||
OnboardingView(config: config)
|
||||
.onAppear { print("🔥 [OSGKeyboardApp] → OnboardingView appeared") }
|
||||
ThemedRoot {
|
||||
Group {
|
||||
if config.isConfigured {
|
||||
HomeView()
|
||||
} else {
|
||||
OnboardingView(config: config)
|
||||
}
|
||||
}
|
||||
}
|
||||
.onAppear { print("🔥 [OSGKeyboardApp] body appeared") }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user