21 lines
728 B
HTML
21 lines
728 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<body>
|
|
<script src="../../resources/dump-as-markup.js"></script>
|
|
<div id="test" contenteditable><ul><li>hello</li><li>world</li>WebKit</ul></div>
|
|
<script>
|
|
|
|
Markup.description('This tests RemoveFormant command on an orphaned list item following non-orphaned list items. WebKit used to remove non-orphaned list items ("hello world"). You should see "hello world WebKit" below.');
|
|
var text = document.getElementById('test').lastChild.lastChild;
|
|
var range = document.createRange();
|
|
range.setStart(text, 0);
|
|
range.setEnd(text, 6);
|
|
window.getSelection().removeAllRanges();
|
|
window.getSelection().addRange(range);
|
|
document.execCommand('RemoveFormat', false, null);
|
|
Markup.dump('test');
|
|
|
|
</script>
|
|
</body>
|
|
</html>
|