PluginProbe ʕ •ᴥ•ʔ
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution / 4.6.9
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution v4.6.9
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 3 years ago product-excerpt-config.php 4 years ago product-excerpt.php 3 years ago
product-excerpt.php
119 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' => 'eicon-text-align-left',
90 ],
91 'center' => [
92 'title' => esc_html__('Center', 'shopengine'),
93 'icon' => 'eicon-text-align-center',
94 ],
95 'right' => [
96 'title' => esc_html__('Right', 'shopengine'),
97 'icon' => 'eicon-text-align-right',
98 ]
99 ],
100 'selectors' => [
101 '{{WRAPPER}} .shopengine-product-excerpt' => 'text-align: {{VALUE}}',
102 '.rtl {{WRAPPER}}.elementor-align-left .shopengine-product-excerpt' => 'text-align:right;',
103 '.rtl {{WRAPPER}}.elementor-align-right .shopengine-product-excerpt' => 'text-align:left;',
104 ],
105 'prefix_class' => 'elementor-align-',
106 ]
107 );
108
109 $this->end_controls_section();
110 }
111
112 protected function screen() {
113
114 $tpl = Products::instance()->get_widget_template($this->get_name());
115
116 include $tpl;
117 }
118 }
119