diff --git a/octoprint_klipper/static/css/klipper.css b/octoprint_klipper/static/css/klipper.css index 48dd006..c0a1434 100644 --- a/octoprint_klipper/static/css/klipper.css +++ b/octoprint_klipper/static/css/klipper.css @@ -238,7 +238,7 @@ div#klipper_editor { div#klipper_editor.modal { height: unset !important; } - + } div#klipper_editor .modal-header { @@ -272,7 +272,9 @@ div#klipper_editor .modal-body input[type="checkbox"] { } div#klipper_editor .modal-body .editor-controls { - flex: 0 auto 50px; + flex: 0 auto; + display: flex; + align-items: center; } div#klipper_editor .flex-end { diff --git a/octoprint_klipper/static/js/klipper_editor.js b/octoprint_klipper/static/js/klipper_editor.js index c13d215..8727811 100644 --- a/octoprint_klipper/static/js/klipper_editor.js +++ b/octoprint_klipper/static/js/klipper_editor.js @@ -38,18 +38,9 @@ $(function () { if (editor) { editor.session.setValue(config.content); + self.settings.settings.plugins.klipper.configuration.old_config(config.content); editor.clearSelection(); } - setInterval(function () { - if (editor) { - - - var modalbodyheight = $('#klipper_editor').height(); - //$('#conf_editor').height( modalbodyheight - 135 ); - editor.resize(); - - }; - }, 500); }; self.checkSyntax = function () { diff --git a/octoprint_klipper/templates/klipper_editor.jinja2 b/octoprint_klipper/templates/klipper_editor.jinja2 index bdae034..917ff27 100644 --- a/octoprint_klipper/templates/klipper_editor.jinja2 +++ b/octoprint_klipper/templates/klipper_editor.jinja2 @@ -24,11 +24,7 @@ {{ _('Check Syntax') }} - - +