Skip to content

Commit

Permalink
fix: render people-picker flyout inside window (#3326)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mnickii authored Oct 2, 2024
1 parent ae49332 commit 5a11252
Showing 1 changed file with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -364,8 +364,15 @@ export class MgtFlyout extends MgtBaseTaskComponent {
height = anchorRectTopToWindowTop;
}
} else {
top = anchorRect.bottom;
height = anchorRectBottomToWindowBottom;
if (anchorRectTopToWindowTop >= flyoutRect.height) {
// render above anchor
bottom = windowRect.height - anchorRect.top;
height = anchorRectTopToWindowTop;
} else {
// render below anchor
top = anchorRect.bottom;
height = anchorRectBottomToWindowBottom;
}
}
} else {
if (flyoutRect.height + 2 * this._edgePadding > windowRect.height) {
Expand Down

0 comments on commit 5a11252

Please sign in to comment.