Further fixes to clear up the fullscreen

This commit is contained in:
Pieter Vander Vennet 2021-03-12 14:52:34 +01:00
parent 482a81b40a
commit 558265eba9
9 changed files with 50 additions and 17 deletions

View file

@ -49,6 +49,15 @@ export default class Hash {
}
hash.setData(newValue)
}
window.addEventListener('popstate', e => {
let newValue = window.location.hash.substr(1);
console.log("Popstate: the hash is now:", newValue)
if (newValue === "") {
newValue = undefined;
}
hash.setData(newValue)
})
return hash;
}