fix: prevent unnecessary window resize handling when event is not from the window

This commit is contained in:
mr. M
2025-03-21 07:51:24 +01:00
parent 4a9967b8d0
commit ba89f392d6

View File

@@ -2372,7 +2372,8 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
return workspace.containerTabId;
}
onWindowResize() {
onWindowResize(event = undefined) {
if (!(!event || event.target === window)) return;
// Check if workspace icons overflow the parent container
const parent = document.getElementById('zen-workspaces-button');
if (!parent) {