Skip to content

Commit 15afd7b

Browse files
authored
Merge pull request #3168 from plotly/fix-scatter-fill-regression
Fix scatter fill regression
2 parents 0a310c9 + 1f3c10c commit 15afd7b

File tree

2 files changed

+6
-13
lines changed

2 files changed

+6
-13
lines changed

src/components/drawing/index.js

+1-7
Original file line numberDiff line numberDiff line change
@@ -198,13 +198,7 @@ drawing.fillGroupStyle = function(s) {
198198
s.style('stroke-width', 0)
199199
.each(function(d) {
200200
var shape = d3.select(this);
201-
try {
202-
shape.call(Color.fill, d[0].trace.fillcolor);
203-
}
204-
catch(e) {
205-
Lib.error(e, s);
206-
shape.remove();
207-
}
201+
shape.call(Color.fill, d[0].trace.fillcolor);
208202
});
209203
};
210204

src/traces/scatter/link_traces.js

+5-6
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,11 @@ module.exports = function linkTraces(gd, plotinfo, cdscatter) {
7575
}
7676
}
7777

78-
if(trace.fill && (
79-
trace.fill.substr(0, 6) === 'tozero' || trace.fill === 'toself' ||
80-
(trace.fill.substr(0, 2) === 'to' && !trace._prevtrace))
81-
) {
82-
trace._ownfill = true;
83-
}
78+
trace._ownfill = (trace.fill && (
79+
trace.fill.substr(0, 6) === 'tozero' ||
80+
trace.fill === 'toself' ||
81+
(trace.fill.substr(0, 2) === 'to' && !trace._prevtrace)
82+
));
8483

8584
prevtraces[group] = trace;
8685
} else {

0 commit comments

Comments
 (0)