Opened 8 years ago

Last modified 6 years ago

#11086 open bug

Sortable: Helper keeps moveing away because of margin

Reported by: syl.fabre Owned by:
Priority: minor Milestone: none
Component: ui.sortable Version: 1.11.2
Keywords: Cc:
Blocked by: Blocking:


JS Fiddle:

Step to reproduce

  1. Drag slowly a draggable over the 1st sortable
  2. Keep dragging down over the 2nd one
  3. A white space is going to appear between the 2 sortables
  4. If you keep moving slowly down right in order to keep the helper between the 2 you'll see that the helper almost keep its place but do not follow the mouse cursor

This is because you keep overing / outing the 2nd sortable. Every entry over the sortable calls _mouseStart which has the following code which seems to keep removing the margins near lines 210 of sortable.js

Change History (5)

comment:1 Changed 8 years ago by Scott González

Status: newopen
Summary: Helper keeps moveing away because of marginSortable: Helper keeps moveing away because of margin

The margin (white space) between the sortables isn't really related. I'm also not sure what code you're intending to refer to. Could use a less distracting test case.

comment:2 Changed 8 years ago by syl.fabre

@scott The margins I'm referring to is not the white space between the 2 sortables but the margin of the draggable elements (.draggable). If you remove this 5px margin in the CSS part, the problem goes away. I'll try to add a screenshot movie later

comment:3 Changed 8 years ago by Scott González

I know what margins you're referring to (hence the ticket being marked valid), please don't add a video. Step #3 is what I was referring to, which is just a distraction. Even with the bug being fixed, that behavior will continue to exist and is just poor UX.

comment:4 Changed 8 years ago by syl.fabre

@scott yes point #3 isn't a bug. I was just trying to describe all the steps to reproduce the bug. Glad to hear that you understand what I meant :-)

comment:5 Changed 6 years ago by Scott González

#14822 is a duplicate of this ticket.

Note: See TracTickets for help on using tickets.