When the second parameter (background color) is darker than the first color, the function seems to calculate the wrong contrast ratio.
Example:
@debug(contrastRatio(#1BA9F5, #1D1E24));
returns
However, every other method of testing contrast says that it is 6.4:




https://snook.ca/technical/colour_contrast/colour.html#fg=1BA9F5,bg=1D1E24
When the second parameter (background color) is darker than the first color, the function seems to calculate the wrong contrast ratio.
Example:
@debug(contrastRatio(#1BA9F5, #1D1E24));returns
However, every other method of testing contrast says that it is
6.4:
https://snook.ca/technical/colour_contrast/colour.html#fg=1BA9F5,bg=1D1E24