Skip to content

Commit

Permalink
Do not show context menu options for moving columns on table body
Browse files Browse the repository at this point in the history
  • Loading branch information
krassowski committed Apr 22, 2024
1 parent b991491 commit 54c9d6e
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions src/launcher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -397,15 +397,17 @@ function LauncherBody(props: {
(event.target as HTMLElement).closest(
'th[data-id]'
) as HTMLElement
)?.dataset['id'] as string;
contextMenu.addItem({
command: CommandIDs.moveColumn,
args: { direction: 'left', order: columnOrder, id }
});
contextMenu.addItem({
command: CommandIDs.moveColumn,
args: { direction: 'right', order: columnOrder, id }
});
)?.dataset['id'];
if (id) {
contextMenu.addItem({
command: CommandIDs.moveColumn,
args: { direction: 'left', order: columnOrder, id }
});
contextMenu.addItem({
command: CommandIDs.moveColumn,
args: { direction: 'right', order: columnOrder, id }
});
}
contextMenu.open(event.clientX, event.clientY);
}}
>
Expand Down

0 comments on commit 54c9d6e

Please sign in to comment.