PageSourceSearch

https://www.navicat.com.cn/templates/Navicat/js/function.js?v=20260923

js navicat.com.cn collected 2026-10-02 06:53:54 UTC 92,409 bytes, 2,153 lines download raw bytes

1function getOS() {
2	var OSName = "W";
3	if (window.navigator.userAgent.indexOf("Windows NT 10.0") != -1) OSName = "W";
4	if (window.navigator.userAgent.indexOf("Windows NT 6.2") != -1) OSName = "W";
5	if (window.navigator.userAgent.indexOf("Windows NT 6.1") != -1) OSName = "W";
6	if (window.navigator.userAgent.indexOf("Windows NT 6.0") != -1) OSName = "W";
7	if (window.navigator.userAgent.indexOf("Windows NT 5.1") != -1) OSName = "W";
8	if (window.navigator.userAgent.indexOf("Windows NT 5.0") != -1) OSName = "W";
9	if (window.navigator.userAgent.indexOf("Mac") != -1) OSName = "M";
10	if (window.navigator.userAgent.indexOf("X11") != -1) OSName = "L";
11	if (window.navigator.userAgent.indexOf("Linux") != -1) OSName = "L";
12	return OSName;
13}
14
15function setCookie(cname, cvalue, exdays) {
16	var d = new Date();
17	d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));
18	var expires = "expires=" + d.toUTCString();
19	document.cookie = cname + "=" + cvalue + ";" + expires + ";path=/";
20}
21
22function getCookie(name) {
23  const value = `; ${document.cookie}`;
24  const parts = value.split(`; ${name}=`);
25  if (parts.length === 2) return decodeURIComponent(parts.pop().split(';').shift());
26  return null;
27}
28
29function selectPlatformTab() {
30	var OS = location.hash.substr(1);
31	if (OS == "" && getCookie('platform') !== null) {
32		OS = getCookie('platform');
33	}
34	if (OS == "") {
35		OS = getOS();
36	}
37	return OS[0];
38}
39
40function getProductBannerClassName(product) {
41	switch(true) {
42		case product.includes("premium") && product.includes("lite"):
43			return "navicat-essentials-banner";
44		case product.includes("premium"):
45			return "navicat-premium-banner";
46		case product.includes("mysql"):
47			return "navicat-mysql-banner";
48		case product.includes("pgsql"):
49			return "navicat-postgresql-banner";
50		case product.includes("mongodb"):
51			return "navicat-mongodb-banner";
52		case product.includes("mariadb"):
53			return "navicat-mariadb-banner";
54		case product.includes("sqlserver"):
55			return "navicat-sqlserver-banner";
56		case product.includes("ora"):
57			return "navicat-oracle-banner";
58		case product.includes("sqlite"):
59			return "navicat-sqlite-banner";
60		case product.includes("redis"):
61			return "navicat-redis-banner";
62		case product.includes("snowflake"):
63			return "navicat-snowflake-banner";
64		case product.includes("navicatdatamodeler") && product.includes("lite"):
65			return "navicat-modeler-essentials-banner";
66		case product.includes("navicatdatamodeler"):
67			return "navicat-modeler-banner";
68		case product.includes("navicatbiviewer"):
69			return "navicat-charts-viewer-banner";
70		case product.includes("navicatbi"):
71			return "navicat-charts-creator-banner";
72		case product.includes("navicatonpremserver"):
73			return "navicat-on-prem-server-banner";
74		case product.includes("navicatmonitor"):
75			return "navicat-monitor-banner";
76		default:
77			return "navicat-premium-banner";;
78	}
79}
80
81function getProductCode(product, os, edition, language) {
82	var code = "";
83	code = code + product + "-" + os + edition + language + "-ESD";
84	return code;
85}
86
87function isPositiveInteger(n) {
88	return 0 === n % (!isNaN(parseFloat(n)) && 0 <= ~~n);
89}
90
91function releaseNotesOSControl() {
92	var OS = location.hash.substr(1);
93	if (OS == "") {
94		OS = getOS();
95	}
96
97	jQuery(".release-notes-ver").removeClass("selected");
98	if (OS == "W") {
99		jQuery("#win-ver").addClass("selected");
100	} else if (OS == "M") {
101		jQuery("#mac-ver").addClass("selected");
102	} else if (OS == "L") {
103		jQuery("#lin-ver").addClass("selected");
104	} else {
105		jQuery("#win-ver").addClass("selected");
106		OS = "W"
107	}
108	jQuery(".release-notes-table").hide();
109	jQuery(".release-notes-table[platform='" + OS + "']").show();
110
111	jQuery(".release-notes-ver").click(function () {
112		var btn = jQuery(this);
113		btn.siblings().removeClass("selected");
114		btn.addClass("selected");
115		location.hash = btn.attr("platform");
116		jQuery(".release-notes-table").hide();
117		jQuery(".release-notes-table[platform='" + btn.attr('platform') + "']").show();
118	});
119
120}
121
122function roundDp(floatValue, dp, preferFloatString) {
123	var factor = Math.pow(10, dp);
124	var ret = Math.round((+floatValue + 1e-15) * factor) / factor;  // Special case: 1.005 * 100 = 100.49999999999999.  Thus, round 1.005 to 2 d.p. gives 1 instead of 1.01.  + 1e-15 (optional) solves this.  Not work for 55.555, 555.555 etc.
125	if (preferFloatString !== false) {
126		ret = ret.toFixed(2);
127		/*if (factor >= 10 && ret.search(/^[+-]?\d+$/) != -1)  // no floating point -> add ".0" for float string representation like in Ruby's round(n) when n > 0
128		  ret += ".00";*/
129	}
130
131	return ret.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
132	//return ret;
133};
134
135function getUrlVars() {
136	var vars = [], hash;
137	var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
138	for (var i = 0; i < hashes.length; i++) {
139		hash = hashes[i].split('=');
140		vars.push(hash[0]);
141		vars[hash[0]] = hash[1];
142	}
143	return vars;
144}
145
146function productInfoScript(data = []) {
147	var isOprem = jQuery(".info-container").hasClass("on-prem-product-info");
148	var OS = location.hash.substr(1);
149	if (OS == "") {
150		OS = getOS();
151	}
152	var classNameOS = [".Windows-container", ".Mac-container", ".Linux-container"];
153	var lang = "_CN";
154
155	jQuery(".info-switcher-in3-container .info-switcher-in3, .info-switcher-in4-container .info-switcher-in4").removeClass("selected");
156	jQuery(".info-content.Linux-container, .info-content.Mac-container, .info-content.Windows-container").hide();
157	if (OS == "L") {
158		jQuery(".info-switcher-in3-container .info-switcher-in3[os='linux'], .info-switcher-in4-container .info-switcher-in4[os='linux']").addClass("selected");
159		jQuery(".Linux-container").show();
160		jQuery(".Linux-container").addClass("platform-selected");
161	} else if (OS == "M") {
162		jQuery(".info-switcher-in3-container .info-switcher-in3[os='mac'], .info-switcher-in4-container .info-switcher-in4[os='mac']").addClass("selected");
163		jQuery(".Mac-container").show();
164		jQuery(".Mac-container").addClass("platform-selected");
165	} else {
166		jQuery(".info-switcher-in3-container .info-switcher-in3[os='win'], .info-switcher-in4-container .info-switcher-in4[os='win']").addClass("selected");
167		jQuery(".Windows-container").show();
168		jQuery(".Windows-container").addClass("platform-selected");
169	}
170
171	jQuery(".product-info-switcher").click(function () {
172		var ele = jQuery(this);
173		ele.siblings().removeClass("selected");
174		ele.addClass("selected");
175		jQuery(".product-info-features-content").hide();
176		jQuery(".product-info-features-content." + ele.attr("os")).show();
177	});
178
179	jQuery(".product-info-screenshot-number div").click(function () {
180		var ele = jQuery(this);
181		ele.parent().siblings().removeClass("selected");
182		ele.parent().addClass("selected");
183		jQuery(this).parent().parent().parent().find(".product-info-screenshot").removeClass("show");
184		jQuery(".product-info-screenshot[index='" + ele.attr("index") + "']").addClass("show");
185	});
186
187	for (let i = 0; i < classNameOS.length; i++) {
188		jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div > div:not(.product-info-screenshot-title-v17-dot-container)").click(function () {
189			let index = jQuery(this).attr("index") - 1;
190			jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div").removeClass("selected").find("> div").removeClass("selected");
191			jQuery(this).addClass("selected").parent().addClass("selected");
192			updateScreenshotByIndex(index, classNameOS[i])
193		});
194		jQuery(classNameOS[i] + " .product-info-screenshot-button-v17-back").click(function () {
195			let index = jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div > div.selected").attr("index") - 1;
196			if (index != 0) {
197				index--;
198				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div").removeClass("selected").find("> div").removeClass("selected");
199				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div> div > div[index='" + (index + 1) + "']").addClass("selected").parent().addClass("selected");
200				updateScreenshotByIndex(index, classNameOS[i]);
201			}
202			if (index <= 0) {
203				jQuery(this).css("opacity", 0.5);
204			} else {
205				jQuery(this).css("opacity", 1);
206			}
207			jQuery(classNameOS[i] + " .product-info-screenshot-button-v17-next").css("opacity", 1);
208		});
209		jQuery(classNameOS[i] + " .product-info-screenshot-button-v17-next").click(function () {
210			let index = jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div> div.selected").attr("index") - 1;
211			let count = data.length;
212			if (index < count - 1) {
213				index++;
214				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div").removeClass("selected").find("> div").removeClass("selected");
215				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17 > div > div > div[index='" + (index + 1) + "']").addClass("selected").parent().addClass("selected");
216				updateScreenshotByIndex(index, classNameOS[i]);
217			}
218			if (index >= count - 1) {
219				jQuery(this).css("opacity", 0.5);
220			} else {
221				jQuery(this).css("opacity", 1);
222			}
223			jQuery(classNameOS[i] + " .product-info-screenshot-button-v17-back").css("opacity", 1);
224		});
225		jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-back").click(function () {
226			let page = jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column.selected").attr("page");
227			page--;
228			if (page != 0) {
229				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column").removeClass("selected");
230				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column[page='" + page + "']").addClass("selected");
231			}
232		});
233		jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-next").click(function () {
234			let page = jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column.selected").attr("page");
235			page++;
236			if (page <= 3) {
237				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column").removeClass("selected");
238				jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column[page='" + page + "']").addClass("selected");
239			}
240		});
241		jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-dot").click(function () {
242			let page = jQuery(this).attr("page");
243			jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column").removeClass("selected");
244			jQuery(classNameOS[i] + " .product-info-screenshot-title-v17-column[page='" + page + "']").addClass("selected");
245		});
246	}
247
248	if (!isOprem) {
249		for (let i = 0; i < data.length; i++) {
250			if (data[i].product === "17_Data_Dictionary") {
251				preloadImage("/images/product_screenshot/Screenshot_Navicat_" + data[i].product + "_CN.png")
252			} else {
253				preloadImage("/images/product_screenshot/Screenshot_Navicat_" + data[i].product + "_Windows" + data[i].image + "_CN.png")
254				preloadImage("/images/product_screenshot/Screenshot_Navicat_" + data[i].product + "_Mac" + data[i].image + "_CN.png")
255				preloadImage("/images/product_screenshot/Screenshot_Navicat_" + data[i].product + "_Linux" + data[i].image + "_CN.png")
256			}
257		}
258	}
259
260	function updateScreenshotByIndex(index, className) {
261		if (isOprem) {
262			if (index === 9) {
263				jQuery(className + " .product-info-screenshot-v17 p").hide();
264				jQuery(className + " .product-info-screenshot-v17 .screenshot").hide();
265				jQuery(".on-prem-product-info-supported-container").show();
266				jQuery(".on-prem-product-info-supported").on("scroll", function () {
267					if (jQuery(this).scrollTop() === jQuery(".on-prem-product-info-supported-list:first-child").outerHeight() + jQuery(".on-prem-product-info-supported-list:nth-child(2)").outerHeight() - 320) {
268						jQuery(".on-prem-product-info-supported-list-arrow-up").show();
269						jQuery(".on-prem-product-info-supported-list-arrow-down").hide();
270					} else {
271						jQuery(".on-prem-product-info-supported-list-arrow-up").hide();
272						jQuery(".on-prem-product-info-supported-list-arrow-down").show();
273					}
274				});
275				jQuery(window).on("resize", function () {
276					var windoWidth = jQuery(window).width();
277					if (windoWidth > 766) {
278						jQuery(".on-prem-product-info-supported-list-arrow-up").hide();
279						jQuery(".on-prem-product-info-supported-list-arrow-down").hide();
280						console.log("!!!!");
281					} else {
282						if (jQuery(".on-prem-product-info-supported").scrollTop() === jQuery(".on-prem-product-info-supported-list:first-child").outerHeight() + jQuery(".on-prem-product-info-supported-list:nth-child(2)").outerHeight() - 320) {
283							jQuery(".on-prem-product-info-supported-list-arrow-up").show();
284							jQuery(".on-prem-product-info-supported-list-arrow-down").hide();
285						} else {
286							jQuery(".on-prem-product-info-supported-list-arrow-up").hide();
287							jQuery(".on-prem-product-info-supported-list-arrow-down").show();
288						}
289					}
290				});
291			} else {
292				jQuery(".on-prem-product-info-supported-container").hide();
293				jQuery(className + " .product-info-screenshot-v17 p").show();
294				jQuery(className + " .product-info-screenshot-v17 .screenshot").show();
295			}
296			jQuery(className + " .product-info-screenshot-v17 h3").html(data[index].title);
297			jQuery(className + " .product-info-screenshot-v17 p").html(data[index].description);
298			jQuery(className + " .product-info-screenshot-v17 .screenshot").attr("src", "/images/product_screenshot/" + data[index].image + lang + ".png");
299			if (data[index].fullScreenshot) {
300				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("box-shadow", "rgba(0, 0, 0, 0.2) 0px 10px 40px");
301			} else {
302				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("box-shadow", "none");
303			}
304			jQuery(className + " .product-info-screenshot-v17 .fancybox").attr("href", "/images/product_screenshot/" + data[index].image + lang + ".png");
305			jQuery(className + " .product-info-screenshot-v17 .fancybox").attr("data-fancybox-title", data[index].title);
306		} else {
307			let os_tmp = jQuery(".info-switcher-in3.selected, .info-switcher-in4.selected").attr("os");
308			switch (os_tmp) {
309				case "win":
310					os_tmp = "Windows";
311					break;
312				case "mac":
313					os_tmp = "Mac";
314					break;
315				case "linux":
316					os_tmp = "Linux";
317					break;
318				default:
319					os_tmp = "Windows";
320			}
321			jQuery(className + " .product-info-screenshot-v17 h3").html(data[index].title);
322			jQuery(className + " .product-info-screenshot-v17 p").html(data[index].description);
323			if (data[index].product === "17_Data_Dictionary") {
324				jQuery(className + " .product-info-screenshot-v17 .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_" + data[index].product + "_CN.png");
325				jQuery(className + " .product-info-screenshot-v17 .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_" + data[index].product + "_CN.png");
326			} else {
327				jQuery(className + " .product-info-screenshot-v17 .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_" + data[index].product + "_" + os_tmp + data[index].image + "_CN.png");
328				jQuery(className + " .product-info-screenshot-v17 .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_" + data[index].product + "_" + os_tmp + data[index].image + "_CN.png");
329			}
330			jQuery(className + " .product-info-screenshot-v17 .fancybox").attr("data-fancybox-title", data[index].title);
331			if ((data[index].product === "17_MongoDB" && data[index].image === "_Data_Manipulation") || data[index].product === "17_MongoDB_Lite" || data[index].product === "17_Data_Dictionary" || data[index].product === "17_Premium_Lite_Import_Export") {
332				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("box-shadow", "none");
333				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("-webkit-box-shadow", "none");
334			} else {
335				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("box-shadow", "0 10px 40px rgba(0, 0, 0, 0.2)");
336				jQuery(className + " .product-info-screenshot-v17 .screenshot").css("-webkit-box-shadow", "0 10px 40px rgba(0, 0, 0, 0.2)");
337			}
338		}
339	}
340
341	function preloadImage(url) {
342		var img = new Image();
343		img.src = url;
344	}
345
346	jQuery(".product-info-table-cell-container").each(function () {
347		if (jQuer
347y(this).find(".product-info-table-arrow").length !== 0) {
348			jQuery(this).css("cursor", "pointer");
349		}
350	});
351
352	jQuery(".product-info-table-cell-container").click(function () {
353		var window_width = window.innerWidth;
354		var column = 3;
355		var position = 0;
356		var appendPosition = 0;
357		if (jQuery(this).find(".product-info-table-arrow").length !== 0) {
358			if (jQuery(this).hasClass("selected")) {
359				jQuery(this).removeClass("selected");
360				jQuery(this).siblings(".product-info-table-cell-details-container-appended").remove();
361			} else {
362				position = jQuery(this).attr("p");
363				if (window_width < 992) {
364					if (position.substring(0, 1) !== "s")
365						column = 2;
366					if (window_width < 768) {
367						column = 1;
368					}
369				}
370				jQuery(this).siblings().removeClass("selected");
371				jQuery(this).addClass("selected");
372				jQuery(this).siblings(".product-info-table-cell-details-container-appended").remove();
373				appendPosition = Math.min(Math.ceil(position.substring(2) / column) * column, jQuery(this).siblings(".product-info-table-cell-container").length + 1);
374				jQuery(".product-info-table-cell-container[p='" + position.substring(0, 2) + appendPosition + "']").after(
375					"<div class='product-info-table-cell-details-container col-sm-12 product-info-table-cell-details-container-appended'><div class='product-info-table-cell-details-triangle-background'><img src='/images/blue_triangle.png' /></div>"
376					+ jQuery(".product-info-table-cell-details-container[p='" + position + "']").html() + "</div>"
377				);
378				jQuery(this).parent().find(".product-info-table-cell-details-container-appended .product-info-table-cell-details-triangle-background").css("left", Math.round(jQuery(this).position().left - jQuery(this).parent().position().left + jQuery(this).width() / 2 - 38 / 2));
379			}
380		}
381	});
382
383	$(window).on("resize", function () {
384		jQuery(".product-info-table-cell-container").removeClass("selected");
385		jQuery(".product-info-table-cell-container").siblings(".product-info-table-cell-details-container-appended").remove();
386	});
387
388	$(document).ready(function () {
389		$('.bxslider').bxSlider({
390			auto: true,
391			controls: false,
392			pager: false,
393			randomStart: true
394		});
395	});
396}
397
398function productInfoV18Script(data = []) {
399	const queryString = window.location.search;
400	const urlParams = new URLSearchParams(queryString);
401	const feature = urlParams.get('feature');
402
403	if(!feature) {
404		jQuery(".info-content-menu-item[index='0']").addClass("selected");
405	}
406
407	var window_width = window.innerWidth;
408	// calProductInfoBackgroundPosition();
409	var data_length = data.length;
410	var preloaded_images = [];
411
412	jQuery(".info-content-menu .info-content-menu-item, .info-content-platform-item").click(function () {
413		var ele = jQuery(this);
414		ele.siblings().removeClass("selected");
415		ele.addClass("selected");
416		if(ele.hasClass("info-content-menu-item")) {
417			var index = ele.attr("index");
418			var platform = jQuery(".info-content-platform-item.selected").attr("platform");
419			jQuery(".info-content-mobile-menu-selected").html(data[index].title);
420			jQuery(".info-content-details .info-content-details-title").html(data[index].slogan);
421			jQuery(".info-content-details .info-content-details-desc").html(data[index].description);
422			jQuery(".info-content-details-screenshot-container .screenshot").removeClass("selected");
423			jQuery(".info-content-details-screenshot-container .screenshot[index='" + index + "'][platform='" + platform + "']").addClass("selected");
424			checkScreenshotArrow(index);
425			jQuery(".info-content-details-learn-more-link").attr("href", "/products/" + data[index].link + "?" + jQuery(".info-content-details-learn-more-link").attr("href").split('?')[1]);
426			if((data[index].image_name_1 == "MongoDB" && data[index].image_name_2 == "Data_Editor") || data[index].image_name_2 == "Data_Dictionary" || data[index].image_name_2 == "NoSQL_Support" || data[index].image_name_2 == "Backup_Restore" || data[index].image_name_2 == "Import_Export") {
427				jQuery(".info-container-v18 .screenshot-container .screenshot").addClass("no-shadow");
428			} else {
429				jQuery(".info-container-v18 .screenshot-container .screenshot").removeClass("no-shadow");
430			}
431			if(jQuery(".screenshot.selected").length != 0)
432				jQuery(".info-content-details-screenshot-expand").css("right", 10 + jQuery(".screenshot.selected").position().left);
433		} else {
434			var index = jQuery(".info-content-menu-item.selected").attr("index");
435			var platform = ele.attr("platform");
436			if(platform == "iOS") {
437				jQuery(".info-content").hide();
438				jQuery(".info-content.IOS-container").show();
439			} else {
440				jQuery(".info-content-details-screenshot-container .screenshot").removeClass("selected");
441				if(!preloaded_images.includes(platform)) {
442					for (let i = 0; i < data.length; i++) {
443						let t = 500;
444						if(index == i || feature == data[i].link) {
445							t = 0;
446						}
447						setTimeout(() => {
448							jQuery(".info-content-details-screenshot-container").append("<a class='fancybox' rel='gallery1' href='" + imageLink(data[i].image_name_1, data[i].image_name_2, platform) + "'><img class='screenshot" + (index == i ? " selected": "")  + "' index='" + i + "' platform='" + platform + "' src='" + imageLink(data[i].image_name_1, data[i].image_name_2, platform) + "' /></a>");
449							if((data[index].image_name_1 == "MongoDB" && data[index].image_name_2 == "Data_Editor") || data[index].image_name_2 == "Data_Dictionary" || data[index].image_name_2 == "NoSQL_Support" || data[index].image_name_2 == "Backup_Restore" || data[index].image_name_2 == "Import_Export") {
450								jQuery(".info-container-v18 .screenshot-container .screenshot").addClass("no-shadow");
451							} else {
452								jQuery(".info-container-v18 .screenshot-container .screenshot").removeClass("no-shadow");
453							}
454						}, t);
455					}
456					preloaded_images.push(platform);
457				} else {
458					jQuery(".info-content-details-screenshot-container .screenshot[index='" + index + "'][platform='" + platform + "']").addClass("selected");
459				}
460				window.location.hash = ele.attr("platform");
461				setCookie("platform", ele.attr("platform"), 90);
462				jQuery(".info-content").show();
463				jQuery(".info-content.IOS-container").hide();
464			}
465		}
466	});
467
468	jQuery(".info-content-mobile-menu-selected, .info-content-mobile-menu-arrow").click(function () {
469		jQuery(".info-content-mobile-menu, .info-content-mobile-menu-option").toggleClass("open");
470		if(jQuery(".info-content-mobile-menu").hasClass("open")) {
471			jQuery('.info-content-menu .info-content-menu-item').each(function() {
472				jQuery(".info-content-mobile-menu-option").append(jQuery(this).prop("outerHTML"));
473			});
474			jQuery(".info-content-mobile-menu-option .info-content-menu-item").click(function () {
475				jQuery(".info-content-menu .info-content-menu-item[index='" + jQuery(this).attr("index") + "']").click();
476				jQuery(".info-content-mobile-menu-selected").click();
477			});
478		} else {
479			jQuery(".info-content-mobile-menu-option").html("");
480			jQuery(".info-content-mobile-menu-option .info-content-menu-item").off("click");
481		}
482	});
483	jQuery(document).on("click", function (event) {
484		if (jQuery(event.target).closest(".info-content-mobile-menu").length === 0) {
485			jQuery(".info-content-mobile-menu, .info-content-mobile-menu-option").removeClass("open");
486			jQuery(".info-content-mobile-menu-option").html("");
487			jQuery(".info-content-mobile-menu-option .info-content-menu-item").off("click");
488		}
489	});
490
491	jQuery(".info-content-details-arrow > div").click(function () {
492		if(!jQuery(this).hasClass("disabled")) {
493			var index = jQuery(".info-content-menu-item.selected").attr("index");
494			if(jQuery(this).hasClass("info-content-details-arrow-back")) {
495				jQuery(".info-content-menu .info-content-menu-item[index='" + (Number(index) - 1) + "']").click();
496			} else {
497				jQuery(".info-content-menu .info-content-menu-item[index='" + (Number(index) + 1) + "']").click();
498			}
499		}
500	});
501
502	jQuery(".product-info-table-cell-container").each(function () {
503		if (jQuery(this).find(".product-info-table-arrow").length !== 0) {
504			jQuery(this).css("cursor", "pointer");
505		}
506	});
507	jQuery(".product-info-table-cell-container").click(function () {
508		var window_width = window.innerWidth;
509		var column = 3;
510		var position = 0;
511		var appendPosition = 0;
512		if (jQuery(this).find(".product-info-table-arrow").length !== 0) {
513			if (jQuery(this).hasClass("selected")) {
514				jQuery(this).removeClass("selected");
515				jQuery(this).siblings(".product-info-table-cell-details-container-appended").remove();
516			} else {
517				position = jQuery(this).attr("p");
518				if (window_width < 992) {
519					if (position.substring(0, 1) !== "s")
520						column = 2;
521					if (window_width < 768) {
522						column = 1;
523					}
524				}
525				jQuery(this).siblings().removeClass("selected");
526				jQuery(this).addClass("selected");
527				jQuery(this).siblings(".product-info-table-cell-details-container-appended").remove();
528				appendPosition = Math.min(Math.ceil(position.substring(2) / column) * column, jQuery(this).siblings(".product-info-table-cell-container").length + 1);
529				jQuery(".product-info-table-cell-container[p='" + position.substring(0, 2) + appendPosition + "']").after(
530					"<div class='product-info-table-cell-details-container col-sm-12 product-info-table-cell-details-container-appended'><div class='product-info-table-cell-details-triangle-background'><img src='/images/blue_triangle.png' /></div>"
531					+ jQuery(".product-info-table-cell-details-container[p='" + position + "']").html() + "</div>"
532				);
533				jQuery(this).parent().find(".product-info-table-cell-details-container-appended .product-info-table-cell-details-triangle-background").css("left", Math.round(jQuery(this).position().left - jQuery(this).parent().position().left + jQuery(this).width() / 2 - 38 / 2));
534			}
535		}
536	});
537
538	jQuery(".info-content-platform-item[OS='" + selectPlatformTab() + "']").click();
539	if(feature) {
540		jQuery('html, body').animate({ scrollTop: jQuery(".info-content-details-title").offset().top - 100 }, 0);
541		jQuery(document).ready(function() {
542			setTimeout(() => {
543				jQuery(".info-content-menu-item[feature='" + feature + "']").click();
544			}, 0);
545		});
546	}
547
548	jQuery(window).on("load", function() {
549		jQuery(".info-content-details-screenshot-expand").css("right", 10 + jQuery(".screenshot.selected").position().left);
550	});
551
552	jQuery(window).resize(function () {
553		// calProductInfoBackgroundPosition();
554		jQuery(".product-info-table-cell-container").removeClass("selected");
555		jQuery(".product-info-table-cell-container").siblings(".product-info-table-cell-details-container-appended").remove();
556	});
557
558	function checkScreenshotArrow(i) {
559		jQuery(".info-content-details-arrow > div").removeClass("disabled");
560		if(i == 0) {
561			jQuery(".info-content-details-arrow-back").addClass("disabled");
562		} else if(i == data_length - 1) {
563			jQuery(".info-content-details-arrow-next").addClass("disabled");
564		}
565	}
566
567	function imageLink(image_name_1, image_name_2, platform) {
568		if(image_name_2 == "Data_Dictionary" || image_name_2 == "NoSQL_Support") {
569			return "/images/product_screenshot/Screenshot_Navicat_" + image_name_2 + ".png";
570		}
571		if(image_name_1 == "") {
572			return "/images/Screenshot_Navicat_" + platform + "_" + image_name_2 + "_CN.png";
573		}
574		return "/images/Screenshot_Navicat_" + image_name_1 + "_" + platform + "_" + image_name_2 + "_CN.png";
575	}
576
577	//screenshot 
578	$(".fancybox").fancybox({openEffect : 'none', closeEffect : 'none' });
579}
580
581function navicatV18HighlightScript() {
582	var window_width = window.innerWidth;
583	var container_width = jQuery(".container.navicat-v18-highlights").width();
584	var card_width = 800;
585	var card_width_2 = 1000;
586	var card_margin = 50;
587
588	scrollableLayoutUpdate();
589	setTimeout(() => {
590		jQuery(".navicat-v18-highlights-header").addClass("loaded");
591	}, 200);
592
593	jQuery(".navicat-v18-highlights-card-switcher-item").click(function() {
594		var ele = jQuery(this);
595		var card_name = jQuery(this).attr("card");
596		ele.siblings().removeClass("selected");
597		ele.addClass("selected");
598		var card = jQuery(".navicat-v18-highlights-card[card='" + card_name + "']");
599		card.siblings().removeClass("selected");
600		card.addClass("selected");
601		card.parent().animate({ scrollLeft: 0}, 0);
602		scrollableLayoutUpdate();
603		if(!card.hasClass("navicat-v18-highlights-card-scrollable")) {
604			card.parent().width("auto").css("left", 0);
605		}
606		if(card_name == "data-editor") {
607			jQuery(".navicat-v18-highlights-data-editor").show();
608		} else {
609			jQuery(".navicat-v18-highlights-data-editor").hide();
610		}
611		if(card_name == "code-insight") {
612			jQuery(".navicat-v18-highlights-code-insight").show();
613			if(ele.parent().parent().parent().attr("id") == "navicat-v18-highlights-section-query-editing")
614				jQuery("#navicat-v18-highlights-section-query-editing .navicat-v18-highlights-scrollable-arrow-row").show();
615		} else {
616			jQuery(".navicat-v18-highlights-code-insight").hide();
617			if(ele.parent().parent().parent().attr("id") == "navicat-v18-highlights-section-query-editing")
618				jQuery("#navicat-v18-highlights-section-query-editing .navicat-v18-highlights-scrollable-arrow-row").hide();
619		}
620		card.parent().parent().find(".navicat-v18-highlights-scrollable-arrow").removeClass("disabled");
621	});
622
623	jQuery(".navicat-v18-highlights-section-mobile-2 .navicat-v18-highlights-card").click(function() {
624		var ele = jQuery(this);
625		var card_name = jQuery(this).attr("card");
626		jQuery(".navicat-v18-highlights-card-switcher-item[card='" + card_name + "']").click();
627	});
628
629	jQuery(".navicat-v18-highlights-section-mobile-1 .navicat-v18-highlights-card-scrollable .navicat-v18-highlights-card-item").click(function() {
630		if(window_width < 768) {
631			var ele = jQuery(this);
632			ele.siblings().removeClass("selected");
633			ele.addClass("selected");
634		}
635	});
636
637	jQuery(".navicat-v18-highlights-scrollable-arrow").click(function() {
638		var ele = jQuery(this);
639		var scrollable_card = ele.parent().parent().find(".navicat-v18-highlights-card-scrollable.selected");
640		var number_child = parseInt(scrollable_card.children().length);
641		var current_showing =  parseInt(scrollable_card.attr("current"));
642		var card_width_this = card_width;
643		if(scrollable_card.parent().parent().attr("id") == "navicat-v18-highlights-section-query-editing") {
644			card_width_this = card_width_2;
645		}
646		scrollable_card.attr("current");
647		if(ele.hasClass("navicat-v18-highlights-scrollable-arrow-back")) {
648			if(current_showing == 1 ) {
649				current_showing = 1;
650			} else if(current_showing == number_child) {
651				current_showing = current_showing - 1;
652			} else if(scrollable_card.parent().scrollLeft() % (card_width_this + card_margin) != 0) {
653				current_showing = current_showing;
654			} else {
655				current_showing = current_showing - 1;
656			}
657		} else {
658			if(current_showing + 1 >= number_child) {
659				current_showing = number_child;
660			} else {
661				current_showing = current_showing + 1;
662			}
663		}
664		scrollable_card.parent().animate({ scrollLeft: (current_showing - 1) * (card_width_this + card_margin)}, 300);
665		scrollable_card.attr("current", current_showing);
666		scrollable_card.find(".navicat-v18-highlights-card-item").removeClass("selected");
667		scrollable_card.find(".navicat-v18-highlights-card-item:nth-child(" + current_showing + ")").addClass("selected");
668		if(window_width < 992) {
669			ele.siblings().removeClass("disabled");
670			if(current_showing == 1) {
671				ele.parent().find(".navicat-v18-highlights-scrollable-arrow-back").addClass("disabled");
672			} else if(current_showing == number_child) {
673				ele.parent().find(".navicat-v18-highlights-scrollable-arrow-next").addClass("disabled");
674			}
675		}
676	});
677
678	jQuery(".navicat-v18-highlights-cards-container").on('scroll', function() {
679		var ele = jQuery(this);
680		var card_width_this = card_width;
681		if(ele.parent().attr("id") == "navicat-v18-highlights-section-query-editing") {
682			card_width_this = card_width_2;
683		}
684		var scroll_left_position = jQuery(this).scrollLeft();
685		var scroll_to = scroll_left_position / (card_width_this + card_margin);
686		ele.find(".navicat-v18-highlights-card-scrollable.selected .navicat-v18-highlights-card-item").each(function() {
687			var ele_2 = jQuery(this);
688			var id = parseInt(ele_2.index());
689			if(id - scroll_to > 0.6) {
690				ele_2.removeClass("active");
691			} else if (id - scroll_to < -0.5) {
692				ele_2.removeClass("active");
693			} else {
694				ele_2.addClass("active");
695			}
696		});
697		if(scroll_left_position % (card_width_this + card_margin) == 0) {
698			scroll_to  = scroll_left_position / (card_width_this + card_margin) + 1;
699		}
700		ele.find(".navicat-v18-highlights-card-scrollable.selected").attr("current", Math.ceil(scroll_to));
701		ele.find(".navicat-v18-highlights-card-scrollable.selected .navicat-v18-highlights-card-item").removeClass("selected");
702		ele.find(".navicat-v18-highlights-card-scrollable.selected .navicat-v18-highlights-card-item:nth-child(" + Math.ceil(scroll_to) + ")").addClass("selected");
703	});
704
705	function scrollableLayoutUpdate() {
706		jQuery(".navicat-v18-highlights-card-scrollable").each(function() {
707			var ele = jQuery(this);
708			if(ele.hasClass("selected")) {
709				var card_width_this = card_width;
710				if(ele.parent().parent().attr("id") == "navicat-v18-highlights-section-query-editing") {
711					card_width_this = card_width_2;
712				}
713				var container_margin = (window_width - container_width) / 2;
714				
715				var child = ele.children().length;
716				ele.css("padding", "0px");
717				ele.width(child * card_width_this + (child - 1) * card_margin + container_margin * 2);
718				ele.parent().width(window_width);
719				ele.parent().css("left", -container_margin);
720				ele.css("padding", "0px " + container_margin + "px");
721			}
722		});
723	}
724
725	jQuery(window).resize(function() {
726		window_width = window.innerWidth;
727		container_width = jQuery(".container.navicat-v18-highlights").width();
728		scrollableLayoutUpdate();
729	});
730}
731
732function navicatDataModelerV5HighlightScript() {
733	var window_width = window.innerWidth;
734	var container_width = jQuery(".container.navicat-v18-highlights").width();
735
736	setTimeout(() => {
737		jQuery(".navicat-v18-highlights-header").addClass("loaded");
738	}, 200);
739
740	calLayout();
741
742	jQuery(window).resize(function() {
743		window_width = window.innerWidth;
744		container_width = jQuery(".container.navicat-v18-highlights").width();
745		calLayout();
746	});
747
748	function calLayout() {
749		var container_margin = (window_width - container_width) / 2;
750		jQuery("#navicat-v18-highlights-section-naming-standards-glossary, #navicat-v18-highlights-section-import-sql-to-model, #navicat-v18-highlights-section-parameters, #navicat-v18-highlights-section-auto-refresh").width(window_width).css("left", -container_margin);
751	}
752
753}
754
755function productFeatureScript() {
756	var window_width = window.innerWidth;
757	var html_height = jQuery("html").height();
758	var mobile_menu_height = 0;
759	calProductInfoBackgroundPosition();
760	jQuery(".product-feature-mobile-menu-title").html(jQuery(".info-content-menu-title").html());
761	jQuery('.info-content-menu .info-content-menu-item').each(function() {
762		jQuery(".product-feature-mobile-menu-items").append(jQuery(this).parent().prop("outerHTML"));
763		mobile_menu_height = mobile_menu_height + 40;
764	});
765	jQuery(".product-feature-mobile-menu-items").height(mobile_menu_height);
766
767	jQuery(".product-feature-mobile-menu-header").click(function() {
768		jQuery(".product-feature-mobile-menu").toggleClass("open");
769	});
770
771	jQuery(".info-content-platform-item").click(function() {
772		var ele = jQuery(this);
773		var original_platform = jQuery(".info-content-platform-item.selected").attr("platform");
774		var new_platform = ele.attr("platform");
775		jQuery('.product-feature-section img').each(function() {
776			jQuery(this).attr("src", jQuery(this).attr("src").replace(original_platform, new_platform));
777		});
778		jQuery('.product-feature-section .fancybox').each(function() {
779			jQuery(this).attr("href", jQuery(this).attr("href").replace(original_platform, new_platform));
780		});
781		ele.siblings().removeClass("selected");
782		ele.addClass("selected");
783		window.location.hash = ele.attr("platform");
784		setCookie("platform", ele.attr("platform"), 90);
785		jQuery('.product-feature-platform-show').hide();
786		jQuery('.' + new_platform + '-show').show();
787	});
788
789	jQuery(".info-content-platform-item[OS='" + selectPlatformTab() + "']").click();
790
791	jQuery(".info-content-left-fix").append(jQuery(".info-content-left-
791original").html());
792	jQuery(".info-content-left-fix").width(jQuery(".info-content-left-original").width());
793
794	jQuery(window).on("load", function() {
795		html_height = jQuery("html").height();
796	});
797
798	jQuery(window).on('scroll', function() {
799		html_height = jQuery("html").height();
800		var scroll_position = jQuery(this).scrollTop();
801		var bottom_position = html_height - jQuery(".modules-sitemap").height() - jQuery(".modules-footer").height() - jQuery(".info-content-left-fix .info-content-menu").height() - 130;
802		if(bottom_position - scroll_position < 0 && scroll_position > 70) {
803			jQuery(".info-content-left-fix").removeClass("show-fix");
804			jQuery(".info-content-left-original .info-content-menu").show();
805			jQuery(".product-feature-container .info-content-left").addClass("bottom-show");
806		} else if(scroll_position > 70) {
807			jQuery(".info-content-left-fix").addClass("show-fix");
808			jQuery(".info-content-left-original .info-content-menu").hide();
809			jQuery(".product-feature-container .info-content-left").removeClass("bottom-show");
810		} else {
811			jQuery(".info-content-left-fix").removeClass("show-fix");
812			jQuery(".info-content-left-original .info-content-menu").show();
813			jQuery(".product-feature-container .info-content-left").removeClass("bottom-show");
814		}
815	});
816
817	jQuery(window).resize(function () {
818		html_height = jQuery("html").height();
819		calProductInfoBackgroundPosition();
820		jQuery(".info-content-left-fix").width(jQuery(".info-content-left-original").width());
821	});
822
823	//screenshot 
824	$(".fancybox").fancybox({openEffect : 'none', closeEffect : 'none' });
825}
826
827function calProductInfoBackgroundPosition() {
828	window_width = window.innerWidth
829	jQuery(".info-content-background").width(window.innerWidth).offset({left: 0});
830}
831
832function productInfoDataModelerScript() {
833	jQuery(".modeler-v5-item").click(function() {
834		jQuery(".modeler-v5-item").removeClass("selected");
835		jQuery(this).addClass("selected");
836	});
837
838	jQuery(".modeler-v5-card-selector-item").click(function() {
839		var ele = jQuery(this);
840		var card_name = ele.attr("card");
841		ele.siblings().removeClass("selected");
842		ele.addClass("selected");
843
844		jQuery(".modeler-v5-card-selector-section .modeler-v5-card").removeClass("selected");
845		jQuery(".modeler-v5-card-selector-section .modeler-v5-card[card='" + card_name + "']").addClass("selected");
846	});
847
848	jQuery(".product-info-switcher").click(function() {
849		var ele = jQuery(this);
850		var platform = ele.attr("platform");
851		var platform_from = jQuery(".product-info-switcher.selected").attr("platform");
852		ele.siblings().removeClass("selected");
853		ele.addClass("selected");
854		jQuery(".modeler-v5-images img").each(function () {
855			jQuery(this).attr("src", jQuery(this).attr("src").replace(platform_from, platform));
856		});
857	});
858}
859
860function productInfoBIScript() {
861	jQuery(".charts-creator-v17-product-info-tab").click(function () {
862		let index = jQuery(this).attr("index");
863		changeBITab(index);
864		if (jQuery(this).parent().parent().hasClass("charts-creator-v17-product-info-tab-sticky")) {
865			jQuery("html, body").scrollTop(jQuery(".charts-creator-v17-product-info-tab-container[real='y']").offset().top);
866		}
867	});
868
869	jQuery(".charts-creator-v17-product-info-tab-arrow:last-child").click(function () {
870		let index = jQuery(".charts-creator-v17-product-info-tab.selected").attr("index");
871		if (index < 4) {
872			index++;
873			changeBITab(index);
874		}
875	});
876
877	jQuery(".charts-creator-v17-product-info-tab-arrow:first-child").click(function () {
878		let index = jQuery(".charts-creator-v17-product-info-tab.selected").attr("index");
879		if (index > 1) {
880			index--;
881			changeBITab(index);
882		}
883	});
884
885	jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-title").click(function () {
886		let index = jQuery(this).attr("index");
887		jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-title, #charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-image .screenshot-container, #charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-image p").removeClass("selected");
888		jQuery(this).addClass("selected");
889		jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-image .screenshot-container[index=" + index + "], #charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-custom-field-image p[index=" + index + "]").addClass("selected");
890	});
891
892	jQuery("#charts-creator-v17-product-info-chart-types .charts-creator-v17-product-info-chart-types-title").click(function () {
893		let index = jQuery(this).attr("index");
894		jQuery("#charts-creator-v17-product-info-chart-types .charts-creator-v17-product-info-chart-types-title, #charts-creator-v17-product-info-chart-types .charts-creator-v17-product-info-chart-types-image img").removeClass("selected");
895		jQuery(this).addClass("selected");
896		jQuery("#charts-creator-v17-product-info-chart-types .charts-creator-v17-product-info-chart-types-image img[index=" + index + "]").addClass("selected");
897	});
898
899	function changeBITab(index) {
900		jQuery(".charts-creator-v17-product-info-tab, .charts-creator-v17-product-info-tab-content").removeClass("selected mobile-show");
901		jQuery(".charts-creator-v17-product-info-tab[index=" + index + "]").addClass("selected");
902		jQuery(".charts-creator-v17-product-info-tab-content[index=" + index + "]").addClass("selected");
903		if (jQuery(".charts-creator-v17-product-info-tab:not(.charts-creator-v17-product-info-tab~.charts-creator-v17-product-info-tab)").hasClass("selected")) {
904			for (let i = 1; i <= 3; i++) {
905				jQuery(".charts-creator-v17-product-info-tab[index=" + i + "]").addClass("mobile-show");
906			}
907		} else {
908			for (let i = 2; i <= 4; i++) {
909				jQuery(".charts-creator-v17-product-info-tab[index=" + i + "]").addClass("mobile-show");
910			}
911		}
912		jQuery(".charts-creator-v17-product-info-tab-arrow:first-child, .charts-creator-v17-product-info-tab-arrow:last-child").removeClass("hide");
913		if (parseInt(index) === 1) {
914			jQuery(".charts-creator-v17-product-info-tab-arrow:first-child").addClass("hide");
915		} else if (parseInt(index) === 4) {
916			jQuery(".charts-creator-v17-product-info-tab-arrow:last-child").addClass("hide");
917		}
918	}
919
920	var window_width = window.innerWidth;
921	customFieldMargin(window_width);
922	jQuery(window).resize(function () {
923		window_width = window.innerWidth;
924		customFieldMargin(window_width);
925	});
926	function customFieldMargin(window_width) {
927		if (window_width >= 992) {
928			let height = jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-card-column:first-child").height();
929			jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-card-column:last-child").height(height);
930		} else {
931			jQuery("#charts-creator-v17-product-info-custom-field .charts-creator-v17-product-info-card-column:last-child").height("auto");
932		}
933	}
934
935	jQuery(document).on("scroll", function () {
936		let scroll = jQuery(document).scrollTop();
937		if (jQuery(".charts-creator-v17-product-info-tab-container[real='y']").length != 0) {
938			let position = jQuery(".charts-creator-v17-product-info-tab-container[real='y']").offset().top;
939			if (scroll >= position - jQuery(".sub-navigation-bar").height() - 10) {
940				jQuery(".charts-creator-v17-product-info-tab-sticky").addClass("show");
941			} else {
942				jQuery(".charts-creator-v17-product-info-tab-sticky").removeClass("show");
943			}
944		}
945	});
946}
947
948function productInfoBI2Script() {
949	var window_width = window.innerWidth;
950	var container_width = jQuery(".container.navicat-v18-highlights").width();
951
952	jQuery(".bi-v17-product-info-item").click(function () {
953		let element = jQuery(this);
954		calSectionContainerScrollLeft(element)
955	});
956
957	jQuery(".bi-v17-product-info-card").click(function () {
958		let card = jQuery(this).attr("card")
959		if (card === undefined) {
960			card = jQuery(this).attr("card-to")
961		}
962		jQuery(".bi-v17-product-info-item[card='" + card + "']").click();
963	});
964
965	jQuery(".bi-v17-product-info-card-expand-arrow").click(function () {
966		let element = jQuery(this);
967		let element_card = element.parent().parent();
968		let card = element_card.attr("card");
969		let element_row_item = element_card.parent().prev().find(".bi-v17-product-info-item[card='" + card + "']");
970		element_card.siblings().removeClass("selected");
971		element_card.addClass("selected");
972		element_row_item.siblings().removeClass("selected");
973		element_row_item.addClass("selected");
974	});
975
976	jQuery(".bi-v17-product-info-card-container").width(jQuery("body").width() - 1)
977	let left_space = (jQuery("body").outerWidth(true) - jQuery(".container").width()) / 2;
978	jQuery(".bi-v17-product-info-card-container").css("left", -left_space);
979	jQuery(".bi-v17-product-info-item.selected").click();
980	jQuery(".bi-v17-product-info-item-row-scroll").width(window_width - 70);
981
982	jQuery(".arrow-previous").click(function () {
983		if((jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() - window_width / 4) <= 0) {
984			jQuery(".arrow-previous.arrow-grey").show();
985			jQuery(".arrow-previous.arrow-blue").hide();
986		} else {
987			jQuery(".arrow-previous.arrow-grey").hide();
988			jQuery(".arrow-previous.arrow-blue").show();
989		}
990		if((jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() - window_width / 4) >= (jQuery(".bi-v17-product-info-item-row").width())) {
991			jQuery(".arrow-next.arrow-grey").show();
992			jQuery(".arrow-next.arrow-blue").hide();
993		} else {
994			jQuery(".arrow-next.arrow-grey").hide();
995			jQuery(".arrow-next.arrow-blue").show();
996		}
997		jQuery(".bi-v17-product-info-item-row-scroll").animate({
998			scrollLeft: jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() - window_width / 4
999		}, 300);
1000	});
1001
1002	jQuery(".arrow-next").click(function () {
1003		if((jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() + window_width / 4) <= 0) {
1004			jQuery(".arrow-previous.arrow-grey").show();
1005			jQuery(".arrow-previous.arrow-blue").hide();
1006		} else {
1007			jQuery(".arrow-previous.arrow-grey").hide();
1008			jQuery(".arrow-previous.arrow-blue").show();
1009		}
1010		if((jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() + window_width / 4) >= (jQuery(".bi-v17-product-info-item-row").width())) {
1011			jQuery(".arrow-next.arrow-grey").show();
1012			jQuery(".arrow-next.arrow-blue").hide();
1013		} else {
1014			jQuery(".arrow-next.arrow-grey").hide();
1015			jQuery(".arrow-next.arrow-blue").show();
1016		}
1017		jQuery(".bi-v17-product-info-item-row-scroll").animate({
1018			scrollLeft: jQuery(".bi-v17-product-info-item-row-scroll").scrollLeft() + window_width / 4
1019		}, 300);
1020	});
1021
1022	jQuery(window).resize(function () {
1023		window_width = window.innerWidth;
1024		container_width = jQuery(".container.navicat-v18-highlights").width();
1025
1026		jQuery(".bi-v17-product-info-section").each(function () {
1027			let element = jQuery(this).find(".bi-v17-product-info-item.selected");
1028			if (element.length != 0)
1029				calSectionContainerScrollLeft(element)
1030		});
1031		jQuery(".bi-v17-product-info-card").each(function () {
1032			jQuery(this).outerHeight(jQuery(this).parent().height());
1033		});
1034		jQuery(".bi-v17-product-info-card-container").width(jQuery("body").width() - 1)
1035		left_space = (jQuery("body").outerWidth(true) - jQuery(".container").width()) / 2;
1036		jQuery(".bi-v17-product-info-card-container").css("left", -left_space);
1037		jQuery(".bi-v17-product-info-item.selected").click();
1038		jQuery(".bi-v17-product-info-item-row-scroll").width(window_width - 70);
1039	});
1040
1041	function calSectionContainerScrollLeft(element) {
1042		let window_width = window.innerWidth;
1043		let element_card_container = element.parent().parent().next();
1044		if(element.hasClass("bi-v17-product-info-item-scroll") ){
1045			element_card_container = element.parent().parent().parent().next();
1046		}
1047		if (window_width < 767) {
1048			element_card_container.scrollLeft(0);
1049		} else {
1050			let card = element.attr("card");
1051			let element_card = element_card_container.find(".bi-v17-product-info-card[card='" + card + "']")
1052			element.siblings().removeClass("selected");
1053			element.addClass("selected");
1054			element_card.siblings().removeClass("selected");
1055			element_card.addClass("selected");
1056			element_card_container.scrollLeft(element_card_container.scrollLeft() + element_card.position().left - left_space);
1057		}
1058	}
1059
1060	jQuery(".bi-v17-product-info-card-content-switcher-title div").click(function () {
1061		let title = jQuery(this);
1062		let content = jQuery(this).parent().parent().find(".bi-v17-product-info-card-content-switcher-content[content='" + title.attr("content") + "']");
1063		title.siblings().removeClass("selected");
1064		title.addClass("selected");
1065		content.siblings().removeClass("selected");
1066		content.addClass("selected");
1067	});
1068
1069	jQuery(window).on('load', function () {
1070		jQuery(".bi-v17-product-info-card").each(function () {
1071			jQuery(this).outerHeight(jQuery(this).parent().height());
1072		});
1073	})
1074}
1075
1076function productInfoOnPremScript() {
1077	var position = [];
1078	var window_width = window.innerWidth;
1079	var window_height = window.innerHeight;
1080	var start = jQuery(".parallax-scrolling-fix-img").offset().top - window.innerHeight;
1081	var end = jQuery(".parallax-scrolling-fix-img").offset().top - window.innerHeight / 2;
1082
1083	getPosition();
1084	calImagePosition();
1085
1086	jQuery(".plan-v17-tab").click(function () {
1087		this_id = jQuery(this).attr("id");
1088		jQuery(".plan-v17-tab").removeClass("selected");
1089		jQuery(this).addClass("selected");
1090		jQuery(".info-content").hide();
1091		jQuery(".info-content." + this_id).show();
1092	});
1093
1094	jQuery(window).resize(function () {
1095		window_width = window.innerWidth;
1096		window_height = window.innerHeight;
1097		start = jQuery(".parallax-scrolling-fix-img").offset().top - window.innerHeight;
1098		end = jQuery(".parallax-scrolling-fix-img").offset().top - window.innerHeight / 2;
1099		getPosition();
1100		calImagePosition();
1101	});
1102
1103	jQuery(document).on("scroll", function () {
1104		calImagePosition();
1105	});
1106
1107	function getPosition() {
1108		position = [];
1109		jQuery(".parallax-scrolling-moving-img").each(function () {
1110			let target_x;
1111			let target_y;
1112			let x;
1113			let y;
1114			jQuery("#" + this.id).removeAttr('style');
1115			if (window_width < 1400) {
1116				if (window_width < 1199) {
1117					if (window_width < 991) {
1118						target_x = jQuery("#" + this.id).attr("target-x-720");
1119						target_y = jQuery("#" + this.id).attr("target-y-720");
1120					} else {
1121						target_x = jQuery("#" + this.id).attr("target-x-940");
1122						target_y = jQuery("#" + this.id).attr("target-y-940");
1123					}
1124				} else {
1125					target_x = jQuery("#" + this.id).attr("target-x-1140");
1126					target_y = jQuery("#" + this.id).attr("target-y-1140");
1127				}
1128			} else {
1129				target_x = jQuery("#" + this.id).attr("target-x");
1130				target_y = jQuery("#" + this.id).attr("target-y");
1131			}
1132			x = jQuery("#" + this.id).position().left;
1133			y = jQuery("#" + this.id).position().top;
1134			position.push({ "id": this.id, "target_x": target_x, "target_y": target_y, "x": x, "y": y });
1135		});
1136	}
1137
1138	function calImagePosition() {
1139		let scroll = jQuery(document).scrollTop();
1140		if (scroll >= end) {
1141			position.forEach(function (arrayItem) {
1142				jQuery("#" + arrayItem.id).css({ "top": arrayItem.target_y + "px", "left": arrayItem.target_x + "px" });
1143			});
1144		} else {
1145			if (scroll <= start) {
1146				position.forEach(function (arrayItem) {
1147					jQuery("#" + arrayItem.id).removeAttr("style");
1148				});
1149			} else {
1150				position.forEach(function (arrayItem) {
1151					jQuery("#" + arrayItem.id).css("left", arrayItem.x + (arrayItem.target_x - arrayItem.x) / (end - start) * (scroll - start));
1152					jQuery("#" + arrayItem.id).css("top", arrayItem.y - (arrayItem.y - arrayItem.target_y) / (end - start) * (scroll - start));
1153				});
1154			}
1155		}
1156		if (scroll >= (jQuery(".parallax-scrolling-mobile").offset().top - window.innerHeight * 0.8)) {
1157			jQuery(".parallax-scrolling-mobile img:last-child").addClass("show");
1158		}
1159		else {
1160			jQuery(".parallax-scrolling-mobile img:last-child").removeClass("show");
1161		}
1162	}
1163}
1164
1165function whatisNavicatForMongodb(a, lang) {
1166	var OS = location.hash.substr(1);
1167	if (OS == "") {
1168		OS = getOS();
1169	}
1170
1171	jQuery(".product-info-switcher").removeClass("selected");
1172	if (OS == "W") {
1173		jQuery(".product-info-switcher[os='Windows']").addClass("selected");
1174		jQuery(".product-info-features-content.Windows").show();
1175	} else if (OS == "M") {
1176		jQuery(".product-info-switcher[os='Mac']").addClass("selected");
1177		jQuery(".product-info-features-content.Mac").show();
1178	} else {
1179		jQuery(".product-info-switcher[os='Windows']").addClass("selected");
1180		jQuery(".product-info-features-content.Windows").show();
1181	}
1182
1183	//product-info
1184	jQuery(".product-info .product-info-switcher").click(function () {
1185		var ele = jQuery(this);
1186		ele.siblings().removeClass("selected");
1187		ele.addClass("selected");
1188		jQuery(".product-info .product-info-features-content").hide();
1189		jQuery(".product-info .product-info-features-content." + ele.attr("os")).show();
1190	});
1191
1192	//object-design
1193	jQuery(".object-design .product-info-switcher").click(function () {
1194		var ele = jQuery(this);
1195		var os = ele.attr("os");
1196		var ver = "";
1197		var name = "";
1198		ele.siblings().removeClass("selected");
1199		ele.addClass("selected");
1200
1201		jQuery(".object-design-options span").each(function () {
1202			if (jQuery(this).hasClass("selected")) {
1203				ver = jQuery(this).attr("id");
1204				name = jQuery(this).attr("name");
1205			}
1206		})
1207		if (ver === "pipeline") {
1208			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Aggregation_Pipeline_CN.png");
1209			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Aggregation_Pipeline_CN.png");
1210		} else if (ver === "GridFS") {
1211			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_GridFS_CN.png");
1212			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_GridFS_CN.png");
1213		} else if (ver === "MapReduce") {
1214			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Map_Reduce_CN.png");
1215			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Map_Reduce_CN.png");
1216		} else if (name !== "") {
1217			jQuery(".object-design .fancybox").attr("href", "/images/" + name + os + ver + "_CN.png");
1218			jQuery(".object-design .screenshot").attr("src", "/images/" + name + os + ver + "_CN.png");
1219		} else {
1220			jQuery(".object-design .fancybox").attr("href", "/images/Screenshot_Navicat_16_MongoDB_02_" + ver + "_" + os + "._CNpng");
1221			jQuery(".object-design .screenshot").attr("src", "/images/Screenshot_Navicat_16_MongoDB_02_" + ver + "_" + os + "_CN.png");
1222		}
1223	});
1224
1225
1226	jQuery(".object-design-options span").click(function () {
1227		var ele = jQuery(this);
1228		var ver = ele.attr("id");
1229		var name = ele.attr("name");
1230		var os = "";
1231		ele.siblings().removeClass("selected");
1232		ele.addClass("selected");
1233
1234		jQuery(".object-design .product-info-switcher").each(function () {
1235			if (jQuery(this).hasClass("selected")) {
1236				os = jQuery(this).attr("os");
1237			}
1238		})
1239		if (ver === "pipeline") {
1240			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Aggregation_Pipeline_CN.png");
1241			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Aggregation_Pipeline_CN.png");
1242		} else if (ver === "GridFS") {
1243			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_GridFS_CN.png");
1244			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_GridFS_CN.png");
1245		} else if (ver === "MapReduce") {
1246			jQuery(".object-design .fancybox").attr("href", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Map_Reduce_CN.png");
1247			jQuery(".object-design .screenshot").attr("src", "/images/product_screenshot/Screenshot_Navicat_17_MongoDB_" + os + "_Map_Reduce_CN.png");
1248		} else if (name !== "") {
1249			jQuery(".object-design .fancybox").attr("href", "/images/" + name + os + ver + "_CN.png");
1250			jQuery(".object-design .screenshot").attr("src", "/images/" + name + os + ver + "_CN.png");
1251		} else {
1252			jQuery(".object-design .fancybox").attr("href", "/images/Screenshot_Navicat_16_MongoDB_02_" + ver + "_" + os + "_CN.png");
1253			jQuery(".object-design .screenshot").attr("src", "/images/Screenshot_Navicat_16_MongoDB_02_" + ver + "_" + os + "_CN.png");
1254		}
1255	});
1256
1257	//Data
1258	jQuery(".data .product-info-switcher").click(function () {
1259		var ele = jQuery(this);
1260		var os = ele.attr("os");
1261		var ver = "";
1262		var name = "";
1263		ele.siblings().removeClass("selected");
1264		ele.addClass("selected");
1265
1266		jQuery(".data-options span").each(function () {
1267			if (jQuery(this).hasClass("selected")) {
1268				ver = jQuery(this).attr("id");
1269				name = jQuery(this).attr("name");
1270			}
1271		})
1272		jQuery(".data .fancybox").attr("href", "/images/" + name + os + ver + "_CN.png");
1273		jQuery(".data .screenshot").attr("src", "/images/" + name + os + ver + "_CN.png");
1274	});
1275
1276	jQuery(".data-options span").click(function () {
1277		var ele = jQuery(this);
1278		var ver = ele.attr("id");
1279		var name = ele.attr("name");
1280		var os = "";
1281		ele.siblings().removeClass("selected");
1282		ele.addClass("selected");
1283
1284		jQuery(".data .product-info-switcher").each(function () {
1285			if (jQuery(this).hasClass("selected")) {
1286				os = jQuery(this).attr("os");
1287			}
1288		})
1289		jQuery(".data .fancybox").attr("href", "/images/" + name + os + ver + "_CN.png");
1290		jQuery(".data .screenshot").attr("src", "/images/" + name + os + ver + "_CN.png");
1291	});
1292
1293	jQuery(".modeling-icon-container").mouseover(function () {
1294		var ele = jQuery(this);
1295		var tool = jQuery(this).attr("tool");
1296		var img = "";
1297		ele.siblings().removeClass("selected");
1298		ele.addClass("selected");
1299		switch (tool) {
1300			case "Codecompletion":
1301				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.Codecompletion);
1302				break;
1303			case "QueryBuilder":
1304				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.QueryBuilder);
1305				break;
1306			case "Snippet":
1307				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.Snippet);
1308				break;
1309			case "DataSync":
1310				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.DataSync);
1311				break;
1312			case "DataTransfer":
1313				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.DataTransfer);
1314				break;
1315			case "ImportExport":
1316				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.ImportExport);
1317				break;
1318			case "Automation":
1319				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.Automation);
1320				break;
1321			case "BI":
1322				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.BI);
1323				break;
1324			case "Model":
1325				jQuery(".nav-for-mongodb-section.productivity .desc").html(a.Model);
1326				break;
1327		}
1328	});
1329
1330	jQuery(".modeling-tools-row-mobile .options span").mouseover(function () {
1331		var ele = jQuery(this);
1332		var tool = jQuery(this).attr("id");
1333		ele.siblings().removeClass("selected");
1334		ele.addClass("selected");
1335		switch (tool) {
1336			case "Codecompletion":
1337				jQuery(".modeling-tools-row-mobile .desc").html(a.Codecompletion);
1338				jQuery(".modeling-tools-row-mobile .title").html("自动完成代码");
1339				img = "Product_Info_Feature_CodeCompletion.svg";
1340				break;
1341			case "QueryBuilder":
1342				jQuery(".modeling-tools-row-mobile .desc").html(a.QueryBuilder);
1343				jQuery(".modeling-tools-row-mobile .title").html("查询创建工具");
1344				img = "Product_Info_Feature_QueryBuilder.svg";
1345				break;
1346			case "Snippet":
1347				jQuery(".modeling-tools-row-mobile .desc").html(a.Snippet);
1348				jQuery(".modeling-tools-row-mobile .title").html("代码段");
1349				img = "Product_Info_Feature_Snippet.svg";
1350				break;
1351			case "DataSync":
1352				jQuery(".modeling-tools-row-mobile .desc").html(a.DataSync);
1353				jQuery(".modeling-tools-row-mobile .title").html("数据同步");
1354				img = "Product_Info_Feature_DataSync.svg";
1355				break;
1356			case "DataTransfer":
1357				jQuery(".modeling-tools-row-mobile .desc").html(a.DataTransfer);
1358				jQuery(".modeling-tools-row-mobile .title").html("数据传输");
1359				img = "Product_Info_Feature_DataTransfer.svg";
1360				break;
1361			case "ImportExport":
1362				jQuery(".modeling-tools-row-mobile .desc").html(a.ImportExport);
1363				jQuery(".modeling-tools-row-mobile .title").html("导出或导入");
1364				img = "Product_Info_Feature_ImportExport.svg";
1365				break;
1366			case "Automation":
1367				jQuery(".modeling-tools-row-mobile .desc").html(a.Automation);
1368				jQuery(".modeling-tools-row-mobile .title").html("自动运行");
1369				img = "Product_Info_Feature_Automation.svg";
1370				break;
1371			case "BI":
1372				jQuery(".modeling-tools-row-mobile .desc").html(a.BI);
1373				jQuery(".modeling-tools-row-mobile .title").html("BI");
1374				img = "Product_Info_Feature_Charts.svg";
1375				break;
1376			case "Model":
1377				jQuery(".modeling-tools-row-mobile .desc").html(a.Model);
1378				jQuery(".modeling-tools-row-mobile .title").html("模型");
1379				img = "Product_Info_Feature_Model.svg";
1380				break;
1381		}
1382		jQuery(".modeling-tools-row-mobile .image>img").attr("src", "/images/" + img);
1383
1384	});
1385
1386	jQuery(".ndm-screenshot-selector > div:not(.clear)").click(function () {
1387		var ele = jQuery(this);
1388		ele.siblings().removeClass("selected");
1389		ele.addClass("selected");
1390		var flag = ele.attr("flag");
1391		jQuery(".hidden-content[flag='" + flag + "']").siblings().hide();
1392		jQuery(".hidden-content[flag='" + flag + "']").show();
1393	});
1394
1395	jQuery(".modeling-icon-container-arrow-next").click(function () {
1396		let index = jQuery(".modeling-icon-container.counter").attr("index");
1397		if (index < 5) {
1398			index++;
1399		}
1400		hideModelingIcon(index);
1401	});
1402	jQuery(".modeling-icon-container-arrow-back").click(function () {
1403		let index = jQuery(".modeling-icon-container.counter").attr("index");
1404		if (index > 1) {
1405			index--;
1406		}
1407		hideModelingIcon(index);
1408	});
1409
1410	if (jQuery(".modeling-icon-container").hasClass("modeling-icon-container-arrow-back")) {
1411		hideModelingIcon(1);
1412	}
1413
1414	function hideModelingIcon(index) {
1415		jQuery(".modeling-icon-container-arrow-back").css("opacity", 1);
1416		jQuery(".modeling-icon-container-arrow-next").css("opacity", 1);
1417		let show = [1, 2, 3, 4, 5];
1418		switch (parseInt(index)) {
1419			case 1:
1420				show = [1, 2, 3, 4, 5];
1421				jQuery(".modeling-icon-container-arrow-back").css("opacity", 0.5);
1422				break;
1423			case 2:
1424				show = [2, 3, 4, 5, 6];
1425				break;
1426			case 3:
1427				show = [3, 4, 5, 6, 7];
1428				break;
1429			case 4:
1430				show = [4, 5, 6, 7, 8];
1431				break;
1432			default:
1433				show = [5, 6, 7, 8, 9];
1434				jQuery(".modeling-icon-container-arrow-next").css("opacity", 0.5);
1435				break;
1436		}
1437		jQuery(".modeling-icon-container").removeClass("counter");
1438		jQuery(".modeling-icon-container[index='" + index + "']").addClass("counter");
1439		jQuery(".modeling-icon-container:not(.modeling-icon-container-arrow)").hide();
1440		for (let i = 1; i <= 9; i++) {
1441			for (let j = 0; j < show.length; j++) {
1442				if (i == show[j]) {
1443					jQuery(".modeling-icon-container[index='" + i + "']").show();
1444				}
1445
1446			}
1447		}
1448	}
1449}
1450
1451function whatisNavicatDataModelerScript() {
1452	var OS = location.hash.substr(1);
1453	if (OS == "") {
1454		OS = getOS();
1455	}
1456
1457	jQuery(".product-info-switcher").removeClass("selected");
1458	if (OS == "W") {
1459		jQuery(".product-info-switcher[os='windows']").addClass("selected");
1460		jQuery(".product-info-features-content.windows").show();
1461	} else if (OS == "M") {
1462		jQuery(".product-info-switcher[os='mac']").addClass("selected");
1463		jQuery(".product-info-features-content.mac").show();
1464	} else {
1465		jQuery(".product-info-switcher[os='windows']").addClass("selected");
1466		jQuery(".product-info-features-content.windows").show();
1467	}
1468
1469	jQuery(".product-info-switcher").click(function () {
1470		var ele = jQuery(this);
1471		ele.siblings().removeClass("selected");
1472		ele.addClass("selected");
1473		jQuery(".product-info-features-content").hide();
1474		jQuery(".product-info-features-content." + ele.attr("os")).show();
1475	});
1476
1477	jQuery(".ndm-screenshot-selector:not(.ndm-screenshot-selector-2) > div:not(.clear)").click(function () {
1478		var ele = jQuery(this);
1479		ele.siblings().removeClass("selected");
1480		ele.addClass("selected");
1481		var flag = ele.attr("flag");
1482		jQuery(".hidden-content[flag='" + flag + "']").siblings().hide();
1483		jQuery(".hidden-content[flag='" + flag + "']").show();
1484	});
1485
1486	jQuery(".ndm-screenshot-selector-2 > div:not(.clear)").click(function () {
1487		var ele = jQuery(this);
1488		ele.siblings().removeClass("selected");
1489		ele.addClass("selected");
1490		var flag = ele.attr("flag");
1491		jQuery(".hidden-content-2[flag='" + flag + "']").siblings().css({ "z-index": "-99", "opacity": "0" });
1492		jQuery(".hidden-content-2[flag='" + flag + "']").css({ "z-index": "99", "opacity": "1" });
1493	});
1494}
1495
1496function whatsNewScript() {
1497	var OS = location.hash.substr(1);
1498	if (OS == "") {
1499		OS = getOS();
1500	}
1501
1502	jQuery(".whats-new-15-screenshot-selector > div:not(.clear)").click(function () {
1503		var ele = jQuery(this);
1504		ele.siblings().removeClass("selected");
1505		ele.addClass("selected");
1506		var flag = ele.attr("flag");
1507		jQuery(".hidden-content-2[flag='" + flag + "']").siblings().css({ "z-index": "-99", "opacity": "0" });
1508		jQuery(".hidden-content-2[flag='" + flag + "']").css({ "z-index": "99", "opacity": "1" });
1509	});
1510
1511	jQuery(".whats-new-15-screenshot-selector-2 > div:not(.clear)").click(function () {
1512		var ele = jQuery(this);
1513		ele.siblings().removeClass("selected");
1514		ele.addClass("selected");
1515		var flag = ele.attr("flag");
1516		jQuery(".hidden-content[flag='" + flag + "']").siblings().hide();
1517		jQuery(".hidden-content[flag='" + flag + "']").show();
1518	});
1519
1520	jQuery(".advanced-chart-selector").mouseover(function () {
1521		var ele = jQuery(this);
1522		ele.siblings().removeClass("selected");
1523		ele.addClass("selected");
1524		var flag = ele.attr("flag");
1525		jQuery(".advanced-chart-screenshot[flag='" + flag + "']").siblings().hide();
1526		jQuery(".advanced-chart-screenshot[flag='" + flag + "']").show();
1527	});
1528
1529	jQuery(".item-control").click(function () {
1530		var ele = jQuery(this);
1531		ele.siblings().removeClass("selected");
1532		ele.addClass("selected");
1533	});
1534
1535	if (OS == "L") {
1536		jQuery(".whats-new-15-screenshot-selector > div[os='linux']").click();
1537		jQuery(".whats-new-15-screenshot-selector > div[os='linux&win']").click();
1538	} else if (OS == "M") {
1539		jQuery(".whats-new-15-screenshot-selector > div[os='mac']").click();
1540	} else {
1541		jQuery(".whats-new-15-screenshot-selector > div[os='win']").click();
1542		jQuery(".whats-new-15-screenshot-selector > div[os='linux&win']").click();
1543	}
1544}
1545
1546function navicatv17HighlightScript() {
1547	jQuery(".navicat-v17-highlights-design-diagram-title span").click(function () {
1548		var index = jQuery(this).attr("index");
1549		jQuery(".navicat-v17-highlights-design-diagram-title span, .navicat-v17-highlights-design-diagram p, .navicat-v17-highlights-design-diagram img").removeClass("selected");
1550		jQuery(".navicat-v17-highlights-design-diagram-title span[index='" + index + "'], .navicat-v17-highlights-design-diagram p[index='" + index + "'], .navicat-v17-highlights-design-diagram img[index='" + index + "']").addClass("selected");
1551	});
1552	jQuery(".navicat-v17-highlights-mobile-view-img").each(function () {
1553		jQuery(this).attr("src", jQuery(this).parent().find(".navicat-v17-highlights-desktop-view-img img").attr("src"))
1554	});
1555	if (window.innerWidth > 991) {
1556		jQuery(".navicat-v17-highlights-section").each(function () {
1557			if (jQuery(this).find("> .navicat-v17-highlights-two-column").length !== 0) {
1558				var card_height = 0;
1559				var tmp_height = 0;
1560				var title_height = 0;
1561				var tmp_title_height = 0;
1562				jQuery(this).find("> .navicat-v17-highlights-two-column").each(function () {
1563					tmp_height = 0;
1564					tmp_title_height = 0;
1565					jQuery(this).find(".navicat-v17-highlights-card").each(function () {
1566						jQuery(this).children().each(function () {
1567							tmp_height = tmp_height + jQuery(this).outerHeight();
1568						});
1569					});
1570					card_height = Math.max(card_height, tmp_height)
1571					card_height = card_height
1572					tmp_title_height = jQuery(this).find("h1").outerHeight();
1573					title_height = Math.max(title_height, tmp_title_height)
1574				});
1575				jQuery(this).find("> .navicat-v17-highlights-two-column").each(function () {
1576					jQuery(this).find(".navicat-v17-highlights-card").css("height", card_height)
1577					jQuery(this).find("h1").css("height", title_height)
1578				});
1579			}
1580		});
1581	} else {
1582		jQuery(".navicat-v17-highlights-card").each(function () {
1583			jQuery(this).css("height", "auto")
1584		})
1585		jQuery(".navicat-v17-highlights-section h1").each(function () {
1586			jQuery(this).css("height", "auto")
1587		})
1588	}
1589
1590	imagesFadeInControl("navicat-v17-highlights-all-new-modeler", 0, 0);
1591	imagesFadeInControl("navicat-v17-highlights-data-dictionary", 0, 0);
1592	jQuery(document).scroll(function () {
1593		var scroll = jQuery(this).scrollTop();
1594		imagesFadeInControl("navicat-v17-highlights-all-new-modeler", scroll, 0);
1595		imagesFadeInControl("navicat-v17-highlights-data-dictionary", scroll, 0);
1596	});
1597
1598}
1599
1600function navicatCollaborationScript() {
1601
1602	function sharingSectionAnimation() {
1603		setTimeout(function () {
1604			jQuery(".sharing-query-box.derek").animate({ opacity: 1 }, 500);
1605		}, 1000);
1606
1607		setTimeout(function () {
1608			jQuery(".sharing-query-box.adam").animate({ opacity: 1 }, 500);
1609		}, 2500);
1610
1611		setTimeout(function () {
1612			if (jQuery(window).width() >= 768)
1613				jQuery(".sharing-query-box").animate({ opacity: 0 }, 200);
1614		}, 6000);
1615	}
1616
1617	function activityLogAnimation() {
1618		setTimeout(function () {
1619			jQuery(".activity-log-content-row:last-child").fadeIn(1000);
1620		}, 500);
1621		setTimeout(function () {
1622			jQuery(".activity-log-content-row:nth-child(2)").fadeIn(1000);
1623		}, 2000);
1624		setTimeout(function () {
1625			jQuery(".activity-log-content-row:first-child").fadeIn(1000);
1626		}, 3500);
1627		setTimeout(function () {
1628			jQuery(".activity-log-content-row").hide();
1629		}, 6000);
1630	}
1631
1632	var interval = setInterval(function () {
1633		sharingSectionAnimation();
1634		activityLogAnimation();
1635	}, 6000);
1636	sharingSectionAnimation();
1637	activityLogAnimation();
1638
1639	jQuery(".collaboration-sharing-arrow").click(function () {
1640		jQuery(".collaboration-sharing-section").toggleClass("default");
1641		jQuery(".sharing-box").toggleClass("selected");
1642		jQuery(".collaboration-sharing-arrow").toggleClass("show");
1643	});
1644
1645	function memberRoles() {
1646		var i = 2;
1647		setInterval(function () {
1648			jQuery(".member-arrow").removeClass("active");
1649			jQuery("#arrow-" + i).addClass("active");
1650			i++;
1651			if (i > 4) {
1652				i = 1;
1653			}
1654		}, 2000);
1655
1656		jQuery(".member-icon").mouseenter(function () {
1657			var member = jQuery(this).attr("member");
1658			jQuery(".member-description > div").removeClass("active");
1659			jQuery(".member-description-content[member='" + member + "']").addClass("active");
1660		});
1661		jQuery(".member-icon").mouseleave(function () {
1662			jQuery(".member-description > div").removeClass("active");
1663			jQuery(".member-description-default").addClass("active");
1664		});
1665
1666		jQuery(".member-icon-btn > span").click(function () {
1667			jQuery(this).parent().addClass("selected").siblings().removeClass("selected");
1668			var member = jQuery(this).parent().attr("member");
1669			jQuery(".member-icon").removeClass("mobile-active");
1670			jQuery(".member-icon[member='" + member + "']").addClass("mobile-active");
1671			jQuery(".member-description-content").removeClass("mobile-active");
1672			jQuery(".member-description-content[member='" + member + "']").addClass("mobile-active");
1673		});
1674	}
1675
1676	memberRoles();
1677}
1678
1679function directDownload(product, location, support, linux_dist) {
1680	jQuery(".product-banner").addClass(getProductBannerClassName(product));
1681	jQuery(".direct-download-banner").css("background", "url('../../../images/02.Product_05_Download_DirectDownload_CollaborationBanner_CN.png') no-repeat center top");
1682	jQuery.ajax({
1683		type: "POST",
1684		url: "/includes/Navicat/direct_download.php",
1685		data: { product: product, location: location, support: support, linux_dist: linux_dist },
1686		dataType: "json",
1687		success: function (data) {
1688			var link = "https://" + data.download_link;
1689			var banner_url = "../../.." + data.banner_url;
1690			window.location = link;
1691			jQuery(".installer-link").attr("href", link);
1692			//console.log(data);
1693		},
1694		failure: function (errMsg) {
1695			//console.log("!!!!!!!!!");
1696		}
1697	});
1698}
1699
1700function directDownload2(product, location, support, linux_dist, version, verNum = false) {
1701	jQuery(".product-banner").addClass(getProductBannerClassName(product));
1702	jQuery(".direct-download-banner").css("background", "url('../../../images/02.Product_05_Download_DirectDownload_CollaborationBanner_CN.png') no-repeat center top");
1703	jQuery.ajax({
1704		type: "POST",
1705		url: "/includes/Navicat/direct_download" + version + ".php",
1706		data: { product: product, location: location, support: support, linux_dist: linux_dist, verNum: verNum },
1707		dataType: "json",
1708		success: function (data) {
1709			var link = "https://" + data.download_link;
1710			var banner_url = "../../.." + data.banner_url;
1711			window.location = link;
1712			jQuery(".installer-link").attr("href", link);
1713			//console.log(data);
1714		},
1715		failure: function (errMsg) {
1716			//console.log("!!!!!!!!!");
1717		}
1718	});
1719}
1720
1721/*function getIndustry(){
1722	jQuery.ajax({
1723		type: "POST",url: "/includes/Navicat/industry.php",
1724		dataType:'json',
1725		data:
1726		{
1727			action: "getIndustry"
1728		}
1729	}).done(function( data ) {
1730		jQuery.each( data.result, function( i, item ) {
1731			var get_industry = "<option value='"+item.industry+"'>"+item.industry+"</option>";
1732			jQuery('#industry-select').append(get_industry);
1733		});
1734		jQuery.each( data.country, function( i, item ) {
1735			var get_industry = "<option value='"+item.country+"'>"+item.country+"</option>";
1736			jQuery('#country-select').append(get_industry);
1737		});
1738	});
1739}*/
1740
1741function featureMatrix() {
1742	jQuery(".fm-title-container .fm-btn").click(function () {
1743		var status = jQuery(this).attr("status");
1744		if (status == "off") {
1745			jQuery(this).attr("status", "on");
1746			jQuery(this).find("img").attr("src", "../../images/02.Product_02_hide.svg")
1747			jQuery(this).parent().parent().find(".fm-content-main-container").slideDown();
1748		} else {
1749			jQuery(this).attr("status", "off");
1750			jQuery(this).find("img").attr("src", "../../images/02.Product_02_expand.svg")
1751			jQuery(this).parent().parent().find(".fm-content-main-container").slideUp();
1752		}
1753	});
1754	var top = jQuery(".page-container .feature-matrix-table").offset().top;
1755	jQuery(document).scroll(function () {
1756		if (jQuery(this).scrollTop() > (top + 18)) {
1757			jQuery(".feature-matrix-fixed-bar").addClass("show");
1758		} else {
1759			jQuery(".feature-matrix-fixed-bar").removeClass("show");
1760		}
1761	});
1762}
1763
1764function getCookie(cname) {
1765	var name = cname + "=";
1766	var decodedCookie = decodeURIComponent(document.cookie);
1767	var ca = decodedCookie.split(';');
1768	for (var i = 0; i < ca.length; i++) {
1769		var c = ca[i];
1770		while (c.charAt(0) == ' ') {
1771			c = c.substring(1);
1772		}
1773		if (c.indexOf(name) == 0) {
1774			var res = c.substring(name.length, c.length);
1775			if (res == "1") {
1776				jQuery(".add-to-cart").remove();
1777				jQuery(".subscription-add-to-cart").remove();
1778				jQuery(".wechatweb-msg").show();
1779			}
1780		}
1781	}
1782	return "";
1783}
1784
1785function monitor2_2PageControl() {
1786	jQuery(".schedule-report-icon-container").mouseover(function () {
1787		$(this).siblings().removeClass("selected");
1788		$(this).addClass("selected");
1789		var id = $(this).attr("id");
1790		$(".schedule-report-desc").removeClass("selected");
1791		$("#" + id + "-desc").addClass("selected");
1792	});
1793}
1794
1795function monitor3KeyTopic() {
1796	jQuery(".monitor-3-key-topic-heading").addClass("active");
1797	setTimeout(function () { jQuery(".monitor-3-key-topic .monitor-3-key-topic-shortcut-row").addClass("active") }, 1500);
1798	imagesFadeInControl("postgresql", 0, 0);
1799	imagesFadeInControl("custom-metrics", 0, 0);
1800	imagesFadeInControl("sql-profiler", 0, 1);
1801	imagesFadeInControl("replication", 0, 0);
1802
1803	jQuery(document).scroll(function () {
1804		var scroll = jQuery(this).scrollTop();
1805		imagesFadeInControl("postgresql", scroll, 0);
1806		imagesFadeInControl("custom-metrics", scroll, 0);
1807		imagesFadeInControl("sql-profiler", scroll, 1);
1808		imagesFadeInControl("replication", scroll, 0);
1809	});
1810
1811	jQuery("#long-running-queries .monitor-3-key-topic-shortcut").click(function () {
1812		var index = jQuery(this).attr("index");
1813		jQuery(this).siblings().removeClass("selected");
1814		jQuery(this).addClass("selected");
1815		jQuery(".monitor-3-key-topic-screenshot[index=" + index + "]").addClass("selected");
1816	});
1817
1818	jQuery("#sql-profiler .monitor-3-key-topic-shortcut, #sql-profiler-hover .monitor-3-key-topic-shortcut").click(function () {
1819		var index = jQuery(this).attr("index");
1820		jQuery(".monitor-3-key-topic-section").removeClass("selected");
1821		jQuery(".monitor-3-key-topic-section[index=" + index + "]").addClass("selected");
1822		var scroll = jQuery(document).scrollTop();
1823		imagesFadeInControl("sql-profiler", scroll, 1);
1824		if (index == "y") {
1825			var top = jQuery("#sql-profiler-hover").offset().top;
1826			if (scroll > top)
1827				jQuery(document).scrollTop(top);
1828		} else {
1829			var top = jQuery("#sql-profiler").offset().top;
1830			if (scroll > top)
1831				jQuery(document).scrollTop(top);
1832		}
1833	});
1834
1835	jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-img").mouseenter(function () {
1836		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-img img:first-child").removeClass("show-img");
1837		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-img img:nth-child(2)").addClass("show-img");
1838		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-hint").hide();
1839	}).mouseleave(function () {
1840		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-img img:first-child").addClass("show-img");
1841		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-img img:nth-child(2)").removeClass("show-img");
1842		jQuery("#sql-profiler-hover .monitor-3-key-topic-hover-hint").show();
1843	});
1844
1845	// function resetHeight() {
1846	// 	var section_1_height = jQuery("#postgresql .monitor-3-key-topic-fix-scroll-end").height();
1847	// 	jQuery("#postgresql").height(section_1_height * 2 + 400 * 4);
1848	// 	var section_2_height = jQuery("#custom-metrics .monitor-3-key-topic-fix-scroll-end").height();
1849	// 	jQuery("#custom-metrics").height(section_2_height * 2 + 400 * 2);
1850	// 	var section_3_height = jQuery("#sql-profiler .monitor-3-key-topic-fix-scroll-end").height();
1851	// 	jQuery("#sql-profiler").height(section_3_height * 2);
1852	// 	var section_4_height = jQuery("#replication .monitor-3-key-topic-fix-scroll-end").height();
1853	// 	jQuery("#replication").height(section_4_height * 2 - 400);
1854	// }
1855	function imagesFadeInControl(id, scroll, background) {
1856		var ele = jQuery("#" + id);
1857		var ele_scroll = ele.find(".monitor-3-key-topic-fix-scroll");
1858		var ele_scroll_start = ele.find(".monitor-3-key-topic-fix-scroll-start");
1859		var ele_scroll_end = ele.find(".monitor-3-key-topic-fix-scroll-end");
1860		var section_height = ele_scroll_end.height();
1861		var section_top = ele.offset().top;
1862		var number_of_images = ele_scroll.find(".monitor-3-key-topic-img").children().length;
1863		var ele_height = section_height * 2 + 400 * (number_of_images - 3);
1864		ele.height(ele_height);
1865		ele_scroll_end.addClass("active");
1866		ele_scroll_start.addClass("active");
1867		if (scroll > section_top) {
1868			if (scroll > section_top + ele_height - section_height - 40 * background) {
1869				ele_scroll_end.addClass("active");
1870				ele_scroll.removeClass("active");
1871				ele_scroll_start.removeClass("active");
1872				ele_scroll.find("img").addClass("show-img");
1873			} else {
1874				if (scroll > section_top + ele_height - section_height - 10) {
1875					ele_scroll_end.addClass("active");
1876				} else {
1877					ele_scroll_end.removeClass("active");
1878				}
1879				ele_scroll.addClass("active");
1880				ele_scroll_start.removeClass("active");
1881
1882				for (let i = 2; i <= number_of_images; i++) {
1883					if (scroll > section_top + (i - 2) * 200) {
1884						ele_scroll.find("img:nth-child(" + i + ")").addClass("show-img");
1885						if (scroll <= section_top + (i - 1) * 200 - 100) {
1886							ele_scroll.find("img:nth-child(" + i + ")").removeClass("show-img");
1887						}
1888					}
1889				}
1890			}
1891		} else {
1892			ele_scroll_start.addClass("active");
1893			ele_scroll.removeClass("active");
1894			ele_scroll_end.removeClass("active");
1895			ele_scroll.find("img").removeClass("show-img");
1896		}
1897	}
1898}
1899
1900function downloadPagePlatformControl(platform) {
1901	var os = getOS();
1902	if (window.location.hash) {
1903		var hash = window.location.hash.substring(1);
1904		if (hash == "windows")
1905			os = "W";
1906		if (hash == "macos")
1907			os = "M";
1908		if (hash == "linux")
1909			os = "L";
1910	}
1911	if (platform) {
1912		os = platform;
1913	}
1914	jQuery(".section-controller, .default-section:not(.download-btn-section)").hide();
1915	jQuery(".change-download-platform").show();
1916	if (os == "L") {
1917		jQuery(".lin").show();
1918		jQuery(".change-download-platform[p='L']").hide();
1919	} else if (os == "M") {
1920		jQuery(".mac").show();
1921		jQuery(".change-download-platform[p='M']").hide();
1922	} else {
1923		jQuery(".win").show();
1924		jQuery(".change-download-platform[p='W']").hide();
1925	}
1926}
1927
1928function redisKeyTopic() {
1929	jQuery(".monitor-3-key-topic-heading").addClass("active");
1930	setTimeout(function () { jQuery(".monitor-3-key-topic .monitor-3-key-topic-shortcut-row").addClass("active") }, 1500);
1931	imagesFadeInControl("query-command", 0, 0);
1932	imagesFadeInControl("pub-sub", 0, 0);
1933	imagesFadeInControl("user-management", 0, 0);
1934	imagesFadeInControl("backup", 0, 0);
1935
1936	jQuery("#data-viewer .whats-new-15-screenshot-selector > div:not(.clear)").click(function () {
1937		var ele = jQuery(this);
1938		ele.siblings().removeClass("selected");
1939		ele.addClass("selected");
1940		var flag = ele.attr("flag");
1941		var index = jQuery("#data-viewer .monitor-3-key-topic-shortcut.selected").attr("index");
1942		jQuery("#data-viewer .monitor-3-key-topic-shortcut.selected").siblings().removeClass("selected");
1943		jQuery("#data-viewer .monitor-3-key-topic-shortcut[index=" + index + "]").addClass("selected");
1944		jQuery("#data-viewer .monitor-3-key-topic-screenshot[index=" + index + "-" + flag + "]").addClass("selected");
1945	});
1946
1947	jQuery("#data-viewer .monitor-3-key-topic-shortcut").click(function () {
1948		var index = jQuery(this).attr("index");
1949		var ele = jQuery("#data-viewer .whats-new-15-screenshot-selector-2 .selected");
1950		var flag = ele.attr("flag");
1951		jQuery(this).siblings().removeClass("selected");
1952		jQuery("#data-viewer .monitor-3-key-topic-shortcut[index=" + index + "]").addClass("selected");
1953		jQuery("#data-viewer .monitor-3-key-topic-screenshot[index=" + index + "-" + flag + "]").addClass("selected");
1954	});
1955
1956	jQuery(".navicat-for-redis-key-topic-feature").mouseover(function () {
1957		var ele = jQuery(this);
1958		var flag = jQuery(this).attr("flag");
1959		ele.siblings().removeClass("selected");
1960		ele.addClass("selected");
1961		jQuery(".navicat-for-redis-key-topic-feature-des p").removeClass("selected");
1962		jQuery(".navicat-for-redis-key-topic-feature-des p[flag='" + flag + "']").addClass("selected");
1963		jQuery("#other-features .monitor-3-key-topic-shortcut").removeClass("selected");
1964		jQuery("#other-features .monitor-3-key-topic-shortcut[flag='" + flag + "']").addClass("selected");
1965		jQuery("#other-features-title.mobile").html(ele.find(".navicat-for-redis-key-topic-title").html());
1966		jQuery(".mobile .navicat-for-redis-key-topic-icon").removeClass("selected");
1967		jQuery(".mobile .navicat-for-redis-key-topic-icon[flag='" + flag + "']").addClass("selected");
1968	});
1969
1970	jQuery("#other-features .monitor-3-key-topic-shortcut").click(function () {
1971		var ele = jQuery(this);
1972		var flag = jQuery(this).attr("flag");
1973		ele.siblings().removeClass("selected");
1974		ele.addClass("selected");
1975		jQuery(".navicat-for-redis-key-topic-feature-des p").removeClass("selected");
1976		jQuery(".navicat-for-redis-key-topic-feature-des p[flag='" + flag + "']").addClass("selected");
1977		jQuery(".navicat-for-redis-key-topic-feature").removeClass("selected");
1978		jQuery(".navicat-for-redis-key-topic-feature[flag='" + flag + "']").addClass("selected");
1979		jQuery("#other-features-title.mobile").html(ele.html());
1980		jQuery(".mobile .navicat-for-redis-key-topic-icon").removeClass("selected");
1981		jQuery(".mobile .navicat-for-redis-key-topic-icon[flag='" + flag + "']").addClass("selected");
1982	});
1983
1984	jQuery(document).scroll(function () {
1985		var scroll = jQuery(this).scrollTop();
1986		imagesFadeInControl("query-command", scroll, 0);
1987		imagesFadeInControl("pub-sub", scroll, 0);
1988		imagesFadeInControl("user-management", scroll, 0);
1989		imagesFadeInControl("backup", scroll, 0);
1990	});
1991
1992	function imagesFadeInControl(id, scroll, background) {
1993		var ele = jQuery("#" + id);
1994		var ele_scroll = ele.find(".monitor-3-key-topic-fix-scroll");
1995		var ele_scroll_start = ele.find(".monitor-3-key-topic-fix-scroll-start");
1996		var ele_scroll_end = ele.find(".monitor-3-key-topic-fix-scroll-end");
1997		var section_height = ele_scroll_end.height();
1998		var section_top = ele.offset().top;
1999		var number_of_images = ele_scroll.find(".monitor-3-key-topic-img").children().length;
2000		var ele_height = section_height * 2 + 400 * (number_of_images - 3);
2001		ele.height(ele_height);
2002		ele_scroll_end.addClass("active");
2003		ele_scroll_start.addClass("active");
2004		if (scroll > section_top) {
2005			if (scroll > section_top + ele_height - section_height - 40 * background) {
2006				ele_scroll_end.addClass("active");
2007				ele_scroll.removeClass("active");
2008				ele_scroll_start.removeClass("active");
2009				ele_scroll.find("img").addClass("show-img");
2010			} else {
2011				if (scroll > section_top + ele_height - section_height) {
2012					ele_scroll_end.addClass("active");
2013				} else {
2014					ele_scroll_end.removeClass("active");
2015				}
2016				ele_scroll.addClass("active");
2017				ele_scroll_start.removeClass("active");
2018
2019				for (let i = 2; i <= number_of_images; i++) {
2020					if (scroll > section_top + (i - 2) * 200) {
2021						ele_scroll.find("img:nth-child(" + i + ")").addClass("show-img");
2022						if (scroll <= section_top + (i - 1) * 200 - 100) {
2023							ele_scroll.find("img:nth-child(" + i + ")").removeClass("show-img");
2024						}
2025					}
2026				}
2027			}
2028		} else {
2029			ele_scroll_start.addClass("active");
2030			ele_scroll.removeClass("active");
2031			ele_scroll_end.removeClass("active");
2032			ele_scroll.find("img").removeClass("show-img");
2033		}
2034	}
2035}
2036
2037function imagesFadeInControl(id, scroll, background) {
2038	var ele = jQuery("#" + id);
2039	var ele_scroll = ele.find(".monitor-3-key-topic-fix-scroll");
2040	var ele_scroll_start = ele.find(".monitor-3-key-topic-fix-scroll-start");
2041	var ele_scroll_end = ele.find(".monitor-3-key-topic-fix-scroll-end");
2042	var section_height = ele_scroll_end.height();
2043	var section_top = ele.offset().top;
2044	var number_of_images = ele_scroll.find(".monitor-3-key-topic-img").children().length;
2045	var ele_height = section_height * 2 + 400 * (number_of_images - 3);
2046	ele.css('height', ele_height);
2047	ele_scroll_end.addClass("active");
2048	ele_scroll_start.addClass("active");
2049	if (scroll > section_top) {
2050		if (scroll > section_top + ele_height - section_height - 40 * background) {
2051			ele_scroll_end.addClass("active");
2052			ele_scroll.removeClass("active");
2053			ele_scroll_start.removeClass("active");
2054			ele_scroll.find("img").addClass("show-img");
2055		} else {
2056			if (scroll > section_top + ele_height - section_height) {
2057				ele_scroll_end.addClass("active");
2058			} else {
2059				ele_scroll_end.removeClass("active");
2060			}
2061			ele_scroll.addClass("active");
2062			ele_scroll_start.removeClass("active");
2063
2064			for (let i = 2; i <= number_of_images; i++) {
2065				if (scroll > section_top + (i - 2) * 200) {
2066					ele_scroll.find("img:nth-child(" + i + ")").addClass("show-img");
2067					if (scroll <= section_top + (i - 1) * 200 - 100) {
2068						ele_scroll.find("img:nth-child(" + i + ")").removeClass("show-img");
2069					}
2070				}
2071			}
2072		}
2073	} else {
2074		ele_scroll_start.addClass("active");
2075		ele_scroll.removeClass("active");
2076		ele_scroll_end.removeClass("active");
2077		ele_scroll.find("img").removeClass("show-img");
2078	}
2079}
2080
2081function showHideVideoArrow() {
2082	jQuery(".navicat-video-arrow").each(function () {
2083		var windowWidth = jQuery(window).width();
2084		var videoNumber = 3;
2085		if (windowWidth < 991) {
2086			videoNumber = 2;
2087		}
2088		var ele = jQuery(this);
2089		var total = parseInt(ele.attr("total"));
2090		var firstVideo = parseInt(ele.parent().attr("firstvideo"));
2091		if (firstVideo === 1 && firstVideo + videoNumber - 1 >= total) {
2092			ele.hide();
2093		} else {
2094			ele.show();
2095		}
2096	});
2097}
2098
2099function videoPageArrowControl(element, action) {
2100	var windowWidth = jQuery(window).width();
2101	var videoNumber = 3;
2102	if (windowWidth < 991) {
2103		videoNumber = 2;
2104	}
2105	var total = parseInt(jQuery(element).parent().attr("total"));
2106	var ele = jQuery(element).parent().parent();
2107	var firstVideo = parseInt(ele.attr("firstvideo"));
2108	if (action === "next") {
2109		firstVideo = firstVideo + videoNumber;
2110		if (firstVideo > total) {
2111			firstVideo = firstVideo - videoNumber;
2112		}
2113	} else if (action === "back") {
2114		firstVideo = firstVideo - videoNumber;
2115		if (firstVideo <= 0) {
2116			firstVideo = 1;
2117		}
2118	}
2119	ele.attr("firstvideo", firstVideo);
2120	ele.find(".navicat-video-container").removeClass("navicat-video-container-show navicat-video-container-show-3");
2121	for (let i = 0; i < 3; i++) {
2122		ele.find(".navicat-video-container.navicat-video-container-" + parseInt(firstVideo + i)).addClass("navicat-video-container-show");
2123		if (i === 2) {
2124			ele.find(".navicat-video-container.navicat-video-container-" + parseInt(firstVideo + i)).addClass("navicat-video-container-show-3");
2125		}
2126	}
2127	ele.find(".navicat-video-arrow-back, .navicat-video-arrow-next").removeClass("navicat-video-arrow-disable");
2128	if (firstVideo <= 1) {
2129		ele.find(".navicat-video-arrow-back").addClass("navicat-video-arrow-disable");
2130	}
2131	if (firstVideo + videoNumber > total) {
2132		ele.find(".navicat-video-arrow-next").addClass("navicat-video-arrow-disable");
2133	}
2134	if (firstVideo === 1 && firstVideo + videoNumber - 1 >= total) {
2135		ele.find(".navicat-video-arrow").hide();
2136	} else {
2137		ele.find(".navicat-video-arrow").show();
2138	}
2139}
2140
2141function playVid(container) {
2142	let iframe = container.querySelector('iframe');
2143	let src = iframe.src.replace('autoplay=0', 'autoplay=1');
2144	iframe.src = src;
2145	jQuery(container).find(".navicat-video-cover").hide();
2146}
2147
2148function pauseVid(container) {
2149	let iframe = container.querySelector('iframe');
2150	let src = iframe.src.replace('autoplay=1', 'autoplay=0');
2151	iframe.src = src;
2152	jQuery(container).find(".navicat-video-cover").show();
2153}

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.