views: Cleaned up status display
This commit is contained in:
parent
1c74d2e50b
commit
d2b7a7c10b
|
@ -25,7 +25,7 @@ class KlipperPlugin(
|
||||||
|
|
||||||
def get_template_configs(self):
|
def get_template_configs(self):
|
||||||
return [
|
return [
|
||||||
dict(type="navbar", custom_bindings=False),
|
dict(type="navbar", custom_bindings=True),
|
||||||
dict(type="settings", custom_bindings=True),
|
dict(type="settings", custom_bindings=True),
|
||||||
dict(type="sidebar",
|
dict(type="sidebar",
|
||||||
custom_bindings=True,
|
custom_bindings=True,
|
||||||
|
|
|
@ -133,6 +133,6 @@ $(function() {
|
||||||
dependencies: ["settingsViewModel", "loginStateViewModel", "connectionViewModel"],
|
dependencies: ["settingsViewModel", "loginStateViewModel", "connectionViewModel"],
|
||||||
|
|
||||||
// elements this view model will be bound to.
|
// elements this view model will be bound to.
|
||||||
elements: ["#tab_plugin_klipper", "#sidebar_plugin_klipper", "#settings_plugin_klipper"]
|
elements: ["#tab_plugin_klipper", "#sidebar_plugin_klipper", "#settings_plugin_klipper", "#navbar_plugin_klipper"]
|
||||||
});
|
});
|
||||||
});
|
});
|
|
@ -1 +1 @@
|
||||||
<a href="#" data-bind="attr: {href: settings.settings.plugins.klipper.url}">Status: Connected</a>
|
<a href="#tab_plugin_klipper" data-bind="text: shortStatus">Idle</a>
|
|
@ -1,5 +1,3 @@
|
||||||
<label><span class="label label-success" data-bind="text: shortStatus">Connected</span></label>
|
|
||||||
|
|
||||||
<label for="connection_printers" data-bind="css: {disabled: !connectionState.isErrorOrClosed()}, enable: connectionState.isErrorOrClosed() && loginState.isUser()">{{ _('Printer Profile') }}</label>
|
<label for="connection_printers" data-bind="css: {disabled: !connectionState.isErrorOrClosed()}, enable: connectionState.isErrorOrClosed() && loginState.isUser()">{{ _('Printer Profile') }}</label>
|
||||||
<select id="connection_printers" data-bind="options: connectionState.printerOptions, optionsText: 'name', optionsValue: 'id', value: connectionState.selectedPrinter, css: {disabled: !connectionState.isErrorOrClosed()}, enable: connectionState.isErrorOrClosed() && loginState.isUser()"></select>
|
<select id="connection_printers" data-bind="options: connectionState.printerOptions, optionsText: 'name', optionsValue: 'id', value: connectionState.selectedPrinter, css: {disabled: !connectionState.isErrorOrClosed()}, enable: connectionState.isErrorOrClosed() && loginState.isUser()"></select>
|
||||||
<!--
|
<!--
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span8">
|
<div class="span8">
|
||||||
<label>Log <span class="label label-success" data-bind="text: shortStatus">Connected</span> </label>
|
|
||||||
<hr>
|
<hr>
|
||||||
<div class="plugin_klipper_msg" data-bind="foreach: logMessages">
|
<div class="plugin_klipper_msg" data-bind="foreach: logMessages">
|
||||||
<div><i data-bind="text: time"></i> <span data-bind="text: msg"></span></div>
|
<div><i data-bind="text: time"></i> <span data-bind="text: msg"></span></div>
|
||||||
|
|
Loading…
Reference in New Issue