Ejemplo n.º 1
0
 private function _add_additional_border_fields()
 {
     if (!isset($this->advanced_options['border'])) {
         return;
     }
     $additional_options = array();
     $color_type = isset($this->advanced_options['border']['settings']['color']) && 'alpha' === $this->advanced_options['border']['settings']['color'] ? 'color-alpha' : 'color';
     $additional_options['use_border_color'] = array('label' => __('Use Border', 'et_builder'), 'type' => 'yes_no_button', 'option_category' => 'layout', 'options' => array('off' => __('No', 'et_builder'), 'on' => __('Yes', 'et_builder')), 'affects' => array('#et_pb_border_color', '#et_pb_border_width', '#et_pb_border_style'), 'shortcode_default' => 'off', 'tab_slug' => 'advanced');
     $additional_options['border_color'] = array('label' => __('Border Color', 'et_builder'), 'type' => $color_type, 'option_category' => 'layout', 'default' => '#ffffff', 'shortcode_default' => '#ffffff', 'tab_slug' => 'advanced', 'depends_default' => true);
     $additional_options['border_width'] = array('label' => __('Border Width', 'et_builder'), 'type' => 'range', 'option_category' => 'layout', 'default' => '1px', 'shortcode_default' => '1px', 'tab_slug' => 'advanced', 'depends_default' => true);
     $additional_options['border_style'] = array('label' => __('Border Style', 'et_builder'), 'type' => 'select', 'option_category' => 'layout', 'options' => et_builder_get_border_styles(), 'shortcode_default' => 'solid', 'tab_slug' => 'advanced', 'depends_default' => true);
     $this->_additional_fields_options = array_merge($this->_additional_fields_options, $additional_options);
 }
Ejemplo n.º 2
0
 function get_fields()
 {
     $fields = array('color' => array('label' => __('Color', 'et_builder'), 'type' => 'color-alpha', 'description' => __('This will adjust the color of the 1px divider line.', 'et_builder')), 'show_divider' => array('label' => __('Visibility', 'et_builder'), 'type' => 'select', 'option_category' => 'configuration', 'options' => $this->show_divider_options, 'affects' => array('#et_pb_divider_style', '#et_pb_divider_position', '#et_pb_divider_weight'), 'description' => __('This settings turns on and off the 1px divider line, but does not affect the divider height.', 'et_builder')), 'height' => array('label' => __('Height', 'et_builder'), 'type' => 'text', 'option_category' => 'layout', 'description' => __('Define how much space should be added below the divider.', 'et_builder')), 'admin_label' => array('label' => __('Admin Label', 'et_builder'), 'type' => 'text', 'description' => __('This will change the label of the module in the builder for easy identification.', 'et_builder')), 'module_id' => array('label' => __('CSS ID', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'description' => __('Enter an optional CSS ID to be used for this module. An ID can be used to create custom CSS styling, or to create links to particular sections of your page.', 'et_builder')), 'module_class' => array('label' => __('CSS Class', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'description' => __('Enter optional CSS classes to be used for this module. A CSS class can be used to create custom CSS styling. You can add multiple classes, separated with a space.', 'et_builder')), 'divider_style' => array('label' => __('Divider Style', 'et_builder'), 'type' => 'select', 'option_category' => 'layout', 'options' => et_builder_get_border_styles(), 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'divider_position' => array('label' => __('Divider Position', 'et_builder'), 'type' => 'select', 'option_category' => 'layout', 'options' => array('top' => __('Top', 'et_builder'), 'center' => __('Vertically Centered', 'et_builder'), 'bottom' => __('Bottom', 'et_builder')), 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'divider_weight' => array('label' => __('Divider Weight', 'et_builder'), 'type' => 'range', 'option_category' => 'layout', 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'hide_on_mobile' => array('label' => __('Hide On Mobile', 'et_builder'), 'type' => 'yes_no_button', 'option_category' => 'layout', 'options' => array('on' => __('Yes', 'et_builder'), 'off' => __('No', 'et_builder')), 'tab_slug' => 'advanced'));
     return $fields;
 }
Ejemplo n.º 3
0
 function get_fields()
 {
     $fields = array('color' => array('label' => esc_html__('Color', 'et_builder'), 'type' => 'color-alpha', 'description' => esc_html__('This will adjust the color of the 1px divider line.', 'et_builder')), 'show_divider' => array('label' => esc_html__('Visibility', 'et_builder'), 'type' => 'select', 'option_category' => 'configuration', 'options' => $this->show_divider_options, 'affects' => array('divider_style', 'divider_position', 'divider_weight'), 'description' => esc_html__('This settings turns on and off the 1px divider line, but does not affect the divider height.', 'et_builder')), 'height' => array('label' => esc_html__('Height', 'et_builder'), 'type' => 'text', 'option_category' => 'layout', 'description' => esc_html__('Define how much space should be added below the divider.', 'et_builder')), 'divider_style' => array('label' => esc_html__('Divider Style', 'et_builder'), 'type' => 'select', 'option_category' => 'layout', 'options' => et_builder_get_border_styles(), 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'divider_position' => array('label' => esc_html__('Divider Position', 'et_builder'), 'type' => 'select', 'option_category' => 'layout', 'options' => array('top' => esc_html__('Top', 'et_builder'), 'center' => esc_html__('Vertically Centered', 'et_builder'), 'bottom' => esc_html__('Bottom', 'et_builder')), 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'divider_weight' => array('label' => esc_html__('Divider Weight', 'et_builder'), 'type' => 'range', 'option_category' => 'layout', 'depends_show_if' => 'on', 'tab_slug' => 'advanced'), 'hide_on_mobile' => array('label' => esc_html__('Hide On Mobile', 'et_builder'), 'type' => 'yes_no_button', 'option_category' => 'layout', 'options' => array('on' => esc_html__('Yes', 'et_builder'), 'off' => esc_html__('No', 'et_builder')), 'tab_slug' => 'advanced'), 'disabled_on' => array('label' => esc_html__('Disable on', 'et_builder'), 'type' => 'multiple_checkboxes', 'options' => array('phone' => esc_html__('Phone', 'et_builder'), 'tablet' => esc_html__('Tablet', 'et_builder'), 'desktop' => esc_html__('Desktop', 'et_builder')), 'additional_att' => 'disable_on', 'option_category' => 'configuration', 'description' => esc_html__('This will disable the module on selected devices', 'et_builder')), 'admin_label' => array('label' => esc_html__('Admin Label', 'et_builder'), 'type' => 'text', 'description' => esc_html__('This will change the label of the module in the builder for easy identification.', 'et_builder')), 'module_id' => array('label' => esc_html__('CSS ID', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'tab_slug' => 'custom_css', 'option_class' => 'et_pb_custom_css_regular'), 'module_class' => array('label' => esc_html__('CSS Class', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'tab_slug' => 'custom_css', 'option_class' => 'et_pb_custom_css_regular'));
     return $fields;
 }