File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -376,7 +376,7 @@ $.ui.position = {
376
376
newOverBottom ;
377
377
if ( overTop < 0 ) {
378
378
newOverBottom = position . top + myOffset + atOffset + offset + data . collisionHeight - outerHeight - withinOffset ;
379
- if ( newOverBottom < 0 || newOverBottom < Math . abs ( overTop ) ) {
379
+ if ( ( position . top + myOffset + atOffset + offset ) > overTop && ( newOverBottom < 0 || newOverBottom < Math . abs ( overTop ) ) ) {
380
380
data . elem
381
381
. addClass ( "ui-flipped-bottom" ) ;
382
382
@@ -385,7 +385,7 @@ $.ui.position = {
385
385
}
386
386
else if ( overBottom > 0 ) {
387
387
newOverTop = position . top - data . collisionPosition . marginTop + myOffset + atOffset + offset - withinOffset ;
388
- if ( newOverTop > 0 || Math . abs ( newOverTop ) < overBottom ) {
388
+ if ( ( position . top + myOffset + atOffset + offset ) > overBottom && ( newOverTop > 0 || Math . abs ( newOverTop ) < overBottom ) ) {
389
389
data . elem
390
390
. addClass ( "ui-flipped-top" ) ;
391
391
You can’t perform that action at this time.
0 commit comments