blob: b8d45152c05e034bd9d4467438b4f5ab125f646a [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>href on a maction toggle</title>
<script type="text/javascript">
function test()
{
var event = new MouseEvent('click', {bubbles: true, cancelable: true});
document.getElementById('link').dispatchEvent(event);
}
</script>
</head>
<body onload="test()">
<p>This test passes if you see a green square.</p>
<div style="width: 150px; height: 150px; overflow: hidden">
<math>
<!-- Initially, the maction element displays its second child which is a red mspace.
After the click, the selection moves to the third child which is a green mspace.
We should not follow the link, whose target is a red space.
-->
<maction id="link" href="#target" actiontype="toggle" selection="2">
<mspace width="150px" height="150px" mathbackground="red"/>
<mspace width="150px" height="150px" mathbackground="red"/>
<mspace width="150px" height="150px" mathbackground="green"/>
</semantics>
</math>
<div style="height: 500px;"></div>
<math id="target">
<mspace id="space" width="150px" height="150px" mathbackground="red"/>
</math>
</div>
</body>
</html>