1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Refix #3170 - copy switch rule type when adding new rule

This commit is contained in:
Nick O'Leary 2021-10-14 21:47:49 +01:00
parent 6cb06c146d
commit fded1e0021
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -211,6 +211,7 @@
var lastRule = $("#node-input-rule-container").editableList('getItemAt',i-1);
var exportedRule = exportRule(lastRule.element);
opt.r.vt = exportedRule.vt;
opt.r.v = "";
// We could copy the value over as well and preselect it (see the 'activeElement' code below)
// But not sure that feels right. Is copying over the last value 'expected' behaviour?
// It would make sense for an explicit 'copy' action, but not sure where the copy button would