made EVEN MORE mobile compatible (missing screenTransition tips text & license font)

This commit is contained in:
2025-01-27 21:15:59 +01:00
parent 4744c4ba1c
commit edfc47c1cc
11 changed files with 39 additions and 25 deletions
+12
View File
@@ -137,7 +137,13 @@ function pauseAnimBtn(state) {
}
function setVh() {
document.documentElement.style.setProperty("--vh", window.innerHeight * 0.01 + "px");
}
document.addEventListener("DOMContentLoaded", async function() {
debugPrint("currentPage", `${CURRENT_PAGE} ${Object.keys(PAGES)[CURRENT_PAGE + 1]}`)
startLoadingScreen()
@@ -180,6 +186,7 @@ document.addEventListener("DOMContentLoaded", async function() {
window.addEventListener("resize", function() {
document.documentElement.style.setProperty("--vh", window.innerHeight * 0.01 + "px");
calcPixelDensity()
switch (CURRENT_PAGE) {
@@ -194,6 +201,11 @@ window.addEventListener("resize", function() {
})
if ("scrollRestoration" in history) {
history.scrollRestoration = "manual";
}
window.addEventListener("pageshow", (event) => {
if (event.persisted) {
// reload page to clear unwanted cache.