aboutsummaryrefslogtreecommitdiff
path: root/ext/fg/js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2019-08-31 11:56:12 -0400
committertoasted-nutbread <toasted-nutbread@users.noreply.github.com>2019-08-31 11:57:09 -0400
commit85472d9407861f688e55b06b1767882f71229fc2 (patch)
treef31a137ca7277741109ce36cee5f6b544da71876 /ext/fg/js
parent68af0d86c3a941e185b34926fdbc57c457466e28 (diff)
Add option for position of popup for horizontal text
Diffstat (limited to 'ext/fg/js')
-rw-r--r--ext/fg/js/popup.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/fg/js/popup.js b/ext/fg/js/popup.js
index 138dec41..86ce575d 100644
--- a/ext/fg/js/popup.js
+++ b/ext/fg/js/popup.js
@@ -91,13 +91,15 @@ class Popup {
}
}
+ const preferBelow = (optionsGeneral.popupHorizontalTextPosition === 'below');
+
const verticalOffset = optionsGeneral.popupVerticalOffset;
const [y, h, below] = Popup.limitGeometry(
elementRect.top - verticalOffset,
elementRect.bottom + verticalOffset,
height,
maxHeight,
- true
+ preferBelow
);
return [x, y, width, h, below];