summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/layers/scroll-no-visible-content-but-visible-descendant.html
blob: cca09c9b94ae8dd73f03783781fec2ceb7498a7a (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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<!DOCTYPE html>
<html>
<head>
<style>
div {
    height: 100px;
    width: 100px;
}

#outerDiv {
    visibility: hidden;
    overflow: hidden;
}

.paddingBlockNoVisibleDescendantOrContent {
    position: relative;
    background: red;
    visibility: visible;
}

.noVisibleContentVisibleWrapper {
    position: relative;
    visibility: visible;
}

.greenContainer {
    background: green;
}
</style>
<script>
    function scroll()
    {
        var outerDiv = document.getElementById("outerDiv");
        outerDiv.scrollTop = "100";
    }
    window.addEventListener("load", scroll, false);
</script>
</head>
<body>
<!--
    Bug 76126: REGRESSION (r94016): Visibility hidden to visible override with outer fixed inner relative elements
    This test has PASSED if there is only a green square and no red!
-->
<div class="hidden noOverflow" id="outerDiv">
    <div class="paddingBlockNoVisibleDescendantOrContent"></div>
    <div class="noVisibleContentVisibleWrapper">
        <div class="greenContainer"></div>
    </div>
</div>
</body>
</html>