-
Notifications
You must be signed in to change notification settings - Fork 13.3k
fix(modal): prevent ion-content collapsing at content-based heights #31413
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
4e8ecc2
e63841c
21e6c23
51e8923
54b1596
d5b4e75
7298645
6738339
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -27,7 +27,12 @@ | |
| --max-width: auto; | ||
| --height: 100%; | ||
| --min-height: auto; | ||
| --max-height: auto; | ||
| /** | ||
| * Clamps a content-sized `--height` (auto, fit-content, ...) to the | ||
| * overlay, giving the wrapper's flex children something to shrink | ||
| * toward so `ion-content` scrolls instead of overflowing. | ||
| */ | ||
| --max-height: 100%; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this considered a breaking change since consumers are used to having it as
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. No, I wouldn't consider this a breaking change because
That means the actual change is From there, the cases where the computed value actually changes are all cases that were already broken:
Anyone who explicitly sets Additionally, CSS variable defaults are not tracked in the public API. |
||
| --overflow: hidden; | ||
| --border-radius: 0; | ||
| --border-width: 0; | ||
|
|
@@ -87,8 +92,16 @@ ion-backdrop { | |
| /** | ||
| * The wrapper receives programmatic focus for screen readers but should not | ||
| * show a visible focus ring, which is meant only for keyboard navigation. | ||
| * | ||
| * A flex layout is required for the wrapper to size itself to its content | ||
| * when the modal is content-sized (`--height` is auto, fit-content, ...). | ||
| * This makes it so that the content can scroll when it overflows the wrapper. | ||
| */ | ||
| .modal-wrapper { | ||
| display: flex; | ||
|
|
||
| flex-direction: column; | ||
|
|
||
| outline: none; | ||
| } | ||
|
|
||
|
|
||

Uh oh!
There was an error while loading. Please reload this page.