Skip to content

Commit

Permalink
Window may be scrolled when modal appears
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-nelson committed Sep 22, 2020
1 parent c1c925c commit d0df3ce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/dropdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -398,8 +398,8 @@
if (this.options.container == document.body) {
idealHeight = dropdownBRect.height;
idealWidth = triggerBRect.width;
idealXPos = triggerBRect.left;
idealYPos = triggerBRect.top;
idealXPos = triggerBRect.left + window.scrollX;
idealYPos = triggerBRect.top + window.scrollY;
} else {
idealHeight = dropdownBRect.height;
idealWidth = dropdownBRect.width;
Expand Down

0 comments on commit d0df3ce

Please sign in to comment.