' . $single_widget_column . ''; } $preview_cache_widgets_output .= ''; } blocksy_add_customizer_preview_cache( function () use ($preview_cache_widgets_output) { return blocksy_html_tag( 'div', [ 'data-id' => 'footer-columns' ], blocksy_footer_widgets_structure( $preview_cache_widgets_output ) ); } ); if ( get_theme_mod( 'has_widget_area', 'yes' ) === 'yes' && ! empty( trim( $footer_widgets_output ) ) ) { /** * Note to code reviewers: This line doesn't need to be escaped. * Function blocksy_footer_widgets_structure() used here escapes the value properly. */ echo blocksy_footer_widgets_structure( $footer_widgets_output ); } } function blocksy_footer_widgets_structure( $output ) { $columns_structure = get_theme_mod( 'footer_widgets_structure', '3' ); $divider_output = ''; if ( blocksy_akg( 'style', get_theme_mod( 'widgetsAreaDivider', [ 'width' => 1, 'style' => 'dashed', 'color' => [ 'color' => '#dddddd', ], ]) ) !== 'none' ) { $divider_output = 'data-divider'; } $class = 'footer-widgets-area'; $class .= ' ' . blocksy_visibility_classes(get_theme_mod('footer_widgets_visibility', [ 'desktop' => true, 'tablet' => true, 'mobile' => false, ])); ob_start(); ?>
'); wp_nav_menu( [ 'theme_location' => 'footer', 'depth' => 1, 'container' => false, 'menu_id' => 'footer-menu', 'menu_class' => 'footer-menu menu', 'fallback_cb' => 'blocksy_link_to_menu_editor', ] ); echo ''; $output = ob_get_clean(); } if ( $kind === 'custom_text' ) { $output = '
' . get_theme_mod( 'section_' . $number . '_text', 'Sample text' ) . '
'; } if ( $kind === 'social_icons' ) { $output = blocksy_social_icons( get_theme_mod('footer_socials_' . $number, [ [ 'id' => 'facebook', 'enabled' => true, ], [ 'id' => 'twitter', 'enabled' => true, ], [ 'id' => 'gplus', 'enabled' => true, ], ]) ); } return '
' . $output . '
'; } function blocksy_footer_main_area_sections_cache() { ob_start(); wp_nav_menu( [ 'theme_location' => 'footer', 'depth' => 1, 'container' => false, 'menu_id' => 'footer-menu', 'menu_class' => 'footer-menu menu', 'fallback_cb' => 'blocksy_link_to_menu_editor', ] ); $output = '
' . ob_get_clean() . '
'; blocksy_add_customizer_preview_cache( function () use ($output) { return blocksy_html_tag( 'div', [ 'data-id' => 'footer-main-area-menu' ], $output ); } ); $output = '
'; $output .= '
' . get_theme_mod( 'section_1_text', 'Sample text' ) . '

'; $output .= '
'; blocksy_add_customizer_preview_cache( function () use ($output) { return blocksy_html_tag( 'div', [ 'data-id' => 'footer-main-area-text' ], $output ); } ); blocksy_add_customizer_preview_cache( function () { return blocksy_html_tag( 'div', [ 'data-id' => 'footer-main-area-socials' ], '
' . blocksy_social_icons(null) . '
' ); } ); } function blocksy_output_back_to_top_link($for_preview = false) { $type = get_theme_mod('top_button_type', 'type-1'); $shape = get_theme_mod('top_button_shape', 'square'); $alignment = get_theme_mod('top_button_alignment', 'right'); $svgs = [ 'type-1' => '', 'type-2' => '', 'type-3' => '', ]; $class = 'ct-back-to-top'; $class .= ' ' . blocksy_visibility_classes(get_theme_mod('back_top_visibility', [ 'desktop' => true, 'tablet' => true, 'mobile' => false, ])); ?> $value) { /** * Note to code reviewers: This line doesn't need to be escaped. * Function blocksy_html_tag() used here escapes the value properly. * It's mainly not escaped with wp_kses_post() because it contains an SVG. */ echo blocksy_html_tag( 'div', ['data-top' => $key], $value ); } } ?>