mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
fix(editor): Make node title non-editable in executions view (#5046)
🐛 Fix node title non-editable in executions
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<span :class="$style.container" data-test-id="node-title-container" @click="onEdit">
|
<span :class="$style.container" data-test-id="node-title-container" @click="onEdit">
|
||||||
<span :class="$style.iconWrapper"><NodeIcon :nodeType="nodeType" :size="18" /></span>
|
<span :class="$style.iconWrapper"><NodeIcon :nodeType="nodeType" :size="18" /></span>
|
||||||
<n8n-popover placement="right" width="200" :value="editName" :disabled="readOnly">
|
<n8n-popover placement="right" width="200" :value="editName" :disabled="!editable">
|
||||||
<div
|
<div
|
||||||
:class="$style.editContainer"
|
:class="$style.editContainer"
|
||||||
@keydown.enter="onRename"
|
@keydown.enter="onRename"
|
||||||
@@ -28,10 +28,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<template #reference>
|
<template #reference>
|
||||||
<div class="ph-no-capture" :class="{ [$style.title]: true, [$style.hoverable]: !readOnly }">
|
<div class="ph-no-capture" :class="{ [$style.title]: true, [$style.hoverable]: editable }">
|
||||||
{{ value }}
|
{{ value }}
|
||||||
<div :class="$style.editIconContainer">
|
<div :class="$style.editIconContainer">
|
||||||
<font-awesome-icon :class="$style.editIcon" icon="pencil-alt" v-if="!readOnly" />
|
<font-awesome-icon :class="$style.editIcon" icon="pencil-alt" v-if="editable" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -60,6 +60,11 @@ export default Vue.extend({
|
|||||||
newName: '',
|
newName: '',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
computed: {
|
||||||
|
editable(): boolean {
|
||||||
|
return !this.readOnly && window === window.parent;
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
onEdit() {
|
onEdit() {
|
||||||
this.newName = this.value;
|
this.newName = this.value;
|
||||||
|
|||||||
Reference in New Issue
Block a user