Compare commits

...

1 Commits

Author SHA1 Message Date
Paul Bottein
a9f1fd8969 Fix custom value in picker with sections 2026-02-12 10:19:38 +01:00

View File

@@ -362,6 +362,18 @@ export class HaPickerComboBox extends ScrollableFadeMixin(LitElement) {
const additionalItems = this._getAdditionalItems();
items.push(...additionalItems);
if (this.allowCustomValue && this._search) {
items.push({
id: this._search,
primary:
this.customValueLabel ??
this.hass?.localize("ui.components.combo-box.add_custom_item") ??
"Add custom item",
secondary: `"${this._search}"`,
icon_path: mdiPlus,
});
}
if (this.mode === "dialog") {
items.push({ id: PADDING_ID, primary: "" }); // padding for safe area inset
}