Изготовление и ремонт РВД на заказ с доставкой по всей России
0) { clearInterval(into); var menuId = "rec721136849"; let menuBlock = document.querySelector("#rec721136849 .t396"); let menuBlockArt = document.querySelector("#rec721136849 .t396__artboard"); menuBlock.style.display = "none"; setTimeout(function() { menuBlock.style.display = "block"; }, 0); var scrollWidth = 0; function removeAnimation(blk) { let block = document.querySelector(blk); let elemList = block.querySelectorAll(".t396__elem"); elemList.forEach(function(el) { if (el.hasAttribute('data-animate-sbs-event') && el.getAttribute('data-animate-sbs-event') != "hover" && el.getAttribute('data-animate-sbs-event') != "click" && el.getAttribute('data-animate-sbs-event') != "scroll") { el.classList.remove('t-sbs-anim_started'); } if (el.classList.contains('t-sbs-anim_reversed')) { el.classList.remove('t-sbs-anim_reversed'); el.classList.remove('t-sbs-anim_started'); } if (el.classList.contains('t-sbs-anim_playing')) { el.classList.remove('t-sbs-anim_playing'); } if (el.hasAttribute('data-animate-style')) { el.classList.remove('t-animate_started'); } }); } function addAnimation(blk) { let block = document.querySelector(blk); let elemList = block.querySelectorAll(".t396__elem"); elemList.forEach(function(el) { if (el.hasAttribute('data-animate-sbs-event') && el.getAttribute('data-animate-sbs-event') != "hover" && el.getAttribute('data-animate-sbs-event') != "click" && el.getAttribute('data-animate-sbs-event') != "scroll") { el.classList.add('t-sbs-anim_started'); } if (el.hasAttribute('data-animate-style')) { el.classList.add('t-animate_started'); } }); } let isIos = function() { var agent = window.navigator.userAgent; var start = agent.indexOf( 'OS ' ); if( ( agent.indexOf( 'iPhone' ) > -1 || agent.indexOf( 'iPad' ) > -1 ) && start > -1 ){ return true; } return false; }; let isAndroid = function() { var agent = window.navigator.userAgent; return agent.toLowerCase().indexOf("android") > -1; }; var scrollTop; function iosLockScroll() { if (isIos()) { scrollTop = window.pageYOffset || document.documentElement.scrollTop; document.body.classList.add('locked'); document.body.style.top = -(scrollTop) + 'px'; } } function iosUnlockScroll(x = "nolink") { if (isIos()) { if (document.body.classList.contains('locked')) { document.body.classList.remove('locked'); window.scrollTo(0, scrollTop); if (x && x != "nolink" && !window.nlm082openLinks.includes(x)) { setTimeout(function() { document.querySelector(`a[href="${x}"]`).click(); }, 500); } } } } function androidScrollFix(x) { if (isAndroid()) { setTimeout(function() { if (document.querySelector(`${x}`)) { document.querySelector(`${x}`).scrollIntoView({ behavior: 'auto', block: 'start' }); } }, 500); } } blk.querySelectorAll('[href]').forEach(function(item) { item.addEventListener("click", function(e) { iosUnlockScroll(item.getAttribute("href")); androidScrollFix(item.getAttribute("href")); }); }); var isAnimOnce = false; function setWidth() { let containerType = "grid"; menuBlock.querySelectorAll(".tn-elem").forEach(function(item) { if (item.getAttribute("data-field-container-value") == "window") { containerType = "window"; } }); let width = document.documentElement.clientWidth; let widthPxOrPercent; let myPercent; let myPx; widthPxOrPercent = "px"; if (width >= 960 && width < 1200) { widthPxOrPercent = "px"; } else if (width >= 640 && width < 960) { widthPxOrPercent = "px"; } else if (width >= 480 && width < 640) { widthPxOrPercent = "px"; } else if (width >= 320 && width < 480) { widthPxOrPercent = "px"; } if (widthPxOrPercent == "px") { myPx = 598; if (width >= 960 && width < 1200) { myPx = 568; } else if (width >= 640 && width < 960) { myPx = 518; } else if (width >= 480 && width < 640) { myPx = 720; } else if (width >= 320 && width < 480) { myPx = 718; } } else { if (width >= 960 && width < 1200) { } else if (width >= 640 && width < 960) { } else if (width >= 480 && width < 640) { } else if (width >= 320 && width < 480) { } } menuBlock.style.width = ""; if (menuBlock.offsetWidth > 0) { menuBlock.style.width = `${menuBlock.offsetWidth + scrollWidth}px`; } if (widthPxOrPercent == "px") { menuBlock.style.height = myPx * myZoom + "px"; } else { let height = menuBlockArt.getAttribute("data-artboard-height"); if (width >= 960 && width < 1200) { height = menuBlockArt.getAttribute("data-artboard-height-res-960"); } else if (width >= 640 && width < 960) { height = menuBlockArt.getAttribute("data-artboard-height-res-640"); } else if (width >= 480 && width < 640) { height = menuBlockArt.getAttribute("data-artboard-height-res-480"); } else if (width >= 320 && width < 480) { height = menuBlockArt.getAttribute("data-artboard-height-res-320"); } menuBlock.style.height = height * myPercent * myZoom + "px"; } if (menuBlock.style.height.replace("px", "") > document.documentElement.clientHeight || myPercent == 1){ menuBlock.style.height = document.documentElement.clientHeight + "px"; } if (!menuBlock.style.transform.includes("translateY(0px)")) { menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; } } setWidth(); menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; menuBlock.style.overflow = "hidden"; function changeZoom() { let z1 = myZoom; let int3 = setInterval(function() { let z2 = myZoom; if (z1 != z2) { setWidth(); clearInterval(int3); } }, 100); setTimeout(function() { clearInterval(int3); },2000); } window.addEventListener("click", function(event) { let clickId = event.target.closest(".tn-elem"); if (document.querySelector(".t-body.nolimPopUp") && document.querySelector(".nolimShow721136849") && !clickId && !event.target.hasAttribute("nlm082") && !event.target.classList.contains("t-slds__arrow")) { isMenuOpen = false; window.nlm082open = false; setTimeout(function() { menuBlock.style.opacity = "0"; menuBlock.style.pointerEvents = "none"; blk.style.display = "none"; document.querySelector(".t-body").classList.remove("nolimPopUp"); if (window.nlm020obj == undefined || (window.nlm020obj && !window.nlm020obj.isOpen)) { document.querySelector("html").style.overflow = "visible"; iosUnlockScroll(); } removeAnimation("#rec721136849"); }, 400); menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; menuBlock.classList.remove("nolimShow721136849"); } }); window.addEventListener("click", function(event) { if (document.querySelector(".t-body.nolimPopUp") && event.target.hasAttribute("nlm082") && event.target.getAttribute("nlm082") != "721136849") { isMenuOpen = false; window.nlm082open = false; setTimeout(function() { menuBlock.style.opacity = "0"; menuBlock.style.pointerEvents = "none"; blk.style.display = "none"; removeAnimation("#rec721136849"); }, 400); menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; menuBlock.classList.remove("nolimShow721136849"); } }); c.forEach((function(item) { item.setAttribute("nlm082", "721136849"); item.addEventListener("click", (function(e) { e.preventDefault(); if (document.querySelector(".nolimShow721136849")) { isMenuOpen = false; window.nlm082open = false; setTimeout(function() { menuBlock.style.opacity = "0"; menuBlock.style.pointerEvents = "none"; blk.style.display = "none"; document.querySelector(".t-body").classList.remove("nolimPopUp"); if (window.nlm020obj == undefined || (window.nlm020obj && !window.nlm020obj.isOpen)) { document.querySelector("html").style.overflow = "visible"; iosUnlockScroll(); } removeAnimation("#rec721136849"); }, 400); menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; menuBlock.classList.remove("nolimShow721136849"); } else { removeAnimation("#rec721136849"); blk.style.display = "block"; setTimeout(function() { isMenuOpen = true; window.nlm082open = true; menuBlock.style.opacity = "1"; menuBlock.style.pointerEvents = "auto"; setWidth(); changeZoom(); if (!isMac) { menuBlock.style.transform = `translateX(-${scrollWidth}px) translateY(0px)`; } else { menuBlock.style.transform = "translateX(0px) translateY(0px)"; } document.querySelector("html").style.overflow = "hidden"; iosLockScroll(); setTimeout(function() { menuBlock.classList.add("nolimShow721136849"); document.querySelector(".t-body").classList.add("nolimPopUp"); setWidth(); if (!isAnimOnce) { addAnimation("#rec721136849"); } isAnimOnce = false; }, 400); setTimeout(function() { "y" === window.lazy && t_lazyload_update(); typeof t_slds_updateSlider != "undefined" && t_slds_updateSlider("721136849"); if (document.querySelector("#rec721136849") && document.querySelector("#rec721136849").getAttribute("data-record-type") == "396") { t396_doResize('721136849'); } }, 300); }, 0); } })); })); document.querySelectorAll(".n-close").forEach((function(item) { item.classList.add("nolim_popup_close"); })); menuBlock.querySelectorAll(".n-close, .nolim_popup_close").forEach((function(item) { item.addEventListener("click", (function() { isMenuOpen = false; window.nlm082open = false; setTimeout(function() { menuBlock.style.opacity = "0"; menuBlock.style.pointerEvents = "none"; blk.style.display = "none"; document.querySelector(".t-body").classList.remove("nolimPopUp"); if (window.nlm020obj == undefined || (window.nlm020obj && !window.nlm020obj.isOpen)) { document.querySelector("html").style.overflow = "visible"; if (!item.querySelector(".tn-atom[href]") && !item.querySelector(".tn-atom a[href]")) { iosUnlockScroll(); } } removeAnimation("#rec721136849"); }, 400); menuBlock.style.transform = `translateY(-${Math.ceil(menuBlock.style.height.replace("px", ""))}px)`; menuBlock.classList.remove("nolimShow721136849"); })); })); window.addEventListener("resize", function() { setWidth(); changeZoom(); }); } }); },500); })); }());
Мы используем cookie-файлы, чтобы улучшить работу сайта и сделать его удобнее для вас. Продолжая пользоваться сайтом, вы соглашаетесь с использованием cookie.
Принять
СТАТЬИ

Регулярно публикуем новости о компании