Don't suggest to pick another card for sections (#19977)

This commit is contained in:
Paul Bottein 2024-03-04 15:30:31 +01:00
parent a9f453ea36
commit 63d93f2a36
No known key found for this signature in database

View File

@ -131,11 +131,15 @@ export class HuiDialogSuggestCard extends LitElement {
</mwc-button>
${!this._params.yaml
? html`
<mwc-button slot="primaryAction" @click=${this._pickCard}
>${this.hass!.localize(
"ui.panel.lovelace.editor.suggest_card.create_own"
)}</mwc-button
>
${!(this._sectionConfig && this._viewSupportsSection)
? html`
<mwc-button slot="primaryAction" @click=${this._pickCard}>
${this.hass!.localize(
"ui.panel.lovelace.editor.suggest_card.create_own"
)}
</mwc-button>
`
: nothing}
<mwc-button
slot="primaryAction"
.disabled=${this._saving}
@ -154,7 +158,7 @@ export class HuiDialogSuggestCard extends LitElement {
)}
</mwc-button>
`
: ""}
: nothing}
</ha-dialog>
`;
}