(Feature Request) MdDialog: Define a class for global overlay wrapper
See original GitHub issueIn MdDialog we can define in configs a class for overlay panel(panelClass
) and backdrop(backdropClass
), but we can not define a class for the wrapper.
The existent parameters are not enough to customize the dialog. Can we have a new parameter like wrapperClass
for .cdk-global-overlay-wrapper
?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:11 (4 by maintainers)
Top Results From Across the Web
Is there any way to modify the MatDialog overlay order?
Based on Eliseo's answer, no panel class modification needed. Reordering the cdk-global-overlay-wrapper elements is enough.
Read more >How to build a reusable Modal Overlay/Dialog Using Angular ...
We will start by defining the configs of the overlay – OverlayConfig . In our case, we will just set the hasBackdrop and...
Read more >angular-material/CHANGELOG.md - UNPKG
317, ### Features. 318. 319, * **autocomplete:** add md-input-class binding. ([#11102](https://github.com/angular/material/issues/11102)) ...
Read more >Untitled
... Features * **autocomplete:** add md-input-class binding. ... custom components like `$mdDialog` or `$mdToast` only available in controller constructors.
Read more >angular dialog prevent close on click outside - You.com
Prevent esc from closing the dialog but allow clicking on the backdrop to close ; export class DialogComponent { constructor(private dialogRef: MatDialogRef< ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@josephperrott For a login/registration like dialog, on small windows, I don’t want a scroll inside the panel, but I want a window scroll for that panel. I know this feature will not be implemented in material, because of Material spec(see https://github.com/angular/material2/issues/5302#issuecomment-312906868), but there are cases when you need it.
For such panels I can not just change the
.cdk-*
styles globally, because they are used for other components too, and they may become broken. So, I have to specify custom classes for panels that needs that feature.Right now, as a workaround, I’m using the private property
_overlayRef
to set that class:And styles to make panel scrollable in window:
@svenkeeter Looks like the backdrop was moved out from the dialog wrapper. You can manually move it back for these purposes: