-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[GB 13.7.x] Open Site Editor in the Gutenframe by using the site-editor.php
route
#65997
[GB 13.7.x] Open Site Editor in the Gutenframe by using the site-editor.php
route
#65997
Conversation
…in Gutenberg 13.7
Here is how your PR affects size of JS and CSS bundles shipped to the user's browser: Sections (~32 bytes removed 📉 [gzipped])
Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to. Async-loaded Components (~11 bytes removed 📉 [gzipped])
React components that are loaded lazily, when a certain part of UI is displayed for the first time. Legend What is parsed and gzip size?Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory. Generated by performance advisor bot at iscalypsofastyet.com. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is working as expected for me...
Simple sites: now that site-editor.php
is a valid route, this works perfectly, loading the Site editor in the Calypso iframe from wp-admin/site-editor.php.
Atomic sites: this won't work until Gutenberg 13.7 is released, as older versions of Gutenberg will redirect from site-editor.php
to themes.php?page=gutenberg-edit-site
and break out of the iframe. However, I can't get any Atomic site to load the Site editor within the iframe right now.
Jetpack sites: these will already redirect and break out of the iframe when using the latest version of Gutenberg, so this change will be a welcome fix.
But still, I think it's best to wait to deploy this until just before Gutenberg 13.7 is released to Atomic sites.
Note that I tested this change on its own, apart from the associated diffs. |
By Jetpack sites, do you mean plain org sites running the Jetpack plugin + connected to Jetpack? I thought those sites didn't use the Gutenframe/Calypso, though? |
You're right, that's still true, afaik, and I forgot about it when I was testing. The Site editor isn't showing in the sidebar for any Jetpack (non-Atomic) sites in Calypso right now, so I was just going directly to the /site-editor/{site} link. |
Proposed Changes
Gutenberg 13.7 deprecates the old
themes.php?page=gutenberg-edit-site
andadmin.php?page=gutenberg-edit-site
in favor of WP core'ssite-editor.php
. This PR changes the Site Editor admin route tosite-editor.php
in the Gutenframe.Testing Instructions
calypso.localhost:3000
;Appearance->Site Editor
menu item. It should open the editor inside the Gutenframe and shouldn't redirect to the wp-admin page!gutenberg-edge
sticker to your existing site);Pre-merge Checklist
Further context:
theme_page
Site Editor routes to the newsite-editor.php
page WordPress/gutenberg#42643 and Update the minimum WP version to 5.9 WordPress/gutenberg#41306.