layout/reftests/bugs/323656-1.html

Wed, 31 Dec 2014 07:16:47 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:16:47 +0100
branch
TOR_BUG_9701
changeset 3
141e0f1194b1
permissions
-rw-r--r--

Revert simplistic fix pending revisit of Mozilla integration attempt.

michael@0 1 <!DOCTYPE html>
michael@0 2 <html>
michael@0 3 <head>
michael@0 4 <title>Test inheritance through various table anonymous boxes</title>
michael@0 5 <style>
michael@0 6 /**
michael@0 7 * The idea is that "color" inherits by default while "border-color" does
michael@0 8 * not. So if the former is red and the latter is green on a parent, and
michael@0 9 * the child's border-color is set to "inherit", it'll be green only if
michael@0 10 * the child is inheriting from the parent. If not, it'll either be
michael@0 11 * whatever the border-color is on what it's inheriting from, which will
michael@0 12 * be red if what it's inheriting from has the default (currentColor)
michael@0 13 * border-color).
michael@0 14 */
michael@0 15
michael@0 16 /* 't' for "test" */
michael@0 17 * { color: red; border: 0px hidden red; background: transparent }
michael@0 18 .t { border-color: green }
michael@0 19 .t > :first-child
michael@0 20 { border-color: inherit; border-style: solid; border-width: 10px }
michael@0 21 </style>
michael@0 22 <script>
michael@0 23 function makeDiv() {
michael@0 24 return document.createElement("div");
michael@0 25 }
michael@0 26
michael@0 27 window.onload = function() {
michael@0 28 var lst = document.getElementsByClassName("d");
michael@0 29 for (var i = 0; i < lst.length; ++i) {
michael@0 30 lst[i].appendChild(makeDiv());
michael@0 31 }
michael@0 32 }
michael@0 33 </script>
michael@0 34 </head>
michael@0 35 <body>
michael@0 36 <table><tr><td class="t"><div></div></td></tr></table>
michael@0 37 <div style="display: table" class="t"><div></div></div>
michael@0 38 <div style="display: table-row-group" class="t"><div></div></div>
michael@0 39 <div style="display: table-row" class="t"><div></div></div>
michael@0 40 <div style="display: table-cell" class="t"><div></div></div>
michael@0 41 <div><span><div style="display: table" class="t"><div></div></div></span></div>
michael@0 42 <div><span><div style="display: table-row-group" class="t"><div></div></div></span></div>
michael@0 43 <div><span><div style="display: table-row" class="t"><div></div></div></span></div>
michael@0 44 <div><span><div style="display: table-cell" class="t"><div></div></div></span></div>
michael@0 45
michael@0 46 <table><tr><td class="t d"></td></tr></table>
michael@0 47 <div style="display: table" class="t d"></div>
michael@0 48 <div style="display: table-row-group" class="t d"></div>
michael@0 49 <div style="display: table-row" class="t d"></div>
michael@0 50 <div style="display: table-cell" class="t d"></div>
michael@0 51 <div><span><div style="display: table" class="t d"></div></span></div>
michael@0 52 <div><span><div style="display: table-row-group" class="t d"></div></span></div>
michael@0 53 <div><span><div style="display: table-row" class="t d"></div></span></div>
michael@0 54 <div><span><div style="display: table-cell" class="t d"></div></span></div>
michael@0 55 </body>
michael@0 56 </html>

mercurial