tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

caret-eol-001.html (1046B)


      1 <!DOCTYPE html>
      2 <html lang=en class="reftest-wait">
      3 <meta charset="utf-8">
      4 <title>CSS Basic User Interface Test: end-of-line carets should be visible</title>
      5 <link rel="author" title="Florian Rivoal" href="mailto:florian@rivoal.net">
      6 <link rel="help" href="http://www.w3.org/TR/css4-ui/#caret-shape">
      7 <link rel="mismatch" href=reference/caret-eol-001.html>
      8 <meta name="assert" content="Checks that carets positioned at the end of the line are shown even if they overflow.">
      9 <script src="/common/reftest-wait.js"></script>
     10 <style>
     11 div {
     12    font-size: 40px;
     13    font-family: monospace;
     14    width: 5ch;
     15    caret-color: orange;
     16    caret-shape: block;
     17    caret-animation: manual;
     18    outline: none;
     19    white-space: pre;
     20 }
     21 </style>
     22 
     23 <p>Test passes if you see a orange text insertion caret at the end of the line below.
     24 
     25 <div id=test contenteditable spellcheck="false">abcde</div>
     26 
     27 <script>
     28 const t = document.querySelector("#test");
     29 window.getSelection().selectAllChildren(t);
     30 window.getSelection().collapseToEnd();
     31 takeScreenshot();
     32 </script>