Skip to content
This repository was archived by the owner on May 5, 2021. It is now read-only.

Commit 7e14e1f

Browse files
Emilien Durieu (edu)dmo-odoo
authored andcommitted
[FIX] DomLayout: firefox screenshot feature
The screenshot feature on Firefox would trigger an error (right click -> Take a screenshot).
1 parent e0414f7 commit 7e14e1f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/plugin-dom-layout/src/DomLayout.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ export class DomLayout<T extends DomLayoutConfig = DomLayoutConfig> extends JWPl
264264
root = ev.target.shadowRoot;
265265
}
266266

267-
if (iframe) {
267+
if (iframe?.contentDocument) {
268268
const iframeDoc = iframe.contentDocument;
269269
const domSelection = iframeDoc.getSelection();
270270
if (isInstanceOf(domSelection.anchorNode, HTMLBodyElement)) {

0 commit comments

Comments
 (0)