Allow custom value for multiple select (#14839)

This commit is contained in:
Paul Bottein 2022-12-21 11:51:35 +01:00 committed by GitHub
parent a7c3774c29
commit ae04a5457e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -118,9 +118,11 @@ export class HaSelectSelector extends LitElement {
.disabled=${this.disabled}
.required=${this.required && !value.length}
.value=${this._filter}
.items=${options}
.filteredItems=${options.filter(
(option) => !option.disabled && !value?.includes(option.value)
)}
.allowCustomValue=${this.selector.select.custom_value ?? false}
@filter-changed=${this._filterChanged}
@value-changed=${this._comboBoxValueChanged}
></ha-combo-box>