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

Blur the active element when closing edit dialog via action

Fixes #2097
This commit is contained in:
Nick O'Leary 2019-04-26 16:33:43 +01:00
parent 3e20892fdf
commit b0d93df387
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -2431,10 +2431,12 @@ RED.editor = (function() {
init: function() {
RED.tray.init();
RED.actions.add("core:confirm-edit-tray", function() {
$(document.activeElement).blur();
$("#node-dialog-ok").click();
$("#node-config-dialog-ok").click();
});
RED.actions.add("core:cancel-edit-tray", function() {
$(document.activeElement).blur();
$("#node-dialog-cancel").click();
$("#node-config-dialog-cancel").click();
});