Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes a virtualization bug in EuiSelectableList where react-window could reuse cached row heights after option updates (notably when group labels are present), causing non-group options to render at an incorrect height after filtering/searching.
Changes:
- Reset
react-window’s internal size cache onoptions/visibleOptionsupdates viaresetAfterIndex(0, false)to prevent stale heights. - Add a Cypress component test covering grouped selectable search filtering and verifying option row heights remain correct after updates.
- Add an upcoming changelog entry documenting the bug fix.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| packages/eui/src/components/selectable/selectable_list/selectable_list.tsx | Resets VariableSizeList cached item sizes on option updates to prevent stale heights in virtualized grouped lists. |
| packages/eui/src/components/selectable/selectable.spec.tsx | Adds Cypress coverage to reproduce the grouped-search height regression and ensure consistent option heights after filtering. |
| packages/eui/changelogs/upcoming/9770.md | Documents the grouped selectable stale-height bug fix in the upcoming changelog. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
1 visual difference(s) found - expand to review, then click Approve visual changes to update baselineseuipopover (1 difference)
|
mgadewoll
marked this pull request as ready for review
June 30, 2026 08:55
weronikaolejniczak
self-requested a review
June 30, 2026 10:19
weronikaolejniczak
approved these changes
Jun 30, 2026
weronikaolejniczak
left a comment
Contributor
There was a problem hiding this comment.
LGTM 🟢 I tested prod vs PR preview, didn't notice any regression.
💚 Build Succeeded
History
cc @mgadewoll |
💚 Build Succeeded
History
cc @mgadewoll |
mgadewoll
added a commit
to elastic/kibana
that referenced
this pull request
Jul 17, 2026
## Dependency updates `@elastic/eui` - v116.5.0 ⏩ v117.0.0 ## Changes - removes temporary custom styles in `src/core/packages/notifications/browser-internal/src/toasts/global_toast_list.tsx` (added previously in #273985) - removes custom icon usages passed via `children` on `EuiCallOut` to prevent duplication (callouts now have internal default icons per type) - updates tests and snapshots due to `EuiCallOut` changes ## Package updates ### `@elastic/eui` [`v117.0.0`](https://github.com/elastic/eui/blob/main/packages/eui/changelogs/CHANGELOG_2026.md) - Added `EuiIllustration` for rendering SVG illustrations (e.g. from `@elastic/eui-illustrations`) that respond to the active EUI color mode ([#9779](elastic/eui#9779)) - Added `compressed` prop to `EuiSearchBar` to enable compact display mode for the search box and filter buttons ([#9743](elastic/eui#9743)) - Added `addToChat` glyph to `EuiIcon` ([#9768](elastic/eui#9768)) - Updated `EuiCallOut`: ([#9642](elastic/eui#9642)) - Updated component styles - Added `text` prop on `EuiCallOut` which renders the main, inline callout description text - use this instead of `children` where possible - Added `actionProps` prop on `EuiCallOut` which renders primary and secondary action buttons - Added `showErrorTooltip` (defaulting to `true`) to `EuiSearchBar` to allow consumers to opt-out of the built-in parse-error tooltip ([#9773](elastic/eui#9773)) **Bug fixes** - Fixed `EuiToast` cutting off absolute positioned content by removing `overflow: hidden`. ([#9791](elastic/eui#9791)) - Fixed `EuiFlyout` container-scoped flyouts shrinking below usable widths for named sizes `s` and `m` by applying minimum width floors derived from theme breakpoints ([#9787](elastic/eui#9787)) - Fixed `EuiSelectable` with group labels rendering options with stale heights ([#9770](elastic/eui#9770)) **Breaking changes** - Removed the `accent` variant for `color` on `EuiCallOut` ([#9642](elastic/eui#9642))
patrykkopycinski
pushed a commit
to patrykkopycinski/kibana
that referenced
this pull request
Aug 5, 2026
## Dependency updates `@elastic/eui` - v116.5.0 ⏩ v117.0.0 ## Changes - removes temporary custom styles in `src/core/packages/notifications/browser-internal/src/toasts/global_toast_list.tsx` (added previously in elastic#273985) - removes custom icon usages passed via `children` on `EuiCallOut` to prevent duplication (callouts now have internal default icons per type) - updates tests and snapshots due to `EuiCallOut` changes ## Package updates ### `@elastic/eui` [`v117.0.0`](https://github.com/elastic/eui/blob/main/packages/eui/changelogs/CHANGELOG_2026.md) - Added `EuiIllustration` for rendering SVG illustrations (e.g. from `@elastic/eui-illustrations`) that respond to the active EUI color mode ([elastic#9779](elastic/eui#9779)) - Added `compressed` prop to `EuiSearchBar` to enable compact display mode for the search box and filter buttons ([elastic#9743](elastic/eui#9743)) - Added `addToChat` glyph to `EuiIcon` ([elastic#9768](elastic/eui#9768)) - Updated `EuiCallOut`: ([elastic#9642](elastic/eui#9642)) - Updated component styles - Added `text` prop on `EuiCallOut` which renders the main, inline callout description text - use this instead of `children` where possible - Added `actionProps` prop on `EuiCallOut` which renders primary and secondary action buttons - Added `showErrorTooltip` (defaulting to `true`) to `EuiSearchBar` to allow consumers to opt-out of the built-in parse-error tooltip ([elastic#9773](elastic/eui#9773)) **Bug fixes** - Fixed `EuiToast` cutting off absolute positioned content by removing `overflow: hidden`. ([elastic#9791](elastic/eui#9791)) - Fixed `EuiFlyout` container-scoped flyouts shrinking below usable widths for named sizes `s` and `m` by applying minimum width floors derived from theme breakpoints ([elastic#9787](elastic/eui#9787)) - Fixed `EuiSelectable` with group labels rendering options with stale heights ([elastic#9770](elastic/eui#9770)) **Breaking changes** - Removed the `accent` variant for `color` on `EuiCallOut` ([elastic#9642](elastic/eui#9642))
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
What: This PR fixes a bug in
EuiSelectableListwhere some options would be rendered with wrong heights after updates for lists with group titles. Any group title elements that are not the first option element have a larger height (to add a separator), which is cached and then wrongly applied to a search result option, resulting in different heights between options.Why: This was noticed by Cloud-UI in https://github.com/elastic/cloud-ui/issues/3449
How:
this.listRef.resetAfterIndex(0, false)to flush thereact-windowinternal height cache on updatesshouldForceUpdate=falseonresetAfterIndexto prevent an unnecessary duplicate state updateThe issue was only visible for selectable lists with group titles, and it would only show for options after an update (e.g. due to a search) that would then be placed in the same indexed spot as a previous (non-first element) group title element, which would result in an option being rendered with the cached height of a group title.
API Changes
⚪ No API changes
Screenshots
Screen.Recording.2026-06-30.at.09.31.31.mov
Screen.Recording.2026-06-30.at.09.31.45.mov
Impact Assessment
Note: Most PRs should be tested in Kibana to help gauge their Impact before merging.
Impact level: 🟢 None
Release Readiness
QA instructions for reviewer
🧪 To reproduce the issue:
✅ Verify that...
Checklist before marking Ready for Review
breaking changelabel (if applicable)Reviewer checklist