1 <!DOCTYPE html PUBLIC
"-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
4 <title>CSS Test: height set to
0 to elements with 'display' set to 'list-item'
</title>
6 <link rel=
"author" title=
"Gérard Talbot" href=
"http://www.gtalbot.org/BrowserBugsSection/css21testsuite/">
7 <link rel=
"author" title=
"Boris Zbarsky" href=
"bzbarsky@MIT.EDU">
8 <link rel=
"bookmark" title=
"Interesting testcase that some UAs appear to fail" href=
"http://lists.w3.org/Archives/Public/public-css-testsuite/2012Feb/0028.html">
9 <link rel=
"help" title=
"10.5 Content height: the 'height' property" href=
"http://www.w3.org/TR/CSS21/visudet.html#the-height-property">
10 <meta content=
"" name=
"flags">
11 <meta content=
"If height of content exceeds the set height of a block-level non-replaced element in normal flow (like a list-item element such as in this test), then the content should overflow according to the 'overflow' property." name=
"assert">
13 <!-- Adapted margin-top values to allow compensating values for height of 1px in the reference result-->
14 <style type=
"text/css">
42 li#yhidden
{ overflow-y:hidden
; }
43 li#xhidden
{ overflow-x:hidden
; }
45 ul#heightless
{ height: 0px; }
51 <p>Test passes if
<strong>5 green
"PASS"</strong> are each preceded by a filled disc.
</p>
53 <!--Inline content in div with display: list-item, overflow: visible and height:0 gets painted-->
54 <div id=
"heightzerolistitem">PASS
</div>
56 <!--Inline content in list-item with overflow: visible and height:0 gets painted-->
61 <!--Inline content in list-item and list-item parent with overflow: visible and height:0 gets painted-->
66 <!--Block content in div with display: list-item, overflow: visible and height:0 gets painted-->
67 <div id=
"heightzerolistitem" style=
"margin-top: 60px;"><div>PASS
</div></div>
69 <!--Block content in list-item with overflow: visible and height:0 gets painted-->
71 <li><div>PASS
</div></li>
74 <!--Inline content in div with display: list-item, overflow-y: hidden and height:0 does not get painted-->
75 <div id=
"heightzerolistitem" style=
"overflow-y:hidden;">PASS
</div>
77 <!--Inline content in list-item with overflow-y: hidden and height:0 does not get painted-->
79 <li id=
"yhidden">PASS
</li>
82 <!--Block content in list-item with overflow-y: hidden and height:0 does not get painted-->
84 <li id=
"yhidden"><div>PASS
</div></li>
87 <!--Inline content in div with display: list-item, overflow-x: hidden and height:0 does not get painted-->
88 <div id=
"heightzerolistitem" style=
"overflow-x:hidden;">PASS
</div>
90 <!--Inline content in list-item with overflow-x: hidden and height:0 does not get painted-->
92 <li id=
"xhidden">PASS
</li>
95 <!--Block content in list-item with overflow-x: hidden and height:0 does not get painted-->
97 <li id=
"xhidden"><div>PASS
</div></li>