This is in 1.8RC1 (and seems to be a regression from 1.7):
(using jQuery 1.4.1)
If you have a sortable ul-li with 2 items at least, the dropping before the first item and after the last item doesn't work if you click to drag on the opposite side in the item to move:
- if you click in upper part to drag the first item after the last one doesn't work
- if you click in lower part to drag the first item after the last one WORKS
- if you click in upper part to drag the last item after the last one WORKS
- if you click in lower part to drag the last item after the last one doesn't work
doesn't work means that the placeholder doesn't appear, the items aren't moved, and on release the moving doesn't happen.
Same is true with any number of items, it's the dropping into the first position which looks at the position of the mouse taking in account the parent boundaries, instead of the real mouse position.
To replicate:
HTML:
<ul id="fieldValuesList"> <li><input type='text' value='' name='vNames[]' /></li> <li><input type='text' value='' name='vNames[]' /></li>
</ul>
jQuery:
$('#fieldValuesList').sortable( { items: 'li', containment: 'parent', animated: true, placeholder: 'fieldValuesList-selected' } );