mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Merge pull request #3157 from node-red/relabel-file-nodes
Add paletteLabel to file nodes to make read/write more obvious
This commit is contained in:
commit
126df969b3
@ -210,9 +210,10 @@
|
|||||||
if (this.overwriteFile === "delete") {
|
if (this.overwriteFile === "delete") {
|
||||||
return this.name||this._("file.label.deletelabel",{file:this.filename});
|
return this.name||this._("file.label.deletelabel",{file:this.filename});
|
||||||
} else {
|
} else {
|
||||||
return this.name||this.filename||this._("file.label.filelabel");
|
return this.name||this.filename||this._("file.label.write");
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
paletteLabel: RED._("node-red:file.label.write"),
|
||||||
labelStyle: function() {
|
labelStyle: function() {
|
||||||
return this.name?"node_label_italic":"";
|
return this.name?"node_label_italic":"";
|
||||||
},
|
},
|
||||||
@ -290,8 +291,9 @@
|
|||||||
},
|
},
|
||||||
icon: "file-in.svg",
|
icon: "file-in.svg",
|
||||||
label: function() {
|
label: function() {
|
||||||
return this.name||this.filename||this._("file.label.filelabel");
|
return this.name||this.filename||this._("file.label.read");
|
||||||
},
|
},
|
||||||
|
paletteLabel: RED._("node-red:file.label.read"),
|
||||||
labelStyle: function() {
|
labelStyle: function() {
|
||||||
return this.name?"node_label_italic":"";
|
return this.name?"node_label_italic":"";
|
||||||
},
|
},
|
||||||
|
@ -863,6 +863,8 @@
|
|||||||
},
|
},
|
||||||
"file": {
|
"file": {
|
||||||
"label": {
|
"label": {
|
||||||
|
"write": "write file",
|
||||||
|
"read": "read file",
|
||||||
"filename": "Filename",
|
"filename": "Filename",
|
||||||
"action": "Action",
|
"action": "Action",
|
||||||
"addnewline": "Add newline (\\n) to each payload?",
|
"addnewline": "Add newline (\\n) to each payload?",
|
||||||
@ -870,7 +872,6 @@
|
|||||||
"outputas": "Output",
|
"outputas": "Output",
|
||||||
"breakchunks": "Break into chunks",
|
"breakchunks": "Break into chunks",
|
||||||
"breaklines": "Break into lines",
|
"breaklines": "Break into lines",
|
||||||
"filelabel": "file",
|
|
||||||
"sendError": "Send message on error (legacy mode)",
|
"sendError": "Send message on error (legacy mode)",
|
||||||
"encoding": "Encoding",
|
"encoding": "Encoding",
|
||||||
"deletelabel": "delete __file__",
|
"deletelabel": "delete __file__",
|
||||||
|
Loading…
Reference in New Issue
Block a user