Pitmairen/selection-search

Incorrect menu display on https://rutor.info

Opened this issue · 1 comments

Hi,
Thanks for the great extension.
On https://rutor.info, when highlighting and clicking, the menu is constantly displayed at the top.
The gif shows clearly https://file.coffee/u/7pGGFiUAfOjhuO02Cm5nW.gif
This only happens on Firefox

Looks like this is caused by wrong calculation of the window height, so the extension thinks the popup is opened outside of the browser view and tries to move it to compensate.

The extension is currently using document.documentElement.clientHeight to get the window height. I think this can be replaced by window.innerHeight to fix the issue.