I have a parent div
with many child divs.
I want when a child div
is dragged inside the parent div
, then the parent div
to scroll. When the parent div
is the body, it works. But I want it to work with my own parent "content" div
.
Here is a js example of the problem: http://jsfiddle.net/yzx4ft46/
Any ideas why it doesn't work?
It seems that the parent div must have
position: relative
and it started working:)Since the cloned element has position
absolute
and absolute positioning is positioned according to the first parent element with other then static positioning, then it is needed the parent element to haveposition: relative
.