@@ 21-29 (lines=9) @@ | ||
18 | */ |
|
19 | function create_legacy_buttons_markup( $attributes, $content, $block ) { |
|
20 | $button_styles = array(); |
|
21 | if ( ! empty( $attributes['customBackgroundButtonColor'] ) ) { |
|
22 | array_push( |
|
23 | $button_styles, |
|
24 | sprintf( |
|
25 | 'background-color: %s', |
|
26 | isset( $attributes['customBackgroundButtonColor'] ) ? sanitize_hex_color( $attributes['customBackgroundButtonColor'] ) : 'transparent' |
|
27 | ) |
|
28 | ); |
|
29 | } |
|
30 | if ( ! empty( $attributes['customTextButtonColor'] ) ) { |
|
31 | array_push( |
|
32 | $button_styles, |
|
@@ 30-38 (lines=9) @@ | ||
27 | ) |
|
28 | ); |
|
29 | } |
|
30 | if ( ! empty( $attributes['customTextButtonColor'] ) ) { |
|
31 | array_push( |
|
32 | $button_styles, |
|
33 | sprintf( |
|
34 | 'color: %s', |
|
35 | isset( $attributes['customTextButtonColor'] ) ? sanitize_hex_color( $attributes['customTextButtonColor'] ) : 'inherit' |
|
36 | ) |
|
37 | ); |
|
38 | } |
|
39 | $button_styles = implode( ';', $button_styles ); |
|
40 | ||
41 | $login_button = sprintf( |