forked from rDrama/rDrama
1
0
Fork 0

shorter is better

master
Aevann 2023-08-03 16:50:33 +03:00
parent d93efa8650
commit dd238cbc68
2 changed files with 4 additions and 4 deletions

View File

@ -228,10 +228,10 @@ socket.on('online', function(data){
bs_trigger(document.getElementById('online3'))
})
window.addEventListener('blur', function(){
addEventListener('blur', function(){
focused=false
})
window.addEventListener('focus', function(){
addEventListener('focus', function(){
focused=true
})

View File

@ -5,13 +5,13 @@ if (standalone) {
const thresholdImg = "/e/marseythumbsup.webp";
const threshold = -100;
window.addEventListener("touchend", () => {
addEventListener("touchend", () => {
if (window.scrollY < threshold) {
location.reload();
}
});
window.addEventListener("scroll", () => {
addEventListener("scroll", () => {
img.setAttribute("src", window.scrollY < threshold ? thresholdImg : defaultImg);
});
} else {