column-balancing-nested-001.html 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. <!--
  2. Any copyright is dedicated to the Public Domain.
  3. http://creativecommons.org/licenses/publicdomain/
  4. -->
  5. <!DOCTYPE html>
  6. <html lang="en-US">
  7. <head>
  8. <title>Testing nested balancing column sets</title>
  9. <link rel="author" title="Mats Palmgren" href="https://bugzilla.mozilla.org/show_bug.cgi?id=822053">
  10. <style type="text/css">
  11. html,body {
  12. color:black; background-color:white; font-family:monospace; font-size:16px; padding:0; margin:0;
  13. }
  14. .colset {
  15. -moz-column-count: 2;
  16. -moz-column-gap: 0px;
  17. -moz-column-rule: 1px solid black;
  18. margin-bottom:1em;
  19. width:30ch;
  20. }
  21. .colset.lvl2 {
  22. -moz-column-rule: 1px solid blue;
  23. }
  24. .colset.lvl3 {
  25. -moz-column-rule: 1px solid red;
  26. }
  27. p { margin: 0; }
  28. .non-balancing {
  29. -moz-column-fill: auto;
  30. }
  31. .fixed-height {
  32. height:3em;
  33. }
  34. </style>
  35. </head>
  36. <body>
  37. <div class="colset">
  38. <p>one one one one one</p>
  39. <div class="colset non-balancing lvl2">
  40. <p>two two two two two</p>
  41. </div>
  42. </div>
  43. <div class="colset">
  44. <p>one one one one one<br>one</p>
  45. <div class="colset fixed-height lvl2">
  46. <p>two two two two two</p>
  47. </div>
  48. </div>
  49. <div class="colset">
  50. <p>one<br>one</p>
  51. <div class="colset lvl2">
  52. <p>two</p>
  53. <div class="colset fixed-height lvl3">
  54. <p>three three three three three three</p>
  55. </div>
  56. </div>
  57. </div>
  58. </body>
  59. </html>