OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <div id="target" style=" | 2 <div id="target" style=" |
3 outline: dashed lightblue; | 3 outline: dashed lightblue; |
4 width: 400px; | 4 width: 400px; |
5 -webkit-columns: 2; | 5 -webkit-columns: 2; |
6 -webkit-column-gap: 0; | 6 -webkit-column-gap: 0; |
| 7 columns: 2; |
| 8 column-gap: 0; |
| 9 column-fill: auto; |
7 height: 90px; | 10 height: 90px; |
8 font: 20px ahem; | 11 font: 20px ahem; |
9 ">Lorem ipsum dolor sit amet consectetur elit.</div> | 12 ">Lorem ipsum dolor sit amet consectetur elit.</div> |
10 <p id="result"> | 13 <p id="result"> |
11 FAIL: Test did not run. | 14 FAIL: Test did not run. |
12 </p> | 15 </p> |
13 <script> | 16 <script> |
14 if (window.testRunner) | 17 if (window.testRunner) |
15 testRunner.dumpAsText(); | 18 testRunner.dumpAsText(); |
16 | 19 |
17 // Clicking below the last line in the first column should not select anythi
ng from the first | 20 // Clicking below the last line in the first column should not select anythi
ng from the first |
18 // line on the second column. | 21 // line on the second column. |
19 var target = document.getElementById("target"); | 22 var target = document.getElementById("target"); |
20 var hitOffset = document.caretRangeFromPoint(target.offsetLeft + 45, target.
offsetTop + 87).startOffset; | 23 var hitOffset = document.caretRangeFromPoint(target.offsetLeft + 45, target.
offsetTop + 87).startOffset; |
21 document.getElementById("result").innerText = hitOffset === 26 || hitOffset
=== 24 ? "PASS" : "FAIL: hit offset " + hitOffset + "."; | 24 document.getElementById("result").innerText = hitOffset === 26 || hitOffset
=== 24 ? "PASS" : "FAIL: hit offset " + hitOffset + "."; |
22 </script> | 25 </script> |
OLD | NEW |