mirror of
https://github.com/zen-browser/desktop.git
synced 2025-10-15 14:26:12 +00:00
Enhance ZenStartup and ZenThemesImporter for improved animation and URL matching; update migration version in ZenUIMigration for future enhancements
This commit is contained in:
@@ -58,7 +58,7 @@
|
||||
if (Services.prefs.getBoolPref('zen.watermark.enabled', false)) {
|
||||
gZenUIManager.motion
|
||||
.animate(
|
||||
'#browser > *, #urlbar',
|
||||
'#browser > *, #urlbar, #tabbrowser-tabbox > *',
|
||||
{
|
||||
opacity: [0, 1],
|
||||
},
|
||||
@@ -68,7 +68,7 @@
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
for (let elem of document.querySelectorAll('#browser > *, #urlbar')) {
|
||||
for (let elem of document.querySelectorAll('#browser > *, #urlbar, #tabbrowser-tabbox > *')) {
|
||||
elem.style.removeProperty('opacity');
|
||||
}
|
||||
});
|
||||
|
@@ -313,5 +313,10 @@ gZenActorsManager.addJSWindowActor('ZenThemeMarketplace', {
|
||||
DOMContentLoaded: {},
|
||||
},
|
||||
},
|
||||
matches: [...Services.prefs.getStringPref('zen.injections.match-urls').split(','), 'about:preferences'],
|
||||
includeChrome: true,
|
||||
matches: [
|
||||
...Services.prefs.getStringPref('zen.injections.match-urls').split(','),
|
||||
'about:preferences',
|
||||
'chrome://browser/content/browser.xhtml',
|
||||
],
|
||||
});
|
||||
|
@@ -6,7 +6,7 @@ ChromeUtils.defineESModuleGetters(lazy, {
|
||||
|
||||
class ZenUIMigration {
|
||||
PREF_NAME = 'zen.migration.version';
|
||||
MIGRATION_VERSION = 1;
|
||||
MIGRATION_VERSION = 2;
|
||||
|
||||
init(isNewProfile, win) {
|
||||
if (!isNewProfile) {
|
||||
@@ -27,6 +27,9 @@ class ZenUIMigration {
|
||||
if (this._migrationVersion < 1) {
|
||||
this._migrateV1(win);
|
||||
}
|
||||
if (this._migrationVersion < 2) {
|
||||
this._migrateV2(win);
|
||||
}
|
||||
}
|
||||
|
||||
clearVariables() {
|
||||
@@ -56,7 +59,11 @@ class ZenUIMigration {
|
||||
},
|
||||
]
|
||||
);
|
||||
notification.persistence = -1;
|
||||
}
|
||||
|
||||
async _migrateV2(win) {
|
||||
// Just check for mods updates until we get an actual implementation
|
||||
document.dispatchEvent(new CustomEvent('ZenCheckForThemeUpdates'));
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user