tor-browser

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

717.html (1550B)


      1 <!DOCTYPE html> 
      2 <html>
      3  <head>
      4    <title>ARIA 1.0 Test Case 717</title>
      5    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      6  </head>
      7  <body>
      8    <h1>ARIA 1.0 Test Case 717</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 
     15      after the onload event completes with the value="polite" and the element has 
     16      a child DOM element node that contains text content. After the aria-live 
     17      attribute is added, the CSS 'display' property of the child DOM element 
     18      node is changed to display="none".</p>
     19    
     20    <script>  
     21 
     22      function hideElement() {
     23        var node  = document.getElementById('TEST_ID_2');  
     24        node.style.display = "none";
     25      }
     26 
     27      function addLiveRegion() {
     28        var node = document.getElementById('TEST_ID_1');  
     29        
     30        var live_node = document.createElement('div');
     31        live_node.setAttribute('aria-live', 'polite');
     32 
     33        var element_node = document.createElement('div');
     34        element_node.setAttribute('id', 'TEST_ID_2');
     35       
     36        var text_node = document.createTextNode('TEST TEXT');
     37        
     38        element_node.appendChild(text_node);
     39        live_node.appendChild(element_node);
     40        node.appendChild(live_node);
     41        
     42        setTimeout(hideElement,500);
     43      }
     44 
     45      function onload() {
     46        setTimeout(addLiveRegion,1000);
     47      }
     48     
     49      window.addEventListener('load', onload);
     50    </script>
     51  </body>
     52  
     53 </html>