Ferrite-backup/Ferrite/Views/CommonViews/DynamicAccentColor.swift
kingbri d7d01465d8 Ferrite: WIP iOS 14 backport
Signed-off-by: kingbri <bdashore3@gmail.com>
2022-08-16 14:19:39 -04:00

22 lines
394 B
Swift

//
// dynamicAccentColor.swift
// Ferrite
//
// Created by Brian Dashore on 8/15/22.
//
import SwiftUI
struct DynamicAccentColor: ViewModifier {
let color: Color
func body(content: Content) -> some View {
if #available(iOS 15, *) {
content
.tint(color)
} else {
content
.accentColor(color)
}
}
}