reactdatagrid icon indicating copy to clipboard operation
reactdatagrid copied to clipboard

Column context menu jump to top left of document

Open vasylHordynskyy opened this issue 3 years ago • 2 comments

  • what edition are you using - We are using enterprise
  • version for @inovua/reactdatagrid-enterprise - 5.8.4

Relevant code or config

What you did: We implement simple grid view. Size of our grid is small so when we open column context menu on last column, it is not fully shown. Then I changed columnContextMenuPosition property to fixed. Column context menu is fully shown.

What happened: When I try to hide or show some column, column context menu jumps to top left of document or disappear.

Reproduction repository: https://reactdatagrid.io/docs/api-reference#props-columnContextMenuPosition

Problem description: Column context menu jump to left top position of document or hidden when I hide or show column using context menu.

Suggested solution:

vasylHordynskyy avatar Feb 09 '23 20:02 vasylHordynskyy

I'm seeing the exact same behavior in 5.8.4 when columnContextMenuPosition is set to "fixed" and you attempt to add/remove columns. The context menu flies up to the left corner of the screen.

React_Data_Grid_Menu_Issue

DCMattyG avatar Feb 24 '23 06:02 DCMattyG

Same here. The problem can be reproduced directly from the code snippet in the docs. Seems like its related to constrainTo being hardcode to true here: https://github.com/inovua/reactdatagrid/blame/07e0045fc678899e6979c137e9438e255221e331/community-edition/plugins/menus/useMenus/renderColumnContextMenu.tsx#L493

peterlau avatar Oct 09 '23 22:10 peterlau

+1

guergana avatar Jul 16 '24 17:07 guergana