tor-browser

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

responsive-iframe-fallback.tentative.html (891B)


      1 <!doctype HTML>
      2 <title>Test that the fallback size is used.</title>
      3 <link rel="author" href="mailto:kojii@chromium.org">
      4 <link rel="help" href="https://drafts.csswg.org/css-sizing/">
      5 <script src="/resources/testharness.js"></script>
      6 <script src="/resources/testharnessreport.js"></script>
      7 <style>
      8 iframe {
      9  border: none;
     10  contain-intrinsic-block-size: from-element 100px;
     11 }
     12 </style>
     13 <iframe id=target frameborder=0 src="resources/iframe-contents-slow.html"></iframe>
     14 <script>
     15 async_test(t => {
     16  window.addEventListener('DOMContentLoaded', t.step_func(e => {
     17    requestAnimationFrame(t.step_func(() => {
     18      assert_equals(target.offsetHeight, 100);
     19    }));
     20  }));
     21  window.addEventListener('load', t.step_func(e => {
     22    requestAnimationFrame(t.step_func(() => {
     23      assert_equals(target.offsetHeight, 400);
     24      t.done();
     25    }));
     26  }));
     27 }, "The fallback size is used");
     28 </script>