(current: Element)
| 304 | } |
| 305 | |
| 306 | function getScroll(current: Element): Coordinate { |
| 307 | if (current === htmlElem) { |
| 308 | return { |
| 309 | x: ownerDoc.defaultView ? ownerDoc.defaultView.pageXOffset : 0, |
| 310 | y: ownerDoc.defaultView ? ownerDoc.defaultView.pageYOffset : 0, |
| 311 | }; |
| 312 | } |
| 313 | |
| 314 | return { x: current.scrollLeft, y: current.scrollTop }; |
| 315 | } |
| 316 | |
| 317 | for (var container = getOverflowParent(elem); container; container = getOverflowParent(container)) { |
| 318 | var containerOverflow = getOverflowStyles(container); |