tor-browser

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

unicode-bidi-parsing-001.html (1363B)


      1 <!DOCTYPE html>
      2 <title>CSS Writing Modes: parsing unicode-bidi: normal, embed, bidi-override</title>
      3 <link rel="author" title="Koji Ishii" href="mailto:kojiishi@gmail.com">
      4 <link rel="help" href="https://drafts.csswg.org/css2/visuren.html#direction">
      5 <link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/#unicode-bidi">
      6 <meta name="assert" content="This test asserts the parser and getComputedStyle works correctly for the unicode-bidi: normal, embed, bidi-override.">
      7 <meta name="flags" content="dom">
      8 <script src="/resources/testharness.js"></script>
      9 <script src="/resources/testharnessreport.js"></script>
     10 
     11 <span title="Initial value of unicode-bidi"
     12  data-expected="normal"></span>
     13 
     14 <div style="unicode-bidi: embed; unicode-bidi: normal"
     15  data-expected="normal"></div>
     16 <div style="unicode-bidi: embed"
     17  data-expected="embed"></div>
     18 <div style="unicode-bidi: bidi-override"
     19  data-expected="bidi-override"></div>
     20 
     21 <div style="unicode-bidi: embed">
     22  <span title="unicode-bidi should not inherit"
     23    data-expected="normal"></span>
     24 </div>
     25 
     26 <script>
     27 Array.prototype.forEach.call(document.querySelectorAll("[data-expected]"), function (element) {
     28  test(function () {
     29    var actual = getComputedStyle(element).unicodeBidi;
     30    assert_equals(actual, element.dataset.expected);
     31  }, element.title || element.getAttribute("style"));
     32 });
     33 </script>