Horje
How to create HTML HSL Color Values

In HTML, a color can be specified using hue, saturation, and lightness (HSL) in the form:

hsl(hue, saturation, lightness)

Hue is a degree on the color wheel from 0 to 360. 0 is red, 120 is green, and 240 is blue.

Saturation is a percentage value. 0% means a shade of gray, and 100% is the full color.

Lightness is also a percentage value. 0% is black, and 100% is white.


Full Example of HTML HSL Color Values

Learn following and try yourself
index.html
Example: HTML
<!DOCTYPE html>
<html>
<body>

<h1 style="background-color:hsl(0, 100%, 50%);">hsl(0, 100%, 50%)</h1>
<h1 style="background-color:hsl(240, 100%, 50%);">hsl(240, 100%, 50%)</h1>
<h1 style="background-color:hsl(147, 50%, 47%);">hsl(147, 50%, 47%)</h1>
<h1 style="background-color:hsl(300, 76%, 72%);">hsl(300, 76%, 72%)</h1>
<h1 style="background-color:hsl(39, 100%, 50%);">hsl(39, 100%, 50%)</h1>
<h1 style="background-color:hsl(248, 53%, 58%);">hsl(248, 53%, 58%)</h1>

</body>
</html>

Output should be:

Full Example of HTML HSL Color Values





Related Articles
What is HTML HSL and HSLA Colors HTML HSL Colors
How to create HTML HSL Color Values HTML HSL Colors
How to create HTML Saturation Color HTML HSL Colors
How to create HTML Lightness Color HTML HSL Colors
How to create HTML Shades of Gray HTML HSL Colors
How to create HTML HSLA Color Values HTML HSL Colors

Single Articles
Full Example of HTML HSL Color ValuesHTML HSL Colors

Read Full:
HTML HSL Colors
Category:
Web Tutorial
Sub Category:
HTML HSL Colors
Uploaded by:
Admin
Views:
225


Reffered: https://www.w3schools.com/html/tryit.asp?filename=tryhtml_color_hsl