PageSourceSearch

https://www.monteroza.co.jp/wp-content/themes/mnt/js/portal_top.js?v=20220407

js monteroza.co.jp collected 2026-10-02 03:52:00 UTC 6,031 bytes, 188 lines download raw bytes

1$(function() {
2	$('.toggle_switch').click(function() {
3		$('nav').slideToggle();
4		$('header').toggleClass('active');
5	});
6});
7
8
9$(function () {
10	var ua = navigator.userAgent;
11	if ((ua.indexOf('iPhone') > 0 || ua.indexOf('Android') > 0) && ua.indexOf('Mobile') > 0) {
12		// sp start
13		$(document).ready(function () {
14
15			var changeMenuSize = function() {
16				$('.portal_view_area').css('height',350);
17			};
18
19			var setAsideMinHeight = function() {
20				$('.portal_view_area').css('height',350);
21			};
22
23			var setViewPortHeight = function() {
24				$('html').css('--vh',  '' + window.innerHeight * 0.01 + 'px');
25			};
26
27			window.addEventListener("orientationchange", function() {
28				isResize = true;
29				var latitude = map.getLatLon().lat;
30				var longitude = map.getLatLon().lon;
31				var zoomLevel = map.getZoom();
32				setAsideMinHeight();
33				setViewPortHeight();
34				changeMenuSize();
35				setCurrentButton();
36				loadMap("#ZDCmap", DEFAULT_MAPTYPE, latitude, longitude, zoomLevel);
37			});
38
39			var setCurrentButton = function() {
40				var h1 = $('.portal_header').outerHeight();
41				var h2 = $('.portal_pr_area').outerHeight();
42				var h3 = $('.portal_view_area').outerHeight();;
43				var currentButtonPosition = h1 + h2 - 95;
44				$("#current_location_button").css("top", currentButtonPosition);
45			}
46
47			setAsideMinHeight();
48			setViewPortHeight();
49			changeMenuSize();
50			setCurrentButton();
51
52			loadMap("#ZDCmap", DEFAULT_MAPTYPE, DEFAULT_LOCATION.lat, DEFAULT_LOCATION.lon, DEFAULT_ZOOM);
53		});
54
55		// sp end
56	} else if (ua.indexOf('iPad') > 0 || ua.indexOf('Android') > 0) {
57		// tab start
58		$(document).ready(function () {
59
60			var h1 = $('.portal_header').outerHeight();
61			var h2 = $('.portal_pr_area').outerHeight();
62			var h3 = $('.refine_box').outerHeight();
63			var hh = h1 + h2 + h3;
64
65			var changeMenuSize = function() {
66				var ah = $(window).height();
67				var menu_height = ah - hh;
68				$('.store_box').css('height',menu_height);
69			};
70
71			var setAsideMinHeight = function() {
72				var ah = $(window).height();
73				var menu_height = ah - hh;
74				$('.store_box').css('height',menu_height);
75			};
76
77			var setViewPortHeight = function() {
78				$('html').css('--vh',  '' + window.innerHeight * 0.01 + 'px');
79			};
80
81			$(window).resize(function() {
82				isResize = true;
83				var latitude = map.getLatLon().lat;
84				var longitude = map.getLatLon().lon;
85				var zoomLevel = map.getZoom();
86				setAsideMinHeight();
87				setViewPortHeight();
88				changeMenuSize();
89				loadMap("#ZDCmap", DEFAULT_MAPTYPE, latitude, longitude, zoomLevel);
90			});
91
92			setAsideMinHeight();
93			setViewPortHeight();
94			changeMenuSize();
95			loadMap("#ZDCmap", DEFAULT_MAPTYPE, DEFAULT_LOCATION.lat, DEFAULT_LOCATION.lon, DEFAULT_ZOOM);
96		});
97		// tab end
98	} else {
99		// pc start
100		$(document).ready(function () {
101
102			var h1 = $('.portal_header').outerHeight();
103			var h2 = $('.portal_pr_area').outerHeight();
104			var h3 = $('.refine_box').outerHeight();
105			var h4 = $('.portal_search_area').outerHeight();
106			var h5 = $('#home_map_h').outerHeight();
107			var hh = h1 + h2 + h3 + h4;
108
109			var changeMenuSize = function() {
110				var ah = $(window).height();
111				var menu_height = ah - hh;
112				$('.store_box').css('height',menu_height);
113			};
114
115			var setAsideMinHeight = function() {
116				var ah = $(window).height();
117				var menu_height = ah - hh;
118				$('.store_box').css('height',menu_height);
119			};
120
121			var setViewPortHeight = function() {
122				$('html').css('--vh',  '' + window.innerHeight * 0.01 + 'px');
123			};
124
125			// current button for IE
126			htmlCurentButton = '<div onClick="getUserLocation();" style="position: absolute; bottom: 35px; right: 5px; z-index: 999;" id="current_location_button">'
127				+ '<img src="./wp-content/themes/mnt/img/portal/map_arrow.svg" alt="" class="map_arrow">'
128				+ '</div>';
129
130			// fix bug input search 
131			var paddingInput = $(".search_btn").outerWidth();
132			$("#search_input").css("padding-right",paddingInput);
133			$(window).resize(function() {
134				isResize = true;
135				var latitude = map.getLatLon().lat;
136				var longitude = map.getLatLon().lon;
137				var zoomLevel = map.getZoom();
138				setAsideMinHeight();
139				setViewPortHeight();
140				changeMenuSize();
141				var msie = ua.indexOf("MSIE ");
142				// If ie browser
143				if (msie > 0 || !!navigator.userAgent.match(/Trident.*rv\:11\./))  // If Internet Explorer, return version number
144				{
145					var ah = $(window).height();
146					var mapHeight = ah - h1 - h2 -h3 - h4;
147					var mapWidth =  $(window).width() - $(".portal_list_area").outerWidth();
148					$('#ZDCmap').css('display','none');
149					$('main').css('height', mapHeight);
150					$('.portal_view_area').css('height', mapHeight);
151					$('.portal_view_area').css('width', mapWidth);
152					loadMap("#IEZDCmap", DEFAULT_MAPTYPE, latitude, longitude, zoomLevel);
153					$("#IEZDCmap").append(htmlCurentButton);
154				}
155				else  // If another browser,
156				{
157					loadMap("#ZDCmap", DEFAULT_MAPTYPE, latitude, longitude, zoomLevel);
158				}
159			});
160
161			setAsideMinHeight();
162			setViewPortHeight();
163			changeMenuSize();
164			var msie = ua.indexOf("MSIE ");
165			// If ie browser
166			if (msie > 0 || !!navigator.userAgent.match(/Trident.*rv\:11\./))  // If Internet Explorer, return version number
167			{
168				var ah = $(window).height();
169				var mapHeight = ah - h1 - h2 -h3 - h4;
170				var mapWidth =  $(window).width() - $(".portal_list_area").outerWidth();
171				$('#ZDCmap').css('display','none');
172				$('main').css('height', mapHeight);
173				$('.portal_view_area').css('height', mapHeight + 140);
174				$('.portal_view_area').css('width', mapWidth);
175				loadMap("#IEZDCmap", DEFAULT_MAPTYPE, DEFAULT_LOCATION.lat, DEFAULT_LOCATION.lon, DEFAULT_ZOOM);
176				$("#IEZDCmap").append(htmlCurentButton);
177			}
178			else  // If another browser,
179			{
180				loadMap("#ZDCmap", DEFAULT_MAPTYPE, DEFAULT_LOCATION.lat, DEFAULT_LOCATION.lon, DEFAULT_ZOOM);
181			}
182		});
183		// pc end
184	}
185})
186
187
188

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.