Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="Stack Overflow pointer events example">
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
<body>
    <div class="container">
        <svg class="stage-layer">
            <rect width="200" height="200"></rect>
        </svg>
        <div class="application-layer">
            <div class="scrollable">
                <p>foo</p>
                <p>foo</p>
                <p>foo</p>
                <p>foo</p>
                <p>foo</p>
                <p>foo</p>
            </div>
        </div>
    </div>
</body>
</html>
 
.container {
    position: relative;
    width: 400px;
    height: 400px;
    border: 2px solid black;
}
.stage-layer {
    position: absolute;
    width: 100%;
    box-sizing: border-box;
    height: 100%;
    border: 2px solid yellow;
}
.application-layer {
    position: relative;
    box-sizing: border-box;
    height: 100%;
    border: 2px solid pink;
    pointer-events: none;
}
rect:hover {
    fill: blue;
}
.scrollable {
    overflow: auto;
    color: hotpink;
    height: 100px;
}
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
OliverJAshpro
0viewers