Horje
HTML HSL and HSLA Colors

HSL stands for hue, saturation, and lightness.

HSLA color values are an extension of HSL with an Alpha channel (opacity).

Below is an HSL color. Set different values for Hue, Saturation and Lightness to make different colors.


Full Example of HTML HSL Colors

index.html
Example: HTML
<!DOCTYPE html>
<html>
<head>
<title>HTML HSL Color Example</title>
</head>
<body>
<h1 style="background-color:hsl(0,100%,50%);">Background Color is set by value hsl(0,100%,50%)</h1>
<h1 style="background-color:hsl(160,60%,40%);">Background Color is set by value hsl(160,60%,40%)</h1>
<h1 style="background-color:hsl(260,70%,60%);">Background Color is set by value hsl(260,70%,60%)</h1>
</body>
</html>

Output should be:

Full Example of HTML HSL Colors





Category:
Web Tutorial
Sub Category:
HTML HSL Colors
Uploaded by:
Admin


Read Article
https://horje.com/learn/1434/reference