Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ed6403c

Browse files
committed
make gl2d traces skip over Axes.expand step in heatmap calc
- as it is now called in the convert step - no duplication
1 parent e8337a7 commit ed6403c

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/traces/heatmap/calc.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ module.exports = function calc(gd, trace) {
2929
ya = Axes.getFromId(gd, trace.yaxis || 'y'),
3030
isContour = Plots.traceIs(trace, 'contour'),
3131
isHist = Plots.traceIs(trace, 'histogram'),
32+
isGL2D = Plots.traceIs(trace, 'gl2d'),
3233
zsmooth = isContour ? 'best' : trace.zsmooth,
3334
x,
3435
x0,
@@ -112,8 +113,11 @@ module.exports = function calc(gd, trace) {
112113
yIn = trace.ytype === 'scaled' ? '' : trace.y,
113114
yArray = makeBoundArray(trace, yIn, y0, dy, z.length, ya);
114115

115-
Axes.expand(xa, xArray);
116-
Axes.expand(ya, yArray);
116+
// handler in gl2d convert step
117+
if(!isGL2D) {
118+
Axes.expand(xa, xArray);
119+
Axes.expand(ya, yArray);
120+
}
117121

118122
var cd0 = {x: xArray, y: yArray, z: z};
119123

0 commit comments

Comments
 (0)