tor-browser

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

canvas-intrinsic-dynamic.html (693B)


      1 <!DOCTYPE html>
      2 <link rel="help" href="https://drafts.csswg.org/css-sizing-3/#intrinsic">
      3 <link rel="match" href="../reference/ref-filled-green-100px-square-only.html">
      4 <meta name="assert" content="This test checks that a dynamic change in the intrinsic size of a canvas element correctly changes the intrinsic size of a parent." />
      5 <body style="position: relative;">
      6  <p>Test passes if there is a filled green square.</p>
      7  <div style="position: absolute; background: green; line-height: 0;">
      8    <canvas id="target"></canvas>
      9  </div>
     10 </body>
     11 <script>
     12  document.body.offsetTop;
     13  const target = document.getElementById('target');
     14  target.width = '100';
     15  target.height = '100';
     16 </script>