PageSourceSearch

https://www.beag-agrar.de/wp-content/themes/master/js/site.js

js beag-agrar.de collected 2026-10-06 18:23:11 UTC 2,687 bytes, 114 lines download raw bytes

1function isTouch(){
2    return navigator.userAgent.match(/(iPhone|iPod|iPad|blackberry|android|Kindle|htc|lg|midp|mmp|mobile|nokia|opera mini|palm|pocket|psp|sgh|smartphone|symbian|treo mini|Playstation Portable|SonyEricsson|Samsung|MobileExplorer|PalmSource|Benq|Windows Phone|Windows Mobile|IEMobile|Windows CE|Nintendo Wii)/i);
3}
4
5var $is_touch = false;
6if (isTouch()) {
7	$is_touch = true;
8}
9
10$(document).ready(function() {
11	vs.init();
12});
13
14var $nav_break = 768;
15var vs = {
16	init: function(){
17		
18		this.initNav();
19		
20		$(window).trigger('resize');
21		
22		var ua = navigator.userAgent.toLowerCase();
23		
24		if (ua.indexOf("msie ") > 0 || /(iphone|ipod|ipad).*os 8_/.test(ua)) {
25			$('html').addClass('oldbrowser');
26		}
27	},
28	
29	
30
31	initNav: function() {
32		
33		$('nav.main > ul > li > a').click(function(){
34			if ($(this).parent('li').find('ul').length) {
35				if ($(window).width() < $nav_break) {
36					if ($(this).parent('li').hasClass('open')) {
37						$(this).parent('li').removeClass('open');
38						$(this).parent('li').find('ul').slideUp();
39					} else {
40						$(this).parent('li').addClass('open');
41						$(this).parent('li').find('ul').slideDown();
42					}
43				}
44				if ($is_touch) {
45					return false;
46				}
47			}
48		});
49		
50		$('.mobile_menu_btn').click(function(){
51			
52			if ($(this).hasClass('mobile_menu_btn_close')) {
53				$(this).removeClass('mobile_menu_btn_close');
54				$('.header_content').removeClass('header_content_open');
55				
56				$('body,html').css({
57					overflow: ''
58				});
59			} else {
60				$(this).addClass('mobile_menu_btn_close');
61				$('.header_content').addClass('header_content_open');
62				
63				$('body,html').css({
64					overflow: 'hidden'
65				});
66			}
67			
68			return false;
69		});
70		
71		$('.open_account_navi').click(function(){
72			$(this).toggleClass('account_navi_open');
73			$('.account_navi').slideToggle();
74			
75			if ($(this).hasClass('account_navi_open')) {
76				$('.navi_overlay').fadeIn();
77			} else {
78				$('.navi_overlay').fadeOut();
79			}
80		});
81		
82		$('nav.main > ul > li').hover(function(){
83			if ($(this).find('ul').length) {
84				$('.navi_overlay').stop(true,true).delay(200).fadeIn();
85			}
86		}, function(){
87			$('.navi_overlay').delay(200).fadeOut();
88		});
89		
90		$('.navi_overlay').on('touchstart', function(){
91			$('.navi_overlay').fadeOut();
92		});
93		
94		if (!$is_touch) {
95			$('.touch_only').remove();
96		}
97		
98		$('.navi_overlay').click(function(){
99			$('.open_account_navi').removeClass('account_navi_open');
100			$('.account_navi').slideUp();
101			$('.navi_overlay').fadeOut();
102		});
103	}
104
105}
106
107	$(window).scroll(function() {
108 if ($(this).scrollTop() > 140){  
109    $('.landingpage').addClass("sticky");
110  }
111  else{
112    $('.landingpage').removeClass("sticky");
113  }
114});

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.