diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c8e842c6d..518265a08 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -436,13 +436,15 @@ jobs: sudo ./aws/install --update - name: Stop self-hosted runner + if: ${{ inputs.create_release && inputs.update_branch == 'release' }} run: | echo "Stopping self-hosted runner" echo "${{ secrets.SELF_HOSTED_RUNNER_STOP_SCRIPT }}" | base64 -d > stop.sh sudo chmod +x stop.sh - bash ./stop.sh + bash ./stop.sh > /dev/null - name: Remove self-hosted runner script + if: always() && ${{ inputs.create_release && inputs.update_branch == 'release' }} run: | echo "Removing self-hosted runner script" rm stop.sh || true diff --git a/src/browser/base/content/ZenCustomizableUI.sys.mjs b/src/browser/base/content/ZenCustomizableUI.sys.mjs index 931bd30b0..f31a4fe4f 100644 --- a/src/browser/base/content/ZenCustomizableUI.sys.mjs +++ b/src/browser/base/content/ZenCustomizableUI.sys.mjs @@ -125,5 +125,8 @@ export var ZenCustomizableUI = new (class { registerToolbarNodes(window) { window.CustomizableUI.registerToolbarNode(window.document.getElementById('zen-sidebar-top-buttons')); window.CustomizableUI.registerToolbarNode(window.document.getElementById('zen-sidebar-icons-wrapper')); + window.addEventListener('DOMContentLoaded', () => { + this._dispatchResizeEvent(window); + }, { once: true }); } })(); diff --git a/src/browser/components/customizableui/CustomizableUI-sys-mjs.patch b/src/browser/components/customizableui/CustomizableUI-sys-mjs.patch index cefac0312..d713fe2a4 100644 --- a/src/browser/components/customizableui/CustomizableUI-sys-mjs.patch +++ b/src/browser/components/customizableui/CustomizableUI-sys-mjs.patch @@ -1,5 +1,5 @@ diff --git a/browser/components/customizableui/CustomizableUI.sys.mjs b/browser/components/customizableui/CustomizableUI.sys.mjs -index b953d7d2c8fa7fe2d320bd7cb7af9aeeef0abc86..bb9568158ddf53801de576af05c50ff9c0f333c6 100644 +index b953d7d2c8fa7fe2d320bd7cb7af9aeeef0abc86..251c3a7fa624057a8eaba5c0c42ef23fe2a6ace3 100644 --- a/browser/components/customizableui/CustomizableUI.sys.mjs +++ b/browser/components/customizableui/CustomizableUI.sys.mjs @@ -13,6 +13,7 @@ ChromeUtils.defineESModuleGetters(lazy, { @@ -124,16 +124,12 @@ index b953d7d2c8fa7fe2d320bd7cb7af9aeeef0abc86..bb9568158ddf53801de576af05c50ff9 /** * Add a widget to an area. * If the area to which you try to add is not known to CustomizableUI, -@@ -6370,7 +6369,7 @@ class OverflowableToolbar { - */ - async #getOverflowInfo() { - function getInlineSize(aElement) { -- return aElement.getBoundingClientRect().width; -+ return aElement.getBoundingClientRect().width - ((win.gZenVerticalTabsManager._hasSetSingleToolbar && aElement.closest('#zen-sidebar-top-buttons-customization-target')) ? win.gZenVerticalTabsManager._topButtonsSeparatorElement.getBoundingClientRect().width : 0); - } - - function sumChildrenInlineSize(aParent, aExceptChild = null) { -@@ -6412,7 +6411,7 @@ class OverflowableToolbar { +@@ -6408,11 +6407,11 @@ class OverflowableToolbar { + parseFloat(style.paddingLeft) - + parseFloat(style.paddingRight) - + toolbarChildrenWidth; +- targetWidth = getInlineSize(this.#target); ++ targetWidth = getInlineSize(this.#target) - ((win.gZenVerticalTabsManager._hasSetSingleToolbar && this.#target.id == 'zen-sidebar-top-buttons-customization-target') ? win.gZenVerticalTabsManager._topButtonsSeparatorElement.getBoundingClientRect().width : 0); targetChildrenWidth = this.#target == this.#toolbar ? toolbarChildrenWidth @@ -142,16 +138,17 @@ index b953d7d2c8fa7fe2d320bd7cb7af9aeeef0abc86..bb9568158ddf53801de576af05c50ff9 }); lazy.log.debug( -@@ -6422,7 +6421,7 @@ class OverflowableToolbar { +@@ -6422,7 +6421,8 @@ class OverflowableToolbar { // If the target has min-width: 0, their children might actually overflow // it, so check for both cases explicitly. let targetContentWidth = Math.max(targetWidth, targetChildrenWidth); - let isOverflowing = Math.floor(targetContentWidth) > totalAvailWidth; ++ if (win.gZenVerticalTabsManager._hasSetSingleToolbar && this.#toolbar == 'nav-bar') return { isOverflowing: false, targetContentWidth, totalAvailWidth }; + let isOverflowing = Math.floor(targetContentWidth) + (win.gZenVerticalTabsManager._hasSetSingleToolbar ? 0.1 : 0) > totalAvailWidth; return { isOverflowing, targetContentWidth, totalAvailWidth }; } -@@ -6516,7 +6515,7 @@ class OverflowableToolbar { +@@ -6516,7 +6516,7 @@ class OverflowableToolbar { } } if (!inserted) {