Skip to content

Commit 8ff0ac2

Browse files
the custom parent bug for positioning
if you set the appendTo property to another tag instead of body, and if the container is scrollable, there will be a tiny bug for positioning on scrolled container, so if you add this line to the src , it will function well ! :)
1 parent 59a1293 commit 8ff0ac2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/jquery.autocomplete.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,7 @@
337337

338338
parentOffsetDiff = $container.offsetParent().offset();
339339
styles.top -= parentOffsetDiff.top;
340+
styles.top += containerParent.scrollTop;
340341
styles.left -= parentOffsetDiff.left;
341342

342343
if (!that.visible){

0 commit comments

Comments
 (0)