From 0d0494030ba3728118795f394b2c562ee5da126f Mon Sep 17 00:00:00 2001 From: Steven Rollason <2099542+gadgetchnnel@users.noreply.github.com> Date: Wed, 17 May 2023 16:00:37 +0100 Subject: [PATCH] Fix for failure to update if updated by another card --- lovelace-text-input-row.js | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/lovelace-text-input-row.js b/lovelace-text-input-row.js index e47dabb..377e35d 100644 --- a/lovelace-text-input-row.js +++ b/lovelace-text-input-row.js @@ -1,9 +1,33 @@ const LitElement = Object.getPrototypeOf(customElements.get("ha-panel-lovelace")); const html = LitElement.prototype.html; const css = LitElement.prototype.css; - class TextInputRow extends LitElement { + static get properties() { + return { + label: { type: String }, + value: { type: String }, + minlength: { type: Number }, + maxlength: { type: Number }, + pattern: { type: String }, + mode: { type: String }, + stateObj: { type: Object }, + _config: { type: Object }, + }; + } + + constructor() { + super(); + this.label = ''; + this.value = ''; + this.minlength = 0; + this.maxlength = Infinity; + this.pattern = ''; + this.mode = ''; + this.stateObj = null; + this._config = null; + } + render() { return html`