Fix ha-icon-button in ha-file-upload (#10328)

This commit is contained in:
Philip Allgaier 2021-10-19 18:24:11 +02:00 committed by GitHub
parent 04f586721f
commit b3f8daa758
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -84,15 +84,20 @@ export class HaFileUpload extends LitElement {
${this.value} ${this.value}
</iron-input> </iron-input>
${this.value ${this.value
? html`<ha-icon-button ? html`
slot="suffix" <ha-icon-button
@click=${this._clearValue} slot="suffix"
.label=${this.hass.localize("ui.common.close")} @click=${this._clearValue}
.path=${mdiClose} .label=${this.hass.localize("ui.common.close")}
></ha-icon-button>` .path=${mdiClose}
: html`<ha-icon-button slot="suffix"> ></ha-icon-button>
.path=${this.icon} ></ha-icon-button `
>`} : html`
<ha-icon-button
slot="suffix"
.path=${this.icon}
></ha-icon-button>
`}
</paper-input-container> </paper-input-container>
</label> </label>
`} `}