Fix #11542. document.body should not be special in .offset() and document.documentElement is the default element.offsetParent. Close gh-899.

This commit is contained in:
Daniel Gálvez
2012-08-19 21:53:09 +02:00
committed by Dave Methvin
parent 69e2f068fe
commit b398a68333
3 changed files with 18 additions and 36 deletions

View File

@@ -5,8 +5,9 @@
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>body</title>
<style type="text/css" media="screen">
body { margin: 1px; padding: 5px; }
body { margin: 1px; padding: 5px; position: relative }
#marker { position: absolute; border: 2px solid #000; width: 50px; height: 50px; background: #ccc; }
#firstElement { width: 50px; height: 50px; background: green; }
</style>
<script src="../../../dist/jquery.js"></script>
<script type="text/javascript" charset="utf-8">
@@ -19,6 +20,7 @@
</script>
</head>
<body>
<div id="firstElement"></div>
<div id="marker"></div>
</body>
</html>