mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Update range node ui
This commit is contained in:
@@ -59,7 +59,7 @@
|
||||
category: 'function',
|
||||
defaults: {
|
||||
action: {value:"replace",required:true},
|
||||
property: {value:"payload"},
|
||||
property: {value:"payload",required:true},
|
||||
from: {value:"",validate: function(v) {
|
||||
if (this.action == "change" && this.reg) {
|
||||
try {
|
||||
@@ -79,7 +79,14 @@
|
||||
outputs: 1,
|
||||
icon: "swap.png",
|
||||
label: function() {
|
||||
return this.name || this.action || "change";
|
||||
if (this.name) {
|
||||
return this.name;
|
||||
}
|
||||
if (this.action == "replace") {
|
||||
return "set msg."+this.property;
|
||||
} else {
|
||||
return this.action+" msg."+this.property
|
||||
}
|
||||
},
|
||||
labelStyle: function() {
|
||||
return this.name ? "node_label_italic" : "";
|
||||
|
Reference in New Issue
Block a user