-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Labels
[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] OverviewComprehensive, high level view of an area of focus often with multiple tracking issuesComprehensive, high level view of an area of focus often with multiple tracking issues
Description
Goal: to iframe all editor instances with front-end content.
It seems best to continue to gradually iframe the remaining content. For 5.9, I propose that we iframe the device previews and the block and pattern previews, and iframe the post editor at a later point. This is to give people time to test their blocks, address issues, contact us in case of problems, yet to slightly push them to do so. The previews (block, patterns and full content for device preview) are a good way to do that because they are non-essential while more visible.
Done ✅
WP 5.9-6.0
- Prepare for the post editor.
- Move the meta boxes (since the scroll container will move inside the iframe, while the meta boxes cannot). Would also allow us to remove the Safari flickering hack.
- Backward compatibility layer (opt-in) to render blocks in an overlay outside the iframe if absolutely necessary.
- This is necessary for the classic block, which currently doesn't work in the iframe.
- Refine the iframe component.
- Remove event bubbling by rewriting:
- All global shortcuts. Most of these how already been rewritten.
- The dag chip Block editor: iframe: remove event bubbling and improve draggable chip #34819
- Allow scripts and styles to be passed to editor settings in WP Dependency handle format, so themes and plugins can add to it. These handles should then be resolved on the server side into a list of assets, which could contain inline scripts and styles as well. See Warning when enqueuing styles for a plugin in iframed Full Site Editor #33212 and Dynamic editor styles and inline CSS without targetting
.editor-styles-wrapper
#18571. - The assets that are loaded into the iframe need to much reduced. Currently we are loading way too many styles in the iframe that are meant for the UI. In some packages like
block-editor
, we'll need to create a separate stylesheet for editor content (that will be loaded in the iframe). We shouldn't load the whole package stylesheet which mostly consists of UI selectors.
- Remove event bubbling by rewriting:
- Move placeholders (editor UI) into shadow DOM. Block editor: placeholders: try admin shadow #33494
- Move appenders (and any other editor UI) out of the content and either into popovers or shadow DOM.
- Ideally the new widget and navigation screens should also be iframed. Who could best do that?
WP 6.2
Post editorPost editor. Maybe this could be done earlier while it remains off by default. In some future release we could simply flip the switch. Another plugin could potentially flip the switch too. There was some interest for that.
Dev notes
lkraav, mcsf, noahtallen and saas786
Metadata
Metadata
Assignees
Labels
[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] OverviewComprehensive, high level view of an area of focus often with multiple tracking issuesComprehensive, high level view of an area of focus often with multiple tracking issues