Color.HSL Class
Color provides static methods for color conversion to hsl values.
Y.Color.toHSL('f00'); // hsl(0, 100%, 50%)
Y.Color.toHSLA('rgb(255, 255, 0'); // hsla(60, 100%, 50%, 1)
Item Index
Methods
_hslToRgb
(
String | Array
protected
-
str
-
[toArray]
Parses the HSL string into r, b, g values. Will return an Array of values or an RGB string.
_hueToRGB
(
Number
protected
-
p
-
q
-
hue
Converts the HSL hue to the different channels for RGB
Returns:
Number:
value for requested channel
_rgbToHsl
(
String | Array
protected
-
str
-
[toArray]
Parses the RGB string into h, s, l values. Will return an Array of values or an HSL string.