Backed out 2 changesets (bug 1943998) for causing wd failures @ phases.py CLOSED...
[gecko.git] / editor / libeditor / crashtests / 1525481.html
blobd96e1c2d0d929d5314032e1d7140e1b75aeae90f
1 <script>
2 function onLoad() {
3 const button = document.querySelector("button");
4 // For emulating the traditional behavior, collapse Selection to end of the
5 // <button> which is the deepest last child of the <body>.
6 getSelection().collapse(button, button.childNodes.length);
7 document.execCommand("styleWithCSS", false, true);
8 document.execCommand("delete");
9 document.querySelector("ul[contenteditable]")
10 .addEventListener("DOMNodeRemoved", () => {
11 const range = document.createRange();
12 range.setEndAfter(button);
13 getSelection().addRange(range);
14 getSelection().deleteFromDocument();
15 });
16 document.execCommand("outdent");
18 </script>
19 <body onload="onLoad()">
20 <ul contenteditable style="margin: -1px 0px 1px 6px">
21 <dd></dd>
22 <dd>
23 <button></button>></dd></ul></body>