summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/semantics/interactive-elements/the-dialog-element/top-layer-parent-opacity.html
blob: 46c5de2a6dd54a6564abf31f0bdb47e605c8fed0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<!DOCTYPE html>
<html>
<title>Test that parent opacity does not affect top layer elements</title>
<meta charset="utf-8">
<link rel="author" title="Tim Nguyen" href="https://github.com/nt1m">
<link rel="match" href="green-dialog-and-backdrop.html">
<link rel="help" href="https://fullscreen.spec.whatwg.org/#new-stacking-layer">
<link rel="help" href="https://bugs.webkit.org/show_bug.cgi?id=229317">
<style>
body { background: red; }

#parent {
    opacity: 0;
}

dialog::backdrop,
dialog {
    background: green;
    outline: none;
}
</style>
<body>
<div id="parent">
    <dialog>PASS if no red shows</dialog>
</div>
<script>
    document.querySelector("dialog").showModal();
</script>
</body>
</html>