PageSourceSearch

https://www.unitedsportsflag.com/DesktopModules/DDRMenu/4colmegamenu/4colmegamenu.js

js unitedsportsflag.com collected 2026-09-29 01:00:41 UTC 4,091 bytes, 146 lines download raw bytes

1var $doc = jQuery(document);
2var $win = jQuery(window);
3
4$doc.ready(function () {
5
6	/* MouseIn Function */
7	/************************************/
8	function HoverOver() { 
9
10		var $this = jQuery(this),
11			$col = jQuery("li.col", $this)
12			$dialog = jQuery(">.dropdown", $this); 
13			$winWidth = $win.width(); 
14		
15		$dialog.css({ "visibility":"hidden", "display":"block", "left":"auto", "right":"auto"});
16		
17		var $position = parseInt($dialog.offset().left + $dialog.outerWidth());
18
19		if ( $col.length > 0 ){
20			$dialog.css({ "visibility":"hidden", "display":"block","top":"auto","left":"auto","right":"auto", "width": "auto" });
21			var reqHeight = 0,
22				reqWidth = 0;
23			for ( i=0; i < $col.length; i++ ){
24				var $currentItem = jQuery($col[i]);
25				if ( reqHeight < $currentItem.outerHeight(true) ){
26					reqHeight = $currentItem.outerHeight(true);
27				}
28				reqWidth += $currentItem.outerWidth(true);
29				if ( i == ($col.length - 1) ){
30					$col.height(reqHeight);
31					$dialog.width(reqWidth + 1);
32				}
33			}
34		}
35
36		if ($dialog.find(".m0") && $winWidth < $position){
37			$dialog.css({"left": "-" + ($position - $winWidth) + "px" } );
38		}
39		
40		if(!$dialog.hasClass("normalNav")){
41			$dialog.width($winWidth).css({left: "-" + $this.offset().left + "px" });
42		}
43
44		$this.addClass("exp");
45		$dialog.css({ "display": "none","visibility": "visible" });
46		$dialog.slideDown("fast");
47
48	}
49
50	/* MouseOut Function */
51	/************************************/
52	function HoverOut() { 
53		var $this = jQuery(this);
54		$this.find("> .dropdown").slideUp("fast", function(){
55			$this.removeClass("exp");
56		});
57	}
58
59	/* HoverIntent Config */
60	/************************************/
61	var config = {
62		sensitivity: 2,
63		interval: 200,
64		over: HoverOver,
65		timeout: 500,
66		out: HoverOut
67	};// HoverIntent Setting
68
69	/* Menu HoverIntent Call */
70	/************************************/
71	jQuery("#dnnStandardMenu li.root.haschild > .m").each( function(){
72		var $wrapper = jQuery(this);
73		var columnCount = 4;
74		if ( $win.width() < 980 ) { columnCount = 3; }
75		if ( $wrapper.children().length <= columnCount ){
76			$wrapper.wrap("<div class=\"dropdown normalNav\"></div>");
77		} else {
78
79			for(var i=1; i <= columnCount; i++){ 
80				var condition = "";
81				if (i===1){ condition = " first" }
82				$wrapper.append("<li class='col" + condition + "'><ul class='col"+i+"'></ul></li>"); 
83			}
84
85			var counter = 1;
86			jQuery(".mi1", $wrapper).each( function(){
87				jQuery(".col"+counter, $wrapper).append(jQuery(this));
88				counter++;
89				if(counter > columnCount)counter=1;
90			});
91
92			$wrapper.wrap("<div class=\"dropdown\"></div>");
93		}
94		$wrapper.show();
95
96	});
97
98	if( jQuery(window).width() > 640){
99
100		/* Selected Item Flow */
101		/************************************/
102		jQuery("#dnnStandardMenu li.haschild").not(".mi1").hoverIntent(config);// Call HoverIntent on mouse over
103
104		if( /Android|webOS|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent) ){
105			jQuery("#dnnStandardMenu").addClass("OnTouchDevice");
106
107			var i, len, element,
108				dropdowns = document.querySelectorAll("#dnnStandardMenu li.haschild > a");
109
110			function menuTouch(event) {
111				// toggle flag for preventing click for this link
112				var i, len, noclick = !(this.dataNoclick);
113
114				// reset flag on all links
115				for (i = 0, len = dropdowns.length; i < len; ++i) {
116					dropdowns[i].dataNoclick = false;
117				}
118
119				// set new flag value and focus on dropdown menu
120				this.dataNoclick = noclick;
121				this.focus();
122			}
123
124			function menuClick(event) {
125				// if click isn't wanted, prevent it
126				if (this.dataNoclick) {
127					event.preventDefault();
128				}
129			}
130
131			for (i = 0, len = dropdowns.length; i < len; ++i) {
132				element = dropdowns[i];
133				element.dataNoclick = false;
134				element.addEventListener("touchstart", menuTouch, false);
135				element.addEventListener("click", menuClick, false);
136			}
137
138		}
139	} else {
140		jQuery(".mobNavLink").click( function(){
141			jQuery(".skin-nav").slideToggle();
142		});
143	}
144
145
146});

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.