Support locale specific default top sites inside multistage about:welcome
Categories
(Firefox :: Messaging System, enhancement, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox79 | --- | unaffected |
firefox80 | --- | verified |
firefox81 | --- | verified |
People
(Reporter: pdahiya, Assigned: pdahiya)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
47 bytes,
text/x-phabricator-request
|
jcristau
:
approval-mozilla-beta+
|
Details | Review |
Default top sites shown in import screen are currently picked from code and not configurable. Scope of this bug is implement locale specific default topsites on import screen in Fx80
Updated•4 years ago
|
Updated•4 years ago
|
Comment 1•4 years ago
|
||
browser.newtabpage.activity-stream.default.sites
is set by ActivityStream.jsm:
https://searchfox.org/mozilla-central/rev/9b282b34b5aa0f836beb735656c55efb2cc4c617/browser/components/newtab/lib/ActivityStream.jsm#100-137,159-164
This pref should be accessible from content that needs to be converted to icons:
https://searchfox.org/mozilla-central/rev/9b282b34b5aa0f836beb735656c55efb2cc4c617/browser/components/newtab/content-src/aboutwelcome/components/MultiStageAboutWelcome.jsx#11-21
Assignee | ||
Comment 2•4 years ago
|
||
(In reply to Ed Lee :Mardak from comment #1)
browser.newtabpage.activity-stream.default.sites
is set by ActivityStream.jsm:
https://searchfox.org/mozilla-central/rev/9b282b34b5aa0f836beb735656c55efb2cc4c617/browser/components/newtab/lib/ActivityStream.jsm#100-137,159-164This pref should be accessible from content that needs to be converted to icons:
https://searchfox.org/mozilla-central/rev/9b282b34b5aa0f836beb735656c55efb2cc4c617/browser/components/newtab/content-src/aboutwelcome/components/MultiStageAboutWelcome.jsx#11-21
@mardak is it safe to assume default sites set in browser.newtabpage.activity-stream.default.sites pref will have rich icons available here
https://searchfox.org/mozilla-central/source/browser/components/newtab/data/content/tippytop/images
or do we need to call TippyTopService to cover edge cases when default topsites set doesn't have packaged rich icons
Comment 3•4 years ago
|
||
The default sites set will have rich icons, but I suppose someone or an add-on could change the pref value to anything. Not sure if we need to support that initially although TippyTopService should handle converting a url to rich icon if we have it instead of having some custom logic.
Assignee | ||
Comment 4•4 years ago
|
||
Comment 5•4 years ago
|
||
[Tracking Requested - why for this release]: showing users localized top-sites is necessary for this onboarding treatment
Updated•4 years ago
|
Assignee | ||
Comment 6•4 years ago
•
|
||
(In reply to Ed Lee :Mardak from comment #3)
The default sites set will have rich icons, but I suppose someone or an add-on could change the pref value to anything. Not sure if we need to support that initially although TippyTopService should handle converting a url to rich icon if we have it instead of having some custom logic.
Realizing default.sites pref is not available early enough in first run and introduces dependency on ActivityStream.jsm to intialize first for pref values to be available. Other option is to move DEFAULT_SITES by locale in its own module that's refrenced from ActivityStream and AboutWelcome, doing so still keeps dependency/wait on browser.search.region set by Search Service to be available
Comment 7•4 years ago
|
||
Will the default sites be needed for the initial page or can there be a delay in getting and rendering async? You should be able to watch for the pref change / getting set.
Assignee | ||
Comment 8•4 years ago
|
||
(In reply to Ed Lee :Mardak from comment #7)
Will the default sites be needed for the initial page or can there be a delay in getting and rendering async? You should be able to watch for the pref change / getting set.
That's correct, have chosen to watch for search.region instead of default.sites as ActivityStream.jsm initializes and update default.sites pref with fallback values even before region is set by search service. Updated patch to bring out Default Sites from ActivityStream in its own module that has benefit of removing AboutWelcome dependency on ActivityStream. Thanks!
Comment 10•4 years ago
|
||
bugherder |
Assignee | ||
Comment 11•4 years ago
•
|
||
Steps to QA fix
- Ensure there is no history or favorite sites in other browsers on user desktop
- Create a new profile and open Nightly
- Open about:config and set browser.search.region as 'RU'
- Open about:welcome -> Click Start Setup -> Default fixed topsites displayed should be respective to region RU from list in link below
https://searchfox.org/mozilla-central/source/browser/components/newtab/lib/DefaultSites.jsm#31
Assignee | ||
Comment 12•4 years ago
|
||
Comment on attachment 9165822 [details]
Bug 1650852 - Support locale specific default top sites inside multistage about:welcome
Beta/Release Uplift Approval Request
- User impact if declined: User will see fixed default topsites in onboarding flow for all locales
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: Yes
- If yes, steps to reproduce: https://bugzilla.mozilla.org/show_bug.cgi?id=1650852#c11
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Feature is already available in 80, fix switches Import screen to show locale specific default sites
- String changes made/needed: None
Assignee | ||
Updated•4 years ago
|
Updated•4 years ago
|
Comment 13•4 years ago
|
||
Comment on attachment 9165822 [details]
Bug 1650852 - Support locale specific default top sites inside multistage about:welcome
approved for 80.0b4
Comment 14•4 years ago
|
||
bugherder uplift |
Updated•4 years ago
|
Comment 15•4 years ago
|
||
I have verified that the default Top Sites displayed are the following:
- "https://vk.com", "https://www.youtube.com", "https://ok.ru/", "https://www.avito.ru/", "https://www.aliexpress.com/"
I have done this by following the STR provided in comment 11 on Firefox Beta 80.0b4 RU (Build ID: 20200804180257) and Firefox Nightly 81.0a1 (Build ID: 20200804215246) using Windows 10 x64, macOS 10.15, and Ubuntu Linux 18.04.
Description
•