Skip to content
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

dragTo should trigger mouseOver before drop #393

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

das-peter
Copy link

@das-peter das-peter commented Jun 28, 2024

Just fiddled with the Drag n Drop testing and came across an issue when testing it with ExtJs e.g. https://docs.sencha.com/extjs/4.2.2/extjs-build/examples/tree/custom-drop-logic.html
Dragging works fine - but dropping runs into nothing because the destination event isn't "ready".
I think most dynamic libraries prepare the destination by listening to a hover event - which currently isn't triggered when dragging n droping.
However, I think the native browser behavior indeed would trigger a mouse over before a drop event.
Hence the added event before the button up.

Tested with:

Feature: DragNDropTest
    Scenario: DragNDropTest
        Given I go to "https://docs.sencha.com/extjs/4.2.2/extjs-build/examples/tree/custom-drop-logic.html"
        And I wait for "2" seconds
        And I drag "#treeview-1013-record-ext-record-1" to "#treeview-1017-record-ext-record-6 div"

Without the patch it fails, with the patch it works as expected.


Found that the mouseover / button up might cause the destination element to be stale.
Added a re-fetch before the final event trigger to avoid that issue.

@uuf6429
Copy link
Member

uuf6429 commented Jan 13, 2025

Seems to relate to #408. Let's continue the discussion there.

@uuf6429
Copy link
Member

uuf6429 commented Jan 20, 2025

@das-peter the PR I mentioned earlier has now been merged. Could you try your test again with it and see if the issue persists? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants