Function: readableColor()
ts
function readableColor(color): Color;Defined in: readableColor.ts:12
Returns black or white depending on which provides better readability against the given background color.
Parameters
| Parameter | Type | Description |
|---|---|---|
color | Color | the background color |
Returns
#000000 if luminance >= 0.1791, #ffffff otherwise