Render header strings

This commit is contained in:
Iván Ovejero
2021-11-18 11:32:13 +01:00
parent f1eef04ad2
commit 99963b04a5
25 changed files with 467 additions and 61 deletions

View File

@@ -95,9 +95,26 @@ export default mixins(
return null;
},
nodeTypeName(): string {
if (this.nodeType) {
const shortNodeType = this.nodeType.name.replace('n8n-nodes-base.', '');
return this.$headerText({
key: `headers.${shortNodeType}.displayName`,
fallback: this.nodeType.name,
});
}
return '';
},
nodeTypeDescription (): string {
if (this.nodeType && this.nodeType.description) {
return this.nodeType.description;
const shortNodeType = this.nodeType.name.replace('n8n-nodes-base.', '');
return this.$headerText({
key: `headers.${shortNodeType}.description`,
fallback: this.nodeType.description,
});
} else {
return this.$baseText('nodeSettings.noDescriptionFound');
}