blob: d360697c375121f7d392b60a7112ae98f27bef22 [file] [log] [blame]
<html xmlns='http://www.w3.org/1999/xhtml'>
<head>
<style>
body {
margin: 0px;
padding: 0px;
border: 1px solid black;
}
#square {
fill: blue;
}
#square:hover {
fill: green;
}
</style>
</head>
<body>
<table><tr><td>
<svg width='100px' height='100px' xmlns='http://www.w3.org/2000/svg'>
<svg>
<rect id='square' width='100' height='100' onclick='alert("You clicked the square! It worked!")'/>
</svg>
</svg>
</td></tr></table>
<script><![CDATA[
if (window.testRunner) {
testRunner.dumpAsText();
}
var hitElement = document.elementFromPoint(50, 50);
var hitSuccess = hitElement && hitElement == document.getElementById("square");
document.body.innerHTML = hitSuccess ? "PASSED" : "FAIL, hit " + hitElement + " @ 50, 50";
]]></script>
</body>
</html>