Skip to content

Function: lighten() ​

ts
function lighten(color, amount): Color;

Defined in: lighten.ts:14

Lighten a color by a specified amount

Parameters ​

ParameterTypeDescription
colorColorThe color to be lightened
amountnumberThe amount to lighten the color by (0-100)

Returns ​

Color

The lightened color

Throws ​

Invalid Color if the color parameter is not a valid color