blob: 4dde038c725a128a77af8ba962bd46d3db035f93 [file] [log] [blame]
<html>
<head>
<style>
#target {
position: relative;
width: 100px;
height: 100px;
}
#target::before {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: gray;
content: "";
}
</style>
<script type="text/javascript" charset="utf-8">
if (window.testRunner)
testRunner.dumpAsText();
function runTest()
{
var hitElement = document.elementFromPoint(58, 58);
var results = document.getElementById('results')
if (hitElement && hitElement.id == 'target')
results.innerHTML = 'elementFromPoint found target: PASS';
else
results.innerHTML = 'elementFromPoint did not find target: FAIL';
}
</script>
</head>
<body onload="runTest()">
<p>Tests hit testing on generated content</p>
<div id="target">&nbsp;</div>
<div id="results">
</div>
</body>
</html>