grapesjs icon indicating copy to clipboard operation
grapesjs copied to clipboard

[Feature]: Improve and fix absolute dragMode

Open damnslow opened this issue 3 years ago • 10 comments

GrapesJS version

  • [X] I confirm to use the latest version of GrapesJS

What browser are you using?

Chrome v93

Reproducible demo link

https://codepen.io/damnslow/pen/yLXXOxQ

Describe the bug

How to reproduce the bug?

  1. Select both the elements
  2. Drag using drag icon

What is the expected behavior? Both elements should move together

What is the current behavior? Only one element moves.

If is necessary to execute some code in order to reproduce the bug, paste it here below: No.

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

damnslow avatar Sep 12 '21 20:09 damnslow

Hi @artf, is there any workaround to solve this?

damnslow avatar Sep 25 '21 15:09 damnslow

Absolute positioning, right now, has more than one issue and I'd like to address them all here:

  • [ ] Wrong position on a different Devices
  • [ ] Wrong position on a zoomed/panned canvas
  • [ ] Wrong position for children of the absolute component
  • [ ] Support multiple selection
  • [ ] Support touch devices
  • [ ] Support % unit

I don't know exactly when I'll start working on it but I hope soon, and as always, any help is appreciated.

artf avatar Oct 16 '21 13:10 artf

Did you find time to deal with it? I'm currently working on a drag and drop project and I'm having an issue with mispositioning on different devices also I can't use the setzoom function for mobile. I would be very grateful if you would take care of this issue. (Google translate used.)

ahmet1340 avatar Nov 14 '21 13:11 ahmet1340

These issues have still not been resolved and are frankly annoying. Changing the absolute dragging to a % instead of a px offset makes so much more sense and solves most issues, but for some reason wasn't chosen. Is there any plans to change this?

Adham380 avatar Feb 24 '22 12:02 Adham380

@Adham380 PRs are welcome

artf avatar Mar 05 '22 15:03 artf

Agree. It also affects the menu of NavBar in Mobile mode. If you set dragMode to "absolute" and move items in NavBar then switch to Mobile Preview mode, you'll see NavBar does not work.

dalmatele avatar Jul 11 '22 07:07 dalmatele

up

vizardkill avatar Feb 23 '23 15:02 vizardkill

Up

voleep avatar Mar 23 '23 04:03 voleep

Hi @artf, this feature is crucial for my current project, so I have two questions:

  1. Is it possible to pay you (or someone else) to prioritize this feature?
  2. If not, can you outline the steps necessary to resolve the issue and give me a starting point?

fmfeit avatar Apr 20 '24 18:04 fmfeit