PluginProbe ʕ •ᴥ•ʔ
Premium Addons for Elementor – Powerful Elementor Templates & Widgets / 4.11.34
Premium Addons for Elementor – Powerful Elementor Templates & Widgets v4.11.34
4.11.79 4.11.78 4.11.77 4.11.76 4.11.75 3.20.5 4.11.69 3.20.6 4.11.7 3.20.7 4.11.70 3.20.8 4.11.71 3.20.9 4.11.72 3.21.1 4.11.73 3.21.2 4.11.74 3.21.3 4.11.8 3.21.4 4.11.9 3.21.5 4.2.0 3.21.6 4.2.1 3.3.0 4.2.2 3.3.1 4.2.3 3.3.2 4.2.4 3.3.3 4.2.5 3.3.4 4.2.6 3.3.5 4.2.7 3.3.6 4.2.8 3.3.7 4.2.9 3.3.8 4.3.0 3.3.9 4.3.1 3.4.0 4.3.2 3.4.1 4.3.3 3.4.2 4.3.4 3.4.3 4.3.5 3.4.4 4.3.6 3.4.5 4.3.7 3.4.6 4.3.8 3.4.7 4.3.9 3.4.8 4.4.0 3.4.9 4.4.1 3.5.0 4.4.2 3.5.1 4.4.3 3.5.2 4.4.4 3.5.3 4.4.5 3.5.4 4.4.6 3.5.5 4.4.7 3.5.6 4.4.8 3.5.7 4.4.9 3.5.8 4.5.0 3.5.9 4.5.1 3.6.0 4.5.2 3.6.1 4.5.3 3.6.2 4.5.4 3.6.3 4.5.5 3.6.4 4.5.6 3.6.5 4.5.7 3.6.6 4.5.8 3.6.7 4.5.9 3.6.8 4.6.0 3.6.9 4.6.1 3.7.0 4.7.0 3.7.1 4.7.1 3.7.2 4.7.2 3.7.3 4.7.3 3.7.4 4.7.4 3.7.5 4.7.5 3.7.6 4.7.6 3.7.7 4.7.7 3.7.8 4.7.8 3.7.9 4.7.9 3.8.0 4.8.0 3.8.1 4.8.1 3.8.2 4.8.10 3.8.3 4.8.11 3.8.4 4.8.2 3.8.5 4.8.3 3.8.6 4.8.4 3.8.7 4.8.5 3.8.8 4.8.6 3.8.9 4.8.7 3.9.0 4.8.8 3.9.1 4.8.9 3.9.2 4.9.0 3.9.3 4.9.0-beta1 3.9.4 4.9.0-beta2 3.9.5 4.9.1 3.9.6 4.9.10 3.9.7 4.9.11 3.9.8 4.9.12 3.9.9 4.9.13 4.0.1 4.9.14 4.0.3 4.9.15 4.0.4 4.9.16 4.0.5 4.9.17 4.0.6 4.9.18 4.0.7 4.9.19 4.0.8 4.9.2 4.0.9 4.9.20 4.1.0 4.9.21 4.1.1 4.9.22 4.1.2 4.9.23 4.1.3 4.9.24 trunk 4.1.4 4.9.25 1.0 4.1.5 4.9.26 1.01 4.1.6 4.9.27 1.02 4.1.7 4.9.28 1.03 4.1.8 4.9.29 1.04 4.1.9 4.9.3 1.05 4.10.0 4.9.30 1.06 4.10.1 4.9.31 1.07 4.10.10 4.9.32 1.08 4.10.11 4.9.33 1.09 4.10.12 4.9.34 2.0 4.10.13 4.9.35 2.0.1 4.10.14 4.9.36 2.0.2 4.10.15 4.9.37 2.0.3 4.10.16 4.9.38 2.0.4 4.10.17 4.9.39 2.0.5 4.10.18 4.9.4 2.0.6 4.10.19 4.9.40 2.0.7 4.10.2 4.9.41 2.0.8 4.10.20 4.9.42 2.0.9 4.10.21 4.9.43 2.1.0 4.10.22 4.9.45 2.1.1 4.10.23 4.9.46 2.1.2 4.10.24 4.9.47 2.1.3 4.10.25 4.9.48 2.1.4 4.10.26 4.9.49 2.1.5 4.10.27 4.9.5 2.1.5-beta1 4.10.28 4.9.50 2.1.6 4.10.29 4.9.51 2.1.7 4.10.3 4.9.52 2.1.8 4.10.30 4.9.53 2.1.9 4.10.31 4.9.54 2.2.0 4.10.32 4.9.55 2.2.1 4.10.33 4.9.56 2.2.2 4.10.34 4.9.57 2.2.3 4.10.35 4.9.6 2.2.4 4.10.36 4.9.7 2.2.5 4.10.37 4.9.8 2.2.6 4.10.38 4.9.9 2.2.7 4.10.39 2.2.8 4.10.4 2.2.9 4.10.40 2.3.0 4.10.41 2.3.1 4.10.42 2.3.2 4.10.43 2.3.3 4.10.44 2.3.4 4.10.45 2.3.5 4.10.46 2.3.6 4.10.47 2.3.7 4.10.48 2.3.8 4.10.49 2.3.9 4.10.5 2.4.0 4.10.50 2.4.1 4.10.51 2.5.0 4.10.52 2.5.1 4.10.53 2.5.2 4.10.54 2.5.3 4.10.55 2.5.4 4.10.56 2.5.5 4.10.57 2.5.6 4.10.58 2.5.7 4.10.59 2.5.8 4.10.6 2.5.9 4.10.60 2.6.0 4.10.61 2.6.1 4.10.62 2.6.2 4.10.63 2.6.3 4.10.64 2.6.4 4.10.65 2.6.5 4.10.66 2.6.6 4.10.67 2.6.7 4.10.68 2.6.8 4.10.69 2.6.9 4.10.7 2.7.0 4.10.70 2.7.1 4.10.71 2.7.2 4.10.72 2.7.3 4.10.73 2.7.4 4.10.74 2.7.5 4.10.75 2.7.6 4.10.76 2.7.7 4.10.77 2.7.8 4.10.78 2.7.9 4.10.79 2.8.0 4.10.8 2.8.1 4.10.80 2.8.2 4.10.81 2.8.3 4.10.82 2.8.4 4.10.83 2.8.5 4.10.84 2.8.6 4.10.85 2.8.7 4.10.86 2.8.8 4.10.87 2.8.9 4.10.88 2.9.0 4.10.89 2.9.1 4.10.9 2.9.2 4.10.90 2.9.3 4.11.0 2.9.4 4.11.1 2.9.5 4.11.10 2.9.6 4.11.11 2.9.7 4.11.12 2.9.8 4.11.13 2.9.9 4.11.14 3.0.0 4.11.15 3.0.1 4.11.16 3.0.2 4.11.17 3.0.3 4.11.18 3.0.4 4.11.19 3.0.5 4.11.2 3.0.6 4.11.20 3.0.7 4.11.21 3.0.8 4.11.22 3.0.9 4.11.23 3.1.0 4.11.24 3.1.1 4.11.25 3.1.2 4.11.26 3.1.3 4.11.27 3.1.4 4.11.28 3.1.5 4.11.29 3.1.6 4.11.3 3.1.7 4.11.30 3.1.8 4.11.31 3.1.9 4.11.32 3.10.0 4.11.33 3.10.1 4.11.34 3.10.2 4.11.35 3.10.3 4.11.36 3.10.4 4.11.37 3.10.5 4.11.38 3.10.6 4.11.39 3.10.7 4.11.4 3.10.8 4.11.40 3.10.9 4.11.41 3.11.0 4.11.42 3.11.1 4.11.43 3.11.2 4.11.44 3.11.3 4.11.45 3.11.4 4.11.46 3.11.5 4.11.47 3.11.6 4.11.48 3.11.7 4.11.49 3.11.8 4.11.5 3.11.9 4.11.50 3.12.0 4.11.51 3.12.1 4.11.52 3.12.2 4.11.53 3.12.3 4.11.54 3.2.0 4.11.55 3.2.1 4.11.56 3.2.2 4.11.57 3.2.3 4.11.58 3.2.4 4.11.59 3.2.5 4.11.6 3.2.6 4.11.60 3.2.7 4.11.61 3.2.8 4.11.62 3.2.9 4.11.63 3.20.0 4.11.64 3.20.1 4.11.65 3.20.2 4.11.66 3.20.3 4.11.67 3.20.4 4.11.68
premium-addons-for-elementor / widgets / premium-person.php
premium-addons-for-elementor / widgets Last commit date
dep 8 months ago premium-banner.php 8 months ago premium-blog.php 8 months ago premium-button.php 8 months ago premium-carousel.php 8 months ago premium-contactform.php 8 months ago premium-countdown.php 8 months ago premium-counter.php 8 months ago premium-dual-header.php 8 months ago premium-fancytext.php 8 months ago premium-grid.php 8 months ago premium-icon-list.php 8 months ago premium-image-button.php 8 months ago premium-image-scroll.php 8 months ago premium-image-separator.php 8 months ago premium-lottie.php 8 months ago premium-maps.php 8 months ago premium-media-wheel.php 8 months ago premium-mobile-menu.php 8 months ago premium-modalbox.php 8 months ago premium-nav-menu.php 8 months ago premium-notifications.php 8 months ago premium-person.php 8 months ago premium-pinterest-feed.php 8 months ago premium-post-ticker.php 8 months ago premium-pricing-table.php 8 months ago premium-progressbar.php 8 months ago premium-search-form.php 8 months ago premium-svg-drawer.php 8 months ago premium-tcloud.php 8 months ago premium-testimonials.php 8 months ago premium-textual-showcase.php 8 months ago premium-tiktok-feed.php 8 months ago premium-title.php 8 months ago premium-videobox.php 8 months ago premium-vscroll.php 8 months ago premium-weather.php 8 months ago premium-world-clock.php 8 months ago
premium-person.php
2612 lines
1 <?php
2 /**
3 * Premium Persons.
4 */
5
6 namespace PremiumAddons\Widgets;
7
8 // Elementor Classes.
9 use Elementor\Plugin;
10 use Elementor\Widget_Base;
11 use Elementor\Utils;
12 use Elementor\Control_Media;
13 use Elementor\Controls_Manager;
14 use Elementor\Core\Kits\Documents\Tabs\Global_Colors;
15 use Elementor\Repeater;
16 use Elementor\Core\Kits\Documents\Tabs\Global_Typography;
17 use Elementor\Group_Control_Image_Size;
18 use Elementor\Group_Control_Typography;
19 use Elementor\Group_Control_Css_Filter;
20 use Elementor\Group_Control_Box_Shadow;
21 use Elementor\Group_Control_Text_Shadow;
22 use Elementor\Group_Control_Border;
23
24 // PremiumAddons Classes.
25 use PremiumAddons\Includes\Helper_Functions;
26
27 if ( ! defined( 'ABSPATH' ) ) {
28 exit; // If this file is called directly, abort.
29 }
30
31 /**
32 * Class Premium_Person
33 */
34 class Premium_Person extends Widget_Base {
35
36 /**
37 * Retrieve Widget Name.
38 *
39 * @since 1.0.0
40 * @access public
41 */
42 public function get_name() {
43 return 'premium-addon-person';
44 }
45
46 /**
47 * Retrieve Widget Title.
48 *
49 * @since 1.0.0
50 * @access public
51 */
52 public function get_title() {
53 return __( 'Team Members', 'premium-addons-for-elementor' );
54 }
55
56 /**
57 * Retrieve Widget Icon.
58 *
59 * @since 1.0.0
60 * @access public
61 *
62 * @return string widget icon.
63 */
64 public function get_icon() {
65 return 'pa-person';
66 }
67
68 /**
69 * Retrieve Widget Dependent CSS.
70 *
71 * @since 1.0.0
72 * @access public
73 *
74 * @return array CSS style handles.
75 */
76 public function get_style_depends() {
77 return array(
78 'pa-glass',
79 'font-awesome-5-all',
80 'pa-slick',
81 'premium-addons',
82 );
83 }
84
85 /**
86 * Retrieve Widget Dependent JS.
87 *
88 * @since 1.0.0
89 * @access public
90 *
91 * @return array JS script handles.
92 */
93 public function get_script_depends() {
94 return array(
95 'pa-glass',
96 'imagesloaded',
97 'pa-slick',
98 'premium-addons',
99 );
100 }
101
102 /**
103 * Retrieve Widget Categories.
104 *
105 * @since 1.5.1
106 * @access public
107 *
108 * @return array Widget categories.
109 */
110 public function get_categories() {
111 return array( 'premium-elements' );
112 }
113
114 /**
115 * Retrieve Widget Keywords.
116 *
117 * @since 1.0.0
118 * @access public
119 *
120 * @return string Widget keywords.
121 */
122 public function get_keywords() {
123 return array( 'pa', 'premium', 'premium team members', 'person', 'carousel', 'slider', 'group' );
124 }
125
126 protected function is_dynamic_content(): bool {
127 return false;
128 }
129
130 /**
131 * Retrieve Widget Support URL.
132 *
133 * @access public
134 *
135 * @return string support URL.
136 */
137 public function get_custom_help_url() {
138 return 'https://premiumaddons.com/support/';
139 }
140
141 public function has_widget_inner_wrapper(): bool {
142 return ! Helper_Functions::check_elementor_experiment( 'e_optimized_markup' );
143 }
144
145 /**
146 * Register Persons controls.
147 *
148 * @since 1.0.0
149 * @access protected
150 */
151 protected function register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore
152
153 $this->start_controls_section(
154 'premium_person_general_settings',
155 array(
156 'label' => __( 'General Settings', 'premium-addons-for-elementor' ),
157 )
158 );
159
160 $demo = Helper_Functions::get_campaign_link( 'https://premiumaddons.com/elementor-team-members-widget/', 'members', 'wp-editor', 'demo' );
161 Helper_Functions::add_templates_controls( $this, 'team-members', $demo );
162
163 $this->add_control(
164 'multiple',
165 array(
166 'label' => __( 'Multiple Member', 'premium-addons-for-elementor' ),
167 'description' => __( 'Enable this option if you need to add multiple persons', 'premium-addons-for-elementor' ),
168 'type' => Controls_Manager::SWITCHER,
169 )
170 );
171
172 $this->add_control(
173 'premium_person_style',
174 array(
175 'label' => __( 'Style', 'premium-addons-for-elementor' ),
176 'type' => Controls_Manager::SELECT,
177 'default' => 'style1',
178 'options' => array(
179 'style1' => __( 'Style 1', 'premium-addons-for-elementor' ),
180 'style2' => __( 'Style 2', 'premium-addons-for-elementor' ),
181 'style3' => __( 'Style 3', 'premium-addons-for-elementor' ),
182 ),
183 'label_block' => true,
184 'render_type' => 'template',
185 )
186 );
187
188 $this->add_control(
189 'title_rotate',
190 array(
191 'label' => __( 'Title Rotate', 'premium-addons-for-elementor' ),
192 'type' => Controls_Manager::SELECT,
193 'options' => array(
194 'cw' => __( '90 Degrees', 'premium-addons-for-elementor' ),
195 'ccw' => __( '-90 Degrees', 'premium-addons-for-elementor' ),
196 ),
197 'default' => 'cw',
198 'prefix_class' => 'premium-persons-title-',
199 'label_block' => true,
200 'condition' => array(
201 'premium_person_style' => 'style3',
202 ),
203 )
204 );
205
206 $this->add_group_control(
207 Group_Control_Image_Size::get_type(),
208 array(
209 'name' => 'thumbnail',
210 'default' => 'full',
211 )
212 );
213
214 $this->add_responsive_control(
215 'premium_person_image_width',
216 array(
217 'label' => __( 'Width', 'premium-addons-for-elementor' ),
218 'type' => Controls_Manager::SLIDER,
219 'description' => __( 'Enter image width in (PX, EM, %), default is 100%', 'premium-addons-for-elementor' ),
220 'size_units' => array( 'px', 'em', '%', 'custom' ),
221 'range' => array(
222 'px' => array(
223 'min' => 1,
224 'max' => 800,
225 ),
226 'em' => array(
227 'min' => 1,
228 'max' => 50,
229 ),
230 ),
231 'default' => array(
232 'unit' => '%',
233 'size' => '100',
234 ),
235 'label_block' => true,
236 'selectors' => array(
237 '{{WRAPPER}} .premium-persons-container' => 'width: {{SIZE}}{{UNIT}};',
238 ),
239 )
240 );
241
242 $this->add_responsive_control(
243 'premium_person_align',
244 array(
245 'label' => __( 'Alignment', 'premium-addons-for-elementor' ),
246 'type' => Controls_Manager::CHOOSE,
247 'options' => array(
248 'flex-start' => array(
249 'title' => __( 'Left', 'premium-addons-for-elementor' ),
250 'icon' => 'eicon-text-align-left',
251 ),
252 'center' => array(
253 'title' => __( 'Center', 'premium-addons-for-elementor' ),
254 'icon' => 'eicon-text-align-center',
255 ),
256 'flex-end' => array(
257 'title' => __( 'Right', 'premium-addons-for-elementor' ),
258 'icon' => 'eicon-text-align-right',
259 ),
260 ),
261 'default' => 'center',
262 'selectors' => array(
263 '{{WRAPPER}}' => 'justify-content: {{VALUE}};',
264 ),
265 )
266 );
267
268 $this->add_control(
269 'premium_person_hover_image_effect',
270 array(
271 'label' => __( 'Hover Effect', 'premium-addons-for-elementor' ),
272 'type' => Controls_Manager::SELECT,
273 'options' => array(
274 'none' => __( 'None', 'premium-addons-for-elementor' ),
275 'zoomin' => __( 'Zoom In', 'premium-addons-for-elementor' ),
276 'zoomout' => __( 'Zoom Out', 'premium-addons-for-elementor' ),
277 'scale' => __( 'Scale', 'premium-addons-for-elementor' ),
278 'grayscale' => __( 'Grayscale', 'premium-addons-for-elementor' ),
279 'blur' => __( 'Blur', 'premium-addons-for-elementor' ),
280 'bright' => __( 'Bright', 'premium-addons-for-elementor' ),
281 'sepia' => __( 'Sepia', 'premium-addons-for-elementor' ),
282 'trans' => __( 'Translate', 'premium-addons-for-elementor' ),
283 ),
284 'default' => 'zoomin',
285 'label_block' => true,
286 )
287 );
288
289 $this->add_responsive_control(
290 'premium_person_text_align',
291 array(
292 'label' => __( 'Content Alignment', 'premium-addons-for-elementor' ),
293 'type' => Controls_Manager::CHOOSE,
294 'options' => array(
295 'left' => array(
296 'title' => __( 'Left', 'premium-addons-for-elementor' ),
297 'icon' => 'eicon-text-align-left',
298 ),
299 'center' => array(
300 'title' => __( 'Center', 'premium-addons-for-elementor' ),
301 'icon' => 'eicon-text-align-center',
302 ),
303 'right' => array(
304 'title' => __( 'Right', 'premium-addons-for-elementor' ),
305 'icon' => 'eicon-text-align-right',
306 ),
307 ),
308 'default' => 'left',
309 'selectors' => array(
310 '{{WRAPPER}} .premium-person-info' => 'text-align: {{VALUE}};',
311 ),
312 )
313 );
314
315 $this->add_control(
316 'premium_person_name_heading',
317 array(
318 'label' => __( 'Name Tag', 'premium-addons-for-elementor' ),
319 'type' => Controls_Manager::SELECT,
320 'default' => 'h2',
321 'options' => array(
322 'h1' => 'H1',
323 'h2' => 'H2',
324 'h3' => 'H3',
325 'h4' => 'H4',
326 'h5' => 'H5',
327 'h6' => 'H6',
328 'div' => 'div',
329 'span' => 'span',
330 'p' => 'p',
331 ),
332 'label_block' => true,
333 )
334 );
335
336 $this->add_control(
337 'premium_person_title_heading',
338 array(
339 'label' => __( 'Title Tag', 'premium-addons-for-elementor' ),
340 'type' => Controls_Manager::SELECT,
341 'default' => 'h4',
342 'options' => array(
343 'h1' => 'H1',
344 'h2' => 'H2',
345 'h3' => 'H3',
346 'h4' => 'H4',
347 'h5' => 'H5',
348 'h6' => 'H6',
349 'div' => 'div',
350 'span' => 'span',
351 'p' => 'p',
352 ),
353 'label_block' => true,
354 )
355 );
356
357 $this->add_responsive_control(
358 'persons_per_row',
359 array(
360 'label' => __( 'Members/Row', 'premium-addons-for-elementor' ),
361 'type' => Controls_Manager::SELECT,
362 'options' => array(
363 '100%' => __( '1 Column', 'premium-addons-for-elementor' ),
364 '50%' => __( '2 Columns', 'premium-addons-for-elementor' ),
365 '33.33%' => __( '3 Columns', 'premium-addons-for-elementor' ),
366 '25%' => __( '4 Columns', 'premium-addons-for-elementor' ),
367 '20%' => __( '5 Columns', 'premium-addons-for-elementor' ),
368 '16.667%' => __( '6 Columns', 'premium-addons-for-elementor' ),
369 ),
370 'default' => '33.33%',
371 'tablet_default' => '100%',
372 'mobile_default' => '100%',
373 'render_type' => 'template',
374 'selectors' => array(
375 '{{WRAPPER}} .premium-person-container' => 'width: {{VALUE}}',
376 ),
377 'condition' => array(
378 'multiple' => 'yes',
379 ),
380 'frontend_available' => true,
381 )
382 );
383
384 $this->add_responsive_control(
385 'spacing',
386 array(
387 'label' => __( 'Spacing', 'premium-addons-for-elementor' ),
388 'type' => Controls_Manager::DIMENSIONS,
389 'size_units' => array( 'px', '%', 'em' ),
390 'default' => array(
391 'top' => 5,
392 'right' => 5,
393 'bottom' => 5,
394 'left' => 5,
395 ),
396 'condition' => array(
397 'multiple' => 'yes',
398 ),
399 'selectors' => array(
400 '{{WRAPPER}} .premium-person-container' => 'padding: 0 {{RIGHT}}{{UNIT}} 0 {{LEFT}}{{UNIT}}; margin: {{TOP}}{{UNIT}} 0 {{BOTTOM}}{{UNIT}} 0',
401 ' {{WRAPPER}} .premium-person-style1 .premium-person-info' => 'left: {{LEFT}}{{UNIT}}; right: {{RIGHT}}{{UNIT}}',
402 ),
403 )
404 );
405
406 $this->add_control(
407 'multiple_equal_height',
408 array(
409 'label' => __( 'Equal Height', 'premium-addons-for-elementor' ),
410 'type' => Controls_Manager::SWITCHER,
411 'default' => 'yes',
412 'description' => __( 'This option searches for the image with the largest height and applies that height to the other images', 'premium-addons-for-elementor' ),
413 'condition' => array(
414 'multiple' => 'yes',
415 'custom_height[size]' => '',
416 ),
417 )
418 );
419
420 $this->add_responsive_control(
421 'custom_height',
422 array(
423 'label' => __( 'Custom Height', 'premium-addons-for-elementor' ),
424 'type' => Controls_Manager::SLIDER,
425 'size_units' => array( 'px', 'em', 'custom' ),
426 'range' => array(
427 'px' => array(
428 'min' => 0,
429 'max' => 500,
430 ),
431 'em' => array(
432 'min' => 0,
433 'max' => 50,
434 ),
435 ),
436 'condition' => array(
437 'multiple' => 'yes',
438 ),
439 'selectors' => array(
440 '{{WRAPPER}} .premium-person-image-container img' => 'height: {{SIZE}}{{UNIT}} !important;',
441 ),
442 )
443 );
444
445 $this->end_controls_section();
446
447 $this->start_controls_section(
448 'premium_person_settings',
449 array(
450 'label' => __( 'Single Member Settings', 'premium-addons-for-elementor' ),
451 'condition' => array(
452 'multiple!' => 'yes',
453 ),
454 )
455 );
456
457 $this->add_control(
458 'premium_person_image',
459 array(
460 'label' => __( 'Image', 'premium-addons-for-elementor' ),
461 'type' => Controls_Manager::MEDIA,
462 'dynamic' => array( 'active' => true ),
463 'default' => array(
464 'url' => Utils::get_placeholder_image_src(),
465 ),
466 'label_block' => true,
467 )
468 );
469
470 $this->add_control(
471 'premium_person_name',
472 array(
473 'label' => __( 'Name', 'premium-addons-for-elementor' ),
474 'type' => Controls_Manager::TEXT,
475 'dynamic' => array( 'active' => true ),
476 'default' => 'John Frank',
477 'separator' => 'before',
478 'label_block' => true,
479 )
480 );
481
482 $this->add_control(
483 'premium_person_title',
484 array(
485 'label' => __( 'Title', 'premium-addons-for-elementor' ),
486 'type' => Controls_Manager::TEXT,
487 'dynamic' => array( 'active' => true ),
488 'default' => __( 'Developer', 'premium-addons-for-elementor' ),
489 'label_block' => true,
490 )
491 );
492
493 $this->add_control(
494 'premium_person_content',
495 array(
496 'label' => __( 'Description', 'premium-addons-for-elementor' ),
497 'type' => Controls_Manager::WYSIWYG,
498 'dynamic' => array( 'active' => true ),
499 'default' => __( 'Lorem ipsum dolor sit amet, consectetur adipiscing elit', 'premium-addons-for-elementor' ),
500 )
501 );
502
503 $this->add_control(
504 'premium_person_profile',
505 array(
506 'label' => __( 'Profile Link', 'premium-addons-for-elementor' ),
507 'type' => Controls_Manager::URL,
508 'dynamic' => array( 'active' => true ),
509 'default' => array(
510 'url' => '',
511 ),
512 'label_block' => true,
513 )
514 );
515
516 $this->add_control(
517 'premium_person_social_enable',
518 array(
519 'label' => __( 'Enable Social Icons', 'premium-addons-for-elementor' ),
520 'type' => Controls_Manager::SWITCHER,
521 'default' => 'yes',
522 'separator' => 'before',
523 )
524 );
525
526 $this->add_control(
527 'premium_person_facebook',
528 array(
529 'label' => __( 'Facebook', 'premium-addons-for-elementor' ),
530 'type' => Controls_Manager::TEXT,
531 'dynamic' => array( 'active' => true ),
532 'default' => '#',
533 'label_block' => true,
534 'condition' => array(
535 'premium_person_social_enable' => 'yes',
536 ),
537 )
538 );
539
540 $this->add_control(
541 'premium_person_twitter',
542 array(
543 'label' => __( 'Twitter', 'premium-addons-for-elementor' ),
544 'type' => Controls_Manager::TEXT,
545 'dynamic' => array( 'active' => true ),
546 'default' => '#',
547 'label_block' => true,
548 'condition' => array(
549 'premium_person_social_enable' => 'yes',
550 ),
551 )
552 );
553
554 $this->add_control(
555 'premium_person_linkedin',
556 array(
557 'label' => __( 'LinkedIn', 'premium-addons-for-elementor' ),
558 'type' => Controls_Manager::TEXT,
559 'dynamic' => array( 'active' => true ),
560 'label_block' => true,
561 'condition' => array(
562 'premium_person_social_enable' => 'yes',
563 ),
564 )
565 );
566
567 $this->add_control(
568 'premium_person_google',
569 array(
570 'label' => __( 'Google+', 'premium-addons-for-elementor' ),
571 'type' => Controls_Manager::TEXT,
572 'dynamic' => array( 'active' => true ),
573 'label_block' => true,
574 'condition' => array(
575 'premium_person_social_enable' => 'yes',
576 ),
577 )
578 );
579
580 $this->add_control(
581 'premium_person_youtube',
582 array(
583 'label' => __( 'YouTube', 'premium-addons-for-elementor' ),
584 'type' => Controls_Manager::TEXT,
585 'dynamic' => array( 'active' => true ),
586 'label_block' => true,
587 'condition' => array(
588 'premium_person_social_enable' => 'yes',
589 ),
590 )
591 );
592
593 $this->add_control(
594 'premium_person_instagram',
595 array(
596 'label' => __( 'Instagram', 'premium-addons-for-elementor' ),
597 'type' => Controls_Manager::TEXT,
598 'dynamic' => array( 'active' => true ),
599 'default' => '#',
600 'label_block' => true,
601 'condition' => array(
602 'premium_person_social_enable' => 'yes',
603 ),
604 )
605 );
606
607 $this->add_control(
608 'premium_person_skype',
609 array(
610 'label' => __( 'Skype', 'premium-addons-for-elementor' ),
611 'type' => Controls_Manager::TEXT,
612 'dynamic' => array( 'active' => true ),
613 'label_block' => true,
614 'condition' => array(
615 'premium_person_social_enable' => 'yes',
616 ),
617 )
618 );
619
620 $this->add_control(
621 'premium_person_pinterest',
622 array(
623 'label' => __( 'Pinterest', 'premium-addons-for-elementor' ),
624 'type' => Controls_Manager::TEXT,
625 'dynamic' => array( 'active' => true ),
626 'label_block' => true,
627 'condition' => array(
628 'premium_person_social_enable' => 'yes',
629 ),
630 )
631 );
632
633 $this->add_control(
634 'premium_person_dribbble',
635 array(
636 'label' => __( 'Dribbble', 'premium-addons-for-elementor' ),
637 'type' => Controls_Manager::TEXT,
638 'dynamic' => array( 'active' => true ),
639 'default' => '#',
640 'label_block' => true,
641 'condition' => array(
642 'premium_person_social_enable' => 'yes',
643 ),
644 )
645 );
646
647 $this->add_control(
648 'premium_person_behance',
649 array(
650 'label' => __( 'Behance', 'premium-addons-for-elementor' ),
651 'type' => Controls_Manager::TEXT,
652 'dynamic' => array( 'active' => true ),
653 'label_block' => true,
654 'condition' => array(
655 'premium_person_social_enable' => 'yes',
656 ),
657 )
658 );
659
660 $this->add_control(
661 'premium_person_whatsapp',
662 array(
663 'label' => __( 'WhatsApp', 'premium-addons-for-elementor' ),
664 'type' => Controls_Manager::TEXT,
665 'dynamic' => array( 'active' => true ),
666 'label_block' => true,
667 'condition' => array(
668 'premium_person_social_enable' => 'yes',
669 ),
670 )
671 );
672
673 $this->add_control(
674 'premium_person_telegram',
675 array(
676 'label' => __( 'Telegram', 'premium-addons-for-elementor' ),
677 'type' => Controls_Manager::TEXT,
678 'dynamic' => array( 'active' => true ),
679 'label_block' => true,
680 'condition' => array(
681 'premium_person_social_enable' => 'yes',
682 ),
683 )
684 );
685
686 $this->add_control(
687 'premium_person_mail',
688 array(
689 'label' => __( 'Email Address', 'premium-addons-for-elementor' ),
690 'type' => Controls_Manager::TEXT,
691 'dynamic' => array( 'active' => true ),
692 'label_block' => true,
693 'condition' => array(
694 'premium_person_social_enable' => 'yes',
695 ),
696 )
697 );
698
699 $this->add_control(
700 'premium_person_site',
701 array(
702 'label' => __( 'Website', 'premium-addons-for-elementor' ),
703 'type' => Controls_Manager::TEXT,
704 'dynamic' => array( 'active' => true ),
705 'label_block' => true,
706 'condition' => array(
707 'premium_person_social_enable' => 'yes',
708 ),
709 )
710 );
711
712 $this->add_control(
713 'premium_person_number',
714 array(
715 'label' => __( 'Phone Number', 'premium-addons-for-elementor' ),
716 'type' => Controls_Manager::TEXT,
717 'dynamic' => array( 'active' => true ),
718 'description' => __( 'Example: tel: +012 345 678 910', 'premium-addons-for-elementor' ),
719 'label_block' => true,
720 'condition' => array(
721 'premium_person_social_enable' => 'yes',
722 ),
723 )
724 );
725
726 $this->add_control(
727 'phone_notice',
728 array(
729 'raw' => __( 'Please note that Phone Number icon will show only on mobile devices.', 'premium-addons-for-elementor' ),
730 'type' => Controls_Manager::RAW_HTML,
731 'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',
732 'condition' => array(
733 'premium_person_social_enable' => 'yes',
734 ),
735 )
736 );
737
738 $this->end_controls_section();
739
740 $this->start_controls_section(
741 'multiple_settings',
742 array(
743 'label' => __( 'Multiple Members Settings', 'premium-addons-for-elementor' ),
744 'condition' => array(
745 'multiple' => 'yes',
746 ),
747 )
748 );
749
750 $repeater = new REPEATER();
751
752 $repeater->add_control(
753 'multiple_image',
754 array(
755 'label' => __( 'Image', 'premium-addons-for-elementor' ),
756 'type' => Controls_Manager::MEDIA,
757 'dynamic' => array( 'active' => true ),
758 'default' => array(
759 'url' => Utils::get_placeholder_image_src(),
760 ),
761 )
762 );
763
764 $repeater->add_control(
765 'multiple_name',
766 array(
767 'label' => __( 'Name', 'premium-addons-for-elementor' ),
768 'type' => Controls_Manager::TEXT,
769 'dynamic' => array( 'active' => true ),
770 'default' => 'John Frank',
771 'separator' => 'before',
772 'label_block' => true,
773 )
774 );
775
776 $repeater->add_control(
777 'multiple_title',
778 array(
779 'label' => __( 'Title', 'premium-addons-for-elementor' ),
780 'type' => Controls_Manager::TEXT,
781 'dynamic' => array( 'active' => true ),
782 'default' => __( 'Developer', 'premium-addons-for-elementor' ),
783 'label_block' => true,
784 )
785 );
786
787 $repeater->add_control(
788 'multiple_description',
789 array(
790 'label' => __( 'Description', 'premium-addons-for-elementor' ),
791 'type' => Controls_Manager::WYSIWYG,
792 'dynamic' => array( 'active' => true ),
793 'default' => __( 'Lorem ipsum dolor sit amet, consectetur adipiscing elit', 'premium-addons-for-elementor' ),
794 )
795 );
796
797 $repeater->add_control(
798 'multiple_profile',
799 array(
800 'label' => __( 'Profile Link', 'premium-addons-for-elementor' ),
801 'type' => Controls_Manager::URL,
802 'dynamic' => array( 'active' => true ),
803 'default' => array(
804 'url' => '',
805 ),
806 'label_block' => true,
807 )
808 );
809
810 $repeater->add_control(
811 'multiple_social_enable',
812 array(
813 'label' => __( 'Enable Social Icons', 'premium-addons-for-elementor' ),
814 'type' => Controls_Manager::SWITCHER,
815 'default' => 'yes',
816 'separator' => 'before',
817 )
818 );
819
820 $repeater->add_control(
821 'multiple_facebook',
822 array(
823 'label' => __( 'Facebook', 'premium-addons-for-elementor' ),
824 'type' => Controls_Manager::TEXT,
825 'dynamic' => array( 'active' => true ),
826 'default' => '#',
827 'label_block' => true,
828 'condition' => array(
829 'multiple_social_enable' => 'yes',
830 ),
831 )
832 );
833
834 $repeater->add_control(
835 'multiple_twitter',
836 array(
837 'label' => __( 'Twitter', 'premium-addons-for-elementor' ),
838 'type' => Controls_Manager::TEXT,
839 'dynamic' => array( 'active' => true ),
840 'default' => '#',
841 'label_block' => true,
842 'condition' => array(
843 'multiple_social_enable' => 'yes',
844 ),
845 )
846 );
847
848 $repeater->add_control(
849 'multiple_linkedin',
850 array(
851 'label' => __( 'LinkedIn', 'premium-addons-for-elementor' ),
852 'type' => Controls_Manager::TEXT,
853 'dynamic' => array( 'active' => true ),
854 'label_block' => true,
855 'condition' => array(
856 'multiple_social_enable' => 'yes',
857 ),
858 )
859 );
860
861 $repeater->add_control(
862 'multiple_google',
863 array(
864 'label' => __( 'Google+', 'premium-addons-for-elementor' ),
865 'type' => Controls_Manager::TEXT,
866 'dynamic' => array( 'active' => true ),
867 'label_block' => true,
868 'condition' => array(
869 'multiple_social_enable' => 'yes',
870 ),
871 )
872 );
873
874 $repeater->add_control(
875 'multiple_youtube',
876 array(
877 'label' => __( 'YouTube', 'premium-addons-for-elementor' ),
878 'type' => Controls_Manager::TEXT,
879 'dynamic' => array( 'active' => true ),
880 'label_block' => true,
881 'condition' => array(
882 'multiple_social_enable' => 'yes',
883 ),
884 )
885 );
886
887 $repeater->add_control(
888 'multiple_instagram',
889 array(
890 'label' => __( 'Instagram', 'premium-addons-for-elementor' ),
891 'type' => Controls_Manager::TEXT,
892 'dynamic' => array( 'active' => true ),
893 'default' => '#',
894 'label_block' => true,
895 'condition' => array(
896 'multiple_social_enable' => 'yes',
897 ),
898 )
899 );
900
901 $repeater->add_control(
902 'multiple_skype',
903 array(
904 'label' => __( 'Skype', 'premium-addons-for-elementor' ),
905 'type' => Controls_Manager::TEXT,
906 'dynamic' => array( 'active' => true ),
907 'label_block' => true,
908 'condition' => array(
909 'multiple_social_enable' => 'yes',
910 ),
911 )
912 );
913
914 $repeater->add_control(
915 'multiple_pinterest',
916 array(
917 'label' => __( 'Pinterest', 'premium-addons-for-elementor' ),
918 'type' => Controls_Manager::TEXT,
919 'dynamic' => array( 'active' => true ),
920 'label_block' => true,
921 'condition' => array(
922 'multiple_social_enable' => 'yes',
923 ),
924 )
925 );
926
927 $repeater->add_control(
928 'multiple_dribbble',
929 array(
930 'label' => __( 'Dribbble', 'premium-addons-for-elementor' ),
931 'type' => Controls_Manager::TEXT,
932 'dynamic' => array( 'active' => true ),
933 'default' => '#',
934 'label_block' => true,
935 'condition' => array(
936 'multiple_social_enable' => 'yes',
937 ),
938 )
939 );
940
941 $repeater->add_control(
942 'multiple_behance',
943 array(
944 'label' => __( 'Behance', 'premium-addons-for-elementor' ),
945 'type' => Controls_Manager::TEXT,
946 'dynamic' => array( 'active' => true ),
947 'label_block' => true,
948 'condition' => array(
949 'multiple_social_enable' => 'yes',
950 ),
951 )
952 );
953
954 $repeater->add_control(
955 'multiple_whatsapp',
956 array(
957 'label' => __( 'WhatsApp', 'premium-addons-for-elementor' ),
958 'type' => Controls_Manager::TEXT,
959 'dynamic' => array( 'active' => true ),
960 'label_block' => true,
961 'condition' => array(
962 'multiple_social_enable' => 'yes',
963 ),
964 )
965 );
966
967 $repeater->add_control(
968 'multiple_telegram',
969 array(
970 'label' => __( 'Telegram', 'premium-addons-for-elementor' ),
971 'type' => Controls_Manager::TEXT,
972 'dynamic' => array( 'active' => true ),
973 'label_block' => true,
974 'condition' => array(
975 'multiple_social_enable' => 'yes',
976 ),
977 )
978 );
979
980 $repeater->add_control(
981 'multiple_mail',
982 array(
983 'label' => __( 'Email Address', 'premium-addons-for-elementor' ),
984 'type' => Controls_Manager::TEXT,
985 'dynamic' => array( 'active' => true ),
986 'label_block' => true,
987 'condition' => array(
988 'multiple_social_enable' => 'yes',
989 ),
990 )
991 );
992
993 $repeater->add_control(
994 'multiple_site',
995 array(
996 'label' => __( 'Website', 'premium-addons-for-elementor' ),
997 'type' => Controls_Manager::TEXT,
998 'dynamic' => array( 'active' => true ),
999 'label_block' => true,
1000 'condition' => array(
1001 'multiple_social_enable' => 'yes',
1002 ),
1003 )
1004 );
1005
1006 $repeater->add_control(
1007 'multiple_number',
1008 array(
1009 'label' => __( 'Phone Number', 'premium-addons-for-elementor' ),
1010 'type' => Controls_Manager::TEXT,
1011 'dynamic' => array( 'active' => true ),
1012 'description' => __( 'Example: tel: +012 345 678 910', 'premium-addons-for-elementor' ),
1013 'label_block' => true,
1014 'condition' => array(
1015 'multiple_social_enable' => 'yes',
1016 ),
1017 )
1018 );
1019
1020 $repeater->add_control(
1021 'phone_notice',
1022 array(
1023 'raw' => __( 'Please note that Phone Number icon will show only on mobile devices.', 'premium-addons-for-elementor' ),
1024 'type' => Controls_Manager::RAW_HTML,
1025 'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',
1026 'condition' => array(
1027 'multiple_social_enable' => 'yes',
1028 ),
1029 )
1030 );
1031
1032 $this->add_control(
1033 'multiple_persons',
1034 array(
1035 'label' => __( 'Members', 'premium-addons-for-elementor' ),
1036 'type' => Controls_Manager::REPEATER,
1037 'default' => array(
1038 array(
1039 'multiple_name' => 'John Frank',
1040 ),
1041 array(
1042 'multiple_name' => 'John Frank',
1043 ),
1044 array(
1045 'multiple_name' => 'John Frank',
1046 ),
1047 ),
1048 'fields' => $repeater->get_controls(),
1049 'title_field' => '{{{multiple_name}}} - {{{multiple_title}}}',
1050 'prevent_empty' => false,
1051 )
1052 );
1053
1054 $this->add_control(
1055 'carousel',
1056 array(
1057 'label' => __( 'Carousel', 'premium-addons-for-elementor' ),
1058 'type' => Controls_Manager::SWITCHER,
1059 'frontend_available' => true,
1060 )
1061 );
1062
1063 $this->add_control(
1064 'carousel_play',
1065 array(
1066 'label' => __( 'Auto Play', 'premium-addons-for-elementor' ),
1067 'type' => Controls_Manager::SWITCHER,
1068 'condition' => array(
1069 'carousel' => 'yes',
1070 ),
1071 'frontend_available' => true,
1072 )
1073 );
1074
1075 $this->add_control(
1076 'speed',
1077 array(
1078 'label' => __( 'Autoplay Speed', 'premium-addons-for-elementor' ),
1079 'description' => __( 'Autoplay Speed means at which time the next slide should come. Set a value in milliseconds (ms)', 'premium-addons-for-elementor' ),
1080 'type' => Controls_Manager::NUMBER,
1081 'default' => 5000,
1082 'condition' => array(
1083 'carousel' => 'yes',
1084 'carousel_play' => 'yes',
1085 ),
1086 'frontend_available' => true,
1087 )
1088 );
1089
1090 $this->add_responsive_control(
1091 'carousel_arrows_pos',
1092 array(
1093 'label' => __( 'Arrows Position', 'premium-addons-for-elementor' ),
1094 'type' => Controls_Manager::SLIDER,
1095 'size_units' => array( 'px', 'em' ),
1096 'range' => array(
1097 'px' => array(
1098 'min' => -100,
1099 'max' => 100,
1100 ),
1101 'em' => array(
1102 'min' => -10,
1103 'max' => 10,
1104 ),
1105 ),
1106 'condition' => array(
1107 'carousel' => 'yes',
1108 ),
1109 'selectors' => array(
1110 '{{WRAPPER}} .premium-persons-container a.carousel-arrow.carousel-next' => 'right: {{SIZE}}{{UNIT}};',
1111 '{{WRAPPER}} .premium-persons-container a.carousel-arrow.carousel-prev' => 'left: {{SIZE}}{{UNIT}};',
1112 ),
1113 )
1114 );
1115
1116 $this->end_controls_section();
1117
1118 $this->start_controls_section(
1119 'section_pa_docs',
1120 array(
1121 'label' => __( 'Help & Docs', 'premium-addons-for-elementor' ),
1122 )
1123 );
1124
1125 $doc1_url = Helper_Functions::get_campaign_link( 'https://premiumaddons.com/docs/persons-widget-tutorial/', 'members-widget', 'wp-editor', 'get-support' );
1126 $doc2_url = Helper_Functions::get_campaign_link( 'https://premiumaddons.com/docs/why-im-not-able-to-see-elementor-font-awesome-5-icons-in-premium-add-ons', 'members-widget', 'wp-editor', 'get-support' );
1127
1128 $this->add_control(
1129 'doc_1',
1130 array(
1131 'type' => Controls_Manager::RAW_HTML,
1132 'raw' => sprintf( '<a href="%s" target="_blank">%s</a>', $doc1_url, __( 'Getting started »', 'premium-addons-for-elementor' ) ),
1133 'content_classes' => 'editor-pa-doc',
1134 )
1135 );
1136
1137 $this->add_control(
1138 'doc_2',
1139 array(
1140 'type' => Controls_Manager::RAW_HTML,
1141 'raw' => sprintf( '<a href="%s" target="_blank">%s</a>', $doc2_url, __( 'I\'m not able to see the social icons in the widget »', 'premium-addons-for-elementor' ) ),
1142 'content_classes' => 'editor-pa-doc',
1143 )
1144 );
1145
1146 $this->end_controls_section();
1147
1148 $this->start_controls_section(
1149 'premium_person_image_style',
1150 array(
1151 'label' => __( 'Image', 'premium-addons-for-elementor' ),
1152 'tab' => Controls_Manager::TAB_STYLE,
1153 )
1154 );
1155
1156 $this->add_responsive_control(
1157 'image_border_radius',
1158 array(
1159 'label' => __( 'Border Radius', 'premium-addons-for-elementor' ),
1160 'type' => Controls_Manager::DIMENSIONS,
1161 'size_units' => array( 'px', 'em', '%' ),
1162 'selectors' => array(
1163 '{{WRAPPER}} .premium-person-image-container' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1164 ),
1165 'condition' => array(
1166 'premium_person_style' => 'style2',
1167 ),
1168 )
1169 );
1170
1171 $this->add_control(
1172 'image_adv_radius',
1173 array(
1174 'label' => __( 'Advanced Border Radius', 'premium-addons-for-elementor' ),
1175 'type' => Controls_Manager::SWITCHER,
1176 'description' => __( 'Apply custom radius values. Get the radius value from ', 'premium-addons-for-elementor' ) . '<a href="https://9elements.github.io/fancy-border-radius/" target="_blank">here</a>' . __( '. See ', 'premium-addons-for-elementor' ) . '<a href="https://www.youtube.com/watch?v=S0BJazLHV-M" target="_blank">tutorial</a>',
1177 'condition' => array(
1178 'premium_person_style' => 'style2',
1179 ),
1180 )
1181 );
1182
1183 $this->add_control(
1184 'image_adv_radius_value',
1185 array(
1186 'label' => __( 'Border Radius', 'premium-addons-for-elementor' ),
1187 'type' => Controls_Manager::TEXT,
1188 'dynamic' => array( 'active' => true ),
1189 'selectors' => array(
1190 '{{WRAPPER}} .premium-person-image-container' => 'border-radius: {{VALUE}};',
1191 ),
1192 'condition' => array(
1193 'premium_person_style' => 'style2',
1194 'image_adv_radius' => 'yes',
1195 ),
1196 )
1197 );
1198
1199 $this->add_group_control(
1200 Group_Control_Css_Filter::get_type(),
1201 array(
1202 'name' => 'css_filters',
1203 'selector' => '{{WRAPPER}} .premium-person-container img',
1204 )
1205 );
1206
1207 $this->add_group_control(
1208 Group_Control_Css_Filter::get_type(),
1209 array(
1210 'name' => 'hover_css_filters',
1211 'label' => __( 'Hover CSS Filters', 'premium-addons-for-elementor' ),
1212 'selector' => '{{WRAPPER}} .premium-person-container:hover img',
1213 )
1214 );
1215
1216 $this->add_group_control(
1217 Group_Control_Box_Shadow::get_type(),
1218 array(
1219 'name' => 'premium_person_shadow',
1220 'selector' => '{{WRAPPER}} .premium-person-social',
1221 'condition' => array(
1222 'premium_person_style' => 'style2',
1223 ),
1224 )
1225 );
1226
1227 $this->add_control(
1228 'blend_mode',
1229 array(
1230 'label' => __( 'Blend Mode', 'premium-addons-for-elementor' ),
1231 'type' => Controls_Manager::SELECT,
1232 'options' => array(
1233 '' => __( 'Normal', 'premium-addons-for-elementor' ),
1234 'multiply' => 'Multiply',
1235 'screen' => 'Screen',
1236 'overlay' => 'Overlay',
1237 'darken' => 'Darken',
1238 'lighten' => 'Lighten',
1239 'color-dodge' => 'Color Dodge',
1240 'saturation' => 'Saturation',
1241 'color' => 'Color',
1242 'luminosity' => 'Luminosity',
1243 ),
1244 'separator' => 'before',
1245 'selectors' => array(
1246 '{{WRAPPER}} .premium-person-image-container img' => 'mix-blend-mode: {{VALUE}}',
1247 ),
1248 )
1249 );
1250
1251 $this->end_controls_section();
1252
1253 $this->start_controls_section(
1254 'premium_person_name_style',
1255 array(
1256 'label' => __( 'Name', 'premium-addons-for-elementor' ),
1257 'tab' => Controls_Manager::TAB_STYLE,
1258 )
1259 );
1260
1261 $this->add_control(
1262 'premium_person_name_color',
1263 array(
1264 'label' => __( 'Color', 'premium-addons-for-elementor' ),
1265 'type' => Controls_Manager::COLOR,
1266 'global' => array(
1267 'default' => Global_Colors::COLOR_PRIMARY,
1268 ),
1269 'selectors' => array(
1270 '{{WRAPPER}} .premium-person-name' => 'color: {{VALUE}};',
1271 ),
1272 )
1273 );
1274
1275 $this->add_control(
1276 'premium_person_name_color_hover',
1277 array(
1278 'label' => __( 'Hover Color', 'premium-addons-for-elementor' ),
1279 'type' => Controls_Manager::COLOR,
1280 'global' => array(
1281 'default' => Global_Colors::COLOR_SECONDARY,
1282 ),
1283 'selectors' => array(
1284 '{{WRAPPER}} .premium-person-link:hover .premium-person-name' => 'color: {{VALUE}} ;',
1285 ),
1286 )
1287 );
1288
1289 $this->add_group_control(
1290 Group_Control_Typography::get_type(),
1291 array(
1292 'name' => 'name_typography',
1293 'global' => array(
1294 'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
1295 ),
1296 'selector' => '{{WRAPPER}} .premium-person-name',
1297 )
1298 );
1299
1300 $this->add_group_control(
1301 Group_Control_Text_Shadow::get_type(),
1302 array(
1303 'name' => 'name_shadow',
1304 'selector' => '{{WRAPPER}} .premium-person-name',
1305 )
1306 );
1307
1308 $this->add_responsive_control(
1309 'name_padding',
1310 array(
1311 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1312 'type' => Controls_Manager::DIMENSIONS,
1313 'size_units' => array( 'px', 'em', '%' ),
1314 'selectors' => array(
1315 '{{WRAPPER}} .premium-person-name' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1316 ),
1317 )
1318 );
1319
1320 $this->end_controls_section();
1321
1322 $this->start_controls_section(
1323 'premium_person_title_style',
1324 array(
1325 'label' => __( 'Job Title', 'premium-addons-for-elementor' ),
1326 'tab' => Controls_Manager::TAB_STYLE,
1327 )
1328 );
1329
1330 $this->add_control(
1331 'premium_person_title_color',
1332 array(
1333 'label' => __( 'Color', 'premium-addons-for-elementor' ),
1334 'type' => Controls_Manager::COLOR,
1335 'global' => array(
1336 'default' => Global_Colors::COLOR_SECONDARY,
1337 ),
1338 'selectors' => array(
1339 '{{WRAPPER}} .premium-person-title' => 'color: {{VALUE}};',
1340 ),
1341 )
1342 );
1343
1344 $this->add_group_control(
1345 Group_Control_Typography::get_type(),
1346 array(
1347 'name' => 'title_typography',
1348 'global' => array(
1349 'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
1350 ),
1351 'selector' => '{{WRAPPER}} .premium-person-title',
1352 )
1353 );
1354
1355 $this->add_group_control(
1356 Group_Control_Text_Shadow::get_type(),
1357 array(
1358 'name' => 'title_shadow',
1359 'selector' => '{{WRAPPER}} .premium-person-title',
1360 )
1361 );
1362
1363 $this->add_responsive_control(
1364 'title_margin',
1365 array(
1366 'label' => __( 'Margin', 'premium-addons-for-elementor' ),
1367 'type' => Controls_Manager::DIMENSIONS,
1368 'size_units' => array( 'px', 'em', '%' ),
1369 'selectors' => array(
1370 '{{WRAPPER}} .premium-person-title' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1371 ),
1372 )
1373 );
1374
1375 $this->add_responsive_control(
1376 'title_padding',
1377 array(
1378 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1379 'type' => Controls_Manager::DIMENSIONS,
1380 'size_units' => array( 'px', 'em', '%' ),
1381 'selectors' => array(
1382 '{{WRAPPER}} .premium-person-title' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1383 ),
1384 )
1385 );
1386
1387 $this->end_controls_section();
1388
1389 $this->start_controls_section(
1390 'premium_person_description_style',
1391 array(
1392 'label' => __( 'Description', 'premium-addons-for-elementor' ),
1393 'tab' => Controls_Manager::TAB_STYLE,
1394 )
1395 );
1396
1397 $this->add_control(
1398 'premium_person_description_color',
1399 array(
1400 'label' => __( 'Color', 'premium-addons-for-elementor' ),
1401 'type' => Controls_Manager::COLOR,
1402 'global' => array(
1403 'default' => Global_Colors::COLOR_TEXT,
1404 ),
1405 'selectors' => array(
1406 '{{WRAPPER}} .premium-person-content' => 'color: {{VALUE}};',
1407 ),
1408 )
1409 );
1410
1411 $this->add_group_control(
1412 Group_Control_Typography::get_type(),
1413 array(
1414 'name' => 'description_typography',
1415 'global' => array(
1416 'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
1417 ),
1418 'selector' => '{{WRAPPER}} .premium-person-content',
1419 )
1420 );
1421
1422 $this->add_group_control(
1423 Group_Control_Text_Shadow::get_type(),
1424 array(
1425 'name' => 'description_shadow',
1426 'selector' => '{{WRAPPER}} .premium-person-content',
1427 )
1428 );
1429
1430 $this->add_responsive_control(
1431 'description_padding',
1432 array(
1433 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1434 'type' => Controls_Manager::DIMENSIONS,
1435 'size_units' => array( 'px', 'em', '%' ),
1436 'selectors' => array(
1437 '{{WRAPPER}} .premium-person-content' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1438 ),
1439 )
1440 );
1441
1442 $this->end_controls_section();
1443
1444 $this->start_controls_section(
1445 'premium_person_social_icon_style',
1446 array(
1447 'label' => __( 'Social Icons', 'premium-addons-for-elementor' ),
1448 'tab' => Controls_Manager::TAB_STYLE,
1449 'condition' => array(
1450 'premium_person_social_enable' => 'yes',
1451 ),
1452 )
1453 );
1454
1455 $this->add_responsive_control(
1456 'premium_person_social_size',
1457 array(
1458 'label' => __( 'Size', 'premium-addons-for-elementor' ),
1459 'type' => Controls_Manager::SLIDER,
1460 'size_units' => array( 'px', 'em', '%' ),
1461 'label_block' => true,
1462 'selectors' => array(
1463 '{{WRAPPER}} .premium-person-list-item i' => 'font-size: {{SIZE}}{{UNIT}};',
1464 ),
1465 )
1466 );
1467
1468 $this->add_control(
1469 'premium_person_social_color',
1470 array(
1471 'label' => __( 'Color', 'premium-addons-for-elementor' ),
1472 'type' => Controls_Manager::COLOR,
1473 'global' => array(
1474 'default' => Global_Colors::COLOR_PRIMARY,
1475 ),
1476 'selectors' => array(
1477 '{{WRAPPER}} .premium-person-list-item i' => 'color: {{VALUE}};',
1478 ),
1479 )
1480 );
1481
1482 $this->add_control(
1483 'premium_person_social_hover_color',
1484 array(
1485 'label' => __( 'Hover Color', 'premium-addons-for-elementor' ),
1486 'type' => Controls_Manager::COLOR,
1487 'global' => array(
1488 'default' => Global_Colors::COLOR_SECONDARY,
1489 ),
1490 'selectors' => array(
1491 '{{WRAPPER}} .premium-person-list-item:hover i' => 'color: {{VALUE}}',
1492 ),
1493 )
1494 );
1495
1496 $this->add_control(
1497 'premium_person_social_background',
1498 array(
1499 'label' => __( 'Background Color', 'premium-addons-for-elementor' ),
1500 'type' => Controls_Manager::COLOR,
1501 'selectors' => array(
1502 '{{WRAPPER}} .premium-person-list-item a' => 'background-color: {{VALUE}}',
1503 ),
1504 )
1505 );
1506
1507 $this->add_control(
1508 'premium_person_social_default_colors',
1509 array(
1510 'label' => __( 'Brands Default Colors', 'premium-addons-for-elementor' ),
1511 'type' => Controls_Manager::SWITCHER,
1512 'prefix_class' => 'premium-person-defaults-',
1513 )
1514 );
1515
1516 $this->add_control(
1517 'premium_person_social_hover_background',
1518 array(
1519 'label' => __( 'Hover Background Color', 'premium-addons-for-elementor' ),
1520 'type' => Controls_Manager::COLOR,
1521 'selectors' => array(
1522 '{{WRAPPER}} li.premium-person-list-item:hover a' => 'background-color: {{VALUE}}',
1523 ),
1524 'condition' => array(
1525 'premium_person_social_default_colors!' => 'yes',
1526 ),
1527 )
1528 );
1529
1530 $this->add_group_control(
1531 Group_Control_Border::get_type(),
1532 array(
1533 'name' => 'premium_person_social_border',
1534 'selector' => '{{WRAPPER}} .premium-person-list-item a',
1535 )
1536 );
1537
1538 $this->add_responsive_control(
1539 'premium_person_social_radius',
1540 array(
1541 'label' => __( 'Border Radius', 'premium-addons-for-elementor' ),
1542 'type' => Controls_Manager::DIMENSIONS,
1543 'size_units' => array( 'px', 'em', '%' ),
1544 'selectors' => array(
1545 '{{WRAPPER}} .premium-person-list-item a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}}',
1546 ),
1547 'condition' => array(
1548 'social_adv_radius!' => 'yes',
1549 ),
1550 )
1551 );
1552
1553 $this->add_control(
1554 'social_adv_radius',
1555 array(
1556 'label' => __( 'Advanced Border Radius', 'premium-addons-for-elementor' ),
1557 'type' => Controls_Manager::SWITCHER,
1558 'description' => __( 'Apply custom radius values. Get the radius value from ', 'premium-addons-for-elementor' ) . '<a href="https://9elements.github.io/fancy-border-radius/" target="_blank">here</a>' . __( '. See ', 'premium-addons-for-elementor' ) . '<a href="https://www.youtube.com/watch?v=S0BJazLHV-M" target="_blank">tutorial</a>',
1559 )
1560 );
1561
1562 $this->add_control(
1563 'social_adv_radius_value',
1564 array(
1565 'label' => __( 'Border Radius', 'premium-addons-for-elementor' ),
1566 'type' => Controls_Manager::TEXT,
1567 'dynamic' => array( 'active' => true ),
1568 'selectors' => array(
1569 '{{WRAPPER}} .premium-person-list-item a' => 'border-radius: {{VALUE}};',
1570 ),
1571 'condition' => array(
1572 'social_adv_radius' => 'yes',
1573 ),
1574 )
1575 );
1576
1577 $this->add_responsive_control(
1578 'premium_person_social_margin',
1579 array(
1580 'label' => __( 'Margin', 'premium-addons-for-elementor' ),
1581 'type' => Controls_Manager::DIMENSIONS,
1582 'size_units' => array( 'px', 'em', '%' ),
1583 'selectors' => array(
1584 '{{WRAPPER}} .premium-person-list-item a' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1585 ),
1586 )
1587 );
1588
1589 $this->add_responsive_control(
1590 'premium_person_social_padding',
1591 array(
1592 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1593 'type' => Controls_Manager::DIMENSIONS,
1594 'size_units' => array( 'px', 'em', '%' ),
1595 'selectors' => array(
1596 '{{WRAPPER}} .premium-person-list-item a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1597 ),
1598 )
1599 );
1600
1601 $this->end_controls_section();
1602
1603 $this->start_controls_section(
1604 'premium_person_general_style',
1605 array(
1606 'label' => __( 'Content', 'premium-addons-for-elementor' ),
1607 'tab' => Controls_Manager::TAB_STYLE,
1608 )
1609 );
1610
1611 $this->add_control(
1612 'premium_person_content_background_color',
1613 array(
1614 'label' => __( 'Background Color', 'premium-addons-for-elementor' ),
1615 'type' => Controls_Manager::COLOR,
1616 'default' => 'rgba(245,245,245,0.97)',
1617 'selectors' => array(
1618 '{{WRAPPER}} .premium-person-info' => 'background-color: {{VALUE}};',
1619 ),
1620 )
1621 );
1622
1623 $this->add_control(
1624 'body_lq_effect',
1625 array(
1626 'label' => __( 'Liquid Glass Effect', 'premium-addons-for-elementor' ),
1627 'type' => Controls_Manager::SELECT,
1628 'description' => sprintf(
1629 /* translators: 1: `<a>` opening tag, 2: `</a>` closing tag. */
1630 esc_html__( 'Important: Make sure this element has a semi-transparent background color to see the effect. See all presets from %1$shere%2$s.', 'premium-addons-for-elementor' ),
1631 '<a href="https://premiumaddons.com/liquid-glass/" target="_blank">',
1632 '</a>'
1633 ),
1634 'options' => array(
1635 'none' => __( 'None', 'premium-addons-for-elementor' ),
1636 'glass1' => __( 'Preset 01', 'premium-addons-for-elementor' ),
1637 'glass2' => __( 'Preset 02', 'premium-addons-for-elementor' ),
1638 'glass3' => apply_filters( 'pa_pro_label', __( 'Preset 03 (Pro)', 'premium-addons-for-elementor' ) ),
1639 'glass4' => apply_filters( 'pa_pro_label', __( 'Preset 04 (Pro)', 'premium-addons-for-elementor' ) ),
1640 'glass5' => apply_filters( 'pa_pro_label', __( 'Preset 05 (Pro)', 'premium-addons-for-elementor' ) ),
1641 'glass6' => apply_filters( 'pa_pro_label', __( 'Preset 06 (Pro)', 'premium-addons-for-elementor' ) ),
1642 ),
1643 'default' => 'none',
1644 'label_block' => true,
1645 'condition' => array(
1646 'premium_person_style!' => 'style3',
1647 ),
1648 )
1649 );
1650
1651 $this->add_responsive_control(
1652 'premium_person_border_bottom_width',
1653 array(
1654 'label' => __( 'Bottom Offset', 'premium-addons-for-elementor' ),
1655 'type' => Controls_Manager::SLIDER,
1656 'size_units' => array( 'px', 'em', '%' ),
1657 'range' => array(
1658 'px' => array(
1659 'min' => 0,
1660 'max' => 700,
1661 ),
1662 ),
1663 'default' => array(
1664 'size' => 20,
1665 'unit' => 'px',
1666 ),
1667 'label_block' => true,
1668 'condition' => array(
1669 'premium_person_style' => 'style1',
1670 ),
1671 'selectors' => array(
1672 '{{WRAPPER}} .premium-person-info' => 'bottom: {{SIZE}}{{UNIT}}',
1673 ),
1674 )
1675 );
1676
1677 $this->add_responsive_control(
1678 'premium_person_content_speed',
1679 array(
1680 'label' => __( 'Transition Duration (sec)', 'premium-addons-for-elementor' ),
1681 'type' => Controls_Manager::SLIDER,
1682 'range' => array(
1683 'px' => array(
1684 'min' => 0,
1685 'max' => 5,
1686 'step' => 0.1,
1687 ),
1688 ),
1689 'selectors' => array(
1690 '{{WRAPPER}} .premium-person-info, {{WRAPPER}} .premium-person-image-container img' => 'transition-duration: {{SIZE}}s',
1691 ),
1692 )
1693 );
1694
1695 $this->add_responsive_control(
1696 'premium_person_content_padding',
1697 array(
1698 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1699 'type' => Controls_Manager::DIMENSIONS,
1700 'size_units' => array( 'px', 'em', '%' ),
1701 'selectors' => array(
1702 '{{WRAPPER}} .premium-person-info-container' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1703 ),
1704 )
1705 );
1706
1707 $this->end_controls_section();
1708
1709 $this->start_controls_section(
1710 'carousel_style',
1711 array(
1712 'label' => __( 'Carousel', 'premium-addons-for-elementor' ),
1713 'tab' => Controls_Manager::TAB_STYLE,
1714 'condition' => array(
1715 'carousel' => 'yes',
1716 ),
1717 )
1718 );
1719
1720 $this->add_control(
1721 'arrow_color',
1722 array(
1723 'label' => __( 'Color', 'premium-addons-for-elementor' ),
1724 'type' => Controls_Manager::COLOR,
1725 'global' => array(
1726 'default' => Global_Colors::COLOR_PRIMARY,
1727 ),
1728 'selectors' => array(
1729 '{{WRAPPER}} .premium-persons-container .slick-arrow' => 'color: {{VALUE}};',
1730 ),
1731 )
1732 );
1733
1734 $this->add_control(
1735 'arrow_hover_color',
1736 array(
1737 'label' => __( 'Hover Color', 'premium-addons-for-elementor' ),
1738 'type' => Controls_Manager::COLOR,
1739 'global' => array(
1740 'default' => Global_Colors::COLOR_PRIMARY,
1741 ),
1742 'selectors' => array(
1743 '{{WRAPPER}} .premium-persons-container .slick-arrow:hover' => 'color: {{VALUE}};',
1744 ),
1745 )
1746 );
1747
1748 $this->add_responsive_control(
1749 'arrow_size',
1750 array(
1751 'label' => __( 'Size', 'premium-addons-for-elementor' ),
1752 'type' => Controls_Manager::SLIDER,
1753 'size_units' => array( 'px', '%', 'em' ),
1754 'selectors' => array(
1755 '{{WRAPPER}} .premium-persons-container .slick-arrow i' => 'font-size: {{SIZE}}{{UNIT}};',
1756 ),
1757 )
1758 );
1759
1760 $this->add_control(
1761 'arrow_background',
1762 array(
1763 'label' => __( 'Background Color', 'premium-addons-for-elementor' ),
1764 'type' => Controls_Manager::COLOR,
1765 'global' => array(
1766 'default' => Global_Colors::COLOR_SECONDARY,
1767 ),
1768 'selectors' => array(
1769 '{{WRAPPER}} .premium-persons-container .slick-arrow' => 'background-color: {{VALUE}};',
1770 ),
1771 )
1772 );
1773
1774 $this->add_control(
1775 'arrow_hover_background',
1776 array(
1777 'label' => __( 'Background Hover Color', 'premium-addons-for-elementor' ),
1778 'type' => Controls_Manager::COLOR,
1779 'global' => array(
1780 'default' => Global_Colors::COLOR_SECONDARY,
1781 ),
1782 'selectors' => array(
1783 '{{WRAPPER}} .premium-persons-container .slick-arrow:hover' => 'background-color: {{VALUE}};',
1784 ),
1785 )
1786 );
1787
1788 $this->add_control(
1789 'arrow_border_radius',
1790 array(
1791 'label' => __( 'Border Radius', 'premium-addons-for-elementor' ),
1792 'type' => Controls_Manager::SLIDER,
1793 'size_units' => array( 'px', '%', 'em' ),
1794 'selectors' => array(
1795 '{{WRAPPER}} .premium-persons-container .slick-arrow' => 'border-radius: {{SIZE}}{{UNIT}};',
1796 ),
1797 )
1798 );
1799
1800 $this->add_control(
1801 'arrow_padding',
1802 array(
1803 'label' => __( 'Padding', 'premium-addons-for-elementor' ),
1804 'type' => Controls_Manager::SLIDER,
1805 'size_units' => array( 'px', '%', 'em' ),
1806 'selectors' => array(
1807 '{{WRAPPER}} .premium-persons-container .slick-arrow' => 'padding: {{SIZE}}{{UNIT}};',
1808 ),
1809 )
1810 );
1811
1812 $this->end_controls_section();
1813 }
1814
1815 /**
1816 * Render Persons widget output on the frontend.
1817 *
1818 * Written in PHP and used to generate the final HTML.
1819 *
1820 * @since 1.0.0
1821 * @access protected
1822 */
1823 protected function render() {
1824
1825 $settings = $this->get_settings_for_display();
1826
1827 $image_effect = $settings['premium_person_hover_image_effect'];
1828
1829 $image_html = '';
1830 if ( ! empty( $settings['premium_person_image']['url'] ) ) {
1831 $image_html = Group_Control_Image_Size::get_attachment_image_html( $settings, 'thumbnail', 'premium_person_image' );
1832 }
1833
1834 $this->add_render_attribute(
1835 'persons_container',
1836 'class',
1837 array(
1838 'premium-persons-container',
1839 'premium-person-' . $settings['premium_person_style'],
1840 )
1841 );
1842
1843 $this->add_render_attribute(
1844 'person_container',
1845 'class',
1846 array(
1847 'premium-person-container',
1848 'premium-person-' . $image_effect . '-effect',
1849 )
1850 );
1851
1852 if ( 'yes' === $settings['multiple'] ) {
1853 $persons = $settings['multiple_persons'];
1854 $this->add_render_attribute( 'persons_container', 'class', 'multiple-persons' );
1855 $this->add_render_attribute( 'persons_container', 'data-persons-equal', $settings['multiple_equal_height'] );
1856 } else {
1857 $this->add_render_attribute( 'premium_person_profile', 'class', 'premium-person-link' );
1858 $this->add_link_attributes( 'premium_person_profile', $settings['premium_person_profile'] );
1859 }
1860
1861 $carousel = 'yes' === $settings['carousel'] ? true : false;
1862
1863 if ( $carousel ) {
1864
1865 $this->add_render_attribute( 'persons_container', 'data-carousel', $carousel );
1866
1867 $this->add_render_attribute(
1868 'persons_container',
1869 array(
1870 'data-rtl' => is_rtl(),
1871 )
1872 );
1873
1874 }
1875
1876 $this->add_render_attribute( 'info_container', 'class', 'premium-person-info' );
1877
1878 if( 'none' !== $settings['body_lq_effect'] && 'style3' !== $settings['premium_person_style'] ) {
1879 $this->add_render_attribute( 'info_container', 'class', 'premium-con-lq__' . $settings['body_lq_effect'] );
1880 }
1881
1882 ?>
1883 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'persons_container' ) ); ?>>
1884 <?php if ( 'yes' !== $settings['multiple'] ) : ?>
1885 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'person_container' ) ); ?>>
1886
1887 <div class="premium-person-image-container">
1888 <?php if ( 'style3' !== $settings['premium_person_style'] && ! empty( $settings['premium_person_profile']['url'] ) ) { ?>
1889 <a <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_person_profile' ) ); ?>>
1890 <?php echo wp_kses_post( $image_html ); ?>
1891 </a>
1892 <?php
1893 } else {
1894 echo wp_kses_post( $image_html );
1895 }
1896 ?>
1897
1898 <?php if ( 'style2' === $settings['premium_person_style'] && 'yes' === $settings['premium_person_social_enable'] ) : ?>
1899 <div class="premium-person-social">
1900 <?php $this->get_social_icons(); ?>
1901 </div>
1902 <?php endif; ?>
1903 </div>
1904 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'info_container' ) ); ?>>
1905 <?php $this->render_person_info(); ?>
1906 </div>
1907 </div>
1908 <?php
1909 else :
1910 foreach ( $persons as $index => $person ) {
1911
1912 $person_image_html = '';
1913
1914 // Add profile link for each person
1915 if ( ! empty( $person['multiple_profile']['url'] ) ) {
1916 $this->add_render_attribute( 'premium_multiple_profile_' . $index, 'class', 'premium-person-link' );
1917 $this->add_link_attributes( 'premium_multiple_profile_' . $index, $person['multiple_profile'] );
1918 }
1919
1920 if ( ! empty( $person['multiple_image']['url'] ) ) {
1921
1922 $image_src = $person['multiple_image']['url'];
1923 $image_id = attachment_url_to_postid( $image_src );
1924
1925 $settings['image_data'] = Helper_Functions::get_image_data( $image_id, $person['multiple_image']['url'], $settings['thumbnail_size'] );
1926 $person_image_html = Group_Control_Image_Size::get_attachment_image_html( $settings, 'thumbnail', 'image_data' );
1927
1928 if ( 'style3' !== $settings['premium_person_style'] && ! empty( $person['multiple_profile']['url'] ) ) {
1929 $person_image_html = '<a ' . wp_kses_post( $this->get_render_attribute_string( 'premium_multiple_profile_' . $index ) ) . '>' . $person_image_html . '</a>';
1930 }
1931 }
1932
1933 ?>
1934 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'person_container' ) ); ?>>
1935 <div class="premium-person-image-container">
1936 <?php echo wp_kses_post( $person_image_html ); ?>
1937 <?php if ( 'style2' === $settings['premium_person_style'] && 'yes' === $person['multiple_social_enable'] ) : ?>
1938 <div class="premium-person-social">
1939 <?php $this->get_social_icons( $person ); ?>
1940 </div>
1941 <?php endif; ?>
1942 </div>
1943 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'info_container' ) ); ?>>
1944 <?php $this->render_person_info( $person, $index ); ?>
1945 </div>
1946 </div>
1947 <?php
1948 }
1949 endif;
1950 ?>
1951 </div>
1952 <?php
1953 }
1954
1955 /**
1956 * Get Social Icons
1957 *
1958 * Render person social icons list
1959 *
1960 * @since 3.8.4
1961 * @access protected
1962 *
1963 * @param object $person current person.
1964 */
1965 private function get_social_icons( $person = '' ) {
1966
1967 $settings = $this->get_settings_for_display();
1968
1969 $social_sites = array(
1970 'facebook' => 'fab fa-facebook-f',
1971 'twitter' => 'fab fa-twitter',
1972 'linkedin' => 'fab fa-linkedin',
1973 'google' => 'fab fa-google-plus',
1974 'youtube' => 'fab fa-youtube',
1975 'instagram' => 'fab fa-instagram',
1976 'skype' => 'fab fa-skype',
1977 'pinterest' => 'fab fa-pinterest',
1978 'dribbble' => 'fab fa-dribbble',
1979 'behance' => 'fab fa-behance',
1980 'whatsapp' => 'fab fa-whatsapp',
1981 'telegram' => 'fab fa-telegram',
1982 'mail' => 'fa fa-envelope',
1983 'site' => 'fa fa-link',
1984 'number' => 'fa fa-phone',
1985 );
1986
1987 echo '<ul class="premium-person-social-list">';
1988
1989 do_action( 'pa_before_member_icon' );
1990
1991 foreach ( $social_sites as $site => $icon ) {
1992
1993 if ( ! \Elementor\Plugin::instance()->editor->is_edit_mode() ) {
1994 if ( 'number' === $site && ! wp_is_mobile() ) {
1995 continue;
1996 }
1997 }
1998
1999 $value = ( '' === $person ) ? $settings[ 'premium_person_' . $site ] : $person[ 'multiple_' . $site ];
2000
2001 if ( ! empty( $value ) ) {
2002 $icon_class = sprintf( 'elementor-icon premium-person-list-item premium-person-%s', $site );
2003 ?>
2004 <li class="<?php echo esc_attr( $icon_class ); ?>">
2005 <a href="<?php echo esc_url( $value ); ?>" target="_blank">
2006 <i class="<?php echo esc_attr( $icon ); ?>"></i>
2007 </a>
2008 </li>
2009 <?php
2010 }
2011 }
2012
2013 do_action( 'pa_after_member_icon' );
2014
2015 echo '</ul>';
2016 }
2017
2018 /**
2019 * Render Person Info
2020 *
2021 * @since 3.12.0
2022 * @access protected
2023 *
2024 * @param object $person current person.
2025 * @param integer $index person index.
2026 */
2027 protected function render_person_info( $person = '', $index = '' ) {
2028
2029 $settings = $this->get_settings_for_display();
2030
2031 $this->add_inline_editing_attributes( 'premium_person_name', 'advanced' );
2032 $this->add_render_attribute( 'premium_person_name', 'class', 'premium-person-name' );
2033
2034 $this->add_inline_editing_attributes( 'premium_person_title', 'advanced' );
2035 $this->add_render_attribute( 'premium_person_title', 'class', 'premium-person-title' );
2036
2037 $this->add_inline_editing_attributes( 'premium_person_content', 'advanced' );
2038 $this->add_render_attribute( 'premium_person_content', 'class', 'premium-person-content' );
2039
2040 $name_heading = Helper_Functions::validate_html_tag( $settings['premium_person_name_heading'] );
2041
2042 $title_heading = Helper_Functions::validate_html_tag( $settings['premium_person_title_heading'] );
2043
2044 $skin = $settings['premium_person_style'];
2045
2046 if ( empty( $person ) ) :
2047 ?>
2048 <div class="premium-person-info-container">
2049 <?php
2050 if ( 'style3' !== $skin && ! empty( $settings['premium_person_name'] ) ) :
2051 $name_tag_open = '<' . wp_kses_post( $name_heading ) . ' ' . $this->get_render_attribute_string( 'premium_person_name' ) . '>';
2052 $name_tag_close = '</' . wp_kses_post( $name_heading ) . '>';
2053 $name_content = wp_kses_post( $settings['premium_person_name'] );
2054 $name_html = $name_tag_open . $name_content . $name_tag_close;
2055 ?>
2056 <?php if ( ! empty( $settings['premium_person_profile']['url'] ) ) { ?>
2057 <a <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_person_profile' ) ); ?>>
2058 <?php echo $name_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2059 </a>
2060 <?php
2061 } else {
2062 echo $name_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
2063 }
2064 ?>
2065 <?php
2066 endif;
2067
2068 if ( 'style3' === $skin ) :
2069 ?>
2070 <div class="premium-person-title-desc-wrap">
2071 <?php
2072 endif;
2073 if ( ! empty( $settings['premium_person_title'] ) ) :
2074 ?>
2075 <<?php echo wp_kses_post( $title_heading . ' ' . $this->get_render_attribute_string( 'premium_person_title' ) ); ?>>
2076 <span><?php echo wp_kses_post( $settings['premium_person_title'] ); ?></span>
2077 </<?php echo wp_kses_post( $title_heading ); ?>>
2078 <?php
2079 endif;
2080
2081 if ( ! empty( $settings['premium_person_content'] ) ) :
2082 ?>
2083 <div <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_person_content' ) ); ?>>
2084 <?php echo $this->parse_text_editor( $settings['premium_person_content'] ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2085 </div>
2086 <?php
2087 endif;
2088 if ( 'style3' === $skin ) :
2089 ?>
2090 </div>
2091 <?php
2092 endif;
2093
2094 if ( 'style3' === $skin ) :
2095 ?>
2096 <div class="premium-person-name-icons-wrap">
2097 <?php
2098 if ( ! empty( $settings['premium_person_name'] ) ) :
2099 $name_heading_tag = esc_html( $name_heading );
2100 $name_tag_open = '<' . $name_heading_tag . ' class="premium-person-name">';
2101 $name_tag_close = '</' . $name_heading_tag . '>';
2102 $name_span = '<span ' . $this->get_render_attribute_string( 'premium_person_name' ) . '>' .
2103 wp_kses_post( $settings['premium_person_name'] ) .
2104 '</span>';
2105 $name_html = $name_tag_open . $name_span . $name_tag_close;
2106 ?>
2107 <?php if ( ! empty( $settings['premium_person_profile']['url'] ) ) { ?>
2108 <a <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_person_profile' ) ); ?>>
2109 <?php echo $name_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2110 </a>
2111 <?php
2112 } else {
2113 echo $name_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
2114 }
2115 ?>
2116
2117 <?php
2118 endif;
2119 if ( 'yes' === $settings['premium_person_social_enable'] ) :
2120 $this->get_social_icons();
2121 endif;
2122 ?>
2123 </div>
2124 <?php
2125 endif;
2126
2127 if ( 'style1' === $settings['premium_person_style'] && 'yes' === $settings['premium_person_social_enable'] ) :
2128 $this->get_social_icons();
2129 endif;
2130 ?>
2131 </div>
2132 <?php
2133 else :
2134
2135 $name_setting_key = $this->get_repeater_setting_key( 'multiple_name', 'multiple_persons', $index );
2136 $title_setting_key = $this->get_repeater_setting_key( 'multiple_title', 'multiple_persons', $index );
2137 $desc_setting_key = $this->get_repeater_setting_key( 'multiple_description', 'multiple_persons', $index );
2138
2139 $this->add_inline_editing_attributes( $name_setting_key, 'advanced' );
2140 $this->add_render_attribute( $name_setting_key, 'class', 'premium-person-name' );
2141
2142 $this->add_inline_editing_attributes( $title_setting_key, 'advanced' );
2143 $this->add_render_attribute( $title_setting_key, 'class', 'premium-person-title' );
2144
2145 $this->add_inline_editing_attributes( $desc_setting_key, 'advanced' );
2146 $this->add_render_attribute( $desc_setting_key, 'class', 'premium-person-content' );
2147
2148 ?>
2149 <div class="premium-person-info-container">
2150 <?php
2151 if ( 'style3' !== $skin && ! empty( $person['multiple_name'] ) ) :
2152 $name_tag_open = '<' . esc_html( $name_heading ) . ' ' . $this->get_render_attribute_string( $name_setting_key ) . '>';
2153 $name_tag_close = '</' . esc_html( $name_heading ) . '>';
2154 $name_content = wp_kses_post( $person['multiple_name'] );
2155 $name_html_multiple = $name_tag_open . $name_content . $name_tag_close;
2156 ?>
2157 <?php if ( ! empty( $person['multiple_profile']['url'] ) ) { ?>
2158 <a <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_multiple_profile_' . $index ) ); ?>>
2159 <?php echo $name_html_multiple; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2160 </a>
2161 <?php
2162 } else {
2163 echo $name_html_multiple; } // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
2164 ?>
2165
2166 <?php
2167 endif;
2168
2169 if ( 'style3' === $skin ) :
2170 ?>
2171 <div class="premium-person-title-desc-wrap">
2172 <?php
2173 endif;
2174 if ( ! empty( $person['multiple_title'] ) ) :
2175 ?>
2176 <<?php echo wp_kses_post( $title_heading . ' ' . $this->get_render_attribute_string( $title_setting_key ) ); ?>>
2177 <span><?php echo wp_kses_post( $person['multiple_title'] ); ?></span>
2178 </<?php echo wp_kses_post( $title_heading ); ?>>
2179 <?php
2180 endif;
2181
2182 if ( ! empty( $person['multiple_description'] ) ) :
2183 ?>
2184 <div <?php echo wp_kses_post( $this->get_render_attribute_string( $desc_setting_key ) ); ?>>
2185 <?php echo $this->parse_text_editor( $person['multiple_description'] ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2186 </div>
2187 <?php
2188 endif;
2189 if ( 'style3' === $skin ) :
2190 ?>
2191 </div>
2192 <?php
2193 endif;
2194
2195 if ( 'style3' === $skin ) :
2196
2197 ?>
2198 <div class="premium-person-name-icons-wrap">
2199 <?php
2200 if ( ! empty( $person['multiple_name'] ) ) :
2201 $name_tag_open = '<' . esc_html( $name_heading ) . ' class="premium-person-name">';
2202 $name_tag_close = '</' . esc_html( $name_heading ) . '>';
2203 $name_content = '<span ' . $this->get_render_attribute_string( $name_setting_key ) . '>' . wp_kses_post( $person['multiple_name'] ) . '</span>';
2204 $name_html_multiple = $name_tag_open . $name_content . $name_tag_close;
2205 ?>
2206 <?php if ( ! empty( $person['multiple_profile']['url'] ) ) { ?>
2207 <a <?php echo wp_kses_post( $this->get_render_attribute_string( 'premium_multiple_profile_' . $index ) ); ?>>
2208 <?php echo $name_html_multiple; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
2209 </a>
2210 <?php
2211 } else {
2212 echo $name_html_multiple; } // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
2213 ?>
2214
2215 <?php
2216 endif;
2217 if ( 'yes' === $person['multiple_social_enable'] ) :
2218 $this->get_social_icons( $person );
2219 endif;
2220 ?>
2221 </div>
2222 <?php
2223 endif;
2224
2225 if ( 'style1' === $settings['premium_person_style'] && 'yes' === $person['multiple_social_enable'] ) :
2226 $this->get_social_icons( $person );
2227 endif;
2228 ?>
2229 </div>
2230 <?php
2231 endif;
2232 }
2233
2234
2235 /**
2236 * Render Persons widget output in the editor.
2237 *
2238 * Written as a Backbone JavaScript template and used to generate the live preview.
2239 *
2240 * @since 1.0.0
2241 * @access protected
2242 */
2243 protected function content_template() {
2244 ?>
2245 <#
2246
2247 view.addInlineEditingAttributes( 'premium_person_name', 'advanced' );
2248 view.addRenderAttribute( 'premium_person_name', 'class', 'premium-person-name' );
2249
2250 view.addInlineEditingAttributes( 'premium_person_title', 'advanced' );
2251 view.addRenderAttribute( 'premium_person_title', 'class', 'premium-person-title' );
2252
2253 view.addInlineEditingAttributes( 'premium_person_content', 'advanced' );
2254 view.addRenderAttribute( 'premium_person_content', 'class', 'premium-person-content' );
2255
2256 var nameHeading = elementor.helpers.validateHTMLTag( settings.premium_person_name_heading ),
2257
2258 titleHeading = elementor.helpers.validateHTMLTag( settings.premium_person_title_heading ),
2259
2260 imageEffect = 'premium-person-' + settings.premium_person_hover_image_effect + '-effect' ;
2261
2262 skin = settings.premium_person_style;
2263
2264 view.addRenderAttribute( 'persons_container', 'class', [ 'premium-persons-container', 'premium-person-' + skin ] );
2265
2266 view.addRenderAttribute( 'person_container', 'class', [ 'premium-person-container', imageEffect ] );
2267
2268 view.addRenderAttribute( 'premium_person_profile', 'href', settings.premium_person_profile.url );
2269
2270
2271 var imageHtml = '';
2272 if ( settings.premium_person_image.url ) {
2273 var image = {
2274 id: settings.premium_person_image.id,
2275 url: settings.premium_person_image.url,
2276 size: settings.thumbnail_size,
2277 dimension: settings.thumbnail_custom_dimension,
2278 model: view.getEditModel()
2279 };
2280
2281 var image_url = elementor.imagesManager.getImageUrl( image );
2282
2283 }
2284
2285 if ( settings.multiple ) {
2286 var persons = settings.multiple_persons;
2287 view.addRenderAttribute( 'persons_container', 'class', 'multiple-persons' );
2288 view.addRenderAttribute( 'persons_container', 'data-persons-equal', settings.multiple_equal_height );
2289 }
2290
2291 var carousel = 'yes' === settings.carousel ? true : false;
2292
2293 if( carousel ) {
2294
2295 view.addRenderAttribute('persons_container', {
2296 'data-carousel': carousel,
2297 });
2298
2299 }
2300
2301
2302 function getSocialIcons( person = null ) {
2303
2304 var personSettings,
2305 socialIcons;
2306
2307 if( null === person ) {
2308 personSettings = settings;
2309 socialIcons = {
2310 facebook: settings.premium_person_facebook,
2311 twitter: settings.premium_person_twitter,
2312 linkedin: settings.premium_person_linkedin,
2313 google: settings.premium_person_google,
2314 youtube: settings.premium_person_youtube,
2315 instagram: settings.premium_person_instagram,
2316 skype: settings.premium_person_skype,
2317 pinterest: settings.premium_person_pinterest,
2318 dribbble: settings.premium_person_dribbble,
2319 behance: settings.premium_person_behance,
2320 whatsapp: settings.premium_person_whatsapp,
2321 telegram: settings.premium_person_telegram,
2322 mail: settings.premium_person_mail,
2323 site: settings.premium_person_site,
2324 number: settings.premium_person_number
2325 };
2326 } else {
2327 personSettings = person;
2328 socialIcons = {
2329 facebook: person.multiple_facebook,
2330 twitter: person.multiple_twitter,
2331 linkedin: person.multiple_linkedin,
2332 google: person.multiple_google,
2333 youtube: person.multiple_youtube,
2334 instagram: person.multiple_instagram,
2335 skype: person.multiple_skype,
2336 pinterest: person.multiple_pinterest,
2337 dribbble: person.multiple_dribbble,
2338 behance: person.multiple_behance,
2339 whatsapp: person.multiple_whatsapp,
2340 telegram: person.multiple_telegram,
2341 mail: person.multiple_mail,
2342 site: person.multiple_site,
2343 number: person.multiple_number
2344 };
2345 }
2346
2347 #>
2348 <ul class="premium-person-social-list">
2349 <# if( '' != socialIcons.facebook ) { #>
2350 <li class="elementor-icon premium-person-list-item premium-person-facebook"><a href="{{ socialIcons.facebook }}" target="_blank"><i class="fab fa-facebook-f"></i></a></li>
2351 <# } #>
2352
2353 <# if( '' != socialIcons.twitter ) { #>
2354 <li class="elementor-icon premium-person-list-item premium-person-twitter"><a href="{{ socialIcons.twitter }}" target="_blank"><i class="fab fa-twitter"></i></a></li>
2355 <# } #>
2356
2357 <# if( '' != socialIcons.linkedin ) { #>
2358 <li class="elementor-icon premium-person-list-item premium-person-linkedin"><a href="{{ socialIcons.linkedin }}" target="_blank"><i class="fab fa-linkedin"></i></a></li>
2359 <# } #>
2360
2361 <# if( '' != socialIcons.google ) { #>
2362 <li class="elementor-icon premium-person-list-item premium-person-google"><a href="{{ socialIcons.google }}" target="_blank"><i class="fab fa-google-plus"></i></a></li>
2363 <# } #>
2364
2365 <# if( '' != socialIcons.youtube ) { #>
2366 <li class="elementor-icon premium-person-list-item premium-person-youtube"><a href="{{ socialIcons.youtube }}" target="_blank"><i class="fab fa-youtube"></i></a></li>
2367 <# } #>
2368
2369 <# if( '' != socialIcons.instagram ) { #>
2370 <li class="elementor-icon premium-person-list-item premium-person-instagram"><a href="{{ socialIcons.instagram }}" target="_blank"><i class="fab fa-instagram"></i></a></li>
2371 <# } #>
2372
2373 <# if( '' != socialIcons.skype ) { #>
2374 <li class="elementor-icon premium-person-list-item premium-person-skype"><a href="{{ socialIcons.skype }}" target="_blank"><i class="fab fa-skype"></i></a></li>
2375 <# } #>
2376
2377 <# if( '' != socialIcons.pinterest ) { #>
2378 <li class="elementor-icon premium-person-list-item premium-person-pinterest"><a href="{{ socialIcons.pinterest }}" target="_blank"><i class="fab fa-pinterest"></i></a></li>
2379 <# } #>
2380
2381 <# if( '' != socialIcons.dribbble ) { #>
2382 <li class="elementor-icon premium-person-list-item premium-person-dribbble"><a href="{{ socialIcons.dribbble }}" target="_blank"><i class="fab fa-dribbble"></i></a></li>
2383 <# } #>
2384
2385 <# if( '' != socialIcons.behance ) { #>
2386 <li class="elementor-icon premium-person-list-item premium-person-behance"><a href="{{ socialIcons.behance }}" target="_blank"><i class="fab fa-behance"></i></a></li>
2387 <# } #>
2388
2389 <# if( '' != socialIcons.whatsapp ) { #>
2390 <li class="elementor-icon premium-person-list-item premium-person-whatsapp"><a href="{{ socialIcons.whatsapp }}" target="_blank"><i class="fab fa-whatsapp"></i></a></li>
2391 <# } #>
2392
2393 <# if( '' != socialIcons.telegram ) { #>
2394 <li class="elementor-icon premium-person-list-item premium-person-telegram"><a href="{{ socialIcons.mail }}" target="_blank"><i class="fab fa-telegram"></i></a></li>
2395 <# } #>
2396
2397 <# if( '' != socialIcons.mail ) { #>
2398 <li class="elementor-icon premium-person-list-item premium-person-mail"><a href="{{ socialIcons.mail }}" target="_blank"><i class="fa fa-envelope"></i></a></li>
2399 <# } #>
2400
2401 <# if( '' != socialIcons.site ) { #>
2402 <li class="elementor-icon premium-person-list-item premium-person-site"><a href="{{ socialIcons.site }}" target="_blank"><i class="fa fa-link"></i></a></li>
2403 <# } #>
2404
2405 <# if( '' != socialIcons.number ) { #>
2406 <li class="elementor-icon premium-person-list-item premium-person-number"><a href="{{ socialIcons.number }}" target="_blank"><i class="fa fa-phone"></i></a></li>
2407 <# } #>
2408
2409 </ul>
2410 <# }
2411
2412 view.addRenderAttribute( 'info_container', 'class', 'premium-person-info' );
2413
2414 if( 'none' !== settings.body_lq_effect && 'style3' !== settings.premium_person_style ) {
2415 view.addRenderAttribute( 'info_container', 'class', 'premium-con-lq__' + settings.body_lq_effect );
2416 }
2417 #>
2418
2419 <div {{{ view.getRenderAttributeString('persons_container') }}}>
2420 <# if( 'yes' !== settings.multiple ) { #>
2421 <div {{{ view.getRenderAttributeString('person_container') }}}>
2422 <div class="premium-person-image-container">
2423 <# if ( '' !== settings.premium_person_profile.url ) { #>
2424 <a {{{ view.getRenderAttributeString('premium_person_profile') }}}>
2425 <img src="{{ image_url }}"/>
2426 </a>
2427 <# } else { #>
2428 <img src="{{ image_url }}"/>
2429 <# } #>
2430 <# if ( 'style2' === settings.premium_person_style && 'yes' === settings.premium_person_social_enable ) { #>
2431 <div class="premium-person-social">
2432 <# getSocialIcons(); #>
2433 </div>
2434 <# } #>
2435 </div>
2436 <div {{{ view.getRenderAttributeString('info_container') }}}>
2437 <div class="premium-person-info-container">
2438 <# if( 'style3' !== skin && '' != settings.premium_person_name ) { #>
2439 <# if ( '' !== settings.premium_person_profile.url ) { #>
2440 <a {{{ view.getRenderAttributeString('premium_person_profile') }}}>
2441 <{{{nameHeading}}} {{{ view.getRenderAttributeString('premium_person_name') }}}>
2442 {{{ settings.premium_person_name }}}
2443 </{{{nameHeading}}}>
2444 </a>
2445 <# } else { #>
2446 <{{{nameHeading}}} {{{ view.getRenderAttributeString('premium_person_name') }}}>
2447 {{{ settings.premium_person_name }}}
2448 </{{{nameHeading}}}>
2449 <# } #>
2450 <# }
2451
2452 if( 'style3' === skin ) { #>
2453 <div class="premium-person-title-desc-wrap">
2454 <# }
2455 if( '' != settings.premium_person_title ) { #>
2456 <{{{titleHeading}}} {{{ view.getRenderAttributeString('premium_person_title') }}}>
2457 <span>{{{ settings.premium_person_title }}}</span>
2458 </{{{titleHeading}}}>
2459 <# }
2460 if( '' != settings.premium_person_content ) { #>
2461 <div {{{ view.getRenderAttributeString('premium_person_content') }}}>
2462 {{{ settings.premium_person_content }}}
2463 </div>
2464 <# }
2465 if( 'style3' === skin ) { #>
2466 </div>
2467 <# }
2468
2469 if( 'style3' === skin ) { #>
2470 <div class="premium-person-name-icons-wrap">
2471 <# if( '' != settings.premium_person_name ) { #>
2472 <# if ( '' !== settings.premium_person_profile.url ) { #>
2473 <a {{{ view.getRenderAttributeString('premium_person_profile') }}}>
2474 <{{{nameHeading}}} {{{ view.getRenderAttributeString('premium_person_name') }}}>
2475 {{{ settings.premium_person_name }}}
2476 </{{{nameHeading}}}>
2477 </a>
2478 <# } else { #>
2479 <{{{nameHeading}}} {{{ view.getRenderAttributeString('premium_person_name') }}}>
2480 {{{ settings.premium_person_name }}}
2481 </{{{nameHeading}}}>
2482 <# } #>
2483 <# }
2484 if( 'yes' === settings.premium_person_social_enable ) {
2485 getSocialIcons();
2486 } #>
2487 </div>
2488 <# }
2489
2490 if ( 'style1' === settings.premium_person_style && 'yes' === settings.premium_person_social_enable ) {
2491 getSocialIcons();
2492 } #>
2493 </div>
2494 </div>
2495 </div>
2496 <# } else {
2497 _.each( persons, function( person, index ) {
2498 var nameSettingKey = view.getRepeaterSettingKey( 'multiple_name', 'multiple_persons', index ),
2499 titleSettingKey = view.getRepeaterSettingKey( 'multiple_title', 'multiple_persons', index ),
2500 descSettingKey = view.getRepeaterSettingKey( 'multiple_description', 'multiple_persons', index );
2501
2502
2503 view.addInlineEditingAttributes( nameSettingKey, 'advanced' );
2504 view.addRenderAttribute( nameSettingKey, 'class', 'premium-person-name' );
2505
2506 view.addInlineEditingAttributes( titleSettingKey, 'advanced' );
2507 view.addRenderAttribute( titleSettingKey, 'class', 'premium-person-title' );
2508
2509 view.addInlineEditingAttributes( descSettingKey, 'advanced' );
2510 view.addRenderAttribute( descSettingKey, 'class', 'premium-person-content' );
2511
2512 if ( person.multiple_profile && person.multiple_profile.url ) {
2513 profileKey = 'premium_multiple_profile_' + index;
2514 view.addRenderAttribute( profileKey, 'href', person.multiple_profile.url );
2515 }
2516 var personImageHtml = '';
2517 if ( person.multiple_image.url ) {
2518 var personImage = {
2519 id: person.multiple_image.id,
2520 url: person.multiple_image.url,
2521 size: settings.thumbnail_size,
2522 dimension: settings.thumbnail_custom_dimension,
2523 model: view.getEditModel()
2524 };
2525
2526 var personImageUrl = elementor.imagesManager.getImageUrl( personImage );
2527
2528 }
2529 #>
2530 <div {{{ view.getRenderAttributeString('person_container') }}}>
2531 <div class="premium-person-image-container">
2532 <# if ( '' !== person.multiple_profile.url) { #>
2533 <a {{{ view.getRenderAttributeString('premium_multiple_profile_' + index) }}}>
2534 <img src="{{ personImageUrl }}"/>
2535 </a>
2536 <# } else { #>
2537 <img src="{{ personImageUrl }}"/>
2538 <# } #>
2539 <# if ( 'style2' === settings.premium_person_style && 'yes' === person.multiple_social_enable ) { #>
2540 <div class="premium-person-social">
2541 <# getSocialIcons( person ); #>
2542 </div>
2543 <# } #>
2544 </div>
2545 <div {{{ view.getRenderAttributeString('info_container') }}}>
2546 <div class="premium-person-info-container">
2547 <# if( 'style3' !== skin && '' != person.multiple_name ) { #>
2548 <# if ( '' !== person.multiple_profile.url ) { #>
2549 <a {{{ view.getRenderAttributeString('premium_multiple_profile_' + index) }}}>
2550 <{{{nameHeading}}} {{{ view.getRenderAttributeString( nameSettingKey ) }}}>
2551 {{{ person.multiple_name }}}
2552 </{{{nameHeading}}}>
2553 </a>
2554 <# } else { #>
2555 <{{{nameHeading}}} {{{ view.getRenderAttributeString( nameSettingKey ) }}}>
2556 {{{ person.multiple_name }}}
2557 </{{{nameHeading}}}>
2558 <# } #>
2559 <# }
2560
2561 if( 'style3' === skin ) { #>
2562 <div class="premium-person-title-desc-wrap">
2563 <# }
2564 if( '' != person.multiple_title ) { #>
2565 <{{{titleHeading}}} {{{ view.getRenderAttributeString( titleSettingKey ) }}}>
2566 <span>{{{ person.multiple_title }}}</span>
2567 </{{{titleHeading}}}>
2568 <# }
2569 if( '' != person.multiple_description ) { #>
2570 <div {{{ view.getRenderAttributeString( descSettingKey ) }}}>
2571 {{{ person.multiple_description }}}
2572 </div>
2573 <# }
2574 if( 'style3' === skin ) { #>
2575 </div>
2576 <# }
2577
2578 if( 'style3' === skin ) { #>
2579 <div class="premium-person-name-icons-wrap">
2580 <# if( '' != settings.premium_person_name ) { #>
2581 <# if ('' !== person.multiple_profile.url ) { #>
2582 <a {{{ view.getRenderAttributeString('premium_multiple_profile_' + index) }}}>
2583 <{{{nameHeading}}} {{{ view.getRenderAttributeString( nameSettingKey ) }}}>
2584 {{{ person.multiple_name }}}
2585 </{{{nameHeading}}}>
2586 </a>
2587 <# } else { #>
2588 <{{{nameHeading}}} {{{ view.getRenderAttributeString( nameSettingKey ) }}}>
2589 {{{ person.multiple_name }}}
2590 </{{{nameHeading}}}>
2591 <# } #>
2592 <# }
2593 if( 'yes' === person.multiple_social_enable ) {
2594 getSocialIcons( person );
2595 } #>
2596 </div>
2597 <# }
2598
2599 if ( 'style1' === settings.premium_person_style && 'yes' === person.multiple_social_enable ) {
2600 getSocialIcons( person );
2601 } #>
2602 </div>
2603 </div>
2604 </div>
2605 <# });
2606 } #>
2607
2608 </div>
2609 <?php
2610 }
2611 }
2612