Skip to content

Commit

Permalink
Fix popup config 'above/below' being flipped
Browse files Browse the repository at this point in the history
  • Loading branch information
Col-E committed Jan 16, 2025
1 parent 151f28e commit 5dc2786
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ public void show() {
? lastCaretBounds.getMaxX()
: lastCaretBounds.getMinX() - popup.getWidth();
double anchorY = config.getPopupPosition().isAbove()
? lastCaretBounds.getMaxY()
: lastCaretBounds.getMinY() - popupSize;
? lastCaretBounds.getMinY() - popupSize
: lastCaretBounds.getMaxY();

// choose other position if the popup is off-screen
// if the popup is off-screen, flip the popup to the other side of the caret on that axis
Expand Down

0 comments on commit 5dc2786

Please sign in to comment.