File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed
Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ final class Settings: ObservableObject {
1515 var automaticallyCheckForUpdate : Bool = false
1616 @AppStorage ( SettingsKey . suggestionWidgetPositionMode, store: . shared)
1717 var suggestionWidgetPositionModeRawValue : Int = 0
18+ @AppStorage ( SettingsKey . widgetColorScheme, store: . shared)
19+ var widgetColorScheme : Int = 0
1820 init ( ) { }
1921}
2022
@@ -64,6 +66,21 @@ struct SettingsView: View {
6466 } label: {
6567 Text ( " Widget position " )
6668 }
69+
70+ Picker ( selection: $settings. widgetColorScheme) {
71+ ForEach ( WidgetColorScheme . allCases, id: \. rawValue) {
72+ switch $0 {
73+ case . system:
74+ Text ( " System " )
75+ case . light:
76+ Text ( " Light " )
77+ case . dark:
78+ Text ( " Dark " )
79+ }
80+ }
81+ } label: {
82+ Text ( " Widget color scheme " )
83+ }
6784 }
6885
6986 Toggle ( isOn: $settings. realtimeSuggestionToggle) {
Original file line number Diff line number Diff line change 1- public enum WidgetColorScheme : Int {
1+ public enum WidgetColorScheme : Int , CaseIterable {
22 case system = 0
33 case light = 1
44 case dark = 2
You can’t perform that action at this time.
0 commit comments