Skip to content

Is there any way to know that the drag was cancel by pressing esc key? #165

Open
@niranjan821

Description

@niranjan821

We have a virtualized list where a dragged item can be removed from the list when moved due to virtualization. If the user drags the item, brings it back to its original position, and presses the Esc key to cancel the drag, the onDrop event doesn’t trigger until the mouse is released. Instead, the onDragLeave event fires, but this also happens when the item is dragged out of the drop target.

To work around this, I tried using keyboard events to detect the Esc key press. However, the issue is that onDragLeave gets triggered even before the onKeyUp event, and the onKeyDown event doesn’t trigger at all.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions