Closed lhkowalski closed 8 months ago
Going to take a look on this one.
I did an audit on the current behavior:
redirect_to
on the checkout URL, and it contains the current post editing URL, but on the wp-admin
format instead of the Calypso format, what can confuse some users
wp-admin
panelredirect_to
URL is set as the "new post URL" (correct) but for the wp-admin
context (not ideal)redirect_to
URL is still the same "new post URL" (could be the URL for the current post)redirect_to
parameter is set here: https://github.com/Automattic/jetpack/blob/trunk/projects/plugins/jetpack/extensions/blocks/ai-assistant/hooks/use-ai-checkout/index.ts#L25redirect_to
set to the My Jetpack page
The things we may need to do:
redirect_to
from Simple sites, to use the Calypso version OR to at least encode the URL so we don't lose the extra parameters and send the user to the right post instead of the list of postsredirect_to
or referer
parameter on the product interstitials of My Jetpack, that would be used as the redirect_to
paramenter of the checkout URLI will start with Jetpack sites, then move to simple sites after it.
When the upgrade process started on the block editor, while editing some post or page, we should redirect the user back to the same post after the upgrade is finished.