\n"; } /** * Menu Fallback * ============= * If this function is assigned to the wp_nav_menu's fallback_cb variable * and a menu has not been assigned to the theme location in the WordPress * menu manager the function with display nothing to a non-logged in user, * and will add a link to the WordPress menu manager if logged in as an admin. * * @param array $args passed from the wp_nav_menu function. */ public static function fallback( $args ) { if ( current_user_can( 'edit_theme_options' ) ) { /* Get Arguments. */ $container = $args['container']; $container_id = $args['container_id']; $container_class = $args['container_class']; $menu_class = $args['menu_class']; $menu_id = $args['menu_id']; if ( $container ) { echo '<' . esc_attr( $container ); if ( $container_id ) { echo ' id="' . esc_attr( $container_id ) . '"'; } if ( $container_class ) { echo ' class="' . sanitize_html_class( $container_class ) . '"'; } echo '>'; } echo ''; echo '
  • ' . esc_html__( 'Add a menu', 'shopstore' ) . '
  • '; echo ''; if ( $container ) { echo ''; } } } } /** * Adds custom classes to the array of body classes. * * @param array $classes Classes for the body element. * @return array */ function shopstore_body_classes( $classes ) { // Adds a class of hfeed to non-singular pages. if ( ! is_singular() ) { $classes[] = 'hfeed'; } // Adds a class of no-sidebar when there is no sidebar present. if ( ! is_active_sidebar( 'sidebar-1' ) ) { $classes[] = 'no-sidebar'; } return $classes; } add_filter( 'body_class', 'shopstore_body_classes' ); /** * Add a pingback url auto-discovery header for single posts, pages, or attachments. */ function shopstore_pingback_header() { if ( is_singular() && pings_open() ) { echo ''; } } add_action( 'wp_head', 'shopstore_pingback_header' ); if ( ! function_exists( 'shopstore_post_thumbnail' ) ) : /** * Displays an optional post thumbnail. * * Wraps the post thumbnail in an anchor element on index views, or a div * element when on single views. */ function shopstore_post_thumbnail() { if ( post_password_required() || is_attachment() || ! has_post_thumbnail() ) { return; } if ( is_singular() ) : ?>
    #elementor-panel-category-pro-elements, #elementor-panel-category-theme-elements, #elementor-panel-category-woocommerce-elements, #elementor-panel-get-pro-elements{ display:none!important; } '; } ); } add_action( 'elementor/editor/init', 'shopstore_elementor_editor_simplify'); } add_filter( 'use_widgets_block_editor', '__return_false' );