-indentation

-css
This commit is contained in:
thelastWallE 2021-03-16 19:32:01 +01:00
parent bc6302e967
commit c1e2cb5ae0
2 changed files with 14 additions and 16 deletions

View File

@ -118,19 +118,19 @@ class KlipperPlugin(
) )
return data return data
def reloadConfigfile(self): def reloadConfigfile(self):
data = octoprint.plugin.SettingsPlugin.on_settings_load(self) data = octoprint.plugin.SettingsPlugin.on_settings_load(self)
filepath = os.path.expanduser( filepath = os.path.expanduser(
self._settings.get(["configuration", "configpath"])) self._settings.get(["configuration", "configpath"]))
try: try:
f = open(filepath, "r", encoding="utf-8") f = open(filepath, "r", encoding="utf-8")
data["config"] = f.read() data["config"] = f.read()
f.close() f.close()
except IOError: except IOError:
self._logger.error( self._logger.error(
"Error: Klipper config file not found at: {}".format(filepath)) "Error: Klipper config file not found at: {}".format(filepath))
return data return data
def on_settings_save(self, data): def on_settings_save(self, data):
if "config" in data: if "config" in data:

View File

@ -42,11 +42,11 @@
padding: 1px; padding: 1px;
} }
ul#klipper-settings { ul#klipper-settings {
margin: 0; margin: 0;
} }
#klipper-settings a{ #klipper-settings a{
margin: 5px; margin: 5px;
} }
@ -62,8 +62,6 @@ ul#klipper-settings {
} }
#tab_plugin_klipper_main .span8 { #tab_plugin_klipper_main .span8 {
min-width: 50%;
width: unset;
flex-grow: 8; flex-grow: 8;
float: left; float: left;
box-sizing: border-box; box-sizing: border-box;