Skip to content
This repository was archived by the owner on Sep 8, 2020. It is now read-only.
This repository was archived by the owner on Sep 8, 2020. It is now read-only.

Helper function returning list element bug #192

Closed
@jyonker

Description

@jyonker

We've noticed the bug mentioned in #186 also occurs when not using connected lists. Using a simple helper function like:

helper: function (e, ui) {
      return ui;
}

Causes the same sort of bug when you drag any item to the bottom of the list. Here's the simple example in codepen: http://codepen.io/anon/pen/Ecbqr

A simple fix that works is to expand upon the fix suggested in the other issue like this:

if (hasSortingHelper(element) 
&& !ui.item.sortable.received 
&& savedNodes.last()[0].nodeName === "#text") {

While this works, it doesn't look like the "right" solution. We're looking for some insight into a cleaner solution that achieves the same thing. Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions