Skip to content

Commit 8e647f3

Browse files
committed
Only set rawColor if color is an array
1 parent 59cc28e commit 8e647f3

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/traces/parcats/calc.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,15 @@ module.exports = function calc(gd, trace) {
8686

8787
// Build color generation function
8888
function getMarkerColorInfo(index) {
89-
var value;
89+
var value, rawColor;
9090
if(Lib.isArrayOrTypedArray(line.color)) {
9191
value = line.color[index % line.color.length];
92+
rawColor = value;
9293
} else {
9394
value = line.color;
9495
}
9596

96-
return {color: markerColorscale(value), rawColor: value};
97+
return {color: markerColorscale(value), rawColor: rawColor};
9798
}
9899

99100
// Number of values and counts

0 commit comments

Comments
 (0)