I started playing with making luminance return a maybe based on whether the alpha channel was opaque or not. This has impacts across the package (grayscale, highContrast, contrast, sufficifientContrast...). Plus API wise it makes me unhappy. It's possible that this means that the opacity needs to be stored separately after all, so that the luminance calculation can easily explicitly not support alpha channel values. Not super happy with that either though
There's no spec, and i don't want to do anything post-render. Sooooooooooo just going to disallow luminance checks unless you're working with opaque colors.
Fixes https://github.com/tesk9/palette/issues/6
Played a bit with how to model this, hence a bajillion commits.
TODO before this merges:
tests/Internal/ColorSpec.elm
/merge back into the main Color spec