tor-browser

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

690.html (1327B)


      1 <!DOCTYPE html> 
      2 <html>
      3  <head>
      4    <title>ARIA 1.0 Test Case 690</title>
      5    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      6  </head>
      7  <body>
      8    <h1>ARIA 1.0 Test Case 690</h1>
      9    
     10    <div id="TEST_ID_1">
     11    </div>
     12    
     13    <h2>Description</h2>
     14    <p>The aria-live attribute is added to an element in the document by a script after 
     15      the onload event completes with the value="assertive". After the aria-live attribute 
     16      is added, a child DOM text node is added to the element with the aria-live attribute.</p>
     17    
     18    <script>  
     19 
     20      function addChildTextNode() {
     21        var node         = document.getElementById('TEST_ID_2');  
     22        var text_node    = document.createTextNode("TEST TEXT");        
     23        node.appendChild(text_node);
     24      }
     25 
     26      function addLiveRegion() {
     27        var node         = document.getElementById('TEST_ID_1');  
     28        var element_node = document.createElement('div');        
     29        element_node.setAttribute('id', 'TEST_ID_2');
     30        element_node.setAttribute('aria-live', 'assertive');
     31        node.appendChild(element_node);
     32        setTimeout(addChildTextNode,500);
     33      }
     34 
     35      function onload() {
     36        setTimeout(addLiveRegion,1000);
     37      }
     38     
     39      window.addEventListener('load', onload);
     40    </script>
     41  </body>
     42  
     43 </html>