blob: 2aeb42ecb736c6d1ebdd8cafa5ded151b0452f3c [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<style>
blockquote {
color: blue;
border-left: 2px solid blue;
margin: 0px;
padding: 0 0 0 20px;
}
</style>
</head>
<body>
<div id="pasteDiv" contenteditable="true"></div>
<div id="copyDiv"><blockquote type='cite'><div>line 1</div><div>line 2</div></blockquote></div>
<div>line 3</div>
</body>
<script src="../../resources/dump-as-markup.js"></script>
<script>
var range = document.createRange();
var nodeToCopy = document.getElementById("copyDiv");
range.setStartBefore(nodeToCopy);
range.setEndAfter(nodeToCopy);
var selection = window.getSelection();
selection.addRange(range);
document.execCommand("Copy");
var pasteNode = document.getElementById("pasteDiv");
selection.collapse(pasteNode, 0);
document.execCommand("Paste");
Markup.description("This test ensures the copied the newline is NOT inside the blockquote -- a '<div><div><br></div></div>' should be appended as the next sibling of the blockquote. \n");
Markup.dump('pasteDiv');
</script>
</html>