MastoSearch/MastoSearchMobile/UIColor+App.swift

22 lines
538 B
Swift
Raw Normal View History

2022-07-03 23:00:17 +00:00
//
// UIColor+App.swift
// MastoSearchMobile
//
// Created by Shadowfacts on 7/3/22.
//
import UIKit
extension UIColor {
static let alternatingTableRow = UIColor { traitCollection in
if traitCollection.userInterfaceStyle == .dark {
return .alternatingTableRowDark
} else {
return .alternatingTableRowLight
}
}
private static let alternatingTableRowDark = UIColor(white: 0.1, alpha: 1)
private static let alternatingTableRowLight = UIColor(white: 0.95, alpha: 1)
}