1function generateBannerId(e){if(!e)return"";let t=e?.href||"";t&&""!==t||(t=e.querySelector("a")?.href||"");let r="adapty"+t+"vm",n=5381;for(let l=0;l<r.length;l++)n=33*n^r.charCodeAt(l);return(n>>>0).toString(16)}function initCloseByClick(e){if(!e?.closeElement||!e?.htmlClassName||!e?.localStorageKey)return;let t=document.querySelector(e.closeElement);t&&t.addEventListener("click",r=>{r.preventDefault();let n=parseInt(t.dataset.hidingPeriod,10)||0,l=new Date().toISOString(),a=e.bannerSelector?document.querySelector(e.bannerSelector):null,s=a?generateBannerId(a):"";localStorage.setItem(e.localStorageKey,JSON.stringify({status:"hidden",closedAt:l,hidingPeriod:n,bannerId:s})),document.documentElement.classList.add(e.htmlClassName),"Adapty:TopHeaderBanner"===e.localStorageKey&&a&&["--thb-height","--thb-visible-area","--thb-margin-top"].forEach(e=>{document.documentElement.style.setProperty(e,"0px")})})}function applyBannerStyles(e,t,r){if(!e)return;let n=document.documentElement;if(t){if(n.classList.remove(r.htmlClassName),"top-header-banner"===e.id){let l=Math.max(e.scrollHeight,e.offsetHeight,e.clientHeight),a=0===l?"auto":`${l}px`;n.style.setProperty("--thb-height",a),n.style.setProperty("--thb-visible-area",a),n.style.setProperty("--thb-margin-top","0px")}}else n.classList.add(r.htmlClassName),"top-header-banner"===e.id&&(n.style.setProperty("--thb-height","0px"),n.style.setProperty("--thb-visible-area","0px"),n.style.setProperty("--thb-margin-top","0px"))}function processaBannersConfig(){window.aBannersConfig.forEach(e=>{let{storageKey:t,closeElement:r,bannerSelector:n,htmlClassName:l}=e,a=n?document.querySelector(n):null,s=a?generateBannerId(a):"",i=document.documentElement,o=localStorage.getItem(t);if(initCloseByClick({closeElement:r,htmlClassName:l,localStorageKey:t,bannerSelector:n}),!o)return i.classList.remove(l),localStorage.setItem(t,JSON.stringify({status:"visible",closedAt:null,hidingPerio
1d:null,bannerId:s})),applyBannerStyles(a,!0,e);try{let c=JSON.parse(o);if(!a||c.bannerId!==s)return i.classList.remove(l),localStorage.setItem(t,JSON.stringify({status:"visible",closedAt:null,hidingPeriod:null,bannerId:s})),applyBannerStyles(a,!0,e);if("visible"===c.status)return i.classList.remove(l),applyBannerStyles(a,!0,e);let{closedAt:y,hidingPeriod:d}=c;if(!y||0===d||null===d)return i.classList.add(l),applyBannerStyles(a,!1,e);let p=new Date(y),h=new Date;Math.floor((h-p)/864e5)<d?(i.classList.add(l),applyBannerStyles(a,!1,e)):(i.classList.remove(l),localStorage.setItem(t,JSON.stringify({status:"visible",closedAt:null,hidingPeriod:d,bannerId:s})),applyBannerStyles(a,!0,e))}catch(m){console.error(`[Adapty]: Error parsing JSON for "${t}" & "${r}": `,m),i.classList.remove(l),applyBannerStyles(a,!0,e)}})}window.aBannersConfig=window.aBannersConfig||[{storageKey:"Adapty:TopHeaderBanner",closeElement:"#thb-close",htmlClassName:"thb--close",bannerSelector:"#top-header-banner"}],processaBannersConfig();
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.