-
Notifications
You must be signed in to change notification settings - Fork 35
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
Incorrect position after mouse-wheel scroll #22
Comments
@aronhelser - Thanks for opening this issue. I'm wondering if the incorrect y-position you are experiencing persists after moving the mouse or only before the mouse is moved. Please let me know. |
It does persist after I move the mouse, but it's corrected if I exit the
element and then re-enter. I'm guessing that something that happens during
mouse-leave or mouse-enter needs to be triggered when the element is
scrolled.
What I'm not sure about is if you can get scroll events for your element
when it's just inside another element that's scrolled? (since that's what's
happening here).
…On Fri, Mar 16, 2018 at 12:57 AM, Ethan Selzer ***@***.***> wrote:
@aronhelser <https://github.com/aronhelser> - Thanks for opening this
issue. I'm wondering if the incorrect y-position you are experiencing
persists after moving the mouse or only before the mouse is moved. Please
let me know.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#22 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AS_pnXZL1oSALPa8EfGMFW2uhIWMvQZFks5te0YngaJpZM4SfN3a>
.
|
@ethanselzer I had a chance to illustrate the problem, thanks for providing a playground pen! https://codepen.io/ahelser/pen/JvPwPR If you mouse-wheel scroll, the position is reported as if it's unscrolled. But if you exit and re-enter, the position is corrected. Looking though your very clean and modular code, I see that you don't listen to scroll events at all. Seems like that would be necessary to fix this problem? |
Hi @aronhelser - Thanks for creating a reduced test case. That is very helpful. I'm working on an improvement that may correct the issue you have identified. I will post here when it is released. |
Hi @aronhelser - The latest release of react-cursor-position introduces the |
@aronhelser - I'm closing this issue for now. If you find your use case is not corrected by v2.5.0, please reopen the issue. Thanks! |
Thanks! Sorry I haven't been able to confirm - I should be able to test
soon.
…On Tue, Jul 24, 2018 at 3:32 PM Ethan Selzer ***@***.***> wrote:
@aronhelser <https://github.com/aronhelser> - I'm closing this issue for
now. If you find your use case is not corrected by v2.5.0, please reopen
the issue. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#22 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AS_pnebmIcgE9Jt7B0xDtxPgvN2IHN6Iks5uJ3ZdgaJpZM4SfN3a>
.
|
I'm seeing some incorrect y-positions after I scroll using my mouse wheel - the cursor remains inside the component. If I scroll by dragging the scroll bar, it's correct.
ReactCursorPosition and the component it's wrapping are inside a
div
withoverfow-y: auto
.I'm happy to provide more detail if needed.
The text was updated successfully, but these errors were encountered: