PageSourceSearch

https://crystalclearfinances.com/wp-content/themes/CCF-2014/js/lib/expand-nav.js?ver=1.0

js crystalclearfinances.com collected 2026-10-06 13:14:53 UTC 2,141 bytes, 47 lines download raw bytes

1jQuery(document).ready(function($){
2	var $lateral_menu_trigger = $('#cd-menu-trigger'),
3		$content_wrapper = $('.site-wrap'),
4		$navigation = $('.nav-wrap');
5
6	//open-close lateral menu clicking on the menu icon
7	$lateral_menu_trigger.on('click', function(event){
8		event.preventDefault();
9
10		$lateral_menu_trigger.toggleClass('is-clicked');
11		$navigation.toggleClass('lateral-menu-is-open');
12		$('body').toggleClass('overflow-hidden');
13		$content_wrapper.toggleClass('lateral-menu-is-open').one('webkitTransitionEnd otransitionend oTransitionEnd msTransitionEnd transitionend', function(){
14			// firefox transitions break when parent overflow is changed, so we need to wait for the end of the trasition to give the body an overflow hidden
15			$('body').toggleClass('overflow-hidden');
16		});
17		$('#cd-lateral-nav').toggleClass('lateral-menu-is-open');
18		
19		//check if transitions are not supported - i.e. in IE9
20		if($('html').hasClass('no-csstransitions')) {
21			$('body').toggleClass('overflow-hidden');
22		}
23	});
24
25	//close lateral menu clicking outside the menu itself
26	$content_wrapper.on('click', function(event){
27		if( !$(event.target).is('#cd-menu-trigger, #cd-menu-trigger span') ) {
28			$lateral_menu_trigger.removeClass('is-clicked');
29			$navigation.removeClass('lateral-menu-is-open');
30			$content_wrapper.removeClass('lateral-menu-is-open').one('webkitTransitionEnd otransitionend oTransitionEnd msTransitionEnd transitionend', function(){
31				$('body').removeClass('overflow-hidden');
32			});
33			$('#cd-lateral-nav').removeClass('lateral-menu-is-open');
34			//check if transitions are not supported
35			if($('html').hasClass('no-csstransitions')) {
36				$('body').removeClass('overflow-hidden');
37			}
38
39		}
40	});
41
42	//open (or close) submenu items in the lateral menu. Close all the other open submenu items.
43	$('.menu-item-has-children').children('a').on('click', function(event){
44		event.preventDefault();
45		$(this).toggleClass('submenu-open').next('.sub-menu').slideToggle(200).end().parent('.menu-item-has-children').siblings('.menu-item-has-children').children('a').removeClass('submenu-open').next('.sub-menu').slideUp(200);
46	});
47});

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.