(t1, t2, hue)
| 1798 | return 0; |
| 1799 | }; |
| 1800 | function hue2rgb(t1, t2, hue) { |
| 1801 | if (hue < 0) { |
| 1802 | hue += 1; |
| 1803 | } |
| 1804 | if (hue >= 1) { |
| 1805 | hue -= 1; |
| 1806 | } |
| 1807 | if (hue < 1 / 6) { |
| 1808 | return (t2 - t1) * hue * 6 + t1; |
| 1809 | } |
| 1810 | else if (hue < 1 / 2) { |
| 1811 | return t2; |
| 1812 | } |
| 1813 | else if (hue < 2 / 3) { |
| 1814 | return (t2 - t1) * 6 * (2 / 3 - hue) + t1; |
| 1815 | } |
| 1816 | else { |
| 1817 | return t1; |
| 1818 | } |
| 1819 | } |
| 1820 | var hsl = function (context, args) { |
| 1821 | var tokens = args.filter(nonFunctionArgSeparator); |
| 1822 | var hue = tokens[0], saturation = tokens[1], lightness = tokens[2], alpha = tokens[3]; |
no outgoing calls
no test coverage detected
searching dependent graphs…