Force YAML if schema has multiple (#8298)

This commit is contained in:
Joakim Sørensen 2021-02-01 13:00:38 +01:00 committed by GitHub
parent 3d4a0b02e5
commit a9192ae2e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,7 +109,8 @@ class HassioAddonConfig extends LitElement {
protected firstUpdated(changedProps) {
super.firstUpdated(changedProps);
this._canShowSchema = !this.addon.schema.find(
(entry) => !SUPPORTED_UI_TYPES.includes(entry.type)
// @ts-ignore
(entry) => !SUPPORTED_UI_TYPES.includes(entry.type) || entry.multiple
);
this._yamlMode = !this._canShowSchema;
}