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 @@ -32,7 +32,7 @@ const POPOVER_BODY_PADDING = 2;
32
32
* The first argument passed to the `present` should be the popover. In order
33
33
* to position the popover relative to the element clicked, the event needs to be
34
34
* passed as the second argument. If the event is not passed, the popover will be
35
- * positioned at the top of the current view. See the [usage](#usage) section for
35
+ * positioned in the center of the current view. See the [usage](#usage) section for
36
36
* an example of passing this event.
37
37
*
38
38
* ### Dismissing
@@ -250,7 +250,7 @@ class PopoverTransition extends Transition {
250
250
let bodyWidth = window . innerWidth ;
251
251
let bodyHeight = window . innerHeight ;
252
252
253
- let targetTop = POPOVER_BODY_PADDING ;
253
+ let targetTop = ( bodyHeight / 2 ) - ( popoverHeight / 2 ) ;
254
254
let targetLeft = bodyWidth / 2 ;
255
255
let targetWidth = 0 ;
256
256
let targetHeight = 0 ;
You can’t perform that action at this time.
0 commit comments