Your IP : 3.21.12.193


Current Path : /var/www/www-root/data/webdav/www/www.monolith-realty.ru/bitrix/js/landing/
Upload File :
Current File : /var/www/www-root/data/webdav/www/www.monolith-realty.ru/bitrix/js/landing/public.min.js

(function(){"use strict";BX((function(){if(typeof BX.Landing==="undefined"||typeof BX.Landing.Main==="undefined"){BX.namespace("BX.Landing");const e=[].slice.call(document.getElementsByClassName("block-wrapper"));if(!!e&&e.length){e.forEach((function(e){var t=new BX.Landing.Event.Block({block:e});BX.onCustomEvent("BX.Landing.Block:init",[t])}))}if(BX.Landing.EventTracker){BX.Landing.EventTracker.getInstance().run()}const t=[].slice.call(document.querySelectorAll('[data-pseudo-url*="{"]'));if(t.length>0){t.forEach((e=>{const t=BX.Landing.Utils.data(e,"data-pseudo-url");if(t.href&&t.enabled&&t.href.indexOf("/bitrix/services/main/ajax.php?action=landing.api.diskFile.download")!==0){if(t.target==="_self"||t.target==="_blank"){e.addEventListener("click",(e=>{e.preventDefault();let n=null;try{n=new URL(t.href)}catch(e){console.error(e)}if(n){const a=n.hostname===window.location.hostname;const o=n.pathname!==window.location.pathname;const i=n.searchParams.get("IFRAME")!=="Y";if(a&&o&&i){BX.addClass(document.body,"landing-page-transition");t.href=n.href;setTimeout((()=>{f(t,e)}),400);setTimeout((()=>{BX.removeClass(document.body,"landing-page-transition")}),3e3)}else{f(t,e)}}}))}const n=e.getElementsByTagName("a");if(n.length>0){[].slice.call(n).map((function(e){o(e)}))}if(BX.hasClass(e,"g-bg-cover")){const t=e.firstElementChild;if(t){o(t)}}}}))}const n=[].slice.call(document.querySelectorAll("[data-stop-propagation]"));if(n.length){n.forEach((function(e){o(e)}))}if(typeof BXMobileApp!=="undefined"){const u=[].slice.call(document.querySelectorAll("a"));if(u.length){u.forEach((function(e){if(e.href&&e.href.indexOf("file:")===0){e.addEventListener("click",(function(t){t.preventDefault();BXMobileApp.PageManager.loadPageBlank({url:e.href,cache:false,bx24ModernStyle:true})}))}}))}}if(typeof BXMobileApp==="undefined"){const h=[].slice.call(document.querySelectorAll('a[href*="#"]'));if(!!h&&h.length){h.forEach((e=>{const t=e.getAttribute("href");if(e.target==="_self"||e.target===""){if(i(t)){e.addEventListener("click",s)}}}))}}const a=[].slice.call(document.querySelectorAll("a"));a.forEach((function(e){const t=e.getAttribute("href");if(e.target==="_self"&&!i(t)){e.addEventListener("click",(t=>{const n=new URL(e.href);if(n.hostname===window.location.host&&n.pathname!==window.location.pathname&&n.searchParams.get("IFRAME")!=="Y"){t.preventDefault();BX.addClass(document.body,"landing-page-transition");setTimeout((()=>{top.open(n.href,e.target)}),400);setTimeout((()=>{BX.removeClass(document.body,"landing-page-transition")}),3e3)}}))}}));function o(e){e.addEventListener("click",(function(e){e.stopPropagation()}))}function i(e){if(e!==null&&(e==="#"||e.startsWith("#/"))){return false}if(r(e)){const t=new URL(e,document.location);return t.hash!==""&&t.pathname===document.location.pathname&&t.hostname===document.location.hostname}if(e!==null&&e.startsWith("#")&&d(e)){return true}return false}function r(e){try{new URL(e);return true}catch{return false}}let l=0;const c=document.querySelector(".u-header.u-header--sticky");if(!!c){const g=c.querySelector(".navbar");if(!!g){const p=BX.findParent(g,{class:"u-header__section"});l=!!p?p.offsetHeight:g.offsetHeight}}if(l&&i(document.URL)){document.addEventListener("DOMContentLoaded",(()=>{if(window.pageYOffset>0){window.scrollTo({top:window.pageYOffset-l})}}))}function s(e){try{e.preventDefault();let t=null;let n=null;const a=e.currentTarget;if(a.tagName==="A"){t=a.hash;n=a.href}else if(a.hasAttribute("data-pseudo-url")){const e=BX.Landing.Utils.data(a,"data-pseudo-url");if(d(e.href)){e.href=window.location.origin+window.location.pathname+e.href}const o=new URL(e.href);t=o.hash;n=o.href}if(!t||!n){return}const o=document.querySelector(t);window.scrollTo({top:o.offsetTop-l,behavior:"smooth"});a.blur();history.pushState({},"",n)}catch(e){}}function f(e,t){if(e.href.indexOf("/bitrix/services/main/ajax.php?action=landing.api.diskFile.download")===0){return}if(typeof BXMobileApp!=="undefined"){BXMobileApp.PageManager.loadPageBlank({url:e.href,cache:false,bx24ModernStyle:true})}else{if(e.target==="_self"&&i(e.href)){s(t)}else{if(e.query){e.href+=e.href.indexOf("?")===-1?"?":"&";e.href+=e.query}if(r(e.href)){top.open(e.href,e.target)}if(d(e.href)){s(t)}}}}function d(e){if(e.charAt(0)!=="#"||e.length===1){return false}const t=/^[\w-]+$/;return t.test(e.slice(1))}}document.addEventListener("DOMContentLoaded",(()=>{const e=document.querySelectorAll("[style]");for(const t of e){let e=t.getAttribute("style");if(e){e=e.replaceAll(/--[\w-]*: ;/gi,"");t.setAttribute("style",e)}}}))}))})();
//# sourceMappingURL=public.map.js