Skip to content

docs(modal): reorganize Styling and add Sizing to Content section - #4689

Merged
brandyscarney merged 9 commits into
mainfrom
FW-7731
Sep 16, 2026
Merged

brandyscarney merged 9 commits into
mainfrom
FW-7731

Conversation

@brandyscarney

@brandyscarney brandyscarney commented Sep 1, 2026

Copy link
Copy Markdown
Member

Description

Other information

Previews:

@vercel

vercel Bot commented Sep 1, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
ionic-docs Ready Ready Preview Sep 16, 2026 7:15pm UTC

Request Review

Comment thread docs/api/modal.mdx
Comment thread docs/api/modal.mdx
Comment thread docs/api/modal.mdx
Comment thread versioned_docs/version-v6/api/modal.mdx
Comment thread docs/api/modal.mdx
@brandyscarney
brandyscarney marked this pull request as ready for review September 1, 2026 22:11
@brandyscarney
brandyscarney requested a review from a team as a code owner September 1, 2026 22:11
@brandyscarney brandyscarney changed the title docs(modal): reorganize styling section and add Sizing to Content section docs(modal): reorganize Styling and add Sizing to Content section Sep 1, 2026

@thetaPC thetaPC left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you! Minor things.

Comment thread docs/api/modal.mdx Outdated
Comment thread docs/api/modal.mdx Outdated
Comment thread versioned_docs/version-v6/api/modal.mdx

@thetaPC thetaPC left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ShaneK ShaneK left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

pull Bot pushed a commit to LoadsAForks/ionic-framework that referenced this pull request Sep 14, 2026
…onic-team#31413)

Issue number: resolves ionic-team#31149

---------

## What is the current behavior?
Setting `--height` to any of the following on an `ion-modal` containing
an `ion-content` results in the `ion-content` collapsing to `0` height:
`auto`, `fit-content`, `min-content`, or `max-content`.

## What is the new behavior?
- Checks if modal `--height` is set to `auto`, `fit-content`,
`min-content,` or `max-content` and styles the `ion-content`, `ion-nav`
and `.ion-page` appropriately if so
- Watches for changes to `--height` on `ion-modal` to dynamically add
and remove the class that sizes the `ion-content` to its content
- Updates modal `--max-height` to `100%` which allows the content to
scroll instead of overflowing and being clipped
- Adds a preview test for different scenarios where `ion-modal` has
`--height` set
- Adds e2e tests for the various `--height` scenarios
- Updates `safe-area-utils` to account for the new content-sized modals
- Adds spec tests for all new functions

## Does this introduce a breaking change?

- [ ] Yes
- [x] No

## Other information

**Dev build**: `9.0.1-dev.11788212611.154b1596`

**Previews**: 
- [Modal: Content
Height](https://ionic-framework-git-fw-7731-ionic1.vercel.app/src/components/modal/test/content-height)
- [Modal: Safe
Area](https://ionic-framework-git-fw-7731-ionic1.vercel.app/src/components/modal/test/safe-area)

**Docs PR**: ionic-team/ionic-docs#4689

---------

Co-authored-by: Brandy Smith <6577830+brandyscarney@users.noreply.github.com>
@brandyscarney
brandyscarney merged commit 165c15e into main Sep 16, 2026
7 checks passed
@brandyscarney
brandyscarney deleted the FW-7731 branch September 16, 2026 19:19
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.

3 participants