Skip to content
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

Unsupported block: Post title is displayed in UBE (Unsupported block editor) when editing an unsupported block #47966

Closed
fluiddot opened this issue Feb 10, 2023 · 2 comments · Fixed by #48435
Labels
Mobile App - i.e. Android or iOS Native mobile impl of the block editor. (Note: used in scripts, ping mobile folks to change) [Type] Bug An existing feature does not function as intended

Comments

@fluiddot
Copy link
Contributor

Description

When editing unsupported blocks in the app using UBE (Unsupported Block Editor), it should only display the block. However, I recently noticed that the Post title is also being shown which adds confusion to the experience.

Step-by-step reproduction instructions

  1. Create a post in the web version of the editor.
  2. Add an unsupported block like a Table block.
  3. Save the post.
  4. Open the same post in the app.
  5. Observe that the block is unsupported.
  6. Tap on the unsupported block and tap on Edit using web editor.
  7. When the content is loaded, observe that the Post title is displayed.

NOTE: UBE (Unsupported Block Editor) is only available in WPCOM or self-hosted sites connected with Jetpack.

Expected behaviour

The Post title shouldn't be displayed when editing an unsupported block using UBE (Unsupported Block Editor).

Actual behaviour

The Post title is displayed when editing an unsupported block using UBE (Unsupported Block Editor).

Screenshots or screen recording (optional)

WordPress information

  • WordPress version: N/A
  • Gutenberg version: N/A
  • Are all plugins except Gutenberg deactivated? N/A
  • Are you using a default theme (e.g. Twenty Twenty-One)? N/A

Device information

  • Device: iPhone 11
  • Operating system: iOS 15.4
  • WordPress app version: 21.7
@fluiddot fluiddot added Mobile App - i.e. Android or iOS Native mobile impl of the block editor. (Note: used in scripts, ping mobile folks to change) [Type] Bug An existing feature does not function as intended labels Feb 10, 2023
@dcalhoun
Copy link
Member

dcalhoun commented Feb 24, 2023

It appears the issue causing this is that the styles injected by the UBE are no longer applied to the editor because the editor is now rendered within an iframe after #46212, which is one portion of a larger goal outlined in #33346.

Since CSS cannot be applied from the parent context onto elements within the iframe, we will need to determine a different approach for modifying the editor in the UBE. E.g. using JavaScript (if the iframe permissions and origin allow it) or a first-party mechanism as described in #21874.

@fluiddot
Copy link
Contributor Author

It appears the issue causing this is that the styles injected by the UBE are no longer applied to the editor because the editor is now rendered within an iframe after #46212, which is one portion of a larger goal outlined in #33346.

Since CSS cannot be applied from the parent context onto elements within the iframe, we will need to determine a different approach for modifying the editor in the UBE. E.g. using JavaScript (if the iframe permissions and origin allow it) or a first-party mechanism as described in #21874.

Good catch @dcalhoun 🙇 ! Definitely, we'd need to investigate how to inject styles into the iframe now that the content is served this way 🤔. Hopefully, the sandbox restrictions that we might encounter in a browser won't be in the app due to the use of WebViews, but we'd need to check this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Mobile App - i.e. Android or iOS Native mobile impl of the block editor. (Note: used in scripts, ping mobile folks to change) [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants