mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-17 14:26:35 +00:00
Tweak
This commit is contained in:
parent
0abafff4c9
commit
8f5c9295d3
@ -202,7 +202,7 @@ export class HaConfigDevicePage extends LitElement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this._diagnosticDownloadLinks = Math.random();
|
this._diagnosticDownloadLinks = Math.random();
|
||||||
this._deleteButtons = [".."];
|
this._deleteButtons = []; // To prevent re-rendering if no delete buttons
|
||||||
this._renderDiagnosticButtons(this._diagnosticDownloadLinks);
|
this._renderDiagnosticButtons(this._diagnosticDownloadLinks);
|
||||||
this._renderDeleteButtons();
|
this._renderDeleteButtons();
|
||||||
}
|
}
|
||||||
@ -316,7 +316,7 @@ export class HaConfigDevicePage extends LitElement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private async _confirmDeleteEntry(e: MouseEvent): Promise<void> {
|
private async _confirmDeleteEntry(e: MouseEvent): Promise<void> {
|
||||||
const entry_id = (e.currentTarget! as HTMLElement).getAttribute("entry_id")
|
const entry_id = (e.currentTarget! as HTMLElement).getAttribute("entry_id");
|
||||||
|
|
||||||
const confirmed = await showConfirmationDialog(this, {
|
const confirmed = await showConfirmationDialog(this, {
|
||||||
text: this.hass.localize("ui.panel.config.devices.confirm_delete"),
|
text: this.hass.localize("ui.panel.config.devices.confirm_delete"),
|
||||||
@ -326,7 +326,7 @@ export class HaConfigDevicePage extends LitElement {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
await removeConfigEntryFromDevice(this.hass!, this.deviceId, entry_id);
|
await removeConfigEntryFromDevice(this.hass!, this.deviceId, entry_id!);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected firstUpdated(changedProps) {
|
protected firstUpdated(changedProps) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user