Fixed focus/blur bug
This commit is contained in:
parent
216589fed5
commit
a74f35e11b
|
@ -32,7 +32,7 @@ const APP_EMAIL_SECURITY = 'security@localhost.test'; // Default security email
|
|||
const APP_USERAGENT = APP_NAME.'-Server v%s. Please report abuse at %s';
|
||||
const APP_MODE_ADMIN = 'admin';
|
||||
const APP_PAGING_LIMIT = 15;
|
||||
const APP_CACHE_BUSTER = 69;
|
||||
const APP_CACHE_BUSTER = 87;
|
||||
const APP_VERSION_STABLE = '0.5.3';
|
||||
const APP_STORAGE_UPLOADS = '/storage/uploads';
|
||||
const APP_STORAGE_CACHE = '/storage/cache';
|
||||
|
|
|
@ -101,14 +101,20 @@
|
|||
});
|
||||
}
|
||||
|
||||
element.addEventListener("click", function(event) {
|
||||
let target = findParent("a", event.target);
|
||||
element.addEventListener('click', function(event) {
|
||||
let targetA = findParent('a', event.target);
|
||||
let targetB = findParent('button', event.target);
|
||||
|
||||
if (!target) {
|
||||
if (!targetA && !targetB) {
|
||||
return false; // no target
|
||||
}
|
||||
|
||||
if (targetA && !targetA.href) {
|
||||
// Just a normal click not an href
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!target.href) {
|
||||
if (targetB && !targetB.classList.contains('link')) {
|
||||
// Just a normal click not an href
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue