tor-browser

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

elementFromPoint-001.html (1034B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4    <title>CSSOM View - 5 - extensions to the Document interface</title>
      5    <link rel="author" title="Neils Christoffersen" href="mailto:neils.christoffersen@gmail.com">
      6    <link rel="help" href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface">
      7    <meta name="flags" content="dom">
      8    <meta name="assert" content="elementFromPoint returns correct element">
      9    <script src="/resources/testharness.js"></script>
     10    <script src="/resources/testharnessreport.js"></script>
     11    <style>
     12    #targetDiv {
     13        position: absolute;
     14        top: 10;
     15        left: 10;
     16        height: 100px;
     17        width: 100px;
     18    }
     19    </style>
     20 </head>
     21 <body>
     22    <div id="myDiv"></div>
     23    <div id="log"></div>
     24    <div id="targetDiv">
     25    </div>
     26    <script>
     27        var element = document.elementFromPoint(15, 15);
     28 
     29        test ( function() {
     30            assert_equals(element.id, "targetDiv", "elementFromPoint didn't return the correct element");
     31        });
     32    </script>
     33 </body>
     34 </html>