1(function(){ 2 if(!window.matchMedia) return; 3 var mq=window.matchMedia('(max-width:430px)'); 4 var de=document.documentElement, vv=window.visualViewport||null; 5 var TH=90,ticking=false,active=false,docked=false,offset=0,lastY=0,ignore=0,savedPad=0; 6 function H(){return document.getElementById('header');} 7 function fs(){return document.fullscreenElement||document.webkitFullscreenElement;} 8 function vb(){return window.innerHeight||(vv&&vv.height)||de.clientHeight;} 9 function paint(h){h.style.setProperty('background-color','#222','important');h.style.setProperty('z-index','99999','important');} 10 function put(h,y,anim){h.style.setProperty('transition',anim?'transform .55s cubic-bezier(.22,.61,.36,1)':'none','important');h.style.setProperty('transform','translateY('+y+'px)','important');} 11 function flush(h){if(!docked)return;var r=h.getBoundingClientRect();var diff=vb()-r.bottom;if(Math.abs(diff)>0.5){offset+=diff;put(h,offset,false);}} 12 function zeroPad(){document.body.style.setProperty('padding-top','0px','important');} 13 function cleanup(h){if(docked)return;de.classList.remove('fss-dockdown');h.style.removeProperty('background-color');h.style.removeProperty('z-index');h.style.removeProperty('transform');h.style.removeProperty('transition');} 14 function dock(h){ 15 if(docked)return;docked=true;de.classList.add('fss-dockdown'); 16 paint(h); 17 savedPad=parseFloat(getComputedStyle(document.body).paddingTop)||0; 18 zeroPad(); 19 if(savedPad>0.5){ignore=4;try{window.scrollTo(0,Math.max(0,(window.pageYOffset||0)-savedPad));}catch(e){}lastY=window.pageYOffset||0;} 20 put(h,vb()+30,false);void h.offsetHeight; 21 requestAnimationFrame(function(){if(!docked)return;var hh=h.offsetHeight||52;offset=Math.max(0,vb()-hh);put(h,offset,true);setTimeout(function(){flush(h);},520);setTimeout(function(){flush(h);},980);}); 22 } 23 function undock(h){ 24 if(!docked)return;docked=false; 25 document.body.style.removeProperty('padding-top'); 26 if(savedPad>0.5){ignore=4;try{window.scrollTo(0,(window.pageYOffset||0)+savedPad);}catch(e){}lastY=window.pageYOffset||0;} 27 put(h,0,true);setTimeout(function(){cleanup(h);},520); 28 } 29 function reflow(){if(!active||!docked)return;var h=H();if(h)flush(h);} 30 function tick(){ 31 ticking=false;if(!active)return; 32 var h=H();if(!h)return; 33 var y=window.pageYOffset||de.scrollTop||0; 34 if(ignore>0){ignore--;lastY=y;if(docked){zeroPad();paint(h);}return;} 35 if(fs()){undock(h);lastY=y;return;} 36 var d=y-lastY;lastY=y; 37 if(y<=TH){undock(h);} 38 else if(d>8){dock(h);} 39 else if(d<-2){undock(h);} 40 if(docked){zeroPad();paint(h);} 41 } 42 function onScroll(){if(ticking||!active)return;ticking=true;requestAnimationFrame(tick);} 43 function enable(){if(active)return;active=true;lastY=window.pageYOffset||0;window.addEventListener('scroll',onScroll,{passive:true});tick();} 44 function disable(){active=false;window.removeEventListener('scroll',onScroll);document.body.style.removeProperty('padding-top');var h=H();if(h){docked=false;cleanup(h);}} 45 function apply(){if(mq.matches)enable();else disable();} 46 apply(); 47 if(mq.addEventListener)mq.addEventListener('change',apply);else if(mq.addListener)mq.addListener(apply); 48 window.addEventListener('resize',reflow); 49 window.addEventListener('orientationchange',function(){setTimeout(reflow,300);}); 50 if(vv)vv.addEventListener('resize',reflow); 51 document.addEventListener('fullscreenchange',onScroll); 52})();
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.