fix: isolate MDL detail stacking context from ancestor overlays - #11764
Merged
Conversation
Use `isolation: isolate` so MDL's internal z-indices (#detail at z-4 in particular) stay contained within MDL's own stacking context. Without it, the detail panel competes with ancestor overlays such as `vaadin-app-layout`'s backdrop (z-2) and renders above them. Fixes #11762
|
vursen
approved these changes
May 18, 2026
Collaborator
|
This ticket/PR has been released with Vaadin 25.2.0-alpha8. |
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.



When
vaadin-master-detail-layoutis nested insidevaadin-app-layoutand both are in overlay mode, the MDL detail panel renders above the app-layout's drawer backdrop. The backdrop becomes click-through behind the detail panel, so users cannot dismiss the drawer by clicking the visible part of it.The root cause is a stacking conflict: MDL's
#detailusesz-index: 4for its own internal layering (above its placeholder, backdrop, and outgoing-detail wrapper), and that z-index applies in the nearest ancestor stacking context — the app-layout's stacking context, where the drawer backdrop sits atz-index: 2.Applying
isolation: isolateon the MDL host contains the internal z-indices in MDL's own stacking context. MDL as a whole then stacks at its default level in the parent, and ancestor overlays (app-layout backdrop, dialogs, etc.) layer above it as expected. Theoverlay-containment='page'mode is excluded — there, the detail usesposition: fixedand must escape MDL's stacking context to layer above the page.Fixes #11762
🤖 Generated with Claude Code