Skip to content

erickreutz/UIColorCSSConvertible

Repository files navigation

UIColorCSSConvertible

Create UIColors with CSS strings

var color1: UIColor = "hsla(0,100%,50%,0.2)"
var color2: UIColor = "hsl(0,100%,100%)"
var color3: UIColor = "rgb(255, 255, 255)"
var color4: UIColor = "rgba(255, 255, 255, 0.2)"
var color5: UIColor = "#FF0000"

"#FF0000".CGColor

var label = UILabel(frame: CGRectZero)
label.textColor = "rgb(255, 255, 255)"

About

Create UIColors from CSS colors

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published