mirror of
https://github.com/twbs/bootstrap.git
synced 2025-04-09 01:53:53 +02:00
Use getBoundingClientRect instead of jQuery
This commit is contained in:
parent
2725acc9e5
commit
3f2a8db471
@ -426,7 +426,8 @@ const Modal = (($) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
_checkScrollbar() {
|
_checkScrollbar() {
|
||||||
this._isBodyOverflowing = $('body').outerWidth(true) < window.innerWidth
|
const rect = document.body.getBoundingClientRect()
|
||||||
|
this._isBodyOverflowing = rect.left + rect.right < window.innerWidth
|
||||||
this._scrollbarWidth = this._getScrollbarWidth()
|
this._scrollbarWidth = this._getScrollbarWidth()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user