mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-24 20:01:36 +02:00
Fix egw message in login page is not removable
This commit is contained in:
parent
5c08a266c1
commit
f671009c3d
@ -452,6 +452,8 @@ window.app = {classes: {}};
|
|||||||
//
|
//
|
||||||
window.egw_LAB.wait = window.egw_ready.then;
|
window.egw_LAB.wait = window.egw_ready.then;
|
||||||
|
|
||||||
|
// dispatch egw-is-created event in order to let login.js knows about egw object readiness
|
||||||
|
document.dispatchEvent(new Event('egw-is-created'));
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
@ -20,8 +20,10 @@ catch (exception){
|
|||||||
alert('Your browser is not up-to-date (JavaScript ES2020 compatible), you may experience some of the features not working.');
|
alert('Your browser is not up-to-date (JavaScript ES2020 compatible), you may experience some of the features not working.');
|
||||||
}
|
}
|
||||||
|
|
||||||
egw_ready.then(function()
|
// listen to egw-is-created object to make sure egw object is ready
|
||||||
{
|
document.addEventListener('egw-is-created', function(){
|
||||||
|
egw_ready.then(function()
|
||||||
|
{
|
||||||
jQuery(document).ready(function()
|
jQuery(document).ready(function()
|
||||||
{
|
{
|
||||||
// lock the device orientation in portrait view
|
// lock the device orientation in portrait view
|
||||||
@ -91,10 +93,9 @@ egw_ready.then(function()
|
|||||||
if (e.target == this) window.open(this.getElementsByTagName('a')[0].href, 'blank');
|
if (e.target == this) window.open(this.getElementsByTagName('a')[0].href, 'blank');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
// register service worker
|
||||||
// register service worker
|
if ('serviceWorker' in navigator) {
|
||||||
if ('serviceWorker' in navigator) {
|
|
||||||
navigator.serviceWorker.register('./service-worker.js', {scope:egw_webserverUrl+'/'})
|
navigator.serviceWorker.register('./service-worker.js', {scope:egw_webserverUrl+'/'})
|
||||||
.then(function(registration) {
|
.then(function(registration) {
|
||||||
console.log('Registration successful, scope is:', registration.scope);
|
console.log('Registration successful, scope is:', registration.scope);
|
||||||
@ -102,4 +103,5 @@ if ('serviceWorker' in navigator) {
|
|||||||
.catch(function(error) {
|
.catch(function(error) {
|
||||||
console.log('Service worker registration failed, error:', error);
|
console.log('Service worker registration failed, error:', error);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user