Skip to content

Commit ffa9d42

Browse files
committed
fix ternary domain vertical offset:
- domain[0] set to 0 means to bottom of the plot area, but svg offset are computed from the top
1 parent e0c29f1 commit ffa9d42

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/plots/ternary/ternary.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ proto.adjustLayout = function(ternaryLayout, graphSize) {
203203
yDomainFinal = yDomain * h / hmax;
204204

205205
x0 = graphSize.l + graphSize.w * xDomainCenter - w / 2;
206-
y0 = graphSize.t + graphSize.h * yDomainCenter - h / 2;
206+
y0 = graphSize.t + graphSize.h * (1 - yDomainCenter) - h / 2;
207207

208208
_this.x0 = x0;
209209
_this.y0 = y0;

0 commit comments

Comments
 (0)