Skip to content

fix(modal): support iOS card view transitions for viewport changes #30520

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

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

ShaneK
Copy link
Member

@ShaneK ShaneK commented Jun 30, 2025

Issue number: resolves #30296


What is the current behavior?

Currently, there is no support for moving between an iOS card view (mobile, portrait modal with presenting element) to a non-card view when the resolution changes (e.g., the device goes from a portrait layout to landscape). This causes issues both way because modals that should be card modals when the user transitions to a portrait view stay as non-card modals and modals that were card modals when they were opened but the user goes to landscape view end up with a black box stuck around the edges of the screen.

What is the new behavior?

With this change, we now fully support transitioning between the two modal views when the resolution changes. This should fix the issue where the background could become stuck and should be a nicer experience for users switching between the two orientations while using modals.

I also took the time to clean up the terminology in use here to refer to "mobile view" (as it was meant here) to be portrait view and the other view to be referred to as landscape view. I did this because I had accidentally mixed them up while working on this and I had to do a refactor to fix it, so I'm hoping that by clarifying the terminology now it helps prevent similar mistakes for others in the future.

Does this introduce a breaking change?

  • Yes
  • No

Other information

Relevant test screen

Dev build: 8.6.3-dev.11751378808.12cc4a5c

@ShaneK ShaneK requested a review from a team as a code owner June 30, 2025 17:43
@ShaneK ShaneK requested a review from thetaPC June 30, 2025 17:43
Copy link

vercel bot commented Jun 30, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
ionic-framework ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 2, 2025 1:23pm

@github-actions github-actions bot added the package: core @ionic/core package label Jun 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: core @ionic/core package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: Switching between card modal & "regular" modal when modal is still open causes page behind it to remain in card modal state
1 participant