graypegg / chromatism

:rainbow: A simple set of utility functions for colours.
1.78k stars 37 forks source link

Problem with hexadecimal #000000 #48

Open Daniel4Digital opened 3 years ago

Daniel4Digital commented 3 years ago

Hi there,

When I try to do a difference between any color and #000000 it gives NaN and not the actual difference.

Daniel4Digital commented 3 years ago

The same with FFFFFF. It gives NaN.

difference('#1E1E1E', '#FFFFFF') difference('#1E1E1E', '#000000')

e-domnenko commented 1 year ago

PR #52 fixes this issue.