d3-color
d3-color copied to clipboard
Color spaces! RGB, HSL, Cubehelix, CIELAB, and more.
Bumps [terser](https://github.com/terser/terser) from 5.12.1 to 5.14.2. Changelog Sourced from terser's changelog. v5.14.2 Security fix for RegExps that should not be evaluated (regexp DDOS) Source maps improvements (#1211) Performance improvements in...
LUV and XYZ.
Per https://github.com/d3/d3-color/issues/33#issuecomment-506914712, d3-color should support CIELUV in addition to CIELAB, and for compatibility with R, should redefine d3.hcl as polar CIELUV, but preserve d3.lch as polar CIELAB. We should also...
`d3.rgb('hsl(120deg, 100%, 50%)') => rgb(0, 0, 0)` `d3.rgb('hsl(120, 100%, 50%)') => rgb(0, 255, 0)` See https://codesandbox.io/s/d3-color-rgb-not-accept-deg-9v8oqm for a repro [CSS Color Module Level 3](https://www.w3.org/TR/2022/REC-css-color-3-20220118/#hsl-color) is a little unclear but seems...
This will fix #61. I made a notebook with a picker for this space [here](https://observablehq.com/@parcly-taxel/the-hwb-colour-model).
https://bottosson.github.io/posts/oklab/ Here's a list of the design choices behind oklab: - Should be an opponent color space, similar to for example CIELAB. - Should predict lightness, chroma and hue well....
Coming in CSS Color Module Level 4: https://www.w3.org/TR/css-color-4/#the-hwb-notation
As defined here: https://www.w3.org/TR/css-color-4/#color-conversion-code https://observablehq.com/@mbostock/lab-and-rgb ```js function rgb_lrgb1(v) { return v
Some new color space: https://www.osapublishing.org/oe/fulltext.cfm?uri=oe-25-13-15131&id=368272 Here python implementation https://github.com/nschloe/colorio Maybe d3 can support it?
In R, *fixup* defaults to TRUE. We need some equivalent to this (but faster, hopefully, at least using binary search): ```js function fixup(c) { while (!c.displayable()) --c.c; return c; }...
For [#51](https://github.com/d3/d3-color/issues/51) Refactors the implementation of the XYZ color space (i.e. CIE XYZ D50) out of `src/lab.js` into its own module, `src/xyz.js`.