You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -842,6 +844,8 @@ HSL Colors: ''hsl()'' and ''hsla()'' functions</h2>
842
844
It is also easier to create sets of matching colors
843
845
(by keeping the hue the same and varying the saturation and lightness).
844
846
847
+
HSL colors resolve to sRGB.
848
+
845
849
<div class='example'>
846
850
For example, the following colors can all be generated off of the basic "green" hue,
847
851
just by varying the other two arguments:
@@ -868,9 +872,9 @@ HSL Colors: ''hsl()'' and ''hsla()'' functions</h2>
868
872
869
873
870
874
<h3 id='hsl-to-rgb'>
871
-
Converting HSL colors to RGB colors</h3>
875
+
Converting HSL colors to sRGB colors</h3>
872
876
873
-
Converting an HSL color to RGB is straightforward mathematically.
877
+
Converting an HSL color to sRGB is straightforward mathematically.
874
878
Here's a simple implementation of the conversion algorithm in JavaScript.
875
879
For simplicity, this algorithm assumes that the hue has been normalized to
876
880
a number in the half-open range [0, 6),
@@ -922,6 +926,8 @@ Examples of HSL colors</h3>
922
926
In each table, the X axis represents the saturation
923
927
while the Y axis represents the lightness.
924
928
929
+
<div class="issue">The conversions in the table below are known to contain errors. They are copied from CSS Color 3, which aso had the same errors. Those colors were supposedly computed by a program in ABC. A future spec will correctly compute those colors. Meanwhile, please note that thses conversions are non-normative examples.</div>
0 commit comments