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

When having a 2D grid system dragged item is not erased, creating a temporary tile #157

Open
vmuresanu opened this issue Oct 26, 2023 · 0 comments

Comments

@vmuresanu
Copy link

Describe the bug
When having a 2D grid system dragged item is not erased, thus placeholder generates a new tile.

Steps to reproduce the behavior:

  1. Have a 2D grid system with any number of divs of a specific height and width and a placeholder available.
  2. Drag any div
  3. Observe that the div is draggable but the original tile does not get removed, thus temporarily adding a new item and shuffling the rest of them

Expected behavior
The original tile is removed.

Screenshots
ngx-drag-drop issue

https://stackblitz.com/edit/stackblitz-starters-veznfz?description=An%20angular-cli%20project%20based%20on%20@angular/animations,%20@angular/common,%20@angular/compiler,%20@angular/core,%20@angular/forms,%20@angular/platform-browser,%20@angular/platform-browser-dynamic,%20@angular/router,%20core-js,%20rxjs,%20tslib%20and%20zone.js&file=src%2Fmain.ts,src%2Fapp.component.scss,src%2Fapp.component.html&title=Angular%20Starter

Desktop (please complete the following information):

  • OS: masOS Ventura - 13.5.2
  • Browser Chrome
  • Version 117.0.5938.88 (Official Build) (arm64)

Additional context
Note: Tried to remove the item from the array at DragStart method, but the dragged item also gets removed.
Note2: Maybe this is not a bug, and there is a way to remove the dragged item while keeping the dragging image availablem but I couldn't figure the way

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

No branches or pull requests

1 participant