t32-opacity-offscreen-multiple-boxes-2-c

opacity

WeasyPrint

Reference (good) by WeasyPrint

Reference (good) by this browser

This browser

Assertion
Opacity is group opacity over elements (not boxes).

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3 	<head>
 4 		<title>CSS Test: opacity</title>
 5 		<link rel="author" title="L. David Baron" href="https://dbaron.org/">
 6 		<link rel="author" title="Mozilla Corporation" href="http://mozilla.com/">
 7 		<link rel="help" href="http://www.w3.org/TR/css3-color/#transparency">
 8 		<link rel="match" href="reference/t32-opacity-offscreen-multiple-boxes-2-c-ref.htm">
 9 		<meta name="flags" content="">
10 		<meta name="assert" content="Opacity is group opacity over elements (not boxes).">
11 		<style type="text/css">
12 
13 		body { background: white; }
14 
15 		div.test { margin: 1em; line-height: 0; font-family: monospace; }
16 		div.test span { opacity: 0.4; }
17 		div.test span a { background: blue; color: blue; }
18 
19 		div.ref { height: 1em; width: 5em; background: rgb(153, 153, 255); }
20 
21 		</style>
22 	</head>
23 	<body>
24 
25 		<p>The following two boxes should be the same color:</p>
26 
27 		<div class="test"><span><a>XXXXX<br>XXXXX</a></span></div>
28 
29 		<div class="ref"></div>
30 
31 	</body>
32 </html>