blob: 22c985fd87ba2290d5d422d4b9fc2c13d82b0e28 [file] [log] [blame]
<p>This tests for a hang when pasting underlined content at the end of a paragraph. You should see 'Hello <u>World!</u>' below.</p>
<div id="div" contenteditable="true"><div>Hello&nbsp;</div></div>
<script>
var sel = window.getSelection();
var div = document.getElementById("div");
sel.setPosition(div, div.childNodes.length);
document.execCommand("InsertHTML", false, "<span style='text-decoration: underline;'><div>World!</div></span>");
</script>