Change helpscout beacon behavior #22612
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
We want to adapt the behavior of the
Contact our support teambutton in theSupportpage to our new Premium and WooCommerce SEO subscription plans.Currently, only users who have Yoast SEO Premium installed can access the Helpscout Beacon through the button, which would have a specific
beacon_idfor Premium.In light of our switch to plan subscription, we want to:
beacon_idvalue according to the user's plan: in case the Premium plan is active, we are going to use the Premiumbeacon_id. Coversely, if the WooCommerce SEO plan is active, we will use the WooCommerce SEObeacon_idSummary
This PR can be summarized in the following changelog entry:
Contact our support teambutton in theSupportpage to our new Premium and WooCommerce SEO subscription plans.Relevant technical choices:
Contact our support teambutton is active or not have been changed from checking if Premium is installed to checking the user's subscription plan (i.e. if the user has a Premium or WooCommerce SEO valid license).Test instructions
Test instructions for the acceptance test before the PR gets merged
This PR can be acceptance tested by following these steps:
Scenario 1: User with no active subscription plans (Free user)
Yoast SEO->Supportand verify:Premiumbadge aside theContact our support teamsection titleContact our support teambutton is deactivated and shows an upsellInstant answerssectionScenario 2: User with Premium subscription only
Yoast SEO->Supportand verify:Premiumbadge aside theContact our support teamsection titleContact our support teambutton is activeContact our support teamopens a section with two available tabs:AskandAnswerswindow.wpseoHelpScoutBeaconwindow.wpseoHelpScoutBeacon('1ae02e91-5865-4f13-b220-7daed946ba25', (...)Yoast SEO->RedirectsYoast SEO->RedirectsChat with usHelpScout beaconScenario 2: User with WooCommerce subscription only
Yoast SEO->Supportand verify:Premiumbadge aside theContact our support teamsection titleContact our support teambutton is activeContact our support teamopens a section with two available tabs:AskandAnswerswindow.wpseoHelpScoutBeaconwindow.wpseoHelpScoutBeacon('8535d745-4e80-48b9-b211-087880aa857d', (...)Yoast SEO->RedirectsYoast SEO->WooCommerce SEOChat with usHelpScout beaconYoast SEO->Redirectswindow.wpseoHelpScoutBeaconwindow.wpseoHelpScoutBeacon('1ae02e91-5865-4f13-b220-7daed946ba25', (...)Scenario 4: User with both Premium and WooCommerce SEO subscriptions
Scenario 4and verify nothing changesScenario 5: Test the add-ons pages HelpScout Beacon
Yoast SEO->News SEOChat with usHelpScout beaconwindow.wpseoHelpScoutBeaconwindow.wpseoHelpScoutBeacon('1161a6b32-9360-4613-bd04-d8098b283a0f', (...)Local SEOandVideo SEOwindow.wpseoHelpScoutBeacon('84c1df2c-435a-45ac-8708-f5e3a00843c5', (...)window.wpseoHelpScoutBeacon('4e7489db-f907-41b3-9e86-93a01b4df9b0', (...)Scenario 6: Test this PR with an old version of Premium
Yoast SEO->Supportand verifyPremiumbadge aside theContact our support teamsection titleContact our support teambutton is activeContact our support teamopens a section with two available tabs:AskandAnswersAcademy)window.wpseoHelpScoutBeaconwindow.wpseoHelpScoutBeacon('1ae02e91-5865-4f13-b220-7daed946ba25', (...)Relevant test scenarios
The browser console should be open to inspect the HelpScout beacon script and verify the correct beacon ID is being used based on subscription status.
Test instructions for QA when the code is in the RC
Impact check
This PR affects the following parts of the plugin, which may require extra testing:
Other environments
[shopify-seo], added test instructions for Shopify and attached theShopifylabel to this PR.Documentation
Quality assurance
Innovation
innovationlabel.Fixes #4004