JSFiddle - React, Tailwind, and code Playground
HTML
<h1>The system is down for maintenance.</h1>
<h3>Click the page to activate, then use backdoor key. [Ctrl+Space]</h3>
<div id="loginbox">
<div>User
<input type="text" />
</div>
<div>Password
<input type="password" />
</div>
<input type="submit" />
</div>
JavaScript
/* Toggle Login */
function hideLogin(isHidden) {
if (isHidden) {
document.getElementById('loginbox').style.display = "none";
} else {
document.getElementById('loginbox').style.display = "block";
}
}
/* define a handler */
function doc_keyUp(e) {
/* http://www.javascripter.net/faq/keycodes.htm */
if (e.ctrlKey && e.keyCode == 32) {
hideLogin(false);
} /* Ctrl+Space */
}
/* register the handler */
document.addEventListener('keyup', doc_keyUp, false);
hideLogin(true);