https://github.com/web-platform-tests/wpt
Raw File
Tip revision: f9e3995a8d4d43f6ae0f1949f8615d2dfcdb7f66 authored by Sandra Sun on 28 March 2018, 01:57:21 UTC
Implement snapping for scroll with intended direction and end position.
Tip revision: f9e3995
unload-1.html
<!doctype html>
<html>
<head><title>Document</title></head>
<body>
<h1>Document</h1>
<script>
onload = function() {
  document.addEventListener("visibilitychange", onVisibilityChange, false);
  opener.postMessage("close", "*");
}

function onVisibilityChange() {
  opener.postMessage(document.visibilityState, "*");
}
</script>
</body>
</html>
back to top