- color.hex() now automatically sets the mode to 'rgba' if the colors alpha channel is < 1. so
chroma('rgba(255,0,0,.5)').hex()
will now return"#ff000080"
instead of"#ff0000"
. if this is not what you want, you must explicitly set the mode torgb
using.hex("rgb")
.
- added LRGB interpolation
- passing null as mode in scale.colors will return chroma objects
- added color.clipped
- added chroma.distance
- added chroma.deltaE
- color.set now returns a new chroma instance
- chroma.scale now allows disabling of internal cache
- chroma.average now works with any color mode
- added unit tests for color conversions
- use hex colors as default string representation
- RGB channels are now stored as floats internally for higher precision
- bugfix with cubehelix and constant lightness
- bugfix in chroma.limits quantiles
- bugfix when running scale.colors(1)
- bugfix in hsi2rgb color conversion
- scale.colors() now returns the original colors instead of just min/max range
- added chroma.average for averaging colors
- refactored chroma.scale
- changed behaviour of scale.domain
- added scale.classes
- added scale.padding
- standardized alpha channel construction
- chroma.bezier automatically returns chroma.scale
- added simple color output to chroma.scale().colors()
- numeric interpolation does what it should
- refactored and modularized code base
- changed argument order of Color::interpolate