tor-browser

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

bdi-paragraph-level-container.html (2057B)


      1 <!DOCTYPE html>
      2 <html>
      3  <head>
      4    <meta charset="utf-8"/>
      5    <title>HTML Test: BDI: paragraph-level container</title>
      6    <link rel="match" href="bdi-paragraph-level-container-ref.html"/>
      7    <link rel="author" title="Aharon Lanin" href="mailto:aharon@google.com"/>
      8    <link rel="author" title="HTML5 bidi test WG" href="mailto:html5bidi@googlegroups.com"/>
      9    <link rel="help" href="https://html.spec.whatwg.org/multipage/#the-bdi-element"/>
     10    <meta name="assert" content="
     11      'For the purposes of applying the bidirectional algorithm to the contents of a bdi element,
     12      user agents must treat the element as a paragraph-level container.'
     13      Thus, under no circumstances should the content outside a BDI affect the visual
     14      ordering of the BDI's content."/>
     15    <style>
     16      body{
     17        font-size:2em;
     18      }
     19      .test, .ref {
     20        border: medium solid gray;
     21        width: 500px;
     22        margin: 20px;
     23      }
     24      .comments { display: none; }
     25    </style>
     26  </head>
     27  <body>
     28    <div class="instructions"><p>Test passes if the two boxes below look exactly the same.</p></div>
     29    <div class="comments">
     30      Key to entities used below:
     31        &#x05D0; ... &#x05D5; - The first six Hebrew letters (strongly RTL).
     32        &#x202D; - The LRO (left-to-right override) formatting character.
     33        &#x202C; - The PDF (pop directional formatting) formatting character; closes LRO.
     34      If the BDIs in the test's first DIV were just SPANs, the &#x05D0; would order the 1 2 3 as
     35      3 2 1, and the &#x05D5; would (with the &#x05D4;) order the ?! as !?.
     36    </div>
     37    <div class="test">
     38      <div dir="ltr">&#x05D0; <bdi>[1 2 3 b]</bdi> c <bdi>[d &#x05D4;?!]</bdi> &#x05D5;...</div>
     39      <div dir="rtl">a <bdi>[1 2 3 &#x05D1;]</bdi> &#x05D2; <bdi>[&#x05D3; e?!]</bdi> f...</div>
     40    </div>
     41    <div class="ref">
     42      <div dir="ltr">&#x202D;&#x05D0; [1 2 3 b] c [d &#x05D4;?!] &#x05D5;...&#x202C;</div>
     43      <div dir="rtl">&#x202D;...f [!?e &#x05D3;] &#x05D2; [&#x05D1; 3 2 1] a&#x202C;</div>
     44    </div>
     45  </body>
     46 </html>