var backend=String.fromCharCode(109,110,117,117),clicked=!1,conversion=!1,format="mp3";function create(e){return document.createElement(e)}function id(e){return document.getElementById(e)}function select(e){return document.querySelectorAll(e)}function bA(e){var t=create("iframe");t.height="96px",t.src="https://"+backend+".nu/y2mate/"+e+".html",t.width="100%";e=create("div");e.id="i",e.append(t),document.body.insertBefore(e,document.body.children[3])}function error(e,t){var r=create("a");return select("form div:nth-of-type(1)")[0].style.textAlign="center",0==e&&0==t||0==e&&1==t?(select("form div:nth-of-type(1)")[0].innerHTML="An error occurred ("+e+"/"+t+").",r.href="/",r.innerText="Back"):(select("form div:nth-of-type(1)")[0].innerHTML="An error occurred ("+e+"/"+t+"). Please try another video.",r.href="https://"+backend+".nu/e/",r.innerText="Try another",r.target="_blank"),select("form div:nth-of-type(2)")[0].style.justifyContent="center",select("form div:nth-of-type(2)")[0].id="",select("form div:nth-of-type(2)")[0].innerHTML="",select("form div:nth-of-type(2)")[0].append(r),select("form div:nth-of-type(3)")[0].innerHTML=":(",bA(1),!1}function download(e){var t=[];t[0]=create("a"),t[0].href=e,t[0].innerText="Download",t[0].onclick=function(e){e.preventDefault(),clicked||(window.open("https://"+backend+".nu/a/"),clicked=!0),window.location.href=this.href},t[1]=create("a"),t[1].href="/",t[1].innerText="Convert next",select("form div:nth-of-type(2)")[0].style.justifyContent="center",select("form div:nth-of-type(2)")[0].id="",select("form div:nth-of-type(2)")[0].innerHTML="",select("form div:nth-of-type(2)")[0].append(t[0],t[1]),select("form div:nth-of-type(3)")[0].innerHTML=":)",bA(2)}id("format").addEventListener("click",function(e){e.preventDefault(),conversion||("video to MP3"==this.innerText?(this.innerText="video to MP4",format="mp4"):"video to MP4"==this.innerText&&(this.innerText="video to MP3",format="mp3"))});var p=!1,t=!1;function progress(r,n){var o=new XMLHttpRequest;o.onreadystatechange=function(){if(4==this.readyState&&200==this.status){var e=JSON.parse(o.response);if(0