FEATURED PRODUCTS
Lorem Ipsum is simply dummy text of the printing and typesetting industry.
', 'type' => 'content', 'conditions' => [ [ 'comparison' => 'contain', 'value' => [ 'top_content' ], 'attribute' => 'showing_items', ], ] ], 'sale_price_color' => [ 'value_path' => 'sale_price_color', 'component' => 'Color', 'title' => __( 'Product price color', 'yaymail' ), 'default_value' => isset( $attributes['sale_price_color'] ) ? $attributes['sale_price_color'] : '#ec4770', 'type' => 'style', 'conditions' => [ [ 'comparison' => 'contain', 'value' => [ 'product_price' ], 'attribute' => 'showing_items', ], ], ], 'regular_price_color' => [ 'value_path' => 'regular_price_color', 'component' => 'Color', 'title' => __( 'Product original price color', 'yaymail' ), 'default_value' => isset( $attributes['regular_price_color'] ) ? $attributes['regular_price_color'] : '#808080', 'type' => 'style', 'conditions' => [ [ 'comparison' => 'contain', 'value' => [ 'product_original_price' ], 'attribute' => 'showing_items', ], ], ], 'button_breaker' => [ 'component' => 'LineBreaker', 'conditions' => $buy_button_conditions, ], 'button_group_definition' => [ 'component' => 'GroupDefinition', 'title' => __( 'Button', 'yaymail' ), 'description' => __( 'Handle buy button settings', 'yaymail' ), 'conditions' => $buy_button_conditions, ], 'buy_button_label' => [ 'value_path' => 'buy_button_label', 'component' => 'TextInput', 'title' => __( 'Buy button text', 'yaymail' ), 'default_value' => isset( $attributes['buy_button_label'] ) ? $attributes['buy_button_label'] : __( 'BUY NOW', 'yaymail' ), 'type' => 'content', 'conditions' => $buy_button_conditions, ], 'buy_button_background_color' => [ 'value_path' => 'buy_button_background_color', 'component' => 'Color', 'title' => __( 'Buy button background color', 'yaymail' ), 'default_value' => isset( $attributes['buy_button_background_color'] ) ? $attributes['buy_button_background_color'] : '#ec4770', 'type' => 'style', 'conditions' => $buy_button_conditions, ], 'buy_button_text_color' => [ 'value_path' => 'buy_button_text_color', 'component' => 'Color', 'title' => __( 'Buy button text color', 'yaymail' ), 'default_value' => isset( $attributes['buy_button_text_color'] ) ? $attributes['buy_button_text_color'] : '#ffffff', 'type' => 'style', 'conditions' => $buy_button_conditions, ], 'products_breaker' => [ 'component' => 'LineBreaker', ], 'products_group_definition' => [ 'component' => 'GroupDefinition', 'title' => __( 'Products', 'yaymail' ), 'description' => __( 'Handle products settings', 'yaymail' ), ], 'products_per_row' => [ 'value_path' => 'products_per_row', 'component' => 'NumberInput', 'title' => __( 'Products per row', 'yaymail' ), 'default_value' => isset( $attributes['products_per_row'] ) ? $attributes['products_per_row'] : '3', 'min' => 1, 'max' => 3, 'type' => 'content', ], 'product_type' => [ 'value_path' => 'product_type', 'component' => 'Selector', 'title' => __( 'Product type', 'yaymail' ), 'default_value' => isset( $attributes['product_type'] ) ? $attributes['product_type'] : 'newest', 'type' => 'content', 'options' => [ [ 'label' => __( 'Newest', 'yaymail' ), 'value' => 'newest', ], [ 'label' => __( 'On sale', 'yaymail' ), 'value' => 'on_sale', ], [ 'label' => __( 'Featured', 'yaymail' ), 'value' => 'featured', ], [ 'label' => __( 'Category selections', 'yaymail' ), 'value' => 'category_selections', ], [ 'label' => __( 'Tag selections', 'yaymail' ), 'value' => 'tag_selections', ], [ 'label' => __( 'Product selections', 'yaymail' ), 'value' => 'product_selections', ], ], ], 'categories' => [ 'value_path' => 'categories', 'component' => 'EntitiesSelector', 'title' => __( 'Product categories', 'yaymail' ), 'default_value' => isset( $attributes['categories'] ) ? $attributes['categories'] : [], 'type' => 'content', 'entity_type' => 'categories', 'conditions' => [ [ 'value' => 'category_selections', 'attribute' => 'product_type', ], ], ], 'tags' => [ 'value_path' => 'tags', 'component' => 'EntitiesSelector', 'title' => __( 'Product tags', 'yaymail' ), 'default_value' => isset( $attributes['tags'] ) ? $attributes['tags'] : [], 'type' => 'content', 'entity_type' => 'tags', 'conditions' => [ [ 'value' => 'tag_selections', 'attribute' => 'product_type', ], ], ], 'products' => [ 'value_path' => 'products', 'component' => 'EntitiesSelector', 'title' => __( 'Products', 'yaymail' ), 'default_value' => isset( $attributes['products'] ) ? $attributes['products'] : [], 'type' => 'content', 'entity_type' => 'products', 'conditions' => [ [ 'value' => 'product_selections', 'attribute' => 'product_type', ], ], ], 'sorted_by' => [ 'value_path' => 'sorted_by', 'component' => 'Selector', 'title' => __( 'Sorted by', 'yaymail' ), 'default_value' => isset( $attributes['sorted_by'] ) ? $attributes['sorted_by'] : 'none', 'options' => [ [ 'label' => __( 'None', 'yaymail' ), 'value' => 'none', ], [ 'label' => __( 'Name A-Z', 'yaymail' ), 'value' => 'name_a_z', ], [ 'label' => __( 'Name Z-A', 'yaymail' ), 'value' => 'name_z_a', ], [ 'label' => __( 'Ascending Price', 'yaymail' ), 'value' => 'price_ascending', ], [ 'label' => __( 'Descending Price', 'yaymail' ), 'value' => 'price_descending', ], [ 'label' => __( 'Random', 'yaymail' ), 'value' => 'random', ], ], 'type' => 'content', ], 'number_of_products' => [ 'value_path' => 'number_of_products', 'component' => 'NumberInput', 'title' => __( 'Number of featured products', 'yaymail' ), 'default_value' => isset( $attributes['number_of_products'] ) ? $attributes['number_of_products'] : '5', 'type' => 'content', 'min' => 1, 'max' => 20, 'is_debounce' => true, 'conditions' => [ [ 'comparison' => '!=', 'value' => 'product_selections', 'attribute' => 'product_type', ], ], ], ], ]; } }