1
0
mirror of https://github.com/Pathduck/pathduck.github.io.git synced 2026-06-26 13:19:54 -04:00

Update keyboard-lock

This commit is contained in:
Stian
2025-07-24 11:48:56 +02:00
parent 25c7704627
commit d2e3bf8c21

View File

@@ -94,10 +94,15 @@ document.addEventListener("fullscreenchange", () => {
lock = false;
if (document.fullscreen) {
fullscreenButton.textContent = LEAVE_FULLSCREEN;
return (div.style.display = "block");
document
.querySelectorAll("main > div[hidden]:not(.info)")
.forEach(div => (div.hidden = false));
return;
}
fullscreenButton.textContent = ENTER_FULLSCREEN;
div.style.display = "none";
document
.querySelectorAll("main > div[hidden]:not(.info)")
.forEach(div => (div.hidden = true));
});
document.addEventListener("keydown", (e) => {