Browse Source

fix: context menu covering connection delete button

Ahmad Kholid 3 years ago
parent
commit
d76370a29b
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/components/newtab/workflow/WorkflowBuilder.vue

+ 3 - 0
src/components/newtab/workflow/WorkflowBuilder.vue

@@ -758,6 +758,9 @@ export default {
       });
       });
       editor.value.on('export', saveEditorState);
       editor.value.on('export', saveEditorState);
       editor.value.on('contextmenu', ({ clientY, clientX, target }) => {
       editor.value.on('contextmenu', ({ clientY, clientX, target }) => {
+        if (target.tagName === 'path' && target.classList.contains('main-path'))
+          return;
+
         const isBlock = target.closest('.drawflow .drawflow-node');
         const isBlock = target.closest('.drawflow .drawflow-node');
         const virtualEl = {
         const virtualEl = {
           getReferenceClientRect: () => ({
           getReferenceClientRect: () => ({