Qix-/color


The issue has been closed
Get luminosity info from array of color #171
rtransat posted onGitHub
Hi,
I need to know if a color is dark or light to display a text in black or white but it seems that is not worked if the color is an array:
const colors = ['#ffffff', '#ffffff', '#ffffff'];
return Color(colors).isLight() ? '#000000' : '#ffffff';
The value returned is #ffffff