Skip to content

Commit

Permalink
Fix datepicker popup position when displayed above its text field
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Bosch authored and ceari committed Mar 24, 2014
1 parent e110b09 commit 30f2b1b
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,7 @@
this.layout(this.gDiv);
switch (options.position){
case 'top':
top -= inputfield.offsetHeight;
top -= cal.outerHeight();
break;
case 'left':
left -= inputfield.offsetWidth;
Expand All @@ -489,6 +489,10 @@
top += inputfield.offsetHeight;
left -= cal.outerWidth() - inputfield.offsetWidth;
break;
case 'top-right':
top -= cal.outerHeight() - inputfield.offsetHeight;
left += inputfield.offsetWidth;
break;
}

cal.css({
Expand Down

0 comments on commit 30f2b1b

Please sign in to comment.