function sharebox(url, effect = 1, scroll) { var el = document.getElementById('reportbox'); switch (effect) { case 1: // Toast el.style.padding = '1rem;'; el.style.right = '0'; el.style.bottom = '0'; el.style.position = 'fixed'; el.style.zindex = '1090'; el.style.width = 'max-content'; el.style.maxwidth = '100%'; el.innerHTML = '
'; el = document.getElementById('reportbox_main'); var op = 0.1; var timer = setInterval(function() { if (op >= 0.8) clearInterval(timer); el.style.opacity = op; el.style.filter = "alpha(opacity="+op*100+")"; op += op * 0.1; }, 50); break; case 2: // Collapse el.style.overflow = 'scroll'; el.style.opacity = '0'; el.style.filter = 'alpha(opacity=0);'; el.style.textAlign = 'right'; el.innerHTML = '