Skip to content

Commit

Permalink
Fixes initial position of DataTableContextMenu
Browse files Browse the repository at this point in the history
  • Loading branch information
HendrikThePendric committed Mar 20, 2018
1 parent 4501fdf commit f4db16c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/data-table/DataTableContextMenu.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,14 @@ function DataTableContextMenu(props, context) {
.keys(props.actions)
.filter(menuActionKey => typeof props.actions[menuActionKey] === 'function');

// Transition and left styles were added to prevent initial rendering in top-left
// https://github.com/mui-org/material-ui/issues/8040
const cmStyle = {
position: 'fixed',
left: -1000,
transition: 'left 0s, top 0s',
};

const {
actions,
activeItem,
Expand Down

0 comments on commit f4db16c

Please sign in to comment.