Skip to content

Commit 35199c6

Browse files
committed
make mock cartesian scale computation marginally simpler
1 parent f547692 commit 35199c6

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/plots/polar/polar.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -337,9 +337,7 @@ proto.mockCartesianAxis = function(fullLayout, polarLayout, opts) {
337337
var sectorBBox = _this.sectorBBox;
338338
var ind = bboxIndices[axId];
339339
var rl = _this.radialAxis._rl;
340-
var radius = _this.radius;
341-
var innerRadius = _this.innerRadius;
342-
var drl = radius * (rl[1] - rl[0]) / (radius - innerRadius);
340+
var drl = (rl[1] - rl[0]) / (1 - polarLayout.hole);
343341
ax.range = [sectorBBox[ind[0]] * drl, sectorBBox[ind[1]] * drl];
344342
};
345343

0 commit comments

Comments
 (0)