aboutsummaryrefslogtreecommitdiff
path: root/ext/js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-06-24 19:18:33 -0400
committerGitHub <noreply@github.com>2021-06-24 19:18:33 -0400
commitef4ea2271b67dd51dc0b15e2e0958999d64f3ce1 (patch)
tree6b7f99ca37851a9f27b32777383bb6978d5546b9 /ext/js
parent1878b118fb1f7caad5b5dbbb10c7ca36e9bc2d76 (diff)
Fix handling of document.body as <frameset> (#1748)
Diffstat (limited to 'ext/js')
-rw-r--r--ext/js/app/popup.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/js/app/popup.js b/ext/js/app/popup.js
index 43699735..63657dd3 100644
--- a/ext/js/app/popup.js
+++ b/ext/js/app/popup.js
@@ -503,7 +503,10 @@ class Popup extends EventDispatcher {
}
_getFrameParentElement() {
- const defaultParent = document.body;
+ let defaultParent = document.body;
+ if (defaultParent !== null && defaultParent.tagName.toLowerCase() === 'frameset') {
+ defaultParent = document.documentElement;
+ }
const fullscreenElement = DocumentUtil.getFullscreenElement();
if (
fullscreenElement === null ||