File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -903,10 +903,9 @@ class InputSpinner extends Component {
903903 * @private
904904 */
905905 _getColorPress ( ) {
906- let color = this . props . color ;
907- if ( this . props . colorAsBackground ) {
908- color = defaultTransparent ;
909- }
906+ const color = this . props . colorAsBackground
907+ ? defaultTransparent
908+ : this . props . color ;
910909 return this . props . colorPress !== defaultColor
911910 ? this . props . colorPress
912911 : color ;
@@ -918,12 +917,15 @@ class InputSpinner extends Component {
918917 * @private
919918 */
920919 _getColorPressText ( ) {
920+ const color = this . props . colorAsBackground
921+ ? this . _getColorBackground ( )
922+ : this . _getColorPress ( ) ;
921923 const pressColor = this . props . buttonPressTextColor
922924 ? this . props . buttonPressTextColor
923- : getColorContrast ( this . _getColorPress ( ) ) ;
925+ : this . _getColorText ( ) ;
924926 return this . props . buttonPressTextColor !== this . props . buttonTextColor
925927 ? pressColor
926- : this . _getColorText ( ) ;
928+ : getColorContrast ( color ) ;
927929 }
928930
929931 /**
You can’t perform that action at this time.
0 commit comments