Skip to content

Re-initiating drag on existing elements doesn't work in Firefox #1

@kineticquant

Description

@kineticquant

In the app.js file, specifically for function dragMoveStart, the event.dataTransfer.setData method is supposed to enable Firefox users to reposition existing elements on the canvas, but instead the elements disappear entirely.

Right now the functionality is only working on Chromium-based browsers.

function dragMoveStart(event) { event.dataTransfer.setData("text/plain", null); // for Firefox event.target.classList.add("dragging"); event.dataTransfer.effectAllowed = "move"; this.offsetX = event.clientX - event.target.offsetLeft; this.offsetY = event.clientY - event.target.offsetTop; }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions