Skip to content

Conversation

dcalhoun
Copy link
Member

@dcalhoun dcalhoun commented Oct 6, 2025

Related:

What?

Send web modal dialog state to the host app.

Why?

Close CMM-822. Close CMM-444. Close #129.

Enable host apps to respond to a web modal dialog opening or closing. E.g., it
may be prudent to disable surrounding native UI while a web modal dialog is
open.

How?

Add bridge events for opening and closing modal dialogs.

Testing Instructions

Important

When testing the iOS Demo app, you may need to run make build or use the development server before running the Demo app.

1. Web modal dialogs disable native header navigation

  1. Open the Demo app.
  2. Open a modal dialog—e.g., block inserter, block inspector.
  3. Verify the native header navigation is disabled.
  4. Close the modal dialog.
  5. Verify the native header navigation is enabled.

2. Android hardware back button dismisses web dialogs

  1. Open the Demo app.
  2. Open a modal dialog—e.g., block inserter, block inspector.
  3. Press the hardware back button.
  4. Verify the web dialog is dismissed.
  5. Press the hardware back button.
  6. Verify the editor is dismissed.

Accessibility Testing Instructions

Perform the testing via a screen reader.

Screenshots or screencast

N/A

Allow the host to respond to the opening and closing of modal dialogs.
This is important for disabling surround interactive native UI elements.
@dcalhoun dcalhoun added the [Type] Enhancement A suggestion for improvement. label Oct 6, 2025
@dcalhoun dcalhoun changed the base branch from trunk to feat/update-android-demo-app-navigation October 6, 2025 15:09
@dcalhoun dcalhoun changed the title feat: Send modal dialog state to host ap feat: Send modal dialog state to host app Oct 6, 2025
Address build warning:

```
Conformance of '_EditorView.Coordinator' to protocol 'EditorViewControllerDelegate' crosses into main actor-isolated code and can cause data races; this is an error in the Swift 6 language mode
```
import Foundation

#if canImport(UIKit)
@MainActor
Copy link
Member Author

Choose a reason for hiding this comment

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

Added in bd8f3c0 to address conformance warning.

@dcalhoun dcalhoun requested review from adalpari and kean October 6, 2025 20:25
Copy link

@adalpari adalpari left a comment

Choose a reason for hiding this comment

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants