This bug captures the on-train work required to support the [Promote Firefox Features to Early Day Users experiment](https://mozilla-hub.atlassian.net/jira/software/c/projects/OMC/boards/427?selectedIssue=OMC-854) and future experimentation with a bookmark style buttons that can replace the existing default “Getting Started” bookmark in Release. We can confirm with product whether there should be a default bookmark message or if no bookmark button should be the default. This will be a new surface in messaging system and should be remotely configurable (see [Jira ticket](https://mozilla-hub.atlassian.net/jira/software/c/projects/OMC/boards/427?selectedIssue=OMC-872) for configurability and telemetry requirements). For now, we can assume the button will only be added during first run. We’ll target new users in the initial experiment, but want the option to target existing users after upgrade in the future. [Bug 1877295](https://bugzilla.mozilla.org/show_bug.cgi?id=1877295) should be a helpful reference for adding a new toolbar button. In that bug, [maybeAddSetupButton](https://searchfox.org/mozilla-central/source/browser/components/aboutwelcome/modules/AWToolbarUtils.sys.mjs#14-36) checks to see if the button should be added. For this use case, we’ll want logic that checks to see if there’s an ASRouter message targeting the user. [sendTriggerMessage](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/ASRouter.sys.mjs#1938) can be used to fire a new trigger and obtain a message (similar to [how it’s used in Feature Callouts](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/FeatureCallout.sys.mjs#1503-1514)). To make this surface more versatile, we can make use of the existing [OPEN_URL special message action](https://searchfox.org/mozilla-central/source/toolkit/components/messaging-system/lib/SpecialMessageActions.sys.mjs#383-394) and plan to support other actions in the future. We’ll also want to add a configurable option to remove the button after a user triggers the primary action. Typically, we use `action: {dismiss: true}` to dismiss surfaces like [FeatureCallout](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/FeatureCallout.sys.mjs#1394). I see a few options to explore here: + We could check for `dismiss: true` in the message’s action (assuming it will also have a SMA `type` and any other fields required by the SMA). If present, we remove the button after that SMA is complete, similar to [how we use “navigate” in about:welcome](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/OnboardingMessageProvider.sys.mjs#162). + Explore using [MULTI_ACTION](https://searchfox.org/mozilla-central/source/toolkit/components/messaging-system/schemas/SpecialMessageActionSchemas/SpecialMessageActionSchemas.json#548) and adding a special message action to remove the button. + Adding something like a `remove_after_action` field to this surface’s schema. Since this is a new surface, we’ll want to: + Update the ASRouter source docs (see [this Spotlight example](https://searchfox.org/mozilla-central/source/browser/components/asrouter/docs/spotlight.md)) + Add a new schema ([Spotlight example](https://searchfox.org/mozilla-central/source/browser/components/asrouter/content-src/templates/OnboardingMessage/Spotlight.schema.json)) + Add the surface to [experimenter.info](http://experimenter.info).
Bug 1901261 Comment 0 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
This bug captures the on-train work required to support the [Promote Firefox Features to Early Day Users experiment](https://mozilla-hub.atlassian.net/jira/software/c/projects/OMC/boards/427?selectedIssue=OMC-854) and future experimentation with a bookmark style buttons that can replace the existing default “Getting Started” bookmark in Release. [Tech doc draft](https://docs.google.com/document/d/1rm00rwHpQoL0R2j0xjF-eP3vN7Xg2_GrsDZcJn7WqDY/edit) ___________ This will be a new surface in messaging system and should be remotely configurable (see [Jira ticket](https://mozilla-hub.atlassian.net/jira/software/c/projects/OMC/boards/427?selectedIssue=OMC-872) for configurability and telemetry requirements). For now, we can assume the button will only be added during first run. We’ll target new users in the initial experiment, but want the option to target existing users after upgrade in the future. [Bug 1877295](https://bugzilla.mozilla.org/show_bug.cgi?id=1877295) should be a helpful reference for adding a new toolbar button. In that bug, [maybeAddSetupButton](https://searchfox.org/mozilla-central/source/browser/components/aboutwelcome/modules/AWToolbarUtils.sys.mjs#14-36) checks to see if the button should be added. For this use case, we’ll want logic that checks to see if there’s an ASRouter message targeting the user. [sendTriggerMessage](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/ASRouter.sys.mjs#1938) can be used to fire a new trigger and obtain a message (similar to [how it’s used in Feature Callouts](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/FeatureCallout.sys.mjs#1503-1514)). To make this surface more versatile, we can make use of the existing [OPEN_URL special message action](https://searchfox.org/mozilla-central/source/toolkit/components/messaging-system/lib/SpecialMessageActions.sys.mjs#383-394) and plan to support other actions in the future. We’ll also want to add a configurable option to remove the button after a user triggers the primary action. Typically, we use `action: {dismiss: true}` to dismiss surfaces like [FeatureCallout](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/FeatureCallout.sys.mjs#1394). I see a few options to explore here: + We could check for `dismiss: true` in the message’s action (assuming it will also have a SMA `type` and any other fields required by the SMA). If present, we remove the button after that SMA is complete, similar to [how we use “navigate” in about:welcome](https://searchfox.org/mozilla-central/source/browser/components/asrouter/modules/OnboardingMessageProvider.sys.mjs#162). + Explore using [MULTI_ACTION](https://searchfox.org/mozilla-central/source/toolkit/components/messaging-system/schemas/SpecialMessageActionSchemas/SpecialMessageActionSchemas.json#548) and adding a special message action to remove the button. + Adding something like a `remove_after_action` field to this surface’s schema. Since this is a new surface, we’ll want to: + Update the ASRouter source docs (see [this Spotlight example](https://searchfox.org/mozilla-central/source/browser/components/asrouter/docs/spotlight.md)) + Add a new schema ([Spotlight example](https://searchfox.org/mozilla-central/source/browser/components/asrouter/content-src/templates/OnboardingMessage/Spotlight.schema.json)) + Add the surface to [experimenter.info](http://experimenter.info).