').appendTo(picker);
var metaRow = $('
').appendTo(picker);
var summary = $('
').appendTo(metaRow);
- var resetButton = $('').appendTo(metaRow).click(function(e) {
+ var resetButton = $('').appendTo(metaRow).on("click", function(e) {
e.preventDefault();
hide();
done(null);
@@ -925,7 +925,7 @@ RED.editor = (function() {
iconDiv.on("mouseout", function() {
summary.html(" ");
})
- iconDiv.click(function() {
+ iconDiv.on("click", function() {
hide();
done(moduleName+"/"+icon);
})
@@ -933,7 +933,7 @@ RED.editor = (function() {
}
});
picker.slideDown(100);
- searchInput.focus();
+ searchInput.trigger("focus");
}
function buildAppearanceForm(container,node) {
@@ -986,7 +986,7 @@ RED.editor = (function() {
var iconContainer = $('',{class:"palette_icon_container"}).appendTo(nodeDiv);
RED.utils.createIconElement(icon_url, iconContainer, true);
- iconButton.click(function(e) {
+ iconButton.on("click", function(e) {
e.preventDefault();
var iconPath;
var icon = $("#node-settings-icon").text()||"";
@@ -1597,7 +1597,7 @@ RED.editor = (function() {
text: RED._("subflow.edit"),
click: function() {
RED.workspaces.show(id);
- $("#node-dialog-ok").click();
+ $("#node-dialog-ok").trigger("click");
}
});
}
@@ -2069,7 +2069,7 @@ RED.editor = (function() {
});
select.append('');
- window.setTimeout(function() { select.change();},50);
+ window.setTimeout(function() { select.trigger("change");},50);
}
}
}
@@ -2281,7 +2281,7 @@ RED.editor = (function() {
$("#subflow-input-category").append($("").val("_custom_").text(RED._("palette.addCategory")));
- $("#subflow-input-category").change(function() {
+ $("#subflow-input-category").on("change", function() {
var val = $(this).val();
if (val === "_custom_") {
$("#subflow-input-category").width(120);
@@ -2397,7 +2397,7 @@ RED.editor = (function() {
if (options.expandable !== false) {
var expandButton = $('').appendTo(editor.toolbar);
- expandButton.click(function(e) {
+ expandButton.on("click", function(e) {
e.preventDefault();
var value = editor.getValue();
RED.editor.editMarkdown({
@@ -2432,13 +2432,13 @@ RED.editor = (function() {
RED.tray.init();
RED.actions.add("core:confirm-edit-tray", function() {
$(document.activeElement).blur();
- $("#node-dialog-ok").click();
- $("#node-config-dialog-ok").click();
+ $("#node-dialog-ok").trigger("click");
+ $("#node-config-dialog-ok").trigger("click");
});
RED.actions.add("core:cancel-edit-tray", function() {
$(document.activeElement).blur();
- $("#node-dialog-cancel").click();
- $("#node-config-dialog-cancel").click();
+ $("#node-dialog-cancel").trigger("click");
+ $("#node-config-dialog-cancel").trigger("click");
});
},
edit: showEditDialog,
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/buffer.js b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/buffer.js
index beec7ae98..ed8e19240 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/buffer.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/buffer.js
@@ -182,7 +182,7 @@
}
});
- $(".node-input-buffer-type").click(function(e) {
+ $(".node-input-buffer-type").on("click", function(e) {
e.preventDefault();
RED.sidebar.info.set(RED._("bufferEditor.modeDesc"));
RED.sidebar.info.show();
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/expression.js b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/expression.js
index 8a6d6e8dd..e4d154fbb 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/expression.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/expression.js
@@ -95,7 +95,7 @@
Object.keys(jsonata.functions).forEach(function(f) {
funcSelect.append($("").val(f).text(f));
})
- funcSelect.change(function(e) {
+ funcSelect.on("change", function(e) {
var f = $(this).val();
var args = RED._('jsonata:'+f+".args",{defaultValue:''});
var title = ""+f+"("+args+")
";
@@ -180,13 +180,13 @@
expressionEditor.session.removeMarker(currentFunctionMarker);
if (scopedFunction) {
//console.log(token,.map(function(t) { return t.type}));
- funcSelect.val(scopedFunction.value).change();
+ funcSelect.val(scopedFunction.value).trigger("change");
}
}
});
dialogForm.i18n();
- $("#node-input-expression-func-insert").click(function(e) {
+ $("#node-input-expression-func-insert").on("click", function(e) {
e.preventDefault();
var pos = expressionEditor.getCursorPosition();
var f = funcSelect.val();
@@ -194,7 +194,7 @@
expressionEditor.insertSnippet(snippet);
expressionEditor.focus();
});
- $("#node-input-expression-reformat").click(function(evt) {
+ $("#node-input-expression-reformat").on("click", function(evt) {
evt.preventDefault();
var v = expressionEditor.getValue()||"";
try {
@@ -231,7 +231,7 @@
lineNumbers: false
});
var changeTimer;
- $(".node-input-expression-legacy").click(function(e) {
+ $(".node-input-expression-legacy").on("click", function(e) {
e.preventDefault();
RED.sidebar.info.set(RED._("expressionEditor.compatModeDesc"));
RED.sidebar.info.show();
@@ -321,7 +321,7 @@
}
});
- $("#node-input-example-reformat").click(function(evt) {
+ $("#node-input-example-reformat").on("click", function(evt) {
evt.preventDefault();
var v = testDataEditor.getValue()||"";
try {
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/json.js b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/json.js
index 0ddc6934a..848c0105d 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/json.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/json.js
@@ -89,7 +89,7 @@
});
checkValid();
}
- $("#node-input-json-reformat").click(function(evt) {
+ $("#node-input-json-reformat").on("click", function(evt) {
evt.preventDefault();
var v = expressionEditor.getValue()||"";
try {
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/markdown.js b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/markdown.js
index 605ce0616..77619b61d 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/markdown.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/markdown.js
@@ -126,7 +126,7 @@
''+
'').appendTo(expressionEditor.toolbar);
- $("#node-btn-markdown-preview").click(function(e) {
+ $("#node-btn-markdown-preview").on("click", function(e) {
e.preventDefault();
if ($(this).hasClass("selected")) {
$(this).removeClass("selected");
@@ -172,7 +172,7 @@
var toolbar = $(toolbarTemplate).appendTo(container);
toolbar.find('button[data-style]').each(function(el) {
var style = styleActions[$(this).data('style')];
- $(this).click(function(e) {
+ $(this).on("click", function(e) {
e.preventDefault();
var current = editor.getSelectedText();
var range = editor.selection.getRange();
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/keyboard.js b/packages/node_modules/@node-red/editor-client/src/js/ui/keyboard.js
index 9218ad4c8..ab06edfdf 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/keyboard.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/keyboard.js
@@ -109,7 +109,7 @@ RED.h = handlers;
get: getSettingsPane,
focus: function() {
setTimeout(function() {
- $("#user-settings-tab-keyboard-filter").focus();
+ $("#user-settings-tab-keyboard-filter").trigger("focus");
},200);
}
})
@@ -399,11 +399,11 @@ RED.h = handlers;
var okButton = $('
').appendTo(div);
var revertButton = $('
').appendTo(div);
- okButton.click(function(e) {
+ okButton.on("click", function(e) {
e.stopPropagation();
endEditShortcut();
});
- revertButton.click(function(e) {
+ revertButton.on("click", function(e) {
e.stopPropagation();
RED.keyboard.revertToDefault(object.id);
container.empty();
@@ -426,7 +426,7 @@ RED.h = handlers;
buildShortcutRow(container,obj);
})
- keyInput.focus();
+ keyInput.trigger("focus");
}
}
@@ -510,7 +510,7 @@ RED.h = handlers;
var scope = $('
').appendTo(item);
$("").text(object.scope === '*'?'global':object.scope||"").appendTo(scope);
- container.click(editShortcut);
+ container.on("click", editShortcut);
}
function getSettingsPane() {
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/library.js b/packages/node_modules/@node-red/editor-client/src/js/ui/library.js
index c2c68a510..a939e8e23 100755
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/library.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/library.js
@@ -209,7 +209,7 @@ RED.library = (function() {
'
'
);
- $('#node-input-'+options.type+'-menu-open-library').click(function(e) {
+ $('#node-input-'+options.type+'-menu-open-library').on("click", function(e) {
activeLibrary = options;
loadLibraryFolder("local",options.url, "", function(items) {
var listing = [{
@@ -249,7 +249,7 @@ RED.library = (function() {
e.preventDefault();
});
- $('#node-input-'+options.type+'-menu-save-library').click(function(e) {
+ $('#node-input-'+options.type+'-menu-save-library').on("click", function(e) {
activeLibrary = options;
//var found = false;
var name = $("#"+elementPrefix+"name").val().replace(/(^\s*)|(\s*$)/g,"");
@@ -299,7 +299,7 @@ RED.library = (function() {
});
var itemTools = $("
").css({position: "absolute",bottom:"6px",right:"8px"});
var menuButton = $('
')
- .click(function(evt) {
+ .on("click", function(evt) {
evt.preventDefault();
evt.stopPropagation();
var elementPos = menuButton.offset();
@@ -368,12 +368,12 @@ RED.library = (function() {
cancelAdd();
}
})
- input.blur(function() {
+ input.on("blur", function() {
confirmAdd();
})
selected.treeList.addChild(newItem);
setTimeout(function() {
- input.focus();
+ input.trigger("focus");
input.select();
},400);
}
@@ -469,7 +469,7 @@ RED.library = (function() {
}
}
});
- $("#node-dialog-library-save-filename").keyup(function() { validateExportFilename($(this))});
+ $("#node-dialog-library-save-filename").on("keyup", function() { validateExportFilename($(this))});
$("#node-dialog-library-save-filename").on('paste',function() { var input = $(this); setTimeout(function() { validateExportFilename(input)},10)});
$( "#node-dialog-library-load" ).dialog({
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/notifications.js b/packages/node_modules/@node-red/editor-client/src/js/ui/notifications.js
index 7a6a3bbf7..533ef513f 100644
--- a/packages/node_modules/@node-red/editor-client/src/js/ui/notifications.js
+++ b/packages/node_modules/@node-red/editor-client/src/js/ui/notifications.js
@@ -105,7 +105,7 @@ RED.notifications = (function() {
if (options.buttons) {
var buttonSet = $('
').appendTo(n)
options.buttons.forEach(function(buttonDef) {
- var b = $('