'; const [h, p, pre] = ['h2', 'p', 'pre'].map(t => document.querySelector(t)); h.textContent = failed ? 'AWS Sign-In reported: ' + failed : 'Signed in to AWS'; p.textContent = failed ? (q.get('error_description') || '') : 'You can close this tab.'; if (paste) setTimeout(() => { p.textContent = 'If the shell did not continue on its own, paste this there as ".aws login ":'; pre.textContent = paste; pre.hidden = false; }, 2000); if (!failed) setTimeout(() => window.close(), 300); window.stop(); // no more parsing or loading: the rest of the page must not boot throw new Error('callback handled'); } }