summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/filter-effects/filtered-inline-is-container-ref.html
blob: aa6c12e33b5bc3779c9a49ee3c9edd69ffe2ed8f (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
52
53
54
55
56
57
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Filter: Filtered inline establishes a containing block.</title>
<link rel="author" title="Vladimir Levin" href="mailto:vmpstr@chromium.org">

<style>
#scroller {
  width: 500px;
  height: 500px;
  overflow: scroll
}
.spacer {
  width: 1000px;
  height: 500px;
  background-color: lightgreen;
}
#transform {
  /* no-op filter */
  transform: translateX(0px);
}
#fixed, #absolute {
  width: 100px;
  height: 100px;
}
#fixed {
  position: fixed;
  top: 100px;
  left: 150px;
  background-color: green;
}
#absolute {
  position: absolute;
  top: 200px;
  left: 300px;
  background-color: blue;
}
</style>

<div id="scroller">
  <div class="spacer">
  </div>
  <div id="transform">
    a
    <div id="fixed"></div>
    <div id="absolute"></div>
  </div>
  <div class="spacer">
  </div>
</div>

<script>
window.onload = function() {
  document.getElementById("scroller").scrollTo(50, 250);
}
</script>