$font_family[0], 'weight' => astra_get_option( 'font-weight-button' ), ); } /** * Button Font Size */ public function button_font_size() { return ''; } /** * Button Line Height */ public function button_line_height() { return ''; } /** * Default type : Button Font Size * * @since 2.2.0 */ public function default_type_button_font_size() { $font_size_arr = array(); $body_font_size = astra_get_option( 'font-size-body' ); $theme_btn_font_size = astra_get_option( 'font-size-button' ); $font_size_arr['desktop'] = astra_responsive_font( $theme_btn_font_size, 'desktop' ); $font_size_arr['tablet'] = astra_responsive_font( $theme_btn_font_size, 'tablet' ); $font_size_arr['mobile'] = astra_responsive_font( $theme_btn_font_size, 'mobile' ); if ( empty( $font_size_arr['desktop'] ) ) { $font_size_arr['desktop'] = astra_responsive_font( $body_font_size, 'desktop' ); } if ( empty( $font_size_arr['tablet'] ) ) { $font_size_arr['tablet'] = astra_responsive_font( $body_font_size, 'tablet' ); } if ( empty( $font_size_arr['mobile'] ) ) { $font_size_arr['mobile'] = astra_responsive_font( $body_font_size, 'mobile' ); } return $font_size_arr; } /** * Default type : Button Line Height * * @since 2.2.0 */ public function default_type_button_line_height() { $theme_btn_body_line_height = astra_get_option( 'body-line-height', 1.85714285714286 ); $theme_btn_line_height = astra_get_option( 'theme-btn-line-height', $theme_btn_body_line_height ); return $theme_btn_line_height; } /** * Button Letter Spacing */ public function button_letter_spacing() { return ''; } /** * Default type : Button Letter Spacing * * @since 2.2.0 */ public function default_type_button_letter_spacing() { $theme_btn_letter_spacing = astra_get_option( 'theme-btn-letter-spacing' ); return $theme_btn_letter_spacing; } /** * Button Text Transform */ public function button_text_transform() { return ''; } /** * Default type : Button Text Transform * * @since 2.2.0 */ public function default_type_button_text_transform() { $theme_btn_text_transform = astra_get_font_extras( astra_get_option( 'font-extras-button' ), 'text-transform' ); return $theme_btn_text_transform; } /** * Button Text Color */ public function button_text_color() { $theme_color = astra_get_option( 'theme-color' ); $link_color = astra_get_option( 'link-color', $theme_color ); $color = astra_get_option( 'button-color' ); if ( empty( $color ) ) { $color = astra_get_foreground_color( $link_color ); } return $color; } /** * Default type : Button Text Color * * @since 2.2.0 */ public function default_type_button_text_color() { $theme_color = astra_get_option( 'theme-color' ); $btn_text_color = astra_get_option( 'button-color' ); if ( empty( $btn_text_color ) ) { $btn_text_color = astra_get_foreground_color( $theme_color ); } return $btn_text_color; } /** * Button Text Hover Color */ public function button_text_hover_color() { $link_hover_color = astra_get_option( 'link-h-color' ); $btn_text_hover_color = astra_get_option( 'button-h-color' ); if ( empty( $btn_text_hover_color ) ) { $btn_text_hover_color = astra_get_foreground_color( $link_hover_color ); } return $btn_text_hover_color; } /** * Default type : Button Text Hover Color * * @since 2.2.0 */ public function default_type_button_text_hover_color() { $link_hover_color = astra_get_option( 'link-h-color' ); $btn_text_hover_color = astra_get_option( 'button-h-color' ); if ( empty( $btn_text_hover_color ) ) { $btn_text_hover_color = astra_get_foreground_color( $link_hover_color ); } return $btn_text_hover_color; } /** * Button Background Color */ public function button_bg_color() { return astra_get_option( 'button-bg-color' ); } /** * Default type : Button Background Color * * @since 2.2.0 */ public function default_type_button_bg_color() { $theme_color = astra_get_option( 'theme-color' ); $btn_bg_color = astra_get_option( 'button-bg-color', $theme_color ); return $btn_bg_color; } /** * Button Background Color */ public function button_bg_hover_color() { return astra_get_option( 'button-bg-h-color' ); } /** * Default type : Button Background Color * * @since 2.2.0 */ public function default_type_button_bg_hover_color() { $link_hover_color = astra_get_option( 'link-h-color' ); $btn_bg_hover_color = astra_get_option( 'button-bg-h-color', $link_hover_color ); return $btn_bg_hover_color; } /** * Button Border Radius */ public function button_border_radius() { return astra_get_option( 'button-radius' ); } /** * Button Padding */ public function button_padding() { $padding = ''; $v_padding = astra_get_option( 'button-v-padding' ); $h_padding = astra_get_option( 'button-h-padding' ); if ( '' != $v_padding && '' != $h_padding ) { $padding = $v_padding . 'px ' . $h_padding . 'px'; } return $padding; } /** * Default type : Button Padding * * @since 2.2.0 */ public function default_type_button_padding() { $padding = astra_get_option( 'theme-button-padding' ); return $padding; } /** * Button Border Width */ public function button_border_width() { $btn_width = array(); $get_btn_width = astra_get_option( 'theme-button-border-group-border-size' ); if ( ! empty( $get_btn_width ) ) { $btn_width = $get_btn_width; } return $btn_width; } /** * Button Border Color */ public function button_border_color() { $theme_color = astra_get_option( 'theme-color' ); $btn_bg_color = astra_get_option( 'button-bg-color', $theme_color ); $get_btn_border_color = astra_get_option( 'theme-button-border-group-border-color', $btn_bg_color ); return $get_btn_border_color; } /** * Button Border Hover Color */ public function button_border_hover_color() { $link_hover_color = astra_get_option( 'link-h-color' ); $btn_bg_hover_color = astra_get_option( 'button-bg-h-color', $link_hover_color ); $get_btn_border_h_color = astra_get_option( 'theme-button-border-group-border-h-color', $btn_bg_hover_color ); return $get_btn_border_h_color; } /** * Button Vertical Padding. * * @deprecated 2.2.0 */ public function button_vertical_padding() { $padding = ''; $v_padding = astra_get_option( 'button-v-padding' ); if ( '' != $v_padding ) { $padding = $v_padding; } return $padding; } /** * Button Horizontal Padding. * * @deprecated 2.2.0 */ public function button_horizontal_padding() { $padding = ''; $h_padding = astra_get_option( 'button-h-padding' ); if ( '' != $h_padding ) { $padding = $h_padding; } return $padding; } } endif; /** * Kicking this off by calling 'get_instance()' method */ Astra_BB_Ultimate_Addon::get_instance();