Chrome Version: 60.0.3078.0
What steps will reproduce the problem?
Open a page with the following content:
<iframe sandbox="allow-scripts"
src="data:text/html,<script>
window.addEventListener('beforeunload', function (event) {
event.returnValue = 'MESSAGE';
});
window.addEventListener('load', function() {
location = 'https://duckduckgo.com';
});
</script>"></iframe>
What is the expected result?
Modal dialogs should be blocked per https://html.spec.whatwg.org/multipage/origin.html#sandboxed-modals-flag
What happens instead?
A modal dialog is opened, asking whether we want to leave the page
Comment 1 by dtapu...@chromium.org
, Oct 27 2017