PATH:
home
/
lab2454c
/
mact34.com
/
wp-content
/
plugins
/
tryo-toolkit
/
widgets
<?php /** * Services Area Two Widget */ namespace Elementor; class Tryo_Services_Two extends Widget_Base { public function get_name() { return 'Services_Two'; } public function get_title() { return __( 'Services Area Two', 'tryo-toolkit' ); } public function get_icon() { return 'eicon-call-to-action'; } public function get_categories() { return [ 'tryo-elements' ]; } protected function _register_controls() { $this->start_controls_section( 'services_section', [ 'label' => __( 'Services Area Control', 'tryo-toolkit' ), 'tab' => Controls_Manager::TAB_CONTENT, ] ); $this->add_control( 'image_position', [ 'label' => __( 'Image Position', 'tryo-toolkit' ), 'type' => Controls_Manager::SELECT, 'default' => 'right', 'options' => [ 'left' => __( 'Left', 'tryo-toolkit' ), 'right' => __( 'Right', 'tryo-toolkit' ), ], ] ); $this->add_control( 'top_title', [ 'label' => __( 'Top Title', 'tryo-toolkit' ), 'type' => Controls_Manager::TEXT, 'default' => __('Fast & Easy Online Banking', 'tryo-toolkit'), ] ); $this->add_control( 'title', [ 'label' => __( 'Title', 'tryo-toolkit' ), 'type' => Controls_Manager::TEXT, 'default' => __('Freelancers, entrepreneurs, and sole traders', 'tryo-toolkit'), ] ); $this->add_control( 'description', [ 'label' => __( 'Description', 'tryo-toolkit' ), 'type' => Controls_Manager::TEXTAREA, 'default' => __('Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', 'tryo-toolkit'), ] ); $list_items = new Repeater(); $list_items->add_control( 'list_title', [ 'label' => __( 'List Title', 'tryo-toolkit' ), 'type' => Controls_Manager::TEXT, 'default' => __( 'Free plan available' , 'tryo-toolkit' ), 'label_block' => true, ] ); $this->add_control( 'lists', [ 'label' => __( 'Add List', 'tryo-toolkit' ), 'type' => Controls_Manager::REPEATER, 'fields' => $list_items->get_controls(), 'default' => [ [ 'list_title' => __( 'Free plan available', 'tryo-toolkit' ), ], [ 'list_title' => __( 'Full data privacy compliance', 'tryo-toolkit' ), ], ], 'title_field' => '{{{ list_title }}}', ] ); $this->add_control( 'image', [ 'label' => __( 'Section Image', 'tryo-toolkit' ), 'type' => Controls_Manager::MEDIA, 'default' => [ 'url' => Utils::get_placeholder_image_src(), ], ] ); $this->add_control( 'list_icon', [ 'label' => __( 'List Icon', 'tryo-toolkit' ), 'type' => Controls_Manager::ICON, ] ); $this->add_control( 'button_text', [ 'label' => __( 'Button Text', 'tryo-toolkit' ), 'type' => Controls_Manager::TEXT, 'default' => __('Apply Now', 'tryo-toolkit'), ] ); $this->add_control( 'button_link', [ 'label' => __( 'Button Link', 'tryo-toolkit' ), 'type' => Controls_Manager::URL, ] ); $this->end_controls_section(); $this->start_controls_section( 'service_style', [ 'label' => __( 'Services Style', 'tryo-toolkit' ), 'tab' => Controls_Manager::TAB_STYLE, ] ); $this->add_control( 'show_image_shape', [ 'label' => __( 'Show Image Animation', 'tryo' ), 'type' => Controls_Manager::SWITCHER, 'label_on' => __( 'Show', 'tryo' ), 'label_off' => __( 'Hide', 'tryo' ), 'return_value' => 'yes', 'default' => 'yes', 'condition' => [ 'image_position' => 'left', ] ] ); $this->add_control( 'title_color', [ 'label' => __( 'Title Color', 'tryo-toolkit' ), 'type' => Controls_Manager::COLOR, 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content h2' => 'color: {{VALUE}}', ], ] ); $this->add_responsive_control( 'title_size', [ 'label' => __( 'Title Font Size', 'tryo-toolkit' ), 'type' => Controls_Manager::SLIDER, 'size_units' => [ 'px' ], 'range' => [ 'px' => [ 'min' => 10, 'max' => 70, 'step' => 1, ], ], 'devices' => [ 'desktop', 'tablet', 'mobile' ], 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content h2' => 'font-size: {{SIZE}}px;', ], ] ); $this->add_responsive_control( 'top_title_size', [ 'label' => __( 'Top Title Font Size', 'tryo-toolkit' ), 'type' => Controls_Manager::SLIDER, 'size_units' => [ 'px' ], 'range' => [ 'px' => [ 'min' => 10, 'max' => 30, 'step' => 1, ], ], 'devices' => [ 'desktop', 'tablet', 'mobile' ], 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content .sub-title' => 'font-size: {{SIZE}}px;', ], ] ); $this->add_control( 'show_title_shape', [ 'label' => __( 'Show Title Animation', 'tryo' ), 'type' => Controls_Manager::SWITCHER, 'label_on' => __( 'Show', 'tryo' ), 'label_off' => __( 'Hide', 'tryo' ), 'return_value' => 'yes', 'default' => 'yes', ] ); $this->add_control( 'content_color', [ 'label' => __( 'Content Color', 'tryo-toolkit' ), 'type' => Controls_Manager::COLOR, 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content p' => 'color: {{VALUE}}', ], ] ); $this->add_responsive_control( 'content_size', [ 'label' => __( 'Content Font Size', 'tryo-toolkit' ), 'type' => Controls_Manager::SLIDER, 'size_units' => [ 'px' ], 'range' => [ 'px' => [ 'min' => 10, 'max' => 30, 'step' => 1, ], ], 'devices' => [ 'desktop', 'tablet', 'mobile' ], 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content p' => 'font-size: {{SIZE}}px;', ], ] ); $this->add_responsive_control( 'list_size', [ 'label' => __( 'List Font Size', 'tryo-toolkit' ), 'type' => Controls_Manager::SLIDER, 'size_units' => [ 'px' ], 'range' => [ 'px' => [ 'min' => 10, 'max' => 30, 'step' => 1, ], ], 'devices' => [ 'desktop', 'tablet', 'mobile' ], 'selectors' => [ '{{WRAPPER}} .overview-box .overview-content .content .features-list li span' => 'font-size: {{SIZE}}px;', ], ] ); $this->end_controls_section(); } protected function render() { $settings = $this->get_settings_for_display(); global $tryo_opt; if( isset( $tryo_opt['enable_lazyloader'] ) ): $is_lazyloader = $tryo_opt['enable_lazyloader']; else: $is_lazyloader = true; endif; if( $is_lazyloader == true ): $lazy_class = 'smartify'; $lazy_attr = 'sm-'; else: $lazy_class = ''; $lazy_attr = ''; endif; // Inline Editing $this-> add_inline_editing_attributes('title','none'); $this-> add_inline_editing_attributes('description','none'); if( $settings['list_icon'] == '' ): $icon = 'flaticon-check-mark'; else: $icon = $settings['list_icon']; endif; ?> <div class="services-area ptb-70"> <div class="container-fluid p-0"> <div class="overview-box"> <?php if( $settings['image_position'] == 'left' ): ?> <div class="overview-image"> <?php if( $settings['image']['url'] != '' ): ?> <div class="image"> <img class="<?php echo esc_attr($lazy_class); ?>" <?php echo esc_attr($lazy_attr); ?>src="<?php echo esc_url( $settings['image']['url'] ); ?>" alt="<?php echo esc_attr__( 'Over View', 'tryo-toolkit' ); ?>"> <?php if( $settings['show_image_shape'] == 'yes' ): ?> <div class="circle-img"> <img class="<?php echo esc_attr($lazy_class); ?>" <?php echo esc_attr($lazy_attr); ?>src="<?php echo esc_url( get_template_directory_uri() .'/assets/img/circle.png' ); ?>" alt="<?php echo esc_attr__( 'Circle', 'tryo-toolkit' ); ?>"> </div> <?php endif; ?> </div> <?php endif; ?> </div> <?php endif; ?> <div class="overview-content"> <div class="content <?php if( $settings['image_position'] == 'right' ): ?>left-content<?php endif; ?>"> <span class="sub-title"><?php echo esc_html( $settings['top_title'] ); ?></span> <h2 <?php echo $this-> get_render_attribute_string('title'); ?>><?php echo esc_html( $settings['title'] ); ?></h2> <?php if( $settings['show_title_shape'] == 'yes' ): ?> <div class="bar"></div> <?php else: ?> <br> <?php endif; ?> <p <?php echo $this-> get_render_attribute_string('description'); ?>><?php echo esc_html( $settings['description'] ); ?></p> <ul class="features-list"> <?php foreach( $settings['lists'] as $list ): ?> <?php if( !$list['list_title'] == '' ): ?> <li><span><i class="<?php echo esc_attr( $icon ); ?>"></i> <?php echo esc_html($list['list_title']); ?></span></li> <?php endif; ?> <?php endforeach; ?> </ul> <?php if( $settings['button_text'] != '' ): ?> <a href="<?php echo esc_url( $settings['button_link']['url'] ); ?>" class="btn btn-primary"><?php echo esc_html( $settings['button_text'] ); ?></a> <?php endif; ?> </div> </div> <?php if( $settings['image_position'] == 'right' ): ?> <div class="overview-image"> <?php if( $settings['image']['url'] != '' ): ?> <div class="image"> <img class="<?php echo esc_attr($lazy_class); ?>" <?php echo esc_attr($lazy_attr); ?>src="<?php echo esc_url( $settings['image']['url'] ); ?>" alt="<?php echo esc_attr__( 'Over View', 'tryo-toolkit' ); ?>"> </div> <?php endif; ?> </div> <?php endif; ?> </div> </div> </div> <?php } protected function _content_template() {} } Plugin::instance()->widgets_manager->register_widget_type( new Tryo_Services_Two );
[-] banner-feature.php
[edit]
[-] profile-form.php
[edit]
[-] business-area.php
[edit]
[-] services-two.php
[edit]
[-] banner-two.php
[edit]
[-] signup.php
[edit]
[+]
..
[-] payment-experience-area.php
[edit]
[-] post.php
[edit]
[-] works.php
[edit]
[-] account-create.php
[edit]
[-] comparisons-table.php
[edit]
[-] partner-slider.php
[edit]
[-] app-download.php
[edit]
[-] feature-box.php
[edit]
[-] team.php
[edit]
[-] global-area.php
[edit]
[-] userinfo-details.php
[edit]
[-] banner-three.php
[edit]
[-] pricing.php
[edit]
[-] success-story-area.php
[edit]
[-] contact-card.php
[edit]
[-] contact-cta-box.php
[edit]
[-] services-area.php
[edit]
[-] ready-to-talk.php
[edit]
[-] section.php
[edit]
[-] receive-details.php
[edit]
[-] about-area.php
[edit]
[-] banner-four.php
[edit]
[-] send-details.php
[edit]
[-] support-area.php
[edit]
[-] invoicing.php
[edit]
[-] testimonials.php
[edit]
[-] funfact.php
[edit]
[-] signin.php
[edit]
[-] information-box.php
[edit]
[-] new-payment.php
[edit]
[-] banner-one.php
[edit]
[-] feedback-card.php
[edit]
[-] feature.php
[edit]