MCPcopy
hub / github.com/angular-ui/ui-grid / getYOffset

Function getYOffset

lib/test/angular/1.7.0/angular.js:5314–5333  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5312 }
5313
5314 function getYOffset() {
5315
5316 var offset = scroll.yOffset;
5317
5318 if (isFunction(offset)) {
5319 offset = offset();
5320 } else if (isElement(offset)) {
5321 var elem = offset[0];
5322 var style = $window.getComputedStyle(elem);
5323 if (style.position !== 'fixed') {
5324 offset = 0;
5325 } else {
5326 offset = elem.getBoundingClientRect().bottom;
5327 }
5328 } else if (!isNumber(offset)) {
5329 offset = 0;
5330 }
5331
5332 return offset;
5333 }
5334
5335 function scrollTo(elem) {
5336 if (elem) {

Callers 1

scrollToFunction · 0.70

Calls 3

isFunctionFunction · 0.70
isElementFunction · 0.70
isNumberFunction · 0.70

Tested by

no test coverage detected