Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## [`master`](https://github.com/elastic/eui/tree/master)

- Removed dependency on option list for custom option of `EuiComboBox` ([#3183](https://github.com/elastic/eui/pull/3183))
- Fixed `EuiPopover` arrow position in Android and Linux ([#3188](https://github.com/elastic/eui/pull/3188))
- Improved `htmlIdGenerator` when supplying both `prefix` and `suffix` ([#3076](https://github.com/elastic/eui/pull/3076))
- Updated pagination prop descriptions for `EuiInMemoryTable` ([#3142](https://github.com/elastic/eui/pull/3142))
Expand Down
13 changes: 12 additions & 1 deletion src/components/combo_box/combo_box.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,18 @@ export class EuiComboBox<T> extends Component<
if (async) {
return false;
}
return flattenOptionGroups(options).length === selectedOptions.length;
let numberOfSelectedOptions = 0;
Comment thread
chandlerprall marked this conversation as resolved.
selectedOptions.forEach(({ label }) => {
if (
flattenOptionGroups(options).findIndex(
option =>
option.label.trim().toLowerCase() === label.trim().toLowerCase()
) !== -1
)
numberOfSelectedOptions += 1;
});

return flattenOptionGroups(options).length === numberOfSelectedOptions;
};

isSingleSelectionCustomOption = () => {
Expand Down