sql generator

This commit is contained in:
Jan Prochazka
2021-04-01 10:48:20 +02:00
parent d6ba822338
commit a3762c6caa
6 changed files with 30 additions and 5 deletions

View File

@@ -5,9 +5,11 @@ export default function contextMenu(node, items) {
const handleContextMenu = e => {
e.preventDefault();
e.stopPropagation();
const left = e.pageX;
const top = e.pageY;
currentDropDownMenu.set({ left, top, items: _.isFunction(items) ? items() : items });
if (items) {
const left = e.pageX;
const top = e.pageY;
currentDropDownMenu.set({ left, top, items: _.isFunction(items) ? items() : items });
}
};
node.addEventListener('contextmenu', handleContextMenu);