mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 20:54:07 -08:00
fix(editor): Fix NDV unexpected re-render (#7532)
This commit is contained in:
parent
233683ce1a
commit
2853fcff73
|
@ -28,7 +28,7 @@
|
||||||
teleported
|
teleported
|
||||||
size="small"
|
size="small"
|
||||||
:modelValue="currentNodeName"
|
:modelValue="currentNodeName"
|
||||||
@update:modelValue="onSelect"
|
@update:modelValue="onInputNodeChange"
|
||||||
:no-data-text="$locale.baseText('ndv.input.noNodesFound')"
|
:no-data-text="$locale.baseText('ndv.input.noNodesFound')"
|
||||||
:placeholder="$locale.baseText('ndv.input.parentNodes')"
|
:placeholder="$locale.baseText('ndv.input.parentNodes')"
|
||||||
filterable
|
filterable
|
||||||
|
@ -432,9 +432,9 @@ export default defineComponent({
|
||||||
onUnlinkRun() {
|
onUnlinkRun() {
|
||||||
this.$emit('unlinkRun');
|
this.$emit('unlinkRun');
|
||||||
},
|
},
|
||||||
onSelect(value: string) {
|
onInputNodeChange(value: string) {
|
||||||
const index = this.parentNodes.findIndex((node) => node.name === value) + 1;
|
const index = this.parentNodes.findIndex((node) => node.name === value) + 1;
|
||||||
this.$emit('select', value, index);
|
this.$emit('changeInputNode', value, index);
|
||||||
},
|
},
|
||||||
onConnectionHelpClick() {
|
onConnectionHelpClick() {
|
||||||
if (this.activeNode) {
|
if (this.activeNode) {
|
||||||
|
|
|
@ -69,7 +69,7 @@
|
||||||
@unlinkRun="() => onUnlinkRun('input')"
|
@unlinkRun="() => onUnlinkRun('input')"
|
||||||
@runChange="onRunInputIndexChange"
|
@runChange="onRunInputIndexChange"
|
||||||
@openSettings="openSettings"
|
@openSettings="openSettings"
|
||||||
@select="onInputSelect"
|
@changeInputNode="onInputNodeChange"
|
||||||
@execute="onNodeExecute"
|
@execute="onNodeExecute"
|
||||||
@tableMounted="onInputTableMounted"
|
@tableMounted="onInputTableMounted"
|
||||||
@itemHover="onInputItemHover"
|
@itemHover="onInputItemHover"
|
||||||
|
@ -710,7 +710,7 @@ export default defineComponent({
|
||||||
pane,
|
pane,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
onInputSelect(value: string, index: number) {
|
onInputNodeChange(value: string, index: number) {
|
||||||
this.runInputIndex = -1;
|
this.runInputIndex = -1;
|
||||||
this.isLinkingEnabled = true;
|
this.isLinkingEnabled = true;
|
||||||
this.selectedInput = value;
|
this.selectedInput = value;
|
||||||
|
|
Loading…
Reference in a new issue