Migrate to bootstrap 4 in LeafWeb

This commit is contained in:
2019-12-06 22:29:15 -05:00
parent f9a452045f
commit 88469b19be
248 changed files with 20293 additions and 21639 deletions
+25
View File
@@ -0,0 +1,25 @@
import getStyleComputedProperty from './getStyleComputedProperty';
import getParentNode from './getParentNode';
/**
* Check if the given element is fixed or is inside a fixed parent
* @method
* @memberof Popper.Utils
* @argument {Element} element
* @argument {Element} customContainer
* @returns {Boolean} answer to "isFixed?"
*/
export default function isFixed(element) {
const nodeName = element.nodeName;
if (nodeName === 'BODY' || nodeName === 'HTML') {
return false;
}
if (getStyleComputedProperty(element, 'position') === 'fixed') {
return true;
}
const parentNode = getParentNode(element);
if (!parentNode) {
return false;
}
return isFixed(parentNode);
}