mirror of
https://github.com/home-assistant/frontend.git
synced 2025-08-07 16:37:48 +00:00
Update zwave js buttons (#26404)
This commit is contained in:
parent
4e969ccf09
commit
b76407d28d
@ -230,6 +230,20 @@ class ZWaveJSConfigDashboard extends SubscribeMixin(LitElement) {
|
|||||||
)}
|
)}
|
||||||
</ha-button>`
|
</ha-button>`
|
||||||
: nothing}
|
: nothing}
|
||||||
|
<ha-button
|
||||||
|
class="remove-node-button"
|
||||||
|
@click=${this._removeNodeClicked}
|
||||||
|
appearance="filled"
|
||||||
|
.disabled=${this._status !== "connected" ||
|
||||||
|
(this._network?.controller.inclusion_state !==
|
||||||
|
InclusionState.Idle &&
|
||||||
|
this._network?.controller.inclusion_state !==
|
||||||
|
InclusionState.SmartStart)}
|
||||||
|
>
|
||||||
|
${this.hass.localize(
|
||||||
|
"ui.panel.config.zwave_js.common.remove_a_node"
|
||||||
|
)}
|
||||||
|
</ha-button>
|
||||||
</div>
|
</div>
|
||||||
</ha-card>
|
</ha-card>
|
||||||
<ha-card header="Diagnostics">
|
<ha-card header="Diagnostics">
|
||||||
@ -408,19 +422,6 @@ class ZWaveJSConfigDashboard extends SubscribeMixin(LitElement) {
|
|||||||
</ha-expansion-panel>
|
</ha-expansion-panel>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-actions">
|
<div class="card-actions">
|
||||||
<ha-button
|
|
||||||
appearance="plain"
|
|
||||||
@click=${this._removeNodeClicked}
|
|
||||||
.disabled=${this._status !== "connected" ||
|
|
||||||
(this._network?.controller.inclusion_state !==
|
|
||||||
InclusionState.Idle &&
|
|
||||||
this._network?.controller.inclusion_state !==
|
|
||||||
InclusionState.SmartStart)}
|
|
||||||
>
|
|
||||||
${this.hass.localize(
|
|
||||||
"ui.panel.config.zwave_js.common.remove_a_node"
|
|
||||||
)}
|
|
||||||
</ha-button>
|
|
||||||
<ha-button
|
<ha-button
|
||||||
appearance="plain"
|
appearance="plain"
|
||||||
@click=${this._rebuildNetworkRoutesClicked}
|
@click=${this._rebuildNetworkRoutesClicked}
|
||||||
@ -504,35 +505,35 @@ class ZWaveJSConfigDashboard extends SubscribeMixin(LitElement) {
|
|||||||
"ui.panel.config.zwave_js.dashboard.nvm_backup.download_backup"
|
"ui.panel.config.zwave_js.dashboard.nvm_backup.download_backup"
|
||||||
)}
|
)}
|
||||||
</ha-button>
|
</ha-button>
|
||||||
<div class="upload-button">
|
<div class="right-buttons">
|
||||||
|
<div class="upload-button">
|
||||||
|
<ha-button
|
||||||
|
appearance="filled"
|
||||||
|
@click=${this._restoreButtonClick}
|
||||||
|
>
|
||||||
|
<span class="button-content">
|
||||||
|
${this.hass.localize(
|
||||||
|
"ui.panel.config.zwave_js.dashboard.nvm_backup.restore_backup"
|
||||||
|
)}
|
||||||
|
</span>
|
||||||
|
</ha-button>
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
id="nvm-restore-file"
|
||||||
|
accept=".bin"
|
||||||
|
@change=${this._handleRestoreFileSelected}
|
||||||
|
style="display: none"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<ha-button
|
<ha-button
|
||||||
appearance="plain"
|
appearance="filled"
|
||||||
@click=${this._restoreButtonClick}
|
@click=${this._openConfigFlow}
|
||||||
variant="danger"
|
|
||||||
>
|
>
|
||||||
<span class="button-content">
|
${this.hass.localize(
|
||||||
${this.hass.localize(
|
"ui.panel.config.zwave_js.dashboard.nvm_backup.migrate"
|
||||||
"ui.panel.config.zwave_js.dashboard.nvm_backup.restore_backup"
|
)}
|
||||||
)}
|
|
||||||
</span>
|
|
||||||
</ha-button>
|
</ha-button>
|
||||||
<input
|
</div>`}
|
||||||
type="file"
|
|
||||||
id="nvm-restore-file"
|
|
||||||
accept=".bin"
|
|
||||||
@change=${this._handleRestoreFileSelected}
|
|
||||||
style="display: none"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<ha-button
|
|
||||||
variant="danger"
|
|
||||||
@click=${this._openConfigFlow}
|
|
||||||
class="migrate-button"
|
|
||||||
>
|
|
||||||
${this.hass.localize(
|
|
||||||
"ui.panel.config.zwave_js.dashboard.nvm_backup.migrate"
|
|
||||||
)}
|
|
||||||
</ha-button>`}
|
|
||||||
</div>
|
</div>
|
||||||
</ha-card>
|
</ha-card>
|
||||||
`
|
`
|
||||||
@ -989,7 +990,13 @@ class ZWaveJSConfigDashboard extends SubscribeMixin(LitElement) {
|
|||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.migrate-button {
|
.remove-node-button {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.right-buttons {
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -162,6 +162,7 @@ class ZWaveJSLogs extends SubscribeMixin(LitElement) {
|
|||||||
textarea {
|
textarea {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
padding: 16px;
|
padding: 16px;
|
||||||
|
font-family: var(--ha-font-family-code);
|
||||||
}
|
}
|
||||||
ha-card {
|
ha-card {
|
||||||
margin: 16px 0;
|
margin: 16px 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user