PluginProbe ʕ •ᴥ•ʔ
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution / 1.0.0
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution v1.0.0
4.9.2 4.9.1 4.9.0 2.0.0 2.1.0 2.2.0 2.2.1 2.2.2 2.3.0 2.4.0 2.5.0 2.5.1 3.0.0 3.1.0 3.1.1 4.0.0 4.0.1 4.1.0 4.1.1 4.2.0 4.2.1 4.3.0 4.3.1 4.4.0 4.5.0 4.5.1 4.6.0 4.6.1 4.6.2 4.6.3 4.6.4 4.6.5 4.6.6 4.6.7 4.6.8 4.6.9 4.7.0 4.7.1 4.7.2 4.7.3 4.7.4 4.7.5 4.7.6 4.7.7 4.7.8 4.7.9 4.8.0 4.8.1 4.8.2 4.8.3 4.8.4 4.8.5 4.8.6 4.8.7 4.8.8 4.8.9 trunk 0.1.2-beta 0.1.3-beta 0.1.4-beta 1.0.0 1.1.0 1.1.1 1.1.2 1.1.3 1.2.0 1.2.1 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.4.0 1.4.1 1.5.0 1.5.1 1.6.0 1.6.1 1.7.0 1.8.0 1.8.1 1.9.0
shopengine / widgets / product-excerpt / product-excerpt.php
shopengine / widgets / product-excerpt Last commit date
screens 5 years ago product-excerpt-config.php 5 years ago product-excerpt.php 5 years ago
product-excerpt.php
118 lines
1 <?php
2
3 namespace Elementor;
4
5 defined('ABSPATH') || exit;
6
7 use ShopEngine\Widgets\Products;
8
9
10 class ShopEngine_Product_Excerpt extends \ShopEngine\Base\Widget
11 {
12
13 public function config() {
14 return new ShopEngine_Product_Excerpt_Config();
15 }
16
17
18 protected function register_controls() {
19
20 /*
21 * Content Tab - Product Excerpt
22 */
23 $this->start_controls_section(
24 'shopengine_section_excerpt',
25 [
26 'label' => esc_html__('Styles', 'shopengine'),
27 'tab' => Controls_Manager::TAB_STYLE,
28 ]
29 );
30
31 $this->add_control(
32 'shopengine_excerpt_color',
33 [
34 'label' => esc_html__('Color', 'shopengine'),
35 'type' => Controls_Manager::COLOR,
36 'default' => '#444444',
37 'alpha' => false,
38 'selectors' => [
39 '{{WRAPPER}} .shopengine-product-excerpt, {{WRAPPER}} .shopengine-product-excerpt p' => 'color: {{VALUE}};',
40 ],
41 ]
42 );
43
44 $this->add_group_control(
45 Group_Control_Typography::get_type(),
46 array(
47 'name' => 'shopengine_excerpt_typography',
48 'label' => esc_html__('Typography', 'shopengine'),
49 'selector' => '{{WRAPPER}} .shopengine-product-excerpt, {{WRAPPER}} .shopengine-product-excerpt p',
50 'exclude' => ['text_decoration'],
51 'fields_options' => [
52 'typography' => [
53 'default' => 'custom',
54 ],
55 'font_weight' => [
56 'default' => '400',
57 ],
58 'font_size' => [
59 'default' => [
60 'size' => '17',
61 'unit' => 'px'
62 ],
63 'label' => 'Font size (px)',
64 'size_units' => ['px'],
65 ],
66 'line_height' => [
67 'default' => [
68 'size' => '22',
69 'unit' => 'px'
70 ],
71 'label' => 'Line-height (px)',
72 'size_units' => ['px']
73 ],
74 'letter_spacing' => [
75 'responsive' => false,
76 ]
77 ],
78 )
79 );
80
81 $this->add_control(
82 'shopengine_excerpt_align',
83 [
84 'label' => esc_html__('Align', 'shopengine'),
85 'type' => Controls_Manager::CHOOSE,
86 'options' => [
87 'left' => [
88 'title' => esc_html__('Left', 'shopengine'),
89 'icon' => 'fa fa-align-left',
90 ],
91 'center' => [
92 'title' => esc_html__('Center', 'shopengine'),
93 'icon' => 'fa fa-align-center',
94 ],
95 'right' => [
96 'title' => esc_html__('Right', 'shopengine'),
97 'icon' => 'fa fa-align-right',
98 ]
99 ],
100 'selectors' => [
101 '{{WRAPPER}} .shopengine-product-excerpt' => 'text-align: {{VALUE}}',
102 ],
103 ]
104 );
105
106 $this->end_controls_section();
107
108 }
109
110
111 protected function screen() {
112
113 $tpl = Products::instance()->get_widget_template($this->get_name());
114
115 include $tpl;
116 }
117 }
118