Opened 14 years ago

Closed 10 years ago

#4305 closed bug (invalid)

Sortable: Revert placeholder calcing position

Reported by: Zebulon Owned by: Zebulon
Priority: minor Milestone: 2.0.0
Component: ui.sortable Version: 1.7
Keywords: Cc:
Blocked by: Blocking:


The placeholder margins left & top are not included in the revert position calcing causing a gap if margin(s) are defined.

Here's a fix ( works fine FF & Safari ) :

Line 288 - Function _mouseStop :

if(this.options.revert) { var self = this; var cur = self.placeholder.offset(); self.reverting = true;

var margin_left=parseInt(self.placeholder.css('marginLeft'),10);
var margin_top=parseInt(self.placeholder.css('marginTop'),10);


left: cur.left - margin_left .......... ,
top: - margin_top ...........

}, parseInt(this.options.revert, 10)
500, function() { self._clear(event); });

Change History (4)

comment:1 Changed 14 years ago by Jörn Zaefferer

Milestone: 1.8

comment:2 Changed 10 years ago by Scott González


comment:3 Changed 10 years ago by petersendidit

Owner: set to Zebulon
Status: newpending
Summary: Revert placeholder calcing positionSortable: Revert placeholder calcing position

Thanks for taking the time to contribute to the jQuery UI project! Please provide a complete reduced test case on jsFiddle to help us assess your ticket.

Additionally, be sure to test against the git version of both jQuery UI and jQuery to ensure the issue still exists. To get you started, use this boilerplate: the link and click to "Fork" (in the top menu) to get started.

comment:4 Changed 10 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.