odhin-reports-playwright
Version:
Odhin Reports for Playwright
1 lines • 1.44 kB
JavaScript
function showHideScroll(e){let t=document.getElementById("body-content");"show"===e?t.classList.contains("hide-scroll")&&t.classList.remove("hide-scroll"):"hide"===e&&(t.classList.contains("hide-scroll")||t.classList.add("hide-scroll"))}function hideLoader(){document.getElementById("loading").style.visibility="visibility",document.getElementById("loading").style.opacity="0",document.getElementById("loading").style.transition="all .3s linear",document.getElementById("loading").style.zIndex="0",setTimeout(function(){document.getElementById("loading").style.display="none"},1800)}function openResultTab(e,t,n){for(var l,a=document.getElementsByClassName("result-tabcontent-"+n),s=0;s<a.length;s++)a[s].style.display="none";for(l=document.getElementsByClassName("result-tablinks-"+n),s=0;s<l.length;s++)l[s].className=l[s].className.replace(" active","");document.getElementById(t).style.display="block",e.currentTarget.className+=" active"}function openMainTab(e,t){for(var n,l=document.getElementsByClassName("main-tabcontent"),a=0;a<l.length;a++)l[a].style.display="none";for(n=document.getElementsByClassName("main-tablinks"),a=0;a<n.length;a++)n[a].className=n[a].className.replace(" active","");document.getElementById(t).style.display="block",e.currentTarget.className+=" active"}window.addEventListener?window.addEventListener("load",hideLoader):window.attachEvent?window.attachEvent("onload",hideLoader):window.onload=hideLoader;