blob: 537fb031a568f82f7f12c456be59d700827f9b2b [file] [log] [blame]
<!DOCTYPE html>
<meta charset="utf-8">
<meta name="assert" content="A position-visibility: anchors-visible element should be visible if the anchor is under overflow: visible." />
<title>CSS Anchor Positioning Test: position-visibility: anchors-visible in overflow</title>
<link rel="help" href="https://drafts.csswg.org/css-anchor-position-1/#position-visibility">
<link rel="match" href="position-visibility-anchors-visible-in-overflow-ref.html">
<style>
#outer-container {
width: 100px;
height: 100px;
overflow: visible;
position: relative;
}
#inner-container {
width: 100px;
height: 100px;
overflow: visible;
position: relative;
}
#anchor {
anchor-name: --anchor;
position: relative;
margin-left: 200px;
width: 100px;
height: 100px;
background: orange;
}
#spacer {
height: 200px;
}
#target-a {
position-anchor: --anchor;
position-visibility: anchors-visible;
position-area: top left;
width: 50px;
height: 50px;
background: green;
position: absolute;
top: 0;
left: 0;
}
#target-b {
position-anchor: --anchor;
position-visibility: anchors-visible;
position-area: center left;
width: 50px;
height: 50px;
background: green;
position: absolute;
top: 0;
left: 0;
}
#target-c {
position-anchor: --anchor;
position-visibility: anchors-visible;
position-area: bottom left;
width: 50px;
height: 50px;
background: green;
position: absolute;
top: 0;
left: 0;
}
</style>
<div id="outer-container">
<div id="inner-container">
<div id="spacer"></div>
<div id="anchor">anchor</div>
<div id="target-a">target-a</div>
</div>
<div id="target-b">target-b</div>
</div>
<div id="target-c">target-c</div>