Hide config entry title when same as integration name (#5589)

This commit is contained in:
Bram Kragten 2020-04-24 10:35:56 +02:00 committed by GitHub
parent 301a964a65
commit 32c7c0b4f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -253,6 +253,10 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) {
? this._configEntries.map((item: any) => {
const devices = this._getDevices(item);
const entities = this._getEntities(item);
const integrationName = domainToName(
this.hass.localize,
item.domain
);
return item.source === "ignore"
? ""
: html`
@ -271,10 +275,12 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) {
/>
</div>
<h1>
${domainToName(this.hass.localize, item.domain)}
${integrationName}
</h1>
<h2>
${item.title}
${integrationName === item.title
? html`&nbsp;`
: item.title}
</h2>
${devices.length || entities.length
? html`