-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong positioning of popover after scrolling #299
Comments
Thanks, I'll look into it when I can. |
I have encountered this problem before, what it turned out to be in my case is that my The proper way to add overflow-y is to style the |
@lostip Can you confirm that the solution posted by @episodeyang fixes your problem or not please? |
Closing due to inactivity. |
Apologies for the late response. |
Ok I think I see now. I might be able to fix this better than just CSS by altering where the popover HTML is placed. I haven't really used the editor in a short format so this isn't a point I've considered before. EDIT: I'm gonna schedule this for the next version as 1.3.0 is too overdue as it is. |
@lostip It's taken me a while to get back around to this - adding in the fix you mentioned earlier seems to work OK, but I don't have any CSS to test this with. I can commit based off your diff if you can confirm that that would fix your issue, but I would like to be able to test it myself. |
@SimeonC let me put together a plunkr or something like that so you can test this better. |
This should be patched in 1.3.8, I think. So if when you get around to testing this do it on that tag please. |
@lostip Could you setup a plnkr so we can update this issue? Thanks a lot. |
Issue reproduced at Plnkr
So basically I had to negate the addition of scope.displayElements.scrollWindow[0].scrollTop with itself (which amounts to zero px). Which means that the code before @lostip code was committed was just fine. I maybe wrong about it, but currently that is what is working for me. |
…e positioning of the popover on scrolling
fix(main): Corrected and improved the issue #299 around the positioni…
Corrected this with PR #1349. Closing - please test... |
hi, i have the same problem and i find a math problem inside the reflowPopover function, só i ll leave here the code that work for me as a suggestion to fix the problem.
|
for me setting the below option inside div worked |
When calling editorScope.showPopover(element), scroll position is not considered for positioning the popover.
Please see attached screenshots to see an example where no scrolling has occurred, and one where it has (this is a custom tool, but I'm using the provided popover).
Also, here's a diff with a possible fix, where the scrollTop is subtracted from the calculated top position in the reflowPopover function:
The text was updated successfully, but these errors were encountered: