From fe38238c7a00f6939a1f5c8f31bd57418a2b3aff Mon Sep 17 00:00:00 2001 From: schelv <13403863+schelv@users.noreply.github.com> Date: Thu, 9 Nov 2023 22:13:50 +0100 Subject: [PATCH] only show clear button if there is a value --- src/components/ha-time-input.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ha-time-input.ts b/src/components/ha-time-input.ts index 9f09a2b5a2eb..5d35d56395b8 100644 --- a/src/components/ha-time-input.ts +++ b/src/components/ha-time-input.ts @@ -50,7 +50,7 @@ export class HaTimeInput extends LitElement { @value-changed=${this._timeChanged} .enableSecond=${this.enableSecond} .required=${this.required} - .clearable=${this.clearable} + .clearable=${this.clearable && this.value !== undefined} .helper=${this.helper} > `;