tor-browser

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

image-orientation-none-computed-style.html (1791B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4 <meta charset="utf-8">
      5 <title>CSS Images Module Level 3: image-orientation: none computed style</title>
      6 <link rel="author" title="Stephen Chenney" href="mailto:schenney@chromium.org">
      7 <link rel="help" href="https://drafts.csswg.org/css-images-3/#propdef-image-orientation">
      8 <script src="/resources/testharness.js"></script>
      9 <script src="/resources/testharnessreport.js"></script>
     10 <style>
     11    body {
     12        overflow: hidden;
     13        image-orientation: none;
     14    }
     15    div {
     16        display: inline-block;
     17        width: 100px;
     18        vertical-align: top;
     19    }
     20 </style>
     21 <script>
     22 function run_tests() {
     23    test(function() {
     24        for (var i = 1; i <= 9; i++) {
     25            var el = document.getElementById("img" + i);
     26            var computedStyle = window.getComputedStyle(el);
     27            assert_equals(computedStyle.width, "100px");
     28            assert_equals(computedStyle.height, "50px");
     29            assert_equals(computedStyle.imageOrientation, "none");
     30        }
     31      }, "image-orientation:none computed style reports correct values");
     32 
     33 }
     34 </script>
     35 </head>
     36 <body onload="run_tests()">
     37    <div><img id="img1" src="support/exif-orientation-1-ul.jpg"/></div>
     38    <div><img id="img2" src="support/exif-orientation-2-ur.jpg"/></div>
     39    <div><img id="img3" src="support/exif-orientation-3-lr.jpg"/></div>
     40    <div><img id="img4" src="support/exif-orientation-4-lol.jpg"/></div>
     41    <div><img id="img5" src="support/exif-orientation-5-lu.jpg"/></div>
     42    <div><img id="img6" src="support/exif-orientation-6-ru.jpg"/></div>
     43    <div><img id="img7" src="support/exif-orientation-7-rl.jpg"/></div>
     44    <div><img id="img8" src="support/exif-orientation-8-llo.jpg"/></div>
     45    <div><img id="img9" src="support/exif-orientation-9-u.jpg"/></div>
     46 </body>
     47 </html>