PluginProbe
Hello Plus / 1.4.0
Hello Plus v1.4.0
trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.1.2 1.1.3 1.2.0 1.2.1 1.3.0 1.4.0 1.4.1 1.5.0 1.5.1 1.5.2 1.5.3 1.6.0 1.6.1 1.6.2 1.7.0 1.7.1 1.7.2 1.7.3 All 30 releases
hello-plus / modules / content / widgets / flex-hero.php

flex-hero.php in Hello Plus 1.4.0, at modules/content/widgets/flex-hero.php

835 lines 19.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace HelloPlus\Modules\Content\Widgets;
4
5 if ( ! defined( 'ABSPATH' ) ) {
6 exit; // Exit if accessed directly.
7 }
8
9 use Elementor\Controls_Manager;
10 use Elementor\Group_Control_Background;
11 use Elementor\Group_Control_Box_Shadow;
12 use Elementor\Group_Control_Typography;
13 use Elementor\Widget_Base;
14 use Elementor\Core\Kits\Documents\Tabs\Global_Typography;
15 use Elementor\Core\Kits\Documents\Tabs\Global_Colors;
16
17 use HelloPlus\Modules\Content\Base\Traits\Shared_Content_Traits;
18 use HelloPlus\Modules\Content\Classes\Choose_Img_Control;
19 use HelloPlus\Modules\Content\Classes\Render\Widget_Flex_Hero_Render;
20 use HelloPlus\Modules\Theme\Module as Theme_Module;
21 use HelloPlus\Classes\{
22 Ehp_Button,
23 Ehp_Image,
24 Ehp_Padding,
25 Ehp_Shapes,
26 };
27 use HelloPlus\Includes\Utils;
28
29 class Flex_Hero extends Widget_Base {
30
31 use Shared_Content_Traits;
32
33 public function get_name(): string {
34 return 'flex-hero';
35 }
36
37 public function get_title(): string {
38 return esc_html__( 'Flex Hero', 'hello-plus' );
39 }
40
41 public function get_categories(): array {
42 return [ Theme_Module::HELLOPLUS_EDITOR_CATEGORY_SLUG ];
43 }
44
45 public function get_keywords(): array {
46 return [ 'flex-hero' ];
47 }
48
49 public function get_icon(): string {
50 return 'eicon-ehp-hero';
51 }
52
53 public function get_style_depends(): array {
54 return array_merge( [ 'helloplus-flex-hero' ], Utils::get_widgets_depends() );
55 }
56
57 protected function render(): void {
58 $render_strategy = new Widget_Flex_Hero_Render( $this );
59
60 $this->add_inline_editing_attributes( 'intro_text', 'basic' );
61 $this->add_inline_editing_attributes( 'heading_text', 'basic' );
62 $this->add_inline_editing_attributes( 'subheading_text', 'basic' );
63
64 $render_strategy->render();
65 }
66
67 protected function register_controls() {
68 $this->add_content_section();
69 $this->add_style_section();
70 }
71
72 protected function add_content_section() {
73 $this->add_content_layout_section();
74 $this->add_content_text_section();
75 $this->add_content_cta_section();
76 $this->add_content_image_section();
77 }
78
79 protected function add_style_section() {
80 $this->add_style_layout_section();
81 $this->add_style_content_section();
82 $this->add_style_cta_section();
83 $this->add_style_image_section();
84 $this->add_style_box_section();
85 }
86
87 protected function add_content_layout_section() {
88 $this->start_controls_section(
89 'content_layout',
90 [
91 'label' => esc_html__( 'Layout', 'hello-plus' ),
92 'tab' => Controls_Manager::TAB_CONTENT,
93 ]
94 );
95
96 $this->add_control(
97 'layout_preset',
98 [
99 'label' => esc_html__( 'Preset', 'hello-plus' ),
100 'type' => Choose_Img_Control::CONTROL_NAME,
101 'default' => 'showcase',
102 'label_block' => true,
103 'columns' => 2,
104 'options' => [
105 'showcase' => [
106 'title' => wp_kses_post( "Showcase:\nHighlight key concepts\nwith a balanced layout." ),
107 'image' => HELLOPLUS_IMAGES_URL . 'flex-hero-showcase.svg',
108 'hover_image' => true,
109 ],
110 'storytelling' => [
111 'title' => wp_kses_post( "Storytelling:\nFocus on a narrative\nwith supporting visuals." ),
112 'image' => HELLOPLUS_IMAGES_URL . 'flex-hero-storytelling.svg',
113 'hover_image' => true,
114 ],
115 ],
116 'frontend_available' => true,
117 ]
118 );
119
120 $this->end_controls_section();
121 }
122
123 protected function add_content_text_section() {
124 $this->start_controls_section(
125 'content_text',
126 [
127 'label' => esc_html__( 'Text', 'hello-plus' ),
128 'tab' => Controls_Manager::TAB_CONTENT,
129 ]
130 );
131
132 $this->add_control(
133 'intro_text',
134 [
135 'label' => esc_html__( 'Intro', 'hello-plus' ),
136 'type' => Controls_Manager::TEXTAREA,
137 'rows' => 6,
138 'default' => esc_html__( 'Start your journey', 'hello-plus' ),
139 'placeholder' => esc_html__( 'Type your description here', 'hello-plus' ),
140 'dynamic' => [
141 'active' => true,
142 ],
143 ]
144 );
145
146 $this->add_control(
147 'intro_tag',
148 [
149 'label' => esc_html__( 'HTML Tag', 'hello-plus' ),
150 'type' => Controls_Manager::SELECT,
151 'options' => [
152 'h1' => 'H1',
153 'h2' => 'H2',
154 'h3' => 'H3',
155 'h4' => 'H4',
156 'h5' => 'H5',
157 'h6' => 'H6',
158 'div' => 'div',
159 'span' => 'span',
160 'p' => 'p',
161 ],
162 'default' => 'p',
163 ]
164 );
165
166 $this->add_control(
167 'heading_text',
168 [
169 'label' => esc_html__( 'Heading', 'hello-plus' ),
170 'type' => Controls_Manager::TEXTAREA,
171 'rows' => 6,
172 'default' => esc_html__( 'Achieve your goals with a personal trainer who cares', 'hello-plus' ),
173 'placeholder' => esc_html__( 'Type your text here', 'hello-plus' ),
174 'dynamic' => [
175 'active' => true,
176 ],
177 ]
178 );
179
180 $this->add_control(
181 'heading_tag',
182 [
183 'label' => esc_html__( 'HTML Tag', 'hello-plus' ),
184 'type' => Controls_Manager::SELECT,
185 'options' => [
186 'h1' => 'H1',
187 'h2' => 'H2',
188 'h3' => 'H3',
189 'h4' => 'H4',
190 'h5' => 'H5',
191 'h6' => 'H6',
192 'div' => 'div',
193 'span' => 'span',
194 'p' => 'p',
195 ],
196 'default' => 'h2',
197 ]
198 );
199
200 $this->add_control(
201 'subheading_text',
202 [
203 'label' => esc_html__( 'Subheading', 'hello-plus' ),
204 'type' => Controls_Manager::TEXTAREA,
205 'rows' => 6,
206 'default' => esc_html__( 'Get customized workouts, expert guidance, and the motivation you need to feel your best.', 'hello-plus' ),
207 'placeholder' => esc_html__( 'Type your text here', 'hello-plus' ),
208 'dynamic' => [
209 'active' => true,
210 ],
211 ]
212 );
213
214 $this->add_control(
215 'subheading_tag',
216 [
217 'label' => esc_html__( 'HTML Tag', 'hello-plus' ),
218 'type' => Controls_Manager::SELECT,
219 'options' => [
220 'h2' => 'H2',
221 'h3' => 'H3',
222 'h4' => 'H4',
223 'h5' => 'H5',
224 'h6' => 'H6',
225 'div' => 'div',
226 'span' => 'span',
227 'p' => 'p',
228 ],
229 'default' => 'h3',
230 ]
231 );
232
233 $this->end_controls_section();
234 }
235
236 protected function add_content_cta_section() {
237 $defaults = [
238 'secondary_cta_show' => 'no',
239 ];
240 $button = new Ehp_Button( $this, [ 'widget_name' => $this->get_name() ], $defaults );
241 $button->add_content_section();
242 }
243
244 protected function add_content_image_section() {
245 $this->start_controls_section(
246 'content_image',
247 [
248 'label' => esc_html__( 'Image', 'hello-plus' ),
249 'tab' => Controls_Manager::TAB_CONTENT,
250 ]
251 );
252
253 $image = new Ehp_Image( $this, [ 'widget_name' => $this->get_name() ] );
254 $image->add_content_section();
255
256 $this->end_controls_section();
257 }
258
259 protected function add_style_layout_section() {
260 $this->start_controls_section(
261 'style_layout',
262 [
263 'label' => esc_html__( 'Layout', 'hello-plus' ),
264 'tab' => Controls_Manager::TAB_STYLE,
265 ]
266 );
267
268 $this->add_responsive_control(
269 'layout_image_position',
270 [
271 'label' => esc_html__( 'Image Position', 'hello-plus' ),
272 'type' => Controls_Manager::CHOOSE,
273 'default' => is_rtl() ? 'start' : 'end',
274 'options' => [
275 'start' => [
276 'title' => esc_html__( 'Start', 'hello-plus' ),
277 'icon' => 'eicon-h-align-' . ( is_rtl() ? 'right' : 'left' ),
278 ],
279 'end' => [
280 'title' => esc_html__( 'End', 'hello-plus' ),
281 'icon' => 'eicon-h-align-' . ( is_rtl() ? 'left' : 'right' ),
282 ],
283 ],
284 'condition' => [
285 'layout_preset' => 'showcase',
286 ],
287 'frontend_available' => true,
288 ]
289 );
290
291 $this->add_responsive_control(
292 'layout_content_position',
293 [
294 'label' => esc_html__( 'Content Position', 'hello-plus' ),
295 'type' => Controls_Manager::CHOOSE,
296 'options' => [
297 'flex-start' => [
298 'title' => esc_html__( 'Start', 'hello-plus' ),
299 'icon' => 'eicon-h-align-' . ( is_rtl() ? 'right' : 'left' ),
300 ],
301 'center' => [
302 'title' => esc_html__( 'Center', 'hello-plus' ),
303 'icon' => 'eicon-h-align-center',
304 ],
305 ],
306 'default' => 'center',
307 'tablet_default' => 'center',
308 'mobile_default' => 'center',
309 'selectors' => [
310 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-content-position: {{VALUE}};',
311 ],
312 'condition' => [
313 'layout_preset' => 'storytelling',
314 ],
315 ]
316 );
317
318 $this->add_control(
319 'layout_content_alignment',
320 [
321 'label' => esc_html__( 'Content Alignment', 'hello-plus' ),
322 'type' => Controls_Manager::CHOOSE,
323 'options' => [
324 'start' => [
325 'title' => esc_html__( 'Start', 'hello-plus' ),
326 'icon' => 'eicon-align-start-v',
327 ],
328 'center' => [
329 'title' => esc_html__( 'Center', 'hello-plus' ),
330 'icon' => 'eicon-align-center-v',
331 ],
332 'end' => [
333 'title' => esc_html__( 'End', 'hello-plus' ),
334 'icon' => 'eicon-align-end-v',
335 ],
336 ],
337 'default' => 'center',
338 'tablet_default' => 'center',
339 'mobile_default' => 'center',
340 'selectors' => [
341 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-content-alignment-showcase: {{VALUE}};',
342 ],
343 'condition' => [
344 'layout_preset' => 'showcase',
345 ],
346 ]
347 );
348
349 $this->add_responsive_control(
350 'layout_text_alignment',
351 [
352 'label' => esc_html__( 'Content Alignment', 'hello-plus' ),
353 'type' => Controls_Manager::CHOOSE,
354 'options' => [
355 'start' => [
356 'title' => esc_html__( 'Start', 'hello-plus' ),
357 'icon' => 'eicon-align-' . ( is_rtl() ? 'end' : 'start' ) . '-h',
358 ],
359 'center' => [
360 'title' => esc_html__( 'Center', 'hello-plus' ),
361 'icon' => 'eicon-align-center-h',
362 ],
363 ],
364 'default' => 'center',
365 'tablet_default' => 'center',
366 'mobile_default' => 'center',
367 'selectors' => [
368 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-content-alignment-storytelling: {{VALUE}};',
369 ],
370 'conditions' => [
371 'relation' => 'and',
372 'terms' => [
373 [
374 'name' => 'layout_preset',
375 'operator' => '==',
376 'value' => 'storytelling',
377 ],
378 [
379 'name' => 'layout_content_position',
380 'operator' => '==',
381 'value' => 'center',
382 ],
383 ],
384 ],
385 ]
386 );
387
388 $this->add_responsive_control(
389 'layout_content_width',
390 [
391 'label' => esc_html__( 'Content Width', 'hello-plus' ),
392 'type' => Controls_Manager::SLIDER,
393 'size_units' => [ 'px', 'em', 'rem', 'custom' ],
394 'range' => [
395 'px' => [
396 'max' => 1200,
397 ],
398 '%' => [
399 'max' => 100,
400 ],
401 ],
402 'default' => [
403 'size' => 648,
404 'unit' => 'px',
405 ],
406 'tablet_default' => [
407 'size' => 648,
408 'unit' => 'px',
409 ],
410 'mobile_default' => [
411 'size' => 648,
412 'unit' => 'px',
413 ],
414 'selectors' => [
415 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-content-width: {{SIZE}}{{UNIT}};',
416 ],
417 'condition' => [
418 'layout_preset' => 'storytelling',
419 ],
420 ]
421 );
422
423 $this->end_controls_section();
424 }
425
426 protected function add_style_content_section() {
427 $this->start_controls_section(
428 'style_content',
429 [
430 'label' => esc_html__( 'Content', 'hello-plus' ),
431 'tab' => Controls_Manager::TAB_STYLE,
432 ]
433 );
434
435 $this->add_control(
436 'intro_label',
437 [
438 'label' => esc_html__( 'Intro', 'hello-plus' ),
439 'type' => Controls_Manager::HEADING,
440 ]
441 );
442
443 $this->add_control(
444 'intro_color',
445 [
446 'label' => esc_html__( 'Text Color', 'hello-plus' ),
447 'type' => Controls_Manager::COLOR,
448 'global' => [
449 'default' => Global_Colors::COLOR_TEXT,
450 ],
451 'selectors' => [
452 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-intro-color: {{VALUE}}',
453 ],
454 ]
455 );
456
457 $this->add_group_control(
458 Group_Control_Typography::get_type(),
459 [
460 'name' => 'intro_typography',
461 'selector' => '{{WRAPPER}} .ehp-flex-hero__intro',
462 'global' => [
463 'default' => Global_Typography::TYPOGRAPHY_TEXT,
464 ],
465 ]
466 );
467
468 $this->add_control(
469 'heading_label',
470 [
471 'label' => esc_html__( 'Heading', 'hello-plus' ),
472 'type' => Controls_Manager::HEADING,
473 'separator' => 'before',
474 ]
475 );
476
477 $this->add_control(
478 'heading_color',
479 [
480 'label' => esc_html__( 'Text Color', 'hello-plus' ),
481 'type' => Controls_Manager::COLOR,
482 'global' => [
483 'default' => Global_Colors::COLOR_PRIMARY,
484 ],
485 'selectors' => [
486 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-heading-color: {{VALUE}}',
487 ],
488 ]
489 );
490
491 $this->add_group_control(
492 Group_Control_Typography::get_type(),
493 [
494 'name' => 'heading_typography',
495 'selector' => '{{WRAPPER}} .ehp-flex-hero__heading',
496 'global' => [
497 'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
498 ],
499 ]
500 );
501
502 $this->add_control(
503 'subheading_label',
504 [
505 'label' => esc_html__( 'Subheading', 'hello-plus' ),
506 'type' => Controls_Manager::HEADING,
507 'separator' => 'before',
508 ]
509 );
510
511 $this->add_control(
512 'subheading_color',
513 [
514 'label' => esc_html__( 'Text Color', 'hello-plus' ),
515 'type' => Controls_Manager::COLOR,
516 'global' => [
517 'default' => Global_Colors::COLOR_SECONDARY,
518 ],
519 'selectors' => [
520 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-subheading-color: {{VALUE}}',
521 ],
522 ]
523 );
524
525 $this->add_group_control(
526 Group_Control_Typography::get_type(),
527 [
528 'name' => 'subheading_typography',
529 'selector' => '{{WRAPPER}} .ehp-flex-hero__subheading',
530 'global' => [
531 'default' => Global_Typography::TYPOGRAPHY_SECONDARY,
532 ],
533 ]
534 );
535
536 $this->end_controls_section();
537 }
538
539 protected function add_style_cta_section() {
540 $this->start_controls_section(
541 'style_cta',
542 [
543 'label' => esc_html__( 'CTA Button', 'hello-plus' ),
544 'tab' => Controls_Manager::TAB_STYLE,
545 ]
546 );
547
548 $button = new Ehp_Button( $this, [ 'widget_name' => $this->get_name() ] );
549 $button->add_style_controls();
550
551 $this->end_controls_section();
552 }
553
554 protected function add_style_image_section() {
555 $this->start_controls_section(
556 'style_image_section',
557 [
558 'label' => esc_html__( 'Image', 'hello-plus' ),
559 'tab' => Controls_Manager::TAB_STYLE,
560 ]
561 );
562
563 $image = new Ehp_Image( $this, [ 'widget_name' => $this->get_name() ] );
564 $image->add_style_controls();
565
566 $this->end_controls_section();
567 }
568
569 protected function add_style_box_section() {
570 $this->start_controls_section(
571 'style_box_section',
572 [
573 'label' => esc_html__( 'Box', 'hello-plus' ),
574 'tab' => Controls_Manager::TAB_STYLE,
575 ]
576 );
577
578 $this->add_control(
579 'box_background_label',
580 [
581 'label' => esc_html__( 'Background', 'hello-plus' ),
582 'type' => Controls_Manager::HEADING,
583 ]
584 );
585
586 $this->add_group_control(
587 Group_Control_Background::get_type(),
588 [
589 'name' => 'background',
590 'types' => [ 'classic', 'gradient' ],
591 'selector' => '{{WRAPPER}} .ehp-flex-hero',
592 'fields_options' => [
593 'background' => [
594 'default' => 'classic',
595 ],
596 ],
597 ]
598 );
599
600 $this->add_control(
601 'box_background_overlay_label',
602 [
603 'label' => esc_html__( 'Background Overlay', 'hello-plus' ),
604 'type' => Controls_Manager::HEADING,
605 'separator' => 'before',
606 ]
607 );
608
609 $this->add_group_control(
610 Group_Control_Background::get_type(),
611 [
612 'name' => 'background_overlay',
613 'types' => [ 'classic', 'gradient' ],
614 'selector' => '{{WRAPPER}} .ehp-flex-hero__overlay',
615 'fields_options' => [
616 'background' => [
617 'default' => 'classic',
618 ],
619 ],
620 'frontend_available' => true,
621 ]
622 );
623
624 $this->add_responsive_control(
625 'background_overlay_opacity',
626 [
627 'label' => esc_html__( 'Opacity', 'hello-plus' ),
628 'type' => Controls_Manager::SLIDER,
629 'range' => [
630 '%' => [
631 'max' => 1,
632 'min' => 0.10,
633 'step' => 0.01,
634 ],
635 ],
636 'default' => [
637 'unit' => '%',
638 'size' => 0.5,
639 ],
640 'selectors' => [
641 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-overlay-opacity: {{SIZE}};',
642 ],
643 ]
644 );
645
646 $this->add_responsive_control(
647 'box_element_spacing',
648 [
649 'label' => esc_html__( 'Element Spacing', 'hello-plus' ),
650 'type' => Controls_Manager::SLIDER,
651 'size_units' => [ 'px', 'em', 'rem', 'custom' ],
652 'range' => [
653 'px' => [
654 'max' => 100,
655 ],
656 'em' => [
657 'max' => 5,
658 ],
659 'rem' => [
660 'max' => 5,
661 ],
662 '%' => [
663 'max' => 100,
664 ],
665 ],
666 'default' => [
667 'size' => 40,
668 'unit' => 'px',
669 ],
670 'tablet_default' => [
671 'size' => 28,
672 'unit' => 'px',
673 ],
674 'mobile_default' => [
675 'size' => 20,
676 'unit' => 'px',
677 ],
678 'selectors' => [
679 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-element-spacing: {{SIZE}}{{UNIT}};',
680 ],
681 'separator' => 'before',
682 ]
683 );
684
685 $this->add_responsive_control(
686 'box_gap',
687 [
688 'label' => esc_html__( 'Gap', 'hello-plus' ),
689 'type' => Controls_Manager::SLIDER,
690 'size_units' => [ 'px', 'em', 'rem', 'custom' ],
691 'range' => [
692 'px' => [
693 'max' => 100,
694 ],
695 'em' => [
696 'max' => 5,
697 ],
698 'rem' => [
699 'max' => 5,
700 ],
701 '%' => [
702 'max' => 100,
703 ],
704 ],
705 'default' => [
706 'size' => 60,
707 'unit' => 'px',
708 ],
709 'tablet_default' => [
710 'size' => 60,
711 'unit' => 'px',
712 ],
713 'mobile_default' => [
714 'size' => 60,
715 'unit' => 'px',
716 ],
717 'selectors' => [
718 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-gap: {{SIZE}}{{UNIT}};',
719 ],
720 'separator' => 'before',
721 ]
722 );
723
724 $this->add_control(
725 'show_box_border',
726 [
727 'label' => esc_html__( 'Border', 'hello-plus' ),
728 'type' => Controls_Manager::SWITCHER,
729 'label_on' => esc_html__( 'Yes', 'hello-plus' ),
730 'label_off' => esc_html__( 'No', 'hello-plus' ),
731 'return_value' => 'yes',
732 'default' => 'no',
733 'separator' => 'before',
734 ]
735 );
736
737 $this->add_control(
738 'box_border_width',
739 [
740 'label' => __( 'Border Width', 'hello-plus' ),
741 'type' => Controls_Manager::SLIDER,
742 'size_units' => [ 'px' ],
743 'range' => [
744 'px' => [
745 'min' => 0,
746 'max' => 10,
747 'step' => 1,
748 ],
749 ],
750 'default' => [
751 'size' => 1,
752 'unit' => 'px',
753 ],
754 'selectors' => [
755 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-box-border-width: {{SIZE}}{{UNIT}};',
756 ],
757 'condition' => [
758 'show_box_border' => 'yes',
759 ],
760 ]
761 );
762
763 $this->add_control(
764 'box_border_color',
765 [
766 'label' => esc_html__( 'Color', 'hello-plus' ),
767 'type' => Controls_Manager::COLOR,
768 'global' => [
769 'default' => Global_Colors::COLOR_TEXT,
770 ],
771 'selectors' => [
772 '{{WRAPPER}} .ehp-flex-hero' => '--flex-hero-box-border-color: {{VALUE}}',
773 ],
774 'condition' => [
775 'show_box_border' => 'yes',
776 ],
777 ]
778 );
779
780 $shapes = new Ehp_Shapes( $this, [
781 'widget_name' => $this->get_name(),
782 'container_prefix' => 'box',
783 ] );
784 $shapes->add_style_controls();
785
786 $this->add_group_control(
787 Group_Control_Box_Shadow::get_type(),
788 [
789 'name' => 'box_box_shadow',
790 'selector' => '{{WRAPPER}} .ehp-flex-hero',
791 ]
792 );
793
794 $padding = new Ehp_Padding( $this, [
795 'widget_name' => $this->get_name(),
796 'container_prefix' => 'box',
797 ] );
798 $padding->add_style_controls();
799
800 $this->add_control(
801 'box_full_screen_height',
802 [
803 'label' => esc_html__( 'Full Screen Height', 'hello-plus' ),
804 'type' => Controls_Manager::SWITCHER,
805 'label_on' => esc_html__( 'Yes', 'hello-plus' ),
806 'label_off' => esc_html__( 'No', 'hello-plus' ),
807 'return_value' => 'yes',
808 'default' => '',
809 'tablet_default' => '',
810 'mobile_default' => '',
811 'separator' => 'before',
812 ]
813 );
814
815 $configured_breakpoints = $this->get_configured_breakpoints();
816
817 $this->add_control(
818 'box_full_screen_height_controls',
819 [
820 'label' => esc_html__( 'Apply Full Screen Height on', 'hello-plus' ),
821 'type' => Controls_Manager::SELECT2,
822 'label_block' => true,
823 'multiple' => true,
824 'options' => $configured_breakpoints['devices_options'],
825 'default' => $configured_breakpoints['active_devices'],
826 'condition' => [
827 'box_full_screen_height' => 'yes',
828 ],
829 ]
830 );
831
832 $this->end_controls_section();
833 }
834 }
835