Initial commit
This commit is contained in:
12
wwwroot/lib/popper.js/esm/dom-utils/getWindow.js
Normal file
12
wwwroot/lib/popper.js/esm/dom-utils/getWindow.js
Normal file
@@ -0,0 +1,12 @@
|
||||
export default function getWindow(node) {
|
||||
if (node == null) {
|
||||
return window;
|
||||
}
|
||||
|
||||
if (node.toString() !== '[object Window]') {
|
||||
var ownerDocument = node.ownerDocument;
|
||||
return ownerDocument ? ownerDocument.defaultView || window : window;
|
||||
}
|
||||
|
||||
return node;
|
||||
}
|
||||
Reference in New Issue
Block a user