From 4930532c7b3f6047ad8e9b29ff06c0f13dc0e120 Mon Sep 17 00:00:00 2001 From: Philip Allgaier Date: Sat, 12 Dec 2020 20:46:56 +0100 Subject: [PATCH] Fix `ha-relative-time` usage for tags and sun (#7944) --- src/components/ha-relative-time.ts | 2 +- src/dialogs/more-info/controls/more-info-sun.ts | 2 +- src/panels/config/tags/ha-config-tags.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/ha-relative-time.ts b/src/components/ha-relative-time.ts index 1bd6e39afc..a2f9e403ca 100644 --- a/src/components/ha-relative-time.ts +++ b/src/components/ha-relative-time.ts @@ -13,7 +13,7 @@ import type { HomeAssistant } from "../types"; class HaRelativeTime extends UpdatingElement { @property({ attribute: false }) public hass!: HomeAssistant; - @property({ attribute: false }) public datetime?: string; + @property({ attribute: false }) public datetime?: string | Date; private _interval?: number; diff --git a/src/dialogs/more-info/controls/more-info-sun.ts b/src/dialogs/more-info/controls/more-info-sun.ts index 80fa678ee4..c5e26348e7 100644 --- a/src/dialogs/more-info/controls/more-info-sun.ts +++ b/src/dialogs/more-info/controls/more-info-sun.ts @@ -44,7 +44,7 @@ class MoreInfoSun extends LitElement { >
diff --git a/src/panels/config/tags/ha-config-tags.ts b/src/panels/config/tags/ha-config-tags.ts index 50c971eb10..713b14d72a 100644 --- a/src/panels/config/tags/ha-config-tags.ts +++ b/src/panels/config/tags/ha-config-tags.ts @@ -84,7 +84,7 @@ export class HaConfigTags extends SubscribeMixin(LitElement) { ${tag.last_scanned_datetime ? html`` : this.hass.localize("ui.panel.config.tags.never_scanned")}
` @@ -103,7 +103,7 @@ export class HaConfigTags extends SubscribeMixin(LitElement) { ${last_scanned_datetime ? html`` : this.hass.localize("ui.panel.config.tags.never_scanned")} `,