Make system color defined in UIColor/NSColor available to SwiftUI Color
SwiftUIColor
Make system color defined in UIColor
/NSColor
available to SwiftUI Color.
About
In this library, colors are defined in an asset file.
Create an extension file for SwiftUI.Color using the Swift Package Plugin. Files are generated by prebuildCommand.
Usage
- import
import SwiftUIColor
- Use
// iOS system colors Color.iOS.systemBackground // macOS system colors Color.macOS.secondarySystemFillColor