%PDF- %PDF-
| Direktori : /home/opti/public_html/stlc/wp-content/plugins/insur-addon/includes/Widgets/ |
| Current File : /home/opti/public_html/stlc/wp-content/plugins/insur-addon/includes/Widgets/FooterSubscribe.php |
<?php
namespace Layerdrops\Insur\Widgets;
class FooterSubscribe extends \Elementor\Widget_Base
{
public function get_name()
{
return 'footer-subscribe';
}
public function get_title()
{
return __('Footer Subscribe', 'insur-addon');
}
public function get_icon()
{
return 'eicon-cogs';
}
public function get_categories()
{
return ['insur-category'];
}
protected function register_controls()
{
$this->start_controls_section(
'content_section',
[
'label' => __('Content', 'insur-addon'),
'tab' => \Elementor\Controls_Manager::TAB_CONTENT,
]
);
$this->add_control(
'title',
[
'label' => __('Widget Title', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => __('Newsletter', 'insur-addon'),
'label_block' => true
]
);
$this->add_control(
'paragraph_text',
[
'label' => __('Paragraph Text', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXTAREA,
'default' => __('Default Paragraph Text', 'insur-addon')
]
);
$this->add_control(
'mailchimp_url',
[
'label' => __('Add Mailchimp URL', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => '#',
]
);
$this->add_control(
'mc_input_placeholder',
[
'label' => __('Input Placeholder Text', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => __('Email Address', 'insur-addon')
]
);
$this->add_control(
'icon',
[
'label' => __('Submit Icon', 'insur-addon'),
'type' => \Elementor\Controls_Manager::ICONS,
'default' => [
'value' => 'far fa-paper-plane',
'library' => 'custom-icon',
],
]
);
$this->add_control(
'call_text',
[
'label' => __('Call Text', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => __('Call to Our Experts ', 'insur-addon'),
'label_block' => true
]
);
$this->add_control(
'call_number',
[
'label' => __('Call Number', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => __('+92 (003) 68-090', 'insur-addon'),
'label_block' => true
]
);
$this->add_control(
'call_url',
[
'label' => __('Call Url', 'insur-addon'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => __('#', 'insur-addon'),
'label_block' => true
]
);
$this->add_control(
'call_icon',
[
'label' => __('Call Icon', 'insur-addon'),
'type' => \Elementor\Controls_Manager::ICONS,
'default' => [
'value' => 'icon-telephone',
'library' => 'custom-icon',
],
]
);
$this->end_controls_section();
//style
$this->start_controls_section(
'style_option',
[
'label' => esc_html__('Style Options', 'insur-addon'),
'tab' => \Elementor\Controls_Manager::TAB_STYLE,
]
);
//widget title typography
$this->add_group_control(
\Elementor\Group_Control_Typography::get_type(),
[
'name' => 'widget_title_typography',
'label' => esc_html__('Widget Title Typography', 'insur-addon'),
'selector' => '{{WRAPPER}} .footer-widget__title',
]
);
$this->add_control(
'widget_title__color',
[
'label' => __('Widget Title Color', 'insur-addon'),
'type' => \Elementor\Controls_Manager::COLOR,
'selectors' => [
'{{WRAPPER}} .footer-widget__title' => 'color: {{VALUE}}',
],
]
);
//Paragraph Text typography
$this->add_group_control(
\Elementor\Group_Control_Typography::get_type(),
[
'name' => 'paragraph_text_typography',
'label' => esc_html__('Paragraph Text Typography', 'insur-addon'),
'selector' => '{{WRAPPER}} .footer-widget__newsletter-text',
]
);
$this->add_control(
'paragraph_text_color',
[
'label' => __('Paragraph Text Color', 'insur-addon'),
'type' => \Elementor\Controls_Manager::COLOR,
'selectors' => [
'{{WRAPPER}} .footer-widget__newsletter-text' => 'color: {{VALUE}}',
],
]
);
//call Text typography
$this->add_group_control(
\Elementor\Group_Control_Typography::get_type(),
[
'name' => 'call_text_typography',
'label' => esc_html__('Call Text Typography', 'insur-addon'),
'selector' => '{{WRAPPER}} .footer-widget__phone-text p',
]
);
$this->add_control(
'call_text_color',
[
'label' => __('Call Text Color', 'insur-addon'),
'type' => \Elementor\Controls_Manager::COLOR,
'selectors' => [
'{{WRAPPER}} .footer-widget__phone-text p' => 'color: {{VALUE}}',
],
]
);
//call number typography
$this->add_group_control(
\Elementor\Group_Control_Typography::get_type(),
[
'name' => 'call_number_typography',
'label' => esc_html__('Call Number Typography', 'insur-addon'),
'selector' => '{{WRAPPER}} .footer-widget__phone-text a',
]
);
$this->add_control(
'call_number_color',
[
'label' => __('Call Number Color', 'insur-addon'),
'type' => \Elementor\Controls_Manager::COLOR,
'selectors' => [
'{{WRAPPER}} .footer-widget__phone-text a' => 'color: {{VALUE}}',
],
]
);
$this->end_controls_section();
}
protected function render()
{
$settings = $this->get_settings_for_display();
include insur_get_template('footer-subscribe-one.php');
}
}