PluginProbe
ShopBuilder – WooCommerce Builder For Elementor / 2.6.0
ShopBuilder – WooCommerce Builder For Elementor v2.6.0
3.4.2 3.4.1 3.4.0 2.0.1 2.0.2 2.0.3 2.1.0 2.1.1 2.1.10 2.1.11 2.1.12 2.1.13 2.1.14 2.1.15 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.1.9 2.2.0 2.2.1 2.2.2 All 63 releases
shopbuilder / app / Elementor / Helper / ControlHelper.php

ControlHelper.php in ShopBuilder – WooCommerce Builder For Elementor 2.6.0, at app/Elementor/Helper/ControlHelper.php

1,360 lines 50.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * BuilderFns class
4 *
5 * The builder.
6 *
7 * @package RadiusTheme\SB
8 * @since 1.0.0
9 */
10
11 namespace RadiusTheme\SB\Elementor\Helper;
12
13 // Do not allow directly accessing this file.
14 if ( ! defined( 'ABSPATH' ) ) {
15 exit( 'This script cannot be accessed directly.' );
16 }
17
18 /**
19 * BuilderFns class
20 */
21 class ControlHelper {
22 /**
23 * Widget alignment.
24 *
25 * @return array
26 */
27 public static function alignment() {
28 return [
29 'left' => [
30 'title' => esc_html__( 'Left', 'shopbuilder' ),
31 'icon' => 'eicon-text-align-left',
32 ],
33 'center' => [
34 'title' => esc_html__( 'Center', 'shopbuilder' ),
35 'icon' => 'eicon-text-align-center',
36 ],
37 'right' => [
38 'title' => esc_html__( 'Right', 'shopbuilder' ),
39 'icon' => 'eicon-text-align-right',
40 ],
41 'justify' => [
42 'title' => esc_html__( 'Justified', 'shopbuilder' ),
43 'icon' => 'eicon-text-align-justify',
44 ],
45 ];
46 }
47 /**
48 * Widget alignment.
49 *
50 * @return array
51 */
52 public static function flex_alignment() {
53 return [
54 'start' => [
55 'title' => esc_html__( 'Start', 'shopbuilder' ),
56 'icon' => 'eicon-text-align-left',
57 ],
58 'center' => [
59 'title' => esc_html__( 'Center', 'shopbuilder' ),
60 'icon' => 'eicon-text-align-center',
61 ],
62 'end' => [
63 'title' => esc_html__( 'End', 'shopbuilder' ),
64 'icon' => 'eicon-text-align-right',
65 ],
66 ];
67 }
68 /**
69 * Grid Layout Columns
70 *
71 * @return array
72 */
73 public static function layout_columns() {
74 return [
75 0 => esc_html__( 'Layout Default', 'shopbuilder' ),
76 1 => esc_html__( '1 Column', 'shopbuilder' ),
77 2 => esc_html__( '2 Columns', 'shopbuilder' ),
78 3 => esc_html__( '3 Columns', 'shopbuilder' ),
79 4 => esc_html__( '4 Columns', 'shopbuilder' ),
80 5 => esc_html__( '5 Columns', 'shopbuilder' ),
81 6 => esc_html__( '6 Columns', 'shopbuilder' ),
82 7 => esc_html__( '7 Columns', 'shopbuilder' ),
83 8 => esc_html__( '8 Columns', 'shopbuilder' ),
84 ];
85 }
86
87 /**
88 * Grid Layouts
89 *
90 * @return array
91 */
92 public static function grid_layouts() {
93 $status = ! rtsb()->has_pro();
94
95 return apply_filters(
96 'rtsb/elements/elementor/grid_layouts',
97 [
98 'grid-layout1' => [
99 'title' => esc_html__( 'Grid Layout 1', 'shopbuilder' ),
100 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-Layout-1.png' ) ),
101 ],
102
103 'grid-layout2' => [
104 'title' => esc_html__( 'Grid Layout 2', 'shopbuilder' ),
105 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-Layout-2.png' ) ),
106 ],
107
108 'grid-layout3' => [
109 'title' => esc_html__( 'Grid Layout 3', 'shopbuilder' ),
110 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-3.png' ) ),
111 'is_pro' => $status,
112 ],
113 'grid-layout4' => [
114 'title' => esc_html__( 'Grid Layout 4', 'shopbuilder' ),
115 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-4.png' ) ),
116 'is_pro' => $status,
117 ],
118 'grid-layout5' => [
119 'title' => esc_html__( 'Grid Layout 5', 'shopbuilder' ),
120 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-5.png' ) ),
121 'is_pro' => $status,
122 ],
123 'grid-layout6' => [
124 'title' => esc_html__( 'Grid Layout 6', 'shopbuilder' ),
125 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-6.png' ) ),
126 'is_pro' => $status,
127 ],
128 'grid-layout7' => [
129 'title' => esc_html__( 'Grid Layout 7', 'shopbuilder' ),
130 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-7.png' ) ),
131 'is_pro' => $status,
132 ],
133 'grid-layout8' => [
134 'title' => esc_html__( 'Grid Layout 8', 'shopbuilder' ),
135 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-8.png' ) ),
136 'is_pro' => $status,
137 ],
138 'grid-layout9' => [
139 'title' => esc_html__( 'Special Layout 1', 'shopbuilder' ),
140 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-9a.png' ) ),
141 'is_pro' => $status,
142 ],
143 ]
144 );
145 }
146
147 /**
148 * Single Product Tab Layouts
149 *
150 * @return array
151 */
152 public static function single_product_tab_layouts() {
153 $status = ! rtsb()->has_pro();
154
155 return apply_filters(
156 'rtsb/elements/elementor/single_product_tab_layouts',
157 [
158 'default' => [
159 'title' => esc_html__( 'Default Layout', 'shopbuilder' ),
160 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-01.png' ) ),
161 ],
162 'custom-layout1' => [
163 'title' => esc_html__( 'Accordion Layout', 'shopbuilder' ),
164 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-02.png' ) ),
165 'is_pro' => $status,
166 ],
167 'custom-layout2' => [
168 'title' => esc_html__( 'Tab Layout', 'shopbuilder' ),
169 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-03.png' ) ),
170 'is_pro' => $status,
171 ],
172 ]
173 );
174 }
175
176
177 /**
178 * General Widgets Advanced Title Layouts
179 *
180 * @return array
181 */
182 public static function general_widgets_advanced_title_layouts() {
183
184 return apply_filters(
185 'rtsb/elements/elementor/general_widgets_advanced_title_layouts',
186 [
187 'rtsb-advanced-heading-layout1' => [
188 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
189 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/advance-heading-layout-01.png' ) ),
190 ],
191 ]
192 );
193 }
194 /**
195 * General Widgets Advanced Title Layouts
196 *
197 * @return array
198 */
199 public static function general_widgets_button_layouts() {
200
201 return apply_filters(
202 'rtsb/elements/elementor/general_widgets_button_layouts',
203 [
204 'rtsb-sb-button-layout1' => [
205 'title' => esc_html__( 'Single Button', 'shopbuilder' ),
206 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/advanced-button-layout-01.png' ) ),
207 ],
208 'rtsb-sb-button-layout2' => [
209 'title' => esc_html__( 'Dual Button', 'shopbuilder' ),
210 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/advanced-button-layout-02.png' ) ),
211 ],
212 ]
213 );
214 }
215 /**
216 * General Widgets FlipBox Layouts
217 *
218 * @return array
219 */
220 public static function general_widgets_flip_box_layouts() {
221
222 return apply_filters(
223 'rtsb/elements/elementor/general_widgets_flip_box_layouts',
224 [
225 'rtsb-flip-box-layout1' => [
226 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
227 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/flip-box-layout-01.png' ) ),
228 ],
229 ]
230 );
231 }
232 /**
233 * General Widgets Counter Layouts
234 *
235 * @return array
236 */
237 public static function general_widgets_counter_layouts() {
238
239 return apply_filters(
240 'rtsb/elements/elementor/general_widgets_counter_layouts',
241 [
242 'rtsb-counter-layout1' => [
243 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
244 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/fun-facts-layout-01.png' ) ),
245 ],
246 'rtsb-counter-layout2' => [
247 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
248 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/fun-facts-layout-02.png' ) ),
249 ],
250
251 ]
252 );
253 }
254 /**
255 * General Widgets Countdown Layouts
256 *
257 * @return array
258 */
259 public static function general_widgets_countdown_layouts() {
260
261 return apply_filters(
262 'rtsb/elements/elementor/general_widgets_countdown_layouts',
263 [
264 'rtsb-countdown-layout1' => [
265 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
266 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-01.png' ) ),
267 ],
268 'rtsb-countdown-layout2' => [
269 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
270 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-02.png' ) ),
271 ],
272 'rtsb-countdown-layout3' => [
273 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
274 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-03.png' ) ),
275 ],
276 'rtsb-countdown-layout4' => [
277 'title' => esc_html__( 'Layout 4', 'shopbuilder' ),
278 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-04.png' ) ),
279 ],
280 'rtsb-countdown-layout5' => [
281 'title' => esc_html__( 'Layout 5', 'shopbuilder' ),
282 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-05.png' ) ),
283 ],
284 'rtsb-countdown-layout6' => [
285 'title' => esc_html__( 'Layout 6', 'shopbuilder' ),
286 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/countdown-layout-06.png' ) ),
287 ],
288 ]
289 );
290 }
291
292 /**
293 * General Widgets Progress Bar Layouts
294 *
295 * @return array
296 */
297 public static function general_widgets_progress_bar_layouts() {
298
299 return apply_filters(
300 'rtsb/elements/elementor/general_widgets_progress_bar_layouts',
301 [
302 'rtsb-progress-bar-layout1' => [
303 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
304 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/progressbar-layout-01.png' ) ),
305 ],
306 'rtsb-progress-bar-layout4' => [
307 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
308 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/progressbar-layout-02.png' ) ),
309 ],
310 'rtsb-progress-bar-layout5' => [
311 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
312 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/progressbar-layout-03.png' ) ),
313 ],
314 'rtsb-progress-bar-layout2' => [
315 'title' => esc_html__( 'Layout 4', 'shopbuilder' ),
316 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/progressbar-layout-04.png' ) ),
317 ],
318 'rtsb-progress-bar-layout3' => [
319 'title' => esc_html__( 'Layout 5', 'shopbuilder' ),
320 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/progressbar-layout-05.png' ) ),
321 ],
322 ]
323 );
324 }
325
326 /**
327 * General Widgets ShopBuilder Accordion Layouts
328 *
329 * @return array
330 */
331 public static function general_widgets_sb_faq_layouts() {
332
333 return apply_filters(
334 'rtsb/elements/elementor/general_widgets_sb_faq_layouts',
335 [
336 'rtsb-sb-faq-layout1' => [
337 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
338 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-01.png' ) ),
339 ],
340 'rtsb-sb-faq-layout3' => [
341 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
342 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-02.png' ) ),
343 ],
344 'rtsb-sb-faq-layout5' => [
345 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
346 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-03.png' ) ),
347 ],
348 'rtsb-sb-faq-layout2' => [
349 'title' => esc_html__( 'Layout 4', 'shopbuilder' ),
350 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-04.png' ) ),
351 ],
352 'rtsb-sb-faq-layout4' => [
353 'title' => esc_html__( 'Layout 5', 'shopbuilder' ),
354 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-05.png' ) ),
355 ],
356 'rtsb-sb-faq-layout6' => [
357 'title' => esc_html__( 'Layout 6', 'shopbuilder' ),
358 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/faqs-layout-06.png' ) ),
359 ],
360
361 ]
362 );
363 }
364 /**
365 * General Widgets Logo Slider And Grid Layouts
366 *
367 * @return array
368 */
369 public static function general_widgets_logo_slider_grid_layouts() {
370
371 return apply_filters(
372 'rtsb/elements/elementor/general_widgets_logo_slider_and_grid_layouts',
373 [
374 'rtsb-logo-layout1' => [
375 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
376 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/logo-slider-layout-01.png' ) ),
377 ],
378 'rtsb-logo-layout2' => [
379 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
380 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/logo-slider-layout-02.png' ) ),
381 ],
382 ]
383 );
384 }
385 /**
386 * General Widgets Logo Slider And Grid Layouts
387 *
388 * @return array
389 */
390 public static function general_widgets_testimonial() {
391
392 return apply_filters(
393 'rtsb/elements/elementor/general_widgets_testimonial_layouts',
394 [
395 'rtsb-testimonial-layout1' => [
396 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
397 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/testimonial-layout-01.png' ) ),
398 ],
399 'rtsb-testimonial-layout2' => [
400 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
401 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/testimonial-layout-02.png' ) ),
402 ],
403 'rtsb-testimonial-layout3' => [
404 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
405 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/testimonial-layout-03.png' ) ),
406 ],
407 'rtsb-testimonial-layout4' => [
408 'title' => esc_html__( 'Layout 4', 'shopbuilder' ),
409 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/testimonial-layout-04.png' ) ),
410 ],
411 'rtsb-testimonial-layout5' => [
412 'title' => esc_html__( 'Layout 5', 'shopbuilder' ),
413 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/testimonial-layout-05.png' ) ),
414 ],
415 ]
416 );
417 }
418 /**
419 * General Widgets Logo Slider And Grid Layouts
420 *
421 * @return array
422 */
423 public static function general_widgets_team_member() {
424
425 return apply_filters(
426 'rtsb/elements/elementor/general_widgets_team_member_layouts',
427 [
428 'rtsb-team-layout1' => [
429 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
430 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/team-layout-01.png' ) ),
431 ],
432 'rtsb-team-layout2' => [
433 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
434 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/team-layout-02.png' ) ),
435 ],
436 'rtsb-team-layout3' => [
437 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
438 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/team-layout-03.png' ) ),
439 ],
440 'rtsb-team-layout4' => [
441 'title' => esc_html__( 'Layout 4', 'shopbuilder' ),
442 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/team-layout-04.png' ) ),
443 ],
444 ]
445 );
446 }
447 /**
448 * General Widgets Post List Layouts
449 *
450 * @return array
451 */
452 public static function general_widgets_post_list() {
453
454 return apply_filters(
455 'rtsb/elements/elementor/general_widgets_post_lists_layouts',
456 [
457 'rtsb-post-list-layout1' => [
458 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
459 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/post-list-layout-01.png' ) ),
460 ],
461 'rtsb-post-list-layout2' => [
462 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
463 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/post-list-layout-02.png' ) ),
464 ],
465 ]
466 );
467 }
468 /**
469 * General Widgets Post Grid Layouts
470 *
471 * @return array
472 */
473 public static function general_widgets_post_grid() {
474
475 return apply_filters(
476 'rtsb/elements/elementor/general_widgets_post_grid_layouts',
477 [
478 'rtsb-post-grid-layout1' => [
479 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
480 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/post-grid-layout-01.png' ) ),
481 ],
482 'rtsb-post-grid-layout2' => [
483 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
484 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/post-grid-layout-02.png' ) ),
485 ],
486 'rtsb-post-grid-layout3' => [
487 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
488 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/post-grid-layout-03.png' ) ),
489 ],
490 ]
491 );
492 }
493
494 /**
495 * General Widgets ShopBuilder Accordion Layouts
496 *
497 * @return array
498 */
499 public static function general_widgets_image_accordion_layouts() {
500
501 return apply_filters(
502 'rtsb/elements/elementor/general_widgets_image_accordion_layouts',
503 [
504 'rtsb-image-accordion-layout1' => [
505 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
506 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/image-accordion-layout-01.png' ) ),
507 ],
508 'rtsb-image-accordion-layout2' => [
509 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
510 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/image-accordion-layout-02.png' ) ),
511 ],
512 ]
513 );
514 }
515
516
517 /**
518 * General Widgets FlipBox Widget Flip Direction
519 *
520 * @return array
521 */
522 public static function flip_box_widget_flip_direction() {
523
524 return apply_filters(
525 'rtsb/elements/elementor/general_widgets_flip_box_flip_direction',
526 [
527 'sb-flip-left' => esc_html__( 'Flip Left', 'shopbuilder' ),
528 'sb-flip-right' => esc_html__( 'Flip Right', 'shopbuilder' ),
529 'sb-flip-up' => esc_html__( 'Flip Up', 'shopbuilder' ),
530 'sb-flip-bottom' => esc_html__( 'Flip Bottom', 'shopbuilder' ),
531 'sb-flip-fade-in' => esc_html__( 'Fade In', 'shopbuilder' ),
532 'sb-flip-zoom-in' => esc_html__( 'Zoom In', 'shopbuilder' ),
533 'sb-flip-zoom-out' => esc_html__( 'Zoom Out', 'shopbuilder' ),
534 'sb-flip-3d-left' => esc_html__( 'Flip 3D Left', 'shopbuilder' ),
535 'sb-flip-3d-right' => esc_html__( 'Flip 3D Right', 'shopbuilder' ),
536 'sb-flip-3d-up' => esc_html__( 'Flip 3D Up', 'shopbuilder' ),
537 'sb-flip-3d-bottom' => esc_html__( 'Flip 3D Bottom', 'shopbuilder' ),
538 ]
539 );
540 }
541
542 /**
543 * General Widgets Button Hover Effects Layouts
544 *
545 * @return array
546 */
547 public static function general_widgets_button_hover_effect_preset() {
548
549 return apply_filters(
550 'rtsb/elements/elementor/general_widgets_button_hover_effects_preset',
551 [
552 'rtsb-sb-button-hover-effect-default' => [
553 'title' => esc_html__( 'Default Hover Effect', 'shopbuilder' ),
554 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/button-hover-effect-01.gif' ) ),
555 ],
556 'rtsb-sb-button-hover-effect-preset2' => [
557 'title' => esc_html__( 'Hover Effect 1', 'shopbuilder' ),
558 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/button-hover-effect-02.gif' ) ),
559 ],
560 'rtsb-sb-button-hover-effect-preset3' => [
561 'title' => esc_html__( 'Hover Effect 2', 'shopbuilder' ),
562 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/button-hover-effect-03.gif' ) ),
563 ],
564 ]
565 );
566 }
567 /**
568 * General Widgets Call To Action Layouts
569 *
570 * @return array
571 */
572 public static function general_widgets_cta_layouts() {
573
574 return apply_filters(
575 'rtsb/elements/elementor/general_widgets_cta_layouts',
576 [
577 'rtsb-cta-layout1' => [
578 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
579 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/call-to-action-layout-01.png' ) ),
580 ],
581 'rtsb-cta-layout2' => [
582 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
583 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/call-to-action-layout-02.png' ) ),
584 ],
585 'rtsb-cta-layout3' => [
586 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
587 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/call-to-action-layout-03.png' ) ),
588 ],
589 ]
590 );
591 }
592 /**
593 * General Widgets Info Box Layouts
594 *
595 * @return array
596 */
597 public static function general_widgets_info_box_layouts() {
598
599 return apply_filters(
600 'rtsb/elements/elementor/general_widgets_info_box_layouts',
601 [
602 'rtsb-info-box-layout1' => [
603 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
604 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/info-box-layout-01.png' ) ),
605 ],
606 'rtsb-info-box-layout3' => [
607 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
608 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/info-box-layout-02.png' ) ),
609 ],
610 'rtsb-info-box-layout4' => [
611 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
612 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/info-box-layout-03.png' ) ),
613 ],
614 ]
615 );
616 }
617 /**
618 * General Widgets Pricing Table Layouts
619 *
620 * @return array
621 */
622 public static function general_widgets_pricing_table_layouts() {
623
624 return apply_filters(
625 'rtsb/elements/elementor/general_widgets_pricing_table_layouts',
626 [
627 'rtsb-pricing-table-layout1' => [
628 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
629 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-table-layout-01.png' ) ),
630 ],
631 'rtsb-pricing-table-layout2' => [
632 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
633 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-table-layout-02.png' ) ),
634 ],
635 'rtsb-pricing-table-layout3' => [
636 'title' => esc_html__( 'Layout 3', 'shopbuilder' ),
637 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-table-layout-03.png' ) ),
638 ],
639 ]
640 );
641 }
642 /**
643 * General Widgets Pricing Table Badge Preset
644 *
645 * @return array
646 */
647 public static function general_widgets_pricing_table_badge_preset() {
648
649 return apply_filters(
650 'rtsb/elements/elementor/general_widgets_pricing_table_badge_preset',
651 [
652 'rtsb-pricing-table-badge-preset1' => [
653 'title' => esc_html__( 'Preset 1', 'shopbuilder' ),
654 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-badge-layout-01.png' ) ),
655 ],
656 'rtsb-pricing-table-badge-preset2' => [
657 'title' => esc_html__( 'Preset 2', 'shopbuilder' ),
658 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-badge-layout-02.png' ) ),
659 ],
660 'rtsb-pricing-table-badge-preset3' => [
661 'title' => esc_html__( 'Preset 3', 'shopbuilder' ),
662 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-badge-layout-03.png' ) ),
663 ],
664 'rtsb-pricing-table-badge-preset4' => [
665 'title' => esc_html__( 'Preset 4', 'shopbuilder' ),
666 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/pricing-badge-layout-04.png' ) ),
667 ],
668 ]
669 );
670 }
671 /**
672 * General Widgets Dropcaps Layouts
673 *
674 * @return array
675 */
676 public static function general_widgets_dropcaps_layouts() {
677
678 return apply_filters(
679 'rtsb/elements/elementor/general_widgets_dropcaps_layouts',
680 [
681 'rtsb-dropcaps-layout1' => [
682 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
683 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/dropcaps-layout-01.png' ) ),
684 ],
685 'rtsb-dropcaps-layout2' => [
686 'title' => esc_html__( 'Layout 2', 'shopbuilder' ),
687 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/dropcaps-layout-02.png' ) ),
688 ],
689 ]
690 );
691 }
692
693 /**
694 * Multi Step Checkout Layouts
695 *
696 * @return array
697 */
698 public static function multi_step_checkout_layouts() {
699 $status = ! rtsb()->has_pro();
700
701 return apply_filters(
702 'rtsb/elements/elementor/single_product_tab_layouts',
703 [
704 'layout1' => [
705 'title' => esc_html__( 'Layout 1', 'shopbuilder' ),
706 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-01.png' ) ),
707 ],
708
709 ]
710 );
711 }
712
713 /**
714 * Single Advanced Product Tab Layouts
715 *
716 * @return array
717 */
718 public static function single_advanced_product_tab_layouts() {
719 // TODO:: Check If the FUnction Used Or Not.
720 return apply_filters(
721 'rtsb/elements/elementor/single_advanced_product_tab_layouts',
722 [
723 'default' => [
724 'title' => esc_html__( 'Default Layout', 'shopbuilder' ),
725 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-01.png' ) ),
726 ],
727 'custom-layout1' => [
728 'title' => esc_html__( 'Accordion Layout', 'shopbuilder' ),
729 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-02.png' ) ),
730 ],
731 'custom-layout2' => [
732 'title' => esc_html__( 'Tab Layout', 'shopbuilder' ),
733 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/tab-03.png' ) ),
734 ],
735 ]
736 );
737 }
738
739 /**
740 * Slider Layouts
741 *
742 * @return array
743 */
744 public static function slider_layouts() {
745 $status = ! rtsb()->has_pro();
746
747 return apply_filters(
748 'rtsb/elements/elementor/slider_layouts',
749 [
750 'slider-layout1' => [
751 'title' => esc_html__( 'Slider Layout 1', 'shopbuilder' ),
752 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-Layout-1.png' ) ),
753 ],
754
755 'slider-layout2' => [
756 'title' => esc_html__( 'Slider Layout 2', 'shopbuilder' ),
757 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-Layout-2.png' ) ),
758 ],
759
760 'slider-layout3' => [
761 'title' => esc_html__( 'Slider Layout 3', 'shopbuilder' ),
762 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/slider-style-3.png' ) ),
763 'is_pro' => $status,
764 ],
765
766 'slider-layout4' => [
767 'title' => esc_html__( 'Slider Layout 4', 'shopbuilder' ),
768 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/slider-style-4.png' ) ),
769 'is_pro' => $status,
770 ],
771 'slider-layout5' => [
772 'title' => esc_html__( 'Slider Layout 5', 'shopbuilder' ),
773 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/slider-style-5.png' ) ),
774 'is_pro' => $status,
775 ],
776 'slider-layout6' => [
777 'title' => esc_html__( 'Slider Layout 6', 'shopbuilder' ),
778 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/slider-style-6.png' ) ),
779 'is_pro' => $status,
780 ],
781 'slider-layout7' => [
782 'title' => esc_html__( 'Slider Layout 7', 'shopbuilder' ),
783 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/slider-style-7.png' ) ),
784 'is_pro' => $status,
785 ],
786 'slider-layout8' => [
787 'title' => esc_html__( 'Slider Layout 8', 'shopbuilder' ),
788 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-6.png' ) ),
789 'is_pro' => $status,
790 ],
791 'slider-layout9' => [
792 'title' => esc_html__( 'Slider Layout 9', 'shopbuilder' ),
793 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/grid-style-8.png' ) ),
794 'is_pro' => $status,
795 ],
796 ]
797 );
798 }
799
800 /**
801 * List Layouts
802 *
803 * @return array
804 */
805 public static function list_layouts() {
806 $status = ! rtsb()->has_pro();
807
808 return apply_filters(
809 'rtsb/elements/elementor/list_layouts',
810 [
811 'list-layout1' => [
812 'title' => esc_html__( 'List Layout 1', 'shopbuilder' ),
813 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-Layout-1.png' ) ),
814 ],
815 'list-layout2' => [
816 'title' => esc_html__( 'List Layout 2', 'shopbuilder' ),
817 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-Layout-2.png' ) ),
818 ],
819 'list-layout3' => [
820 'title' => esc_html__( 'List Layout 3', 'shopbuilder' ),
821 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-3.png' ) ),
822 'is_pro' => $status,
823 ],
824 'list-layout4' => [
825 'title' => esc_html__( 'List Layout 4', 'shopbuilder' ),
826 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-4.png' ) ),
827 'is_pro' => $status,
828 ],
829 'list-layout5' => [
830 'title' => esc_html__( 'List Layout 5', 'shopbuilder' ),
831 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-5.png' ) ),
832 'is_pro' => $status,
833 ],
834 'list-layout6' => [
835 'title' => esc_html__( 'List Layout 6', 'shopbuilder' ),
836 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-6.png' ) ),
837 'is_pro' => $status,
838 ],
839 'list-layout7' => [
840 'title' => esc_html__( 'List Layout 7', 'shopbuilder' ),
841 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/list-style-7.png' ) ),
842 'is_pro' => $status,
843 ],
844 ]
845 );
846 }
847
848 /**
849 * Category Layouts
850 *
851 * @return array
852 */
853 public static function category_layouts() {
854 $status = ! rtsb()->has_pro();
855
856 return apply_filters(
857 'rtsb/elements/elementor/category_layouts',
858 [
859 'category-layout1' => [
860 'title' => esc_html__( 'Category Layout 1', 'shopbuilder' ),
861 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/categories-1.png' ) ),
862 ],
863
864 'category-layout2' => [
865 'title' => esc_html__( 'Category Layout 2', 'shopbuilder' ),
866 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/categories-2.png' ) ),
867 ],
868 'category-layout3' => [
869 'title' => esc_html__( 'Category Layout 3', 'shopbuilder' ),
870 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/categories-3.png' ) ),
871 'is_pro' => $status,
872 ],
873 'category-layout4' => [
874 'title' => esc_html__( 'Category Layout 4', 'shopbuilder' ),
875 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/categories-3.png' ) ),
876 'is_pro' => $status,
877 ],
878
879 ]
880 );
881 }
882
883 /**
884 * Category Layouts
885 *
886 * @return array
887 */
888 public static function share_layouts() {
889 $status = ! rtsb()->has_pro();
890
891 return apply_filters(
892 'rtsb/elements/elementor/share_layouts',
893 [
894 'share-layout1' => [
895 'title' => esc_html__( 'Social Share Preset 1', 'shopbuilder' ),
896 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/share-preset-1.png' ) ),
897 ],
898
899 'share-layout2' => [
900 'title' => esc_html__( 'Social Share Preset 2', 'shopbuilder' ),
901 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/share-preset-2.png' ) ),
902 ],
903
904 // TODO: Will be activated later.
905 // 'share-layout3' => [
906 // 'title' => esc_html__( 'Social Share Preset 3', 'shopbuilder' ),
907 // 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/share-preset-1.png' ) ),
908 // 'is_pro' => $status,
909 // ],
910 ]
911 );
912 }
913
914 /**
915 * Action Button Presets
916 *
917 * @return array
918 */
919 public static function action_btn_presets() {
920
921 return apply_filters(
922 'rtsb/elements/elementor/action_btn_presets',
923 [
924 'preset1' => [
925 'title' => esc_html__( 'Preset 1', 'shopbuilder' ),
926 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-1.jpg' ) ),
927 ],
928
929 'preset2' => [
930 'title' => esc_html__( 'Preset 2', 'shopbuilder' ),
931 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-2.jpg' ) ),
932 ],
933
934 'preset3' => [
935 'title' => esc_html__( 'Preset 3', 'shopbuilder' ),
936 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-3.jpg' ) ),
937 ],
938 'preset4' => [
939 'title' => esc_html__( 'Preset 4', 'shopbuilder' ),
940 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-4.jpg' ) ),
941 ],
942 'preset5' => [
943 'title' => esc_html__( 'Preset 5', 'shopbuilder' ),
944 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-5.jpg' ) ),
945 'is_pro' => ! rtsb()->has_pro(),
946 ],
947 'preset6' => [
948 'title' => esc_html__( 'Preset 6', 'shopbuilder' ),
949 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/action-preset-6.jpg' ) ),
950 'is_pro' => ! rtsb()->has_pro(),
951 ],
952 ]
953 );
954 }
955
956 /**
957 * Badge Presets
958 *
959 * @return array
960 */
961 public static function badge_presets() {
962 $status = ! rtsb()->has_pro();
963
964 return apply_filters(
965 'rtsb/elements/elementor/badge_presets',
966 [
967 'preset1' => [
968 'title' => esc_html__( 'Preset 1', 'shopbuilder' ),
969 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/badge-preset-1.png' ) ),
970 ],
971
972 'preset2' => [
973 'title' => esc_html__( 'Preset 2', 'shopbuilder' ),
974 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/badge-preset-2.png' ) ),
975 ],
976
977 'preset3' => [
978 'title' => esc_html__( 'Preset 3', 'shopbuilder' ),
979 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/badge-preset-3.png' ) ),
980 ],
981
982 'preset4' => [
983 'title' => esc_html__( 'Preset 4', 'shopbuilder' ),
984 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/badge-preset-4.png' ) ),
985 ],
986 ]
987 );
988 }
989
990 /**
991 * Single Category Layouts
992 *
993 * @return array
994 */
995 public static function single_category_layouts() {
996 $status = ! rtsb()->has_pro();
997
998 return apply_filters(
999 'rtsb/elements/elementor/category_single_layouts',
1000 [
1001 'category-single-layout1' => [
1002 'title' => esc_html__( 'Single Category Layout 1', 'shopbuilder' ),
1003 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/single-category-1.png' ) ),
1004 ],
1005
1006 'category-single-layout2' => [
1007 'title' => esc_html__( 'Single Category Layout 2', 'shopbuilder' ),
1008 'url' => esc_url( rtsb()->get_assets_uri( 'images/layout/single-category-2.png' ) ),
1009 'is_pro' => $status,
1010 ],
1011 ]
1012 );
1013 }
1014
1015 /**
1016 * Posts Order By.
1017 *
1018 * @return array
1019 */
1020 public static function posts_order_by() {
1021 return [
1022 'ID' => esc_html__( 'Product ID', 'shopbuilder' ),
1023 'title' => esc_html__( 'Product Title', 'shopbuilder' ),
1024 'price' => esc_html__( 'Product Price', 'shopbuilder' ),
1025 'date' => esc_html__( 'Date', 'shopbuilder' ),
1026 'menu_order' => esc_html__( 'Menu Order', 'shopbuilder' ),
1027 'rand' => esc_html__( 'Random', 'shopbuilder' ),
1028 ];
1029 }
1030
1031 /**
1032 * Categories Order By.
1033 *
1034 * @return array
1035 */
1036 public static function cats_order_by() {
1037 return [
1038 'id' => esc_html__( 'Category IDs', 'shopbuilder' ),
1039 'name' => esc_html__( 'Category Name', 'shopbuilder' ),
1040 'count' => esc_html__( 'Product Count', 'shopbuilder' ),
1041 'menu_order' => esc_html__( 'Menu Order', 'shopbuilder' ),
1042 ];
1043 }
1044
1045 /**
1046 * Posts Order By.
1047 *
1048 * @return array
1049 */
1050 public static function posts_order() {
1051 return [
1052 'ASC' => esc_html__( 'Ascending', 'shopbuilder' ),
1053 'DESC' => esc_html__( 'Descending', 'shopbuilder' ),
1054 ];
1055 }
1056
1057 /**
1058 * Filter products
1059 *
1060 * @return array
1061 */
1062 public static function filter_products() {
1063 return [
1064 'recent' => esc_html__( 'Default', 'shopbuilder' ),
1065 'featured' => esc_html__( 'Featured Products', 'shopbuilder' ),
1066 'best-selling' => esc_html__( 'Best Selling Products', 'shopbuilder' ),
1067 'sale' => esc_html__( 'On Sale Products', 'shopbuilder' ),
1068 'top-rated' => esc_html__( 'Top Rated Products', 'shopbuilder' ),
1069 'recently-viewed' => esc_html__( 'Recently Viewed Products', 'shopbuilder' ),
1070 ];
1071 }
1072
1073 /**
1074 * Pagination options
1075 *
1076 * @return array
1077 */
1078 public static function pagination_options() {
1079 return apply_filters(
1080 'rtsb/elementor/pagination_options',
1081 [
1082 'pagination' => esc_html__( 'Number Pagination', 'shopbuilder' ),
1083 ]
1084 );
1085 }
1086
1087 /**
1088 * Heading Tags
1089 *
1090 * @return array
1091 */
1092 public static function heading_tags() {
1093 return [
1094 'h1' => esc_html__( 'H1', 'shopbuilder' ),
1095 'h2' => esc_html__( 'H2', 'shopbuilder' ),
1096 'h3' => esc_html__( 'H3', 'shopbuilder' ),
1097 'h4' => esc_html__( 'H4', 'shopbuilder' ),
1098 'h5' => esc_html__( 'H5', 'shopbuilder' ),
1099 'h6' => esc_html__( 'H6', 'shopbuilder' ),
1100 'p' => esc_html__( 'p', 'shopbuilder' ),
1101 'div' => esc_html__( 'div', 'shopbuilder' ),
1102 'span' => esc_html__( 'span', 'shopbuilder' ),
1103 ];
1104 }
1105
1106 /**
1107 * General Style Section
1108 *
1109 * @param string $id_prefix Section id prefix.
1110 * @param string $title Section title.
1111 * @param object $obj Reference object.
1112 * @param array $condition Condition.
1113 * @param array $selectors CSS electors.
1114 * @param array $conditions Conditions.
1115 *
1116 * @return array
1117 */
1118 public static function general_elementor_style( $id_prefix, $title, $obj, $condition, $selectors, $conditions = [] ) {
1119 $prefix = str_replace( ' ', '_', strtolower( $id_prefix ) ) . '_';
1120
1121 $fields[ $prefix . 'style_section' ] = $obj->start_section(
1122 esc_html( $title ),
1123 'style',
1124 $conditions,
1125 $condition
1126 );
1127
1128 $fields[ $prefix . 'typo_note' ] = $obj->el_heading( esc_html__( 'Typography', 'shopbuilder' ), 'default' );
1129
1130 $fields[ 'rtsb_el_' . $prefix . 'typography' ] = [
1131 'mode' => 'group',
1132 'type' => 'typography',
1133 'selector' => ! empty( $selectors['typography'] ) ? $selectors['typography'] : [],
1134 ];
1135
1136 $fields[ $prefix . 'alignment' ] = [
1137 'mode' => 'responsive',
1138 'type' => 'choose',
1139 'label' => esc_html__( 'Alignment', 'shopbuilder' ),
1140 'options' => [
1141 'left' => [
1142 'title' => esc_html__( 'Left', 'shopbuilder' ),
1143 'icon' => 'eicon-text-align-left',
1144 ],
1145 'center' => [
1146 'title' => esc_html__( 'Center', 'shopbuilder' ),
1147 'icon' => 'eicon-text-align-center',
1148 ],
1149 'right' => [
1150 'title' => esc_html__( 'Right', 'shopbuilder' ),
1151 'icon' => 'eicon-text-align-right',
1152 ],
1153 ],
1154 'selectors' => ! empty( $selectors['alignment'] ) ? $selectors['alignment'] : [],
1155 ];
1156
1157 $fields[ $prefix . 'color_note' ] = $obj->el_heading( esc_html__( 'Colors', 'shopbuilder' ), 'before' );
1158
1159 $fields[ $prefix . 'color_tabs' ] = $obj->start_tab_group();
1160 $fields[ $prefix . 'color_tab' ] = $obj->start_tab( esc_html__( 'Normal', 'shopbuilder' ) );
1161
1162 $fields[ $prefix . 'color' ] = [
1163 'type' => 'color',
1164 'label' => esc_html__( 'Color', 'shopbuilder' ),
1165 'selectors' => ! empty( $selectors['color'] ) ? $selectors['color'] : [],
1166 'separator' => 'default',
1167 ];
1168
1169 $fields[ $prefix . 'bg_color' ] = [
1170 'type' => 'color',
1171 'label' => esc_html__( 'Background Color', 'shopbuilder' ),
1172 'selectors' => ! empty( $selectors['bg_color'] ) ? $selectors['bg_color'] : [],
1173 'separator' => 'default',
1174 ];
1175
1176 $fields[ $prefix . 'color_tab_end' ] = $obj->end_tab();
1177 $fields[ $prefix . 'hover_color_tab' ] = $obj->start_tab( esc_html__( 'Hover', 'shopbuilder' ) );
1178
1179 $fields[ $prefix . 'hover_color' ] = [
1180 'type' => 'color',
1181 'label' => esc_html__( 'Hover Color', 'shopbuilder' ),
1182 'selectors' => ! empty( $selectors['hover_color'] ) ? $selectors['hover_color'] : [],
1183 'separator' => 'default',
1184 ];
1185
1186 $fields[ $prefix . 'hover_bg_color' ] = [
1187 'type' => 'color',
1188 'label' => esc_html__( 'Hover Background Color', 'shopbuilder' ),
1189 'selectors' => ! empty( $selectors['hover_bg_color'] ) ? $selectors['hover_bg_color'] : [],
1190 'separator' => 'default',
1191 ];
1192
1193 $fields[ $prefix . 'hover_color_tab_end' ] = $obj->end_tab();
1194 $fields[ $prefix . 'color_tabs_end' ] = $obj->end_tab_group();
1195
1196 $fields[ $prefix . 'border_note' ] = $obj->el_heading( esc_html__( 'Border', 'shopbuilder' ), 'before' );
1197
1198 $fields[ 'rtsb_el_' . $prefix . 'border' ] = [
1199 'mode' => 'group',
1200 'type' => 'border',
1201 'label' => esc_html__( 'Border', 'shopbuilder' ),
1202 'selector' => ! empty( $selectors['border'] ) ? $selectors['border'] : [],
1203 'fields_options' => [
1204 'color' => [
1205 'label' => esc_html__( 'Border Color', 'shopbuilder' ),
1206 ],
1207 ],
1208 'separator' => 'default',
1209 ];
1210
1211 $fields[ $prefix . 'border_hover_color' ] = [
1212 'type' => 'color',
1213 'label' => esc_html__( 'Hover Border Color', 'shopbuilder' ),
1214 'condition' => [ 'rtsb_el_' . $prefix . 'border_border!' => [ '' ] ],
1215 'selectors' => ! empty( $selectors['border_hover_color'] ) ? $selectors['border_hover_color'] : [],
1216 'separator' => 'default',
1217 ];
1218
1219 $fields[ $prefix . 'spacing_note' ] = $obj->el_heading( esc_html__( 'Spacing', 'shopbuilder' ), 'before' );
1220
1221 $fields[ $prefix . 'padding' ] = [
1222 'mode' => 'responsive',
1223 'type' => 'dimensions',
1224 'label' => esc_html__( 'Padding', 'shopbuilder' ),
1225 'size_units' => [ 'px', '%', 'em' ],
1226 'selectors' => ! empty( $selectors['padding'] ) ? $selectors['padding'] : [],
1227 'separator' => 'default',
1228 ];
1229
1230 $fields[ $prefix . 'margin' ] = [
1231 'mode' => 'responsive',
1232 'type' => 'dimensions',
1233 'label' => esc_html__( 'Margin', 'shopbuilder' ),
1234 'size_units' => [ 'px', '%', 'em' ],
1235 'selectors' => ! empty( $selectors['margin'] ) ? $selectors['margin'] : [],
1236 ];
1237
1238 $fields[ $prefix . 'style_section_end' ] = $obj->end_section();
1239
1240 return $fields;
1241 }
1242
1243 /**
1244 * Sharing Settings.
1245 *
1246 * @return array
1247 */
1248 public static function sharing_settings() {
1249 $settings = get_option( 'rtsb_settings' );
1250 $share_settings = ! empty( $settings['general']['social_share']['share_platforms'] ) ? $settings['general']['social_share']['share_platforms'] : [];
1251
1252 return ! empty( $share_settings ) && is_array( $share_settings ) ? $share_settings : [ 'facebook', 'twitter' ];
1253 }
1254 /**
1255 * General Widgets Social Media List
1256 *
1257 * @return array
1258 */
1259 public static function social_media_field() {
1260 $social_media_lists = self::social_media_profile_list();
1261 $fields = [];
1262 foreach ( $social_media_lists as $key => $social_media_list ) {
1263 $fields[ $key . '_url' ] = [
1264 'label' => $social_media_list['name'],
1265 'type' => 'url',
1266 'label_block' => true,
1267 ];
1268 switch ( $key ) {
1269 case 'facebook':
1270 $fields[ $key . '_url' ]['default'] = [
1271 'url' => 'https://www.facebook.com/',
1272 'is_external' => true,
1273 'nofollow' => true,
1274 ];
1275 break;
1276 case 'twitter':
1277 $fields[ $key . '_url' ]['default'] = [
1278 'url' => 'https://www.x.com/',
1279 'is_external' => true,
1280 'nofollow' => true,
1281 ];
1282 break;
1283 case 'youtube':
1284 $fields[ $key . '_url' ]['default'] = [
1285 'url' => 'https://www.youtube.com/',
1286 'is_external' => true,
1287 'nofollow' => true,
1288 ];
1289 break;
1290 default:
1291 break;
1292 }
1293 }
1294 return $fields;
1295 }
1296 /**
1297 * General Widgets Social Media Profile List
1298 *
1299 * @return array
1300 */
1301 public static function social_media_profile_list() {
1302 return apply_filters(
1303 'rtsb/general/widgets/social_media_lists',
1304 [
1305 'facebook' => [
1306 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" width="18" height="20" viewBox="0 0 602 1024"><path d="M548 6.857v150.857h-89.714q-49.143 0-66.286 20.571t-17.143 61.714v108h167.429l-22.286 169.143h-145.143v433.714h-174.857v-433.714h-145.714v-169.143h145.714v-124.571q0-106.286 59.429-164.857t158.286-58.571q84 0 130.286 6.857z"></path></svg>',
1307 'name' => esc_html__( 'Facebook', 'shopbuilder' ),
1308 ],
1309 'twitter' => [
1310 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" width="20" height="20"><path d="M389.2 48h70.6L305.6 224.2 487 464H345L233.7 318.6 106.5 464H35.8L200.7 275.5 26.8 48H172.4L272.9 180.9 389.2 48zM364.4 421.8h39.1L151.1 88h-42L364.4 421.8z"/></svg>',
1311 'name' => esc_html__( 'Twitter', 'shopbuilder' ),
1312 ],
1313 'linkedin' => [
1314 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 878 1024"><path d="M199.429 357.143v566.286h-188.571v-566.286h188.571zM211.429 182.286q0.571 41.714-28.857 69.714t-77.429 28h-1.143q-46.857 0-75.429-28t-28.571-69.714q0-42.286 29.429-70t76.857-27.714 76 27.714 29.143 70zM877.714 598.857v324.571h-188v-302.857q0-60-23.143-94t-72.286-34q-36 0-60.286 19.714t-36.286 48.857q-6.286 17.143-6.286 46.286v316h-188q1.143-228 1.143-369.714t-0.571-169.143l-0.571-27.429h188v82.286h-1.143q11.429-18.286 23.429-32t32.286-29.714 49.714-24.857 65.429-8.857q97.714 0 157.143 64.857t59.429 190z"></path></svg>',
1315 'name' => esc_html__( 'Linkedin', 'shopbuilder' ),
1316 ],
1317 'instagram' => [
1318 'icon' => '<svg viewBox="0 0 448 512" xmlns="http://www.w3.org/2000/svg" width="20" height="20">
1319 <path d="M224.1 141c-63.6 0-114.9 51.3-114.9 114.9s51.3 114.9 114.9 114.9S339 319.5 339 255.9 287.7 141 224.1 141zm0 189.6c-41.1 0-74.7-33.5-74.7-74.7s33.5-74.7 74.7-74.7 74.7 33.5 74.7 74.7-33.6 74.7-74.7 74.7zm146.4-194.3c0 14.9-12 26.8-26.8 26.8-14.9 0-26.8-12-26.8-26.8s12-26.8 26.8-26.8 26.8 12 26.8 26.8zm76.1 27.2c-1.7-35.9-9.9-67.7-36.2-93.9-26.2-26.2-58-34.4-93.9-36.2-37-2.1-147.9-2.1-184.9 0-35.8 1.7-67.6 9.9-93.9 36.1s-34.4 58-36.2 93.9c-2.1 37-2.1 147.9 0 184.9 1.7 35.9 9.9 67.7 36.2 93.9s58 34.4 93.9 36.2c37 2.1 147.9 2.1 184.9 0 35.9-1.7 67.7-9.9 93.9-36.2 26.2-26.2 34.4-58 36.2-93.9 2.1-37 2.1-147.8 0-184.8zM398.8 388c-7.8 19.6-22.9 34.7-42.6 42.6-29.5 11.7-99.5 9-132.1 9s-102.7 2.6-132.1-9c-19.6-7.8-34.7-22.9-42.6-42.6-11.7-29.5-9-99.5-9-132.1s-2.6-102.7 9-132.1c7.8-19.6 22.9-34.7 42.6-42.6 29.5-11.7 99.5-9 132.1-9s102.7-2.6 132.1 9c19.6 7.8 34.7 22.9 42.6 42.6 11.7 29.5 9 99.5 9 132.1s2.7 102.7-9 132.1z"/>
1320 </svg>',
1321 'name' => esc_html__( 'Instagram', 'shopbuilder' ),
1322 ],
1323 'tiktok' => [
1324 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" width="20" height="20"><path d="M448 209.9a210.1 210.1 0 0 1 -122.8-39.3V349.4A162.6 162.6 0 1 1 185 188.3V278.2a74.6 74.6 0 1 0 52.2 71.2V0l88 0a121.2 121.2 0 0 0 1.9 22.2h0A122.2 122.2 0 0 0 381 102.4a121.4 121.4 0 0 0 67 20.1z"/></svg>',
1325 'name' => esc_html__( 'Tiktok', 'shopbuilder' ),
1326 ],
1327 'youtube' => [
1328 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512" width="22" height="24"><path d="M549.7 124.1c-6.3-23.7-24.8-42.3-48.3-48.6C458.8 64 288 64 288 64S117.2 64 74.6 75.5c-23.5 6.3-42 24.9-48.3 48.6-11.4 42.9-11.4 132.3-11.4 132.3s0 89.4 11.4 132.3c6.3 23.7 24.8 41.5 48.3 47.8C117.2 448 288 448 288 448s170.8 0 213.4-11.5c23.5-6.3 42-24.2 48.3-47.8 11.4-42.9 11.4-132.3 11.4-132.3s0-89.4-11.4-132.3zm-317.5 213.5V175.2l142.7 81.2-142.7 81.2z"/></svg>',
1329 'name' => esc_html__( 'Youtube', 'shopbuilder' ),
1330 ],
1331 'skype' => [
1332 'icon' => '<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="24px" height="24px" viewBox="0 0 24 24" enable-background="new 0 0 24 24" xml:space="preserve" class="eapps-social-share-buttons-item-icon"> <path d="M23.016,13.971c0.111-0.638,0.173-1.293,0.173-1.963 c0-6.213-5.014-11.249-11.199-11.249c-0.704,0-1.393,0.068-2.061,0.193C8.939,0.348,7.779,0,6.536,0C2.926,0,0,2.939,0,6.565 c0,1.264,0.357,2.443,0.973,3.445c-0.116,0.649-0.18,1.316-0.18,1.999c0,6.212,5.014,11.25,11.198,11.25 c0.719,0,1.419-0.071,2.099-0.201C15.075,23.656,16.229,24,17.465,24C21.074,24,24,21.061,24,17.435 C24,16.163,23.639,14.976,23.016,13.971z M12.386,19.88c-3.19,0-6.395-1.453-6.378-3.953c0.005-0.754,0.565-1.446,1.312-1.446 c1.877,0,1.86,2.803,4.85,2.803c2.098,0,2.814-1.15,2.814-1.95c0-2.894-9.068-1.12-9.068-6.563c0-2.945,2.409-4.977,6.196-4.753 c3.61,0.213,5.727,1.808,5.932,3.299c0.102,0.973-0.543,1.731-1.662,1.731c-1.633,0-1.8-2.188-4.613-2.188 c-1.269,0-2.341,0.53-2.341,1.679c0,2.402,9.014,1.008,9.014,6.295C18.441,17.882,16.012,19.88,12.386,19.88z"></path> </svg>',
1333 'name' => esc_html__( 'Skype', 'shopbuilder' ),
1334 ],
1335 'behance' => [
1336 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" width="20" height="20"><path d="M155.3 318.4c17.2 0 31.2-6.1 31.2-25.4c0-19.7-11.7-27.4-30.3-27.5h-46v52.9h45.1zm-5.4-129.6H110.3v44.8H153c15.1 0 25.8-6.6 25.8-22.9c0-17.7-13.7-21.9-28.9-21.9zm129.5 74.8h62.2c-1.7-18.5-11.3-29.7-30.5-29.7c-18.3 0-30.5 11.4-31.7 29.7zM384 32H64C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H384c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64zM349.5 185H271.7V166.1h77.8V185zM193.7 243.7c23.6 6.7 35 27.5 35 51.6c0 39-32.7 55.7-67.6 55.9H68v-192h90.5c32.9 0 61.4 9.3 61.4 47.5c0 19.3-9 28.8-26.2 37zm118.7-38.6c43.5 0 67.6 34.3 67.6 75.4c0 1.6-.1 3.3-.2 5c0 .8-.1 1.5-.1 2.2H279.5c0 22.2 11.7 35.3 34.1 35.3c11.6 0 26.5-6.2 30.2-18.1h33.7c-10.4 31.9-31.9 46.8-65.1 46.8c-43.8 0-71.1-29.7-71.1-73c0-41.8 28.7-73.6 71.1-73.6z"/></svg>',
1337 'name' => esc_html__( 'Behance', 'shopbuilder' ),
1338 ],
1339 'pinterest' => [
1340 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 731 1024"><path d="M0 341.143q0-61.714 21.429-116.286t59.143-95.143 86.857-70.286 105.714-44.571 115.429-14.857q90.286 0 168 38t126.286 110.571 48.571 164q0 54.857-10.857 107.429t-34.286 101.143-57.143 85.429-82.857 58.857-108 22q-38.857 0-77.143-18.286t-54.857-50.286q-5.714 22.286-16 64.286t-13.429 54.286-11.714 40.571-14.857 40.571-18.286 35.714-26.286 44.286-35.429 49.429l-8 2.857-5.143-5.714q-8.571-89.714-8.571-107.429 0-52.571 12.286-118t38-164.286 29.714-116q-18.286-37.143-18.286-96.571 0-47.429 29.714-89.143t75.429-41.714q34.857 0 54.286 23.143t19.429 58.571q0 37.714-25.143 109.143t-25.143 106.857q0 36 25.714 59.714t62.286 23.714q31.429 0 58.286-14.286t44.857-38.857 32-54.286 21.714-63.143 11.429-63.429 3.714-56.857q0-98.857-62.571-154t-163.143-55.143q-114.286 0-190.857 74t-76.571 187.714q0 25.143 7.143 48.571t15.429 37.143 15.429 26 7.143 17.429q0 16-8.571 41.714t-21.143 25.714q-1.143 0-9.714-1.714-29.143-8.571-51.714-32t-34.857-54-18.571-61.714-6.286-60.857z"></path></svg>',
1341 'name' => esc_html__( 'Pinterest', 'shopbuilder' ),
1342 ],
1343 'whatsapp' => [
1344 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" fill="currentColor" class="bi bi-whatsapp" viewBox="0 0 16 16"> <path d="M13.601 2.326A7.854 7.854 0 0 0 7.994 0C3.627 0 .068 3.558.064 7.926c0 1.399.366 2.76 1.057 3.965L0 16l4.204-1.102a7.933 7.933 0 0 0 3.79.965h.004c4.368 0 7.926-3.558 7.93-7.93A7.898 7.898 0 0 0 13.6 2.326zM7.994 14.521a6.573 6.573 0 0 1-3.356-.92l-.24-.144-2.494.654.666-2.433-.156-.251a6.56 6.56 0 0 1-1.007-3.505c0-3.626 2.957-6.584 6.591-6.584a6.56 6.56 0 0 1 4.66 1.931 6.557 6.557 0 0 1 1.928 4.66c-.004 3.639-2.961 6.592-6.592 6.592zm3.615-4.934c-.197-.099-1.17-.578-1.353-.646-.182-.065-.315-.099-.445.099-.133.197-.513.646-.627.775-.114.133-.232.148-.43.05-.197-.1-.836-.308-1.592-.985-.59-.525-.985-1.175-1.103-1.372-.114-.198-.011-.304.088-.403.087-.088.197-.232.296-.346.1-.114.133-.198.198-.33.065-.134.034-.248-.015-.347-.05-.099-.445-1.076-.612-1.47-.16-.389-.323-.335-.445-.34-.114-.007-.247-.007-.38-.007a.729.729 0 0 0-.529.247c-.182.198-.691.677-.691 1.654 0 .977.71 1.916.81 2.049.098.133 1.394 2.132 3.383 2.992.47.205.84.326 1.129.418.475.152.904.129 1.246.08.38-.058 1.171-.48 1.338-.943.164-.464.164-.86.114-.943-.049-.084-.182-.133-.38-.232z"/> </svg>',
1345 'name' => esc_html__( 'Whatsapp', 'shopbuilder' ),
1346 ],
1347 'dribble' => [
1348 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" width="20" height="20"><path d="M86.6 64l85.2 85.2C194.5 121.7 208 86.4 208 48c0-14.7-2-28.9-5.7-42.4C158.6 15 119 35.5 86.6 64zM64 86.6C35.5 119 15 158.6 5.6 202.3C19.1 206 33.3 208 48 208c38.4 0 73.7-13.5 101.3-36.1L64 86.6zM256 0c-7.3 0-14.6 .3-21.8 .9C238 16 240 31.8 240 48c0 47.3-17.1 90.5-45.4 124L256 233.4 425.4 64C380.2 24.2 320.9 0 256 0zM48 240c-16.2 0-32-2-47.1-5.8C.3 241.4 0 248.7 0 256c0 64.9 24.2 124.2 64 169.4L233.4 256 172 194.6C138.5 222.9 95.3 240 48 240zm463.1 37.8c.6-7.2 .9-14.5 .9-21.8c0-64.9-24.2-124.2-64-169.4L278.6 256 340 317.4c33.4-28.3 76.7-45.4 124-45.4c16.2 0 32 2 47.1 5.8zm-4.7 31.9C492.9 306 478.7 304 464 304c-38.4 0-73.7 13.5-101.3 36.1L448 425.4c28.5-32.3 49.1-71.9 58.4-115.7zM340.1 362.7C317.5 390.3 304 425.6 304 464c0 14.7 2 28.9 5.7 42.4C353.4 497 393 476.5 425.4 448l-85.2-85.2zM317.4 340L256 278.6 86.6 448c45.1 39.8 104.4 64 169.4 64c7.3 0 14.6-.3 21.8-.9C274 496 272 480.2 272 464c0-47.3 17.1-90.5 45.4-124z"/></svg>',
1349 'name' => esc_html__( 'Dribble', 'shopbuilder' ),
1350 ],
1351 'reddit' => [
1352 'icon' => '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 512 512"><path d="M324,256a36,36,0,1,0,36,36A36,36,0,0,0,324,256Z"/><circle cx="188" cy="292" r="36" transform="translate(-97.43 94.17) rotate(-22.5)"/><path d="M496,253.77c0-31.19-25.14-56.56-56-56.56a55.72,55.72,0,0,0-35.61,12.86c-35-23.77-80.78-38.32-129.65-41.27l22-79L363.15,103c1.9,26.48,24,47.49,50.65,47.49,28,0,50.78-23,50.78-51.21S441,48,413,48c-19.53,0-36.31,11.19-44.85,28.77l-90-17.89L247.05,168.4l-4.63.13c-50.63,2.21-98.34,16.93-134.77,41.53A55.38,55.38,0,0,0,72,197.21c-30.89,0-56,25.37-56,56.56a56.43,56.43,0,0,0,28.11,49.06,98.65,98.65,0,0,0-.89,13.34c.11,39.74,22.49,77,63,105C146.36,448.77,199.51,464,256,464s109.76-15.23,149.83-42.89c40.53-28,62.85-65.27,62.85-105.06a109.32,109.32,0,0,0-.84-13.3A56.32,56.32,0,0,0,496,253.77ZM414,75a24,24,0,1,1-24,24A24,24,0,0,1,414,75ZM42.72,253.77a29.6,29.6,0,0,1,29.42-29.71,29,29,0,0,1,13.62,3.43c-15.5,14.41-26.93,30.41-34.07,47.68A30.23,30.23,0,0,1,42.72,253.77ZM390.82,399c-35.74,24.59-83.6,38.14-134.77,38.14S157,423.61,121.29,399c-33-22.79-51.24-52.26-51.24-83A78.5,78.5,0,0,1,75,288.72c5.68-15.74,16.16-30.48,31.15-43.79a155.17,155.17,0,0,1,14.76-11.53l.3-.21,0,0,.24-.17c35.72-24.52,83.52-38,134.61-38s98.9,13.51,134.62,38l.23.17.34.25A156.57,156.57,0,0,1,406,244.92c15,13.32,25.48,28.05,31.16,43.81a85.44,85.44,0,0,1,4.31,17.67,77.29,77.29,0,0,1,.6,9.65C442.06,346.77,423.86,376.24,390.82,399Zm69.6-123.92c-7.13-17.28-18.56-33.29-34.07-47.72A29.09,29.09,0,0,1,440,224a29.59,29.59,0,0,1,29.41,29.71A30.07,30.07,0,0,1,460.42,275.1Z"/><path d="M323.23,362.22c-.25.25-25.56,26.07-67.15,26.27-42-.2-66.28-25.23-67.31-26.27h0a4.14,4.14,0,0,0-5.83,0l-13.7,13.47a4.15,4.15,0,0,0,0,5.89h0c3.4,3.4,34.7,34.23,86.78,34.45,51.94-.22,83.38-31.05,86.78-34.45h0a4.16,4.16,0,0,0,0-5.9l-13.71-13.47a4.13,4.13,0,0,0-5.81,0Z"/></svg>',
1353 'name' => esc_html__( 'Reddit', 'shopbuilder' ),
1354 ],
1355
1356 ]
1357 );
1358 }
1359 }
1360