Fix link on all backups button (#23374)

This commit is contained in:
Bram Kragten 2024-12-21 16:35:00 +01:00 committed by GitHub
parent 4de8b562bd
commit d403532fc1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3,7 +3,6 @@ import type { CSSResultGroup } from "lit";
import { css, html, LitElement } from "lit";
import { customElement, property } from "lit/decorators";
import memoizeOne from "memoize-one";
import { navigate } from "../../../../../common/navigate";
import "../../../../../components/ha-button";
import "../../../../../components/ha-card";
import "../../../../../components/ha-icon-next";
@ -35,10 +34,6 @@ class HaBackupOverviewBackups extends LitElement {
@property({ attribute: false }) public backups: BackupContent[] = [];
private _showAll() {
navigate("/config/backup/backups");
}
private _automaticStats = memoizeOne((backups: BackupContent[]) => {
const automaticBackups = backups.filter(
(backup) => backup.with_automatic_settings
@ -89,12 +84,9 @@ class HaBackupOverviewBackups extends LitElement {
</ha-md-list>
</div>
<div class="card-actions">
<ha-button
href="/config/backup/backups?type=all"
@click=${this._showAll}
>
Show all backups
</ha-button>
<a href="/config/backup/backups?type=all">
<ha-button>Show all backups</ha-button>
</a>
</div>
</ha-card>
`;