From fcdf252f03b0f734069b60d505bf60814ad0c5e3 Mon Sep 17 00:00:00 2001 From: Steve-Mcl Date: Wed, 27 Apr 2022 12:52:01 +0100 Subject: [PATCH] rename jsonButtons to toolbarButtons --- .../@node-red/editor-client/src/js/ui/diagnostics.js | 2 +- .../@node-red/editor-client/src/js/ui/editors/json.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/diagnostics.js b/packages/node_modules/@node-red/editor-client/src/js/ui/diagnostics.js index 5fc2f4c3e..4e4a2d657 100644 --- a/packages/node_modules/@node-red/editor-client/src/js/ui/diagnostics.js +++ b/packages/node_modules/@node-red/editor-client/src/js/ui/diagnostics.js @@ -25,7 +25,7 @@ RED.diagnostics = (function () { value: json, requireValid: true, readOnly: true, - jsonButtons: [ + toolbarButtons: [ { text: RED._('clipboard.export.copy'), icon: 'fa fa-copy', 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 281fad400..ad80f88b9 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 @@ -509,9 +509,9 @@ open: function(tray) { var trayBody = tray.find('.red-ui-tray-body'); var dialogForm = RED.editor.buildEditForm(tray.find('.red-ui-tray-body'),'dialog-form',type,'editor'); - var jsonButtons = options.jsonButtons || []; - if (jsonButtons.length) { - jsonButtons.forEach(function (button) { + var toolbarButtons = options.toolbarButtons || []; + if (toolbarButtons.length) { + toolbarButtons.forEach(function (button) { var element = $('') .insertBefore("#node-input-json-reformat") .on("click", function (evt) {