chore: Small fixes for testing, b=(no-bug), c=kbs, split-view, tests, workspaces

This commit is contained in:
Mr. M
2025-05-04 23:17:17 +02:00
parent 05df28ae72
commit 13923b84f2
9 changed files with 21 additions and 5 deletions

2
l10n

Submodule l10n updated: 9a673b4339...5a1124db1f

View File

@@ -219,7 +219,6 @@ pref('zen.watermark.enabled', false, sticky);
// Privacy
pref('dom.private-attribution.submission.enabled', false);
pref('dom.security.https_only_mode', true);
// Crash reports
pref("breakpad.reportURL", "");

View File

@@ -45,7 +45,7 @@
<label data-l10n-id="zen-panel-ui-gradient-generator-custom-color"></label>
<hbox>
<html:input type="text" placeholder="#000000" id="PanelUI-zen-gradient-generator-custom-input" />
<toolbarbutton id="PanelUI-zen-gradient-generator-color-custom-add" class="subviewbutton" data-l10n-id="zen-panel-ui-gradient-generator-custom-color-add">
<toolbarbutton id="PanelUI-zen-gradient-generator-color-custom-add" class="subviewbutton">
<image></image>
</toolbarbutton>
</hbox>

View File

@@ -808,6 +808,8 @@ var zenMissingKeyboardShortcutL10n = {
key_accessibility: 'zen-devtools-toggle-accessibility-shortcut',
};
var zenIgnoreKeyboardShortcutL10n = ['zen-full-zoom-reduce-shortcut-alt-b', 'zen-full-zoom-reduce-shortcut-alt-a'];
var gZenCKSSettings = {
async init() {
await this._initializeCKS();
@@ -871,6 +873,10 @@ var gZenCKSSettings = {
const labelValue = zenMissingKeyboardShortcutL10n[keyID] ?? l10nID;
if (zenIgnoreKeyboardShortcutL10n.includes(labelValue)) {
continue;
}
let fragment = window.MozXULElement.parseXULToFragment(`
<hbox class="${ZEN_CKS_CLASS_BASE}">
<label class="${ZEN_CKS_LABEL_CLASS}" for="${ZEN_CKS_CLASS_BASE}-${keyID}"></label>

View File

@@ -399,7 +399,7 @@ class KeyShortcut {
// note that this l10n id is not used for actually translating the key's label, but rather to
// identify the default keybinds.
if (this.#l10nId) {
key.setAttribute('data-l10n-id', this.#l10nId);
// key.setAttribute('data-l10n-id', this.#l10nId);
}
key.setAttribute('modifiers', this.#modifiers.toString());
if (this.#action) {

View File

@@ -839,6 +839,7 @@ class ZenViewSplitter extends ZenDOMOperatedFeature {
<menuseparator/>
<menuitem id="context_zenSplitTabs"
data-lazy-l10n-id="tab-zen-split-tabs"
data-l10n-args='{"tabCount": 1}'
command="cmd_zenSplitViewContextMenu"/>
<menuseparator/>
`);

View File

@@ -6,6 +6,8 @@ if [ ! -f "package.json" ]; then
exit 1
fi
#npm run build:ui
cd ./engine
./mach mochitest zen/tests/ $@
cd ..

View File

@@ -1062,7 +1062,11 @@
}
const button = browser.document.getElementById('PanelUI-zen-gradient-generator-color-toggle-algo');
document.l10n.setAttributes(button, `zen-panel-ui-gradient-generator-algo-${browser.gZenThemePicker.useAlgo}`);
if (browser.gZenThemePicker.useAlgo) {
document.l10n.setAttributes(button, `zen-panel-ui-gradient-generator-algo-${browser.gZenThemePicker.useAlgo}`);
} else {
button.removeAttribute('data-l10n-id');
}
browser.gZenThemePicker.resetCustomColorList();
if (!workspaceTheme || workspaceTheme.type !== 'gradient') {

View File

@@ -175,6 +175,10 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
return null;
}
if (gZenUIManager.testingEnabled) {
return null;
}
try {
// Check if we have a valid empty tab and can replace new tab
if (