CSS outline and border properties for setting color
For modifying the outline color, web developers can use the shorthand outline
property, which lists all outline values (weight, style, and color) separated by gaps or choose the more specific outline-color
property.
Since border sides can all be different, you can use the border-color
property and, in clockwise order, specify the color for each side.
What value can the color property take?
- Color name, e.g.,
yellow
- HEX code, e.g.
#FDC500
- RGB code, e.g.
rgb(253,197,0)
- HSL - specify a HSL value, like
hsl(47, 100%, 50%)
- Transparent