mirror of
https://github.com/tenrok/bootstrap.git
synced 2026-05-24 14:04:09 +03:00
Use getBoundingClientRect instead of jQuery
This commit is contained in:
+2
-1
@@ -426,7 +426,8 @@ const Modal = (($) => {
|
||||
}
|
||||
|
||||
_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()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user