@@ -62,14 +62,6 @@ function handleDefaults(contIn, contOut, coerce, opts) {
6262
6363        coerceAxis ( 'uirevision' ,  contOut . uirevision ) ; 
6464
65-         var  dfltColor ; 
66-         var  dfltFontColor ; 
67- 
68-         if ( visible )  { 
69-             dfltColor  =  coerceAxis ( 'color' ) ; 
70-             dfltFontColor  =  ( dfltColor  ===  axIn . color )  ? dfltColor  : opts . font . color ; 
71-         } 
72- 
7365        // We don't want to make downstream code call ax.setScale, 
7466        // as both radial and angular axes don't have a set domain. 
7567        // Furthermore, angular axes don't have a set range. 
@@ -91,18 +83,6 @@ function handleDefaults(contIn, contOut, coerce, opts) {
9183
9284                coerceAxis ( 'range' ) ; 
9385                axOut . cleanRange ( 'range' ,  { dfltRange : [ 0 ,  1 ] } ) ; 
94- 
95-                 if ( visible )  { 
96-                     coerceAxis ( 'side' ) ; 
97-                     coerceAxis ( 'angle' ,  sector [ 0 ] ) ; 
98- 
99-                     coerceAxis ( 'title.text' ) ; 
100-                     Lib . coerceFont ( coerceAxis ,  'title.font' ,  { 
101-                         family : opts . font . family , 
102-                         size : Lib . bigFont ( opts . font . size ) , 
103-                         color : dfltFontColor 
104-                     } ) ; 
105-                 } 
10686                break ; 
10787
10888            case  'angularaxis' :
@@ -142,20 +122,27 @@ function handleDefaults(contIn, contOut, coerce, opts) {
142122        } ) ; 
143123
144124        if ( visible )  { 
125+             var  dfltColor ; 
126+             var  dfltFontColor ; 
127+             var  dfltFontSize ; 
128+             var  dfltFontFamily ; 
129+             var  font  =  opts . font  ||  { } ; 
130+ 
131+             dfltColor  =  coerceAxis ( 'color' ) ; 
132+             dfltFontColor  =  ( dfltColor  ===  axIn . color )  ? dfltColor  : font . color ; 
133+             dfltFontSize  =  font . size ; 
134+             dfltFontFamily  =  font . family ; 
135+ 
145136            handleTickValueDefaults ( axIn ,  axOut ,  coerceAxis ,  axOut . type ) ; 
146-             handleTickLabelDefaults ( axIn ,  axOut ,  coerceAxis ,  axOut . type ) ; 
147-             handleTickMarkDefaults ( axIn ,  axOut ,  coerceAxis ,  { outerTicks : true } ) ; 
137+             handleTickLabelDefaults ( axIn ,  axOut ,  coerceAxis ,  axOut . type ,  { 
138+                 font : { 
139+                     color : dfltFontColor , 
140+                     size : dfltFontSize , 
141+                     family : dfltFontFamily 
142+                 } 
143+             } ) ; 
148144
149-             var  showTickLabels  =  coerceAxis ( 'showticklabels' ) ; 
150-             if ( showTickLabels )  { 
151-                 Lib . coerceFont ( coerceAxis ,  'tickfont' ,  { 
152-                     family : opts . font . family , 
153-                     size : opts . font . size , 
154-                     color : dfltFontColor 
155-                 } ) ; 
156-                 coerceAxis ( 'tickangle' ) ; 
157-                 coerceAxis ( 'tickformat' ) ; 
158-             } 
145+             handleTickMarkDefaults ( axIn ,  axOut ,  coerceAxis ,  { outerTicks : true } ) ; 
159146
160147            handleLineGridDefaults ( axIn ,  axOut ,  coerceAxis ,  { 
161148                dfltColor : dfltColor , 
@@ -170,6 +157,18 @@ function handleDefaults(contIn, contOut, coerce, opts) {
170157            } ) ; 
171158
172159            coerceAxis ( 'layer' ) ; 
160+ 
161+             if ( axName  ===  'radialaxis' )  { 
162+                 coerceAxis ( 'side' ) ; 
163+                 coerceAxis ( 'angle' ,  sector [ 0 ] ) ; 
164+ 
165+                 coerceAxis ( 'title.text' ) ; 
166+                 Lib . coerceFont ( coerceAxis ,  'title.font' ,  { 
167+                     color : dfltFontColor , 
168+                     size : Lib . bigFont ( dfltFontSize ) , 
169+                     family : dfltFontFamily 
170+                 } ) ; 
171+             } 
173172        } 
174173
175174        if ( axType  !==  'category' )  coerceAxis ( 'hoverformat' ) ; 
0 commit comments