mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
feat(editor): Replace root events with event bus events (no-changelog) (#6454)
* feat: replace root events with event bus events * fix: prevent cypress from replacing global with globalThis in import path * feat: remove emitter mixin * fix: replace component events with event bus * fix: fix linting issue * fix: fix breaking expression switch * chore: prettify ndv e2e suite code
This commit is contained in:
@@ -166,6 +166,7 @@ import type { IPermissions } from '@/permissions';
|
||||
import { getWorkflowPermissions } from '@/permissions';
|
||||
import { createEventBus } from 'n8n-design-system';
|
||||
import { useCloudPlanStore } from '@/stores';
|
||||
import { nodeViewEventBus } from '@/event-bus';
|
||||
|
||||
const hasChanged = (prev: string[], curr: string[]) => {
|
||||
if (prev.length !== curr.length) {
|
||||
@@ -445,7 +446,7 @@ export default defineComponent({
|
||||
return;
|
||||
}
|
||||
|
||||
this.$root.$emit('importWorkflowData', { data: workflowData });
|
||||
nodeViewEventBus.emit('importWorkflowData', { data: workflowData });
|
||||
};
|
||||
|
||||
const inputRef = this.$refs.importFile as HTMLInputElement | undefined;
|
||||
@@ -505,7 +506,7 @@ export default defineComponent({
|
||||
},
|
||||
)) as MessageBoxInputData;
|
||||
|
||||
this.$root.$emit('importWorkflowUrl', { url: promptResponse.value });
|
||||
nodeViewEventBus.emit('importWorkflowUrl', { url: promptResponse.value });
|
||||
} catch (e) {}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user