Skip to content

Commit 3a60fd6

Browse files
committed
MC-23058: Template strict mode is not set for unsaved template previews
1 parent 6283a65 commit 3a60fd6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/code/Magento/Newsletter/Test/Mftf/ActionGroup/AdminNewsletterTemplateActionGroup.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<click selector="{{BasicFieldNewsletterSection.preview}}" stepKey="clickPreview"/>
3636
<switchToNextTab stepKey="switchToPreviewTab"/>
3737
<waitForElementVisible selector="{{BasicFieldNewsletterSection.previewIframe}}" stepKey="waitForIframeVisible"/>
38-
<executeJS function="Array.from(document.getElementById('preview_iframe').sandbox.values()).map(document.getElementById('preview_iframe').sandbox.remove)" stepKey="addSandboxValue"/>
38+
<executeJS function="Array.from(document.getElementById('preview_iframe').sandbox.values()).map(document.getElementById('preview_iframe').sandbox.remove)" stepKey="removeSandboxValues"/>
3939
<switchToIFrame userInput="preview_iframe" stepKey="switchToIframe"/>
4040
<waitForPageLoad stepKey="waitForPreviewIframeLoaded"/>
4141
</actionGroup>

app/code/Magento/Newsletter/view/adminhtml/templates/preview/iframeswitcher.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
frameborder="0"
2222
title="<?= $block->escapeHtmlAttr(__('Preview')) ?>"
2323
width="100%"
24-
sandbox="allow-forms allow-pointer-lock"
24+
sandbox="allow-forms allow-pointer-lock allow-same-origin"
2525
>
2626

2727
</iframe>

0 commit comments

Comments
 (0)