tor-browser

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

shadow-root-001.html (862B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4 <title>Shadow DOM Test: Basic shadow root</title>
      5 <link rel="match" href="shadow-root-001-ref.html">
      6 <link rel="author" title="Hayato Ito" href="mailto:hayato@google.com">
      7 <link rel="author" title="Yuta Kitamura" href="mailto:yutak@google.com">
      8 <link rel="help" href="http://www.w3.org/TR/2013/WD-shadow-dom-20130514/#shadow-trees">
      9 <meta name="assert" content="When a shadow root is attached, the shadow tree is rendered.">
     10 <script src="../../../html/resources/common.js"></script>
     11 <style>
     12 p { color: black; }
     13 * { color: red; }
     14 </style>
     15 </head>
     16 <body>
     17 <p>You should see green text saying "PASS" below.</p>
     18 <div id="host">FAIL</div>
     19 <script>
     20 var shadowRoot = window.host.attachShadow({mode: 'open'});
     21 shadowRoot.innerHTML =
     22    '<style>#pass { color: green; }</style>\n' +
     23    '<div id="pass">PASS</div>';
     24 </script>
     25 </body>
     26 </html>