Repository navigation
[Flyout] set min-inline-size for container-bound flyouts - #9787
Conversation
4 visual difference(s) found - expand to review, then click Approve visual changes to update baselineseuisuperdatepicker (2 differences)
euipopover (1 difference)
euidatagrid (1 difference)
|
08e3318 to
0dcc56d
Compare
3 visual difference(s) found - expand to review, then click Approve visual changes to update baselineseuisuperdatepicker (2 differences)
euipopover (1 difference)
|
There was a problem hiding this comment.
Pull request overview
This PR adjusts container-scoped EuiFlyout sizing so named sizes (s, m) enforce a sensible pixel-based minimum width when rendered inside a container, preventing overly narrow/cropped flyouts after the default container scoping change.
Changes:
- Add container-specific
minInlineSizefloors for flyout sizessandm, derived from theme breakpoints and capped at 90% of the container width. - Update Storybook flyout manager demo defaults for
mainMinWidth/childMinWidth. - Add Jest coverage for container
min-inline-sizebehavior.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| packages/eui/src/components/flyout/manager/flyout_containers.stories.tsx | Updates Storybook args to avoid forcing a min width via the resizable props by default. |
| packages/eui/src/components/flyout/flyout.component.tsx | Implements per-size container min-width floors (for s/m) via minInlineSize when containerRect is present. |
| packages/eui/src/components/flyout/flyout_container.test.tsx | Adds tests verifying container minInlineSize behavior and capping logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
2 visual difference(s) found - expand to review, then click Approve visual changes to update baselineseuisuperdatepicker (2 differences)
|
2 visual difference(s) found - expand to review, then click Approve visual changes to update baselineseuisuperdatepicker (2 differences)
|
💚 Build Succeeded
History
|
💚 Build Succeeded
History
|
weronikaolejniczak
left a comment
There was a problem hiding this comment.
LGTM 🟢 Tested prod vs PR preview, issue looks fixed 👌🏻
## 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))
## 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))












Needed for elastic/kibana#267417
Summary
sandm, preventing content from being cropped at narrow container widths.ssize flyout layout issues kibana#267417 — after flyouts were scoped to#app-main-scrollby default, sizesflyouts could shrink to unusably narrow widths becauseminInlineSizewas overridden to0.minInlineSize: 0with per-size pixel minimums derived from theme breakpoints (breakpoint.m * 0.42fors,breakpoint.m * 0.5form), capped at 90% of the container width.filland custom sizes retainminInlineSize: 0.API Changes
No public API changes. This is an internal behavioral fix — container flyouts now have a sensible minimum width floor instead of allowing unconstrained shrinking.
Screenshots
What if the flyout is resizable?
This fix applies to the flyout's initial named size (
s,m). When a flyout is resizable, the resize hook replaces the named size with a percentage string (e.g."15.5%"), which doesn't match any key in the min-width map — so the floor drops out during and after a resize drag. This is intentional:EuiFlyoutResizablehas its ownminWidthprop that separately constrains the resize handle, so the two mechanisms don't conflict.Impact Assessment
[ ] 🔴 Breaking changes — N/Asandmflyouts will no longer shrink below ~323px / ~384px respectively. This matches the intended design and should only improve currently-broken layouts.[ ] 🧪 Test impact — N/A (no HTML structure or class name changes)[ ] 🔧 Hard to integrate — N/AImpact level: 🟢 Low
Release Readiness
[ ] Documentation: {link to docs page(s)}— No doc changes needed[ ] Figma: {link to Figma}— No design changes needed[ ] Migration guide:— No migration needed[ ] Adoption plan:— Fix is automatic for all container flyoutsQA instructions for reviewer
mainSize: sandmainResizable: false.mainSize: mand confirm it does not shrink below ~384px.mainSize: filland confirm it still behaves as before (takes 90% of container, no minimum floor).Checklist before marking Ready for Review
[ ] QA: Tested light/dark modes, high contrast, mobile, Chrome/Safari/Edge/Firefox, keyboard-only, screen reader[ ] QA: Tested docs changes— No docs changes