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

Fix view post iframe URL #85179

Merged
merged 6 commits into from
Dec 20, 2023
Merged

Fix view post iframe URL #85179

merged 6 commits into from
Dec 20, 2023

Conversation

noahtallen
Copy link
Member

@noahtallen noahtallen commented Dec 13, 2023

Fixes the "view post" link in the post-publish message which appears after updating or publishing content:

image

On trunk, it opens the page inside the editor iframe, and the top-level URL does not change. This PR changes to use mutation observers, since the click event is stopped before propagating to our global click override handler.

Resolves #78059

Testing instructions:

  1. sandbox a test site and widgets.wp.com
  2. Run install-plugin.sh wbe fix-post-url on your sandbox to download the build of wpcom block editor
  3. Visit the editor. (Force-refresh to ensure the browser cache is updated.)
  4. Publish or update a post.
  5. Click the link shown in the above screenshot.
  6. The link should open in a new tab with the correct URL.

Copy link

github-actions bot commented Dec 13, 2023

@matticbot
Copy link
Contributor

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • wpcom-block-editor

To test WordPress.com changes, run install-plugin.sh $pluginSlug fix-post-url on your sandbox.

@matticbot
Copy link
Contributor

This PR does not affect the size of JS and CSS bundles shipped to the user's browser.

Generated by performance advisor bot at iscalypsofastyet.com.

@noahtallen noahtallen changed the title Fix new post URL Fix view post iframe URL Dec 20, 2023
@noahtallen noahtallen merged commit 26a9c81 into trunk Dec 20, 2023
10 of 11 checks passed
@noahtallen noahtallen deleted the fix-post-url branch December 20, 2023 22:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants