10 border: 2px solid blue;
15 .scenario { margin-bottom: 16px;}
16 .scenario:first-line { font-weight: bold; margin-bottom: 16px;}
17 .expected-results:first-line { font-weight: bold }
19 <script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
22 function editingTest() {
23 var t = document.getElementById("test");
24 setSelectionCommand(t, 0, t, t.childNodes.length);
27 var e = document.getElementById("target");
28 setSelectionCommand(e, 0, e, 1);
34 <title>Editing Test</title>
36 <body id="root" contenteditable>
37 <p>This tests pasting a table to replace some text. <b>It demonstrates two bugs: 1) selecting a table without also selecting the line break after programmatically is impossible when its followed by a div because of the way DOM positions are mapped to visible positions, 2) pasting content that ends in a table places the caret in the last table cell instead of after the table, so the interchange newline is placed in the last table cell and not after the table.</b></p>
39 <tbody><tr><td>one</td><td>two</td></tr></tbody></table>
40 <div id="target">replaceme</div>