Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<!-- This test passes if it does not crash. -->
<iframe id="frame"></iframe>
<script>
window.onload = () => {
const host = document.createElement("div");
frame.appendChild(host);
frame.contentDocument.body.innerHTML = "<dialog></dialog>";
document.body.offsetTop;
const root = host.attachShadow({mode: 'open'});
root.innerHTML = "<content>";
const dialog = frame.contentDocument.querySelector("dialog");
dialog.showModal();
};
</script>