mirror of
https://github.com/zen-browser/desktop.git
synced 2026-04-05 07:09:30 +00:00
fix: Fixed flashing backgrounds at startup and animating tabs from session restore, b=no-bug, c=common
This commit is contained in:
@@ -59,7 +59,7 @@ var gZenUIManager = {
|
||||
)
|
||||
).observe(gNavToolbox);
|
||||
|
||||
SessionStore.promiseAllWindowsRestored.then(() => {
|
||||
gZenWorkspaces.promiseInitialized.finally(() => {
|
||||
this._hasLoadedDOM = true;
|
||||
this.updateTabsToolbar();
|
||||
});
|
||||
@@ -599,7 +599,7 @@ var gZenVerticalTabsManager = {
|
||||
},
|
||||
|
||||
animateTab(aTab) {
|
||||
if (!gZenUIManager.motion || !aTab || !gZenUIManager._hasLoadedDOM) {
|
||||
if (!gZenUIManager.motion || !aTab || !gZenUIManager._hasLoadedDOM || !aTab.isConnected) {
|
||||
return;
|
||||
}
|
||||
// get next visible tab
|
||||
@@ -624,7 +624,11 @@ var gZenVerticalTabsManager = {
|
||||
easing: 'ease-out',
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
.then(() => {})
|
||||
.catch((err) => {
|
||||
console.error(err);
|
||||
})
|
||||
.finally(() => {
|
||||
aTab.style.removeProperty('margin-bottom');
|
||||
aTab.style.removeProperty('transform');
|
||||
aTab.style.removeProperty('opacity');
|
||||
@@ -640,7 +644,11 @@ var gZenVerticalTabsManager = {
|
||||
easing: 'ease-out',
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
.then(() => {})
|
||||
.catch((err) => {
|
||||
console.error(err);
|
||||
})
|
||||
.finally(() => {
|
||||
aTab.querySelector('.tab-stack').style.removeProperty('filter');
|
||||
});
|
||||
} catch (e) {
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
:root[zen-before-loaded='true'] #browser > *:not(#zen-browser-background, #zen-toast-container),
|
||||
:root[zen-before-loaded='true'] #browser > *:not(#zen-toast-container),
|
||||
:root[zen-before-loaded='true'] #urlbar {
|
||||
opacity: 0 !important;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user