table-caption-2c-dyn.html 680 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <!DOCTYPE html>
  2. <html class="reftest-wait">
  3. <head>
  4. <style type="text/css">
  5. .separator {
  6. height: 20px;
  7. background-color: green;
  8. }
  9. #table {
  10. display: table;
  11. width: 100px;
  12. margin: 15px 0;
  13. }
  14. #caption {
  15. display: table-cell;
  16. height: 20px;
  17. margin: 15px 0;
  18. background-color: blue;
  19. }
  20. </style>
  21. <script type="text/javascript">
  22. function test() {
  23. document.getElementById('caption').style.display = 'table-caption';
  24. document.documentElement.removeAttribute('class');
  25. }
  26. document.addEventListener('MozReftestInvalidate', test, false);
  27. </script>
  28. </head>
  29. <body>
  30. <div class="separator"></div>
  31. <div id="table">
  32. <div id="caption"></div>
  33. </div>
  34. <div class="separator"></div>
  35. </body>
  36. </html>