tor-browser

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

bug1518339-2.html (710B)


      1 <!doctype html>
      2 <html class="reftest-wait">
      3 <title>user-select can be overriden on a contenteditable element</title>
      4 <script src="/tests/SimpleTest/EventUtils.js"></script>
      5 <script src="/tests/SimpleTest/SimpleTest.js"></script>
      6 <style>
      7  div {
      8    -webkit-user-select: all;
      9    -moz-user-select: all;
     10    user-select: all;
     11  }
     12 </style>
     13 <div contenteditable="true">
     14  You should be able to select <b>all</b> of me.
     15 </div>
     16 <script>
     17 SimpleTest.waitForFocus(function() {
     18  const editable = document.querySelector('div[contenteditable="true"]');
     19  editable.focus();
     20  synthesizeMouseAtCenter(editable.querySelector("b"), {});
     21  setTimeout(() => document.documentElement.removeAttribute("class"), 0);
     22 });
     23 </script>