mirror of
https://github.com/zulip/zulip.git
synced 2025-11-05 14:35:27 +00:00
Popover menus: Fix disappearing popover on small screens.
The popover would go to the top of the screen and would disappear when the screen height is small. Fixes #29472
This commit is contained in:
@@ -336,7 +336,10 @@ function get_props_for_popover_centering(
|
|||||||
return {
|
return {
|
||||||
arrow: false,
|
arrow: false,
|
||||||
getReferenceClientRect: () => new DOMRect(0, 0, 0, 0),
|
getReferenceClientRect: () => new DOMRect(0, 0, 0, 0),
|
||||||
placement: "top",
|
// Since we are resetting the reference to (0,0) in DOM the placement here doesn't matter
|
||||||
|
// Using "bottom" placement as it works well with Popper's positioning system
|
||||||
|
// when the popover exceeds window height
|
||||||
|
placement: "bottom",
|
||||||
popperOptions: {
|
popperOptions: {
|
||||||
modifiers: [
|
modifiers: [
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user