MCPcopy Index your code
hub / github.com/SeleniumHQ/selenium / getOverflowParent

Function getOverflowParent

javascript/atoms/typescript/is-displayed.ts:269–281  ·  view source on GitHub ↗
(current: Element)

Source from the content-addressed store, hash-verified

267 }
268
269 function getOverflowParent(current: Element): Element | null {
270 var position = getEffectiveStyle(current, 'position');
271 if (position === 'fixed') {
272 treatAsFixedPosition = true;
273 return current === htmlElem ? null : htmlElem;
274 }
275
276 var parent = getParentElement(current);
277 while (parent && !canBeOverflowed(parent, position)) {
278 parent = getParentElement(parent);
279 }
280 return parent;
281 }
282
283 function getOverflowStyles(current: Element): OverflowStyles {
284 var overflowElem = current;

Callers 1

getOverflowStateFunction · 0.70

Calls 3

getEffectiveStyleFunction · 0.85
getParentElementFunction · 0.85
canBeOverflowedFunction · 0.70

Tested by

no test coverage detected