Opened 10 years ago

Closed 10 years ago

#7976 closed bug (worksforme)

Sortable Items Selector (Parent > Child) not working

Reported by: SouthernLlama Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.sortable Version: 1.8.17
Keywords: Cc:
Blocked by: Blocking:

Description

'Sortable' component doesn't allow sorting of items when the 'items' option is specified with a parent-child selector (or ancestor-descendant selector).

For example, none of these will work:

"ul > li"
".a > .b"
".a .b"

I find this odd given that this selector does works:

> li

Change History (1)

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

Resolution: worksforme
Status: newclosed

This works fine for me. You're probably trying to use the sortable element or an ancestor in your selector. The selector must match elements from within the element. This of it is $( sortableElement ).find( items ).

Note: See TracTickets for help on using tickets.