diff --git a/cypress/e2e/10-settings-log-streaming.cy.ts b/cypress/e2e/10-settings-log-streaming.cy.ts index a302b9e4dc..9acec76f42 100644 --- a/cypress/e2e/10-settings-log-streaming.cy.ts +++ b/cypress/e2e/10-settings-log-streaming.cy.ts @@ -46,6 +46,7 @@ describe('Log Streaming Settings', () => { it('should create a destination and delete it', () => { cy.enableFeature('logStreaming'); cy.visit('/settings/log-streaming'); + cy.wait(1000); // Race condition with getDestinationDataFromBackend() settingsLogStreamingPage.actions.clickAddFirstDestination(); cy.wait(100); settingsLogStreamingPage.getters.getDestinationModal().should('be.visible'); @@ -73,6 +74,7 @@ describe('Log Streaming Settings', () => { it('should create a destination and delete it via card actions', () => { cy.enableFeature('logStreaming'); cy.visit('/settings/log-streaming'); + cy.wait(1000); // Race condition with getDestinationDataFromBackend() settingsLogStreamingPage.actions.clickAddFirstDestination(); cy.wait(100); settingsLogStreamingPage.getters.getDestinationModal().should('be.visible'); diff --git a/packages/editor-ui/src/components/SettingsLogStreaming/EventDestinationSettingsModal.ee.vue b/packages/editor-ui/src/components/SettingsLogStreaming/EventDestinationSettingsModal.ee.vue index 9d846e5056..723ffc38d4 100644 --- a/packages/editor-ui/src/components/SettingsLogStreaming/EventDestinationSettingsModal.ee.vue +++ b/packages/editor-ui/src/components/SettingsLogStreaming/EventDestinationSettingsModal.ee.vue @@ -189,7 +189,7 @@ import { defaultMessageEventBusDestinationSentryOptions, } from 'n8n-workflow'; import type { PropType } from 'vue'; -import { defineComponent, nextTick } from 'vue'; +import { defineComponent } from 'vue'; import { LOG_STREAM_MODAL_KEY, MODAL_CONFIRM } from '@/constants'; import Modal from '@/components/Modal.vue'; import { useMessage } from '@/composables'; @@ -378,9 +378,7 @@ export default defineComponent({ if (newDestination) { this.headerLabel = newDestination?.label ?? this.headerLabel; - void nextTick(() => { - this.setupNode(newDestination); - }); + this.setupNode(newDestination); } }, valueChanged(parameterData: IUpdateInformation) { diff --git a/packages/editor-ui/src/components/TagsDropdown.vue b/packages/editor-ui/src/components/TagsDropdown.vue index a60d288ff5..c78df4a479 100644 --- a/packages/editor-ui/src/components/TagsDropdown.vue +++ b/packages/editor-ui/src/components/TagsDropdown.vue @@ -155,12 +155,11 @@ export default defineComponent({ } else if (keyboardEvent.key === 'Enter' && filter.value.length === 0) { preventUpdate.value = true; - // Disable blur event due to element-plus handler changes - // emit('blur'); - // - // if (typeof selectRef.value?.blur === 'function') { - // selectRef.value.blur(); - // } + emit('blur'); + + if (typeof selectRef.value?.blur === 'function') { + selectRef.value.blur(); + } } }); } diff --git a/packages/editor-ui/src/stores/logStreaming.store.ts b/packages/editor-ui/src/stores/logStreaming.store.ts index 7d44182f4c..397dc4d6cc 100644 --- a/packages/editor-ui/src/stores/logStreaming.store.ts +++ b/packages/editor-ui/src/stores/logStreaming.store.ts @@ -67,7 +67,7 @@ export const useLogStreamingStore = defineStore('logStreaming', { state.items[destination.id].destination = destination; } // to trigger refresh - state.items = deepCopy(state.items); + state.items = { ...state.items }; }); } }, @@ -162,6 +162,8 @@ export const useLogStreamingStore = defineStore('logStreaming', { delete this.items[id]; }, clearDestinationItemTrees() { + console.log('clearing destinations'); + this.items = {} as DestinationSettingsStore; }, setSelectionAndBuildItems(destination: MessageEventBusDestinationOptions) { diff --git a/packages/editor-ui/src/views/SettingsLogStreamingView.vue b/packages/editor-ui/src/views/SettingsLogStreamingView.vue index 589c2f99e1..c8841b170a 100644 --- a/packages/editor-ui/src/views/SettingsLogStreamingView.vue +++ b/packages/editor-ui/src/views/SettingsLogStreamingView.vue @@ -73,7 +73,7 @@