jQuery Sortable List - scroll bar jumps up when sorting

后端 未结 13 1035
慢半拍i
慢半拍i 2020-12-24 12:28

I created a demo: http://pastebin.me/584b9a86d715c9ba85b7bebf0375e237

When the scroll bar is at the bottom and you drag items to sort them, it causes the scroll bar

13条回答
  •  醉梦人生
    2020-12-24 13:13

    I had this issue in Chrome. And all sortable divs had fixed height.

    Problem was in css property position: relative of these divs. When div was dragged and removed from DOM, it's coordinates were calculated wrong due to relative position.

    Inherit or absolute positioning should be used for sortable elements.

提交回复
热议问题