1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-05 19:42:38 +02:00

Change the compress menu button and add a back button if it is a PWA

This commit is contained in:
Daniel Neto 2024-04-09 16:24:17 -03:00
parent 243a300016
commit 24d0525f7d
3 changed files with 19 additions and 10 deletions

View file

@ -69,6 +69,10 @@ try {
} catch (e) {
//console.log('Variable declaration ERROR', e);
}
//add the class pwa in the <body> tag if is a pwa app
if (window.navigator.standalone || window.matchMedia('(display-mode: standalone)').matches) {
document.body.classList.add('pwa');
}
var queryString = window.location.search;
var urlParams = new URLSearchParams(queryString);
@ -4146,4 +4150,3 @@ function formatNumber(num) {
}
}
}