diff --git a/src/zen/workspaces/ZenWorkspace.mjs b/src/zen/workspaces/ZenWorkspace.mjs index 5c24fd827..7e48a2f0e 100644 --- a/src/zen/workspaces/ZenWorkspace.mjs +++ b/src/zen/workspaces/ZenWorkspace.mjs @@ -88,7 +88,11 @@ this.scrollbox._canScrollToElement = (element) => { if (gBrowser.isTab(element)) { - return !element.hasAttribute('zen-essential') || !this.hasAttribute('positionpinnedtabs'); + return ( + !element.hasAttribute('zen-essential') && + !this.hasAttribute('positionpinnedtabs') && + !element.hasAttribute('zen-empty-tab') + ); } return true; }; diff --git a/src/zen/workspaces/ZenWorkspaces.mjs b/src/zen/workspaces/ZenWorkspaces.mjs index 762059c6f..13ca5d02b 100644 --- a/src/zen/workspaces/ZenWorkspaces.mjs +++ b/src/zen/workspaces/ZenWorkspaces.mjs @@ -2600,7 +2600,10 @@ var gZenWorkspaces = new (class extends ZenMultiWindowFeature { forAnimation = false; } for (const entry of entries) { - const originalWorkspaceId = entry.target.getAttribute('zen-workspace-id'); + let originalWorkspaceId = entry.target.getAttribute('zen-workspace-id'); + if (!originalWorkspaceId) { + originalWorkspaceId = entry.target.closest('zen-workspace')?.id; + } const workspacesIds = []; if (entry.target.closest('#zen-essentials')) { // Get all workspaces that have the same userContextId