mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
fix dialogs
This commit is contained in:
parent
29f295b69c
commit
d08ee04bdb
10 changed files with 113 additions and 70 deletions
|
@ -149,7 +149,7 @@
|
|||
}, 0);
|
||||
|
||||
dom.addEventListener((dlg.dialogContainer || backdrop), 'click', function (e) {
|
||||
if (!isParent(dlg, e.target)) {
|
||||
if (e.target == dlg.dialogContainer) {
|
||||
close(dlg);
|
||||
}
|
||||
}, {
|
||||
|
@ -157,20 +157,6 @@
|
|||
});
|
||||
}
|
||||
|
||||
function isParent(parent, child) {
|
||||
|
||||
while (child) {
|
||||
|
||||
if (child == parent) {
|
||||
return true;
|
||||
}
|
||||
|
||||
child = child.parentNode;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
function isHistoryEnabled(dlg) {
|
||||
return dlg.getAttribute('data-history') == 'true';
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue