Add Medium Light & Dark theme

This commit is contained in:
Thomas Ricouard 2023-01-19 11:58:38 +01:00
parent 7506c33482
commit 47004d00c1
3 changed files with 30 additions and 0 deletions

View file

@ -19,6 +19,8 @@ public enum ColorSetName: String {
case desertLight = "Desert - Light"
case nemesisDark = "Nemesis - Dark"
case nemesisLight = "Nemesis - Light"
case mediumLight = "Medium - Light"
case mediumDark = "Medium - Dark"
}
public struct IceCubeDark: ColorSet {
@ -86,3 +88,25 @@ public struct NemesisLight: ColorSet {
public init() {}
}
public struct MediumDark: ColorSet {
public var name: ColorSetName = .mediumDark
public var scheme: ColorScheme = .dark
public var tintColor: Color = .init(hex: 0x1A8917)
public var primaryBackgroundColor: Color = .init(hex: 0x121212)
public var secondaryBackgroundColor: Color = .init(hex: 0x191919)
public var labelColor: Color = .white
public init() {}
}
public struct MediumLight: ColorSet {
public var name: ColorSetName = .mediumLight
public var scheme: ColorScheme = .light
public var tintColor: Color = .init(hex: 0x1A8917)
public var primaryBackgroundColor: Color = .init(hex: 0xFFFFFF)
public var secondaryBackgroundColor: Color = .init(hex: 0xFAFAFA)
public var labelColor: Color = .black
public init() {}
}

View file

@ -128,6 +128,8 @@ public class Theme: ObservableObject {
DesertLight(),
NemesisDark(),
NemesisLight(),
MediumLight(),
MediumDark(),
]
}

View file

@ -22,6 +22,10 @@ public struct ThemePreviewView: View {
ThemeBoxView(color: NemesisDark())
ThemeBoxView(color: NemesisLight())
}
HStack(spacing: gutterSpace) {
ThemeBoxView(color: MediumDark())
ThemeBoxView(color: MediumLight())
}
}
.padding(4)
.frame(maxHeight: .infinity)