diff --git a/hassio/src/backups/hassio-backups.ts b/hassio/src/backups/hassio-backups.ts index 2901549ae8..df4433b11f 100644 --- a/hassio/src/backups/hassio-backups.ts +++ b/hassio/src/backups/hassio-backups.ts @@ -119,7 +119,7 @@ export class HassioBackups extends LitElement { private _columns = memoizeOne( (narrow: boolean): DataTableColumnContainer => ({ name: { - title: this.supervisor?.localize("backup.name") || "", + title: this.supervisor.localize("backup.name"), sortable: true, filterable: true, grows: true, @@ -127,8 +127,16 @@ export class HassioBackups extends LitElement { html`${entry || backup.slug}
${backup.secondary}
`, }, + size: { + title: this.supervisor.localize("backup.size"), + width: "15%", + hidden: narrow, + filterable: true, + sortable: true, + template: (entry: number) => Math.ceil(entry * 10) / 10 + " MB", + }, date: { - title: this.supervisor?.localize("backup.created") || "", + title: this.supervisor.localize("backup.created"), width: "15%", direction: "desc", hidden: narrow, @@ -188,11 +196,11 @@ export class HassioBackups extends LitElement { slot="trigger" > - ${this.supervisor?.localize("common.reload")} + ${this.supervisor.localize("common.reload")} ${atLeastVersion(this.hass.config.version, 0, 116) ? html` - ${this.supervisor?.localize("backup.upload_backup")} + ${this.supervisor.localize("backup.upload_backup")} ` : ""} diff --git a/src/data/hassio/backup.ts b/src/data/hassio/backup.ts index c5af101857..c01b9440da 100644 --- a/src/data/hassio/backup.ts +++ b/src/data/hassio/backup.ts @@ -20,6 +20,7 @@ export interface HassioBackup { slug: string; date: string; name: string; + size: number; type: "full" | "partial"; protected: boolean; content: BackupContent; diff --git a/src/translations/en.json b/src/translations/en.json index c95ec5fd6f..70027504fc 100755 --- a/src/translations/en.json +++ b/src/translations/en.json @@ -4445,6 +4445,7 @@ "partial_backup": "Partial backup", "addons": "Add-ons", "folders": "Folders", + "size": "Size", "password": "Backup password", "confirm_password": "Confirm backup password", "password_protection": "Password protection",