tor-browser

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

details-add-summary.html (819B)


      1 <!DOCTYPE html>
      2 <html class="reftest-wait">
      3 <link rel=match href="details-add-summary-ref.html">
      4 <link rel=author href="mailto:jarhar@chromium.org">
      5 <link rel=help href="https://github.com/whatwg/html/pull/6466">
      6 
      7 <!-- This test makes sure that new <summary> elements get rendered correctly
      8  when added to a <details> element. I ran into it when adding
      9  content-visibility:hidden to the second slot of <details>. -->
     10 
     11 <script>
     12 onload = () => {
     13  const newsummary = document.createElement('summary');
     14  newsummary.textContent = 'new summary';
     15  document.getElementById('detailsid').insertBefore(newsummary,
     16    document.getElementById('oldsummary'));
     17 
     18  document.documentElement.classList.remove('reftest-wait');
     19 };
     20 </script>
     21 
     22 <details id=detailsid>
     23  <summary id=oldsummary>old summary</summary>
     24  details
     25 </details>