@@ -951,33 +951,33 @@ function formatDate(ax, out, hover, extraPrecision) {
951
951
952
952
function formatLog ( ax , out , hover , extraPrecision , hideexp ) {
953
953
var dtick = ax . dtick ,
954
- base = ax . exponentbase || 10 ,
954
+ exponentbase = ax . exponentbase || 10 ,
955
955
x = out . x ;
956
956
if ( extraPrecision && ( ( typeof dtick !== 'string' ) || dtick . charAt ( 0 ) !== 'L' ) ) dtick = 'L3' ;
957
957
958
958
if ( ax . tickformat || ( typeof dtick === 'string' && dtick . charAt ( 0 ) === 'L' ) ) {
959
- out . text = numFormat ( Math . pow ( base , x ) , ax , hideexp , extraPrecision ) ;
959
+ out . text = numFormat ( Math . pow ( exponentbase , x ) , ax , hideexp , extraPrecision ) ;
960
960
}
961
961
else if ( isNumeric ( dtick ) || ( ( dtick . charAt ( 0 ) === 'D' ) && ( mod ( x + 0.01 , 1 ) < 0.1 ) ) ) {
962
962
if ( [ 'e' , 'E' , 'power' ] . indexOf ( ax . exponentformat ) !== - 1 ) {
963
- base = base === Math . E ? 'e' : base ;
963
+ exponentbase = exponentbase === Math . E ? 'e' : exponentbase ;
964
964
var p = Math . round ( x ) ;
965
965
if ( p === 0 ) out . text = '1' ;
966
- else if ( p === 1 ) out . text = String ( base ) ;
967
- else if ( p > 1 ) out . text = base + '<sup>' + p + '</sup>' ;
968
- else out . text = base + '<sup>\u2212' + - p + '</sup>' ;
966
+ else if ( p === 1 ) out . text = String ( exponentbase ) ;
967
+ else if ( p > 1 ) out . text = exponentbase + '<sup>' + p + '</sup>' ;
968
+ else out . text = exponentbase + '<sup>\u2212' + - p + '</sup>' ;
969
969
970
970
out . fontSize *= 1.25 ;
971
971
}
972
972
else {
973
- out . text = numFormat ( Math . pow ( base , x ) , ax , '' , 'fakehover' ) ;
973
+ out . text = numFormat ( Math . pow ( exponentbase , x ) , ax , '' , 'fakehover' ) ;
974
974
if ( dtick === 'D1' && ax . _id . charAt ( 0 ) === 'y' ) {
975
975
out . dy -= out . fontSize / 6 ;
976
976
}
977
977
}
978
978
}
979
979
else if ( dtick . charAt ( 0 ) === 'D' ) {
980
- out . text = String ( Math . round ( Math . pow ( base , mod ( x , 1 ) ) ) ) ;
980
+ out . text = String ( Math . round ( Math . pow ( exponentbase , mod ( x , 1 ) ) ) ) ;
981
981
out . fontSize *= 0.75 ;
982
982
}
983
983
else throw 'unrecognized dtick ' + String ( dtick ) ;
0 commit comments