Sindbad~EG File Manager
<?php
namespace Elementor;
class ElementsKit_Extend_Sticky{
public function __construct() {
add_action( 'elementor/element/section/section_advanced/after_section_end', [ $this, 'register_controls' ] );
add_action( 'elementor/element/common/_section_style/after_section_end', [ $this, 'register_controls' ] );
}
public function register_controls( Controls_Stack $element ) {
$element->start_controls_section(
'section_scroll_effect',
[
'label' => __( 'Sticky Effect', 'elementskit' ),
'tab' => Controls_Manager::TAB_ADVANCED,
]
);
$element->add_control(
'ekit_sticky',
[
'label' => __( 'Sticky', 'elementskit' ),
'type' => Controls_Manager::SELECT,
'options' => [
'' => __( 'None', 'elementskit' ),
'top' => __( 'Top', 'elementskit' ),
'bottom' => __( 'Bottom', 'elementskit' ),
],
'render_type' => 'none',
'frontend_available' => true,
]
);
$element->add_control(
'ekit_sticky_on',
[
'label' => __( 'Sticky On', 'elementskit' ),
'type' => Controls_Manager::SELECT2,
'multiple' => true,
'label_block' => 'true',
'default' => [ 'desktop', 'tablet', 'mobile' ],
'options' => [
'desktop' => __( 'Desktop', 'elementskit' ),
'tablet' => __( 'Tablet', 'elementskit' ),
'mobile' => __( 'Mobile', 'elementskit' ),
],
'condition' => [
'ekit_sticky!' => '',
],
'render_type' => 'none',
'frontend_available' => true,
]
);
$element->add_control(
'ekit_sticky_offset',
[
'label' => __( 'Sticky Offset', 'elementskit' ),
'type' => Controls_Manager::SLIDER,
'default' => [
'unit' => 'px',
'size' => 0,
],
'required' => true,
'condition' => [
'ekit_sticky!' => '',
],
'render_type' => 'none',
'frontend_available' => true,
]
);
$element->add_control(
'ekit_sticky_effect_offset',
[
'label' => __( 'Effect Offset', 'elementskit' ),
'type' => Controls_Manager::SLIDER,
'default' => [
'unit' => 'px',
'size' => 0,
],
'required' => true,
'condition' => [
'ekit_sticky!' => '',
],
'render_type' => 'none',
'frontend_available' => true,
]
);
$element->end_controls_section();
}
}
Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists