PageSourceSearch

https://omelhorcroissantdaminharua.com/wp-content/plugins/header-footer-elementor/inc/js/frontend_ver-1.5.3.js

js omelhorcroissantdaminharua.com collected 2026-10-05 05:23:25 UTC 23,627 bytes, 601 lines download raw bytes

1( function( $ ) {
2
3	/**
4	* Search widget JS
5	*/
6
7	var WidgethfeSearchButton = function( $scope, $ ){
8
9		if ( 'undefined' == typeof $scope )
10			return;
11
12			var $input = $scope.find( "input.hfe-search-form__input" );
13			var $clear = $scope.find( "button#clear" );
14			var $clear_with_button = $scope.find( "button#clear-with-button" );
15			var $search_button = $scope.find( ".hfe-search-submit" );
16			var $toggle_search = $scope.find( ".hfe-search-icon-toggle input" );
17
18		$scope.find( '.hfe-search-icon-toggle' ).on( 'click', function( ){
19			$scope.find( ".hfe-search-form__input" ).focus();						
20		});	
21		
22		$scope.find( ".hfe-search-form__input" ).focus( function(){
23			$scope.find( ".hfe-search-button-wrapper" ).addClass( "hfe-input-focus" );
24		});
25
26		$scope.find( ".hfe-search-form__input" ).blur( function() {
27			$scope.find( ".hfe-search-button-wrapper" ).removeClass( "hfe-input-focus" );
28		});
29  		   
30
31		$search_button.on( 'touchstart click', function(){
32			$input.submit();
33		});
34
35		$toggle_search.css( 'padding-right', $toggle_search.next().outerWidth() + 'px' );
36
37	
38		$input.on( 'keyup', function(){
39			$clear.style = (this.value.length) ? $clear.css('visibility','visible'): $clear.css('visibility','hidden');
40			$clear_with_button.style = (this.value.length) ? $clear_with_button.css('visibility','visible'): $clear_with_button.css('visibility','hidden');
41			$clear_with_button.css( 'right', $search_button.outerWidth() + 'px' );
42		});
43
44		$clear.on("click",function(){
45			this.style = $clear.css('visibility','hidden');
46			$input.value = "";
47		});
48		$clear_with_button.on("click",function(){
49			this.style = $clear_with_button.css('visibility','hidden');
50			$input.value = "";
51		});
52		
53	};
54		/**
55	 * Nav Menu handler Function.
56	 *
57	 */
58	var WidgethfeNavMenuHandler = function( $scope, $ ) {
59
60		if ( 'undefined' == typeof $scope )
61			return;
62		
63		var id = $scope.data( 'id' );
64		var wrapper = $scope.find('.elementor-widget-hfe-nav-menu ');		
65		var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
66		var flyout_data = $( '.elementor-element-' + id + ' .hfe-flyout-wrapper' ).data( 'flyout-class' );
67		var last_item = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'last-item' );
68		var last_item_flyout = $( '.elementor-element-' + id + ' .hfe-flyout-wrapper' ).data( 'last-item' );
69
70		$( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
71
72		_toggleClick( id );
73
74		if( 'horizontal' !== layout ){
75
76			_eventClick( id );
77		}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches ) {
78
79			_eventClick( id );
80		}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
81
82			_eventClick( id );
83		}
84
85		$( '.elementor-element-' + id + ' .hfe-flyout-trigger .hfe-nav-menu-icon' ).off( 'click keyup' ).on( 'click keyup', function() {
86
87			_openMenu( id );
88		} );
89
90		$( '.elementor-element-' + id + ' .hfe-flyout-close' ).off( 'click keyup' ).on( 'click keyup', function() {
91
92			_closeMenu( id );
93		} );
94
95		$( '.elementor-element-' + id + ' .hfe-flyout-overlay' ).off( 'click' ).on( 'click', function() {
96
97			_closeMenu( id );
98		} );	
99
100
101		$scope.find( '.sub-menu' ).each( function() {
102
103			var parent = $( this ).closest( '.menu-item' );
104
105			$scope.find( parent ).addClass( 'parent-has-child' );
106			$scope.find( parent ).removeClass( 'parent-has-no-child' );
107		});
108
109		if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
110			$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().addClass( 'elementor-button-wrapper' );
111			$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).addClass( 'elementor-button' );			
112		}
113
114		_borderClass( id );	
115
116		$( window ).resize( function(){ 
117
118			if( 'horizontal' !== layout ) {
119
120				_eventClick( id );
121			}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches ) {
122
123				_eventClick( id );
124			}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
125
126				_eventClick( id );
127			}
128
129			if( 'horizontal' == layout && window.matchMedia( "( min-width: 977px )" ).matches){
130
131				$( '.elementor-element-' + id + ' div.hfe-has-submenu-container' ).next().css( 'position', 'absolute');	
132			}
133
134			if( 'expandible' == layout || 'flyout' == layout ){
135
136				_toggleClick( id );
137			}else if ( 'vertical' == layout || 'horizontal' == layout ) {
138				if( window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))){
139
140					_toggleClick( id );					
141				}else if ( window.matchMedia( "( max-width: 1024px )" ).matches && $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
142					
143					_toggleClick( id );
144				}
145			}
146
147			_borderClass( id );	
148
149		});
150
151        // Acessibility functions
152
153  		$scope.find( '.parent-has-child .hfe-has-submenu-container a').attr( 'aria-haspopup', 'true' );
154  		$scope.find( '.parent-has-child .hfe-has-submenu-container a').attr( 'aria-expanded', 'false' );
155
156  		$scope.find( '.hfe-nav-menu__toggle').attr( 'aria-haspopup', 'true' );
157  		$scope.find( '.hfe-nav-menu__toggle').attr( 'aria-expanded', 'false' );
158
159  		// End of accessibility functions
160
161		$( document ).trigger( 'hfe_nav_menu_init', id );
162
163		$( '.elementor-element-' + id + ' div.hfe-has-submenu-container' ).on( 'keyup', function(e){
164
165			var $this = $( this );
166
167		  	if( $this.parent().hasClass( 'menu-active' ) ) {
168
169		  		$this.parent().removeClass( 'menu-active' );
170
171		  		$this.parent().next().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
172		  		$this.parent().prev().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
173
174		  		$this.parent().next().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu
174-active' );
175		  		$this.parent().prev().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
176			}else { 
177
178				$this.parent().next().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
179		  		$this.parent().prev().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
180
181		  		$this.parent().next().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
182		  		$this.parent().prev().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
183
184				$this.parent().siblings().find( '.hfe-has-submenu-container a' ).attr( 'aria-expanded', 'false' );
185
186				$this.parent().next().removeClass( 'menu-active' );
187		  		$this.parent().prev().removeClass( 'menu-active' );
188
189				event.preventDefault();
190
191				$this.parent().addClass( 'menu-active' );
192
193				if( 'horizontal' !== layout ){
194					$this.addClass( 'sub-menu-active' );	
195				}
196				
197				$this.find( 'a' ).attr( 'aria-expanded', 'true' );
198
199				$this.next().css( { 'visibility': 'visible', 'opacity': '1', 'height': 'auto' } );
200
201				if ( 'horizontal' !== layout ) {
202						
203		  			$this.next().css( 'position', 'relative');			
204				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
205										
206  					$this.next().css( 'position', 'relative');		  					
207				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
208					
209  					if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
210
211  						$this.next().css( 'position', 'relative');	
212  					} else if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-none') ) {
213  						
214  						$this.next().css( 'position', 'absolute');	
215  					}
216  				}		
217			}
218		});
219
220		$( '.elementor-element-' + id + ' li.menu-item' ).on( 'keyup', function(e){
221			var $this = $( this );
222
223	 		$this.next().find( 'a' ).attr( 'aria-expanded', 'false' );
224	 		$this.prev().find( 'a' ).attr( 'aria-expanded', 'false' );
225	  		
226	  		$this.next().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
227	  		$this.prev().find('ul').css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
228	  		
229	  		$this.siblings().removeClass( 'menu-active' );
230	  		$this.next().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
231		  	$this.prev().find( 'div.hfe-has-submenu-container' ).removeClass( 'sub-menu-active' );
232		  		
233		});
234	};
235
236	function _openMenu( id ) {
237
238		var flyout_content = $( '#hfe-flyout-content-id-' + id );
239		var layout = $( '#hfe-flyout-content-id-' + id ).data( 'layout' );
240		var layout_type = $( '#hfe-flyout-content-id-' + id ).data( 'flyout-type' );
241		var wrap_width = flyout_content.width() + 'px';
242		var container = $( '.elementor-element-' + id + ' .hfe-flyout-container .hfe-side.hfe-flyout-' + layout );
243
244		$( '.elementor-element-' + id + ' .hfe-flyout-overlay' ).fadeIn( 100 );
245
246		if( 'left' == layout ) {
247
248			$( 'body' ).css( 'margin-left' , '0' );
249			container.css( 'left', '0' );
250
251			if( 'push' == layout_type ) {
252
253				$( 'body' ).addClass( 'hfe-flyout-animating' ).css({ 
254					position: 'absolute',
255					width: '100%',
256					'margin-left' : wrap_width,
257					'margin-right' : 'auto'
258				});
259			}	
260
261			container.addClass( 'hfe-flyout-show' );	
262		} else {
263
264			$( 'body' ).css( 'margin-right', '0' );
265			container.css( 'right', '0' );
266
267			if( 'push' == layout_type ) {
268
269				$( 'body' ).addClass( 'hfe-flyout-animating' ).css({ 
270					position: 'absolute',
271					width: '100%',
272					'margin-left' : '-' + wrap_width,
273					'margin-right' : 'auto',
274				});
275			}
276
277			container.addClass( 'hfe-flyout-show' );
278		}		
279	}
280
281	function _closeMenu( id ) {
282
283		var flyout_content = $( '#hfe-flyout-content-id-' + id );
284		var layout    = $( '#hfe-flyout-content-id-' + id ).data( 'layout' );
285		var wrap_width = flyout_content.width() + 'px';
286		var layout_type = $( '#hfe-flyout-content-id-' + id ).data( 'flyout-type' );
287		var container = $( '.elementor-element-' + id + ' .hfe-flyout-container .hfe-side.hfe-flyout-' + layout );
288
289		$( '.elementor-element-' + id + ' .hfe-flyout-overlay' ).fadeOut( 100 );	
290
291		if( 'left' == layout ) {
292
293			container.css( 'left', '-' + wrap_width );
294
295			if( 'push' == layout_type ) {
296
297				$( 'body' ).css({ 
298					position: '',
299					'margin-left' : '',
300					'margin-right' : '',
301				});
302
303				setTimeout( function() {
304					$( 'body' ).removeClass( 'hfe-flyout-animating' ).css({ 
305						width: '',
306					});
307				});
308			}	
309
310			container.removeClass( 'hfe-flyout-show' );					
311		} else {
312			container.css( 'right', '-' + wrap_width );
313			
314			if( 'push' == layout_type ) {
315
316				$( 'body' ).css({
317					position: '',
318					'margin-right' : '',
319					'margin-left' : '',
320				});
321
322				setTimeout( function() {
323					$( 'body' ).removeClass( 'hfe-flyout-animating' ).css({ 
324						width: '',
325					});
326				});
327			}
328			container.removeClass( 'hfe-flyout-show' );
329		}	
330	}
331
332	function _eventClick( id ){
333
334		var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
335
336		$( '.elementor-element-' + id + ' div.hfe-has-submenu-container' ).off( 'click' ).on( 'click', function( event ) {
337
338			var $this = $( this );
339			
340		  	if( $this.hasClass( 'sub-menu-active' ) ) {
341
342		  		if( ! $this.next().hasClass( 'sub-menu-open' ) ) {
343
344		  			$this.find( 'a' ).attr( 'aria-expanded', 'false' );
345
346		  			if( 'horizontal' !== layout ){
347
348						event.preventDefault();
349
350		  				$this.next().css( 'position', 'relative' );	
351					}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
352						
353						event.preventDefault();
354
355		  				$this.next().css( 'position', 'relative' );	
356					}else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches && ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
357						
358						event.preventDefault();	
359
360		  				$this.next().css( 'position', 'relative' );	
361					}	
362	  			
363					$this.removeClass( 'sub-menu-active' );
364					$this.next().removeClass( 'sub-menu-open' );
365					$this.next().css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
366					$this.next().css( { 'transition': 'none'} );										
367		  		}else{
368
369		  			$this.find( 'a' ).attr( 'aria-expanded', 'false' );
370		  			
371		  			$this.removeClass( 'sub-menu-active' );
372					$this.next().removeClass( 'sub-menu-open' );
373					$this.next().css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
374					$this.next().css( { 'transition': 'none'} );	
375						  			  			
376					if ( 'horizontal' !== layout ){
377
378						$this.next().css( 'position', 'relative' );
379					} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
380						
381						$this.next().css( 'position', 'relative' );	
382						
383					} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches && ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
384						
385						$this.next().css( 'position', 'absolute' );				
386					}	  								
387		  		}		  											
388			}else {
389
390					$this.find( 'a' ).attr( 'aria-expanded', 'true' );
391					if ( 'horizontal' !== layout ) {
392						
393						event.preventDefault();
394			  			$this.next().css( 'position', 'relative');			
395					} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
396						
397						event.preventDefault();
398	  					$this.next().css( 'position', 'relative');		  					
399					} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
400						event.preventDefault();
401
402	  					if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
403
404	  						$this.next().css( 'position', 'relative');	
405	  					} else if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-none') ) {
406	  						
407	  						$this.next().css( 'position', 'absolute');	
408	  					}
409	  				}	
410	  					
411				$this.addClass( 'sub-menu-active' );
412				$this.next().addClass( 'sub-menu-open' );	
413				$this.next().css( { 'visibility': 'visible', 'opacity': '1', 'height': 'auto' } );
414				$this.next().css( { 'transition': '0.3s ease'} );								
415			}
416		});
417
418		$( '.elementor-element-' + id + ' .hfe-menu-toggle' ).off( 'click keyup' ).on( 'click keyup',function( event ) {
419
420			var $this = $( this );
421
422		  	if( $this.parent().parent().hasClass( 'menu-active' ) ) {
423
424	  			event.preventDefault();
425
426				$this.parent().parent().removeClass( 'menu-active' );
427				$this.parent().parent().next().css( { 'visibility': 'hidden', 'opacity': '0', 'height': '0' } );
428
429				if ( 'horizontal' !== layout ) {
430						
431		  			$this.parent().parent().next().css( 'position', 'relative');			
432				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
433										
434  					$this.parent().parent().next().css( 'position', 'relative');		  					
435				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
436					
437  					if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
438
439  						$this.parent().parent().next().css( 'position', 'relative');	
440  					} else if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-none') ) {
441  						
442  						$this.parent().parent().next().css( 'position', 'absolute');	
443  					}
444  				}
445			}else { 
446
447				event.preventDefault();
448
449				$this.parent().parent().addClass( 'menu-active' );
450
451				$this.parent().parent().next().css( { 'visibility': 'visible', 'opacity': '1', 'height': 'auto' } );
452
453				if ( 'horizontal' !== layout ) {
454						
455		  			$this.parent().parent().next().css( 'position', 'relative');			
456				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 767px )" ).matches && ($( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile'))) {
457										
458  					$this.parent().parent().next().css( 'position', 'relative');		  					
459				} else if ( 'horizontal' === layout && window.matchMedia( "( max-width: 1024px )" ).matches ) {
460					
461  					if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
462
463  						$this.parent().parent().next().css( 'position', 'relative');	
464  					} else if ( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-none') ) {
465  						
466  						$this.parent().parent().next().css( 'position', 'absolute');	
467  					}
468  				}		
469			}
470		});
471	}
472
473	function _borderClass( id ){
474
475		var last_item = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'last-item' );
476		var last_item_flyout = $( '.elementor-element-' + id + ' .hfe-flyout-wrapper' ).data( 'last-item' );
477		var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
478
479		$( '.elementor-element-' + id + ' nav').removeClass('hfe-dropdown');
480
481		if ( window.matchMedia( "( max-width: 767px )" ).matches ) {
482
483			if( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-mobile') || $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet')){
484				
485				$( '.elementor-element-' + id + ' nav').addClass('hfe-dropdown');
486				if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
487					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().removeClass( 'elementor-button-wrapper' );
488					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).removeClass( 'elementor-button' );	
489				}	
490			}else{
491				
492				$( '.elementor-element-' + id + ' nav').removeClass('hfe-dropdown');
493				if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
494					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().addClass( 'elementor-button-wrapper' );
495					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).addClass( 'elementor-button' );	
496				}
497			}
498		}else if ( window.matchMedia( "( max-width: 1024px )" ).matches ) {
499
500			if( $( '.elementor-element-' + id ).hasClass('hfe-nav-menu__breakpoint-tablet') ) {
501				
502				$( '.elementor-element-' + id + ' nav').addClass('hfe-dropdown');
503				if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
504					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().removeClass( 'elementor-button-wrapper' );
505					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).removeClass( 'elementor-button' );	
506				}
507			}else{
508				
509				$( '.elementor-element-' + id + ' nav').removeClass('hfe-dropdown');
510				if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
511					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().addClass( 'elementor-button-wrapper' );
512					$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).addClass( 'elementor-button' );
513				}
514			}
515		}
516
517		var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
518		if( 'expandible' == layout ){
519			if( ( 'cta' == last_item || 'cta' == last_item_flyout ) && 'expandible' != layout ){
520				$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).parent().removeClass( 'elementor-button-wrapper' );
521				$( '.elementor-element-' + id + ' li.menu-item:last-child a.hfe-menu-item' ).removeClass( 'elementor-button' );			
522			}			
523		}
524	}
525
526	function _toggleClick( id ){
527
528		if ( $( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).hasClass( 'hfe-active-menu-full-width' ) ){
529
530			$( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).next().css( 'left', '0' );
531
532			var width = $( '.elementor-element-' + id ).closest('.elementor-section').outerWidth();
533			var sec_pos = $( '.elementor-element-' + id ).closest('.elementor-section').offset().left - $( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).next().offset().left;
534			$( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).next().css( 'width', width + 'px' );
535			$( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).next().css( 'left', sec_pos + 'px' );
536		}
537
538		$( '.elementor-element-' + id + ' .hfe-nav-menu__toggle' ).off( 'click keyup' ).on( 'click keyup', function( event ) {
539
540			var $this = $( this );
541			var $selector = $this.next();
542
543			if ( $this.hasClass( 'hfe-active-menu' ) ) {
544
545				var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
546				var full_width = $selector.data( 'full-width' );
547				var toggle_icon = $( '.elementor-element-' + id + ' nav' ).data( 'toggle-icon' );
548
549				$( '.elementor-element-' + id).find( '.hfe-nav-menu-icon' ).html( toggle_icon );
550
551				$this.removeClass( 'hfe-active-menu' );
552				$this.attr( 'aria-expanded', 'false' );
553				
554				if ( 'yes' == full_width ){
555
556					$this.removeClass( 'hfe-active-menu-full-width' );
557				
558					$selector.css( 'width', 'auto' );
559					$selector.css( 'left', '0' );
560					$selector.css( 'z-index', '0' );
561				}				
562			} else {
563
564				var layout = $( '.elementor-element-' + id + ' .hfe-nav-menu' ).data( 'layout' );
565				var full_width = $selector.data( 'full-width' );
566				var close_icon = $( '.elementor-element-' + id + ' nav' ).data( 'close-icon' );
567
568				$( '.elementor-element-' + id).find( '.hfe-nav-menu-icon' ).html( close_icon );
569				
570				$this.addClass( 'hfe-active-menu' );
571				$this.attr( 'aria-expanded', 'true' );
572
573				if ( 'yes' == full_width ){
574
575					$this.addClass( 'hfe-active-menu-full-width' );
576
577					var width = $( '.elementor-element-' + id ).closest('.elementor-section').outerWidth();
578					var sec_pos = $( '.elementor-element-' + id ).closest('.elementor-section').offset().left - $selector.offset().left;
579				
580					$selector.css( 'width', width + 'px' );
581					$selector.css( 'left', sec_pos + 'px' );
582					$selector.css( 'z-index', '9999' );
583				}
584			}
585
586			if( $( '.elementor-element-' + id + ' nav' ).hasClass( 'menu-is-active' ) ) {
587
588				$( '.elementor-element-' + id + ' nav' ).removeClass( 'menu-is-active' );
589			}else {
590
591				$( '.elementor-element-' + id + ' nav' ).addClass( 'menu-is-active' );
592			}				
593		} );
594	}
595
596	$( window ).on( 'elementor/frontend/init', function () {
597
598		elementorFrontend.hooks.addAction( 'frontend/element_ready/navigation-menu.default', WidgethfeNavMenuHandler );
599		elementorFrontend.hooks.addAction( 'frontend/element_ready/hfe-search-button.default', WidgethfeSearchButton );
600	});
601} )( jQuery );

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.