/
home
/
techb158
/
l2hypotheques.com
/
wp-content
/
plugins
/
pyloncore
/
elementor
/
/home/techb158/l2hypotheques.com/wp-content/plugins/pyloncore/elementor
mkdir
upload
Name
Size
Mode
Actions
assets/
-
0755
rm
widgets/
-
0755
rm
custom-elements.php
11232
0644
edit
dl
rm
icons.php
4839
0644
edit
dl
rm
Edit:
/home/techb158/l2hypotheques.com/wp-content/plugins/pyloncore/elementor/custom-elements.php
(11232B)
<?php if ( !defined( 'ABSPATH' ) ) { exit; } global $void_widgets; $void_widgets= array_map('basename', glob(dirname( __FILE__ ) . '/widgets/*.php')); // No access of directly access class PylonElementorConfig { public function __construct() { add_action( 'elementor/editor/after_enqueue_styles', array( $this, 'pylon_core_editor_styles' ) ); add_action( 'elementor/editor/after_enqueue_scripts', array( $this, 'pylon_core_editor_scripts' ) ); add_action( 'elementor/frontend/after_register_scripts', array( $this, 'pylon_core_register_scripts' ) ); } public function pylon_core_editor_styles() { wp_enqueue_style('flaticon', plugins_url('/', __FILE__) . 'assets/css/flaticon.css', array(), 1.0, 'all'); wp_enqueue_style( 'swiper-min', plugins_url( '/', __FILE__ ) . 'assets/css/swiper-min.css', array(), '5.4.5', 'all' ); wp_enqueue_style( 'owl-carousel', plugins_url( '/', __FILE__ ) . 'assets/css/owl.carousel.min.css', array(), '2.3.4', 'all' ); } public function pylon_core_editor_scripts() { wp_enqueue_script( 'swiper-min-js', plugins_url( '/', __FILE__ ) . 'assets/js/swiper-min.js', array(), 1.0, true ); wp_enqueue_script( 'owl-carousel-min', plugins_url( '/', __FILE__ ) . 'assets/js/owl.carousel.min.js', array(),'2.3.4', true ); } public function pylon_core_register_scripts() { wp_enqueue_style( 'swiper-min', plugins_url( '/', __FILE__ ) . 'assets/css/swiper-min.css', array(), '5.4.5', 'all' ); wp_enqueue_style( 'pyloncore', plugins_url( '/', __FILE__ ) . 'assets/css/pyloncore.css', array(), '1.0.1', 'all' ) ; wp_enqueue_script( 'swiper-min-js', plugins_url( '/', __FILE__ ) . 'assets/js/swiper-min.js', array( 'jquery', 'bootstrap-bundle-min' ), 1.0, true ); wp_enqueue_style( 'owl-carousel', plugins_url( '/', __FILE__ ) . 'assets/css/owl.carousel.min.css', array(), '2.3.4', 'all' ); wp_enqueue_script( 'owl-carousel-min', plugins_url( '/', __FILE__ ) . 'assets/js/owl.carousel.min.js', array(),'2.3.4', true ); } } new PylonElementorConfig(); class pylonElementorWidget { private static $instance = null; public static function get_instance() { if ( !self::$instance ) { self::$instance = new self; } return self::$instance; } public function init() { add_action( 'elementor/widgets/widgets_registered', array( $this, 'pylon_elementor_widgets' ) ); } public function pylon_elementor_widgets() { // Check if the Elementor plugin has been installed / activated. global $void_widgets; if ( defined( 'ELEMENTOR_PATH' ) && class_exists( 'Elementor\Widget_Base' ) ) { foreach($void_widgets as $key => $value){ require_once __DIR__ . '/widgets/'.$value; } } } } add_action('elementor/element/section/section_layout/before_section_start', 'pylon_section_option_elementor', 10); if( !function_exists('pylon_section_option_elementor') ) { function pylon_section_option_elementor( $element ) { $element->start_controls_section( 'pylon_title_section_elementor', [ 'label' => esc_html__('Pylon Theme Option', 'pylon'), 'tab' => Elementor\Controls_Manager::TAB_LAYOUT, ], ); $element->add_control( 'pylon-stretched-column', [ 'label' => esc_html__('Stretch Column Background' , 'pylon'), 'type' => Elementor\Controls_Manager::SELECT, 'default' => 'none', 'label_block' => true, 'hide_in_inner' => true, 'prefix_class' => 'pylon-column-stretched-', 'options' => [ 'none' => esc_html__('No Stretch','pylon'), 'left' => esc_html__('Stretch Background From Left Side','pylon'), 'right' => esc_html__('Stretch Background From Right Side','pylon'), 'both' => esc_html__('Stretch Background From Both Side','pylon'), ], ], ); $element->add_control( 'pylon-left-side-content-stretched', [ 'label' => esc_html__('Stretch Content From Left Side?' , 'pylon'), 'type' => Elementor\Controls_Manager::SWITCHER, 'hide_in_inner' => true, 'prefix_class' => 'pylon-left-stretched-content-', 'label_on' => 'Yes', 'label_off' => 'No', 'return_value' => 'yes', 'default' => '', 'condition' => [ 'pylon-stretched-column' => array('left' , 'both'), ] ] ); $element->add_control( 'pylon-right-side-content-stretched', [ 'label' => esc_html__('Stretch Content From Right Side?' , 'pylon'), 'type' => Elementor\Controls_Manager::SWITCHER, 'hide_in_inner' => true, 'label_block' => true, 'prefix_class' => 'pylon-right-stretched-content-', 'label_on' => 'Yes', 'label_off' => 'No', 'return_value' => 'yes', 'default' => '', 'condition' => [ 'pylon-stretched-column' => array('right' , 'both'), ] ] ); $element->add_control( 'pylon-left-content-margin', [ 'label' => esc_html__('Add Margin to Left side Content' , 'pylon'), 'type' => Elementor\Controls_Manager::DIMENSIONS, 'separator' => 'before', 'selectors' => [ '{{WRAPPER}} .pylon-stretched-section.pylon-stretched-left-side' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}}', ], ] ); $element->add_control( 'pylon-right-content-margin', [ 'label' => esc_html__('Add Margin to Right side Content' , 'pylon'), 'type' => Elementor\Controls_Manager::DIMENSIONS, 'separator' => 'before', 'selectors' => [ '{{WRAPPER}} .pylon-stretched-section.pylon-stretched-right-side' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}}', ], ] ); $element->add_control( 'pylon-background-color', [ 'label' => esc_html__('Background Color of Section','pylon'), 'type' => Elementor\Controls_Manager::SELECT, 'separator' => 'before', 'default' => '', 'prefix_class' => 'pylon-background-color-', 'options' =>[ '' => esc_html__('Transparent','pylon'), 'light' => esc_html__('Light Color Background','pylon'), 'dark' => esc_html__('Dark Color Background','pylon'), 'gray' => esc_html__('Gray Color Background','pylon'), 'theme' => esc_html__('Theme Color Background','pylon'), ] ] ); $element->add_control( 'pylon-text-color', [ 'label' => esc_html__('Text Color of Section','pylon'), 'type' => Elementor\Controls_Manager::SELECT, 'default' => '', 'prefix_class' => 'pylon-text-color-', 'options' =>[ '' => esc_html__('Default','pylon'), 'light' => esc_html__('Light Color Text','pylon'), 'dark' => esc_html__('Dark Color Text','pylon'), 'theme' => esc_html__('Theme Color Text','pylon'), ] ] ); $element->end_controls_section(); } } add_action('elementor/element/column/layout/before_section_start', 'pylon_column_option_elementor', 10); if (!function_exists('pylon_column_option_elementor')) { function pylon_column_option_elementor( $element ) { $element->start_controls_section( 'pylon_title_section_elementor', [ 'label' => esc_html__('Pylon Theme Option', 'pylon'), 'tab' => Elementor\Controls_Manager::TAB_LAYOUT, ], ); $element->add_control( 'pylon-background-color', [ 'label' => esc_html__('Background Color of Column','pylon'), 'type' => Elementor\Controls_Manager::SELECT, 'separator' => 'before', 'default' => '', 'prefix_class' => 'pylon-column-background-color-yes pylon-column-background-color-', 'options' =>[ '' => esc_html__('Transparent','pylon'), 'white' => esc_html__('White Color Background','pylon'), 'dark' => esc_html__('Dark Color Background','pylon'), 'gray' => esc_html__('Gray Color Background','pylon'), 'light' => esc_html__('Light Color Background','pylon'), 'theme' => esc_html__('Theme Color Background','pylon'), ] ] ); $element->add_control( 'pylon-text-color', [ 'label' => esc_html__('Text Color of Column','pylon'), 'type' => Elementor\Controls_Manager::SELECT, 'default' => '', 'prefix_class' => 'pylon-text-color-', 'options' =>[ '' => esc_html__('Default','pylon'), 'white' => esc_html__('White Color Text','pylon'), 'dark' => esc_html__('Dark Color Text','pylon'), 'theme' => esc_html__('Theme Color Text','pylon'), ] ] ); $element->end_controls_section(); } } pylonElementorWidget::get_instance()->init(); function pylon_elementor_widget_categories( $elements_manager ) { $elements_manager->add_category( 'pylon', [ 'title' => esc_html__( 'Pylon Elements', 'pyloncore' ), ] ); } add_action( 'elementor/elements/categories_registered', 'pylon_elementor_widget_categories' );
Save
cmd:
run