Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

Commit 78a1e9d

Browse files
stan-zpkozlowski-opensource
authored andcommitted
fix(datapicker): set popup initial position in append-to-body case
Set the initial position offsets of the datepicker popup element in case of appended to 'body'. Todo: refresh the position on parent elements resize.
1 parent 5d9bd05 commit 78a1e9d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/datepicker/datepicker.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ function ($compile, $parse, $document, $position, dateFilter, datepickerPopupCon
414414
}
415415

416416
function updatePosition() {
417-
scope.position = $position.position(element);
417+
scope.position = appendToBody ? $position.offset(element) : $position.position(element);
418418
scope.position.top = scope.position.top + element.prop('offsetHeight');
419419
}
420420

0 commit comments

Comments
 (0)