chore: Change the use of hidden after the new firefox update, b=no-bug, c=compact-mode, split-view, workspaces

This commit is contained in:
Mr. M
2025-09-13 01:46:35 +02:00
parent 9ce963f1cd
commit 5c8e6dd5a4
3 changed files with 21 additions and 8 deletions

View File

@@ -513,7 +513,11 @@ class nsZenViewSplitter extends nsZenDOMOperatedFeature {
const wrapper = this.overlay?.parentNode;
if (!wrapper) return;
wrapper.setAttribute('hidden', !value);
if (!value) {
wrapper.setAttribute('hidden', 'true');
} else {
wrapper.removeAttribute('hidden');
}
}
enableTabRearrangeView(tabDrag = false) {
@@ -896,9 +900,12 @@ class nsZenViewSplitter extends nsZenDOMOperatedFeature {
tabCount: window.gBrowser.selectedTabs.length,
});
document.getElementById('context_zenSplitTabs').setAttribute('data-l10n-args', tabCountInfo);
document
.getElementById('context_zenSplitTabs')
.setAttribute('hidden', !this.contextCanSplitTabs());
const splitTabs = document.getElementById('context_zenSplitTabs');
if (!this.contextCanSplitTabs()) {
splitTabs.setAttribute('hidden', 'true');
} else {
splitTabs.removeAttribute('hidden');
}
});
}