?
Current File : /home/c/i/d/cideo/www/wp-includesVIp/js/crop/images/vendors.tar
plugins/class-vc-vendor-qtranslate-x.php000066600000005004151262607420014375 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * Class Vc_Vendor_QtranslateX
 * @since 4.12
 */
class Vc_Vendor_QtranslateX implements Vc_Vendor_Interface {

	public function load() {
		add_action( 'vc_backend_editor_render', array( $this, 'enqueueJsBackend' ) );
		add_action( 'vc_frontend_editor_render', array( $this, 'enqueueJsFrontend' ) );
		add_filter( 'vc_frontend_editor_iframe_url',
			array(
				$this,
				'appendLangToUrl',
			) );

		add_filter( 'vc_nav_front_controls',
			array(
				$this,
				'vcNavControlsFrontend',
			) );

		if ( ! vc_is_frontend_editor() ) {
			add_filter( 'vc_get_inline_url',
				array(
					$this,
					'vcRenderEditButtonLink',
				) );
		}
	}

	public function enqueueJsBackend() {
		wp_enqueue_script( 'vc_vendor_qtranslatex_backend',
			vc_asset_url( 'js/vendors/qtranslatex_backend.js' ),
			array( 'vc-backend-min-js', 'jquery' ),
			'1.0',
			true );
	}

	public function appendLangToUrl( $link ) {
		global $q_config;
		if ( $q_config && isset( $q_config['language'] ) ) {
			return add_query_arg( array( 'lang' => ( $q_config['language'] ) ), $link );
		}

		return $link;
	}

	public function enqueueJsFrontend() {
		wp_enqueue_script( 'vc_vendor_qtranslatex_frontend',
			vc_asset_url( 'js/vendors/qtranslatex_frontend.js' ),
			array( 'vc-frontend-editor-min-js', 'jquery' ),
			'1.0',
			true );
	}

	/**
	 * @return string
	 */
	public function generateSelectFrontend() {
		global $q_config;
		$output = '';
		$output .= '<select id="vc_vendor_qtranslatex_langs_front" class="vc_select vc_select-navbar">';
		$inline_url = vc_frontend_editor()->getInlineUrl();
		$activeLanguage = $q_config['language'];
		$availableLanguages = $q_config['enabled_languages'];
		foreach ( $availableLanguages as $lang ) {
			$output .= '<option value="' . add_query_arg( array( 'lang' => $lang ),
					$inline_url ) . '"' . ( $activeLanguage == $lang ? ' selected' : '' ) . ' > ' . qtranxf_getLanguageNameNative( $lang ) . '</option > ';
		}
		$output .= '</select > ';

		return $output;
	}

	/**
	 * @param $list
	 *
	 * @return array
	 */
	public function vcNavControlsFrontend( $list ) {
		if ( is_array( $list ) ) {
			$list[] = array(
				'qtranslatex',
				'<li class="vc_pull-right" > ' . $this->generateSelectFrontend() . '</li > ',
			);
		}

		return $list;
	}

	/**
	 * @param $link
	 *
	 * @return string
	 */
	public function vcRenderEditButtonLink( $link ) {
		global $q_config;
		$activeLanguage = $q_config['language'];

		return add_query_arg( array( 'lang' => $activeLanguage ), $link );
	}
}
plugins/class-vc-vendor-ninja-forms.php000066600000004625151262607420014205 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * Ninja Forms vendor
 * @since 4.4
 */
class Vc_Vendor_NinjaForms implements Vc_Vendor_Interface {

	/**
	 * Implement interface, map ninja forms shortcode
	 * @since 4.4
	 */
	public function load() {
		vc_lean_map( 'ninja_forms_display_form', array(
			$this,
			'addShortcodeSettings',
		) );

	}

	/**
	 * Add Shortcode To Visual Composer
	 *
	 * @param array $ninja_forms - list of ninja forms (ID->NAME)
	 *
	 * @since 4.4
	 *
	 * @deprecated 4.9
	 */
	public function mapNinjaForms( $ninja_forms = array() ) {
		// We map only ninja_forms_display_form shortcode same as contact-form-7
		vc_map( array(
				'base' => 'ninja_forms_display_form',
				'name' => __( 'Ninja Forms', 'js_composer' ),
				'icon' => 'icon-wpb-ninjaforms',
				'category' => __( 'Content', 'js_composer' ),
				'description' => __( 'Place Ninja Form', 'js_composer' ),
				'params' => array(
					array(
						'type' => 'dropdown',
						'heading' => __( 'Select ninja form', 'js_composer' ),
						'param_name' => 'id',
						'value' => $ninja_forms,
						'save_always' => true,
						'description' => __( 'Choose previously created ninja form from the drop down list.', 'js_composer' ),
					),
				),
			) );
	}

	/**
	 * Mapping settings for lean method.
	 *
	 * @since 4.9
	 *
	 * @param $tag
	 *
	 * @return array
	 */
	public function addShortcodeSettings( $tag ) {
		if ( ! function_exists( 'ninja_forms_get_all_forms' ) ) {
			// experimental, maybe not needed
			require_once( NINJA_FORMS_DIR . '/includes/database.php' );
		}
		$ninja_forms_data = ninja_forms_get_all_forms();
		$ninja_forms = array();
		if ( ! empty( $ninja_forms_data ) ) {
			// Fill array with Name=>Value(ID)
			foreach ( $ninja_forms_data as $key => $value ) {
				if ( is_array( $value ) ) {
					$ninja_forms[ $value['name'] ] = $value['id'];
				}
			}
		}

		return array(
			'base' => $tag,
			'name' => __( 'Ninja Forms', 'js_composer' ),
			'icon' => 'icon-wpb-ninjaforms',
			'category' => __( 'Content', 'js_composer' ),
			'description' => __( 'Place Ninja Form', 'js_composer' ),
			'params' => array(
				array(
					'type' => 'dropdown',
					'heading' => __( 'Select ninja form', 'js_composer' ),
					'param_name' => 'id',
					'value' => $ninja_forms,
					'save_always' => true,
					'description' => __( 'Choose previously created ninja form from the drop down list.', 'js_composer' ),
				),
			),
		);
	}
}
plugins/class-vc-vendor-contact-form7.php000066600000003511151262607420014436 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * Contact form7 vendor
 * =======
 * Plugin Contact form 7 vendor
 * To fix issues when shortcode doesn't exists in frontend editor. #1053, #1054 etc.
 * @since 4.3
 */
class Vc_Vendor_ContactForm7 implements Vc_Vendor_Interface {

	/**
	 * Add action when contact form 7 is initialized to add shortcode.
	 * @since 4.3
	 */
	public function load() {

		vc_lean_map( 'contact-form-7',
			array(
				$this,
				'addShortcodeSettings',
			) );
	}

	/**
	 * Mapping settings for lean method.
	 *
	 * @since 4.9
	 *
	 * @param $tag
	 *
	 * @return array
	 */
	public function addShortcodeSettings( $tag ) {
		/**
		 * Add Shortcode To Visual Composer
		 */
		$cf7 = get_posts( 'post_type="wpcf7_contact_form"&numberposts=-1' );

		$contact_forms = array();
		if ( $cf7 ) {
			foreach ( $cf7 as $cform ) {
				$contact_forms[ $cform->post_title ] = $cform->ID;
			}
		} else {
			$contact_forms[ __( 'No contact forms found', 'js_composer' ) ] = 0;
		}

		return array(
			'base' => $tag,
			'name' => __( 'Contact Form 7', 'js_composer' ),
			'icon' => 'icon-wpb-contactform7',
			'category' => __( 'Content', 'js_composer' ),
			'description' => __( 'Place Contact Form7', 'js_composer' ),
			'params' => array(
				array(
					'type' => 'dropdown',
					'heading' => __( 'Select contact form', 'js_composer' ),
					'param_name' => 'id',
					'value' => $contact_forms,
					'save_always' => true,
					'description' => __( 'Choose previously created contact form from the drop down list.', 'js_composer' ),
				),
				array(
					'type' => 'textfield',
					'heading' => __( 'Search title', 'js_composer' ),
					'param_name' => 'title',
					'admin_label' => true,
					'description' => __( 'Enter optional title to search if no ID selected or cannot find by ID.', 'js_composer' ),
				),
			),
		);
	}
}
plugins/class-vc-vendor-yoast_seo.php000066600000004776151262607420013776 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * Class Vc_Vendor_YoastSeo
 * @since 4.4
 */
class Vc_Vendor_YoastSeo implements Vc_Vendor_Interface {

	/**
	 * Created to improve yoast multiply calling wpseo_pre_analysis_post_content filter.
	 * @since 4.5.3
	 * @var string - parsed post content
	 */
	protected $parsedContent;

	function __construct() {
		add_action( 'vc_backend_editor_render', array(
			&$this,
			'enqueueJs',
		) );
	}

	/**
	 * Add filter for yoast.
	 * @since 4.4
	 */
	public function load() {
		if ( class_exists( 'WPSEO_Metabox' ) && ( 'admin_page' === vc_mode() || 'admin_frontend_editor' === vc_mode() ) ) {
			add_filter( 'wpseo_pre_analysis_post_content', array(
				&$this,
				'filterResults',
			) );
		}
	}

	/**
	 * Properly parse content to detect images/text keywords.
	 * @since 4.4
	 *
	 * @param $content
	 *
	 * @return string
	 */
	public function filterResults( $content ) {
		if ( empty( $this->parsedContent ) ) {
			global $post, $wp_the_query;
			$wp_the_query->post = $post; // since 4.5.3 to avoid the_post replaces
			/**
			 * @since 4.4.3
			 * vc_filter: vc_vendor_yoastseo_filter_results
			 */
			do_action( 'vc_vendor_yoastseo_filter_results' );
			$this->parsedContent = do_shortcode( shortcode_unautop( $content ) );
			wp_reset_query();
		}

		return $this->parsedContent;
	}

	/**
	 * @since 4.4
	 */
	public function enqueueJs() {
		wp_enqueue_script( 'vc_vendor_yoast_js', vc_asset_url( 'js/vendors/yoast.js' ), array( 'yoast-seo-admin-global-script' ), WPB_VC_VERSION, true );
	}

	public function frontendEditorBuild() {
		$vc_yoast_meta_box = $GLOBALS['wpseo_metabox'];
		remove_action( 'admin_init', array( $GLOBALS['wpseo_meta_columns'], 'setup_hooks' ) );
		apply_filters( 'wpseo_use_page_analysis', false );
		remove_action( 'add_meta_boxes', array($vc_yoast_meta_box, 'add_meta_box' ) );
		remove_action( 'admin_enqueue_scripts', array( $vc_yoast_meta_box, 'enqueue' ) );
		remove_action( 'wp_insert_post', array( $vc_yoast_meta_box, 'save_postdata' ) );
		remove_action( 'edit_attachment', array( $vc_yoast_meta_box, 'save_postdata' ) );
		remove_action( 'add_attachment', array( $vc_yoast_meta_box, 'save_postdata' ) );
		remove_action( 'post_submitbox_start', array( $vc_yoast_meta_box, 'publish_box' ) );
		remove_action( 'admin_init', array( $vc_yoast_meta_box, 'setup_page_analysis' ) );
		remove_action( 'admin_init', array( $vc_yoast_meta_box, 'translate_meta_boxes' ) );
		remove_action( 'admin_footer', array( $vc_yoast_meta_box, 'template_keyword_tab' ) );
	}
}
plugins/acf/class-vc-gitem-acf-shortcode.php000066600000003051151262607420015034 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

class Vc_Gitem_Acf_Shortcode extends WPBakeryShortCode {
	/**
	 * @param $atts
	 * @param null $content
	 *
	 * @return mixed|void
	 */
	protected function content( $atts, $content = null ) {
		$field_key = $label = '';
		/**
		 * @var string $el_class
		 * @var string $show_label
		 * @var string $align
		 * @var string $field_group
		 */
		extract( shortcode_atts( array(
			'el_class' => '',
			'field_group' => '',
			'show_label' => '',
			'align' => '',
		), $atts ) );
		if ( 0 === strlen( $field_group ) ) {
			$groups = function_exists( 'acf_get_field_groups' ) ? acf_get_field_groups() : apply_filters( 'acf/get_field_groups', array() );
			if ( is_array( $groups ) && isset( $groups[0] ) ) {
				$key = isset( $groups[0]['id'] ) ? 'id' : ( isset( $groups[0]['ID'] ) ? 'ID' : 'id' );
				$field_group = $groups[0][ $key ];
			}
		}
		if ( ! empty( $field_group ) ) {
			$field_key = ! empty( $atts[ 'field_from_' . $field_group ] ) ? $atts[ 'field_from_' . $field_group ] : 'field_from_group_' . $field_group;
		}
		if ( 'yes' === $show_label && $field_key ) {
			$field_key .= '_labeled';
		}
		$css_class = 'vc_gitem-acf'
		             . ( strlen( $el_class ) ? ' ' . $el_class : '' )
		             . ( strlen( $align ) ? ' vc_gitem-align-' . $align : '' )
		             . ( strlen( $field_key ) ? ' ' . $field_key : '' );

		return '<div ' . $field_key . ' class="' . esc_attr( $css_class ) . '">'
		       . '{{ acf' . ( ! empty( $field_key ) ? ':' . $field_key : '' ) . ' }}'
		       . '</div>';
	}
}
plugins/acf/grid-item-attributes.php000066600000002622151262607420013547 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * Get ACF data
 *
 * @param $value
 * @param $data
 *
 * @return string
 */
function vc_gitem_template_attribute_acf( $value, $data ) {
	$label = '';
	/**
	 * @var null|Wp_Post $post ;
	 * @var string $data ;
	 */
	extract( array_merge( array(
		'post' => null,
		'data' => '',
	), $data ) );

	if ( strstr( $data, 'field_from_group_' ) ) {
		$group_id = preg_replace( '/(^field_from_group_|_labeled$)/', '', $data );
		$fields = function_exists( 'acf_get_fields' ) ? acf_get_fields( $group_id ) : apply_filters( 'acf/field_group/get_fields', array(), $group_id );
		$field = is_array( $fields ) && isset( $fields[0] ) ? $fields[0] : false;
		if ( is_array( $field ) && isset( $field['key'] ) ) {
			$data = $field['key'] . ( strstr( $data, '_labeled' ) ? '_labeled' : '' );
		}
	}
	$label = '';
	if ( preg_match( '/_labeled$/', $data ) ) {
		$data = preg_replace( '/_labeled$/', '', $data );
		$field = get_field_object( $data );
		$label = is_array( $field ) && isset( $field['label'] ) ? '<span class="vc_gitem-acf-label">' . $field['label'] . ':</span> ' : '';
	}

	$value = '';
	if ( $data ) {
		$value = do_shortcode( '[acf field="' . $data . '" post_id="' . $post->ID . '"]' );
	}

	return $label . apply_filters( 'vc_gitem_template_attribute_acf_value', $value );
}

add_filter( 'vc_gitem_template_attribute_acf', 'vc_gitem_template_attribute_acf', 10, 2 );
plugins/acf/grid-item-shortcodes.php000066600000005323151262607420013537 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

$groups = function_exists( 'acf_get_field_groups' ) ? acf_get_field_groups() : apply_filters( 'acf/get_field_groups', array() );
$groups_param_values = $fields_params = array();
foreach ( $groups as $group ) {
	$id = isset( $group['id'] ) ? 'id' : ( isset( $group['ID'] ) ? 'ID' : 'id' );
	$groups_param_values[ $group['title'] ] = $group[ $id ];
	$fields = function_exists( 'acf_get_fields' ) ? acf_get_fields( $group[ $id ] ) : apply_filters( 'acf/field_group/get_fields', array(), $group[ $id ] );
	$fields_param_value = array();
	foreach ( $fields as $field ) {
		$fields_param_value[ $field['label'] ] = (string) $field['key'];
	}
	$fields_params[] = array(
		'type' => 'dropdown',
		'heading' => __( 'Field name', 'js_composer' ),
		'param_name' => 'field_from_' . $group[ $id ],
		'value' => $fields_param_value,
		'save_always' => true,
		'description' => __( 'Select field from group.', 'js_composer' ),
		'dependency' => array(
			'element' => 'field_group',
			'value' => array( (string) $group[ $id ] ),
		),
	);
}

return array(
	'vc_gitem_acf' => array(
		'name' => __( 'Advanced Custom Field', 'js_composer' ),
		'base' => 'vc_gitem_acf',
		'icon' => 'vc_icon-acf',
		'category' => __( 'Content', 'js_composer' ),
		'description' => __( 'Advanced Custom Field', 'js_composer' ),
		'php_class_name' => 'Vc_Gitem_Acf_Shortcode',
		'params' => array_merge(
			array(
				array(
					'type' => 'dropdown',
					'heading' => __( 'Field group', 'js_composer' ),
					'param_name' => 'field_group',
					'value' => $groups_param_values,
					'save_always' => true,
					'description' => __( 'Select field group.', 'js_composer' ),
				),
			), $fields_params,
			array(
				array(
					'type' => 'checkbox',
					'heading' => __( 'Show label', 'js_composer' ),
					'param_name' => 'show_label',
					'value' => array( __( 'Yes', 'js_composer' ) => 'yes' ),
					'description' => __( 'Enter label to display before key value.', 'js_composer' ),
				),
				array(
					'type' => 'dropdown',
					'heading' => __( 'Align', 'js_composer' ),
					'param_name' => 'align',
					'value' => array(
						__( 'left', 'js_composer' ) => 'left',
						__( 'right', 'js_composer' ) => 'right',
						__( 'center', 'js_composer' ) => 'center',
						__( 'justify', 'js_composer' ) => 'justify',
					),
					'description' => __( 'Select alignment.', 'js_composer' ),
				),
				array(
					'type' => 'textfield',
					'heading' => __( 'Extra class name', 'js_composer' ),
					'param_name' => 'el_class',
					'description' => __( 'Style particular content element differently - add a class name and refer to it in custom CSS.', 'js_composer' ),
				),
			)
		),
		'post_type' => Vc_Grid_Item_Editor::postType(),
	),
);
plugins/class-vc-vendor-jwplayer.php000066600000003757151262607420013624 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * JWPLayer loader.
 * @since 4.3
 */
class Vc_Vendor_Jwplayer implements Vc_Vendor_Interface {
	/**
	 * Dublicate jwplayer logic for editor, when used in frontend editor mode.
	 *
	 * @since 4.3
	 */
	public function load() {

		add_action( 'wp_enqueue_scripts', array(
			&$this,
			'vc_load_iframe_jscss',
		) );
		add_filter( 'vc_front_render_shortcodes', array(
			&$this,
			'renderShortcodes',
		) );
		add_filter( 'vc_frontend_template_the_content', array(
			&$this,
			'wrapPlaceholder',
		) );

		// fix for #1065
		add_filter( 'vc_shortcode_content_filter_after', array(
			&$this,
			'renderShortcodesPreview',
		) );
	}

	/**
	 * @param $output
	 *
	 * @since 4.3
	 *
	 * @return mixed|string
	 */
	public function renderShortcodes( $output ) {
		$output = str_replace( '][jwplayer', '] [jwplayer', $output ); // fixes jwplayer shortcode regex..
		$data = JWP6_Shortcode::the_content_filter( $output );
		preg_match_all( '/(jwplayer-\d+)/', $data, $matches );
		$pairs = array_unique( $matches[0] );

		if ( count( $pairs ) > 0 ) {
			$id_zero = time();
			foreach ( $pairs as $pair ) {
				$data = str_replace( $pair, 'jwplayer-' . $id_zero ++, $data );
			}
		}

		return $data;
	}

	public function wrapPlaceholder( $content ) {
		add_shortcode( 'jwplayer', array( &$this, 'renderPlaceholder' ) );

		return $content;
	}

	public function renderPlaceholder() {
		return '<div class="vc_placeholder-jwplayer"></div>';
	}

	/**
	 * @param $output
	 *
	 * @since 4.3, due to #1065
	 *
	 * @return string
	 */
	public function renderShortcodesPreview( $output ) {
		$output = str_replace( '][jwplayer', '] [jwplayer', $output ); // fixes jwplayer shortcode regex..
		return $output;
	}

	/**
	 * @since 4.3
	 * @todo check it for preview mode (check is it needed)
	 */
	public function vc_load_iframe_jscss() {
		wp_enqueue_script( 'vc_vendor_jwplayer', vc_asset_url( 'js/frontend_editor/vendors/plugins/jwplayer.js' ), array( 'jquery' ), '1.0', true );
	}
}
mqtranslate.php000066600000001321151262610440007612 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin mqtranslate vendor
 */
add_action( 'plugins_loaded', 'vc_init_vendor_mqtranslate' );
function vc_init_vendor_mqtranslate() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'mqtranslate/mqtranslate.php' ) || function_exists( 'mqtranslate_activation_check' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-mqtranslate.php' );
		$vendor = new Vc_Vendor_Mqtranslate();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	}
}
ninja_forms.php000066600000001355151262610440007573 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin ninja forms vendor
 */
add_action( 'plugins_loaded', 'vc_init_vendor_ninja_forms' );
function vc_init_vendor_ninja_forms() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'ninja-forms/ninja-forms.php' ) || defined( 'NINJA_FORMS_DIR' ) || function_exists( 'ninja_forms_get_all_forms' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-ninja-forms.php' );
		$vendor = new Vc_Vendor_NinjaForms();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	}
}
revslider.php000066600000001171151262610440007261 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin revslider vendor.
 */
add_action( 'plugins_loaded', 'vc_init_vendor_revslider' );
function vc_init_vendor_revslider() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'revslider/revslider.php' ) || class_exists( 'RevSlider' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-revslider.php' );
		$vendor = new Vc_Vendor_Revslider();
		$vendor->load();
	}
}
wp_customize.php000066600000001363151262610440010015 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 */
// Remove scripts from the Visual Composer while in the Customizer = Temp Fix
// Actually we need to check if this is really needed in 4.4 uncomment if you have customizer issues
// But this actually will break any VC js in Customizer preview.
// removed by fixing vcTabsBevahiour in js_composer_front.js
/*
if ( ! function_exists( 'vc_wpex_remove_vc_scripts' ) ) {
	function vc_wpex_remove_vc_scripts() {
		if ( is_customize_preview() ) {
			wp_deregister_script( 'wpb_composer_front_js' );
			wp_dequeue_script( 'wpb_composer_front_js' );
		}
	}
}*/
//add_action( 'wp_enqueue_scripts', 'vc_wpex_remove_vc_scripts' );
cf7.php000066600000001415151262610440005742 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin contact form 7 vendor - fix load cf7 shortcode when in editor (frontend)
 */
add_action( 'plugins_loaded', 'vc_init_vendor_cf7' );
function vc_init_vendor_cf7() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'contact-form-7/wp-contact-form-7.php' ) || defined( 'WPCF7_PLUGIN' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-contact-form7.php' );
		$vendor = new Vc_Vendor_ContactForm7();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	} // if contact form7 plugin active
}
qtranslate.php000066600000001276151262610440007446 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin qtranslate vendor.
 */
add_action( 'plugins_loaded', 'vc_init_vendor_qtranslate' );
function vc_init_vendor_qtranslate() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'qtranslate/qtranslate.php' ) || defined( 'QT_SUPPORTED_WP_VERSION' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-qtranslate.php' );
		$vendor = new Vc_Vendor_Qtranslate();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	}
}
gravity_forms.php000066600000006510151262610440010157 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to add gravity forms shortcode into visual composer
 */
add_action( 'plugins_loaded', 'vc_init_vendor_gravity_forms' );
function vc_init_vendor_gravity_forms() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'gravityforms/gravityforms.php' ) || class_exists( 'RGForms' ) || class_exists( 'RGFormsModel' ) ) {
		// Call on map
		add_action( 'vc_after_set_mode', 'vc_vendor_gravityforms_load' );
	} // if gravityforms active
}

function vc_vendor_gravityforms_load() {
	$gravity_forms_array[ __( 'No Gravity forms found.', 'js_composer' ) ] = '';
	if ( class_exists( 'RGFormsModel' ) ) {
		$gravity_forms = RGFormsModel::get_forms( 1, 'title' );
		if ( $gravity_forms ) {
			$gravity_forms_array = array( __( 'Select a form to display.', 'js_composer' ) => '' );
			foreach ( $gravity_forms as $gravity_form ) {
				$gravity_forms_array[ $gravity_form->title ] = $gravity_form->id;
			}
		}
	}
	vc_map( array(
		'name' => __( 'Gravity Form', 'js_composer' ),
		'base' => 'gravityform',
		'icon' => 'icon-wpb-vc_gravityform',
		'category' => __( 'Content', 'js_composer' ),
		'description' => __( 'Place Gravity form', 'js_composer' ),
		'params' => array(
			array(
				'type' => 'dropdown',
				'heading' => __( 'Form', 'js_composer' ),
				'param_name' => 'id',
				'value' => $gravity_forms_array,
				'save_always' => true,
				'description' => __( 'Select a form to add it to your post or page.', 'js_composer' ),
				'admin_label' => true,
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Display Form Title', 'js_composer' ),
				'param_name' => 'title',
				'value' => array(
					__( 'No', 'js_composer' ) => 'false',
					__( 'Yes', 'js_composer' ) => 'true',
				),
				'save_always' => true,
				'description' => __( 'Would you like to display the forms title?', 'js_composer' ),
				'dependency' => array(
					'element' => 'id',
					'not_empty' => true,
				),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Display Form Description', 'js_composer' ),
				'param_name' => 'description',
				'value' => array(
					__( 'No', 'js_composer' ) => 'false',
					__( 'Yes', 'js_composer' ) => 'true',
				),
				'save_always' => true,
				'description' => __( 'Would you like to display the forms description?', 'js_composer' ),
				'dependency' => array(
					'element' => 'id',
					'not_empty' => true,
				),
			),
			array(
				'type' => 'dropdown',
				'heading' => __( 'Enable AJAX?', 'js_composer' ),
				'param_name' => 'ajax',
				'value' => array(
					__( 'No', 'js_composer' ) => 'false',
					__( 'Yes', 'js_composer' ) => 'true',
				),
				'save_always' => true,
				'description' => __( 'Enable AJAX submission?', 'js_composer' ),
				'dependency' => array(
					'element' => 'id',
					'not_empty' => true,
				),
			),
			array(
				'type' => 'textfield',
				'heading' => __( 'Tab Index', 'js_composer' ),
				'param_name' => 'tabindex',
				'description' => __( '(Optional) Specify the starting tab index for the fields of this form. Leave blank if you\'re not sure what this is.',
				'js_composer' ),
				'dependency' => array(
					'element' => 'id',
					'not_empty' => true,
				),
			),
		),
	) );
}
layerslider.php000066600000001245151262610440007603 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin layerslider vendor.
 */
add_action( 'plugins_loaded', 'vc_init_vendor_layerslider' );
function vc_init_vendor_layerslider() {
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( is_plugin_active( 'LayerSlider/layerslider.php' ) || class_exists( 'LS_Sliders' ) || defined( 'LS_ROOT_PATH' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-layerslider.php' );
		$vendor = new Vc_Vendor_Layerslider();
		$vendor->load();
	}
}
acf.php000066600000002021151262610440006006 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize advanced custom fields vendor.
 */
add_action( 'acf/init', 'vc_init_vendor_acf' ); // pro version
add_action( 'acf/register_fields', 'vc_init_vendor_acf' ); // free version
add_action( 'plugins_loaded', 'vc_init_vendor_acf' );
add_action( 'after_setup_theme', 'vc_init_vendor_acf' ); // for themes
function vc_init_vendor_acf() {
	if ( did_action( 'vc-vendor-acf-load' ) ) {
		return;
	}
	include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Require plugin.php to use is_plugin_active() below
	if ( class_exists( 'acf' ) || is_plugin_active( 'advanced-custom-fields/acf.php' ) || is_plugin_active( 'advanced-custom-fields-pro/acf.php' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR',
			'plugins/class-vc-vendor-advanced-custom-fields.php' );
		$vendor = new Vc_Vendor_AdvancedCustomFields();
		add_action( 'vc_after_set_mode',
			array(
				$vendor,
				'load',
			) );
	}
}
qtranslate-x.php000066600000001023151262610440007701 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin qtranslate vendor.
 */
add_action( 'plugins_loaded', 'vc_init_vendor_qtranslatex' );
function vc_init_vendor_qtranslatex() {
	if ( defined( 'QTX_VERSION' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-qtranslate-x.php' );
		$vendor = new Vc_Vendor_QtranslateX();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	}
}
wpml.php000066600000000575151262610440006250 0ustar00<?php

if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

add_action( 'plugins_loaded', 'vc_init_vendor_wpml' );
function vc_init_vendor_wpml() {
	if ( defined( 'ICL_SITEPRESS_VERSION' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-wpml.php' );
		$vendor = new Vc_Vendor_WPML();
		add_action( 'vc_after_set_mode', array(
			$vendor,
			'load',
		) );
	}
}
jwplayer.php000066600000001110151262610440007110 0ustar00<?php
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

/**
 * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
 *
 * Used to initialize plugin jwplayer vendor for frontend editor.
 */
add_action( 'plugins_loaded', 'vc_init_vendor_jwplayer' );
function vc_init_vendor_jwplayer() {
	if ( is_plugin_active( 'jw-player-plugin-for-wordpress/jwplayermodule.php' ) || defined( 'JWP6' ) || class_exists( 'JWP6_Plugin' ) ) {
		require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-jwplayer.php' );
		$vendor = new Vc_Vendor_Jwplayer();
		$vendor->load();
	}
}
qtranslatex_frontend.js000066600000000704151263271130011355 0ustar00(function ( $ ) {
	$( '#vc_vendor_qtranslatex_langs_front' ).change( function () {
		vc.closeActivePanel();
		$( '#vc_logo' ).addClass( 'vc_ui-wp-spinner' );
		window.location.href = $( this ).val();
	} );
	
	var nativeGetContent = vc.ShortcodesBuilder.prototype.getContent;
	vc.ShortcodesBuilder.prototype.getContent = function () {
		var content = nativeGetContent();
		jQuery( '#content' ).val( content );
		return content;
	};

})( window.jQuery );qtranslate_backend.js000066600000003212151263271130010732 0ustar00(function ( $ ) {
	$( '#content-html' ).on( 'click', function () {
		window.setTimeout( function () {
			window.wpActiveEditor = 'qtrans_textarea_content';
		}, 10 );
	} );

	$( window ).ready( function () {
		var activeLang = qtrans_get_active_language(),
			$langs = $( '#vc_vendor_qtranslate_langs' );

		$( 'option', $langs ).each( function () {
			var $el = $( this );
			if ( $el.val() == activeLang ) {
				$el.prop( 'selected', true );
			}
			$( '#qtrans_select_' + $el.val() ).on( 'click', function () {
				$el.prop( 'selected', true );
			} );
		} );

		$langs.on( 'change', function () {
			$( '#qtrans_select_' + $( this ).val() ).trigger( 'click' );
			var link = $( ":selected", this ).attr( 'link' );
			$( '.wpb_switch-to-front-composer' ).each( function () {
				$( this ).attr( 'href', link );
			} );
			$( '#wpb-edit-inline' ).attr( 'href', link );
			vc.shortcodes.fetch( { reset: true } );
		} );

		$langs.show();

		if ( ! window.vc ) {
			window.vc = {};
		}
		vc.QtransResetContent = function () {
			$( '#content-html' ).trigger( 'click' );
			$( '#qtrans_textarea_content' ).css( 'minHeight', '300px' );
			window.wpActiveEditor = 'qtrans_textarea_content';
		};

		vc.Storage.prototype.getContent = function () {
			var content;
			vc.QtransResetContent();
			content = $( '#qtrans_textarea_content' ).val();
			if ( vc.gridItemEditor && ! content.length ) {
				content = vcDefaultGridItemContent;
			}
			return content;
		};

		vc.Storage.prototype.setContent = function ( content ) {
			$( '#content-html' ).trigger( 'click' );
			$( '#qtrans_textarea_content' ).val( content );
			vc.QtransResetContent();
		};

	} );
})( window.jQuery );advanced_custom_fields.js000066600000000453151263271130011576 0ustar00jQuery( document ).on( 'acf/setup_fields', function ( e, el ) {
	// Redeclare active editor.
	setTimeout( function () {
		if ( 'tinymce' === getUserSetting( 'editor' ) ) {
			jQuery( '#content-tmce' ).trigger( 'click' );
		} else {
			jQuery( '#content-html' ).trigger( 'click' );
		}
	}, 10 );
} );qtranslate_frontend.js000066600000001523151263271130011165 0ustar00(function ( $ ) {
	$( '#vc_vendor_qtranslate_langs_front' ).change( function () {
		vc.closeActivePanel();
		$( '#vc_logo' ).addClass( 'vc_ui-wp-spinner' );
		window.location.href = $( this ).val();
	} );

	vc.ShortcodesBuilder.prototype.getContent = function () {
		var output,
			$postContent = $( '#vc_vendor_qtranslate_postcontent' ),
			lang = $postContent.attr( 'data-lang' ),
			content = $postContent.val();
		vc.shortcodes.sort();
		output = this.modelsToString( vc.shortcodes.where( { parent_id: false } ) );
		return qtrans_integrate( lang, output, content );
	};
	vc.ShortcodesBuilder.prototype.getTitle = function () {
		var $titleContent = $( '#vc_vendor_qtranslate_posttitle' ),
			lang = $titleContent.attr( 'data-lang' ),
			content = $titleContent.val();
		return qtrans_integrate( lang, vc.title, content );
	};
})( window.jQuery );yoast.js000066600000005645151263271130006260 0ustar00/* global vc, YoastSEO, _, jQuery */
jQuery( document ).ready( function () {
	'use strict';
	var imageEventString, vcYoast, relevantData = {}, pluginName = 'vcVendorYoast', eventsList = [
		'sync',
		'add',
		'update'
	];
	var contentModification = function ( data ) {
		data = _.reduce( relevantData, function ( memo, value, key ) {
			if ( value.html ) {
				memo = memo.replace( '"' + value.text + '"', value.html );
			}
			if ( value.image && value.param ) {
				var i, imagesString = '', attachment;
				for ( i = 0;
					  value.image.length > i;
					  i ++ ) {
					attachment = window.wp.media.model.Attachment.get( value.image[ i ] );
					if ( attachment.get( 'url' ) ) {
						imagesString += '<img src=\'' + attachment.get( 'url' ) + '\' alt=\'' +
							( attachment.get( 'alt' ) || attachment.get( 'caption' ) || attachment.get( 'title' ) ) + '\'>';
					}
				}
				memo += imagesString;
			}
			return memo;
		}, data );
		return data;
	};

	function getImageEventString( e ) {
		return ' shortcodes:' + e + ':param:type:attach_image' +
			' shortcodes:' + e + ':param:type:attach_images';
	}

	// add relevant data for images
	imageEventString = _.reduce( eventsList, function ( memo, e ) {
		return memo + getImageEventString( e );
	}, '' );
	vc.events.on( imageEventString, function ( model, param, settings ) {
		if ( param && param.length > 0 ) {
			var ids = param.split( /\s*,\s*/ );
			_.each( ids, function ( id ) {
				var attachment = window.wp.media.model.Attachment.get( id );
				if ( ! attachment.get( 'url' ) ) {
					attachment.once( 'sync', function () {
						YoastSEO.app.pluginReloaded( pluginName );
					} );
					attachment.fetch();
				}
			} );
			relevantData[ model.get( 'id' ) + settings.param_name ] = {
				image: ids,
				paramName: settings.param_name,
				param: param
			};
		}
	} );
	vc.events.on( getImageEventString( 'destroy' ), function ( model, param, settings ) {
		delete relevantData[ model.get( 'id' ) + settings.param_name ];
	} );
	// Add relevant data to headings
	vc.events.on( 'shortcodes:vc_custom_heading', function ( model, event ) {
		var params, tagSearch;
		params = model.get( 'params' )
		params = _.extend( {}, vc.getDefaults( model.get( 'shortcode' ) ), params );

		if ( 'destroy' === event ) {
			delete relevantData[ model.get( 'id' ) ];
		}
		else if ( params.text && params.font_container ) {
			tagSearch = params.font_container.match( /tag:([^\|]+)/ );
			if ( tagSearch[ 1 ] ) {
				relevantData[ model.get( 'id' ) ] = {
					html: '<' + tagSearch[ 1 ] + '>' +
					params.text + '</' + tagSearch[ 1 ] + '>',
					text: params.text
				};
			}
		}
	} );
	var VcVendorYoast = function () {
		// init
		YoastSEO.app.registerPlugin( pluginName, { status: 'ready' } );
		YoastSEO.app.pluginReady( pluginName );
		YoastSEO.app.registerModification( 'content', contentModification, pluginName, 5 );
	};
	jQuery( window ).on( 'YoastSEO:ready', function () {
		vcYoast = new VcVendorYoast();
	} );
} );
woocommerce-add-to-cart.js000066600000001577151263271130011535 0ustar00window.jQuery( document ).ready( function ( $ ) {
	$( 'body' ).on( 'adding_to_cart', function ( event, $button, data ) {
		$button && $button.hasClass( 'vc_gitem-link' ) && $button
			.addClass( 'vc-gitem-add-to-cart-loading-btn' )
			.parents( '.vc_grid-item-mini' )
			.addClass( 'vc-woocommerce-add-to-cart-loading' )
			.append( $( '<div class="vc_wc-load-add-to-loader-wrapper"><div class="vc_wc-load-add-to-loader"></div></div>' ) );
	} ).on( 'added_to_cart', function ( event, fragments, cart_hash, $button ) {
		if ( 'undefined' === typeof($button) ) {
			$button = $( '.vc-gitem-add-to-cart-loading-btn' );
		}
		$button && $button.hasClass( 'vc_gitem-link' ) && $button
			.removeClass( 'vc-gitem-add-to-cart-loading-btn' )
			.parents( '.vc_grid-item-mini' )
			.removeClass( 'vc-woocommerce-add-to-cart-loading' )
			.find( '.vc_wc-load-add-to-loader-wrapper' ).remove();
	} );
} );
qtranslatex_backend.js000066600000001027151263271130011124 0ustar00(function ( $ ) {
	$( function () {
		var Manager = qTranslateConfig.js.get_qtx();

		Manager.addLanguageSwitchListener( hookLanguageSwitch );
	} );

	function hookLanguageSwitch( activeLang ) {
		var $inlineHref = $( '.wpb_switch-to-front-composer' );
		if ( ! $inlineHref.data( 'raw-url' ) ) {
			$inlineHref.data( 'raw-url', $inlineHref.attr( 'href' ) );
		}
		var newUrl = $inlineHref.data( 'raw-url' ) + '&lang=' + activeLang;
		$inlineHref.attr( 'href', newUrl );
		vc.shortcodes.fetch( { reset: true } );
	}
})( window.jQuery );