Bug 1942006 - Upstream a variety of Servo-specific code from Servo's downstream fork...
[gecko.git] / layout / reftests / forms / legend / legend-padding-1-ref.html
blob950d8d1833cbc6673887615db1408239ddc720ce
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <title>Reference for bug 1483499</title>
5 <style>
6 legend, .legendRef {
7 /* Here in the reference case, we explicitly specify padding, and we also
8 use a custom-styled div as the reference case for any legend element
9 that is not directly snapped into a fieldset border. */
10 background: yellow;
11 border: 1px solid brown;
12 padding: 0px 2px;
14 </style>
15 </head>
16 <body>
17 <!-- Test: legend default styling shouldn't be affected
18 by presence of a display:contents wrapper: -->
19 <fieldset>
20 <legend>DisplayContentsWrapper</legend>
21 </fieldset>
22 <br>
24 <!-- Test: legend should get the same 2px of inline-axis padding, even
25 if it's not inside of a fieldset at all. -->
26 <div class="legendRef">JustALegend</div>
27 <br>
29 <div class="legendRef">
30 <div class="legendRef">NestedLegend</div>
31 </div>
32 <br>
34 <fieldset>
35 <legend>
36 <div class="legendRef">
37 <div class="legendRef">NestedLegendInFieldset</div>
38 </div>
39 </legend>
40 </fieldset>
42 </body>
43 </html>