function __construct()
 {
     $i = 0;
     foreach ($this->component['structure']['element'] as $index => $value) {
         if (!is_array($value)) {
             unset($this->component['structure']['element'][$index]);
         }
     }
     $this->component['structure']['element'] = array_values($this->component['structure']['element']);
     foreach ($this->component['structure']['element'] as $index => $value) {
         $this->setDefaultElement($this->componentDefault, $value);
         if ($i == 0) {
             $this->setDefaultElement($this->componentDefault, $this->componentDescription);
             $this->componentDescription['ui']['panel'] = $value['ui']['panel'];
             $this->componentDescription['ui']['text']['header'] = __('Description', PLUGIN_PAGE_BUILDER_DOMAIN);
             $this->componentDescription['ui']['text']['subheader'] = __('Description of used component', PLUGIN_PAGE_BUILDER_DOMAIN);
             $this->component['structure']['element'][$i] = $this->componentDescription;
         }
         $i++;
         $this->component['structure']['element'][$i] = $value;
     }
     $function = PBComponentData::get($this->getComponentId(), 'component_construct');
     if (is_callable($function)) {
         $this->component = call_user_func($function, $this->component);
     }
 }
 function __construct()
 {
     $this->style = array('jquery-nivo-slider' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'jquery.nivo.slider.css'), 'nivo-slider' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('jquery-nivo-slider' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'jquery.nivo.slider.pack.js'), 'nivo-slider' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.NivoSlider.js'));
     $this->effect = array('sliceDown' => array(__('Slice down', PLUGIN_PAGE_BUILDER_DOMAIN)), 'sliceDownLeft' => array(__('Slice down left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'sliceUp' => array(__('Slice up', PLUGIN_PAGE_BUILDER_DOMAIN)), 'sliceUpLeft' => array(__('Slice up left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'sliceUpDown' => array(__('Slice up down', PLUGIN_PAGE_BUILDER_DOMAIN)), 'sliceUpDownLeft' => array(__('Slice up down left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'fold' => array(__('Fold', PLUGIN_PAGE_BUILDER_DOMAIN)), 'fade' => array(__('Fade', PLUGIN_PAGE_BUILDER_DOMAIN)), 'random' => array(__('Random', PLUGIN_PAGE_BUILDER_DOMAIN)), 'slideInRight' => array(__('Slide in right', PLUGIN_PAGE_BUILDER_DOMAIN)), 'slideInLeft' => array(__('Slide in left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'boxRandom' => array(__('Box random', PLUGIN_PAGE_BUILDER_DOMAIN)), 'boxRain' => array(__('Box rain', PLUGIN_PAGE_BUILDER_DOMAIN)), 'boxRainReverse' => array(__('Box rain reverse', PLUGIN_PAGE_BUILDER_DOMAIN)), 'boxRainGrow' => array(__('Box rain grow', PLUGIN_PAGE_BUILDER_DOMAIN)), 'boxRainGrowReverse' => array(__('Box rain grow reverse', PLUGIN_PAGE_BUILDER_DOMAIN)));
     $this->component = array('name' => __('Nivo Slider', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays Nivo Slider', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Nivo Slider', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array(array('id' => 'image', 'ui' => array('text' => array('header' => __('Images', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Click on below button to create gallery with images to the slider', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-gallery'))), array('id' => 'image_size', 'ui' => array('text' => array('header' => __('Image size', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select image size', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'image-size')), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'image_default'))), array('id' => 'url', 'ui' => array('text' => array('header' => __('URL', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'transition_effect', 'ui' => array('text' => array('header' => __('Transition effect', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select transition effect', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'checkbox', 'dictionary' => array('source' => PBHelper::extractDictionary($this->effect)))), 'shortcode' => array('default' => 'random')), array('id' => 'count_slice', 'ui' => array('text' => array('header' => __('Number of slices', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter number of slices - only for "slice" transitions', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '15')), array('id' => 'count_column', 'ui' => array('text' => array('header' => __('Number of columns', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter number of columns - only for "box" transitions', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '8')), array('id' => 'count_row', 'ui' => array('text' => array('header' => __('Number of rows', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter number of rows - only for "box" transitions', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '4')), array('id' => 'transition_speed', 'ui' => array('text' => array('header' => __('Transition speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Slide transition speed in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '500')), array('id' => 'pause_time', 'ui' => array('text' => array('header' => __('Pause time', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter value of pause time in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '3000')), array('id' => 'start_slide', 'ui' => array('text' => array('header' => __('Start slide', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter number of start slide', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '0')), array('id' => 'preloader_enable', 'ui' => array('text' => array('header' => __('Preloader', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable image slider preloader', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'direction_navigation_enable', 'ui' => array('text' => array('header' => __('Direction navigation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable Prev/Next navigation', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'control_navigation_enable', 'ui' => array('text' => array('header' => __('Control navigation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable 1,2,3 ... navigation (pagination)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'control_navigation_thumbs_enable', 'ui' => array('text' => array('header' => __('Control navigation with thumbnails', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Use thumbnails for control navigation', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'pause_on_hover', 'ui' => array('text' => array('header' => __('Pause on hover', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Stop transition when user hover on image', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'manual_advance_enable', 'ui' => array('text' => array('header' => __('Manual advance', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Force manual transitions', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'random_start_enable', 'ui' => array('text' => array('header' => __('Random at start', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Start on a random slide', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'css_class', 'ui' => array('text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space', PLUGIN_PAGE_BUILDER_DOMAIN)))))));
     parent::__construct();
 }
 function __construct()
 {
     $Header = new PBHeader();
     $Window = new PBWindow();
     $this->style = array('call-to-action' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('call-to-action' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.CallToAction.js'));
     $this->component = array('name' => __('Call To Action', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays Call To Action box', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Call To Action', PLUGIN_PAGE_BUILDER_DOMAIN)), 'ui' => array('panel' => array(1 => array('header' => __('General', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('First line', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Second line', PLUGIN_PAGE_BUILDER_DOMAIN)), 4 => array('header' => __('Button', PLUGIN_PAGE_BUILDER_DOMAIN)), 5 => array('header' => __('Box', PLUGIN_PAGE_BUILDER_DOMAIN)), 6 => array('header' => __('Border', PLUGIN_PAGE_BUILDER_DOMAIN))), 'group' => array(1 => array('header' => __('Colors', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Colors of button elements in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Padding', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Padding of the box in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Border top', PLUGIN_PAGE_BUILDER_DOMAIN)), 4 => array('header' => __('Border right', PLUGIN_PAGE_BUILDER_DOMAIN)), 5 => array('header' => __('Border bottom', PLUGIN_PAGE_BUILDER_DOMAIN)), 6 => array('header' => __('Border left', PLUGIN_PAGE_BUILDER_DOMAIN)), 7 => array('header' => __('Padding', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Padding of the button in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 8 => array('header' => __('Margin', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Margin of the button in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'element' => array(array('id' => 'css_class', 'ui' => array('panel' => 1, 'text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'first_line_text', 'ui' => array('panel' => 2, 'text' => array('header' => __('First line', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Content of the first line', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => 'first_line/@content')), array('id' => 'first_line_text_color', 'ui' => array('panel' => 2, 'text' => array('header' => __('Text color', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Text color of the first line in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'first_line/@text_color')), array('id' => 'first_line_header_important', 'ui' => array('panel' => 2, 'text' => array('header' => __('Importance of the header', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Header->important)))), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'first_line_header_important_default'), 'path' => 'first_line/@header_important')), array('id' => 'second_line_text', 'ui' => array('panel' => 3, 'text' => array('header' => __('Second line', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Content of the second line', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => 'second_line/@content')), array('id' => 'second_line_text_color', 'ui' => array('panel' => 3, 'text' => array('header' => __('Text color', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Text color of the second line in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'second_line/@text_color')), array('id' => 'second_line_header_important', 'ui' => array('panel' => 3, 'text' => array('header' => __('Importance of the header', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Header->important)))), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'second_line_header_important_default'), 'path' => 'second_line/@header_important')), array('id' => 'button_src', 'ui' => array('panel' => 4, 'text' => array('header' => __('URL', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('URL of the button', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => 'button/@src')), array('id' => 'button_target', 'ui' => array('panel' => 4, 'text' => array('header' => __('Target', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Target of the URL', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Window->linkTarget)))), 'shortcode' => array('path' => 'button/@src_target')), array('id' => 'button_label', 'ui' => array('panel' => 4, 'text' => array('header' => __('Label', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Label of the button', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => 'button/@content')), array('id' => 'button_text_color', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Text color', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@text_color')), array('id' => 'button_text_color_hover', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Text color (on hover)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@text_color_hover')), array('id' => 'button_bg_color', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Background color', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@bg_color')), array('id' => 'button_bg_color_hover', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Background color (on hover)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@bg_color_hover')), array('id' => 'button_border_color', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Border color', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@border_color')), array('id' => 'button_border_color_hover', 'ui' => array('panel' => 4, 'group' => 1, 'text' => array('label' => __('Border color (on hover)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'button/@border_color_hover')), array('id' => 'button_padding_top', 'ui' => array('panel' => 4, 'group' => 7, 'text' => array('label' => __('Top', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@padding_top')), array('id' => 'button_padding_right', 'ui' => array('panel' => 4, 'group' => 7, 'text' => array('label' => __('Right', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@padding_right')), array('id' => 'button_padding_bottom', 'ui' => array('panel' => 4, 'group' => 7, 'text' => array('label' => __('Bottom', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@padding_bottom')), array('id' => 'button_padding_left', 'ui' => array('panel' => 4, 'group' => 7, 'text' => array('label' => __('Left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@padding_left')), array('id' => 'button_margin_top', 'ui' => array('panel' => 4, 'group' => 8, 'text' => array('label' => __('Top', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@margin_top')), array('id' => 'button_margin_bottom', 'ui' => array('panel' => 4, 'group' => 8, 'text' => array('label' => __('Bottom', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => 'button/@margin_bottom')), array('id' => 'box_bg_color', 'ui' => array('panel' => 5, 'text' => array('header' => __('Background color', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Background color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => '@bg_color')), array('id' => 'box_padding_top', 'ui' => array('panel' => 5, 'group' => 2, 'text' => array('label' => __('Top', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@padding_top')), array('id' => 'box_padding_right', 'ui' => array('panel' => 5, 'group' => 2, 'text' => array('label' => __('Right', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@padding_right')), array('id' => 'box_padding_bottom', 'ui' => array('panel' => 5, 'group' => 2, 'text' => array('label' => __('Bottom', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@padding_bottom')), array('id' => 'box_padding_left', 'ui' => array('panel' => 5, 'group' => 2, 'text' => array('label' => __('Left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@padding_left')), array('id' => 'box_border_top_width', 'ui' => array('panel' => 6, 'group' => 3, 'text' => array('label' => __('Width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@border_top_width')), array('id' => 'box_border_top_color', 'ui' => array('panel' => 6, 'group' => 3, 'text' => array('label' => __('Color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => '@border_top_color')), array('id' => 'box_border_right_width', 'ui' => array('panel' => 6, 'group' => 4, 'text' => array('label' => __('Width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@border_right_width')), array('id' => 'box_border_right_color', 'ui' => array('panel' => 6, 'group' => 4, 'text' => array('label' => __('Color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => '@border_right_color')), array('id' => 'box_border_bottom_width', 'ui' => array('panel' => 6, 'group' => 5, 'text' => array('label' => __('Width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@border_bottom_width')), array('id' => 'box_border_bottom_color', 'ui' => array('panel' => 6, 'group' => 5, 'text' => array('label' => __('Color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => '@border_bottom_color')), array('id' => 'box_border_left_width', 'ui' => array('panel' => 6, 'group' => 6, 'text' => array('label' => __('Width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '4'))), 'shortcode' => array('path' => '@border_left_width')), array('id' => 'box_border_left_color', 'ui' => array('panel' => 6, 'group' => 6, 'text' => array('label' => __('Color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => '@border_left_color')))));
     parent::__construct();
 }
 function __construct()
 {
     $Easing = new PBEasing();
     $this->style = array('jquery-flexslider' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'flexslider.css'), 'flexslider' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('jquery-flexslider' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'jquery.flexslider-min.js'), 'flexslider' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.FlexSlider.js'));
     $this->animation = array('fade' => __('Fade', PLUGIN_PAGE_BUILDER_DOMAIN), 'slide' => __('Slide', PLUGIN_PAGE_BUILDER_DOMAIN));
     $this->direction = array('horizontal' => __('Horizontal', PLUGIN_PAGE_BUILDER_DOMAIN), 'vertical' => __('Vertical', PLUGIN_PAGE_BUILDER_DOMAIN));
     $this->component = array('name' => __('FlexSlider', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays FlexSlider', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('FlexSlider', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array(array('id' => 'image', 'ui' => array('text' => array('header' => __('Images', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Click on below button to create gallery with images to the slider', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-gallery'))), array('id' => 'image_size', 'ui' => array('text' => array('header' => __('Image size', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select image size', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'image-size')), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'image_default'))), array('id' => 'preloader_enable', 'ui' => array('text' => array('header' => __('Preloader', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable image slider preloader', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'url', 'ui' => array('text' => array('header' => __('URL', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => array(__('URL of site which has to be open after clicking on each image.', PLUGIN_PAGE_BUILDER_DOMAIN), __('You can set URL of separate image during editing it via Media Library.', PLUGIN_PAGE_BUILDER_DOMAIN))))), array('id' => 'animation', 'ui' => array('text' => array('header' => __('Animation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select animation type', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->animation)))), 'shortcode' => array('default' => 'fade')), array('id' => 'easing', 'ui' => array('text' => array('header' => __('Easing', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Determines the easing method used in transitions', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($Easing->easingType)))), 'shortcode' => array('default' => 'swing')), array('id' => 'direction', 'ui' => array('text' => array('header' => __('Direction', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select the sliding direction', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => $this->direction))), 'shortcode' => array('default' => 'horizontal')), array('id' => 'start_at', 'ui' => array('text' => array('header' => __('Start at', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('The slide that the slider should start on', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '0')), array('id' => 'slideshow_speed', 'ui' => array('text' => array('header' => __('Slideshow speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Set the speed of the slideshow cycling in milliseconds.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '7000')), array('id' => 'animation_speed', 'ui' => array('text' => array('header' => __('Animation speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Set the speed of animations in milliseconds.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '600')), array('id' => 'init_delay', 'ui' => array('text' => array('header' => __('Initialization delay', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Set an initialization delay in milliseconds.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '0')), array('id' => 'reverse', 'ui' => array('text' => array('header' => __('Reverse', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Reverse the animation direction', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'animation_loop', 'ui' => array('text' => array('header' => __('Animation loop', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'smooth_height', 'ui' => array('text' => array('header' => __('Smooth height', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Allow height of the slider to animate smoothly in horizontal mode', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'slideshow', 'ui' => array('text' => array('header' => __('Slideshow', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Animate slider automatically', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'randomize', 'ui' => array('text' => array('header' => __('Randomize', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Randomize slide order', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'pause_on_action', 'ui' => array('text' => array('header' => __('Pause on action', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Pause the slideshow when interacting with control elements', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'pause_on_hover', 'ui' => array('text' => array('header' => __('Pause on hover', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Pause the slideshow when hovering over slider, then resume when no longer hovering', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'use_css', 'ui' => array('text' => array('header' => __('Use CSS', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Slider will use CSS3 transitions if available', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'touch', 'ui' => array('text' => array('header' => __('Touch', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Allow touch swipe navigation of the slider on touch-enabled devices', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'control_nav', 'ui' => array('text' => array('header' => __('Control navigation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable control (1,2,3 ...) navigation', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'direction_nav', 'ui' => array('text' => array('header' => __('Direction navigation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enbale or disable direction (previous/next slide) navigation', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'keyboard', 'ui' => array('text' => array('header' => __('Keyboard', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Allow slider navigating via keyboard left/right keys', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'multiple_keyboard', 'ui' => array('text' => array('header' => __('Multiple keyboard', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => array(__('Allow keyboard navigation to affect multiple sliders.', PLUGIN_PAGE_BUILDER_DOMAIN), __('Default behavior cuts out keyboard navigation with more than one slider present.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'mousewheel', 'ui' => array('text' => array('header' => __('Mousewheel', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __(' Allows slider navigating via mousewheel.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'css_class', 'ui' => array('text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space', PLUGIN_PAGE_BUILDER_DOMAIN)))))));
     parent::__construct();
 }
 function __construct()
 {
     $Post = new PBPost();
     $Easing = new PBEasing();
     $this->style = array('zaccordion' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('jquery-zaccordion' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'jquery.zaccordion.min.js'), 'zaccordion' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.ZAccordion.js'));
     $this->dataSource = array(1 => __('Gallery', PLUGIN_PAGE_BUILDER_DOMAIN), 2 => __('Posts', PLUGIN_PAGE_BUILDER_DOMAIN));
     $this->tabOpenTriggerEvent = array('click' => __('On click', PLUGIN_PAGE_BUILDER_DOMAIN), 'mouseover' => __('On mouseover', PLUGIN_PAGE_BUILDER_DOMAIN));
     $this->component = array('name' => __('zAccordion', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays zAccordion', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('zAccordion', PLUGIN_PAGE_BUILDER_DOMAIN)), 'ui' => array('panel' => array(1 => array('header' => __('General', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Gallery', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Posts', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'element' => array(array('id' => 'data_source', 'ui' => array('panel' => 1, 'text' => array('header' => __('Data source', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => array(__('Select data source for accordion content.', PLUGIN_PAGE_BUILDER_DOMAIN), __('Accordion can be build based on gallery (images) or posts featured image. Each of them can be setup in separate tabs.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->dataSource)))), 'shortcode' => array('default' => 1)), array('id' => 'image_size', 'ui' => array('panel' => 1, 'text' => array('header' => __('Image size', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select image size', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'image-size')), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'image_default'))), array('id' => 'preloader_enable', 'ui' => array('panel' => 1, 'text' => array('header' => __('Preloader', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable image slider preloader', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'starting_slide', 'ui' => array('panel' => 1, 'text' => array('header' => __('Start slide', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enter number of start slide', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3))), 'shortcode' => array('default' => '0')), array('id' => 'timeout', 'ui' => array('panel' => 1, 'text' => array('header' => __('Timeout', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Time between each slide in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '2000')), array('id' => 'speed', 'ui' => array('panel' => 1, 'text' => array('header' => __('Speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Speed of the slide in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '500')), array('id' => 'auto', 'ui' => array('panel' => 1, 'text' => array('header' => __('Auto', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Whether or not the slideshow should play automatically', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'pause', 'ui' => array('panel' => 1, 'text' => array('header' => __('Pause', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Pause on hover', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'easing', 'ui' => array('panel' => 1, 'text' => array('header' => __('Easing', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Easing method', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($Easing->easingType)))), 'shortcode' => array('default' => 'easeInQuad')), array('id' => 'trigger', 'ui' => array('panel' => 1, 'text' => array('header' => __('Event type', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => array(__('Event type needed to open tab', PLUGIN_PAGE_BUILDER_DOMAIN), __('Accordion can be build based on gallery (images) or posts featured image. Each of them can be setup in separate tabs.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->tabOpenTriggerEvent)))), 'shortcode' => array('default' => 'click')), array('id' => 'display_slide_title', 'ui' => array('panel' => 1, 'text' => array('header' => __('Slide title', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable slide title (for posts) or caption (for images)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'display_slide_excerpt', 'ui' => array('panel' => 1, 'text' => array('header' => __('Slide excerpt', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable slide excerpt (for posts) or description (for images)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'css_class', 'ui' => array('panel' => 1, 'text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'image', 'ui' => array('panel' => 2, 'text' => array('header' => __('Images', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Click on below button to create gallery with images to the accordion', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-gallery'))), array('id' => 'url', 'ui' => array('panel' => 2, 'text' => array('header' => __('URL', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'post_type', 'ui' => array('panel' => 3, 'text' => array('header' => __('Post type', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select types of posts which have to be displayed.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'checkbox', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->postType)))), 'shortcode' => array('default' => '')), array('id' => 'post_status', 'ui' => array('panel' => 3, 'text' => array('header' => __('Post status', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select types of post statuses which have to be displayed.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'checkbox', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->postStatus)))), 'shortcode' => array('default' => '')), array('id' => 'post__in', 'ui' => array('panel' => 3, 'text' => array('header' => __('Include', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Define a comma-separated list of page ID\'s to be included to the list', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '')), array('id' => 'post__not_in', 'ui' => array('panel' => 3, 'text' => array('header' => __('Exclude', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Define a comma-separated list of page ID\'s to be excluded from the list.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '')), array('id' => 'posts_per_page', 'ui' => array('panel' => 3, 'text' => array('header' => __('Limit number of posts', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Number of posts to show. Leave this field empty to show all posts.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '-2')), array('id' => 'orderby', 'ui' => array('panel' => 3, 'text' => array('header' => __('Sort column', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->sortColumn)))), 'shortcode' => array('default' => 'date')), array('id' => 'order', 'ui' => array('panel' => 3, 'text' => array('header' => __('Sort order', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => array('asc' => __('Ascending', PLUGIN_PAGE_BUILDER_DOMAIN), 'desc' => __('Descending', PLUGIN_PAGE_BUILDER_DOMAIN))))), 'shortcode' => array('default' => 'asc')))));
     parent::__construct();
 }
 function __construct()
 {
     $Align = new PBAlign();
     $Border = new PBBorder();
     $Header = new PBheader();
     $this->style = array('box' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('box' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.Box.js'));
     $this->icon = (array) PBComponentData::get($this->getComponentId(), 'icon');
     foreach ($this->icon as $index => $value) {
         $this->icon[$index]['file'] = PBComponentData::setFile($this->getComponentId(), 'icon_feature_' . $index, $value['path']);
     }
     $this->iconPosition = array('top' => array(__('Top', PLUGIN_PAGE_BUILDER_DOMAIN)), 'right' => array(__('Right', PLUGIN_PAGE_BUILDER_DOMAIN)), 'bottom' => array(__('Bottom', PLUGIN_PAGE_BUILDER_DOMAIN)), 'left' => array(__('Left', PLUGIN_PAGE_BUILDER_DOMAIN)));
     $this->component = array('name' => __('Box', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays box', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Box', PLUGIN_PAGE_BUILDER_DOMAIN)), 'ui' => array('panel' => array(1 => array('header' => __('General', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Styles', PLUGIN_PAGE_BUILDER_DOMAIN))), 'group' => array(1 => array('header' => __('Border top', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Border top properties in order: style, width, color, radius.', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Border right', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Border right properties in order: style, width, color, radius.', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Border bottom', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Border bottom properties in order: style, width, color, radius.', PLUGIN_PAGE_BUILDER_DOMAIN)), 4 => array('header' => __('Border left', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Border left properties in order: style, width, color, radius.', PLUGIN_PAGE_BUILDER_DOMAIN)), 5 => array('header' => __('Padding', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Padding of the box in pixels in order: top, right, bottom, left.', PLUGIN_PAGE_BUILDER_DOMAIN)), 6 => array('header' => __('Text colors', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Text colors in HEX.', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'element' => array(array('id' => 'css_class', 'ui' => array('panel' => 1, 'text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'header_content', 'ui' => array('panel' => 1, 'text' => array('header' => __('Header', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Content of the header', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => 'header/@content')), array('id' => 'header_important', 'ui' => array('panel' => 1, 'text' => array('header' => __('Importance of the header', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Header->important)))), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'header_important_default'), 'path' => 'header/@important')), array('id' => 'header_align', 'ui' => array('panel' => 1, 'text' => array('header' => __('Align of the header', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Align->align)))), 'shortcode' => array('path' => 'header/@align', 'default' => 'left')), array('id' => 'text', 'ui' => array('panel' => 1, 'text' => array('header' => __('Content', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'editor')), 'visibility' => 1, 'shortcode' => array('path' => 'text/@content')), array('id' => 'icon_enable', 'ui' => array('panel' => 2, 'text' => array('header' => __('Enable icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'icon', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => $this->icon[PBComponentData::get($this->getComponentId(), 'icon_size_default')]['file'], 'use_default' => false)))), array('id' => 'icon_size', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon size', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->icon, 'label')))), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'icon_size_default'))), array('id' => 'icon_position', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon position', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->iconPosition)))), 'shortcode' => array('default' => 'left')), array('id' => 'icon_background_position', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon background position', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'background_color', 'ui' => array('panel' => 3, 'text' => array('header' => __('Background color', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Background color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_top_style', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style))))), array('id' => 'border_top_width', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Width in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_top_color', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Color in HEX:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_top_radius', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Radius in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_right_style', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style))))), array('id' => 'border_right_width', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Width in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_right_color', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Color in HEX:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_right_radius', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Radius in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_bottom_style', 'ui' => array('panel' => 3, 'group' => 3, 'text' => array('label' => __('Style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style))))), array('id' => 'border_bottom_width', 'ui' => array('panel' => 3, 'group' => 3, 'text' => array('label' => __('Width in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_bottom_color', 'ui' => array('panel' => 3, 'group' => 3, 'text' => array('label' => __('Color in HEX:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_bottom_radius', 'ui' => array('panel' => 3, 'group' => 3, 'text' => array('label' => __('Radius in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_left_style', 'ui' => array('panel' => 3, 'group' => 4, 'text' => array('label' => __('Style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style))))), array('id' => 'border_left_width', 'ui' => array('panel' => 3, 'group' => 4, 'text' => array('label' => __('Width in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'border_left_color', 'ui' => array('panel' => 3, 'group' => 4, 'text' => array('label' => __('Color in HEX:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_left_radius', 'ui' => array('panel' => 3, 'group' => 4, 'text' => array('label' => __('Radius in pixels:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'padding_top', 'ui' => array('panel' => 3, 'group' => 5, 'text' => array('label' => __('Top:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'padding_right', 'ui' => array('panel' => 3, 'group' => 5, 'text' => array('label' => __('Right:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'padding_bottom', 'ui' => array('panel' => 3, 'group' => 5, 'text' => array('label' => __('Bottom:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'padding_left', 'ui' => array('panel' => 3, 'group' => 5, 'text' => array('label' => __('Left:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 3)))), array('id' => 'text_color_content', 'ui' => array('panel' => 3, 'group' => 6, 'text' => array('label' => __('Content text color:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'text/@text_color')), array('id' => 'text_color_header', 'ui' => array('panel' => 3, 'group' => 6, 'text' => array('label' => __('Header text color:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker')), 'shortcode' => array('path' => 'header/@text_color')), array('id' => 'text_color_link', 'ui' => array('panel' => 3, 'group' => 6, 'text' => array('label' => __('Link text color:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'text_color_link_hover', 'ui' => array('panel' => 3, 'group' => 6, 'text' => array('label' => __('Link text color on hover:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))))));
     parent::__construct();
 }
    function processShortcodeLayoutColumn($attribute, $content, $tag)
    {
        $Layout = new PBLayout();
        $attribute = $this->processAttribute($tag, $attribute);
        $index = PBComponentData::get('layout', 'index');
        $layout = PBComponentData::get('layout', 'layout');
        $class = array('pb-layout-' . $Layout->getLayoutColumnCSSClass($layout, $index));
        $html = '
			<li' . PBHelper::createClassAttribute($class) . '> 
				<div class="pb-space-line"></div>
				<div>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</div>
			</li>			
		';
        PBComponentData::set('layout', 'index', $index + 1);
        return PBHelper::formatHTML($html, PBHelper::formatContent($content, true, false, false));
    }
 function __construct()
 {
     $Font = new PBFont();
     $Border = new PBBorder();
     $Window = new PBWindow();
     $this->style = array('button' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('button' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.Button.js'));
     $this->buttonSize = array('tiny' => array(__('Tiny', PLUGIN_PAGE_BUILDER_DOMAIN)), 'small' => array(__('Small', PLUGIN_PAGE_BUILDER_DOMAIN)), 'medium' => array(__('Medium', PLUGIN_PAGE_BUILDER_DOMAIN)), 'large' => array(__('Large', PLUGIN_PAGE_BUILDER_DOMAIN)));
     $this->buttonIconPosition = array('left' => array(__('Left', PLUGIN_PAGE_BUILDER_DOMAIN)), 'right' => array(__('Right', PLUGIN_PAGE_BUILDER_DOMAIN)));
     $this->icon_url = PBComponentData::get($this->getComponentId(), 'icon_url');
     $this->icon_url_retina = PBComponentData::get($this->getComponentId(), 'icon_url_retina');
     $this->icon_path = PBComponentData::get($this->getComponentId(), 'icon_path');
     $this->icon_file = PBComponentData::setFile($this->getComponentId(), 'icon_file', $this->icon_path);
     $this->component = array('name' => __('Button', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays button', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Button', PLUGIN_PAGE_BUILDER_DOMAIN)), 'ui' => array('panel' => array(1 => array('header' => __('General', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 3 => array('header' => __('Styles', PLUGIN_PAGE_BUILDER_DOMAIN))), 'group' => array(1 => array('header' => __('Normal state', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Styles used in normal (default) state', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Hover state', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Styles used in hover state', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'element' => array(array('id' => 'label', 'ui' => array('panel' => 1, 'text' => array('header' => __('Label', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Label of the button', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '@content')), array('id' => 'src', 'ui' => array('panel' => 1, 'text' => array('header' => __('URL', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('URL address of a link', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'src_target', 'ui' => array('panel' => 1, 'text' => array('header' => __('URL target', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Window->linkTarget)))), 'shortcode' => array('default' => '_self')), array('id' => 'size', 'ui' => array('panel' => 1, 'text' => array('header' => __('Button size', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->buttonSize)))), 'shortcode' => array('default' => 'medium')), array('id' => 'css_class', 'ui' => array('panel' => 1, 'text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'arrow_enable', 'ui' => array('panel' => 2, 'text' => array('header' => __('Enable arrow', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'icon_enable', 'ui' => array('panel' => 2, 'text' => array('header' => __('Enable icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '0')), array('id' => 'icon', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($this->icon_file))))), array('id' => 'icon_position', 'ui' => array('panel' => 2, 'text' => array('header' => __('Icon position', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->buttonIconPosition)))), 'shortcode' => array('default' => 'left')), array('id' => 'text_color', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Text color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'bg_color', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Background color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_style', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Border style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style)))), 'shortcode' => array('default' => '-1')), array('id' => 'border_color', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Border color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_width', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Border width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '3'))), 'shortcode' => array('default' => '0')), array('id' => 'border_radius', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Border radius in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '3'))), 'shortcode' => array('default' => '0')), array('id' => 'font_weight', 'ui' => array('panel' => 3, 'group' => 1, 'text' => array('label' => __('Font weight', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Font->weight)))), 'shortcode' => array('default' => '-1')), array('id' => 'text_color_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Text color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'bg_color_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Background color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_style_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Border style:', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Border->style)))), 'shortcode' => array('default' => '-1')), array('id' => 'border_color_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Border color in HEX', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'color-picker'))), array('id' => 'border_width_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Border width in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '3'))), 'shortcode' => array('default' => '0')), array('id' => 'border_radius_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Border radius in pixels', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => '3'))), 'shortcode' => array('default' => '0')), array('id' => 'font_weight_hover', 'ui' => array('panel' => 3, 'group' => 2, 'text' => array('label' => __('Font weight', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Font->weight)))), 'shortcode' => array('default' => '-1')))));
     parent::__construct();
 }
 function __construct()
 {
     $this->bullet = array();
     $this->bullet['file'] = array();
     $bullet = (array) PBComponentData::get($this->getComponentId(), 'bullet');
     $this->bullet['url'] = $bullet['url'];
     $this->bullet['url_retina'] = $bullet['url_retina'];
     $this->bullet['path'] = $bullet['path'];
     $this->bullet['css_class'] = $bullet['css_class'];
     $file = PBFile::scanDir($bullet['path']);
     if (is_array($file)) {
         $this->bullet['file'] = array_combine($file, $file);
     }
     $this->style = array('list' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->component = array('name' => __('List', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays list', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('List', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array(array('id' => 'bullet', 'ui' => array('text' => array('header' => __('Bullet', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select bullet of the list element', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => $this->bullet['file'])))), array('id' => 'list', 'ui' => array('text' => array('header' => __('List', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Content of the list', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'editor')), 'visibility' => 1, 'shortcode' => array('path' => '@content')), array('id' => 'css_class', 'ui' => array('text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))))));
     parent::__construct();
 }
 function __construct()
 {
     $Post = new PBPost();
     $this->style = array('sitemap' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $bullet = (array) PBComponentData::get($this->getComponentId(), 'bullet');
     $this->bullet = array();
     $this->bullet['url'] = $bullet['url'];
     $this->bullet['url_retina'] = $bullet['url_retina'];
     $this->bullet['path'] = $bullet['path'];
     $file = PBFile::scanDir($bullet['path']);
     $this->bullet['file'] = array();
     if (is_array($file)) {
         $this->bullet['file'] = array_combine($file, $file);
     }
     /***/
     $this->component = array('name' => __('Sitemap', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays Sitemap', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Sitemap', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array(array('id' => 'bullet', 'ui' => array('text' => array('header' => __('List bullet', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => $this->bullet['file'], 'use_default' => false)))), array('id' => 'post_type', 'ui' => array('text' => array('header' => __('Post type', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select types of posts which have to be displayed.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'checkbox', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->postType)))), 'shortcode' => array('default' => '')), array('id' => 'post_status', 'ui' => array('text' => array('header' => __('Post status', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select types of post statuses which have to be displayed.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'checkbox', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->postStatus)))), 'shortcode' => array('default' => '')), array('id' => 'post__in', 'ui' => array('text' => array('header' => __('Include', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Define a comma-separated list of page ID\'s to be included to the list', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '')), array('id' => 'post__not_in', 'ui' => array('text' => array('header' => __('Exclude', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Define a comma-separated list of page ID\'s to be excluded from the list.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '')), array('id' => 'posts_per_page', 'ui' => array('text' => array('header' => __('Limit number of posts', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Number of posts to show. Leave this field empty to show all posts.', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('default' => '-2')), array('id' => 'orderby', 'ui' => array('text' => array('header' => __('Sort column', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($Post->sortColumn)))), 'shortcode' => array('default' => 'date')), array('id' => 'order', 'ui' => array('text' => array('header' => __('Sort order', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => array('asc' => __('Ascending', PLUGIN_PAGE_BUILDER_DOMAIN), 'desc' => __('Descending', PLUGIN_PAGE_BUILDER_DOMAIN))))), 'shortcode' => array('default' => 'asc')), array('id' => 'css_class', 'ui' => array('text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))))));
     parent::__construct();
 }
 function createCSS($code = null, $retina = false)
 {
     $CSS = new PBCSS();
     $key = $retina ? 'icon_url_retina' : 'icon_url';
     $codeCurrent = null;
     foreach ($this->social as $index => $value) {
         $codeCurrent .= $CSS->create(array('selector' => array('ul.pb-social-icon>li>a.pb-social-icon-' . $index), 'property' => array('background-image' => PBComponentData::get($this->getComponentId(), $key) . $value[1])));
     }
     if ($retina) {
         $codeCurrent = $CSS->getRetinaMediaQuery($codeCurrent);
     }
     $code .= $codeCurrent;
     if (PBData::get('retina_ready') == 1 && !$retina) {
         $this->createCSS($code, true);
         return;
     }
     PBComponentData::set($this->getComponentId(), 'css', $code);
 }
 function __construct()
 {
     $Easing = new PBEasing();
     $this->icon_url = PBComponentData::get($this->getComponentId(), 'icon_url');
     $this->icon_path = PBComponentData::get($this->getComponentId(), 'icon_path');
     $this->icon_file = PBComponentData::setFile($this->getComponentId(), 'icon_file', $this->icon_path);
     if (PBData::get('retina_ready') == 1) {
         $this->icon_url_retina = PBComponentData::get($this->getComponentId(), 'icon_url_retina');
     }
     add_theme_support('menus');
     add_filter('wp_setup_nav_menu_item', array($this, 'setupNavigationMenuItemField'));
     add_action('wp_update_nav_menu_item', array($this, 'updateNavigationMenuItemField'), 10, 3);
     add_filter('wp_edit_nav_menu_walker', array($this, 'editNavigationMenuWalker'), 10, 2);
     $this->style = array('menu' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'), 'responsive-nav' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'responsive-nav.css'));
     $this->script = array('responsive-nav' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'responsive-nav.min.js'), 'superfish' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'superfish.js'), 'menu' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.Menu.js'));
     $ResponsiveMode = new PBResponsiveMode();
     $this->responiveMode = $ResponsiveMode->getDictionary();
     $this->component = array('name' => __('Menu + Logo', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays Menu and logo', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Menu + Logo', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array(array('id' => 'logo_src', 'ui' => array('text' => array('header' => __('Logo', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select a image file', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-image'))), array('id' => 'menu_id', 'ui' => array('text' => array('header' => __('Menu', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select a menu', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->getMenuDictionary()))))), array('id' => 'responsive_mode', 'ui' => array('text' => array('header' => __('Responsive menu', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable responsive menu when screen width (in px) is less than selected', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->responiveMode), 'use_default' => true))), 'shortcode' => array('default' => PBComponentData::get($this->getComponentId(), 'responsive_menu_default'))), array('id' => 'sticky_enable', 'ui' => array('text' => array('header' => __('Sticky menu', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable sticky menu', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'hide_scroll_enable', 'ui' => array('text' => array('header' => __('Hide menu on scroll', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Hide menu when page is scrolled', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'menu_animation_enable', 'ui' => array('text' => array('header' => __('Menu animation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable menu animation', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'menu_animation_speed_open', 'ui' => array('text' => array('header' => __('Menu opening speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Speed of the opening animation in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '400')), array('id' => 'menu_animation_speed_close', 'ui' => array('text' => array('header' => __('Menu closing speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Speed of the closing animation in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '200')), array('id' => 'menu_animation_delay', 'ui' => array('text' => array('header' => __('Menu delay', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('The delay in milliseconds that the mouse can remain outside a submenu without it closing', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '800')), array('id' => 'scroll_animation_enable', 'ui' => array('text' => array('header' => __('Scrolling animation', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Enable or disable animation during page scrolling (after clicking on menu item)', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'choice-2')), 'shortcode' => array('default' => '1')), array('id' => 'scroll_animation_speed', 'ui' => array('text' => array('header' => __('Scrolling speed', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Speed of the scrolling in miliseconds', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('attribute' => array('maxlength' => 5))), 'shortcode' => array('default' => '1000')), array('id' => 'scroll_animation_easing', 'ui' => array('text' => array('header' => __('Scrolling easing', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Type of easing for scrolling animation.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($Easing->easingType)))), 'shortcode' => array('default' => 'easeOutQuint')), array('id' => 'css_class', 'ui' => array('text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))))));
     parent::__construct();
 }
    function processShortcodeList($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $Validation = new PBValidation();
        if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'gr') {
            $classBullet = null;
            if ($Validation->isNotEmpty($attribute['bullet'])) {
                $classBullet = 'pb-list-icon-name-' . PBHelper::createHash($attribute['bullet']);
            }
            $class = array('pb-list', 'pb-list-icon-type-gr', $classBullet, $attribute['css_class']);
        } else {
            $class = array('pb-list', 'pb-list-icon-type-fa', $attribute['css_class']);
        }
        $id = PBHelper::createId('pb_list');
        $html = '<div' . PBHelper::createClassAttribute($class) . ' id="' . esc_attr($id) . '">' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</div>';
        if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'fa' && $Validation->isNotEmpty($attribute['font_icon_name'])) {
            $option = array();
            $option['icon_type'] = 'fa';
            if ($Validation->isNotEmpty($attribute['font_icon_name'])) {
                $option['font_icon_name'] = $attribute['font_icon_name'];
            }
            if ($Validation->isColor($attribute['font_icon_color'])) {
                $option['font_icon_color'] = $attribute['font_icon_color'];
            }
            if ($Validation->isNumber($attribute['font_icon_size'], 1, 200)) {
                $option['font_icon_size'] = $attribute['font_icon_size'];
            }
            $html .= '
				<div class="pb-script-tag">
					<script type="text/javascript">
						jQuery(document).ready(function($)
						{
							$(\'#' . $id . '\').PBList(' . json_encode($option) . ');
						});
					</script>
				</div>
			';
        }
        return PBHelper::formatHTML($html, $content);
    }
 function __construct()
 {
     $Background = new PBBackground();
     $bullet = (array) PBComponentData::get($this->getComponentId(), 'bullet');
     $this->bullet = array();
     $this->bullet['url'] = $bullet['url'];
     $this->bullet['url_retina'] = $bullet['url_retina'];
     $this->bullet['path'] = $bullet['path'];
     $file = PBFile::scanDir($bullet['path']);
     $this->bullet['file'] = array();
     if (is_array($file)) {
         $this->bullet['file'] = array_combine($file, $file);
     }
     $Layout = new PBLayout();
     $this->currentIndex = 0;
     $this->currentLayout = null;
     $this->style = array('pricing-plan' => array('use' => 2, 'path' => $this->getStyleURL(), 'file' => 'style.css'));
     $this->script = array('pricing-plan' => array('use' => 2, 'path' => $this->getScriptURL(), 'file' => 'PB.PricingPlan.js'));
     $this->type = array('1' => array(__('Type 1', PLUGIN_PAGE_BUILDER_DOMAIN)), '2' => array(__('Type 2', PLUGIN_PAGE_BUILDER_DOMAIN)));
     $this->layout = $Layout->getMainLayout();
     $this->component = array('name' => __('Pricing Plan', PLUGIN_PAGE_BUILDER_DOMAIN), 'description' => __('Displays Pricing Plan', PLUGIN_PAGE_BUILDER_DOMAIN), 'structure' => array('window' => array('title' => __('Pricing Plan', PLUGIN_PAGE_BUILDER_DOMAIN)), 'ui' => array('panel' => array(1 => array('header' => __('General', PLUGIN_PAGE_BUILDER_DOMAIN)), 2 => array('header' => __('Plans', PLUGIN_PAGE_BUILDER_DOMAIN))), 'multi' => array(1 => array('header' => __('Content of the plan', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'element' => array(array('id' => 'layout', 'ui' => array('panel' => 1, 'text' => array('header' => __('Layout', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select layout of the pricing plan.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($this->layout, 'name')))), 'shortcode' => array('default' => '50x50')), array('id' => 'type', 'ui' => array('panel' => 1, 'text' => array('header' => __('Type', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select one from the available types.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'radio', 'dictionary' => array('source' => PBHelper::extractDictionary($this->type)))), 'shortcode' => array('default' => '1')), array('id' => 'css_class', 'ui' => array('panel' => 1, 'text' => array('header' => __('CSS class', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of CSS classes defined in CSS files separated by space.', PLUGIN_PAGE_BUILDER_DOMAIN)))), array('id' => 'item_header', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Header', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/item_header/@content')), array('id' => 'item_description', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Description', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'textarea')), 'shortcode' => array('path' => '*item/item_description/@content')), array('id' => 'item_feature', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Feature list', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('List of features separated by new line.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'textarea')), 'shortcode' => array('path' => '*item/item_feature/@content')), array('id' => 'item_feature_bullet', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Feature list bullet', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Bullet for the feature list elements', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => $this->bullet['file'], 'use_default' => false))), 'shortcode' => array('path' => '*item/item_feature/@bullet')), array('id' => 'item_image_url', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Image URL', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select image of the background. This option works only with type named "Style 2".', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-image')), 'shortcode' => array('path' => '*item/@image_url')), array('id' => 'item_image_position', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Image position', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/@image_position')), array('id' => 'item_image_repeat', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Image repeat', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Select type of background repeat.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($Background->backgroundRepeat)))), 'shortcode' => array('path' => '*item/@image_repeat')), array('id' => 'item_image_size_a', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Image size', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => __('Specify the image size. For options "Length" and "Percentage" you have to specify these values in next field.', PLUGIN_PAGE_BUILDER_DOMAIN)), 'element' => array('type' => 'select-one', 'dictionary' => array('source' => PBHelper::extractDictionary($Background->backgroundSize)))), 'shortcode' => array('path' => '*item/@image_size_a')), array('id' => 'item_image_size_b', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Image size', PLUGIN_PAGE_BUILDER_DOMAIN), 'subheader' => array(__('Sets the width and height of the background image.', PLUGIN_PAGE_BUILDER_DOMAIN), __('Sets the width and height of the background image in percent of the parent element.', PLUGIN_PAGE_BUILDER_DOMAIN), __('The first value sets the width, the second value sets the height. If only one value is given, the second is set to "auto"', PLUGIN_PAGE_BUILDER_DOMAIN)))), 'shortcode' => array('path' => '*item/@image_size_b')), array('id' => 'item_button_label', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Button label', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/item_button/@content')), array('id' => 'item_button_url', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Button URL', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/item_button/@url')), array('id' => 'item_price_value', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Price', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/item_price/item_price_value/@content')), array('id' => 'item_price_suffix', 'ui' => array('panel' => 2, 'multi' => 1, 'text' => array('header' => __('Price suffix', PLUGIN_PAGE_BUILDER_DOMAIN))), 'shortcode' => array('path' => '*item/item_price/item_price_suffix/@content')))));
     parent::__construct();
 }
    function processShortcodeTabNavigationHeader($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $style = array();
        $Validation = new PBValidation();
        if ($Validation->isNumber(PBComponentData::get('tab', 'header_font_size'), 1, 100, false)) {
            $style['font-size'] = PBComponentData::get('tab', 'header_font_size') . 'px';
        }
        $html = '
			<li><a href="#"' . PBHelper::createStyleAttribute($style) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</a><span></span></li>
		';
        return PBHelper::formatHTML($html, $content);
    }
    function processShortcodeGallery($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $html = null;
        $elementHTML = null;
        $Layout = new PBLayout();
        $Validation = new PBValidation();
        $ImageHover = new PBImageHover();
        $file = PBFile::getImage(explode(',', $attribute['image']));
        if ($file === false) {
            return $html;
        }
        if (!count($file->posts)) {
            return $html;
        }
        if (!PBFile::isWPImage($attribute['image_size'])) {
            return $html;
        }
        if (!array_key_exists($attribute['layout'], $this->layout)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['hover_enable'])) {
            return $html;
        }
        if (!array_key_exists($attribute['hover_type'], $ImageHover->type)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['caption_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['preloader_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['description_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['layout_full_width_enable'])) {
            return $html;
        }
        $key = array('hover_type', 'hover_enable', 'preloader_enable', 'layout_full_width_enable');
        foreach ($key as $index) {
            $option[$index] = $attribute[$index];
        }
        $id = PBHelper::createId('pb_gallery');
        global $post;
        $bPost = $post;
        $i = 0;
        while ($file->have_posts()) {
            global $post;
            $file->the_post();
            $full = wp_get_attachment_image_src(get_post_thumbnail_id(), 'full');
            $thumbnail = wp_get_attachment_image_src(get_post_thumbnail_id(), $attribute['image_size']);
            $meta = PBMeta::get($post);
            PBHelper::removeUIndex($meta, 'media_library_video_url', 'media_library_url');
            $class = array();
            $class[0] = array('pb-layout-' . $Layout->getLayoutColumnCSSClass($attribute['layout'], $i));
            $class[1] = array('pb-image-box');
            $class[2] = array('pb-image');
            if ($attribute['preloader_enable'] == 1) {
                array_push($class[1], 'pb-image-preloader', 'pb-image-preloader-animation-enable');
            }
            if ($attribute['hover_enable'] == 1) {
                array_push($class[1], 'pb-image-hover', 'pb-image-hover-type-' . $attribute['hover_type']);
            }
            /****/
            $imageTextHTML = null;
            if ($Validation->isNotEmpty($post->post_excerpt) && $attribute['caption_enable'] == 1) {
                $imageTextHTML .= '<' . PBComponentData::get($this->getComponentId(), 'image_text_caption_header_tag') . ' class="pb-image-text-caption">' . get_the_excerpt() . '</' . PBComponentData::get($this->getComponentId(), 'image_text_caption_header_tag') . '>';
            }
            if ($Validation->isNotEmpty($post->post_content) && $attribute['description_enable'] == 1) {
                $imageTextHTML .= '<div class="pb-image-text-description">' . get_the_content() . '</div>';
            }
            if ($Validation->isNotEmpty($imageTextHTML)) {
                $imageTextHTML = '<div class="pb-image-text">' . $imageTextHTML . '</div>';
            }
            if ($Validation->isNotEmpty($imageTextHTML)) {
                $imageTextHTML .= '<div class="pb-image-text-fancybox"><b>' . get_the_excerpt() . '</b> ' . get_the_content() . '</div>';
            }
            /****/
            $url = null;
            $rel = null;
            if ($Validation->isVideoURL($meta['media_library_video_url'])) {
                $url = $meta['media_library_video_url'];
                array_push($class[1], 'pb-image-type-video');
            } elseif ($Validation->isURL($meta['media_library_url'])) {
                $url = $meta['media_library_url'];
                array_push($class[1], 'pb-image-type-link');
            } else {
                $rel = $id;
                $url = $full[0];
                array_push($class[1], 'pb-image-type-image');
            }
            /****/
            $imageHTML = null;
            if ($attribute['hover_enable'] == 1) {
                $imageHTML = '<a href="' . $url . '"' . PBHelper::createClassAttribute($class[2]) . ($Validation->isEmpty($rel) ? null : ' data-fancybox-group="' . esc_attr($rel) . '"') . '><img src="' . $thumbnail[0] . '" alt=""/><span><span><span></span></span></span></a>';
            } else {
                $imageHTML = '<div' . PBHelper::createClassAttribute($class[2]) . '><img src="' . $thumbnail[0] . '" alt=""/></div>';
            }
            /****/
            if ($Validation->isNotEmpty($imageTextHTML)) {
                array_push($class[1], 'pb-image-text-enable');
            }
            $elementHTML .= '<li' . PBHelper::createClassAttribute($class[0]) . '><div' . PBHelper::createClassAttribute($class[1]) . '>' . $imageHTML . $imageTextHTML . '</div></li>';
            $i++;
        }
        wp_reset_query();
        $post = $bPost;
        $class = array();
        $class[0] = array('pb-gallery', 'pb-clear-fix', $attribute['css_class']);
        $class[1] = array($Layout->getLayoutCSSClass($attribute['layout']), 'pb-reset-list', 'pb-clear-fix');
        if ($attribute['layout_full_width_enable'] == 1) {
            array_push($class[1], 'pb-layout-full-width');
        }
        $html = '
			<div' . PBHelper::createClassAttribute($class[0]) . ' id="' . $id . '">
				<ul' . PBHelper::createClassAttribute($class[1]) . '>
					' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '
				</ul>			
			</div>
			<div class="pb-script-tag">
				<script type="text/javascript">
					jQuery(document).ready(function($)
					{
						$(\'#' . $id . '\').PBGallery(' . json_encode($option) . ');
					});
				</script>
			</div>
		';
        return PBHelper::formatHTML($html, $elementHTML);
    }
    function processShortcodeCounterBoxItemHeader($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $html = null;
        $Validation = new PBValidation();
        if ($Validation->isEmpty($content)) {
            return $html;
        }
        $html = '
			<h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . PBHelper::createClassAttribute(array('pb-counter-box-header')) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . '>
		';
        return PBHelper::formatHTML($html, $content);
    }
    function processShortcodeSocialIcon($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $html = null;
        $style = array();
        $social = array();
        $Window = new PBWindow();
        $Validation = new PBValidation();
        if (!array_key_exists($attribute['target'], $Window->linkTarget)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['native_color_enable'])) {
            return $html;
        }
        foreach ($this->social as $index => $value) {
            $url = 'profile_' . $index . '_url';
            $order = 'profile_' . $index . '_order';
            PBHelper::removeUIndex($attribute, $url, $order);
            if (!$Validation->isURL($attribute[$url])) {
                continue;
            }
            $orderValue = (int) $attribute[$order];
            $socialData = array('id' => $index, 'url' => $attribute[$url], 'name' => $value[1]);
            if ($Validation->isNumber($attribute[$order], 0, 99)) {
                if (isset($social[$orderValue])) {
                    array_push($social, $socialData);
                } else {
                    $social[$orderValue] = $socialData;
                }
            } else {
                array_push($social, $socialData);
            }
        }
        ksort($social);
        if (!count($social)) {
            return;
        }
        $option = array('in' => array(), 'out' => array());
        if ($Validation->isNumber($attribute['width'], 0, 999)) {
            $style['width'] = $attribute['width'] . 'px';
        }
        if ($Validation->isNumber($attribute['height'], 0, 999)) {
            $style['height'] = $attribute['height'] . 'px';
        }
        if (PBComponentData::get($this->getComponentId(), 'icon_type') !== 'gr') {
            if ($Validation->isNumber($attribute['font_icon_size'], 1, 200)) {
                $style['font-size'] = $attribute['font_icon_size'] . 'px';
            }
        }
        $borderRadius = null;
        if ($Validation->isNumber($attribute['border_radius_top_left'], 0, 999)) {
            $borderRadius .= ' ' . $attribute['border_radius_top_left'] . 'px';
        }
        if ($Validation->isNumber($attribute['border_radius_top_right'], 0, 999)) {
            $borderRadius .= ' ' . $attribute['border_radius_top_right'] . 'px';
        }
        if ($Validation->isNumber($attribute['border_radius_bottom_right'], 0, 999)) {
            $borderRadius .= ' ' . $attribute['border_radius_bottom_right'] . 'px';
        }
        if ($Validation->isNumber($attribute['border_radius_bottom_left'], 0, 999)) {
            $borderRadius .= ' ' . $attribute['border_radius_bottom_left'] . 'px';
        }
        if ($Validation->isNotEmpty($borderRadius)) {
            $borderRadius = trim($borderRadius);
            $style['-webkit-border-radius'] = $borderRadius;
            $style['-moz-border-radius'] = $borderRadius;
            $style['border-radius'] = $borderRadius;
        }
        if ($Validation->isNumber($attribute['border_width'], 0, 999)) {
            $style['border-style'] = 'solid';
            $style['border-width'] = $attribute['border_width'] . 'px';
            $option['out']['border-width'] = $style['border-width'];
            $option['out']['border-style'] = 'solid';
        }
        if ($Validation->isColor($attribute['bg_color'])) {
            $style['background-color'] = PBColor::getColor($attribute['bg_color']);
            $option['out']['background-color'] = $style['background-color'];
        }
        if (PBComponentData::get($this->getComponentId(), 'icon_type') == 'fa') {
            if ($Validation->isColor($attribute['icon_color'])) {
                $style['color'] = PBColor::getColor($attribute['icon_color']);
                $option['out']['color'] = $style['color'];
            }
        }
        if ($Validation->isColor($attribute['border_color'])) {
            $style['border-color'] = PBColor::getColor($attribute['border_color']);
            $option['out']['border-color'] = $style['border-color'];
        }
        if ($Validation->isNumber($attribute['border_width_hover'], 0, 999)) {
            $option['in']['border-width'] = $attribute['border_width_hover'] . 'px';
            $option['in']['border-style'] = 'solid';
        }
        if ($Validation->isColor($attribute['bg_color_hover'])) {
            $option['in']['background-color'] = PBColor::getColor($attribute['bg_color_hover']);
        }
        if (PBComponentData::get($this->getComponentId(), 'icon_type') == 'fa') {
            if ($Validation->isColor($attribute['font_icon_color_hover'])) {
                $option['in']['color'] = PBColor::getColor($attribute['font_icon_color_hover']);
            }
        }
        if ($Validation->isColor($attribute['border_color_hover'])) {
            $option['in']['border-color'] = PBColor::getColor($attribute['border_color_hover']);
        }
        foreach ($social as $index => $value) {
            $class = array('pb-social-icon-' . $value['id']);
            $iconHTML = null;
            if (PBComponentData::get($this->getComponentId(), 'icon_type') == 'fa') {
                $iconHTML = '<i class="fa fa-' . esc_html($value['name']) . '"></i>';
            }
            array_push($class, $Window->getTargetCSSClass($attribute['target']));
            $html .= '
				<li><a href="' . esc_attr($value['url']) . '"' . PBHelper::createClassAttribute($class) . PBHelper::createStyleAttribute($style) . '>' . $iconHTML . '</a></li>
			';
        }
        $id = PBHelper::createId('pb_social_icon');
        $class = array('pb-social-icon');
        if ($attribute['native_color_enable'] == 1) {
            array_push($class, 'pb-social-icon-color-native');
        }
        if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'gr') {
            array_push($class, 'pb-social-icon-type-gr');
        } elseif (PBComponentData::get($this->getComponentId(), 'icon_type') === 'fa') {
            array_push($class, 'pb-social-icon-type-fa');
        }
        array_push($class, 'pb-reset-list', 'pb-clear-fix', $attribute['css_class']);
        $html = '
			<ul' . PBHelper::createClassAttribute($class) . ' id="' . esc_attr($id) . '">
				' . $html . '
			</ul>
			<div class="pb-script-tag">
				<script type="text/javascript">
					jQuery(document).ready(function($)
					{
						$(\'#' . $id . '\').PBSocialIcon(' . json_encode($option) . ');
					});
				</script>
			</div>
		';
        return PBHelper::formatHTML($html);
    }
    function processShortcodeTeam($attribute, $content, $tag)
    {
        $html = null;
        $teamHTML = null;
        $option = array();
        $attribute = $this->processAttribute($tag, $attribute);
        $Window = new PBWindow();
        $Easing = new PBEasing();
        $Layout = new PBLayout();
        $Validation = new PBValidation();
        $ImageHover = new PBImageHover();
        $data = $this->getTeam($attribute);
        if ($data === false) {
            return;
        }
        if (!count($data->posts)) {
            return;
        }
        if (!array_key_exists($attribute['template'], $this->template)) {
            return $html;
        }
        if (!array_key_exists($attribute['layout'], $this->layout)) {
            return $html;
        }
        if (!PBFile::isWPImage($attribute['image_size'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['hover_enable'])) {
            return $html;
        }
        if (!array_key_exists($attribute['hover_type'], $ImageHover->type)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['preloader_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['skill_list_waypoint_enable'])) {
            return $html;
        }
        if (!$Validation->isNumber($attribute['skill_list_waypoint_duration'], 0, 99999)) {
            return $html;
        }
        if (!array_key_exists($attribute['skill_list_waypoint_easing'], $Easing->easingType)) {
            return $html;
        }
        $key = array('hover_type', 'hover_enable', 'preloader_enable', 'skill_list_waypoint_enable', 'skill_list_waypoint_easing', 'skill_list_waypoint_duration', 'skill_list_waypoint_offset_trigger');
        foreach ($key as $index) {
            $option[$index] = $attribute[$index];
        }
        $layoutCurrent = '100';
        if ($attribute['template'] == 2) {
            $layoutCurrent = '50x50';
        } elseif ($attribute['template'] == 3) {
            $layoutCurrent = $attribute['layout'];
        }
        global $post;
        $bPost = $post;
        $i = 0;
        while ($data->have_posts()) {
            global $post;
            $data->the_post();
            $full = wp_get_attachment_image_src(get_post_thumbnail_id(), 'full');
            $thumbnail = wp_get_attachment_image_src(get_post_thumbnail_id(), $attribute['image_size']);
            if ($full == false || $thumbnail == false) {
                continue;
            }
            $meta = PBMeta::get($post);
            PBHelper::removeUIndex($meta, 'team_social', 'team_skill');
            /***/
            $class = array(array(), array());
            $class[0] = array('pb-layout-' . $Layout->getLayoutColumnCSSClass($layoutCurrent, $i));
            $class[1] = array('pb-image-box', 'pb-image-preloader-animation-enable');
            $class[2] = array('pb-image');
            if ($attribute['preloader_enable'] == 1) {
                array_push($class[1], 'pb-image-preloader');
            }
            if ($attribute['hover_enable'] == 1) {
                array_push($class[1], 'pb-image-hover', 'pb-image-hover-type-' . $attribute['hover_type'], 'pb-image-type-image');
            }
            /***/
            $textHTML = null;
            if ($Validation->isNotEmpty($meta['team_first_name']) || $Validation->isNotEmpty($meta['team_second_name'])) {
                $textHTML .= '<h3 class="pb-team-text-box-member-name">' . trim($meta['team_first_name'] . ' ' . $meta['team_second_name']) . '</h3>';
            }
            if ($Validation->isNotEmpty($meta['team_position'])) {
                $textHTML .= '<div class="pb-team-text-box-member-position">' . $meta['team_position'] . '</div>';
            }
            /***/
            $socialHTML = null;
            if (is_array($meta['team_social'])) {
                $social = PBHelper::orderArrayByElement($meta['team_social'], 'team_social_order');
                foreach ($social as $index => $value) {
                    if (!array_key_exists($value['team_social_name'], $this->social)) {
                        continue;
                    }
                    $socialHTML .= '
						<li>
							<a href="' . esc_attr($value['team_social_url']) . '" class="pb-team-social-icon-' . $value['team_social_name'] . ' ' . $Window->getTargetCSSClass('_blank') . '"></a>
						</li>
					';
                }
                if ($Validation->isNotEmpty($socialHTML)) {
                    $socialHTML = '
						<ul class="pb-team-social-icon-box pb-reset-list pb-clear-fix">
							' . $socialHTML . '
						</ul>
					';
                }
            }
            /***/
            $skillHTML = null;
            if (is_array($meta['team_skill'])) {
                $skill = PBHelper::orderArrayByElement($meta['team_skill'], 'team_skill_order');
                foreach ($skill as $index => $value) {
                    if (!$Validation->isNumber($value['team_skill_level'], 0, 100)) {
                        continue;
                    }
                    $skillHTML .= '
						<div class="pb-team-skill pb-value-' . (int) $value['team_skill_level'] . '">
							<span class="pb-team-skill-label">' . esc_html($value['team_skill_name']) . '</span>
							<span class="pb-team-skill-value">
								<span class="pb-team-skill-value-value">' . (int) $value['team_skill_level'] . '</span>
								<span class="pb-team-skill-value-character-after">%</span>
							</span>
							<span class="pb-team-skill-foreground"></span>
							<span class="pb-team-skill-background"></span>						
						</div>
					';
                }
                if ($Validation->isNotEmpty($skillHTML)) {
                    $skillHTML = '
						<div class="pb-team-skill-box">
							' . $skillHTML . '
						</div>
					';
                }
            }
            /***/
            $imageTextHTML = null;
            if ($Validation->isNotEmpty($meta['team_first_name']) || $Validation->isNotEmpty($meta['team_second_name'])) {
                $imageTextHTML .= '<' . PBComponentData::get($this->getComponentId(), 'image_text_caption_header_tag') . ' class="pb-image-text-caption">' . trim($meta['team_first_name'] . ' ' . $meta['team_second_name']) . '</' . PBComponentData::get($this->getComponentId(), 'image_text_caption_header_tag') . '>';
            }
            if ($Validation->isNotEmpty($meta['team_position'])) {
                $imageTextHTML .= '<div class="pb-image-text-description">' . $meta['team_position'] . '</div>';
            }
            if ($Validation->isNotEmpty($imageTextHTML)) {
                $imageTextHTML = '<div class="pb-image-text">' . $imageTextHTML . '</div>';
            }
            /***/
            $imageHTML = null;
            if ($attribute['hover_enable'] == 1) {
                $imageHTML = '<a href="' . $full[0] . '"' . PBHelper::createClassAttribute($class[2]) . '><img src="' . $thumbnail[0] . '" alt=""/><span><span><span></span></span></span></a>';
            } else {
                $imageHTML = '<div' . PBHelper::createClassAttribute($class[2]) . '><img src="' . $thumbnail[0] . '" alt=""/></div>';
            }
            if ($Validation->isNotEmpty($imageTextHTML)) {
                array_push($class[1], 'pb-image-text-enable');
            }
            $imageBoxHTML = '<div' . PBHelper::createClassAttribute($class[1]) . '>' . $imageHTML . $imageTextHTML . '</div>';
            /***/
            $teamHTML .= '
				<li' . PBHelper::createClassAttribute($class[0]) . '>
			';
            switch ($attribute['template']) {
                case 1:
                    $teamHTML .= '<div class="pb-layout-33x66 pb-clear-fix"><div class="pb-layout-column-left">' . $imageBoxHTML . $socialHTML . '</div><div class="pb-layout-column-right"><div class="pb-team-text-box">' . $textHTML . apply_filters('the_content', do_shortcode(get_the_content())) . '</div>' . $skillHTML . '</div></div>';
                    break;
                case 2:
                    $teamHTML .= '<div class="pb-layout-50x50 pb-clear-fix"><div class="pb-layout-column-left">' . $imageBoxHTML . '</div><div class="pb-layout-column-right"><div class="pb-team-quote-box"></div><div class="pb-team-text-box">' . apply_filters('the_content', do_shortcode(get_the_content())) . '</div>' . $socialHTML . '</div></div>';
                    break;
                case 3:
                    $teamHTML .= '<div>' . $imageBoxHTML . $socialHTML . '</div>';
                    break;
            }
            $teamHTML .= '
				</li>
			';
            $i++;
        }
        wp_reset_query();
        $post = $bPost;
        if ($Validation->isEmpty($teamHTML)) {
            return;
        }
        $id = PBHelper::createId('pb_team');
        $class = array();
        $class[0] = array('pb-team', 'pb-team-template-' . $attribute['template'], 'pb-clear-fix', $attribute['css_class']);
        $class[1] = array('pb-layout-' . $layoutCurrent, 'pb-reset-list', 'pb-clear-fix');
        $html = '
			<div' . PBHelper::createClassAttribute($class[0]) . ' id="' . $id . '">
				<ul' . PBHelper::createClassAttribute($class[1]) . '>
					' . $teamHTML . '
				</ul>			
			</div>
			<div class="pb-script-tag">
				<script type="text/javascript">
					jQuery(document).ready(function($)
					{
						$(\'#' . $id . '\').PBTeam(' . json_encode($option) . ');
					});
				</script>
			</div>
		';
        return $html;
    }
    function processShortcodeSitemap($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $html = null;
        $Validation = new PBValidation();
        $argument = array();
        if ($Validation->isNotEmpty($attribute['post_type'])) {
            $argument['post_type'] = explode(',', $attribute['post_type']);
        }
        if ($Validation->isNotEmpty($attribute['post_status'])) {
            $argument['post_status'] = explode(',', $attribute['post_status']);
        }
        if ($Validation->isNotEmpty($attribute['post__in'])) {
            $argument['post__in'] = explode(',', $attribute['post__in']);
        }
        if ($Validation->isNotEmpty($attribute['post__not_in'])) {
            $argument['post__not_in'] = explode(',', $attribute['post__not_in']);
        }
        if ($Validation->isNotEmpty($attribute['posts_per_page'])) {
            $argument['posts_per_page'] = $attribute['posts_per_page'] == -2 ? -1 : $attribute['posts_per_page'];
        }
        if ($Validation->isNotEmpty($attribute['orderby'])) {
            $argument['orderby'] = $attribute['orderby'];
        }
        if ($Validation->isNotEmpty($attribute['order'])) {
            $argument['order'] = $attribute['order'];
        }
        $query = new WP_Query($argument);
        if ($query === false) {
            return $html;
        }
        if ($query->post_count == 0) {
            return $html;
        }
        $class = array(array('pb-sitemap'), array('pb-reset-list'));
        if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'gr') {
            if (array_key_exists($attribute['bullet'], $this->bullet['file'])) {
                array_push($class[0], 'pb-sitemap-icon-type-gr', 'pb-sitemap-icon-name-' . PBHelper::createHash($attribute['bullet']));
            }
        }
        $iconHTML = null;
        if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'fa') {
            if ($Validation->isNotEmpty($attribute['font_icon_name'])) {
                $style = array();
                if ($Validation->isColor($attribute['font_icon_color'])) {
                    $style['color'] = PBColor::getColor($attribute['font_icon_color']);
                }
                if ($Validation->isNumber($attribute['font_icon_size'], 1, 200)) {
                    $style['font-size'] = $attribute['font_icon_size'] . 'px';
                }
                array_push($class[0], 'pb-sitemap-icon-type-fa');
                $iconHTML = '<i class="fa fa-' . esc_attr($attribute['font_icon_name']) . '"' . PBHelper::createStyleAttribute($style) . '></i>';
            }
        }
        global $post;
        $bPost = $post;
        while ($query->have_posts()) {
            $query->the_post();
            $html .= '
				<li id="post-' . get_the_ID() . '" class="' . implode(' ', get_post_class()) . '">
					' . $iconHTML . '
					<a href="' . get_the_permalink() . '">' . preg_replace('/\\<br\\/\\>/', ' ', get_the_title()) . '</a>
				</li>
			';
        }
        $post = $bPost;
        $html = '
			<div' . PBHelper::createClassAttribute($class[0]) . '>
				<ul' . PBHelper::createClassAttribute($class[1]) . '>' . $html . '</ul>
			</div>
		';
        return PBHelper::formatHTML($html);
    }
    function processShortcodeNoticeFirstLine($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $style = array();
        $Validation = new PBValidation();
        if ($Validation->isColor($attribute['text_color'])) {
            $style['color'] = PBColor::getColor($attribute['text_color']);
        }
        $class = array('pb-notice-first-line');
        $html = '
			<h' . PBComponentData::get($this->getComponentId(), 'first_line_header_important_default') . PBHelper::createClassAttribute($class) . PBHelper::createStyleAttribute($style) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</h' . PBComponentData::get($this->getComponentId(), 'first_line_header_important_default') . '>
		';
        return PBHelper::formatHTML($html, $content);
    }
    function processShortcodeAccordionPanelHeader($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $style = array();
        $Validation = new PBValidation();
        if ($Validation->isNumber(PBComponentData::get('accordion', 'header_font_size'), 1, 100, false)) {
            $style['font-size'] = PBComponentData::get('accordion', 'header_font_size') . 'px';
        }
        $html = '
			<h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . '><a href="#"' . PBHelper::createStyleAttribute($style) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '<span></span></a></h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . '>
		';
        return PBHelper::formatHTML($html, $content);
    }
    function processShortcodeRecentPost($attribute, $content, $tag)
    {
        $attribute = $this->processAttribute($tag, $attribute);
        $html = null;
        $Layout = new PBLayout();
        $Validation = new PBValidation();
        $ImageHover = new PBImageHover();
        if (!PBFile::isWPImage($attribute['image_size'])) {
            return $html;
        }
        if (!array_key_exists($attribute['layout'], $this->layout)) {
            return $html;
        }
        if (!array_key_exists($attribute['template'], $this->template)) {
            return $html;
        }
        if (!$Validation->isNumber($attribute['post_count'], 1, 999)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['preloader_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['hover_enable'])) {
            return $html;
        }
        if (!array_key_exists($attribute['hover_type'], $ImageHover->type)) {
            return $html;
        }
        if (!$Validation->isBool($attribute['date_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['image_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['header_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['author_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['excerpt_enable'])) {
            return $html;
        }
        if (!$Validation->isBool($attribute['category_enable'])) {
            return $html;
        }
        $option = array();
        $key = array('hover_type', 'hover_enable', 'preloader_enable');
        foreach ($key as $index) {
            $option[$index] = $attribute[$index];
        }
        $data = $this->getPost($attribute);
        if ($data === false) {
            return null;
        }
        if (!count($data->posts)) {
            return null;
        }
        $i = 0;
        global $post;
        $bPost = $post;
        while ($data->have_posts()) {
            $data->the_post();
            $class = array('pb-layout-' . $Layout->getLayoutColumnCSSClass($attribute['layout'], $i));
            $meta = array('date' => null, 'comment_count' => null, 'image' => null, 'header' => null, 'excerpt' => null, 'meta' => null);
            if ($attribute['date_enable']) {
                $meta['date'] = '<div class="pb-recent-post-date">' . get_the_date() . '</div>';
            }
            if ($attribute['image_enable']) {
                if (has_post_thumbnail()) {
                    $commentCountHTML = null;
                    if ($attribute['template'] == 1) {
                        if ($attribute['comment_count_enable'] == 1 && comments_open(get_the_id())) {
                            $commentCount = wp_count_comments(get_the_id());
                            $commentCountHTML = '<div class="pb-recent-post-comment-count"><span class="pb-recent-post-comment-count-value">' . $commentCount->approved . '</span><span class="pb-recent-post-comment-count-arrow"></span></div>';
                        }
                    }
                    $classImage = array(array('pb-recent-post-image', 'pb-image-box'), array('pb-image'));
                    if ($attribute['preloader_enable'] == 1) {
                        array_push($classImage[0], 'pb-image-preloader', 'pb-image-preloader-animation-enable');
                    }
                    if ($attribute['hover_enable'] == 1) {
                        array_push($classImage[0], 'pb-image-hover', 'pb-image-hover-type-' . $attribute['hover_type']);
                    }
                    if ($attribute['hover_enable'] == 1) {
                        $meta['image'] = '<a href="' . get_permalink(get_the_ID()) . '"' . PBHelper::createClassAttribute($classImage[1]) . '>' . get_the_post_thumbnail(get_the_ID(), $attribute['image_size']) . '<span><span><span></span></span></span></a>';
                    } else {
                        $meta['image'] = '<div' . PBHelper::createClassAttribute($classImage[1]) . '>' . get_the_post_thumbnail(get_the_ID(), $attribute['image_size']) . '</div>';
                    }
                    $meta['image'] = '<div' . PBHelper::createClassAttribute($classImage[0]) . '>' . $meta['image'] . $commentCountHTML . '</div>';
                }
            }
            if ($attribute['header_enable']) {
                $meta['header'] = '<h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . ' class="pb-recent-post-header"><a href="' . get_permalink(get_the_ID()) . '">' . get_the_title() . '</a></h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . '>';
            }
            if ($attribute['excerpt_enable']) {
                $meta['excerpt'] = '<div class="pb-recent-post-excerpt">' . get_the_excerpt() . '</div>';
            }
            if ($attribute['author_enable'] || $attribute['category_enable'] || $attribute['template'] == 2 && $attribute['comment_count_enable'] == 1 && comments_open(get_the_id())) {
                $authorHTML = null;
                $categoryHTML = null;
                $commentCountHTML = null;
                if ($attribute['author_enable']) {
                    $authorHTML = '<div class="pb-recent-post-meta-author">' . get_the_author() . '</div>';
                }
                $category = get_the_category(get_the_ID());
                $count = count($category);
                if ($count) {
                    foreach ($category as $index => $value) {
                        $separator = $index == $count - 1 ? '' : ',&nbsp;';
                        $title = $Validation->isEmpty($value->description) ? sprintf(__('View all posts filed under %s', PLUGIN_PAGE_BUILDER_DOMAIN), $value->name) : strip_tags(apply_filters('category_description', $value->description, $value));
                        $categoryHTML .= '<li><a href="' . get_category_link($value->term_id) . '" title="' . esc_attr($title) . '">' . esc_html($value->name) . '</a>' . $separator . '</li>';
                    }
                    $categoryHTML = '<div class="pb-recent-post-meta-category"><ul class="pb-reset-list">' . $categoryHTML . '</ul></div>';
                }
                if ($attribute['template'] == 2) {
                    if ($attribute['comment_count_enable'] == 1 && comments_open(get_the_id())) {
                        $commentCount = wp_count_comments(get_the_id());
                        $commentCountHTML = '<div class="pb-recent-post-meta-comment-count">' . __(sprintf('%d Comments', $commentCount->approved), PLUGIN_PAGE_BUILDER_DOMAIN) . '</div>';
                    }
                }
                $meta['meta'] = '<div class="pb-recent-post-meta pb-clear-fix">' . $authorHTML . $categoryHTML . $commentCountHTML . '</div>';
            }
            $templateHTML = array();
            $templateOrder = array('date', 'image', 'header', 'excerpt', 'meta');
            if ($attribute['template'] == 2) {
                $templateOrder = array('image', 'header', 'date', 'excerpt', 'meta');
            }
            foreach ($templateOrder as $value) {
                if (isset($meta[$value])) {
                    $templateHTML[$value] = $meta[$value];
                }
            }
            $html .= '<li' . PBHelper::createClassAttribute($class) . '><div>' . implode($templateHTML) . '</div></li>';
            $i++;
        }
        wp_reset_query();
        $post = $bPost;
        $id = PBHelper::createId('pb_recent_post');
        $class = array();
        $class[0] = array('pb-recent-post', 'pb-recent-post-template-' . $attribute['template'], $attribute['css_class']);
        $class[1] = array('pb-clear-fix', 'pb-reset-list', $Layout->getLayoutCSSClass($attribute['layout']));
        $html = '
			<div' . PBHelper::createClassAttribute($class[0]) . ' id="' . $id . '">
				<ul' . PBHelper::createClassAttribute($class[1]) . '>
					' . $html . '
				</ul>
			</div>
			<div class="pb-script-tag">
				<script type="text/javascript">
					jQuery(document).ready(function($) 
					{
						$("#' . $id . '").PBRecentPost(' . json_encode($option) . ');
					});
				</script>
			</div>
		';
        return PBHelper::formatHTML($html);
    }
 function createCSSFile()
 {
     $content = null;
     $component = PBData::get('component');
     $Validation = new PBValidation();
     foreach ($component as $componentName => $componentData) {
         $className = 'PBComponent' . $this->formatName($componentName);
         $Component = new $className();
         if (method_exists($Component, 'createCSS')) {
             $Component->createCSS();
             $css = PBComponentData::get($componentName, 'css');
             if ($Validation->isNotEmpty($css)) {
                 $content .= $css . "\n\n";
             }
         }
     }
     $file = PBData::get('theme_path_multisite_style') . 'PB.Frontend.css';
     $WPFileSystem = new PBWPFileSystem();
     if ($WPFileSystem->put_contents($file, $content, 0755) === false) {
         return false;
     }
     return true;
 }
 function processShortcodeFeatureItemHeader($attribute, $content, $tag)
 {
     $attribute = $this->processAttribute($tag, $attribute);
     $html = null;
     $Window = new PBWindow();
     $Validation = new PBValidation();
     if ($Validation->isEmpty($content)) {
         return $html;
     }
     if (!array_key_exists($this->attrItemURLTarget, $Window->linkTarget)) {
         return $html;
     }
     $content = do_shortcode($content);
     if ($Validation->isNotEmpty($this->attrItemURL)) {
         $class = array($Window->getTargetCSSClass($this->attrItemURLTarget));
         $content = '<a href="' . esc_attr($this->attrItemURL) . '"' . PBHelper::createClassAttribute($class) . '>' . $content . '</a>';
     }
     $class = array('pb-feature-header');
     $html = '<h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . PBHelper::createClassAttribute($class) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</h' . PBComponentData::get($this->getComponentId(), 'header_important_default') . '>';
     return PBHelper::formatHTML($html, $content);
 }