.append("rect")
.attr("x", (d) => this.xScale(d.day))
.attr("y", (d) => this.yScale(d.time))
.attr("width", this.xScale.bandwidth())
.attr("height", this.yScale.bandwidth())
.on("mouseover", this.mouseOverHandler)
.on("mouseleave", this.mouseLeaveHandler)
.style("fill", "white")
.transition(t)
.delay((d, i) => i * 20)
.style("fill", (d) => this.colorRange(d.value));
and defined colorRange:{} and assigned as below:
this.colorRange = d3
.scaleLinear()
.range(["#B7C0FC", "#216BFF"])
.domain([1, 1000]);
},
Anybody can help me on what basis color can be differentiated if values are like 0 and 1