PluginProbe ʕ •ᴥ•ʔ
Shortcodes and extra features for Phlox theme / 2.5.13
Shortcodes and extra features for Phlox theme v2.5.13
2.17.21 2.17.20 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.6 1.0.9 1.1.0 1.3.0 1.3.1 1.3.10 1.3.14 1.3.2 1.3.3 1.3.6 1.4.0 1.4.1 1.4.2 1.5.0 1.5.2 1.6.0 1.6.2 1.6.4 1.7.0 1.7.2 2.10.0 2.10.1 2.10.3 2.10.5 2.10.7 2.10.8 2.10.9 2.11.0 2.11.1 2.11.2 2.12.0 2.14.0 2.15.0 2.15.2 2.15.4 2.15.5 2.15.6 2.15.7 2.15.8 2.15.9 2.16.0 2.16.1 2.16.2 2.16.3 2.16.4 2.17.0 2.17.1 2.17.12 2.17.13 2.17.14 2.17.15 2.17.16 2.17.2 2.17.3 2.17.4 2.17.5 2.17.6 2.17.8 2.17.9 2.4.12 2.4.13 2.4.14 2.4.16 2.4.18 2.4.19 2.4.9 2.5.0 2.5.1 2.5.10 2.5.11 2.5.12 2.5.13 2.5.14 2.5.15 2.5.16 2.5.17 2.5.19 2.5.2 2.5.20 2.5.3 2.5.7 2.5.8 2.5.9 2.6.0 2.6.1 2.6.10 2.6.12 2.6.13 2.6.14 2.6.15 2.6.16 2.6.17 2.6.19 2.6.2 2.6.20 2.6.4 2.6.5 2.6.7 2.7.0 2.7.1 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.9 2.9.0 2.9.12 2.9.14 2.9.15 2.9.16 2.9.17 2.9.18 2.9.19 2.9.2 2.9.20 2.9.21 2.9.22 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7 2.9.8
auxin-elements / includes / elementor / widgets / theme-elements / menu.php
auxin-elements / includes / elementor / widgets / theme-elements Last commit date
breadcrumbs.php 6 years ago copyright.php 6 years ago current-time.php 6 years ago logo.php 6 years ago menu.php 6 years ago modern-search.php 6 years ago search.php 6 years ago shopping-cart.php 6 years ago site-title.php 6 years ago
menu.php
1495 lines
1 <?php
2 namespace Auxin\Plugin\CoreElements\Elementor\Elements\Theme_Elements;
3
4 use Elementor\Plugin;
5 use Elementor\Widget_Base;
6 use Elementor\Controls_Manager;
7 use Elementor\Group_Control_Typography;
8 use Elementor\Scheme_Typography;
9 use Elementor\Group_Control_Border;
10 use Elementor\Group_Control_Background;
11 use Elementor\Group_Control_Box_Shadow;
12 use Elementor\Group_Control_Text_Shadow;
13
14
15 if ( ! defined( 'ABSPATH' ) ) {
16 exit; // Exit if accessed directly.
17 }
18
19 /**
20 * Elementor 'MenuBox' widget.
21 *
22 * Elementor widget that displays an 'MenuBox'.
23 *
24 * @since 1.0.0
25 */
26 class MenuBox extends Widget_Base {
27
28 /**
29 * Get widget name.
30 *
31 * Retrieve 'MenuBox' widget name.
32 *
33 * @since 1.0.0
34 * @access public
35 *
36 * @return string Widget name.
37 */
38 public function get_name() {
39 return 'aux_menu_box';
40 }
41
42 /**
43 * Get widget title.
44 *
45 * Retrieve 'MenuBox' widget title.
46 *
47 * @since 1.0.0
48 * @access public
49 *
50 * @return string Widget title.
51 */
52 public function get_title() {
53 return __('Navigation Menu', 'auxin-elements' );
54 }
55
56 /**
57 * Get widget icon.
58 *
59 * Retrieve 'MenuBox' widget icon.
60 *
61 * @since 1.0.0
62 * @access public
63 *
64 * @return string Widget icon.
65 */
66 public function get_icon() {
67 return 'eicon-nav-menu auxin-badge';
68 }
69
70 /**
71 * Get widget categories.
72 *
73 * Retrieve 'MenuBox' widget icon.
74 *
75 * @since 1.0.0
76 * @access public
77 *
78 * @return string Widget icon.
79 */
80 public function get_categories() {
81 return array( 'auxin-core', 'auxin-theme-elements' );
82 }
83
84 /**
85 * Get the all available menus
86 *
87 * Retrieve the list of all menus.
88 *
89 * @since 1.0.0
90 * @access public
91 *
92 * @return array menu slug.
93 */
94 private function get_available_menus() {
95 $menus = wp_get_nav_menus();
96
97 $options = array();
98
99 foreach ( $menus as $menu ) {
100 $options[ $menu->slug ] = $menu->name;
101 }
102
103 return $options;
104 }
105
106
107 /**
108 * Register 'MenuBox' widget controls.
109 *
110 * Adds different input fields to allow the user to change and customize the widget settings.
111 *
112 * @since 1.0.0
113 * @access protected
114 */
115 protected function _register_controls() {
116
117 $this->start_controls_section(
118 'general',
119 array(
120 'label' => __('General', 'auxin-elements' ),
121 )
122 );
123
124 $menus = $this->get_available_menus();
125
126 if ( ! empty( $menus ) ) {
127 $this->add_control(
128 'menu_slug',
129 array(
130 'label' => __( 'Menu', 'auxin-elements' ),
131 'type' => Controls_Manager::SELECT,
132 'options' => $menus,
133 'default' => array_keys( $menus )[0],
134 'save_default' => true,
135 'description' => sprintf(
136 __( 'Go to the %s Menus screen %s to manage your menus.', 'auxin-elements' ),
137 '<a href="'. self_admin_url( 'nav-menus.php' ) .'" target="_blank">',
138 '</a>'
139 )
140 )
141 );
142 } else {
143 $this->add_control(
144 'menu_slug',
145 array(
146 'type' => Controls_Manager::RAW_HTML,
147 'raw' => sprintf( __( '<strong>There are no menus in your site.</strong><br>Go to the <a href="%s" target="_blank">Menus screen</a> to create one.', 'auxin-elements' ), self_admin_url( 'nav-menus.php?action=edit&menu=0' ) ),
148 'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',
149 )
150 );
151 }
152
153 $this->add_control(
154 'type',
155 array(
156 'label' => __('Type', 'auxin-elements'),
157 'type' => Controls_Manager::SELECT,
158 'default' => 'horizontal',
159 'options' => array(
160 'horizontal' => __('Horizontal' , 'auxin-elements' ),
161 'vertical' => __('Vertical' , 'auxin-elements' ),
162 'burger' => __('Burger' , 'auxin-elements' )
163 ),
164 'condition' => array(
165 'menu_slug!' => ''
166 )
167 )
168 );
169
170 $this->add_control(
171 'splitter',
172 array(
173 'label' => __( 'Display Menu Splitter', 'auxin-elements' ),
174 'type' => Controls_Manager::SWITCHER,
175 'label_on' => __( 'On', 'auxin-elements' ),
176 'label_off' => __( 'Off', 'auxin-elements' ),
177 'return_value' => 'yes',
178 'default' => 'yes',
179 'condition' => array(
180 'type' => 'horizontal'
181 )
182 )
183 );
184
185 $this->add_control(
186 'indicator',
187 array(
188 'label' => __( 'Display Submenu Indicator', 'auxin-elements' ),
189 'type' => Controls_Manager::SWITCHER,
190 'label_on' => __( 'On', 'auxin-elements' ),
191 'label_off' => __( 'Off', 'auxin-elements' ),
192 'return_value' => 'yes',
193 'default' => 'yes',
194 )
195 );
196
197 $this->end_controls_section();
198
199 $this->start_controls_section(
200 'mobile_menu_section',
201 array(
202 'label' => __('Mobile Menu', 'auxin-elements' ),
203 )
204 );
205
206 $this->add_control(
207 'display_burger',
208 array(
209 'label' => __('Display Mobile Menu on', 'auxin-elements'),
210 'label_block' => true,
211 'type' => Controls_Manager::SELECT,
212 'default' => '768',
213 'options' => array(
214 '1024' => __('Tablet (1024px and lower)' , 'auxin-elements' ),
215 '768' => __('Mobile (768px and lower)' , 'auxin-elements' ),
216 'custom' => __('Custom Breakpoint', 'auxin-elements' )
217 ),
218 'condition' => array(
219 'menu_slug!' => ''
220 )
221 )
222 );
223
224 $this->add_control(
225 'breakpoint',
226 array(
227 'label' => __('BreakPoint (pixel)', 'auxin-elements' ),
228 'type' => Controls_Manager::SLIDER,
229 'size_units' => array('px'),
230 'range' => array(
231 'px' => array(
232 'min' => 1,
233 'max' => 1600,
234 'step' => 1
235 )
236 ),
237 'default' => array(
238 'unit' => 'px',
239 'size' => 768
240 ),
241 'separator' => 'before',
242 'condition' => array(
243 'type!' => 'burger',
244 'display_burger' => 'custom'
245 )
246 )
247 );
248
249 $this->add_control(
250 'burger_menu_location',
251 array(
252 'label' => __('Mobile Menu Type', 'auxin-elements' ),
253 'type' => 'aux-visual-select',
254 'style_items' => '',
255 'options' => array(
256 'toggle-bar' => array(
257 'label' => __( 'Expandable under top header', 'auxin-elements' ),
258 'image' => AUXIN_URL . 'images/visual-select/burger-menu-location-1.svg'
259 ),
260 'overlay' => array(
261 'label' => __( 'FullScreen on entire page', 'auxin-elements' ),
262 'image' => AUXIN_URL . 'images/visual-select/burger-menu-location-3.svg'
263 ),
264 'offcanvas' => array(
265 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
266 'image' => AUXIN_URL . 'images/visual-select/burger-menu-location-2.svg'
267 )
268 ),
269 'default' => 'toggle-bar',
270 'seperator' => 'before'
271 )
272 );
273
274 $this->add_control(
275 'offcanvas_align',
276 array(
277 'label' => __( 'Position', 'auxin-elements' ),
278 'type' => Controls_Manager::SELECT,
279 'default' => 'left',
280 'options' => array(
281 'left' => __('Left' , 'auxin-elements' ),
282 'right' => __('Right' , 'auxin-elements' )
283 ),
284 'condition' => array(
285 'burger_menu_location' => 'offcanvas'
286 )
287 )
288 );
289
290 $this->add_control(
291 'burger_toggle_type',
292 array(
293 'label' => __('Mobile Menu Opening Type', 'auxin-elements'),
294 'label_block' => true,
295 'type' => Controls_Manager::SELECT,
296 'default' => 'toggle',
297 'options' => array(
298 'toggle' => __('Toggle' , 'auxin-elements' ),
299 'accordion' => __('Accordion' , 'auxin-elements' )
300 )
301 )
302 );
303
304 $this->end_controls_section();
305
306 /*-----------------------------------------------------------------------------------*/
307 /* Style TAB
308 /*-----------------------------------------------------------------------------------*/
309
310 /* Menu Item Section
311 /*-------------------------------------*/
312
313 $this->start_controls_section(
314 'menu_item_section',
315 array(
316 'label' => __( 'Menu Item', 'auxin-elements' ),
317 'tab' => Controls_Manager::TAB_STYLE
318 )
319 );
320
321 $this->add_responsive_control(
322 'align',
323 array(
324 'label' => __('Text Align', 'auxin-elements'),
325 'type' => Controls_Manager::CHOOSE,
326 'devices' => array( 'desktop', 'mobile' ),
327 'options' => array(
328 'left' => array(
329 'title' => __( 'Left', 'auxin-elements' ),
330 'icon' => 'fa fa-align-left'
331 ),
332 'center' => array(
333 'title' => __( 'Center', 'auxin-elements' ),
334 'icon' => 'fa fa-align-center'
335 ),
336 'right' => array(
337 'title' => __( 'Right', 'auxin-elements' ),
338 'icon' => 'fa fa-align-right'
339 )
340 ),
341 'default' => 'left',
342 'toggle' => true,
343 'selectors' => array(
344 '{{WRAPPER}}' => 'text-align: {{VALUE}}'
345 )
346 )
347 );
348
349 $this->start_controls_tabs( 'item_colors' );
350
351 $this->start_controls_tab(
352 'item_color_normal',
353 array(
354 'label' => __( 'Normal' , 'auxin-elements' )
355 )
356 );
357
358 $this->add_control(
359 'item_color',
360 array(
361 'label' => __( 'Color', 'auxin-elements' ),
362 'type' => Controls_Manager::COLOR,
363 'selectors' => array(
364 '{{WRAPPER}} .aux-menu-depth-0 > .aux-item-content' => 'color: {{VALUE}};'
365 )
366 )
367 );
368
369 $this->add_group_control(
370 Group_Control_Typography::get_type(),
371 array(
372 'name' => 'menu_item_typo',
373 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
374 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-item-content'
375 )
376 );
377
378 $this->add_group_control(
379 Group_Control_Text_Shadow::get_type(),
380 [
381 'name' => 'menu_item_text_shadow',
382 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-item-content'
383 ]
384 );
385
386 $this->add_group_control(
387 Group_Control_Box_Shadow::get_type(),
388 array(
389 'name' => 'item_box_shadow',
390 'selector' => '{{WRAPPER}} .aux-menu-depth-0'
391 )
392 );
393
394 $this->add_group_control(
395 Group_Control_Background::get_type(),
396 array(
397 'name' => 'item_background',
398 'label' => __( 'Background', 'auxin-elements' ),
399 'types' => array( 'classic', 'gradient' ),
400 'selector' => '{{WRAPPER}} .aux-menu-depth-0 '
401 )
402 );
403
404 $this->add_group_control(
405 Group_Control_Border::get_type(),
406 array(
407 'name' => 'item_border',
408 'selector' => '{{WRAPPER}} .aux-menu-depth-0',
409 'separator' => 'none'
410 )
411 );
412
413 $this->add_responsive_control(
414 'item_border_radius',
415 array(
416 'label' => __( 'Border Radius', 'auxin-elements' ),
417 'type' => Controls_Manager::DIMENSIONS,
418 'size_units' => array( 'px', 'em', '%' ),
419 'selectors' => array(
420 '{{WRAPPER}} .aux-menu-depth-0' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
421 ),
422 'allowed_dimensions' => 'all'
423 )
424 );
425
426 $this->end_controls_tab();
427
428 $this->start_controls_tab(
429 'item_color_hover',
430 array(
431 'label' => __( 'Hover' , 'auxin-elements' )
432 )
433 );
434
435 $this->add_control(
436 'item_hover_color',
437 array(
438 'label' => __( 'Color', 'auxin-elements' ),
439 'type' => Controls_Manager::COLOR,
440 'selectors' => array(
441 '{{WRAPPER}} .aux-menu-depth-0.aux-hover > .aux-item-content ' => 'color: {{VALUE}} !important;'
442 )
443 )
444 );
445
446 $this->add_group_control(
447 Group_Control_Typography::get_type(),
448 array(
449 'name' => 'menu_item_typo_hover',
450 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
451 'selector' => '{{WRAPPER}} .aux-menu-depth-0.aux-hover > .aux-item-content',
452 )
453 );
454
455 $this->add_group_control(
456 Group_Control_Text_Shadow::get_type(),
457 [
458 'name' => 'menu_item_text_shadow_hover',
459 'selector' => '{{WRAPPER}} .aux-menu-depth-0.aux-hover > .aux-item-content'
460 ]
461 );
462
463 $this->add_group_control(
464 Group_Control_Box_Shadow::get_type(),
465 array(
466 'name' => 'hover_item_box_shadow',
467 'selector' => '{{WRAPPER}} .aux-menu-depth-0.aux-hover'
468 )
469 );
470
471 $this->add_group_control(
472 Group_Control_Background::get_type(),
473 array(
474 'name' => 'hover_item_background',
475 'label' => __( 'Background', 'auxin-elements' ),
476 'types' => array( 'classic', 'gradient' ),
477 'selector' => '{{WRAPPER}} .aux-menu-depth-0.aux-hover'
478 )
479 );
480
481 $this->add_group_control(
482 Group_Control_Border::get_type(),
483 array(
484 'name' => 'item_hover_border',
485 'selector' => '{{WRAPPER}} .aux-menu-depth-0.aux-hover',
486 'separator' => 'none'
487 )
488 );
489
490 $this->add_responsive_control(
491 'item_hover_border_radius',
492 array(
493 'label' => __( 'Border Radius', 'auxin-elements' ),
494 'type' => Controls_Manager::DIMENSIONS,
495 'size_units' => array( 'px', 'em', '%' ),
496 'selectors' => array(
497 '{{WRAPPER}} .aux-menu-depth-0.aux-hover' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
498 ),
499 'allowed_dimensions' => 'all',
500 )
501 );
502
503
504 $this->end_controls_tab();
505
506 $this->end_controls_tabs();
507
508
509 $this->add_responsive_control(
510 'item_padding',
511 array(
512 'label' => __( 'Padding', 'auxin-elements' ),
513 'type' => Controls_Manager::DIMENSIONS,
514 'size_units' => array( 'px', '%' ),
515 'selectors' => array(
516 '{{WRAPPER}} .aux-menu-depth-0 > .aux-item-content' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
517 ),
518 'separator' => 'before'
519 )
520 );
521
522 $this->add_responsive_control(
523 'item_margin',
524 array(
525 'label' => __( 'Margin', 'auxin-elements' ),
526 'type' => Controls_Manager::DIMENSIONS,
527 'size_units' => array( 'px', '%' ),
528 'selectors' => array(
529 '{{WRAPPER}} .aux-menu-depth-0' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
530 ),
531 'seperator' => 'after'
532 )
533 );
534
535 $this->end_controls_section();
536
537 /* Menu item - Current Section
538 /*-------------------------------------*/
539
540 $this->start_controls_section(
541 'menu_item_current_section',
542 array(
543 'label' => __( 'Menu Item - Selected', 'auxin-elements' ),
544 'tab' => Controls_Manager::TAB_STYLE
545 )
546 );
547
548 $this->add_control(
549 'menu_item_current_color',
550 array(
551 'label' => __( 'Color', 'auxin-elements' ),
552 'type' => Controls_Manager::COLOR,
553 'selectors' => array(
554 '{{WRAPPER}} .aux-menu-depth-0.current-menu-item > a' => 'color: {{VALUE}};',
555 ),
556 )
557 );
558
559 $this->add_group_control(
560 Group_Control_Typography::get_type(),
561 array(
562 'name' => 'menu_item_current_typography',
563 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
564 'selector' => '{{WRAPPER}} .aux-menu-depth-0.current-menu-item > a'
565 )
566 );
567
568 $this->add_group_control(
569 Group_Control_Text_Shadow::get_type(),
570 [
571 'name' => 'menu_item_current_text_shadow',
572 'selector' => '{{WRAPPER}} .aux-menu-depth-0.current-menu-item > a'
573 ]
574 );
575
576 $this->add_group_control(
577 Group_Control_Box_Shadow::get_type(),
578 array(
579 'name' => 'menu_item_current_box_shadow',
580 'selector' => '{{WRAPPER}} .aux-menu-depth-0.current-menu-item > a'
581 )
582 );
583
584 $this->add_group_control(
585 Group_Control_Background::get_type(),
586 array(
587 'name' => 'menu_item_current_background',
588 'label' => __( 'Background', 'auxin-elements' ),
589 'types' => array( 'classic', 'gradient' ),
590 'selector' => '{{WRAPPER}} .aux-menu-depth-0.current-menu-item > a '
591 )
592 );
593
594 $this->end_controls_section();
595
596
597 /* Submenu Section
598 /*-------------------------------------*/
599
600 $this->start_controls_section(
601 'submenu_style_section',
602 array(
603 'label' => __( 'Submenu', 'auxin-elements' ),
604 'tab' => Controls_Manager::TAB_STYLE
605 )
606 );
607
608 $this->add_control(
609 'submenu_skin',
610 array(
611 'label' => __('Skin','auxin-elements' ),
612 'type' => 'aux-visual-select',
613 'style_items' => 'max-width:45%;',
614 'options' => array(
615 'classic' => array(
616 'label' => __('Paradox', 'auxin-elements' ),
617 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-1.svg'
618 ),
619 'classic-center' => array(
620 'label' => __( 'Classic', 'auxin-elements' ),
621 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-2.svg'
622 ),
623 'dash-divided' => array(
624 'label' => __( 'Dark Transparent', 'auxin-elements' ),
625 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-5.svg'
626 ),
627 'divided' => array(
628 'label' => __( 'Divided', 'auxin-elements' ),
629 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-3.svg'
630 ),
631 'minimal-center' => array(
632 'label' => __( 'Center Paradox', 'auxin-elements' ),
633 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-4.svg'
634 ),
635 'modern' => array(
636 'label' => __( 'Modern Paradox', 'auxin-elements' ),
637 'image' => AUXIN_URL . 'images/visual-select/sub-menu-skin-6.svg'
638 )
639 ),
640 'default' => 'classic',
641 'separator' => 'after'
642 )
643 );
644
645 $this->add_control(
646 'submenu_anim',
647 array(
648 'label' => __('Animation Effect','auxin-elements' ),
649 'type' => 'aux-visual-select',
650 'style_items' => 'max-width:100%;',
651 'options' => array(
652 'none' => array(
653 'label' => __( 'None', 'auxin-elements' ),
654 'video_src' => AUXIN_URL . 'images/visual-select/videos/NoFade.webm webm'
655 ),
656 'fade' => array(
657 'label' => __( 'Fade', 'auxin-elements' ),
658 'video_src' => AUXIN_URL . 'images/visual-select/videos/Fade.webm webm'
659 ),
660 'slide-up' => array(
661 'label' => __( 'Fade and move', 'auxin-elements' ),
662 'video_src' => AUXIN_URL . 'images/visual-select/videos/FadeAndMove.webm webm'
663 )
664 ),
665 'default' => 'none',
666 'seperator' => 'after'
667 )
668 );
669
670 $this->start_controls_tabs( 'sub_background_tab' );
671
672 $this->start_controls_tab(
673 'submenu_style_normal',
674 array(
675 'label' => __( 'Normal' , 'auxin-elements' )
676 )
677 );
678
679 $this->add_group_control(
680 Group_Control_Background::get_type(),
681 array(
682 'name' => 'sub_background',
683 'label' => __( 'Background', 'auxin-elements' ),
684 'types' => array( 'classic', 'gradient' ),
685 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu'
686 )
687 );
688
689 $this->add_group_control(
690 Group_Control_Box_Shadow::get_type(),
691 array(
692 'name' => 'sub_box_shadow',
693 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu'
694 )
695 );
696
697 $this->add_responsive_control(
698 'sub_border_radius',
699 array(
700 'label' => __( 'Border Radius', 'auxin-elements' ),
701 'type' => Controls_Manager::DIMENSIONS,
702 'size_units' => array( 'px', 'em', '%' ),
703 'selectors' => array(
704 '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
705 ),
706 'allowed_dimensions' => 'all',
707 )
708 );
709
710 $this->add_group_control(
711 Group_Control_Border::get_type(),
712 array(
713 'name' => 'sub_border',
714 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu',
715 'separator' => 'none'
716 )
717 );
718
719 $this->end_controls_tab();
720
721 $this->start_controls_tab(
722 'submenu_style_hover',
723 array(
724 'label' => __( 'Hover' , 'auxin-elements' )
725 )
726 );
727
728 $this->add_group_control(
729 Group_Control_Background::get_type(),
730 array(
731 'name' => 'hover_sub_background',
732 'label' => __( 'Background', 'auxin-elements' ),
733 'types' => array( 'classic', 'gradient' ),
734 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu:hover'
735 )
736 );
737
738 $this->add_group_control(
739 Group_Control_Box_Shadow::get_type(),
740 array(
741 'name' => 'hover_sub_box_shadow',
742 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu:hover'
743 )
744 );
745
746 $this->add_responsive_control(
747 'sub_hover_border_radius',
748 array(
749 'label' => __( 'Border Radius', 'auxin-elements' ),
750 'type' => Controls_Manager::DIMENSIONS,
751 'size_units' => array( 'px', 'em', '%' ),
752 'selectors' => array(
753 '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu:hover' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
754 ),
755 'allowed_dimensions' => 'all',
756 )
757 );
758
759 $this->add_group_control(
760 Group_Control_Border::get_type(),
761 array(
762 'name' => 'sub_hover_border',
763 'selector' => '{{WRAPPER}} .aux-menu-item.aux-open > .aux-submenu:hover',
764 'separator' => 'none'
765 )
766 );
767
768 $this->end_controls_tab();
769
770 $this->end_controls_tabs();
771
772 $this->end_controls_section();
773
774
775 /* SubMenu Item Section
776 /*-------------------------------------*/
777
778 $this->start_controls_section(
779 'submenu_item_section',
780 array(
781 'label' => __( 'Submenu Item', 'auxin-elements' ),
782 'tab' => Controls_Manager::TAB_STYLE
783 )
784 );
785
786 $this->start_controls_tabs( 'sub_item_colors' );
787
788 $this->start_controls_tab(
789 'sub_item_color_normal',
790 array(
791 'label' => __( 'Normal' , 'auxin-elements' )
792 )
793 );
794
795 $this->add_control(
796 'sub_item_color',
797 array(
798 'label' => __( 'Color', 'auxin-elements' ),
799 'type' => Controls_Manager::COLOR,
800 'selectors' => array(
801 '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content' => 'color: {{VALUE}} !important;',
802 ),
803 'seperartor' => 'after'
804 )
805 );
806
807 $this->add_group_control(
808 Group_Control_Typography::get_type(),
809 array(
810 'name' => 'menu_sub_item_typo',
811 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
812 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item',
813 )
814 );
815
816 $this->add_group_control(
817 Group_Control_Text_Shadow::get_type(),
818 [
819 'name' => 'sub_item_text_shadow',
820 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content'
821 ]
822 );
823
824 $this->add_group_control(
825 Group_Control_Box_Shadow::get_type(),
826 array(
827 'name' => 'sub_item_box_shadow',
828 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content'
829 )
830 );
831
832 $this->add_group_control(
833 Group_Control_Background::get_type(),
834 array(
835 'name' => 'sub_item_background',
836 'label' => __( 'Background', 'auxin-elements' ),
837 'types' => array( 'classic', 'gradient' ),
838 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content'
839 )
840 );
841
842
843 $this->add_responsive_control(
844 'sub_item_border_radius',
845 array(
846 'label' => __( 'Border Radius', 'auxin-elements' ),
847 'type' => Controls_Manager::DIMENSIONS,
848 'size_units' => array( 'px', 'em', '%' ),
849 'selectors' => array(
850 '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
851 ),
852 'allowed_dimensions' => 'all',
853 )
854 );
855
856 $this->add_group_control(
857 Group_Control_Border::get_type(),
858 array(
859 'name' => 'sub_item_border',
860 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content',
861 'separator' => 'none'
862 )
863 );
864
865 $this->end_controls_tab();
866
867 $this->start_controls_tab(
868 'sub_item_color_hover',
869 array(
870 'label' => __( 'Hover' , 'auxin-elements' )
871 )
872 );
873
874 $this->add_control(
875 'sub_item_hover_color',
876 array(
877 'label' => __( 'Color', 'auxin-elements' ),
878 'type' => Controls_Manager::COLOR,
879 'selectors' => array(
880 '{{WRAPPER}} .aux-submenu .aux-menu-item.aux-hover .aux-item-content' => 'color: {{VALUE}} !important;'
881 ),
882 'seperartor' => 'after'
883 )
884 );
885
886 $this->add_group_control(
887 Group_Control_Typography::get_type(),
888 array(
889 'name' => 'menu_sub_item_typo_hover',
890 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
891 'selector' => '{{WRAPPER}} .aux-submenu .aux-menu-item.aux-hover',
892 )
893 );
894
895 $this->add_group_control(
896 Group_Control_Text_Shadow::get_type(),
897 [
898 'name' => 'hover_sub_item_text_shadow',
899 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-submenu > .aux-menu-item.aux-hover > .aux-item-content'
900 ]
901 );
902
903 $this->add_group_control(
904 Group_Control_Box_Shadow::get_type(),
905 array(
906 'name' => 'hover_sub_item_box_shadow',
907 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-submenu > .aux-menu-item.aux-hover > .aux-item-content'
908 )
909 );
910
911 $this->add_group_control(
912 Group_Control_Background::get_type(),
913 array(
914 'name' => 'hover_sub_item_background',
915 'label' => __( 'Background', 'auxin-elements' ),
916 'types' => array( 'classic', 'gradient' ),
917 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-submenu > .aux-menu-item.aux-hover > .aux-item-content'
918 )
919 );
920
921 $this->add_responsive_control(
922 'sub_item_hover_border_radius',
923 array(
924 'label' => __( 'Border Radius', 'auxin-elements' ),
925 'type' => Controls_Manager::DIMENSIONS,
926 'size_units' => array( 'px', 'em', '%' ),
927 'selectors' => array(
928 '{{WRAPPER}} .aux-menu-depth-0 > .aux-submenu > .aux-menu-item.aux-hover > .aux-item-content' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
929 ),
930 'allowed_dimensions' => 'all',
931 )
932 );
933
934 $this->add_group_control(
935 Group_Control_Border::get_type(),
936 array(
937 'name' => 'sub_item_hover_border',
938 'selector' => '{{WRAPPER}} .aux-menu-depth-0 > .aux-submenu > .aux-menu-item.aux-hover > .aux-item-content',
939 'separator' => 'none'
940 )
941 );
942
943 $this->end_controls_tab();
944
945 $this->end_controls_tabs();
946
947
948 $this->add_responsive_control(
949 'sub_item_padding',
950 array(
951 'label' => __( 'Padding', 'auxin-elements' ),
952 'type' => Controls_Manager::DIMENSIONS,
953 'size_units' => array( 'px', '%' ),
954 'selectors' => array(
955 '{{WRAPPER}} .aux-submenu .aux-menu-item .aux-item-content' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
956 ),
957 'separator' => 'before'
958 )
959 );
960
961 $this->add_responsive_control(
962 'sub_item_margin',
963 array(
964 'label' => __( 'Margin', 'auxin-elements' ),
965 'type' => Controls_Manager::DIMENSIONS,
966 'size_units' => array( 'px', '%' ),
967 'selectors' => array(
968 '{{WRAPPER}} .aux-submenu .aux-menu-item' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
969 ),
970 'seperator' => 'after'
971 )
972 );
973
974 $this->end_controls_section();
975
976 /* Burger Button Section
977 /*-------------------------------------*/
978
979 $this->start_controls_section(
980 'burger_section',
981 array(
982 'label' => __( 'Burger Button', 'auxin-elements' ),
983 'tab' => Controls_Manager::TAB_STYLE
984 )
985 );
986
987 $this->add_control(
988 'burger_type',
989 array(
990 'label' => __( 'Type', 'auxin-elements' ),
991 'type' => Controls_Manager::SELECT,
992 'default' => 'default',
993 'options' => array(
994 'default' => __( 'Default', 'auxin-elements' ),
995 'custom' => __( 'Custom', 'auxin-elements' ),
996 ),
997 )
998 );
999
1000 $this->start_controls_tabs(
1001 'burger_color',
1002 array(
1003 'condition' => array(
1004 'burger_type' => 'default'
1005 )
1006 )
1007 );
1008
1009 $this->start_controls_tab(
1010 'burger_color_normal',
1011 array(
1012 'label' => __( 'Normal' , 'auxin-elements' )
1013 )
1014 );
1015
1016 $this->add_control(
1017 'burger_btn_color',
1018 array(
1019 'label' => __( 'Color', 'auxin-elements' ),
1020 'type' => Controls_Manager::COLOR,
1021 'selectors' => array(
1022 '{{WRAPPER}} .aux-burger:before, {{WRAPPER}} .aux-burger:after, {{WRAPPER}} .aux-burger .mid-line' => 'border-color: {{VALUE}} !important;',
1023 ),
1024 'seperartor' => 'after'
1025 )
1026 );
1027
1028 $this->end_controls_tab();
1029
1030 $this->start_controls_tab(
1031 'burger_color_hover',
1032 array(
1033 'label' => __( 'Hover' , 'auxin-elements' )
1034 )
1035 );
1036
1037 $this->add_control(
1038 'burger_btn_hover_color',
1039 array(
1040 'label' => __( 'Color', 'auxin-elements' ),
1041 'type' => Controls_Manager::COLOR,
1042 'selectors' => array(
1043 '{{WRAPPER}} .aux-burger:hover:before, {{WRAPPER}} .aux-burger:hover:after, {{WRAPPER}} .aux-burger:hover .mid-line' => 'border-color: {{VALUE}} !important;',
1044 ),
1045 'seperartor' => 'after'
1046 )
1047 );
1048
1049 $this->end_controls_tab();
1050
1051 $this->end_controls_tabs();
1052
1053 $this->add_control(
1054 'burger_btn_style',
1055 array(
1056 'label' => __('Burger Button Style','auxin-elements' ),
1057 'type' => 'aux-visual-select',
1058 'style_items' => 'max-width:45%;',
1059 'options' => array(
1060 'aux-lite-large' => array(
1061 'label' => __( 'Expandable under top header', 'auxin-elements' ),
1062 'image' => AUXIN_URL . 'images/visual-select/burger-lite-large.svg'
1063 ),
1064 'aux-regular-large' => array(
1065 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1066 'image' => AUXIN_URL . 'images/visual-select/burger-regular-large.svg'
1067 ),
1068 'aux-thick-large' => array(
1069 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1070 'image' => AUXIN_URL . 'images/visual-select/burger-thick-large.svg'
1071 ),
1072 'aux-lite-medium' => array(
1073 'label' => __( 'FullScreen on entire page', 'auxin-elements' ),
1074 'image' => AUXIN_URL . 'images/visual-select/burger-lite-medium.svg'
1075 ),
1076 'aux-regular-medium' => array(
1077 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1078 'image' => AUXIN_URL . 'images/visual-select/burger-regular-medium.svg'
1079 ),
1080 'aux-thick-medium' => array(
1081 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1082 'image' => AUXIN_URL . 'images/visual-select/burger-thick-medium.svg'
1083 ),
1084 'aux-lite-small' => array(
1085 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1086 'image' => AUXIN_URL . 'images/visual-select/burger-lite-small.svg'
1087 ),
1088 'aux-regular-small' => array(
1089 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1090 'image' => AUXIN_URL . 'images/visual-select/burger-regular-small.svg'
1091 ),
1092 'aux-thick-small' => array(
1093 'label' => __( 'Offcanvas panel', 'auxin-elements' ),
1094 'image' => AUXIN_URL . 'images/visual-select/burger-thick-small.svg'
1095 )
1096 ),
1097 'default' => 'aux-lite-small',
1098 'seperator' => 'before',
1099 'condition' => array(
1100 'burger_type' => 'default'
1101 )
1102 )
1103 );
1104
1105 $this->add_control(
1106 'burger_custom',
1107 array(
1108 'label' => '',
1109 'type' => Controls_Manager::CODE,
1110 'default' => '',
1111 'placeholder' => __( 'Enter inline SVG content here', 'auxin-elements' ),
1112 'show_label' => false,
1113 'condition' => array(
1114 'burger_type' => 'custom'
1115 )
1116 )
1117 );
1118
1119 $this->end_controls_section();
1120
1121 /* Full Screen Menu Section
1122 /*-------------------------------------*/
1123
1124 $this->start_controls_section(
1125 'fullscr_section',
1126 array(
1127 'label' => __( 'Fullscreen Menu', 'auxin-elements' ),
1128 'tab' => Controls_Manager::TAB_STYLE,
1129 'condition' => array(
1130 'burger_menu_location' => 'overlay'
1131 )
1132 )
1133 );
1134
1135 $this->add_group_control(
1136 Group_Control_Background::get_type(),
1137 array(
1138 'name' => 'fullscr_bg',
1139 'label' => __( 'Background', 'auxin-elements' ),
1140 'types' => array( 'classic', 'gradient' ),
1141 'selector' => '{{WRAPPER}} .aux-fs-popup'
1142 )
1143 );
1144
1145 $this->start_controls_tabs( 'fullscr_item_colors' );
1146
1147 $this->start_controls_tab(
1148 'fullscr_item_color_normal',
1149 array(
1150 'label' => __( 'Normal' , 'auxin-elements' )
1151 )
1152 );
1153
1154 $this->add_control(
1155 'fullscr_item_color',
1156 array(
1157 'label' => __( 'Color', 'auxin-elements' ),
1158 'type' => Controls_Manager::COLOR,
1159 'selectors' => array(
1160 '{{WRAPPER}} .aux-fs-menu .aux-menu-item > .aux-item-content' => 'color: {{VALUE}};',
1161 ),
1162 'seperartor' => 'after'
1163 )
1164 );
1165
1166 $this->add_group_control(
1167 Group_Control_Typography::get_type(),
1168 array(
1169 'name' => 'fullscr_menu_item_typo',
1170 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
1171 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item > .aux-item-content',
1172 )
1173 );
1174
1175 $this->add_group_control(
1176 Group_Control_Text_Shadow::get_type(),
1177 [
1178 'name' => 'fullscr_item_text_shadow',
1179 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item > .aux-item-content'
1180 ]
1181 );
1182
1183 $this->add_group_control(
1184 Group_Control_Box_Shadow::get_type(),
1185 array(
1186 'name' => 'fullscr_item_box_shadow',
1187 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item'
1188 )
1189 );
1190
1191 $this->add_group_control(
1192 Group_Control_Background::get_type(),
1193 array(
1194 'name' => 'fullscr_item_background',
1195 'label' => __( 'Background', 'auxin-elements' ),
1196 'types' => array( 'classic', 'gradient' ),
1197 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item '
1198 )
1199 );
1200
1201 $this->add_responsive_control(
1202 'fullscr_item_border_radius',
1203 array(
1204 'label' => __( 'Border Radius', 'auxin-elements' ),
1205 'type' => Controls_Manager::DIMENSIONS,
1206 'size_units' => array( 'px', 'em', '%' ),
1207 'selectors' => array(
1208 '{{WRAPPER}} .aux-fs-menu .aux-menu-item' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
1209 ),
1210 'allowed_dimensions' => 'all',
1211 )
1212 );
1213
1214 $this->add_group_control(
1215 Group_Control_Border::get_type(),
1216 array(
1217 'name' => 'fullscr_item_border',
1218 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item',
1219 'separator' => 'none'
1220 )
1221 );
1222
1223 $this->end_controls_tab();
1224
1225 $this->start_controls_tab(
1226 'fullscr_item_color_hover',
1227 array(
1228 'label' => __( 'Hover' , 'auxin-elements' )
1229 )
1230 );
1231
1232 $this->add_control(
1233 'fullscr_item_hover_color',
1234 array(
1235 'label' => __( 'Color', 'auxin-elements' ),
1236 'type' => Controls_Manager::COLOR,
1237 'selectors' => array(
1238 '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover > .aux-item-content' => 'color: {{VALUE}} !important;'
1239 ),
1240 'seperartor' => 'after'
1241 )
1242 );
1243
1244 $this->add_group_control(
1245 Group_Control_Typography::get_type(),
1246 array(
1247 'name' => 'fullscr_menu_item_typo_hover',
1248 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
1249 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover > .aux-item-content',
1250 )
1251 );
1252
1253 $this->add_group_control(
1254 Group_Control_Text_Shadow::get_type(),
1255 [
1256 'name' => 'fullscr_hover_item_text_shadow',
1257 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover > .aux-item-content'
1258 ]
1259 );
1260
1261 $this->add_group_control(
1262 Group_Control_Box_Shadow::get_type(),
1263 array(
1264 'name' => 'fullscr_hover_item_box_shadow',
1265 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover'
1266 )
1267 );
1268
1269 $this->add_group_control(
1270 Group_Control_Background::get_type(),
1271 array(
1272 'name' => 'fullscr_hover_item_background',
1273 'label' => __( 'Background', 'auxin-elements' ),
1274 'types' => array( 'classic', 'gradient' ),
1275 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover'
1276 )
1277 );
1278
1279 $this->add_responsive_control(
1280 'fullscr_item_hover_border_radius',
1281 array(
1282 'label' => __( 'Border Radius', 'auxin-elements' ),
1283 'type' => Controls_Manager::DIMENSIONS,
1284 'size_units' => array( 'px', 'em', '%' ),
1285 'selectors' => array(
1286 '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover' => 'border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'
1287 ),
1288 'allowed_dimensions' => 'all',
1289 'separator' => 'after'
1290 )
1291 );
1292
1293 $this->add_group_control(
1294 Group_Control_Border::get_type(),
1295 array(
1296 'name' => 'fullscr_item_hover_border',
1297 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-item.aux-hover',
1298 'separator' => 'none'
1299 )
1300 );
1301
1302 $this->end_controls_tab();
1303
1304 $this->end_controls_tabs();
1305
1306 $this->add_responsive_control(
1307 'fullscr_item_padding',
1308 array(
1309 'label' => __( 'Padding', 'auxin-elements' ),
1310 'type' => Controls_Manager::DIMENSIONS,
1311 'size_units' => array( 'px', '%' ),
1312 'selectors' => array(
1313 '{{WRAPPER}} .aux-fs-menu .aux-menu-item > .aux-item-content' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1314 ),
1315 'separator' => 'before'
1316 )
1317 );
1318
1319 $this->add_responsive_control(
1320 'fullscr_item_margin',
1321 array(
1322 'label' => __( 'Margin', 'auxin-elements' ),
1323 'type' => Controls_Manager::DIMENSIONS,
1324 'size_units' => array( 'px', '%' ),
1325 'selectors' => array(
1326 '{{WRAPPER}} .aux-fs-menu .aux-menu-item' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
1327 ),
1328 'seperator' => 'after'
1329 )
1330 );
1331
1332 $this->add_responsive_control(
1333 'fullscr_align',
1334 array(
1335 'label' => __('Text Align','auxin-elements'),
1336 'type' => Controls_Manager::CHOOSE,
1337 'devices' => array( 'desktop', 'mobile' ),
1338 'options' => array(
1339 'left' => array(
1340 'title' => __( 'Left', 'auxin-elements' ),
1341 'icon' => 'fa fa-align-left',
1342 ),
1343 'center' => array(
1344 'title' => __( 'Center', 'auxin-elements' ),
1345 'icon' => 'fa fa-align-center',
1346 ),
1347 'right' => array(
1348 'title' => __( 'Right', 'auxin-elements' ),
1349 'icon' => 'fa fa-align-right',
1350 ),
1351 ),
1352 'default' => 'left',
1353 'toggle' => true,
1354 'selectors' => array(
1355 '{{WRAPPER}} .aux-fs-menu .aux-master-menu' => 'text-align: {{VALUE}}',
1356 ),
1357 'separator' => 'after'
1358 )
1359 );
1360
1361 $this->add_control(
1362 'fullscr_current_item_color',
1363 array(
1364 'label' => __( 'Color', 'auxin-elements' ),
1365 'type' => Controls_Manager::COLOR,
1366 'selectors' => array(
1367 '{{WRAPPER}} .aux-fs-menu .aux-menu-depth-0.current-menu-item > a' => 'color: {{VALUE}};'
1368 )
1369 )
1370 );
1371
1372 $this->add_group_control(
1373 Group_Control_Typography::get_type(),
1374 array(
1375 'name' => 'fullscr_current_item_typography',
1376 'scheme' => Scheme_Typography::TYPOGRAPHY_1,
1377 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-depth-0.current-menu-item > a'
1378 )
1379 );
1380
1381 $this->add_group_control(
1382 Group_Control_Text_Shadow::get_type(),
1383 [
1384 'name' => 'fullscr_current_item_text_shadow',
1385 'selector' => '{{WRAPPER}} .aux-fs-menu .aux-menu-depth-0.current-menu-item > a'
1386 ]
1387 );
1388
1389 $this->end_controls_section();
1390
1391 }
1392
1393 /**
1394 * Render MenuBox widget output on the frontend.
1395 *
1396 * Written in PHP and used to generate the final HTML.
1397 *
1398 * @since 1.0.0
1399 * @access protected
1400 */
1401 protected function render() {
1402 $settings = $this->get_settings_for_display();
1403
1404 if ( ! isset( $settings['menu_slug'] ) ) {
1405 return _e( 'There are no menus in your site.', 'auxin-elements' ) ;
1406 }
1407
1408
1409 $offcanvas_output = '';
1410 $fullscreen_output = '';
1411 $toggle_bar_output = '';
1412
1413 $indicator = auxin_is_true( $settings['indicator'] );
1414 $splitter = auxin_is_true( $settings['splitter'] );
1415
1416
1417 $menu_class = '';
1418 $menu_class .= ' aux-skin-' . $settings['submenu_skin'] ;
1419 $menu_class .= 'none' !== $settings['submenu_anim'] ? ' aux-' . $settings['submenu_anim'] . '-nav' : '';
1420 $menu_class .= $indicator ? ' aux-with-indicator' : '';
1421 $menu_class .= $splitter ? ' aux-with-splitter' : '';
1422
1423
1424 $mobile_menu_target = '.elementor-element-' . $this->get_id();
1425
1426 switch( $settings['burger_menu_location'] ) {
1427 case 'overlay':
1428 $fullscreen_output = '<section class="aux-fs-popup aux-fs-menu-layout-center aux-indicator">';
1429 $fullscreen_output .= '<div class="aux-panel-close"><div class="aux-close aux-cross-symbol aux-thick-medium"></div></div>';
1430 $fullscreen_output .= '<div class="aux-fs-menu"></div>';
1431 $fullscreen_output .= '</section>';
1432 $mobile_menu_target .= ' .aux-fs-popup .aux-fs-menu';
1433 break;
1434
1435 case 'offcanvas':
1436 $offcanvas_output = '<section class="aux-offcanvas-menu aux-pin-' . $settings['offcanvas_align'] . '">';
1437 $offcanvas_output .= '<div class="aux-panel-close"><div class="aux-close aux-cross-symbol aux-thick-medium"></div></div>';
1438 $offcanvas_output .= '<div class="offcanvas-header"></div>';
1439 $offcanvas_output .= '<div class="offcanvas-content"></div>';
1440 $offcanvas_output .= '<div class="offcanvas-footer"></div>';
1441 $offcanvas_output .= '</section>';
1442 $mobile_menu_target .= ' .aux-offcanvas-menu .offcanvas-content';
1443 break;
1444
1445 case 'toggle-bar':
1446 $toggle_bar_output = '<div class="aux-toggle-menu-bar"></div>';
1447 $mobile_menu_target .= ' .aux-toggle-menu-bar';
1448 break;
1449
1450 default:
1451
1452 }
1453
1454 printf( '<div class="aux-elementor-header aux-nav-menu-element aux-nav-menu-element-%s">', $this->get_id() );
1455
1456 if ( 'default' === $settings['burger_type'] ) {
1457 $burger_content = '<div class="aux-burger ' . $settings['burger_btn_style'] . '"><span class="mid-line"></span></div>';
1458 } else {
1459 $burger_content = '<div class="aux-burger aux-custom-burger">' . $settings['burger_custom'] . '</div>';
1460 }
1461
1462 $burger_btn_output = printf( '<div class="aux-burger-box" data-target-panel="%s" data-target-content="%s">%s</div>',
1463 $settings['burger_menu_location'],
1464 '.elementor-element-' . $this->get_id() . ' .aux-master-menu',
1465 $burger_content
1466 );
1467
1468 $breakpoint = 'custom' === $settings['display_burger'] ? $settings['breakpoint']['size'] : $settings['display_burger'];
1469
1470 wp_nav_menu( array(
1471 'container_id' => 'master-menu-elementor-'. $this->get_id(),
1472 'menu' => $settings['menu_slug'],
1473 'direction' => 'burger' === $settings['type'] ? null : $settings['type'],
1474 'mobile_under' => 'burger' === $settings['type'] ? 7000 : $breakpoint,
1475 'mobile_menu_type' => $settings['burger_toggle_type'],
1476 'mobile_menu_target' => $mobile_menu_target,
1477 'theme_location' => 'element',
1478 'extra_class' => esc_attr( $menu_class ),
1479 'fallback_cb' => 'wp_page_menu'
1480 ));
1481
1482 echo $offcanvas_output;
1483 echo $fullscreen_output;
1484 echo $toggle_bar_output;
1485
1486 echo '</div>';
1487
1488 if ( 'burger' !== $settings['type'] ) {
1489 printf( '<style>@media only screen and (min-width: %spx) { .elementor-element-%s .aux-burger-box { display: none } }</style>', $breakpoint + 1, $this->get_id() );
1490 }
1491
1492 }
1493
1494 }
1495