HEX
Server: Apache/2.4.57 (Unix) OpenSSL/1.1.1k
System: Linux tam.zee-supreme-vps.net 4.18.0-513.9.1.el8_9.x86_64 #1 SMP Sat Dec 2 05:23:44 EST 2023 x86_64
User: adltc (1070)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: /home/adltc/public_html/wp-content/plugins/elementskit/modules/wrapper-link/init.php
<?php
namespace ElementsKit\Modules\Wrapper_Link;

defined( 'ABSPATH' ) || exit;

class Init {
	private $dir;
	private $url;

	public function __construct() {

		// get current directory path
		$this->dir = dirname(__FILE__) . '/';

		// get current module's url
		$this->url = \ElementsKit::plugin_url() . 'modules/wrapper-link/';

		// enqueue scripts
		add_action( 'elementor/frontend/after_enqueue_scripts', [ $this, 'enqueue_wrapper_scripts' ] );

		// include all necessary files
		$this->include_files();

		// calling the wrapper controls
		new \Elementor\ElementsKit_Wrapper_Link();
		
	}

	public function include_files() {
		include $this->dir . 'wrapper-link.php';
	}

	public function enqueue_wrapper_scripts() {
		wp_enqueue_script( 'elementskit-wrapper', $this->url . 'assets/js/wrapper.js' , ['jquery'], \ElementsKit::version(), true );
	}
}