From da9cb714e92dc2fc997043bbca33004910763998 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joy=20Serqui=C3=B1a?= <44146839+essjay05@users.noreply.github.com> Date: Thu, 10 Oct 2024 15:29:31 -0700 Subject: [PATCH] fix(material/dialog): updates dialog max-height in landscape (#29853) * fix(material/dialog): updates dialog max-height in landscape Updates Angular Component Dialog component to have a max-height of 95vh which gives it a calculable height for its contents to adjust on smaller screens or in landscape mode so that the action buttons are able to be accessed by scrolling rather than the dialog window cutting them off. Fixes b/323588333 * refactor(material/dialog): reverted max-height to inherit Updates previous fix to revert max-height back to inherit. Fixes b/323588333 --- src/material/dialog/dialog.scss | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/material/dialog/dialog.scss b/src/material/dialog/dialog.scss index 98ebb7dd78aa..33e2560d527e 100644 --- a/src/material/dialog/dialog.scss +++ b/src/material/dialog/dialog.scss @@ -11,6 +11,11 @@ $mat-dialog-content-max-height: 65vh !default; // don't expose this value as variable. $mat-dialog-button-horizontal-margin: 8px !default; +// Dialog container max height. This has been given a default value so the +// flex-children can be calculated and not overflow on smaller screens. +// Fixes b/323588333 +$mat-dialog-container-max-height: 95vh !default; + // Whether to emit fallback values for the structural styles. Previously MDC was emitting // paddings in the static styles which meant that users would get them even if they didn't // include the `dialog-base`. Eventually we should clean up the usages of this flag.