mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-11-21 11:04:24 +00:00
Position: Support positioning within document with jQuery 1.6.x
Fixes #10071 Closes gh-1294
This commit is contained in:
parent
f7429edfe9
commit
9bb51d308e
@ -123,8 +123,11 @@ $.position = {
|
||||
offset: withinElement.offset() || { left: 0, top: 0 },
|
||||
scrollLeft: withinElement.scrollLeft(),
|
||||
scrollTop: withinElement.scrollTop(),
|
||||
width: isWindow ? withinElement.width() : withinElement.outerWidth(),
|
||||
height: isWindow ? withinElement.height() : withinElement.outerHeight()
|
||||
|
||||
// support: jQuery 1.6.x
|
||||
// jQuery 1.6 doesn't support .outerWidth/Height() on documents or windows
|
||||
width: isWindow || isDocument ? withinElement.width() : withinElement.outerWidth(),
|
||||
height: isWindow || isDocument ? withinElement.height() : withinElement.outerHeight()
|
||||
};
|
||||
}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user