Add generate widgets to the ExtensionWidgetsFeed
Categories
(Firefox :: Widgets, task)
Tracking
()
People
(Reporter: fchasen, Assigned: fchasen)
References
(Blocks 2 open bugs)
Details
(Whiteboard: [hnt][hnt-wattle])
Attachments
(1 external file)
Generate widgets need to be shown on New Tab when they are enabled. This mean moving from the WidgetsRegistry pulling widgets from the ExtensionWidgetsFeed to all widgets on the extension feed showing, with the registry being able to control the visibility of specific (built-in) ones instead.
WidgetManagerneeds to add a pref branch for each widget that records its enabled state and size.ExtensionWidgetsFeedneeds to update to publishing every widget whose prefs are under the New Tab branch, along with its enabled state, size, telemetry name and system pref.WidgetsRegistrywill need to merge the published extension widgets withWIDGET_REGISTRYso it can control the display and other params of built-in widgets.- Newly installed widget extension should be added to the start of the order.
Updated•8 days ago
|
| Assignee | ||
Comment 2•8 days ago
|
||
Acceptance criteria from Bug 2089910:
- Uninstalling a generated widget removes it from New Tab, with no empty slot or stale entry after a reload.
- The other widgets keep their order and size.
- Opting out of Labs and blocking AI leave generated widgets in place and running.
- A test checks uninstalling a widget and then reloading New Tab.
| Assignee | ||
Comment 3•7 days ago
|
||
From https://phabricator.services.mozilla.com/D335844: it would be nice to turn this (test_a_package_installs_and_its_page_loads) into a test that ensures that the generated widget started and loaded as expected in the about:newtab once all the other missing bits to be able to do that are available.
That should be possible after with these changes.
| Assignee | ||
Comment 4•1 day ago
|
||
Publishes every WidgetManager widget in the ExtensionWidgets state, so generated widgets appear in the New Tab widget row.
- Adds
setWidgetEnabledandsetWidgetSizehelpers that sendWIDGETS_EXTENSIONS_SETfor an extension widget andSET_PREFfor a built-in widget. - Uses the helpers for hiding, resizing, hide all and maximize.
- Places new widgets at the start of
widgets.orderand drops them from it on uninstall. - Adds a
widgets.generated.enabledpref, off by default, that makes generated widgets available. - Leaves generated widgets out of the Customize panel.
Description
•