tor-browser

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

update-subpixel-rem-unit.html (719B)


      1 <!doctype html>
      2 <html style="font-size:16px">
      3 <head>
      4  <title>CSS Values and Units Test: rem subpixel change</title>
      5  <link rel="help" href="https://drafts.csswg.org/css-values/#rem">
      6  <script src="/resources/testharness.js"></script>
      7  <script src="/resources/testharnessreport.js"></script>
      8 </head>
      9 <body>
     10  <div style="font-size:16px">
     11  <div id="remElement" style="width: 10rem"></div>
     12  </div>
     13  <script>
     14    test(() => {
     15      assert_equals(getComputedStyle(remElement).width, "160px");
     16      document.documentElement.style.fontSize = "16.1px";
     17      assert_equals(getComputedStyle(remElement).width, "161px");
     18    }, "Check that a 0.1px change in root font-size affect rem units.");
     19  </script>
     20 <body>
     21 </html>