d3 / d3-scale-chromatic

Sequential, diverging and categorical color scales.
https://d3js.org/d3-scale-chromatic
Other
798 stars 107 forks source link

Swap order of PuOr scheme. #6

Closed jheer closed 7 years ago

jheer commented 7 years ago

Fixes d3/d3-scale-chromatic#5.

Changes:

mbostock commented 7 years ago

Thanks for doing this. I think there might be a couple typos. I ran this quick test:

d3.select("body")
    .text(null)
  .selectAll(".scheme")
  .data(scheme)
  .enter().append("div")
    .attr("class", "scheme")
  .selectAll(".swatch")
  .data(scheme => scheme || [])
  .enter().append("div")
    .attr("class", "swatch")
    .style("display", "inline-block")
    .style("width", "20px")
    .style("height", "20px")
    .style("background-color", color => color);

Before:

screen shot 2017-02-15 at 2 12 36 pm

After:

screen shot 2017-02-15 at 2 12 41 pm
mbostock commented 7 years ago

Okay, fixed! Thank you.