'https://www.diviessential.com/divi-advanced-tab/', 'author' => 'Divi Next', 'author_uri' => 'www.divinext.com', ); public function init() { $this->name = esc_html__('Advanced Tab', 'dnxte-divi-essential'); $this->icon_path = plugin_dir_path(__FILE__) . 'icon.svg'; $this->folder_name = 'et_pb_divi_essential'; $this->settings_modal_toggles = array( 'general' => array( 'toggles' => array( 'tab_container_bg' => array( 'title' => esc_html__('Tab Container Background', 'dnxte-divi-essential'), ), 'content_container_bg' => array( 'title' => esc_html__('Content Container Background', 'dnxte-divi-essential'), ), ), ), 'advanced' => array( 'toggles' => array( 'tabs_settings' => array( 'title' => esc_html__('Tab Settings', 'dnxte-divi-essential'), ), 'body_settings' => array( 'title' => esc_html__('Body Settings', 'dnxte-divi-essential'), ), 'tab_fonts' => array( 'title' => esc_html__('Tab Text', 'dnxte-divi-essential'), 'sub_toggles' => array( 'tab_title' => array( 'name' => esc_html__('Title', 'dnxte-divi-essential'), ), 'tab_subtitle' => array( 'name' => esc_html__('Subtitle', 'dnxte-divi-essential'), ), ), 'tabbed_subtoggles' => true, ), 'tab_active_fonts' => array( 'title' => esc_html__('Tab Active Text', 'dnxte-divi-essential'), 'sub_toggles' => array( 'tab_title' => array( 'name' => esc_html__('Title', 'dnxte-divi-essential'), ), 'tab_subtitle' => array( 'name' => esc_html__('Subtitle', 'dnxte-divi-essential'), ), ), 'tabbed_subtoggles' => true, ), 'body_fonts' => array( 'title' => esc_html__('Body Text', 'dnxte-divi-essential'), 'sub_toggles' => array( 'body_title' => array( 'name' => esc_html__('Title', 'dnxte-divi-essential'), ), 'body_description' => array( 'name' => esc_html__('Description', 'dnxte-divi-essential'), ), ), 'tabbed_subtoggles' => true, ), 'icon_settings' => array( 'title' => esc_html__('Icon Settings', 'dnxte-divi-essential'), 'sub_toggles' => array( 'tab' => array( 'name' => esc_html__('Tab', 'dnxte-divi-essential'), ), 'body' => array( 'name' => esc_html__('Body', 'dnxte-divi-essential'), ), ), 'tabbed_subtoggles' => true, ), 'tab_body_borders' => array( 'title' => esc_html__('Tab & Body Border', 'dnxte-divi-essential'), 'sub_toggles' => array( 'tab' => array( 'name' => esc_html__('Tab', 'dnxte-divi-essential'), ), 'body' => array( 'name' => esc_html__('Body', 'dnxte-divi-essential'), ), ), 'tabbed_subtoggles' => true, ), 'tab_borders_active' => esc_html__('Tab Active Border', 'dnxte-divi-essential'), 'tab_active_settings' => esc_html__('Tab Active Styles', 'dnxte-divi-essential'), ), ), ); $this->custom_css_fields = array( 'tab_wrapper' => array( 'label' => esc_html__('Tab Wrapper', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_menu ul, %%order_class%% .RRT__tabs', ), 'tab_item' => array( 'label' => esc_html__('Tab Item', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_menu ul li a.dnxte_tab_a, %%order_class%% .dnxte-ad-tab', ), 'tab_item_active' => array( 'label' => esc_html__('Tab Item Active', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_menu ul li a.dnxte_active_a, %%order_class%% .RRT__tab--selected', ), 'tab_title' => array( 'label' => esc_html__('Tab Title', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_nav_title', ), 'tab_subtitle' => array( 'label' => esc_html__('Tab Subtitle', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_nav_pra', ), 'tab_icon' => array( 'label' => esc_html__('Tab Icon', 'dnxte-divi-essential'), 'selector' => '%%order_class%% span.dnxte_tab_nav_icon', ), 'body_title' => array( 'label' => esc_html__('Body Title', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_content_slidebar_two .dnxte_tab_content_title', ), 'body_description' => array( 'label' => esc_html__('Body Description', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_content_slidebar_two .dnxte_tab_content_pra', ), 'body_icon' => array( 'label' => esc_html__('Body Icon', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_content_slidebar_one .dnxte_tab_content_icon', ), 'body_image' => array( 'label' => esc_html__('Body Image', 'dnxte-divi-essential'), 'selector' => '%%order_class%% .dnxte_tab_content_slidebar_one img', ), ); } public function get_advanced_fields_config() { return array( 'fonts' => array( 'tab_title' => array( 'label' => esc_html__('Tab Text', 'dnxte-divi-essential'), 'toggle_slug' => 'tab_fonts', 'sub_toggle' => 'tab_title', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_menu ul li a span > .dnxte_tab_nav_title, %%order_class%% .dnxte-ad-tab .dnxte_tab_nav_title", 'important' => 'plugin-only', ), ), 'tab_active_title' => array( 'label' => esc_html__('Tab Text', 'dnxte-divi-essential'), 'toggle_slug' => 'tab_active_fonts', 'sub_toggle' => 'tab_title', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_menu ul li a.dnxte_active_a span > .dnxte_tab_nav_title, %%order_class%% .RRT__tab--selected span .dnxte_tab_nav_title", 'important' => 'plugin-only', ), ), 'tab_subtitle' => array( 'label' => esc_html__('Tab Subtitle', 'dnxte-divi-essential'), 'toggle_slug' => 'tab_fonts', 'sub_toggle' => 'tab_subtitle', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_menu ul li a span > .dnxte_tab_nav_pra, %%order_class%% .dnxte-ad-tab span > .dnxte_tab_nav_pra", ), ), 'tab_active_subtitle' => array( 'label' => esc_html__('Tab Subtitle', 'dnxte-divi-essential'), 'toggle_slug' => 'tab_active_fonts', 'sub_toggle' => 'tab_subtitle', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_menu ul li a.dnxte_active_a span > .dnxte_tab_nav_pra, %%order_class%% .RRT__tab--selected span > .dnxte_tab_nav_pra", ), ), 'body_title' => array( 'label' => esc_html__('Body Title', 'dnxte-divi-essential'), 'toggle_slug' => 'body_fonts', 'sub_toggle' => 'body_title', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_content_slidebar_two .dnxte_tab_content_title", ), ), 'body_description' => array( 'label' => esc_html__('Body Description', 'dnxte-divi-essential'), 'toggle_slug' => 'body_fonts', 'sub_toggle' => 'body_description', 'tab_slug' => 'advanced', 'css' => array( 'main' => "%%order_class%% .dnxte_tab_content_slidebar_two .dnxte_tab_content_pra", ), ), ), 'borders' => array( 'tab' => array( 'css' => array( 'main' => array( 'border_radii' => "%%order_class%% .dnxte-ad-tab:not(.RRT__tab--selected),%%order_class%% .dnxte_tab_menu ul li a:not(a.dnxte_active_a)", 'border_styles' => "%%order_class%% .dnxte-ad-tab:not(.RRT__tab--selected),%%order_class%% .dnxte_tab_menu ul li a:not(a.dnxte_active_a)", ), 'important' => 'all', ), 'toggle_slug' => 'tab_body_borders', 'sub_toggle' => 'tab', 'tab_slug' => 'advanced', ), 'body' => array( 'css' => array( 'main' => array( 'border_radii' => "%%order_class%% .dnxte-ad-panel, %%order_class%% .dnxte_tab_content", 'border_styles' => "%%order_class%% .dnxte-ad-panel, %%order_class%% .dnxte_tab_content", ), 'important' => 'all', ), 'toggle_slug' => 'tab_body_borders', 'sub_toggle' => 'body', 'tab_slug' => 'advanced', ), 'tab_active' => array( 'css' => array( 'main' => array( 'border_radii' => "%%order_class%% .RRT__tab--selected,%%order_class%% ul li a.dnxte_active_a", 'border_styles' => "%%order_class%% .RRT__tab--selected,%%order_class%% ul li a.dnxte_active_a", ), 'important' => 'plugin_only', ), 'toggle_slug' => 'tab_active_settings', 'tab_slug' => 'advanced', ), ), 'box_shadow' => array( 'tab_active' => array( 'css' => array( 'main' => "%%order_class%% .RRT__tabs .RRT__tab--selected,%%order_class%% ul li a.dnxte_active_a", // 'custom_style' => true, ), 'toggle_slug' => 'tab_active_settings', 'tab_slug' => 'advanced', ), ), 'text' => false, 'link_options' => false ); } public function get_fields() { $fields = array( 'hover_effect' => array( 'label' => esc_html__('Select Hover Effect', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Pick a hover effect from the collection.','dnxte-divi-essential'), 'option_category' => 'configuration', 'toggle_slug' => 'body_settings', 'tab_slug' => 'advanced', 'default' => '', 'description' => esc_html__('Here you can adjust the hover effect.', 'dnxte-divi-essential'), 'options' => array( 'none' => esc_html__('Select One', 'dnxte-divi-essential'), 'dnxt-hover-fadeIn ' => esc_html__('Fade In', 'dnxte-divi-essential'), 'dnxt-hover-pulse' => esc_html__('Pulse', 'dnxte-divi-essential'), 'dnxt-hover-pulse-grow' => esc_html__('Pulse Grow', 'dnxte-divi-essential'), 'dnxt-hover-pulse-shrink' => esc_html__('Pulse Shrink', 'dnxte-divi-essential'), 'dnxt-hover-push' => esc_html__('Push', 'dnxte-divi-essential'), 'dnxt-hover-pop' => esc_html__('Pop', 'dnxte-divi-essential'), 'dnxt-hover-bob' => esc_html__('Bob', 'dnxte-divi-essential'), 'dnxt-hover-bob-float' => esc_html__('Bob Float', 'dnxte-divi-essential'), 'dnxt-hover-hang' => esc_html__('Hang', 'dnxte-divi-essential'), 'dnxt-hover-hang-sink' => esc_html__('Hang Sink', 'dnxte-divi-essential'), 'dnxt-hover-wobble-horizontal' => esc_html__('Wobble Horizontal', 'dnxte-divi-essential'), 'dnxt-hover-wobble-vertical' => esc_html__('Wobble Vertical', 'dnxte-divi-essential'), 'dnxt-hover-wobble-to-bottom-right' => esc_html__('Wobble to Bottom Right', 'dnxte-divi-essential'), 'dnxt-hover-wobble-to-top-right' => esc_html__('Wobble to Top Right', 'dnxte-divi-essential'), 'dnxt-hover-wobble-top' => esc_html__('Wobble to Top', 'dnxte-divi-essential'), 'dnxt-hover-wobble-bottom' => esc_html__('Wobble Bottom', 'dnxte-divi-essential'), 'dnxt-hover-wobble-skew' => esc_html__('Wobble Skew', 'dnxte-divi-essential'), 'dnxt-hover-buzz' => esc_html__('Buzz', 'dnxte-divi-essential'), 'dnxt-hover-buzz-out' => esc_html__('Buzz Out', 'dnxte-divi-essential'), 'dnxt-hover-ripple-out' => esc_html__('Ripple Out', 'dnxte-divi-essential'), 'dnxt-hover-ripple-in' => esc_html__('Ripple In', 'dnxte-divi-essential'), 'dnxt-hover-icon-down' => esc_html__('Icon Down', 'dnxte-divi-essential'), 'dnxt-hover-icon-up' => esc_html__('Icon Up', 'dnxte-divi-essential'), 'dnxt-hover-icon-drop' => esc_html__('Icon Drop', 'dnxte-divi-essential'), 'dnxt-hover-icon-float-away' => esc_html__('Icon Float Away', 'dnxte-divi-essential'), 'dnxt-hover-icon-sink-away' => esc_html__('Icon Sink Away', 'dnxte-divi-essential'), 'dnxt-hover-icon-pulse' => esc_html__('Icon Pulse', 'dnxte-divi-essential'), 'dnxt-hover-icon-pulse-grow' => esc_html__('Icon Pulse Grow', 'dnxte-divi-essential'), 'dnxt-hover-icon-pulse-shrink' => esc_html__('Icon Pulse Shrink', 'dnxte-divi-essential'), 'dnxt-hover-icon-push' => esc_html__('Icon Push', 'dnxte-divi-essential'), 'dnxt-hover-icon-pop' => esc_html__('Icon Pop', 'dnxte-divi-essential'), 'dnxt-hover-icon-bob' => esc_html__('Icon Bob', 'dnxte-divi-essential'), 'dnxt-hover-icon-bob-float' => esc_html__('Icon Bob Float', 'dnxte-divi-essential'), 'dnxt-hover-icon-hang' => esc_html__('Icon Hang', 'dnxte-divi-essential'), 'dnxt-hover-icon-hang-sink' => esc_html__('Icon Hang Sink', 'dnxte-divi-essential'), 'dnxt-hover-icon-wobble-horizontal' => esc_html__('Icon Wobble Horizontal', 'dnxte-divi-essential'), 'dnxt-hover-icon-wobble-vertical' => esc_html__('Icon Wobble Vertical', 'dnxte-divi-essential'), 'dnxt-hover-icon-buzz' => esc_html__('Icon Buzz', 'dnxte-divi-essential'), 'dnxt-hover-icon-buzz-out' => esc_html__('Icon Buzz Out', 'dnxte-divi-essential'), ), 'depends_show_if' => 'on', ), 'hover_animation_duration' => array( 'label' => esc_html__('Animation Duration', 'dnxte-divi-essential'), 'description' => esc_html__('Here you can adjust the hover animation duration.', 'dnxte-divi-essential'), 'type' => 'range', 'option_category' => 'basic_option', 'range_settings' => array( 'step' => 0.1, 'min' => 1, 'max' => 10, ), 'default' => 1, 'fixed_unit' => '', 'validate_unit' => false, 'unitless' => true, 'toggle_slug' => 'body_settings', 'tab_slug' => 'advanced', ), ); $tab_settings = array( 'tab_hover_effect' => array( 'label' => esc_html__('Select Hover Effect', 'dnxte-divi-essential'), 'type' => 'select', 'option_category' => 'configuration', 'toggle_slug' => 'tabs_settings', 'tab_slug' => 'advanced', 'default' => '', 'description' => esc_html__('Here you can adjust the hover effect.', 'dnxte-divi-essential'), 'options' => array( 'none' => esc_html__('Select One', 'dnxte-divi-essential'), 'skew' => esc_html__('Skew', 'dnxte-divi-essential'), 'skew-forward' => esc_html__('Skew Forward', 'dnxte-divi-essential'), 'skew-backward' => esc_html__('Skew Backward', 'dnxte-divi-essential'), 'wobble-horizontal' => esc_html__('Wobble Horizontal', 'dnxte-divi-essential'), 'wobble-top' => esc_html__('Wobble Top', 'dnxte-divi-essential'), 'wobble-bottom' => esc_html__('Wobble Bottom', 'dnxte-divi-essential'), 'sweep-to-right' => esc_html__('Sweep to Right', 'dnxte-divi-essential'), 'sweep-to-right' => esc_html__('Sweep to Left', 'dnxte-divi-essential'), 'sweep-to-top' => esc_html__('Sweep to Top', 'dnxte-divi-essential'), 'sweep-to-bottom' => esc_html__('Sweep to Bottom', 'dnxte-divi-essential'), 'forward' => esc_html__('Forward', 'dnxte-divi-essential'), 'backward' => esc_html__('Backward', 'dnxte-divi-essential'), // 'bubble-top' => esc_html__('Bubble Top', 'dnxte-divi-essential'), // 'bubble-bottom' => esc_html__('Bubble Bottom', 'dnxte-divi-essential'), // 'bubble-right' => esc_html__('Bubble Right', 'dnxte-divi-essential'), // 'bubble-left' => esc_html__('Bubble Left', 'dnxte-divi-essential'), ), ), 'tab_content_alignment' => array( 'label' => esc_html__('Tab Content Alignment', 'dnxte-divi-essential'), 'description' => esc_html__('Align inside content of the single tab to the left, right or center.', 'dnxte-divi-essential'), 'type' => 'align', 'option_category' => 'layout', 'options' => et_builder_get_text_orientation_options(array('justified')), 'tab_slug' => 'advanced', 'toggle_slug' => 'tabs_settings', 'default' => 'left', 'mobile_options' => true, 'responsive' => true, ), ); $tab_settings['tabs_width'] = array( 'label' => esc_html__('Tabs Item width', 'dnxte-divi-essential'), 'type' => 'composite', 'description' => esc_html__('Check the responsiveness using this feature.','dnxte-divi-essential'), 'tab_slug' => 'advanced', 'toggle_slug' => 'tabs_settings', 'composite_type' => 'default', 'composite_structure' => array( 'desktop' => array( 'icon' => 'desktop', 'controls' => array( 'use_tabs_fullwidth' => array( 'label' => esc_html__('Use Fullwidth tabs', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to use full width tab.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'on', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'use_tabs_wrap' => array( 'label' => esc_html__('Use Tab Wrap', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to wrap the tab background around the text.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'off', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'tabs_min_width' => array( 'label' => esc_html__('Tabs Item Min Width', 'dnxte-divi-essential'), 'type' => 'range', // 'option_category' => 'font_option', 'default' => '100px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '300', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth' => 'off'), ), 'tabs_max_width' => array( 'label' => esc_html__('Tabs Item Max Width', 'dnxte-divi-essential'), 'type' => 'range', // 'option_category' => 'font_option', 'default' => '200px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '500', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth' => 'off'), ), ), ), 'tablet' => array( 'icon' => 'tablet', 'controls' => array( 'use_tabs_fullwidth_tablet' => array( 'label' => esc_html__('Use Fullwidth tabs', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to use full width tab for tablet devices.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'on', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'use_tabs_wrap_tablet' => array( 'label' => esc_html__('Use Tab Wrap', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to wrap the tab background around the text.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'off', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'tabs_min_width_tablet' => array( 'label' => esc_html__('Tabs Item Min Width', 'dnxte-divi-essential'), 'type' => 'range', 'option_category' => 'font_option', 'default' => '100px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '300', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth_tablet' => 'off'), ), 'tabs_max_width_tablet' => array( 'label' => esc_html__('Tabs Item Max Width', 'dnxte-divi-essential'), 'type' => 'range', 'option_category' => 'font_option', 'default' => '200px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '500', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth_tablet' => 'off'), ), ), ), 'phone' => array( 'icon' => 'phone', 'controls' => array( 'use_tabs_fullwidth_phone' => array( 'label' => esc_html__('Use Fullwidth tabs', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to use full width tab for small devices.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'on', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'use_tabs_wrap_phone' => array( 'label' => esc_html__('Use Tab Wrap', 'dnxte-divi-essential'), 'type' => 'yes_no_button', 'descriptions' => esc_html__('Switch to wrap the tab background around the text.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'default' => 'off', 'options' => array( 'off' => esc_html__('No', 'dnxte-divi-essential'), 'on' => esc_html__('Yes', 'dnxte-divi-essential'), ), ), 'tabs_min_width_phone' => array( 'label' => esc_html__('Tabs Item Min Width', 'dnxte-divi-essential'), 'type' => 'range', 'option_category' => 'font_option', 'default' => '100px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '300', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth_phone' => 'off'), ), 'tabs_max_width_phone' => array( 'label' => esc_html__('Tabs Item Max Width', 'dnxte-divi-essential'), 'type' => 'range', 'option_category' => 'font_option', 'default' => '200px', 'default_unit' => 'px', 'range_settings' => array( 'min' => '1', 'max' => '500', 'step' => '1', ), 'show_if' => array('use_tabs_fullwidth_phone' => 'off'), ), ), ), ), ); $tab_settings['tabs_placement'] = array( 'label' => esc_html__('Tabs Placement', 'dnxte-divi-essential'), 'type' => 'composite', 'tab_slug' => 'advanced', 'toggle_slug' => 'tabs_settings', 'composite_type' => 'default', 'composite_structure' => array( 'desktop' => array( 'icon' => 'desktop', 'controls' => array( 'tab_item_placement' => array( 'label' => esc_html__('Tab Placement', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a placement for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'center' => esc_html__('Top', 'dnxte-divi-essential'), 'bottom' => esc_html__('Bottom', 'dnxte-divi-essential'), 'left' => esc_html__('Left', 'dnxte-divi-essential'), 'right' => esc_html__('Right', 'dnxte-divi-essential'), ), 'default' => 'center', ), 'tabs_item_alignment' => array( 'label' => esc_html__('Tab Alignment', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a alignment for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'flex-start' => esc_html__('Start', 'dnxte-divi-essential'), 'center' => esc_html__('Center', 'dnxte-divi-essential'), 'flex-end' => esc_html__('End', 'dnxte-divi-essential'), ), 'default' => 'flex-start', ), ), ), 'tablet' => array( 'icon' => 'tablet', 'controls' => array( 'tab_item_placement_tablet' => array( 'label' => esc_html__('Tab Placement', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a placement for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'center' => esc_html__('Top', 'dnxte-divi-essential'), 'bottom' => esc_html__('Bottom', 'dnxte-divi-essential'), 'left' => esc_html__('Left', 'dnxte-divi-essential'), 'right' => esc_html__('Right', 'dnxte-divi-essential'), ), 'default' => 'center', ), 'tabs_item_alignment_tablet' => array( 'label' => esc_html__('Tab Alignment', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a alignment for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'flex-start' => esc_html__('Start', 'dnxte-divi-essential'), 'center' => esc_html__('Center', 'dnxte-divi-essential'), 'flex-end' => esc_html__('End', 'dnxte-divi-essential'), ), 'default' => 'flex-start', ), ), ), 'phone' => array( 'icon' => 'phone', 'controls' => array( 'tab_item_placement_phone' => array( 'label' => esc_html__('Tab Placement', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a placement for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'center' => esc_html__('Top', 'dnxte-divi-essential'), 'bottom' => esc_html__('Bottom', 'dnxte-divi-essential'), 'left' => esc_html__('Left', 'dnxte-divi-essential'), 'right' => esc_html__('Right', 'dnxte-divi-essential'), ), 'default' => 'center', ), 'tabs_item_alignment_phone' => array( 'label' => esc_html__('Tab Alignment', 'dnxte-divi-essential'), 'type' => 'select', 'description' => esc_html__('Select a alignment for the tab from the following.', 'dnxte-divi-essential'), 'option_category' => 'basic_option', 'options' => array( 'flex-start' => esc_html__('Start', 'dnxte-divi-essential'), 'center' => esc_html__('Center', 'dnxte-divi-essential'), 'flex-end' => esc_html__('End', 'dnxte-divi-essential'), ), 'default' => 'flex-start', ), ), ), ), ); $tab_icon_settings = array( 'tab_icon_size' => array( 'label' => esc_html__('Tabs Icon Size', 'dnxte-divi-essential'), 'type' => 'range', 'description' => esc_html__('Adjust the size of the icon using the slider.', 'dnxte-divi-essential'), 'default' => '20px', 'default_unit' => 'px', 'tab_slug' => 'advanced', 'toggle_slug' => 'icon_settings', 'sub_toggle' => 'tab', 'mobile_options' => true, 'responsive' => true, 'range_settings' => array( 'min' => '1', 'max' => '300', 'step' => '1', ), ), 'tab_icon_color' => array( 'label' => esc_html__('Icon Color', 'dnxte-divi-essential'), 'type' => 'color-alpha', 'description' => esc_html__('Select a color for the icon.', 'dnxte-divi-essential'), 'toggle_slug' => 'icon_settings', 'sub_toggle' => 'tab', 'tab_slug' => 'advanced', 'mobile_options' => true, 'responsive' => true, ), 'tab_icon_active_color' => array( 'label' => esc_html__('Active Icon Color', 'dnxte-divi-essential'), 'type' => 'color-alpha', 'description' => esc_html__('Select a a color for the active tab icon.', 'dnxte-divi-essential'), 'toggle_slug' => 'icon_settings', 'sub_toggle' => 'tab', 'tab_slug' => 'advanced', 'mobile_options' => true, 'responsive' => true, ), ); $body_icon_settings = array( 'body_icon_size' => array( 'label' => esc_html__('Body Icon Size', 'dnxte-divi-essential'), 'type' => 'range', 'description' => esc_html__('Adjust the size of the icon using the slider.', 'dnxte-divi-essential'), 'default' => '20px', 'default_unit' => 'px', 'tab_slug' => 'advanced', 'toggle_slug' => 'icon_settings', 'sub_toggle' => 'body', 'mobile_options' => true, 'responsive' => true, 'range_settings' => array( 'min' => '1', 'max' => '300', 'step' => '1', ), ), 'body_icon_color' => array( 'label' => esc_html__('Icon Color', 'dnxte-divi-essential'), 'type' => 'color-alpha', 'description' => esc_html__('Select a color for the icon.', 'dnxte-divi-essential'), 'toggle_slug' => 'icon_settings', 'sub_toggle' => 'body', 'tab_slug' => 'advanced', 'mobile_options' => true, 'responsive' => true, ), ); $margin_padding = array( 'tab_wrapper_margin' => array( 'label' => esc_html__('Tab Wrapper Margin', 'dnxte-divi-essential'), 'type' => 'custom_margin', 'mobile_options' => true, 'hover' => 'tabs', 'allowed_units' => array('%', 'em', 'rem', 'px', 'cm', 'mm', 'in', 'pt', 'pc', 'ex', 'vh', 'vw'), 'option_category' => 'layout', 'tab_slug' => 'advanced', 'toggle_slug' => 'margin_padding', ), 'body_wrapper_margin' => array( 'label' => esc_html__('Body Wrapper Margin', 'dnxte-divi-essential'), 'type' => 'custom_margin', 'mobile_options' => true, 'hover' => 'tabs', 'allowed_units' => array('%', 'em', 'rem', 'px', 'cm', 'mm', 'in', 'pt', 'pc', 'ex', 'vh', 'vw'), 'option_category' => 'layout', 'tab_slug' => 'advanced', 'toggle_slug' => 'margin_padding', ), 'body_wrapper_padding' => array( 'label' => esc_html__('Body Wrapper Padding', 'dnxte-divi-essential'), 'type' => 'custom_padding', 'mobile_options' => true, 'hover' => 'tabs', 'default' => '20px|20px|20px|20px', 'allowed_units' => array('%', 'em', 'rem', 'px', 'cm', 'mm', 'in', 'pt', 'pc', 'ex', 'vh', 'vw'), 'option_category' => 'basic', 'tab_slug' => 'advanced', 'toggle_slug' => 'margin_padding', ), ); $background_opt = array( 'hover' => 'tabs', 'description' => esc_html__('Add a background fill color or gradient for the Content area.', 'dnxte-divi-essential'), ); $tab_container_bg = Common::background_fields($this, "tab_container_", "Background Color", "tab_container_bg", "general", $background_opt); $tab_single_bg = Common::background_fields($this, "tab_single_", "Single tab Background Color", "tab_container_bg", "general", $background_opt); $tab_active_bg = Common::background_fields($this, "tab_active_", "Active tab Background Color", "tab_container_bg", "general", $background_opt); $content_container_bg = Common::background_fields($this, "content_container_", "Background Color", "content_container_bg", "general", $background_opt); return array_merge($fields, $tab_settings, $tab_icon_settings, $body_icon_settings, $margin_padding, $tab_container_bg, $tab_single_bg, $tab_active_bg, $content_container_bg); } public function before_render() { global $dnxte_ad_tabs; $dnxte_ad_tabs = []; } private function render_tab_html() { global $dnxte_ad_tabs; $tab_hover_effect = isset($this->props['tab_hover_effect']) ? $this->props['tab_hover_effect'] : ''; // $arrow_svg = str_starts_with($tab_hover_effect, 'bubble') ? '' : ''; $ad_tab_html = '
%3$s