Skip to content

Commit

Permalink
fix(positioning): fix positioning with the width constraint
Browse files Browse the repository at this point in the history
Fixes #1876
Closes #1902
  • Loading branch information
mschoudry authored and pkozlowski-opensource committed Dec 15, 2017
1 parent 9a27911 commit 0df398c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util/positioning.ts
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ export class Positioning {
availablePlacementArr: Array<string>) {
let html = document.documentElement;
// check for left-bottom
if ((window.innerHeight || html.clientHeight) - hostElemClientRect.left >= targetElemClientRect.width) {
if ((window.innerWidth || html.clientWidth) - hostElemClientRect.left >= targetElemClientRect.width) {
availablePlacementArr.splice(availablePlacementArr.length, 1, primaryPlacement + '-left');
}
if (targetElemClientRect.width <= hostElemClientRect.right) {
Expand Down

0 comments on commit 0df398c

Please sign in to comment.