Commit Graph

62 Commits

Author SHA1 Message Date
Sam Foster
829925fc2c Bug 1954056 - Avoid closing the sidebar launcher when just closing the open panel. r=sidebar-reviewers,kcochrane
* Remove some of the overloading of SidebarState.updateVisibility
* Remove the no-longer-used #previousLauncherExpanded property
* SidebarController.hide() just hides the panel (same as legacy/original API)
* Skip the browser_toolbarKeyNav.js test when sidebar.revamp=true, this should have been failing all along.

Differential Revision: https://phabricator.services.mozilla.com/D242240
2025-03-28 00:27:49 +00:00
Cosmin Sabou
a6f42c65a8 Backed out changeset a99655962ea6 (bug 1954056) for turning browser_toolbarKeyNav.js into permafail. CLOSED TREE 2025-03-27 06:41:26 +02:00
Sam Foster
b87c7b1846 Bug 1954056 - Avoid closing the sidebar launcher when just closing the open panel. r=sidebar-reviewers,kcochrane
* Remove some of the overloading of SidebarState.updateVisibility
* Remove the no-longer-used #previousLauncherExpanded property
* SidebarController.hide() just hides the panel (same as legacy/original API)

Differential Revision: https://phabricator.services.mozilla.com/D242240
2025-03-26 23:00:27 +00:00
Kelly Cochrane
6685a37131 Bug 1950419 - Prevent sidebar from collapsing when opening context menu if expand on hover is enabled r=tabbrowser-reviewers,sidebar-reviewers,jsudiaman
Differential Revision: https://phabricator.services.mozilla.com/D242740
2025-03-26 19:14:46 +00:00
Kelly Cochrane
d8275ce7d6 Bug 1951427 - Rework expand on hover to only overlay the sidebar launcher r=desktop-theme-reviewers,tabbrowser-reviewers,sidebar-reviewers,dao,emilio,sclements
Differential Revision: https://phabricator.services.mozilla.com/D240171
2025-03-14 13:09:18 +00:00
Goloman Adrian
8cbc210af4 Backed out changeset e93b9b73aebd (bug 1951427) for causing bc failures @browser_sidebar_move.js. 2025-03-14 08:20:43 +02:00
Kelly Cochrane
8959c0fe82 Bug 1951427 - Rework expand on hover to only overlay the sidebar launcher r=desktop-theme-reviewers,tabbrowser-reviewers,sidebar-reviewers,dao,emilio,sclements
Differential Revision: https://phabricator.services.mozilla.com/D240171
2025-03-13 23:39:02 +00:00
Sam Foster
5e0d65a91e Bug 1921536 - Make the SidebarState the source of truth for the current sidebar command/panel and re-open previous panel when toggling the sidebar open. r=sidebar-reviewers,jsudiaman
* We retain the behavior from legacy sidebar which re-opens the previously open sidebar panel when the sidebar is toggled open
* Rename SidebarState's '#previousLauncherVisible' to '#previousLauncherExpanded' as it actually tracks expandedness
* Don't persist the panel/command id when the panel isn't open
* Ensure all the sidebar tests reset the sidebar state when they are done

Differential Revision: https://phabricator.services.mozilla.com/D234773
2025-03-12 16:41:47 +00:00
Goloman Adrian
6847fa7ceb Backed out changeset 4754bc9e58f3 (bug 1921536) for causing bc failures @browser_toolbarKeyNav.js 2025-03-08 09:15:01 +02:00
Sam Foster
ace31bb084 Bug 1921536 - Make the SidebarState the source of truth for the current sidebar command/panel and re-open previous panel when toggling the sidebar open. r=sidebar-reviewers,jsudiaman
* We retain the behavior from legacy sidebar which re-opens the previously open sidebar panel when the sidebar is toggled open
* Rename SidebarState's '#previousLauncherVisible' to '#previousLauncherExpanded' as it actually tracks expandedness
* Don't persist the panel/command id when the panel isn't open
* Ensure all the sidebar tests reset the sidebar state when they are done

Differential Revision: https://phabricator.services.mozilla.com/D234773
2025-03-08 05:17:08 +00:00
Sandor Molnar
b51ff49434 Backed out changeset f56181344f2a (bug 1921536) for causing bc failures @ browser_bookmark_context_menu_contents.js & browser_reviewchecker_sidebar.js CLOSED TREE 2025-03-06 06:15:10 +02:00
Sam Foster
dc4f09430e Bug 1921536 - Make the SidebarState the source of truth for the current sidebar command/panel and re-open previous panel when toggling the sidebar open. r=sidebar-reviewers,jsudiaman
* We retain the behavior from legacy sidebar which re-opens the previously open sidebar panel when the sidebar is toggled open
* Rename SidebarState's '#previousLauncherVisible' to '#previousLauncherExpanded' as it actually tracks expandedness
* Don't persist the panel/command id when the panel isn't open
* Ensure all the sidebar tests reset the sidebar state when they are done

Differential Revision: https://phabricator.services.mozilla.com/D234773
2025-03-06 01:52:28 +00:00
Jonathan Sudiaman
bea3043c03 Bug 1950962 - Add prefs to be set to true for old or new sidebar usage r=sidebar-reviewers,sfoster
Differential Revision: https://phabricator.services.mozilla.com/D239961
2025-02-28 23:07:10 +00:00
Goloman Adrian
a048ca4c8b Backed out changeset b0a8901d8246 (bug 1921536) for casuing failures @test_sidebar_state.js. 2025-02-27 10:46:12 +02:00
Sam Foster
d318c71f26 Bug 1921536 - Make the SidebarState the source of truth for the current sidebar command/panel and re-open previous panel when toggling the sidebar open. r=sidebar-reviewers,jsudiaman
* We retain the behavior from legacy sidebar which re-opens the previously open sidebar panel when the sidebar is toggled open
* Rename SidebarState's '#previousLauncherVisible' to '#previousLauncherExpanded' as it actually tracks expandedness
* Don't persist the panel/command id when the panel isn't open
* Ensure all the sidebar tests reset the sidebar state when they are done

Differential Revision: https://phabricator.services.mozilla.com/D234773
2025-02-27 07:22:17 +00:00
Jonathan Sudiaman
c74cba113e Bug 1948925 - SidebarState: launcherWidth setter should only update launcherExpanded during a drag-and-drop resize r=sidebar-reviewers,nsharpley
https://treeherder.mozilla.org/#/jobs?repo=try&revision=b9e1c7d04d1e985dd13237a7866ddae82cf70b78

Differential Revision: https://phabricator.services.mozilla.com/D238632
2025-02-24 13:20:46 +00:00
Jonathan Sudiaman
15bccd9659 Bug 1947607 - Replace calls to flushTaskQueue() with more precise waits r=sidebar-reviewers,nsharpley,sfoster
- Remove flushTaskQueue() from head.js and its usages. Reduce arbitrary waits as much as possible.
- Replace _waitForOngoingAnimations() with a generic function to await all UI updates, which can be used in tests as well.
- Create a helper method to reliably wait for a repaint for cases where it's truly necessary.

Differential Revision: https://phabricator.services.mozilla.com/D238042
2025-02-24 13:20:45 +00:00
Sandor Molnar
e2d60a3172 Backed out 2 changesets (bug 1947607, bug 1948925) for causing sidebar related bc failures CLOSED TREE
Backed out changeset ea661e75b85b (bug 1948925)
Backed out changeset c2881b804a7c (bug 1947607)
2025-02-19 04:32:59 +02:00
Jonathan Sudiaman
707a9a1b51 Bug 1948925 - SidebarState: launcherWidth setter should only update launcherExpanded during a drag-and-drop resize r=sidebar-reviewers,nsharpley
https://treeherder.mozilla.org/#/jobs?repo=try&revision=b9e1c7d04d1e985dd13237a7866ddae82cf70b78

Differential Revision: https://phabricator.services.mozilla.com/D238632
2025-02-19 01:36:13 +00:00
Jonathan Sudiaman
a87903a846 Bug 1947607 - Replace calls to flushTaskQueue() with more precise waits r=sidebar-reviewers,nsharpley,sfoster
- Remove flushTaskQueue() from head.js and its usages. Reduce arbitrary waits as much as possible.
- Replace _waitForOngoingAnimations() with a generic function to await all UI updates, which can be used in tests as well.
- Create a helper method to reliably wait for a repaint for cases where it's truly necessary.

Differential Revision: https://phabricator.services.mozilla.com/D238042
2025-02-19 01:36:13 +00:00
Nikki Sharpley
70e23c057f Bug 1941625 - Add context menu items for sidebar main r=sidebar-reviewers,fluent-reviewers,bolsson,kcochrane
On right clicking the sidebar main element when vertical tabs are disabled,
show options for hiding the sidebar, customizing the sidebar and turning on
vertical tabs.

Differential Revision: https://phabricator.services.mozilla.com/D237264
2025-02-18 19:26:53 +00:00
Cosmin Sabou
f14010e66b Backed out changeset 650ff35a3ff0 (bug 1941625) for causing browser_sidebar related failures. CLOSED TREE 2025-02-14 21:22:29 +02:00
Nikki Sharpley
4d1b9a0447 Bug 1941625 - Add context menu items for sidebar main r=sidebar-reviewers,fluent-reviewers,bolsson,kcochrane
On right clicking the sidebar main element when vertical tabs are disabled,
show options for hiding the sidebar, customizing the sidebar and turning on
vertical tabs.

Differential Revision: https://phabricator.services.mozilla.com/D237264
2025-02-14 15:55:45 +00:00
Sam Foster
8559325d30 Bug 1947526 - Preserve user's visibility pref value and fix default expanded state when switching to vertical tabs. r=sidebar-reviewers,nsharpley,kcochrane
* Make sure we don't overwrite a user's choice to hide-sidebars in vertical tabs at startup
* Roll in a fix to bug 1947257 and ensure the launcher is initially expanded when enabling vertical tabs

Differential Revision: https://phabricator.services.mozilla.com/D237849
2025-02-13 23:45:43 +00:00
Nikki Sharpley
94a85bdc4f Bug 1944910 - Hide sidebar main element when "hide-sidebar" is selected in vertical tabs mode.r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236605
2025-02-11 16:29:47 +00:00
Jonathan Sudiaman
80c4ec2838 Bug 1946188 - Add test for resizing the sidebar after toggling revamp on and off r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236935
2025-02-11 00:05:12 +00:00
Jonathan Sudiaman
5e9cd630a5 Bug 1945927 - Ensure that resize observer is restored when reinitializing revamped sidebar. r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236933
2025-02-11 00:05:12 +00:00
Norisz Fay
322845f56e Backed out changeset 022da00de2e7 (bug 1944910) for causing failures on browser_vertical_tabs.js CLOSED TREE 2025-02-11 05:34:20 +02:00
Nikki Sharpley
3b00c42254 Bug 1944910 - Hide sidebar main element when "hide-sidebar" is selected in vertical tabs mode.r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236605
2025-02-10 14:32:23 +00:00
Alexandru Marc
88bcc4fdba Backed out 2 changesets (bug 1946188, bug 1945927) for causing bc failures @ browser_sidebar_max_width.js
Backed out changeset 12f92dcdff8d (bug 1946188)
Backed out changeset b71374a4ec8d (bug 1945927)
2025-02-10 16:59:42 +02:00
Jonathan Sudiaman
856cc21a41 Bug 1946188 - Add test for resizing the sidebar after toggling revamp on and off r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236935
2025-02-10 13:31:32 +00:00
Jonathan Sudiaman
fa275b3b28 Bug 1945927 - Ensure that resize observer is restored when reinitializing revamped sidebar. r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236933
2025-02-10 13:31:32 +00:00
Alexandru Marc
f43ff8bcd9 Backed out changeset 24d23a09f65c (bug 1944910) for causing bc failures @ browser_newtabButton.js CLOSED TREE 2025-02-08 15:17:08 +02:00
Nikki Sharpley
88603ffd0e Bug 1944910 - Hide sidebar main element when "hide-sidebar" is selected in vertical tabs mode.r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236605
2025-02-07 22:03:50 +00:00
Goloman Adrian
d2c88036c2 Backed out changeset ff0ae341ed38 (bug 1945927) for causing bc failures @browser_customize_sidebar.js. CLOSED TREE 2025-02-06 18:52:47 +02:00
Jonathan Sudiaman
094417d2bf Bug 1945927 - Ensure that resize observer is restored when reinitializing revamped sidebar. r=sidebar-reviewers,kcochrane
Differential Revision: https://phabricator.services.mozilla.com/D236933
2025-02-06 15:27:35 +00:00
Kelly Cochrane
cae199c0f2 Bug 1930201 - Add option to expand sidebar on hover r=desktop-theme-reviewers,sidebar-reviewers,emilio,tabbrowser-reviewers,flod,sclements,dao
Differential Revision: https://phabricator.services.mozilla.com/D233098
2025-02-05 18:04:20 +00:00
Stanca Serban
0efa589b90 Backed out changeset 1be8354cedcd (bug 1930201) for causing mochitests failures. CLOSED TREE 2025-02-05 19:11:28 +02:00
Kelly Cochrane
03c6b75a99 Bug 1930201 - Add option to expand sidebar on hover r=desktop-theme-reviewers,sidebar-reviewers,emilio,tabbrowser-reviewers,flod,sclements,dao
Differential Revision: https://phabricator.services.mozilla.com/D233098
2025-02-05 14:05:08 +00:00
Jonathan Sudiaman
0979dad16f Bug 1944842 - Sidebar can get into scenario where it's expanded but vertical tabs aren't showing labels r=sidebar-reviewers,sfoster
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
2025-02-03 15:05:46 +00:00
Nikki Sharpley
3a0cdaac95 Bug 1939917 - Update Sidebar visibility settings and settings order r=sidebar-reviewers,fluent-reviewers,desktop-theme-reviewers,bolsson,sclements,hjones
- change order of settings as per spec
- only show visibilty settings if vertical tabs enabled

Depends on D234592

Differential Revision: https://phabricator.services.mozilla.com/D235178
2025-01-31 17:20:04 +00:00
Stanca Serban
20ad1078ea Backed out changeset fed22f8c018a (bug 1944842) for causing mochitests failures in browser_toolbar_sidebar_button.js. CLOSED TREE 2025-01-31 18:02:47 +02:00
Jonathan Sudiaman
5effea42bc Bug 1944842 - Sidebar can get into scenario where it's expanded but vertical tabs aren't showing labels r=sidebar-reviewers,sfoster
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
2025-01-31 14:09:59 +00:00
Goloman Adrian
93e9d720c3 Backed out changeset 85ef05d78aa4 (bug 1944842) for causing bc failures @browser_resize_sidebar.js. 2025-01-30 23:28:35 +02:00
Jonathan Sudiaman
1294445e6e Bug 1944842 - Sidebar can get into scenario where it's expanded but vertical tabs aren't showing labels r=sidebar-reviewers,sfoster
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
2025-01-30 19:25:30 +00:00
Nikki Sharpley
551f8d2aaa Bug 1938249 - Disable expanded sidebar behaviour for horizontal tabs mode r=sidebar-reviewers,desktop-theme-reviewers,dao,jsudiaman,kcochrane,sessionstore-reviewers
- 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
2025-01-28 00:51:28 +00:00
Butkovits Atila
a375e8316f Backed out changeset ead9919b0da6 (bug 1938249) for causing failures at test_restore_sidebar.py. CLOSED TREE 2025-01-27 23:43:36 +02:00
Nikki Sharpley
5d44461250 Bug 1938249 - Disable expanded sidebar behaviour for horizontal tabs mode r=sidebar-reviewers,desktop-theme-reviewers,dao,jsudiaman,kcochrane
- 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
2025-01-27 18:19:26 +00:00
Goloman Adrian
7dc18d7e06 Backed out changeset 2e8e6c3c9ad8 (bug 1938249) for causing bc failures @browser_glean_sidebar.js. CLOSED TREE 2025-01-27 18:50:28 +02:00
Nikki Sharpley
e80180f302 Bug 1938249 - Disable expanded sidebar behaviour for horizontal tabs mode r=sidebar-reviewers,desktop-theme-reviewers,dao,jsudiaman,kcochrane
- 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
2025-01-27 15:52:05 +00:00