$vefmb_definition ) { if ( in_array( $vefmb_key, array( 'accent', 'button_text' ), true ) ) { continue; // Saved below, with the other colors. } $vefmb_value = sanitize_text_field( wp_unslash( $_POST[ 'vefmb_style_' . $vefmb_key ] ?? '' ) ); if ( 'color' === $vefmb_definition['type'] ) { $vefmb_value = VEFMB_Block_Options::sanitize_color( $vefmb_value ); } elseif ( ! array_key_exists( $vefmb_value, $vefmb_definition['choices'] ) ) { $vefmb_value = ''; } $vefmb_block_defaults[ VEFMB_Block_Options::global_setting_name( $vefmb_key ) ] = $vefmb_value; } VEFMB_Settings::update( $vefmb_block_defaults + array( 'style_font_family' => VEFMB_Style::sanitize_font( sanitize_text_field( wp_unslash( $_POST['vefmb_style_font_family'] ?? '' ) ) ), 'style_title_size' => array_key_exists( $vefmb_title_size, VEFMB_Style::title_sizes() ) ? $vefmb_title_size : 'theme', 'style_heading_size' => array_key_exists( $vefmb_heading_size, VEFMB_Style::heading_sizes() ) ? $vefmb_heading_size : 'theme', 'style_accent_color' => VEFMB_Style::sanitize_color( sanitize_text_field( wp_unslash( $_POST['vefmb_style_accent_color'] ?? '' ) ) ), 'style_button_text_color' => VEFMB_Style::sanitize_color( sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_text_color'] ?? '' ) ) ), // Button shadow: color (with opacity) turns it on; each number // is clamped by VEFMB_Button_Shadow (empty = default value). 'style_button_shadow_color' => VEFMB_Style::sanitize_color( sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_shadow_color'] ?? '' ) ) ), 'style_button_shadow_x' => VEFMB_Button_Shadow::sanitize_number( 'x', sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_shadow_x'] ?? '' ) ) ), 'style_button_shadow_y' => VEFMB_Button_Shadow::sanitize_number( 'y', sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_shadow_y'] ?? '' ) ) ), 'style_button_shadow_blur' => VEFMB_Button_Shadow::sanitize_number( 'blur', sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_shadow_blur'] ?? '' ) ) ), 'style_button_shadow_spread' => VEFMB_Button_Shadow::sanitize_number( 'spread', sanitize_text_field( wp_unslash( $_POST['vefmb_style_button_shadow_spread'] ?? '' ) ) ), ) ); $vefmb_notice = __( 'Style saved.', 'vefmultibooking' ); } $vefmb_settings = VEFMB_Settings::get_all(); $vefmb_title_labels = array( 'theme' => __( 'Theme size (default)', 'vefmultibooking' ), 'small' => __( 'Small', 'vefmultibooking' ), 'medium' => __( 'Medium', 'vefmultibooking' ), 'large' => __( 'Large', 'vefmultibooking' ), ); $vefmb_shadow_fields = array( 'x' => __( 'Horizontal offset', 'vefmultibooking' ), 'y' => __( 'Vertical offset', 'vefmultibooking' ), 'blur' => __( 'Blur', 'vefmultibooking' ), 'spread' => __( 'Spread', 'vefmultibooking' ), ); ?>

array( 'radius', 'density', 'title_align', 'field_style' ), 'shadows' => array( 'shadow_block', 'shadow_cards', 'shadow_fields', 'shadow_color' ), 'layout' => array( 'offers_layout', 'offers_columns', 'slots_layout', 'steps', 'descriptions', 'prices' ), ); $vefmb_site_titles = array( 'appearance' => __( 'Shape and spacing', 'vefmultibooking' ), 'shadows' => __( 'Shadows', 'vefmultibooking' ), 'layout' => __( 'Layout', 'vefmultibooking' ), ); $vefmb_definitions = VEFMB_Block_Options::definitions(); ?>

$vefmb_keys ) : ?>