: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
// Reset $wp_query to its origin
$wp_query = $wp_query_page; // phpcs:ignore WordPress.Variables.GlobalVariables.OverrideProhibited
'use_current_loop' => array(
'label' => esc_html__( 'Posts For Current Page', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'description' => esc_html__( 'Display posts for the current page. Useful on archive and index pages.', 'et_builder' ),
'computed_affects' => array(
'toggle_slug' => 'main_content',
'function.isTBLayout' => 'on',
'label' => esc_html__( 'Post Count', 'et_builder' ),
'option_category' => 'configuration',
'description' => esc_html__( 'Choose how many posts you would like to display in the slider.', 'et_builder' ),
'computed_affects' => array(
'toggle_slug' => 'main_content',
'include_categories' => array(
'label' => esc_html__( 'Included Categories', 'et_builder' ),
'meta_categories' => array(
'all' => esc_html__( 'All Categories', 'et_builder' ),
'current' => esc_html__( 'Current Category', 'et_builder' ),
'option_category' => 'basic_option',
'renderer_options' => array(
'description' => esc_html__( 'Choose which categories you would like to include in the slider.', 'et_builder' ),
'toggle_slug' => 'main_content',
'computed_affects' => array(
'use_current_loop' => 'off',
'label' => esc_html__( 'Order', 'et_builder' ),
'option_category' => 'configuration',
'date_desc' => esc_html__( 'Date: new to old', 'et_builder' ),
'date_asc' => esc_html__( 'Date: old to new', 'et_builder' ),
'title_asc' => esc_html__( 'Title: a-z', 'et_builder' ),
'title_desc' => esc_html__( 'Title: z-a', 'et_builder' ),
'rand' => esc_html__( 'Random', 'et_builder' ),
'default' => 'date_desc',
'description' => esc_html__( 'Here you can adjust the order in which posts are displayed.', 'et_builder' ),
'computed_affects' => array(
'use_current_loop' => 'off',
'toggle_slug' => 'main_content',
'label' => esc_html__( 'Show Arrows', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'toggle_slug' => 'elements',
'description' => esc_html__( 'This setting will turn on and off the navigation arrows.', 'et_builder' ),
'mobile_options' => true,
'show_pagination' => array(
'label' => esc_html__( 'Show Controls', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'toggle_slug' => 'elements',
'description' => esc_html__( 'This setting will turn on and off the circle buttons at the bottom of the slider.', 'et_builder' ),
'mobile_options' => true,
'show_more_button' => array(
'label' => esc_html__( 'Show Read More Button', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'toggle_slug' => 'elements',
'description' => esc_html__( 'This setting will turn on and off the read more button.', 'et_builder' ),
'mobile_options' => true,
'label' => et_builder_i18n( 'Button' ),
'option_category' => 'configuration',
'default_on_front' => esc_html__( 'Read More', 'et_builder' ),
'depends_show_if' => 'on',
'toggle_slug' => 'main_content',
'dynamic_content' => 'text',
'description' => esc_html__( 'Define the text which will be displayed on "Read More" button. Leave blank for default ( Read More )', 'et_builder' ),
'mobile_options' => true,
'content_source' => array(
'label' => esc_html__( 'Content Display', 'et_builder' ),
'option_category' => 'configuration',
'off' => esc_html__( 'Show Excerpt', 'et_builder' ),
'on' => esc_html__( 'Show Content', 'et_builder' ),
'description' => esc_html__( 'Showing the full content will not truncate your posts in the slider. Showing the excerpt will only display excerpt text.', 'et_builder' ),
'toggle_slug' => 'main_content',
'computed_affects' => array(
'mobile_options' => true,
'use_manual_excerpt' => array(
'label' => esc_html__( 'Use Post Excerpts', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'depends_show_if' => 'off',
'description' => esc_html__( 'Disable this option if you want to ignore manually defined excerpts and always generate it automatically.', 'et_builder' ),
'toggle_slug' => 'main_content',
'computed_affects' => array(
'excerpt_length' => array(
'label' => esc_html__( 'Excerpt Length', 'et_builder' ),
'option_category' => 'configuration',
'default_on_front' => '270',
'depends_show_if' => 'off',
'description' => esc_html__( 'Define the length of automatically generated excerpts. Leave blank for default ( 270 ) ', 'et_builder' ),
'toggle_slug' => 'main_content',
'computed_affects' => array(
'label' => esc_html__( 'Show Post Meta', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
// Uses cached uppercase translation but keeps the lowercase not change definition content.
'on' => strtolower( et_builder_i18n( 'Yes' ) ),
'off' => et_builder_i18n( 'No' ),
'default_on_fron' => 'on',
'toggle_slug' => 'elements',
'description' => esc_html__( 'This setting will turn on and off the meta section.', 'et_builder' ),
'default_on_front'=> 'on',
'mobile_options' => true,
'label' => esc_html__( 'Show Featured Image', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
// Uses cached uppercase translation but keeps the lowercase not change definition content.
'on' => strtolower( et_builder_i18n( 'Yes' ) ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'toggle_slug' => 'featured_image',
'description' => esc_html__( 'This setting will turn on and off the featured image in the slider.', 'et_builder' ),
'mobile_options' => true,
'image_placement' => array(
'label' => esc_html__( 'Featured Image Placement', 'et_builder' ),
'option_category' => 'configuration',
'background' => et_builder_i18n( 'Background' ),
'left' => et_builder_i18n( 'Left' ),
'right' => et_builder_i18n( 'Right' ),
'top' => et_builder_i18n( 'Top' ),
'bottom' => et_builder_i18n( 'Bottom' ),
'default_on_front' => 'background',
'depends_show_if' => 'on',
'toggle_slug' => 'featured_image',
'description' => esc_html__( 'Select how you would like to display the featured image in slides', 'et_builder' ),
'use_bg_overlay' => array(
'label' => esc_html__( 'Use Background Overlay', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'tab_slug' => 'advanced',
'toggle_slug' => 'overlay',
'description' => esc_html__( 'When enabled, a custom overlay color will be added above your background image and behind your slider content.', 'et_builder' ),
'bg_overlay_color' => array(
'label' => esc_html__( 'Background Overlay Color', 'et_builder' ),
'depends_show_if' => 'on',
'tab_slug' => 'advanced',
'toggle_slug' => 'overlay',
'description' => esc_html__( 'Use the color picker to choose a color for the background overlay.', 'et_builder' ),
'mobile_options' => true,
'use_text_overlay' => array(
'label' => esc_html__( 'Use Text Overlay', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'configuration',
'off' => et_builder_i18n( 'No' ),
// Uses cached uppercase translation but keeps the lowercase not change definition content.
'on' => strtolower( et_builder_i18n( 'Yes' ) ),
'tab_slug' => 'advanced',
'toggle_slug' => 'overlay',
'description' => esc_html__( 'When enabled, a background color is added behind the slider text to make it more readable atop background images.', 'et_builder' ),
'text_overlay_color' => array(
'label' => esc_html__( 'Text Overlay Color', 'et_builder' ),
'depends_show_if' => 'on',
'tab_slug' => 'advanced',
'toggle_slug' => 'overlay',
'description' => esc_html__( 'Use the color picker to choose a color for the text overlay.', 'et_builder' ),
'mobile_options' => true,
'show_content_on_mobile' => array(
'label' => esc_html__( 'Show Content On Mobile', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'layout',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'tab_slug' => 'custom_css',
'toggle_slug' => 'visibility',
'show_cta_on_mobile' => array(
'label' => esc_html__( 'Show CTA On Mobile', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'layout',
'on' => et_builder_i18n( 'Yes' ),
'off' => et_builder_i18n( 'No' ),
'default_on_front' => 'on',
'tab_slug' => 'custom_css',
'toggle_slug' => 'visibility',
'show_image_video_mobile' => array(
'label' => esc_html__( 'Show Image On Mobile', 'et_builder' ),
'type' => 'yes_no_button',
'option_category' => 'layout',
'off' => et_builder_i18n( 'No' ),
'on' => et_builder_i18n( 'Yes' ),
'default_on_front' => 'off',
'tab_slug' => 'custom_css',
'toggle_slug' => 'visibility',
'text_border_radius' => array(
'label' => esc_html__( 'Text Overlay Border Radius', 'et_builder' ),
'description' => esc_html__( 'Increasing the border radius will increase the roundness of the overlay corners. Setting this value to 0 will result in squared corners.', 'et_builder' ),
'option_category' => 'layout',
'allowed_units' => array( '%', 'em', 'rem', 'px', 'cm', 'mm', 'in', 'pt', 'pc', 'ex', 'vh', 'vw' ),
'default_on_front' => '',
'range_settings' => array(
'depends_show_if' => 'on',
'tab_slug' => 'advanced',
'toggle_slug' => 'overlay',
'mobile_options' => true,
'arrows_custom_color' => array(
'label' => esc_html__( 'Arrow Color', 'et_builder' ),
'description' => esc_html__( 'Pick a color to use for the slider arrows that are used to navigate through each slide.', 'et_builder' ),
'tab_slug' => 'advanced',
'toggle_slug' => 'navigation',
'mobile_options' => true,
'dot_nav_custom_color' => array(
'label' => esc_html__( 'Dot Navigation Color', 'et_builder' ),
'description' => esc_html__( 'Pick a color to use for the dot navigation that appears at the bottom of the slider to designate which slide is active.', 'et_builder' ),
'tab_slug' => 'advanced',
'toggle_slug' => 'navigation',
'mobile_options' => true,
'computed_callback' => array( 'ET_Builder_Module_Fullwidth_Post_Slider', 'get_blog_posts' ),
'computed_depends_on' => array(
'offset_number' => array(
'label' => esc_html__( 'Post Offset Number', 'et_builder' ),
'description' => esc_html__( 'Choose how many posts you would like to offset by', 'et_builder' ),
'option_category' => 'configuration',
'toggle_slug' => 'main_content',
'computed_affects' => array(
public function get_transition_fields_css_props() {
$fields = parent::get_transition_fields_css_props();
$fields['background_layout'] = array(
'background-color' => '%%order_class%% .et_pb_slide_overlay_container, %%order_class%% .et_pb_text_overlay_wrapper',
'color' => self::$_->array_get( $this->advanced_fields, 'text.css.main', '%%order_class%%' ),
$fields['dot_nav_custom_color'] = array( 'background-color' => et_pb_slider_options()->get_dots_selector() );
$fields['arrows_custom_color'] = array( 'all' => et_pb_slider_options()->get_arrows_selector() );
function render( $attrs, $content = null, $render_slug ) {
* Cached $wp_filter so it can be restored at the end of the callback.
* This is needed because this callback uses the_content filter / calls a function
* which uses the_content filter. WordPress doesn't support nested filter
$wp_filter_cache = $wp_filter;
$multi_view = et_pb_multi_view_options( $this );
$use_current_loop = isset( $this->props['use_current_loop'] ) ? $this->props['use_current_loop'] : 'off';
$show_arrows = $this->props['show_arrows'];
$show_pagination = $this->props['show_pagination'];
$parallax = $this->props['parallax'];
$parallax_method = $this->props['parallax_method'];
$auto = $this->props['auto'];
$auto_speed = $this->props['auto_speed'];
$auto_ignore_hover = $this->props['auto_ignore_hover'];
$body_font_size = $this->props['body_font_size'];
$show_content_on_mobile = $this->props['show_content_on_mobile'];
$show_cta_on_mobile = $this->props['show_cta_on_mobile'];
$show_image_video_mobile = $this->props['show_image_video_mobile'];
$background_position = $this->props['background_position'];
$background_size = $this->props['background_size'];
$posts_number = $this->props['posts_number'];
$include_categories = $this->props['include_categories'];
$more_text = $this->props['more_text'];
$background_color = $this->props['background_color'];
$show_image = $this->props['show_image'];
$image_placement = $this->props['image_placement'];
$background_image = $this->props['background_image'];
$background_repeat = $this->props['background_repeat'];
$background_blend = $this->props['background_blend'];
$use_bg_overlay = $this->props['use_bg_overlay'];
$use_text_overlay = $this->props['use_text_overlay'];
$orderby = $this->props['orderby'];
$button_custom = $this->props['custom_button'];
$button_rel = $this->props['button_rel'];
$use_manual_excerpt = $this->props['use_manual_excerpt'];
$excerpt_length = $this->props['excerpt_length'];
$header_level = $this->props['header_level'];
$offset_number = $this->props['offset_number'];
$bg_overlay_color_values = et_pb_responsive_options()->get_property_values( $this->props, 'bg_overlay_color' );
$text_overlay_color_values = et_pb_responsive_options()->get_property_values( $this->props, 'text_overlay_color' );
$text_border_radius_values = et_pb_responsive_options()->get_property_values( $this->props, 'text_border_radius' );
$custom_icon_values = et_pb_responsive_options()->get_property_values( $this->props, 'button_icon' );
$custom_icon = isset( $custom_icon_values['desktop'] ) ? $custom_icon_values['desktop'] : '';
$custom_icon_tablet = isset( $custom_icon_values['tablet'] ) ? $custom_icon_values['tablet'] : '';
$custom_icon_phone = isset( $custom_icon_values['phone'] ) ? $custom_icon_values['phone'] : '';
$hide_on_mobile_class = self::HIDE_ON_MOBILE;
$is_text_overlay_applied = 'on' === $use_text_overlay;
if ( 'on' === $use_bg_overlay ) {
// Background Overlay color.
et_pb_responsive_options()->generate_responsive_css( $bg_overlay_color_values, '%%order_class%% .et_pb_slide .et_pb_slide_overlay_container', 'background-color', $render_slug, '', 'color' );
if ( $is_text_overlay_applied ) {
et_pb_responsive_options()->generate_responsive_css( $text_overlay_color_values, '%%order_class%% .et_pb_slide .et_pb_text_overlay_wrapper', 'background-color', $render_slug, '', 'color' );
et_pb_responsive_options()->generate_responsive_css( $text_border_radius_values, '%%order_class%%.et_pb_slider_with_text_overlay .et_pb_text_overlay_wrapper', 'border-radius', $render_slug );
$video_background = $this->video_background();
$parallax_image_background = $this->get_parallax_image_background();
$this->generate_responsive_hover_style( 'arrows_custom_color', et_pb_slider_options()->get_arrows_selector(), 'color' );
$this->generate_responsive_hover_style( 'dot_nav_custom_color', et_pb_slider_options()->get_dots_selector(), 'background-color' );
$content_source_both = count( $multi_view->get_values( 'content_source', true ) ) > 1;
$is_show_image = $multi_view->has_value( 'show_image', 'on' );
$is_show_meta = $multi_view->has_value( 'show_meta', 'on' );
$multi_view_attrs_button = $multi_view->render_attrs( array(
'content' => '{{more_text}}',
'more_text' => '__not_empty',
'show_more_button' => 'on',
$multi_view_attrs_show_meta = $multi_view->render_attrs( array(