@@ -256,7 +256,7 @@ function drawBulletGauge(gd, plotGroup, cd, opts) {
256256 var bulletLeft = domain . x [ 0 ] ;
257257 var bulletRight = domain . x [ 0 ] + ( domain . x [ 1 ] - domain . x [ 0 ] ) * ( ( trace . _hasNumber || trace . _hasDelta ) ? ( 1 - cn . bulletNumberDomainSize ) : 1 ) ;
258258
259- ax = mockAxis ( gd , trace . gauge . axis , trace . gauge . axis . range ) ;
259+ ax = mockAxis ( gd , trace . gauge . axis ) ;
260260 ax . _id = 'xbulletaxis' ;
261261 ax . domain = [ bulletLeft , bulletRight ] ;
262262 ax . setScale ( ) ;
@@ -567,8 +567,10 @@ function drawNumbers(gd, plotGroup, cd, opts) {
567567 }
568568
569569 function drawBignumber ( ) {
570- // bignumber
571- var bignumberAx = mockAxis ( gd , { tickformat : trace . number . valueformat } ) ;
570+ var bignumberAx = mockAxis ( gd , { tickformat : trace . number . valueformat } , trace . _range ) ;
571+ bignumberAx . setScale ( ) ;
572+ Axes . calcTicks ( bignumberAx ) ;
573+
572574 var fmt = function ( v ) { return Axes . tickText ( bignumberAx , v ) . text ; } ;
573575 var bignumberSuffix = trace . number . suffix ;
574576 var bignumberPrefix = trace . number . prefix ;
@@ -607,8 +609,10 @@ function drawNumbers(gd, plotGroup, cd, opts) {
607609 }
608610
609611 function drawDelta ( ) {
610- // delta
611- var deltaAx = mockAxis ( gd , { tickformat : trace . delta . valueformat } ) ;
612+ var deltaAx = mockAxis ( gd , { tickformat : trace . delta . valueformat } , trace . _range ) ;
613+ deltaAx . setScale ( ) ;
614+ Axes . calcTicks ( deltaAx ) ;
615+
612616 var deltaFmt = function ( v ) { return Axes . tickText ( deltaAx , v ) . text ; } ;
613617 var deltaValue = function ( d ) {
614618 var value = trace . delta . relative ? d . relativeDelta : d . delta ;
@@ -797,34 +801,12 @@ function arcTween(arc, endAngle, newAngle) {
797801function mockAxis ( gd , opts , zrange ) {
798802 var fullLayout = gd . _fullLayout ;
799803
800- var axisIn = {
801- visible : opts . visible ,
804+ var axisIn = Lib . extendFlat ( {
802805 type : 'linear' ,
803806 ticks : 'outside' ,
804807 range : zrange ,
805- tickmode : opts . tickmode ,
806- nticks : opts . nticks ,
807- tick0 : opts . tick0 ,
808- dtick : opts . dtick ,
809- tickvals : opts . tickvals ,
810- ticktext : opts . ticktext ,
811- ticklen : opts . ticklen ,
812- tickwidth : opts . tickwidth ,
813- tickcolor : opts . tickcolor ,
814- showticklabels : opts . showticklabels ,
815- tickfont : opts . tickfont ,
816- tickangle : opts . tickangle ,
817- tickformat : opts . tickformat ,
818- exponentformat : opts . exponentformat ,
819- separatethousands : opts . separatethousands ,
820- showexponent : opts . showexponent ,
821- showtickprefix : opts . showtickprefix ,
822- tickprefix : opts . tickprefix ,
823- showticksuffix : opts . showticksuffix ,
824- ticksuffix : opts . ticksuffix ,
825- title : opts . title ,
826808 showline : true
827- } ;
809+ } , opts ) ;
828810
829811 var axisOut = {
830812 type : 'linear' ,
0 commit comments