mirror of
https://github.com/Dimillian/IceCubesApp.git
synced 2024-06-26 00:50:48 +00:00
15 lines
558 B
Swift
15 lines
558 B
Swift
import SwiftUI
|
|
|
|
public class Theme: ObservableObject {
|
|
enum ThemeKey: String {
|
|
case tint, label, primaryBackground, secondaryBackground
|
|
}
|
|
|
|
@AppStorage(ThemeKey.tint.rawValue) public var tintColor: Color = .brand
|
|
@AppStorage(ThemeKey.primaryBackground.rawValue) public var primaryBackgroundColor: Color = .primaryBackground
|
|
@AppStorage(ThemeKey.secondaryBackground.rawValue) public var secondaryBackgroundColor: Color = .secondaryBackground
|
|
@AppStorage(ThemeKey.label.rawValue) public var labelColor: Color = .label
|
|
|
|
public init() { }
|
|
}
|