chore: Update l10n submodule commit

This commit is contained in:
Mauro Balades
2024-08-25 13:03:10 +02:00
parent 3def55d48b
commit dd68add538
4 changed files with 23 additions and 4 deletions

2
l10n

Submodule l10n updated: bfcfcf1aab...6f103b0af5

View File

@@ -26,7 +26,23 @@ var gZenMarketplaceManager = {
Services.prefs.addObserver(this.updatePref, this._buildThemesList.bind(this)); Services.prefs.addObserver(this.updatePref, this._buildThemesList.bind(this));
this._buildThemesList(); this._buildThemesList();
document.getElementById("zenThemeMarketplaceCheckForUpdates").addEventListener("click", (event) => { document.getElementById("zenThemeMarketplaceCheckForUpdates").addEventListener("click", (event) => {
this._checkForThemeUpdates(event); if (event.target === document.getElementById("zenThemeMarketplaceCheckForUpdates")) {
event.preventDefault();
this._checkForThemeUpdates(event);
}
});
document.addEventListener("ZenThemeMarketplace:CheckForUpdatesFinished", (event) => {
document.getElementById("zenThemeMarketplaceCheckForUpdates").disabled = false;
const updates = event.detail.updates;
const success = document.getElementById("zenThemeMarketplaceUpdatesSuccess");
const error = document.getElementById("zenThemeMarketplaceUpdatesFailure");
if (updates) {
success.hidden = false;
error.hidden = true;
} else {
success.hidden = true;
error.hidden = false;
}
}); });
}, },
@@ -140,7 +156,7 @@ var gZenMarketplaceManager = {
<button class="zenThemeMarketplaceItemUninstallButton" data-l10n-id="zen-theme-marketplace-remove-button" zen-theme-id="${theme.id}"></button> <button class="zenThemeMarketplaceItemUninstallButton" data-l10n-id="zen-theme-marketplace-remove-button" zen-theme-id="${theme.id}"></button>
</hbox> </hbox>
`); `);
fragment.querySelector(".zenThemeMarketplaceItemTitle").textContent = theme.name; fragment.querySelector(".zenThemeMarketplaceItemTitle").textContent = `${theme.name} (v${theme.version || "1.0.0"})`;
fragment.querySelector(".zenThemeMarketplaceItemDescription").textContent = theme.description; fragment.querySelector(".zenThemeMarketplaceItemDescription").textContent = theme.description;
fragment.querySelector(".zenThemeMarketplaceItemUninstallButton").addEventListener("click", async (event) => { fragment.querySelector(".zenThemeMarketplaceItemUninstallButton").addEventListener("click", async (event) => {
if (!confirm("Are you sure you want to remove this theme?")) { if (!confirm("Are you sure you want to remove this theme?")) {

View File

@@ -14,6 +14,9 @@
<button id="zenThemeMarketplaceCheckForUpdates" data-l10n-id="zen-theme-marketplace-check-for-updates-button" /> <button id="zenThemeMarketplaceCheckForUpdates" data-l10n-id="zen-theme-marketplace-check-for-updates-button" />
</hbox> </hbox>
<description class="description-deemphasized" data-l10n-id="zen-theme-marketplace-updates-success" hidden="true" id="zenThemeMarketplaceUpdatesSuccess" />
<description class="description-deemphasized" data-l10n-id="zen-theme-marketplace-updates-failure" hidden="true" id="zenThemeMarketplaceUpdatesFailure" />
<vbox id="zenThemeMarketplaceList"></vbox> <vbox id="zenThemeMarketplaceList"></vbox>
</groupbox> </groupbox>