- Guard the main entry-points in SidebarController to handle the window being a popup
- Amend the test to also try the shortcut to show a sidebar in a popup window
Differential Revision: https://phabricator.services.mozilla.com/D236292
Disabling revamp means that we also set expanded to false. However, since revamp is disabled, these changes are not reflected back to sidebar-main, resulting in a weird mismatch between SidebarState and what the launcher sees.
This was partially fixed by the lines in initializeState(), which updates the tab container, but not the launcher. This generalizes the solution to ensure that *all* components are kept up to date.
Differential Revision: https://phabricator.services.mozilla.com/D236240
- disable expand behaviour for horizontal tabs mode
- remove expand/collapse option from customize panel when horizontal mode (follow up bug to land immediately after - bug 1939917)
- default horizontal mode to show/hide with the launcher visible initially
- default vertical mode to expand/collapse
- remove auto collapsing behviour when expanded and opening a panel
Differential Revision: https://phabricator.services.mozilla.com/D234592
- disable expand behaviour for horizontal tabs mode
- remove expand/collapse option from customize panel when horizontal mode (follow up bug to land immediately after - bug 1939917)
- default horizontal mode to show/hide with the launcher visible initially
- default vertical mode to expand/collapse
- remove auto collapsing behviour when expanded and opening a panel
Differential Revision: https://phabricator.services.mozilla.com/D234592
- disable expand behaviour for horizontal tabs mode
- remove expand/collapse option from customize panel when horizontal mode (follow up bug to land immediately after - bug 1939917)
- default horizontal mode to show/hide with the launcher visible initially
- default vertical mode to expand/collapse
- remove auto collapsing behviour when expanded and opening a panel
Differential Revision: https://phabricator.services.mozilla.com/D234592
- disable expand behaviour for horizontal tabs mode
- remove expand/collapse option from customize panel when horizontal mode (follow up bug to land immediately after - bug 1939917)
- default horizontal mode to show/hide with the launcher visible initially
- default vertical mode to expand/collapse
- remove auto collapsing behviour when expanded and opening a panel
Differential Revision: https://phabricator.services.mozilla.com/D234592
- Move resize observer (setting max width) logic over to SidebarState.
- Add `command` property to SidebarState.
- Handle receiving legacy session restore data.
- Add unit tests along with mocking structures to get a better idea of state/controller coupling (which we should ultimately reduce).
Differential Revision: https://phabricator.services.mozilla.com/D232730
Any menu items that were added after `viewCustomizeSidebar` in `this.sidebars`, such as extensions, were previous ignored in `selectMenuItem` thus resulting in an incorrect checked state in the menu.
Differential Revision: https://phabricator.services.mozilla.com/D232648
- Ensure that init() does not clear existing state.
- Keep tab container's "expanded" attribute up to date, as that controls the tab styling.
Differential Revision: https://phabricator.services.mozilla.com/D232259
*Update SidebarState logic so that opening and closing panels reverts to the correct launcher visibility for the show and hide setting
*Add a test
Differential Revision: https://phabricator.services.mozilla.com/D231838
- Adds a remote content browser to contain `about:shoppingsidebar` in `review-checker.xhtml` and update the Review Checker sidebar to use that wrapper document.
- Adds ReviewChecker actors for the sidebar Review Checker panel.
- ReviewCheckerParent is a simplified version of the ShoppingSidebarParent as it does not need to handle the state of the sidebar opening or closing.
- ReviewCheckerChild is just extends ShoppingSidebarChild for now, though it will need to be separate in the future.
- Adds a browser.shopping.experience2023.shoppingSidebar boolean pref to disable ShoppingSidebar actors when they are not needed.
- Fixes `AbortError` error handling when the outer sidebar browser is removed.
Note that any auto-opening or closing behavior will need to be added afterwards, as these actors are not around to check product urls when the sidebar is closed.
Differential Revision: https://phabricator.services.mozilla.com/D222840
- Created a SidebarState API to manage reactive properties for the controller.
- Replaced usages of sidebarMain.hidden with state.launcherVisible.
- Replaced usages of sidebarMain.expanded with state.launcherExpanded.
- Removed toggleExpanded() and toggleHide(), replaced with equivalent state toggles.
Differential Revision: https://phabricator.services.mozilla.com/D229558