Conversation
|
Hmm, this still crashes if you try to have a threshold opacity scale, which is a separate but related bug: Plot.cellX(d3.range(10), {fill: "red", opacity: Plot.identity}).plot({opacity: {type: "threshold", legend: true, domain: [1, 2, 3], range: [0.2, 0.4, 0.6, 0.8]}})But also it crashes if you try to display an ordinal opacity scale with a ramp legend, which should be supported (because we can display ordinal color scales with a ramp legend, too): Plot.cellX(d3.range(10), {fill: "red", opacity: Plot.identity}).plot({opacity: {type: "ordinal", legend: "ramp"}}) |
|
Unfortunately it looks like the |
|
Resurrected the SVG filter technique from #2416. 👍 |
|
I decided it’s easier for the ramp & swatches legends to understand opacity scales, rather than trying to have the opacity scale masquerade as a color scale. |
Fixes #2284.