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

Skip to content

Commit 4008965

Browse files
committed
Cast tick value to String for render
1 parent 450167b commit 4008965

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/plots/cartesian/axes.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1712,8 +1712,8 @@ function formatLog(ax, out, hover, extraPrecision, hideexp) {
17121712
if(['e','E','power'].indexOf(ax.exponentformat)!==-1) {
17131713
base = base === Math.E ? 'e' : base;
17141714
var p = Math.round(x);
1715-
if(p === 0) out.text = 1;
1716-
else if(p === 1) out.text = base;
1715+
if(p === 0) out.text = '1';
1716+
else if(p === 1) out.text = String(base);
17171717
else if(p > 1) out.text = base + '<sup>' + p + '</sup>';
17181718
else out.text = base + '<sup>\u2212' + -p + '</sup>';
17191719

0 commit comments

Comments
 (0)