Skip to content

[Flyout System] Child Flyout History#9409

Draft
tsullivan wants to merge 60 commits intoelastic:mainfrom
tsullivan:flyout/child-history
Draft

[Flyout System] Child Flyout History#9409
tsullivan wants to merge 60 commits intoelastic:mainfrom
tsullivan:flyout/child-history

Conversation

@tsullivan
Copy link
Member

@tsullivan tsullivan commented Feb 24, 2026

Depends on #9377
Depends on #9412

Summary

Why are we making this change?

Closes #9410

Screenshots #

Impact to users

QA

Remove or strikethrough items that do not apply to your PR.

General checklist

  • Browser QA
    • [ ] Checked in both light and dark modes
    • [ ] Checked in both MacOS and Windows high contrast modes
    • [ ] Checked in mobile
    • Checked in Chrome, Safari, Edge, and Firefox
    • [ ] Checked for accessibility including keyboard-only and screenreader modes
  • Docs site QA
  • Code quality checklist
  • Release checklist
    • A changelog entry exists and is marked appropriately
    • [ ] If applicable, added the breaking change issue label (and filled out the breaking change checklist)
    • [ ] If the changes unblock an issue in a different repo, smoke tested carefully (see Testing EUI features in Kibana ahead of time)
  • Designer checklist
    • [ ] If applicable, file an issue to update EUI's Figma library with any corresponding UI changes. (This is an internal repo, if you are external to Elastic, ask a maintainer to submit this request)

tsullivan and others added 30 commits February 12, 2026 17:14
Refactor `useEuiFlyoutResizable` to output percentage-based widths
instead of raw pixels. The hook now clamps resize at 90% of a
reference width (defaulting to the viewport), accounts for a sibling
flyout's width, and scales proportionally when the container resizes
in either direction. Updates unit and Cypress tests accordingly.

Co-authored-by: Cursor <cursoragent@cursor.com>
…rlay

Add `containerElement` and `minWidth` to the flyout manager state,
actions, reducer, and store. Extend `EuiPortal` with an optional
`container` prop for mounting into a specific element. Enrich
`EuiFlyoutParentContext` to share the parent's container element
with child flyouts. Add `container` prop to the flyout overlay for
portal targeting. Refactor selector tests to use a `createMockManager`
factory that includes the new `setContainerElement` API.

Co-authored-by: Cursor <cursoragent@cursor.com>
Introduce the `container` prop on `EuiFlyout` for positioning flyouts
relative to an application container instead of the viewport. When a
container is provided, the flyout uses `position: absolute` with
container queries; otherwise it uses `position: fixed` with media
queries. Width values use `%` units throughout (identical to `vw` for
fixed positioning, container-relative for absolute).

Key changes:
- Refactor `euiFlyoutStyles` into shared base + position variants
  (`fixed`/`absolute`) + sizing modes (`viewport`/`container`)
- Wire container through `EuiFlyoutParentContext` for child inheritance
- Set `container-type: inline-size` and scroll-reset listener on the
  container element; report it to manager state for layout calculations
- `layout_mode.ts` uses container width for responsive breakpoints
- Add `container` to `EuiProvider` component defaults for global config
- Consolidate selector hooks: read `useFlyoutManager()` once per
  component and derive values inline (reduces redundant calls)
- Deprecation warnings for `maskProps` and
  `includeFixedHeadersInFocusTrap` when `container` is provided
- `--euiFlyoutMainWidth` CSS variable for synchronous fill-child sizing

Co-authored-by: Cursor <cursoragent@cursor.com>
Add website documentation for the `container` prop explaining
container-relative positioning, `position: relative` requirement,
and the `container-type: inline-size` caveat for fixed descendants.

Add `FlyoutContainerDemo` storybook demonstrating both "app" flyouts
(container-relative, push type, with child) and "global" flyouts
(viewport-relative, overlay type) in a simulated app layout with
left navigation and right tools sidebar.

Co-authored-by: Cursor <cursoragent@cursor.com>
@tsullivan tsullivan mentioned this pull request Feb 26, 2026
14 tasks
@tsullivan tsullivan force-pushed the flyout/child-history branch from 6b10192 to 7155be4 Compare February 26, 2026 22:48
@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

@elasticmachine
Copy link
Collaborator

💔 Build Failed

Failed CI Steps

History

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1️⃣ Child Flyout History

2 participants