diff --git a/octoprint_customControl/static/js/customControl.js b/octoprint_customControl/static/js/customControl.js index aaa57b1..0dcf6d1 100644 --- a/octoprint_customControl/static/js/customControl.js +++ b/octoprint_customControl/static/js/customControl.js @@ -231,7 +231,7 @@ } control.name = ko.observable(control.name || ""); - control.style = ko.observable(control.style || ""); + control.customClass = ko.observable(control.customClass || ""); control.width = ko.observable(control.hasOwnProperty("width") ? control.width : "2"); control.offset = ko.observable(control.hasOwnProperty("offset") ? control.offset : ""); @@ -321,7 +321,7 @@ return; } - element.style("btn " + style); + element.customClass("btn " + style); } self.deleteElement = function (invokedOn, contextParent, selectedMenu) { var element = self.searchElement(self.controlsFromServer, contextParent.attr('id')); diff --git a/octoprint_customControl/static/js/customControlDialog.js b/octoprint_customControl/static/js/customControlDialog.js index d5ecd1d..e2e8b8f 100644 --- a/octoprint_customControl/static/js/customControlDialog.js +++ b/octoprint_customControl/static/js/customControlDialog.js @@ -59,7 +59,7 @@ self.reset = function (data) { var element = { name: undefined, - style: "", + cusotmClass: "", collapsed: false, commands: "", confirm: "", @@ -106,7 +106,7 @@ } case "command": { el.name = obj.name; - el.style = "btn"; + el.customClass = "btn"; if (obj.commands.indexOf('\n') == -1) el.command = obj.commands; else @@ -167,7 +167,7 @@ case "script": { el.name = obj.name; - el.style = "btn"; + el.customClass = "btn"; el.script = obj.script; if (self.useConfirm()) { diff --git a/octoprint_customControl/templates/customControl_hookedsettings.jinja2 b/octoprint_customControl/templates/customControl_hookedsettings.jinja2 index 2f7727e..62600d2 100644 --- a/octoprint_customControl/templates/customControl_hookedsettings.jinja2 +++ b/octoprint_customControl/templates/customControl_hookedsettings.jinja2 @@ -86,10 +86,9 @@ @@ -110,7 +109,7 @@ -